@ministryofjustice/hmpps-mpop-frontend-components-lib 0.0.10 → 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
{% if params.currentYear.appointments.allowance is defined and params.currentYear.appointments.completed is defined and (params.currentYear.appointments.completed | int) >= (params.currentYear.appointments.allowance | int) and not params.inputs.offenderPersonalDisorderPathway %}
|
|
1
|
+
{% if params.currentYear.appointments.allowance is defined and params.currentYear.appointments.completed is defined and (params.currentYear.appointments.allowance | int) > 0 and (params.currentYear.appointments.completed | int) >= (params.currentYear.appointments.allowance | int) and not params.inputs.offenderPersonalDisorderPathway %}
|
|
2
2
|
<strong class='app-status-badge govuk-tag govuk-tag--red'>No appointments remaining</strong>
|
|
3
3
|
{% endif %}
|
|
4
4
|
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
{% set standardAppointmentsComplete = params.currentYear.appointments.allowance is defined and params.currentYear.appointments.completed is defined and (params.currentYear.appointments.completed | int) >= (params.currentYear.appointments.allowance| int) %}
|
|
3
3
|
{% set hasSpecialStatus = params.inputs.offenderPersonalDisorderPathway or params.inputs.sentences | hasBreachedSentence or params.inputs.sentences | isInCustody or params.inputs.sentences | isAtLarge or params.inputs.integratedOffenderManagementRedRated %}
|
|
4
4
|
{% set sentenceTypeValue = params.inputs | sentenceType %}
|
|
5
|
+
{% set showPhaseColumn = params.inputs.offenderPersonalDisorderPathway or params.inputs.sentences | isAtLarge or params.inputs.sentences | isInCustody or params.inputs.liferCategory.code == 'LF01' or params.inputs.liferCategory.code == 'LF02' or params.inputs.liferCategory.code == 'LF03' or params.inputs.liferCategory.code == 'x9' or params.phase.name.code == 'INIT' or params.phase.name.code == 'STD' %}
|
|
5
6
|
|
|
6
7
|
{% if
|
|
7
8
|
params.inputs.nationalSecurityDivision
|
|
@@ -25,7 +26,7 @@
|
|
|
25
26
|
{% endif %}
|
|
26
27
|
|
|
27
28
|
<div class='govuk-grid-row'>
|
|
28
|
-
<div class='{{ "govuk-grid-column-one-half" if
|
|
29
|
+
<div class='{{ "govuk-grid-column-one-half" if showPhaseColumn else "govuk-grid-column-two-thirds" }}'>
|
|
29
30
|
{% if params.inputs.sentences | hasBreachedSentence %}
|
|
30
31
|
<div class='govuk-warning-text'>
|
|
31
32
|
<span class='govuk-warning-text__icon' aria-hidden='true'>!</span>
|
|
@@ -94,7 +95,7 @@
|
|
|
94
95
|
{% endif %}
|
|
95
96
|
</div>
|
|
96
97
|
|
|
97
|
-
{% if
|
|
98
|
+
{% if showPhaseColumn %}
|
|
98
99
|
<div class='govuk-grid-column-one-half'>
|
|
99
100
|
{% if params.inputs.offenderPersonalDisorderPathway %}
|
|
100
101
|
<h3 class='govuk-heading-s'>Supervision appointments</h3>
|
|
@@ -111,8 +112,6 @@
|
|
|
111
112
|
{% elseif params.phase.name.code == 'STD' %}
|
|
112
113
|
<h3 class='govuk-heading-s'>{{ params.phase.name.description | toTitleCase }} stage</h3>
|
|
113
114
|
{% include './partials/_standard-supervision.njk' %}
|
|
114
|
-
{% else %}
|
|
115
|
-
<h3 class='govuk-heading-s'>{{ params.phase.name.description | toTitleCase }}</h3>
|
|
116
115
|
{% endif %}
|
|
117
116
|
|
|
118
117
|
{% if params.allAppointmentsHref %}
|