Skip to content

Commit d8b7b0e

Browse files
Added the extra fields to the induction schedule mapper
1 parent 47f124b commit d8b7b0e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/main/kotlin/uk/gov/justice/digital/hmpps/hmppsintegrationapi/models/hmpps/InductionSchedule.kt

+4
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,8 @@ class InductionScheduleDeserializer : JsonDeserializer<InductionSchedule>() {
136136
val systemUpdatedAt = node["updatedAt"]?.asText()?.let { Instant.parse(it) }
137137
val inductionPerformedBy = node["inductionPerformedBy"]?.takeUnless { it.isNull }?.asText()
138138
val inductionPerformedAt = node["inductionPerformedAt"]?.takeUnless { it.isNull }?.asText()?.let { LocalDate.parse(it) }
139+
val inductionPerformedByRole = node["inductionPerformedByRole"]?.takeUnless { it.isNull }?.asText()
140+
val inductionPerformedAtPrison = node["inductionPerformedAtPrison"]?.takeUnless { it.isNull }?.asText()
139141
val version = node["version"]?.asInt()
140142
val exemptionReason = node["exemptionReason"]?.asText()
141143

@@ -148,6 +150,8 @@ class InductionScheduleDeserializer : JsonDeserializer<InductionSchedule>() {
148150
systemUpdatedAt = systemUpdatedAt,
149151
inductionPerformedBy = inductionPerformedBy,
150152
inductionPerformedAt = inductionPerformedAt,
153+
inductionPerformedByRole = inductionPerformedByRole,
154+
inductionPerformedAtPrison = inductionPerformedAtPrison,
151155
exemptionReason = exemptionReason,
152156
version = version,
153157
)

0 commit comments

Comments
 (0)