fixing bug with changed category names

pull/1/head
Jared Cosulich 8 years ago
parent a90cf41f79
commit 3030d8abad

@ -25,11 +25,11 @@ class Category < ApplicationRecord
def root_index
[
"teachers-and-the-teaching-environment",
"academic-learning",
"school-culture",
"resources",
"indicators-of-academic-learning",
"character-and-wellbeing-outcomes",
"citizenship-and-wellbeing",
"pilot-family-questions"
].index(root_identifier)
end

@ -2,9 +2,10 @@
.title.col-8
%h2= link_to('MCIEA'.html_safe, root_path)
.navigation.col-4.text-right
- if current_user
= link_to 'Sign Out', destroy_user_session_path, rel: "nofollow", method: :delete, class: 'btn btn-small grey waves-effect waves-light '
- else
= link_to 'Login', new_user_session_path, class: 'btn btn-small grey waves-effect waves-light '
=# link_to 'Register', new_user_registration_path, class: 'btn btn-small grey waves-effect waves-light '
-#
.navigation.col-4.text-right
- if current_user
= link_to 'Sign Out', destroy_user_session_path, rel: "nofollow", method: :delete, class: 'btn btn-small grey waves-effect waves-light '
- else
= link_to 'Login', new_user_session_path, class: 'btn btn-small grey waves-effect waves-light '
=# link_to 'Register', new_user_registration_path, class: 'btn btn-small grey waves-effect waves-light '

@ -1,5 +1,5 @@
- num_likerts = 5
- likert = info.answer_index_average || 0
- likert = info.answer_index_average
- average_offset = (likert/num_likerts) * 100
- approval_zone = [[76, 90], [77, 91], [71, 85], [73, 86], [73, 86], []][info.category.root_index]

Loading…
Cancel
Save