diff --git a/backend/vkt/src/main/java/fi/oph/vkt/model/ExamEvent.java b/backend/vkt/src/main/java/fi/oph/vkt/model/ExamEvent.java index ccecf5654..129cfef49 100644 --- a/backend/vkt/src/main/java/fi/oph/vkt/model/ExamEvent.java +++ b/backend/vkt/src/main/java/fi/oph/vkt/model/ExamEvent.java @@ -10,6 +10,7 @@ import jakarta.persistence.GenerationType; import jakarta.persistence.Id; import jakarta.persistence.OneToMany; +import jakarta.persistence.OrderBy; import jakarta.persistence.Table; import java.time.LocalDate; import java.time.LocalDateTime; @@ -53,6 +54,7 @@ public class ExamEvent extends BaseEntity { private long maxParticipants; @OneToMany(mappedBy = "examEvent") + @OrderBy("createdAt") private List enrollments = new ArrayList<>(); @OneToMany(mappedBy = "examEvent") diff --git a/frontend/packages/vkt/public/i18n/fi-FI/common.json b/frontend/packages/vkt/public/i18n/fi-FI/common.json index e88025b21..4b5fe9752 100644 --- a/frontend/packages/vkt/public/i18n/fi-FI/common.json +++ b/frontend/packages/vkt/public/i18n/fi-FI/common.json @@ -46,6 +46,7 @@ }, "dates": { "dateTimeFormat": "l [klo] HH.mm", + "dateTimeFormatPrecise": "l [klo] HH.mm.ss", "timeFormat": "[klo] HH.mm", "dateFormat": "l", "registrationOpensAt": "klo 10.00", diff --git a/frontend/packages/vkt/public/i18n/sv-SE/common.json b/frontend/packages/vkt/public/i18n/sv-SE/common.json index fee62838f..9a0e7f5ee 100644 --- a/frontend/packages/vkt/public/i18n/sv-SE/common.json +++ b/frontend/packages/vkt/public/i18n/sv-SE/common.json @@ -46,6 +46,7 @@ }, "dates": { "dateTimeFormat": "l [kl.] HH.mm", + "dateTimeFormatPrecise": "l [kl.] HH.mm.ss", "dateFormat": "l", "timeFormat": "[kl.] HH.mm", "registrationOpensAt": "kl. 10.00", diff --git a/frontend/packages/vkt/src/components/clerkEnrollment/listing/ClerkEnrollmentListingRow.tsx b/frontend/packages/vkt/src/components/clerkEnrollment/listing/ClerkEnrollmentListingRow.tsx index 03b69e1a3..336d3a416 100644 --- a/frontend/packages/vkt/src/components/clerkEnrollment/listing/ClerkEnrollmentListingRow.tsx +++ b/frontend/packages/vkt/src/components/clerkEnrollment/listing/ClerkEnrollmentListingRow.tsx @@ -88,7 +88,9 @@ export const ClerkEnrollmentListingRow = ({ {getSelectedPartialExamsText()} - {DateTimeUtils.renderDateTime(enrollment.enrollmentTime)} + + {DateTimeUtils.renderDateTimePrecise(enrollment.enrollmentTime)} + {[ diff --git a/frontend/packages/vkt/src/utils/dateTime.ts b/frontend/packages/vkt/src/utils/dateTime.ts index fee70c0ae..3c5854727 100644 --- a/frontend/packages/vkt/src/utils/dateTime.ts +++ b/frontend/packages/vkt/src/utils/dateTime.ts @@ -13,6 +13,15 @@ export class DateTimeUtils { ); } + static renderDateTimePrecise(dateTime?: Dayjs) { + const t = translateOutsideComponent(); + + return DateUtils.formatOptionalDateTime( + dateTime, + t('vkt.common.dates.dateTimeFormatPrecise'), + ); + } + static renderOpenDateTime(dateTime?: Dayjs) { const t = translateOutsideComponent();