+ {% for error in form.first_name.errors %}
+ {{ error }}
+ {% endfor %}
+
+ {% endif %}
- {% endif %}
-
-
-
-
-
-
- {{form.date_of_birth}}
- {% if form.date_of_birth.errors %}
+
+
+
{{form.surname}}
+ {% if form.surname.errors %}
- {% for error in form.date_of_birth.errors %}
+ {% for error in form.surname.errors %}
{{ error }}
{% endfor %}
- {% endif %}
-
-
-
-
- {{form.sex}}
- {% if form.sex.errors %}
-
- {% for error in form.sex.errors %}
- {{ error }}
- {% endfor %}
-
- {% endif %}
+ {% endif %}
+
-
-
-
-
-
-
- {{form.postcode}}
- {% if form.postcode.errors %}
+
+
+
+
+ {{form.date_of_birth}}
+ {% if form.date_of_birth.errors %}
- {% for error in form.postcode.errors %}
+ {% for error in form.date_of_birth.errors %}
{{ error }}
{% endfor %}
{% endif %}
-
- {% include 'epilepsy12/cases/postcode_options.html' with choices=choices test_positive=test_positive child_has_unknown_postcode=child_has_unknown_postcode %}
+
+
+ {{form.sex}}
+ {% if form.sex.errors %}
+
+ {% for error in form.sex.errors %}
+ {{ error }}
+ {% endfor %}
+
+ {% endif %}
+
-
+
- {% if organisation.country.boundary_identifier == "JEY" %}
-
-
- {{form.unique_reference_number}}
-
- {% for error in form.unique_reference_number.errors %}
- {{ error }}
- {% endfor %}
-
-
- {% else %}
-
-
- {{form.nhs_number}}
- {% if form.nhs_number.errors %}
-
- {% for error in form.nhs_number.errors %}
- {{ error }}
- {% endfor %}
+
+
+ {{form.postcode}}
+ {% if form.postcode.errors %}
+
+ {% for error in form.postcode.errors %}
+ {{ error }}
+ {% endfor %}
+
+ {% endif %}
+
+
+
+ {% include 'epilepsy12/cases/postcode_options.html' with choices=choices test_positive=test_positive child_has_unknown_postcode=child_has_unknown_postcode %}
- {% endif %}
+
- {% endif %}
-
-
- {{form.ethnicity}}
- {% if form.ethnicity.errors %}
-
- {% for error in form.ethnicity.errors %}
+ {% if organisation.country.boundary_identifier == "JEY" %}
+
+
+ {{form.unique_reference_number}}
+
+ {% for error in form.unique_reference_number.errors %}
+ {{ error }}
+ {% endfor %}
+
+
+ {% else %}
+
+
+ {{form.nhs_number}}
+ {% if form.nhs_number.errors %}
+
+ {% for error in form.nhs_number.errors %}
{{ error }}
{% endfor %}
+
+ {% endif %}
{% endif %}
-
-
- {% if case and perms.epilepsy.can_opt_out_child_from_inclusion_in_audit %}
-
-
-
- Children, young people and their families can opt out of Epilepsy12 at any
- time. Should {{case}} or their family choose to do so, all records
- relating to {{case}}'s epilepsy care will be removed from RCPCH servers.
-
-
-
+
+ {{form.ethnicity}}
+ {% if form.ethnicity.errors %}
+
+ {% for error in form.ethnicity.errors %}
+ {{ error }}
+ {% endfor %}
+
+ {% endif %}
- {% else %}
-
-
-
-
-
-
Organisation
-
- {% if organisation.trust %}
- {{organisation.name}}({{organisation.trust.name}})
- {% else %}
- {{organisation.name}}({{organisation.local_health_board.name}})
- {% endif %}
-
- will be allocated automatically as the lead Epilepsy12 centre on saving
- this child's information.
-
+ {% if case and perms.epilepsy.can_opt_out_child_from_inclusion_in_audit %}
+
+
+
+
+
+ Children, young people and their families can opt out of Epilepsy12 at any
+ time. Should {{case}} or their family choose to do so, all records
+ relating to {{case}}'s epilepsy care will be removed from RCPCH servers.
+
+
+
+
+
+ {% else %}
+
+
+
+
+
+
Organisation
+
+ {% if organisation.trust %}
+ {{organisation.name}}({{organisation.trust.name}})
+ {% else %}
+ {{organisation.name}}({{organisation.local_health_board.name}})
+ {% endif %}
+
+ will be allocated automatically as the lead Epilepsy12 centre on saving
+ this child's information.
+
diff --git a/templates/epilepsy12/partials/epilepsy_context/epilepsy_diagnosis_withdrawn.html b/templates/epilepsy12/partials/epilepsy_context/epilepsy_diagnosis_withdrawn.html
index b00a5689a..6b067158c 100644
--- a/templates/epilepsy12/partials/epilepsy_context/epilepsy_diagnosis_withdrawn.html
+++ b/templates/epilepsy12/partials/epilepsy_context/epilepsy_diagnosis_withdrawn.html
@@ -1,2 +1,2 @@
{% url 'diagnosis_of_epilepsy_withdrawn' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#diagnosis_of_epilepsy_withdrawn" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.diagnosis_of_epilepsy_withdrawn tooltip_id='diagnosis_of_epilepsy_withdrawn_tooltip' label=epilepsy_context.get_diagnosis_of_epilepsy_withdrawn_help_label_text reference=epilepsy_context.get_diagnosis_of_epilepsy_withdrawn_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#diagnosis_of_epilepsy_withdrawn" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.diagnosis_of_epilepsy_withdrawn tooltip_id='diagnosis_of_epilepsy_withdrawn_tooltip' label=epilepsy_context.get_diagnosis_of_epilepsy_withdrawn_help_label_text reference=epilepsy_context.get_diagnosis_of_epilepsy_withdrawn_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_focal_seizures.html b/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_focal_seizures.html
index d14e61847..9b6b5b5c9 100644
--- a/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_focal_seizures.html
+++ b/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_focal_seizures.html
@@ -1,2 +1,2 @@
{% url 'experienced_prolonged_focal_seizures' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#experienced_prolonged_focal_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.experienced_prolonged_focal_seizures tooltip_id='experienced_prolonged_focal_seizures_tooltip' label=epilepsy_context.get_experienced_prolonged_focal_seizures_help_label_text reference=epilepsy_context.get_experienced_prolonged_focal_seizures_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#experienced_prolonged_focal_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.experienced_prolonged_focal_seizures tooltip_id='experienced_prolonged_focal_seizures_tooltip' label=epilepsy_context.get_experienced_prolonged_focal_seizures_help_label_text reference=epilepsy_context.get_experienced_prolonged_focal_seizures_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_generalized_convulsive_seizures.html b/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_generalized_convulsive_seizures.html
index 59e65d32e..cc12ea3f1 100644
--- a/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_generalized_convulsive_seizures.html
+++ b/templates/epilepsy12/partials/epilepsy_context/experienced_prolonged_generalized_convulsive_seizures.html
@@ -1,2 +1,2 @@
{% url 'experienced_prolonged_generalized_convulsive_seizures' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#experienced_prolonged_generalized_convulsive_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.experienced_prolonged_generalized_convulsive_seizures tooltip_id='experienced_prolonged_generalized_convulsive_seizures_tooltip' label=epilepsy_context.get_experienced_prolonged_generalized_convulsive_seizures_help_label_text reference=epilepsy_context.get_experienced_prolonged_generalized_convulsive_seizures_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#experienced_prolonged_generalized_convulsive_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.experienced_prolonged_generalized_convulsive_seizures tooltip_id='experienced_prolonged_generalized_convulsive_seizures_tooltip' label=epilepsy_context.get_experienced_prolonged_generalized_convulsive_seizures_help_label_text reference=epilepsy_context.get_experienced_prolonged_generalized_convulsive_seizures_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/is_there_a_family_history_of_epilepsy.html b/templates/epilepsy12/partials/epilepsy_context/is_there_a_family_history_of_epilepsy.html
index f85e196ec..a58a12481 100644
--- a/templates/epilepsy12/partials/epilepsy_context/is_there_a_family_history_of_epilepsy.html
+++ b/templates/epilepsy12/partials/epilepsy_context/is_there_a_family_history_of_epilepsy.html
@@ -1,2 +1,2 @@
{% url 'is_there_a_family_history_of_epilepsy' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#is_there_a_family_history_of_epilepsy" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.is_there_a_family_history_of_epilepsy tooltip_id='is_there_a_family_history_of_epilepsy_tooltip' label=epilepsy_context.get_is_there_a_family_history_of_epilepsy_help_label_text reference=epilepsy_context.get_is_there_a_family_history_of_epilepsy_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#is_there_a_family_history_of_epilepsy" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.is_there_a_family_history_of_epilepsy tooltip_id='is_there_a_family_history_of_epilepsy_tooltip' label=epilepsy_context.get_is_there_a_family_history_of_epilepsy_help_label_text reference=epilepsy_context.get_is_there_a_family_history_of_epilepsy_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/previous_acute_symptomatic_seizure.html b/templates/epilepsy12/partials/epilepsy_context/previous_acute_symptomatic_seizure.html
index 87798bc02..86d0be194 100644
--- a/templates/epilepsy12/partials/epilepsy_context/previous_acute_symptomatic_seizure.html
+++ b/templates/epilepsy12/partials/epilepsy_context/previous_acute_symptomatic_seizure.html
@@ -1,2 +1,2 @@
{% url 'previous_acute_symptomatic_seizure' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_acute_symptomatic_seizure" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_acute_symptomatic_seizure tooltip_id='previous_acute_symptomatic_seizure_tooltip' label=epilepsy_context.get_previous_acute_symptomatic_seizure_help_label_text reference=epilepsy_context.get_previous_acute_symptomatic_seizure_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_acute_symptomatic_seizure" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_acute_symptomatic_seizure tooltip_id='previous_acute_symptomatic_seizure_tooltip' label=epilepsy_context.get_previous_acute_symptomatic_seizure_help_label_text reference=epilepsy_context.get_previous_acute_symptomatic_seizure_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/previous_febrile_seizure.html b/templates/epilepsy12/partials/epilepsy_context/previous_febrile_seizure.html
index 4312483ae..5f6fc922a 100644
--- a/templates/epilepsy12/partials/epilepsy_context/previous_febrile_seizure.html
+++ b/templates/epilepsy12/partials/epilepsy_context/previous_febrile_seizure.html
@@ -1,2 +1,2 @@
{% url 'previous_febrile_seizure' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_febrile_seizure" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_febrile_seizure tooltip_id='previous_febrile_seizure_tooltip' label=epilepsy_context.get_previous_febrile_seizure_help_label_text reference=epilepsy_context.get_previous_febrile_seizure_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_febrile_seizure" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_febrile_seizure tooltip_id='previous_febrile_seizure_tooltip' label=epilepsy_context.get_previous_febrile_seizure_help_label_text reference=epilepsy_context.get_previous_febrile_seizure_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/previous_neonatal_seizures.html b/templates/epilepsy12/partials/epilepsy_context/previous_neonatal_seizures.html
index a5b6d7576..08569552f 100644
--- a/templates/epilepsy12/partials/epilepsy_context/previous_neonatal_seizures.html
+++ b/templates/epilepsy12/partials/epilepsy_context/previous_neonatal_seizures.html
@@ -1,2 +1,2 @@
{% url 'previous_neonatal_seizures' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_neonatal_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_neonatal_seizures tooltip_id='previous_neonatal_seizures_tooltip' label=epilepsy_context.get_previous_neonatal_seizures_help_label_text reference=epilepsy_context.get_previous_neonatal_seizures_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with choices=uncertain_choices hx_post=hx_post hx_target="#previous_neonatal_seizures" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.previous_neonatal_seizures tooltip_id='previous_neonatal_seizures_tooltip' label=epilepsy_context.get_previous_neonatal_seizures_help_label_text reference=epilepsy_context.get_previous_neonatal_seizures_help_reference_text data_position='top left' %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/epilepsy_context/were_any_of_the_epileptic_seizures_convulsive.html b/templates/epilepsy12/partials/epilepsy_context/were_any_of_the_epileptic_seizures_convulsive.html
index df7067f9c..c9a7850a2 100644
--- a/templates/epilepsy12/partials/epilepsy_context/were_any_of_the_epileptic_seizures_convulsive.html
+++ b/templates/epilepsy12/partials/epilepsy_context/were_any_of_the_epileptic_seizures_convulsive.html
@@ -1,2 +1,2 @@
{% url 'were_any_of_the_epileptic_seizures_convulsive' epilepsy_context_id=epilepsy_context.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#were_any_of_the_epileptic_seizures_convulsive" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.were_any_of_the_epileptic_seizures_convulsive tooltip_id='were_any_of_the_epileptic_seizures_convulsive_tooltip' label=epilepsy_context.get_were_any_of_the_epileptic_seizures_convulsive_help_label_text reference=epilepsy_context.get_were_any_of_the_epileptic_seizures_convulsive_help_reference_text data_position="top left" enabled=perms.epilepsy12.change_epilepsycontext %}
\ No newline at end of file
+{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#were_any_of_the_epileptic_seizures_convulsive" hx_trigger="click" hx_swap="innerHTML" test_positive=epilepsy_context.were_any_of_the_epileptic_seizures_convulsive tooltip_id='were_any_of_the_epileptic_seizures_convulsive_tooltip' label=epilepsy_context.get_were_any_of_the_epileptic_seizures_convulsive_help_label_text reference=epilepsy_context.get_were_any_of_the_epileptic_seizures_convulsive_help_reference_text data_position="top left" %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/first_paediatric_assessment/first_paediatric_assessment_in_acute_or_nonacute_setting.html b/templates/epilepsy12/partials/first_paediatric_assessment/first_paediatric_assessment_in_acute_or_nonacute_setting.html
index aead0291c..c87cb5e84 100644
--- a/templates/epilepsy12/partials/first_paediatric_assessment/first_paediatric_assessment_in_acute_or_nonacute_setting.html
+++ b/templates/epilepsy12/partials/first_paediatric_assessment/first_paediatric_assessment_in_acute_or_nonacute_setting.html
@@ -1,4 +1,4 @@
{% url 'first_paediatric_assessment_in_acute_or_nonacute_setting' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target='#first_paediatric_assessment_in_acute_or_nonacute_setting' hx_trigger="click" tooltip_id='first_paediatric_assessment_in_acute_or_nonacute_setting_tooltip' label=first_paediatric_assessment.get_first_paediatric_assessment_in_acute_or_nonacute_setting_help_label_text reference=first_paediatric_assessment.get_first_paediatric_assessment_in_acute_or_nonacute_setting_help_reference_text test_positive=first_paediatric_assessment.first_paediatric_assessment_in_acute_or_nonacute_setting data_position="top left" choices=chronicity_selection enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target='#first_paediatric_assessment_in_acute_or_nonacute_setting' hx_trigger="click" tooltip_id='first_paediatric_assessment_in_acute_or_nonacute_setting_tooltip' label=first_paediatric_assessment.get_first_paediatric_assessment_in_acute_or_nonacute_setting_help_label_text reference=first_paediatric_assessment.get_first_paediatric_assessment_in_acute_or_nonacute_setting_help_reference_text test_positive=first_paediatric_assessment.first_paediatric_assessment_in_acute_or_nonacute_setting data_position="top left" choices=chronicity_selection %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/first_paediatric_assessment/when_the_first_epileptic_episode_occurred.html b/templates/epilepsy12/partials/first_paediatric_assessment/when_the_first_epileptic_episode_occurred.html
index 038ce899a..cda87b775 100644
--- a/templates/epilepsy12/partials/first_paediatric_assessment/when_the_first_epileptic_episode_occurred.html
+++ b/templates/epilepsy12/partials/first_paediatric_assessment/when_the_first_epileptic_episode_occurred.html
@@ -19,20 +19,20 @@
{% url 'general_examination_performed' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.general_examination_performed tooltip_id='general_examination_performed' label=first_paediatric_assessment.get_general_examination_performed_help_label_text reference=first_paediatric_assessment.get_general_examination_performed_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.general_examination_performed tooltip_id='general_examination_performed' label=first_paediatric_assessment.get_general_examination_performed_help_label_text reference=first_paediatric_assessment.get_general_examination_performed_help_reference_text data_position='top left' %}
{% url 'developmental_learning_or_schooling_problems' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.developmental_learning_or_schooling_problems tooltip_id='developmental_learning_or_schooling_problems' label=first_paediatric_assessment.get_developmental_learning_or_schooling_problems_help_label_text reference=first_paediatric_assessment.get_developmental_learning_or_schooling_problems_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.developmental_learning_or_schooling_problems tooltip_id='developmental_learning_or_schooling_problems' label=first_paediatric_assessment.get_developmental_learning_or_schooling_problems_help_label_text reference=first_paediatric_assessment.get_developmental_learning_or_schooling_problems_help_reference_text data_position='top left' %}
{% url 'behavioural_or_emotional_problems' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.behavioural_or_emotional_problems tooltip_id='behavioural_or_emotional_problems' label=first_paediatric_assessment.get_behavioural_or_emotional_problems_help_label_text reference=first_paediatric_assessment.get_behavioural_or_emotional_problems_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.behavioural_or_emotional_problems tooltip_id='behavioural_or_emotional_problems' label=first_paediatric_assessment.get_behavioural_or_emotional_problems_help_label_text reference=first_paediatric_assessment.get_behavioural_or_emotional_problems_help_reference_text data_position='top left' %}
{% url 'has_number_of_episodes_since_the_first_been_documented' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.has_number_of_episodes_since_the_first_been_documented tooltip_id='has_number_of_episodes_since_the_first_been_documented' label=first_paediatric_assessment.get_has_number_of_episodes_since_the_first_been_documented_help_label_text reference=first_paediatric_assessment.get_has_number_of_episodes_since_the_first_been_documented_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.has_number_of_episodes_since_the_first_been_documented tooltip_id='has_number_of_episodes_since_the_first_been_documented' label=first_paediatric_assessment.get_has_number_of_episodes_since_the_first_been_documented_help_label_text reference=first_paediatric_assessment.get_has_number_of_episodes_since_the_first_been_documented_help_reference_text data_position='top left' %}
{% url 'neurological_examination_performed' first_paediatric_assessment_id=first_paediatric_assessment.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.neurological_examination_performed tooltip_id='neurological_examination_performed' label=first_paediatric_assessment.get_neurological_examination_performed_help_label_text reference=first_paediatric_assessment.get_neurological_examination_performed_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_firstpaediatricassessment %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#when_the_first_epileptic_episode_occurred' hx_trigger='click' hx_swap='innerHTML' test_positive=first_paediatric_assessment.neurological_examination_performed tooltip_id='neurological_examination_performed' label=first_paediatric_assessment.get_neurological_examination_performed_help_label_text reference=first_paediatric_assessment.get_neurological_examination_performed_help_reference_text data_position='top left' %}
- {% if not perms.epilepsy12.add_antiepilepsymedicine or not perms.epilepsy12.change_antiepilepsymedicine or not perms.epilepsy12.delete_aantiepilepsymedicine %}
- {% permission_text perms.epilepsy12.add_antiepilepsymedicine perms.epilepsy12.change_antiepilepsymedicine perms.epilepsy12.delete_antiepilepsymedicine 'antiepilepsy/seizure medicines' %}
+ {% if not can_add_antiepilepsymedicine or not can_change_antiepilepsymedicine or not can_delete_antiepilepsymedicine %}
+ {% permission_text can_add_antiepilepsymedicine can_change_antiepilepsymedicine can_delete_antiepilepsymedicine 'antiepilepsy/seizure medicines' %}
{% endif %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/management/antiepilepsy_medicines/antiepilepsy_medicines.html b/templates/epilepsy12/partials/management/antiepilepsy_medicines/antiepilepsy_medicines.html
index 64aea3743..649645429 100644
--- a/templates/epilepsy12/partials/management/antiepilepsy_medicines/antiepilepsy_medicines.html
+++ b/templates/epilepsy12/partials/management/antiepilepsy_medicines/antiepilepsy_medicines.html
@@ -2,7 +2,7 @@
{% url 'has_an_aed_been_given' management_id=management.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with test_positive=management.has_an_aed_been_given hx_post=hx_post hx_swap="innerHTML" hx_target="#aeds" hx_trigger="click" tooltip_id='has_an_aed_been_given_tooltip' label=management.get_has_an_aed_been_given_help_label_text reference=management.get_has_an_aed_been_given_help_reference_text enabled=perms.epilepsy12.change_management %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with test_positive=management.has_an_aed_been_given hx_post=hx_post hx_swap="innerHTML" hx_target="#aeds" hx_trigger="click" tooltip_id='has_an_aed_been_given_tooltip' label=management.get_has_an_aed_been_given_help_label_text reference=management.get_has_an_aed_been_given_help_reference_text enabled=can_change_management %}
{% if management.has_an_aed_been_given %}
-{% if not perms.epilepsy12.add_comorbidity or not perms.epilepsy12.change_comorbidity or not perms.epilepsy12.delete_comorbidity %}
+{% if not can_change_comorbidity or not perms.epilepsy12.add_comorbidity or not perms.epilepsy12.change_comorbidity or not perms.epilepsy12.delete_comorbidity %}
{% permission_text perms.epilepsy12.add_comorbidity perms.epilepsy12.change_comorbidity perms.epilepsy12.delete_comorbidity 'comorbidities' %}
{% endif %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/comorbidities/comorbidity_section.html b/templates/epilepsy12/partials/multiaxial_diagnosis/comorbidities/comorbidity_section.html
index 94c6f8bb1..c43ca852b 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/comorbidities/comorbidity_section.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/comorbidities/comorbidity_section.html
@@ -2,7 +2,7 @@
{% csrf_token %}
{% url 'relevant_impairments_behavioural_educational' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#comorbidity_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.relevant_impairments_behavioural_educational tooltip_id='relevant_impairments_behavioural_educational_tooltip' label=multiaxial_diagnosis.get_relevant_impairments_behavioural_educational_help_label_text reference=multiaxial_diagnosis.get_relevant_impairments_behavioural_educational_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_comorbidity %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#comorbidity_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.relevant_impairments_behavioural_educational tooltip_id='relevant_impairments_behavioural_educational_tooltip' label=multiaxial_diagnosis.get_relevant_impairments_behavioural_educational_help_label_text reference=multiaxial_diagnosis.get_relevant_impairments_behavioural_educational_help_reference_text data_position='top left' enabled=can_change_comorbidity %}
{% if multiaxial_diagnosis.relevant_impairments_behavioural_educational %}
{% url 'epilepsy_cause_categories' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/multiple_choice_multiple_toggle_button.html' with choices=epilepsy_cause_selection hx_post=hx_post hx_target="#epilepsy_cause_categories" hx_trigger="click" hx_swap="innerHTML" test_positive=multiaxial_diagnosis.epilepsy_cause_categories tooltip_id='epilepsy_cause_categories_tooltip' label=multiaxial_diagnosis.get_epilepsy_cause_categories_help_label_text reference=multiaxial_diagnosis.get_epilepsy_cause_categories_help_reference_text data_position="top left" enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/multiple_choice_multiple_toggle_button.html' with choices=epilepsy_cause_selection hx_post=hx_post hx_target="#epilepsy_cause_categories" hx_trigger="click" hx_swap="innerHTML" test_positive=multiaxial_diagnosis.epilepsy_cause_categories tooltip_id='epilepsy_cause_categories_tooltip' label=multiaxial_diagnosis.get_epilepsy_cause_categories_help_label_text reference=multiaxial_diagnosis.get_epilepsy_cause_categories_help_reference_text data_position="top left" enabled=can_change_multiaxialdiagnosis %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/epilepsy_causes/epilepsy_cause_section.html b/templates/epilepsy12/partials/multiaxial_diagnosis/epilepsy_causes/epilepsy_cause_section.html
index 5bb49792b..95fb468d2 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/epilepsy_causes/epilepsy_cause_section.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/epilepsy_causes/epilepsy_cause_section.html
@@ -2,7 +2,7 @@
{% csrf_token %}
{% url 'epilepsy_cause_known' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#epilepsy_cause_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.epilepsy_cause_known tooltip_id='epilepsy_cause_known_tooltip' label=multiaxial_diagnosis.get_epilepsy_cause_known_help_label_text reference=multiaxial_diagnosis.get_epilepsy_cause_known_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#epilepsy_cause_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.epilepsy_cause_known tooltip_id='epilepsy_cause_known_tooltip' label=multiaxial_diagnosis.get_epilepsy_cause_known_help_label_text reference=multiaxial_diagnosis.get_epilepsy_cause_known_help_reference_text data_position='top left' enabled=can_change_multiaxialdiagnosis %}
{% include 'epilepsy12/partials/multiaxial_diagnosis/epilepsy_causes/epilepsy_cause_categories.html' with choices=epilepsy_cause_selection multiaxial_diagnosis=multiaxial_diagnosis %}
-
+
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/episodes.html b/templates/epilepsy12/partials/multiaxial_diagnosis/episodes.html
index ab5af56a0..4a8c2f820 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/episodes.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/episodes.html
@@ -72,7 +72,7 @@
{% endif %}
{% url 'global_developmental_delay_or_learning_difficulties' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#global_developmental_delay_or_learning_difficulties_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.global_developmental_delay_or_learning_difficulties tooltip_id='global_developmental_delay_or_learning_difficulties_tooltip' label=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_help_label_text reference=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#global_developmental_delay_or_learning_difficulties_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.global_developmental_delay_or_learning_difficulties tooltip_id='global_developmental_delay_or_learning_difficulties_tooltip' label=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_help_label_text reference=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_help_reference_text data_position='top left' enabled=can_change_multiaxial_diagnosis %}
{% if multiaxial_diagnosis.global_developmental_delay_or_learning_difficulties %}
{% url 'global_developmental_delay_or_learning_difficulties_severity' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target="#global_developmental_delay_or_learning_difficulties_section" hx_trigger="click" hx_swap="innerHTML" choices=global_developmental_delay_or_learning_difficulties_severity_choices test_positive=multiaxial_diagnosis.global_developmental_delay_or_learning_difficulties_severity tooltip_id='global_developmental_delay_or_learning_difficulties_severity_tooltip' label=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_severity_help_label_text reference=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_severity_help_reference_text hx_default_text='Select severity' hx_name='global_developmental_delay_or_learning_difficulties_severity' data_position="top left" enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/single_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target="#global_developmental_delay_or_learning_difficulties_section" hx_trigger="click" hx_swap="innerHTML" choices=global_developmental_delay_or_learning_difficulties_severity_choices test_positive=multiaxial_diagnosis.global_developmental_delay_or_learning_difficulties_severity tooltip_id='global_developmental_delay_or_learning_difficulties_severity_tooltip' label=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_severity_help_label_text reference=multiaxial_diagnosis.get_global_developmental_delay_or_learning_difficulties_severity_help_reference_text hx_default_text='Select severity' hx_name='global_developmental_delay_or_learning_difficulties_severity' data_position="top left" enabled=can_change_multiaxial_diagnosis %}
{% endif %}
\ No newline at end of file
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/mental_health_section.html b/templates/epilepsy12/partials/multiaxial_diagnosis/mental_health_section.html
index 2b00e2fc4..620bcd538 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/mental_health_section.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/mental_health_section.html
@@ -1,6 +1,6 @@
{% url 'autistic_spectrum_disorder' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.autistic_spectrum_disorder tooltip_id='autistic_spectrum_disorder_tooltip' label=multiaxial_diagnosis.get_autistic_spectrum_disorder_help_label_text reference=multiaxial_diagnosis.get_autistic_spectrum_disorder_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.autistic_spectrum_disorder tooltip_id='autistic_spectrum_disorder_tooltip' label=multiaxial_diagnosis.get_autistic_spectrum_disorder_help_label_text reference=multiaxial_diagnosis.get_autistic_spectrum_disorder_help_reference_text data_position='top left' enabled=can_change_multiaxial_diagnosis %}
@@ -9,13 +9,13 @@
{% url 'mental_health_screen' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.mental_health_screen tooltip_id='mental_health_screen_tooltip' label=multiaxial_diagnosis.get_mental_health_screen_help_label_text reference=multiaxial_diagnosis.get_mental_health_screen_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.mental_health_screen tooltip_id='mental_health_screen_tooltip' label=multiaxial_diagnosis.get_mental_health_screen_help_label_text reference=multiaxial_diagnosis.get_mental_health_screen_help_reference_text data_position='top left' enabled=can_change_multiaxial_diagnosis %}
{% url 'mental_health_issue_identified' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.mental_health_issue_identified tooltip_id='mental_health_issue_identified_tooltip' label=multiaxial_diagnosis.get_mental_health_issue_identified_help_label_text reference=multiaxial_diagnosis.get_mental_health_issue_identified_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target='#mental_health_section' hx_trigger='click' hx_swap='innerHTML' test_positive=multiaxial_diagnosis.mental_health_issue_identified tooltip_id='mental_health_issue_identified_tooltip' label=multiaxial_diagnosis.get_mental_health_issue_identified_help_label_text reference=multiaxial_diagnosis.get_mental_health_issue_identified_help_reference_text data_position='top left' enabled=can_change_multiaxial_diagnosis %}
{% if multiaxial_diagnosis.mental_health_issue_identified %}
{% url 'mental_health_issues' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
- {% include 'epilepsy12/partials/page_elements/multiple_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target="#mental_health_section" hx_trigger="click" hx_swap="innerHTML" choices=mental_health_issues_choices test_positive=multiaxial_diagnosis.mental_health_issues tooltip_id='mental_health_issue_tooltip' label=multiaxial_diagnosis.get_mental_health_issues_help_label_text reference=multiaxial_diagnosis.get_mental_health_issues_help_reference_text hx_default_text='Select mental health issue' hx_name='mental_health_issue' data_position="top left" enabled=perms.epilepsy12.change_multiaxialdiagnosis %}
+ {% include 'epilepsy12/partials/page_elements/multiple_choice_multiple_toggle_button.html' with hx_post=hx_post hx_target="#mental_health_section" hx_trigger="click" hx_swap="innerHTML" choices=mental_health_issues_choices test_positive=multiaxial_diagnosis.mental_health_issues tooltip_id='mental_health_issue_tooltip' label=multiaxial_diagnosis.get_mental_health_issues_help_label_text reference=multiaxial_diagnosis.get_mental_health_issues_help_reference_text hx_default_text='Select mental health issue' hx_name='mental_health_issue' data_position="top left" enabled=can_change_multiaxial_diagnosis %}
{% endif %}
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/syndrome_section.html b/templates/epilepsy12/partials/multiaxial_diagnosis/syndrome_section.html
index f9c5e9b00..a3a8ce635 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/syndrome_section.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/syndrome_section.html
@@ -1,6 +1,6 @@
{% load epilepsy12_template_tags %}
{% url 'syndrome_present' multiaxial_diagnosis_id=multiaxial_diagnosis.pk as hx_post %}
-{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#syndrome_section" hx_trigger='click' hx_swap="innerHTML" test_positive=multiaxial_diagnosis.syndrome_present tooltip_id='syndrome_present_tooltip' label=multiaxial_diagnosis.get_syndrome_present_help_label_text reference=multiaxial_diagnosis.get_syndrome_present_help_reference_text data_position='top left' enabled=perms.epilepsy12.change_syndrome %}
+{% include 'epilepsy12/partials/page_elements/toggle_button.html' with hx_post=hx_post hx_target="#syndrome_section" hx_trigger='click' hx_swap="innerHTML" test_positive=multiaxial_diagnosis.syndrome_present tooltip_id='syndrome_present_tooltip' label=multiaxial_diagnosis.get_syndrome_present_help_label_text reference=multiaxial_diagnosis.get_syndrome_present_help_reference_text data_position='top left' enabled=can_change_syndrome %}
{% if multiaxial_diagnosis.syndrome_present %}
diff --git a/templates/epilepsy12/partials/multiaxial_diagnosis/syndromes.html b/templates/epilepsy12/partials/multiaxial_diagnosis/syndromes.html
index bd755b857..d29e5011e 100644
--- a/templates/epilepsy12/partials/multiaxial_diagnosis/syndromes.html
+++ b/templates/epilepsy12/partials/multiaxial_diagnosis/syndromes.html
@@ -40,7 +40,7 @@
{% endif %}
{% for choice in choices %}
{% for choice in choices %}
{% if test_positive == choice.0 %}
>{{choice.1}}
{% else %}
>{{choice}}
{% else %}
{% endif %}
- {% if not enabled %}
+ {% if disabled %}
You do not have permission to update this field
{% endif %}
diff --git a/templates/epilepsy12/partials/page_elements/toggle_button.html b/templates/epilepsy12/partials/page_elements/toggle_button.html
index 61f04c12e..606b49f2f 100644
--- a/templates/epilepsy12/partials/page_elements/toggle_button.html
+++ b/templates/epilepsy12/partials/page_elements/toggle_button.html
@@ -17,7 +17,7 @@
label: this is the label text pulled in from the the model help text
reference: this is the reference text pulled in from the the model help text
data_position: this is the position of the popup label (js independent) ['top left', 'top center', 'top right', 'bottom left', 'bottom center', 'bottom right', 'right center', 'left center']
- enabled: buttons are disabled if users have view-only access
+ disabled: buttons are disabled if the cohort is closed orusers have view-only access
{% endcomment %}
@@ -43,7 +43,7 @@
Yes
Yes
{% endif %} -->
- {% if not enabled %}
+ {% if disabled %}
You do not have permission to update this field
{% endif %}