Skip to content

Commit

Permalink
PI-1561 Handle null additional offence date
Browse files Browse the repository at this point in the history
  • Loading branch information
marcus-bcl committed Oct 16, 2023
1 parent ced3a3e commit e36f9f8
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import java.time.LocalDate

interface CaseOffence {
val description: String
val date: LocalDate
val date: LocalDate?
val main: Boolean
val eventNumber: String
}
Expand Down Expand Up @@ -61,7 +61,7 @@ class AdditionalOffence(
val offence: Offence,

@Column(name = "offence_date")
val date: LocalDate,
val date: LocalDate?,

@Column(columnDefinition = "number")
val softDeleted: Boolean,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,5 @@ data class MappaDetail(
val lastUpdated: ZonedDateTime
)

data class Offence(val description: String, val date: LocalDate, val main: Boolean, val eventNumber: String)
data class Offence(val description: String, val date: LocalDate?, val main: Boolean, val eventNumber: String)
data class Registration(val description: String, val startDate: LocalDate)
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ class AdditionalOffence(
val event: Event?,

@Column(name = "offence_date")
val date: LocalDate,
val date: LocalDate?,

@JoinColumn(name = "offence_id")
@ManyToOne(cascade = [CascadeType.PERSIST])
Expand Down

0 comments on commit e36f9f8

Please sign in to comment.