Skip to content

Commit

Permalink
MAN-21 - add pre-sentence header for pre-sentence events
Browse files Browse the repository at this point in the history
  • Loading branch information
achimber-moj committed Nov 7, 2024
1 parent 7c4a0d0 commit 04c21e3
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 61 deletions.
8 changes: 7 additions & 1 deletion server/views/pages/sentence.njk
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,13 @@
</div>
<div class="govuk-grid-column-three-quarters">
{% set sentence = sentenceDetails.sentence %}
<h2 class="govuk-heading-m govuk-!-margin-bottom-2" data-qa="pageHeading">{{ sentence.order.description }}</h2>

{% if sentence.order.description %}
<h2 class="govuk-heading-m govuk-!-margin-bottom-2" data-qa="pageHeading">{{ sentence.order.description }}</h2>
{% else %}
<h2 class="govuk-heading-m govuk-!-margin-bottom-2" data-qa="pageHeading">Pre-Sentence</h2>
{% endif%}

{% set hasAdditionalOffences = sentence.offenceDetails.additionalOffences and sentence.offenceDetails.additionalOffences.length > 0 %}
{% set additionalOffences %}
{% if hasAdditionalOffences %}
Expand Down
64 changes: 4 additions & 60 deletions wiremock/mappings/X808126-sentence.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"sentenceSummaryList": [
{
"eventNumber": "1",
"description": "Default Sentence Type"
"description": "Pre-Sentence"
}
],
"sentence": {
Expand All @@ -42,67 +42,11 @@
"sentencingCourt": "Hull Court",
"responsibleCourt": "Birmingham Court",
"convictionDate": "2024-03-20",
"additionalSentences": [
{
"length": 3,
"description": "Disqualified from Driving"
}
]
},
"order": {
"description": "Default Sentence Type",
"length": 12,
"endDate": "2025-03-19",
"startDate": "2024-03-19"
"additionalSentences": []
},
"requirements": [],
"courtDocuments": [
{
"id": "4d74f43c-5b42-4317-852e-56c7d29b610b",
"lastSaved": "2024-04-03",
"documentName": "Pre-sentence report"
},
{
"id": "6037becb-0d0c-44e1-8727-193f22df0494",
"lastSaved": "2024-04-01",
"documentName": "CPS Pack"
},
{
"id": "d072ed9a-999f-4333-a116-a871a845aeb3",
"lastSaved": "",
"documentName": "Previous convictions"
}
],
"licenceConditions": [
{
"id": 2500257207,
"mainDescription": "Alcohol",
"imposedReleasedDate": "2022-02-04",
"actualStartDate": "2022-02-04",
"notes": []
},
{
"id": 2500257206,
"mainDescription": "Freedom of movement ",
"subTypeDescription": "Not to enter or remain in sight of any [NAMED PLACE] without the prior approval of your supervising officer. ",
"imposedReleasedDate": "2024-02-04",
"actualStartDate": "2024-02-04",
"licenceConditionNotes": [
{
"id": 0,
"createdBy": "Peter Parker",
"createdByDate": "2024-10-22",
"note": "Is not allowed to any sporting events",
"hasNoteBeenTruncated": false
},
{
"id": 1,
"note": "Not to go to a football game.",
"hasNoteBeenTruncated": false
}
]
}
]
"courtDocuments": [],
"licenceConditions": []
}
},
"headers": {
Expand Down

0 comments on commit 04c21e3

Please sign in to comment.