|
|
@ -37,7 +37,8 @@ end
|
|
|
|
if @current_user_ex_answers.present?
|
|
|
|
if @current_user_ex_answers.present?
|
|
|
|
json.current_answer_user do
|
|
|
|
json.current_answer_user do
|
|
|
|
json.partial! "exercises/exercise_user",locals: {exercise_user:@current_user_ex_answers.first, subjective_type:@subjective_type,
|
|
|
|
json.partial! "exercises/exercise_user",locals: {exercise_user:@current_user_ex_answers.first, subjective_type:@subjective_type,
|
|
|
|
user_status:@exercise_current_user_status, exercise:@exercise}
|
|
|
|
user_status:@exercise_current_user_status, exercise:@exercise,
|
|
|
|
|
|
|
|
question_ids: @exercise.exercise_questions.pluck(:id)}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
@ -45,7 +46,8 @@ if @exercise_users_list.present?
|
|
|
|
json.exercise_users do
|
|
|
|
json.exercise_users do
|
|
|
|
json.array! @exercise_users_list.each do |exercise_user|
|
|
|
|
json.array! @exercise_users_list.each do |exercise_user|
|
|
|
|
json.partial! "exercises/exercise_user",locals: {exercise_user:exercise_user, subjective_type:@subjective_type,
|
|
|
|
json.partial! "exercises/exercise_user",locals: {exercise_user:exercise_user, subjective_type:@subjective_type,
|
|
|
|
user_status:@exercise_current_user_status, exercise:@exercise}
|
|
|
|
user_status:@exercise_current_user_status, exercise:@exercise,
|
|
|
|
|
|
|
|
question_ids: @exercise.exercise_questions.pluck(:id)}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
else
|
|
|
|
else
|
|
|
|