generated from ministryofjustice/template-repository
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
1 parent
64252bb
commit 7284184
Showing
10 changed files
with
237 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
...nt-summary-and-delius/src/dev/resources/messages/assessment-summary-produced-O123456.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"Type": "Notification", | ||
"MessageId": "33ad848a-4342-5ff2-9fe9-d96307935317", | ||
"Message": "{\n \"eventType\": \"assessment.summary.produced\",\n \"version\": 1,\n \"description\": \"Assessment Summary has been produced\",\n \"detailUrl\": \"http://localhost:{wiremock.port}/eor/oasys/ass/asssumm/O123456/ALLOW/10069391/COMPLETE\",\n \"occurredAt\": \"2023-12-05T15:32:32+00:00\",\",personReference\":{\"identifiers\":[{\"type\":\"CRN\",\"value\":\"O123456\"}]}}", | ||
"Timestamp": "2023-12-05T15:32:33.823Z", | ||
"MessageAttributes": { | ||
"eventType": { | ||
"Type": "String", | ||
"Value": "risk-assessment.scores.determined" | ||
} | ||
} | ||
} |
115 changes: 115 additions & 0 deletions
115
...-summary-and-delius/src/dev/resources/simulations/__files/assessment-summary-O123456.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
{ | ||
"probNumber": "O123456", | ||
"assessments": [ | ||
{ | ||
"assessmentPk": 10069391, | ||
"assessmentType": "LAYER3", | ||
"dateCompleted": "2023-12-07T12:22:44", | ||
"assessorSignedDate": "2023-12-07T12:16:12", | ||
"initiationDate": "2023-12-07T11:49:57", | ||
"assessmentStatus": "COMPLETE", | ||
"superStatus": "COMPLETE", | ||
"laterWIPAssessmentExists": false, | ||
"latestWIPDate": null, | ||
"laterSignLockAssessmentExists": false, | ||
"latestSignLockDate": null, | ||
"laterPartCompUnsignedAssessmentExists": false, | ||
"latestPartCompUnsignedDate": null, | ||
"laterPartCompSignedAssessmentExists": false, | ||
"latestPartCompSignedDate": null, | ||
"laterCompleteAssessmentExists": false, | ||
"latestCompleteDate": "2023-12-07T12:22:44", | ||
"riskChildrenCommunity": null, | ||
"currentConcernsCustody": null, | ||
"currentConcernsDisruptive": null, | ||
"currentConcernsHostel": null, | ||
"reviewNum": null, | ||
"currentConcernsEscape": null, | ||
"initialSpDate": "12/02/2024", | ||
"currentConcernsVulnerablity": null, | ||
"currentConcernsBreachOfTrust": null, | ||
"currentConcernsRiskOfSelfHarm": null, | ||
"currentConcernsRiskOfSuicide": null, | ||
"reviewSpDate": "2024-08-12", | ||
"riskPrisonersCustody": null, | ||
"riskStaffCustody": null, | ||
"riskStaffCommunity": null, | ||
"riskKnownAdultCustody": null, | ||
"riskKnownAdultCommunity": null, | ||
"riskPublicCustody": null, | ||
"riskPublicCommunity": null, | ||
"riskChildrenCustody": null, | ||
"weightedScores": { | ||
"accommodationWeightedScore": 3, | ||
"eteWeightedScore": 3, | ||
"relationshipsWeightedScore": 2, | ||
"lifestyleWeightedScore": 3, | ||
"drugWeightedScore": 0, | ||
"alcoholWeightedScore": 3, | ||
"thinkingWeightedScore": 5, | ||
"attitudesWeightedScore": 4 | ||
}, | ||
"furtherInformation": { | ||
"totWeightedScore": 76, | ||
"pOAssessment": "270", | ||
"pOAssessmentDesc": "Review", | ||
"assessorName": "John Smith", | ||
"ogrs1Year": 11, | ||
"ogrs2Year": 20, | ||
"reviewTerm": "N", | ||
"courtCode": "CRT150", | ||
"courtType": "MC", | ||
"courtName": "Downpatrick Magistrate Court (DPKMC)" | ||
}, | ||
"offender": { | ||
"riskToOthers": "N", | ||
"offenderPk": 7843827 | ||
}, | ||
"ogpOvp": { | ||
"ogpNC": "Y", | ||
"ovpNC": "Y", | ||
"ogp1Year": null, | ||
"ogp2Year": null, | ||
"ovp1Year": null, | ||
"ovp2Year": null, | ||
"ogrs3RiskRecon": "L", | ||
"ogpRisk": null, | ||
"ovpRisk": null | ||
}, | ||
"basicSentencePlan": [ | ||
{ | ||
"bspAreaLinked": "ATTITUDES", | ||
"bspAreaLinkedDesc": "Attitudes" | ||
}, | ||
{ | ||
"bspAreaLinked": "RISK_MANAGEMENT", | ||
"bspAreaLinkedDesc": "Risk Management" | ||
}, | ||
{ | ||
"bspAreaLinked": "THINKING_AND_BEHAVIOUR", | ||
"bspAreaLinkedDesc": "Thinking/Behaviour" | ||
}, | ||
{ | ||
"bspAreaLinked": "EDUCATION_TRAINING_AND_EMPLOYABILITY", | ||
"bspAreaLinkedDesc": "ETE" | ||
}, | ||
{ | ||
"bspAreaLinked": "EDUCATION_TRAINING_AND_EMPLOYABILITY", | ||
"bspAreaLinkedDesc": "ETE" | ||
}, | ||
{ | ||
"bspAreaLinked": "ATTITUDES", | ||
"bspAreaLinkedDesc": "Attitudes" | ||
} | ||
], | ||
"offences": [ | ||
{ | ||
"offenceCode": "804", | ||
"offenceSubcode": "00", | ||
"additionalOffence": "N" | ||
} | ||
], | ||
"sentencePlan": null | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
...rc/main/kotlin/uk/gov/justice/digital/hmpps/integrations/delius/person/entity/Disposal.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package uk.gov.justice.digital.hmpps.integrations.delius.person.entity | ||
|
||
import jakarta.persistence.* | ||
import org.hibernate.annotations.Immutable | ||
|
||
@Entity | ||
@Immutable | ||
class Disposal( | ||
@OneToOne | ||
@JoinColumn(name = "event_id") | ||
val event: Event, | ||
|
||
@ManyToOne | ||
@JoinColumn(name = "disposal_type_id") | ||
val type: DisposalType, | ||
|
||
@Column(name = "active_flag", columnDefinition = "number") | ||
val active: Boolean = true, | ||
|
||
@Column(columnDefinition = "number") | ||
val softDeleted: Boolean = false, | ||
|
||
@Id | ||
@Column(name = "disposal_id") | ||
val id: Long, | ||
) | ||
|
||
@Entity | ||
@Immutable | ||
@Table(name = "r_disposal_type") | ||
class DisposalType( | ||
@Column | ||
val sentenceType: String, | ||
|
||
@Id | ||
@Column(name = "disposal_type_id") | ||
val id: Long, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters