|
|
|
@ -1,6 +1,8 @@
|
|
|
|
|
if identity == Course::STUDENT
|
|
|
|
|
if homework.homework_type == "practice"
|
|
|
|
|
json.task_operation task_operation_url(work.try(:myshixun), homework.shixuns.take)
|
|
|
|
|
shixun = homework.shixuns.take
|
|
|
|
|
myshixun = work.try(:myshixun) ? work.myshixun : shixun.myshixuns.find_by(user_id: work.user_id)
|
|
|
|
|
json.task_operation task_operation_url(myshixun, shixun)
|
|
|
|
|
json.view_report work.work_status > 0
|
|
|
|
|
json.commit_des commit_des_status(work, homework)
|
|
|
|
|
else
|
|
|
|
|