diff --git a/app/views/annotations/_show.html.erb b/app/views/annotations/_show.html.erb index 969c323..e5f122b 100644 --- a/app/views/annotations/_show.html.erb +++ b/app/views/annotations/_show.html.erb @@ -1,12 +1,27 @@ - -

- <%= (plan.template.org.abbreviation.present? ? plan.template.org.abbreviation : plan.template.org.name) %> - <% if annotation.example_answer? %> - <%= _('Example Answer') %> - <% else %> - <%= _('Guidance') %> - <% end %> - -

+
+ +
+ +
+
+ <%= raw annotation.text %> +
+
diff --git a/app/views/guidance_groups/_show.html.erb b/app/views/guidance_groups/_show.html.erb index 263fdd0..aeacc91 100644 --- a/app/views/guidance_groups/_show.html.erb +++ b/app/views/guidance_groups/_show.html.erb @@ -1,8 +1,24 @@ -

- <%= group[:org] %> guidance on <%= theme %> - -

+
+ +
+ +
+
+ <%= raw group[:text] %> +
+
diff --git a/app/views/layouts/_es5_scripts.html.erb b/app/views/layouts/_es5_scripts.html.erb index 6a59ea3..f293a65 100644 --- a/app/views/layouts/_es5_scripts.html.erb +++ b/app/views/layouts/_es5_scripts.html.erb @@ -39,7 +39,6 @@ <%= javascript_include_tag 'views/notes/show.js' %> <%= javascript_include_tag 'views/orgs/admin_edit.js' %> <%= javascript_include_tag 'views/orgs/shibboleth_ds.js' %> - <%= javascript_include_tag 'views/phases/edit.js' %> <%= javascript_include_tag 'views/plans/available_templates.js' %> <%= javascript_include_tag 'views/plans/export_configure.js' %> <%= javascript_include_tag 'views/plans/index.js' %> diff --git a/app/views/phases/_guidance_section.html.erb b/app/views/phases/_guidance_section.html.erb index eb3e18f..837f1d4 100644 --- a/app/views/phases/_guidance_section.html.erb +++ b/app/views/phases/_guidance_section.html.erb @@ -30,20 +30,22 @@ class="tab-panel<%= active_tab == 'guidance_tab' ? ' active' : '' %>" aria-hidden="false" aria-labelledby="guidance_tab"> -
- expand all - | - collapse all +
+ <%= _('expand all') %> + | + <%= _('collapse all') %>
-
+
+ <% num_annotations = 0 %> <% i = 0 %> <% if annotations.present? %> <% annotations.each do |annotation| %> - <%= render partial: 'annotations/show', locals: {plan: plan, annotation: annotation} %> + <%= render partial: 'annotations/show', locals: {plan: plan, annotation: annotation, question: question} %> <% num_annotations += 1%> <% i += 1 %> <% end %> @@ -62,9 +64,9 @@ <% i += 1 %> <% end %> <% end %> -
+
-
+
-
- expand all - | - collapse all + +
<%= render :partial => "/plans/progress", locals: { plan: @plan } %>
- -
+ +
<% @phase.sections.order(:number).each do |section| %> <% sectionid = section.id %> -

-
- <%= section.title %> - -
- <%= render :partial => "/sections/progress", locals: { section: section, plan: @plan } %> +
+ +
+ +
+
+ +
<%= raw section.description %>
+ + -
-

+ -
- -
<%= raw section.description %>
+ +
+ <% section.questions.each do |question| %> + <% if question.id == session[:question_id_comments].to_i then id_css = "current_question" end %> +
- - - - -
- <% section.questions.each do |question| %> - <% if question.id == session[:question_id_comments].to_i then id_css = "current_question" end %> -
- - <% - # Load the answer or create a new one - answers = question.plan_answers(@plan.id) - if answers.present? - answer = answers.first - else - answer = Answer.new({plan_id: @plan.id, - question_id: question.id, - user_id: current_user.id }) - if question.default_value.present? - answer.text = question.default_value + <% + # Load the answer or create a new one + answers = question.plan_answers(@plan.id) + if answers.present? + answer = answers.first + else + answer = Answer.new({plan_id: @plan.id, + question_id: question.id, + user_id: current_user.id }) + if question.default_value.present? + answer.text = question.default_value + end end - end - %> + %> - -
-
-
" class="answer-locking">
-
"> - <%= render(partial: 'answers/new_edit', - locals: { question: question, answer: answer, readonly: @readonly }) %> -
-
-
+ +
+
+
" class="answer-locking">
+
"> + <%= render(partial: 'answers/new_edit', + locals: { question: question, answer: answer, readonly: @readonly }) %> +
+
+
- -
- <%= render partial: 'guidance_section', - locals: {plan: @plan, question: question, answer: answer, - question_guidances: @question_guidances} %> -
-
- <% end %> + +
+ <%= render partial: 'guidance_section', + locals: {plan: @plan, question: question, answer: answer, + question_guidances: @question_guidances} %> +
+
+ <% end %> -
+
-
+
+
<% end %> -
+
+