Skip to content

Commit

Permalink
MAN-109 - update db object
Browse files Browse the repository at this point in the history
  • Loading branch information
achimber-moj committed Oct 29, 2024
1 parent 3bbdaf5 commit 3249179
Showing 1 changed file with 1 addition and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,24 +81,7 @@ class Appointment (
@Column(name = "contact_id")
val id: Long = 0,

) {

@CreatedDate
@Column(name = "created_datetime")
var createdDateTime: ZonedDateTime = ZonedDateTime.now()

@LastModifiedDate
@Column(name = "last_updated_datetime")
var lastUpdatedDateTime: ZonedDateTime = ZonedDateTime.now()

val duration: Duration
get() =
if (endTime != null) {
Duration.between(startTime, endTime)
} else {
Duration.ZERO
}
}
)

interface AppointmentRepository : JpaRepository<Appointment, Long> {
@Query(
Expand Down

0 comments on commit 3249179

Please sign in to comment.