|
|
|
@ -364,10 +364,10 @@ class ExerciseQuestionsController < ApplicationController
|
|
|
|
|
Rails.logger.info("#####_________update_objective_score___________##############{update_objective_score}")
|
|
|
|
|
if update_objective_score != 0
|
|
|
|
|
objective_score = ex_user.objective_score
|
|
|
|
|
subjective_score = ex_user.subjective_score
|
|
|
|
|
total_score_subjective_score = subjective_score < 0.0 ? 0.0 : subjective_score
|
|
|
|
|
total_score = objective_score + update_objective_score + total_score_subjective_score
|
|
|
|
|
ex_user.update_attributes(objective_score:objective_score,score:total_score)
|
|
|
|
|
new_objective_score = objective_score + update_objective_score
|
|
|
|
|
total_score = ex_user.score + update_objective_score
|
|
|
|
|
total_score = total_score < 0.0 ? 0.0 : total_score
|
|
|
|
|
ex_user.update_attributes(objective_score:new_objective_score,score:total_score)
|
|
|
|
|
end
|
|
|
|
|
Rails.logger.info("#####_________ex_user.score___________##############{ex_user.score}")
|
|
|
|
|
# user = ex_user.user
|
|
|
|
|