Move hearing to past date: room, hearingStartTime and multi-day#33
Merged
ozturkmenb merged 4 commits intoJul 10, 2026
Merged
Conversation
…-day range - request schema: add optional courtRoomId + endDate and mandatory hearingStartTime (local Europe/London -> UTC in backend) - -enriched command migrated to a hearingDays[] array; async handler re-issues N hearing days (changeStartDate + assignHearingDaysV2) - validate future date, endDate>=startDate and startDate>=today-6months for all jurisdictions (sync 422); weekend-only range rejected - MAGS: adapter sends room/time/endDate to courtscheduler and maps the bookedSlots[] response; no-session stays sync 422 - CROWN: listing-side enrichment using hearingStartTime (courtscheduler still not called - Phase 2) - unit + integration tests updated/added
1 similar comment
ed75f3e to
b8281f8
Compare
…uest - request schema: courtRoomId added to required - IT test-data templates (MAGS + CROWN) now carry courtRoomId - Steps injects the hearing's room into the template, keeps the missing-centre payload precise (only centre absent), adds courtRoomId to the unknown-hearing payload, and adds a missing-courtRoomId helper - IT: multi-day range test supplies the room; new shouldRejectMoveWith400WhenCourtRoomIdMissing
…tartTime/endTime
Request contract is now { courtCentreId, courtRoomId (both mandatory UUIDs),
startTime (mandatory, absolute UTC e.g. 2026-07-02T17:00:00.000Z), endTime
(optional UTC) }. startDate+hearingStartTime (local HH:mm) collapse into startTime
and endDate becomes endTime; the backend derives the day and time-of-day directly
from the UTC instants, removing all local->UTC conversion. Enriched command,
handler and courtscheduler service are unchanged (API derives the values they take).
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Extend
listing.command.move-hearing-to-past-datewith an optional court room, a mandatory localhearingStartTime(converted to UTC in the backend), and an optionalendDatefor multi-day moves; MAGISTRATES sessions are selected by time-of-day.Changes
courtRoomId(opt),endDate(opt), mandatoryhearingStartTime(HH:mm).-enrichedcommand: single session fields →hearingDays[]array; async handler re-issues NHearingDays (changeStartDate + assignHearingDaysV2).bookedSlots[]response; no-session stays sync 422 NO_SESSION_FOUND.hearingStartTime(courtscheduler still not called — Phase 2).Testing
runIntegrationTests.sh): full suite 233 run / 0 fail / 3 skipped;MoveHearingToPastDateIT11/11 (MAGS + CROWN, single & multi-day, room-scoped, 422 paths).Pairs with hmcts/cpp-context-listing-courtscheduler dev/move-to-past-date-room-time-multiday.