Browse Source

shuffle if statement

pull/28/head
Kat 4 years ago
parent
commit
a2e74b32ab
  1. 9
      app/helpers/tasklist_helper.rb

9
app/helpers/tasklist_helper.rb

@ -17,12 +17,9 @@ module TasklistHelper
if subsection_name == "declaration" if subsection_name == "declaration"
return all_questions_completed(case_log) ? :not_started : :cannot_start_yet return all_questions_completed(case_log) ? :not_started : :cannot_start_yet
end end
if questions.all? {|question| case_log[question].blank?}
return :not_started return :not_started if questions.all? {|question| case_log[question].blank?}
end return :completed if questions.all? {|question| case_log[question].present?}
if questions.all? {|question| case_log[question].present?}
return :completed
end
:in_progress :in_progress
end end

Loading…
Cancel
Save