diff --git a/app/views/branded/phases/_guidances_notes.html.erb b/app/views/branded/phases/_guidances_notes.html.erb index e5cac31..a564285 100644 --- a/app/views/branded/phases/_guidances_notes.html.erb +++ b/app/views/branded/phases/_guidances_notes.html.erb @@ -1,5 +1,5 @@ <%# locals: { plan, template, question, answer, question_guidance, guidance_groups } %> -<% annotations = question.annotations.where(type: Annotation.types[:guidance]) %> +<% annotations = question.annotations.where(type: Annotation.types[:guidance]).where.not(text: [nil, ""]) %> <% guidance_set = question_guidance[question.id] || {} %> <% guidances_active = (annotations.present? || guidance_set.length > 0) %>
diff --git a/lib/assets/javascripts/views/org_admin/phases/new_edit.js b/lib/assets/javascripts/views/org_admin/phases/new_edit.js index f638690..92e3024 100644 --- a/lib/assets/javascripts/views/org_admin/phases/new_edit.js +++ b/lib/assets/javascripts/views/org_admin/phases/new_edit.js @@ -22,7 +22,10 @@ // For some reason the toolbar options are retained after the call to Tinymce.init() on // the views/notifications/edit.js file. Tried 'Object.assign' instead of '$.extend' but it // made no difference - Tinymce.init({ selector: `#${context} .question`, toolbar: 'bold italic | bullist numlist | link | table' }); + Tinymce.init({ + selector: `#${context} .question`, + forced_root_block: '', + toolbar: 'bold italic | bullist numlist | link | table' }); ariatiseForm({ selector: `#${context} .question_form` }); initQuestionOption(context); // Swap in the question_formats when the user selects an option based question type