https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=42997
Bug ID: 42997
Summary: Keep booking end dates in sync with checkout due dates
at issue and renewal
Initiative type: ---
Sponsorship ---
status:
Product: Koha
Version: Main
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: P5 - low
Component: Circulation
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
CC: [email protected], [email protected]
Target Milestone: ---
Depends on bug 41898 (booking status lifecycle).
With the 'issued' booking status in place, the booking and its linked
checkout can drift apart whenever the due date differs from the booking
end date - at issue time (staff due date overrides) and at renewal.
This patchset makes the checkout due date authoritative and keeps the
booking in step with it:
- AddIssue syncs any due date override back to booking.end_date the
moment the booking transitions to 'issued'; if the override would
clash with a subsequent booking the checkout proceeds with the
booking's original end date
- CanBookBeIssued raises a new BOOKED_DUE_DATE_CLASH confirmation on
the checkout screen when an explicitly requested due date runs into
the next booking for the item, so staff are warned before continuing
- circulation.pl now honours an explicit due date override for booked
items instead of silently clamping it to the booking end date
- CanBookBeRenewed no longer allows a renewal to run straight through
the start of the next booking: the patron's own booking previously
hid subsequent bookings from the clash lookup. Requested due dates
(checkouts screen renewal date, circ/renew.pl hard due date) are now
validated against bookings too
- AddRenewal pulls the linked booking's end_date along with the renewed
due date, mirroring the AddIssue behaviour
Test plan:
1. Run t/db_dependent/Circulation.t and t/db_dependent/Koha/Item.t
2. Create two consecutive bookings on one item for two patrons; check
the item out to the first patron with a due date beyond the second
booking's start; confirm the warning appears and, on confirming,
the checkout uses the requested date whilst the booking keeps its
original end date
3. Check out a booked item with a non-clashing due date override and
confirm the booking end date follows it
4. Renew a booked checkout and confirm the booking end date follows
the new due date; attempt to renew past the next booking's start
and confirm the renewal is refused
--
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/