dev_course
cxt 5 years ago
parent 177dded969
commit bf9796c8b5

@ -34,7 +34,7 @@ json.homeworks @homework_commons.each do |homework|
current_myshixun = homework.user_work(@user.id).try(:myshixun) current_myshixun = homework.user_work(@user.id).try(:myshixun)
myshixun = current_myshixun ? current_myshixun : shixun.myshixuns.find_by(user_id: @user.id) myshixun = current_myshixun ? current_myshixun : shixun.myshixuns.find_by(user_id: @user.id)
# json.game_count current_myshixun ? current_myshixun.exec_count : 0 # json.game_count current_myshixun ? current_myshixun.exec_count : 0
json.task_operation task_operation_url(current_myshixun, shixun) json.task_operation task_operation_url(myshixun, shixun)
else else
work = homework.user_work(@user.id) work = homework.user_work(@user.id)
json.work_id work.try(:id) json.work_id work.try(:id)

Loading…
Cancel
Save