Repository navigation
fix(parking): rechazar una salida anterior a la entrada - #13
Merged
bpstack merged 2 commits intoOct 12, 2026
Merged
Conversation
- bookings.repository.ts: checkOut compares the real check-out with the stored check-in, inside its transaction, and throws PARKING_INVALID_DATES when it is earlier. - bookings.controller.ts: that error answers 400 with its code. - checkout-dates.test.ts: an earlier check-out is refused and writes nothing; an equal or later one commits. Why: the handler only rejected an unreadable date, so a check-out before the check-in was stored. Checked in the browser: the check-out modal with the day before is refused, with a later time it completes. Any year is still accepted: the owner chose to only enforce the order.
- Remove the "Parking: check-in and check-out accept arbitrary real dates" entry. Why: a check-out earlier than its check-in is now refused; the owner decided not to bound the year, so nothing else is left.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
Cambios
docs/TODO.md: se borra el punto, ya decidido (sin límite de años).Por qué
Se podía cerrar una reserva con una salida antes de la entrada, lo que estropeaba duraciones e importes.