From 21fb4634455607f48bd89e1379393b78e0880d74 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Wed, 8 Dec 2021 14:59:17 +0000 Subject: [PATCH] Bug 29002: Add modal based booking cancellation This patch adds a modal based booking cancellation flow to the biblio bookings display tab page. Test plan 1) Follow the test plans for the previous patches 2) Note a new column now appears in the bookings table with a 'Cancel' action button against each booking 3) Cancel one of the bookings using the new cancel button 4) A modal dialog should appear allowing you to continue with the cancelation or cancel 5) Confirm the cancelled booking is removed from the bookings table 6) Sign off Signed-off-by: Martin Renvoize Signed-off-by: Janet McGowan Signed-off-by: Caroline Cyr La Rose Signed-off-by: Laurence Rault Signed-off-by: Kyle M Hall Signed-off-by: Tomas Cohen Arazi --- .../en/includes/modals/cancel_booking.inc | 22 +++++++++++++++ .../prog/en/modules/bookings/list.tt | 12 ++++++++ .../prog/js/cancel_booking_modal.js | 28 +++++++++++++++++++ 3 files changed, 62 insertions(+) create mode 100644 koha-tmpl/intranet-tmpl/prog/en/includes/modals/cancel_booking.inc create mode 100644 koha-tmpl/intranet-tmpl/prog/js/cancel_booking_modal.js diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/modals/cancel_booking.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/modals/cancel_booking.inc new file mode 100644 index 0000000000..3e54718311 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/modals/cancel_booking.inc @@ -0,0 +1,22 @@ + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt index a0b61bc34d..34ba2c655a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt @@ -52,6 +52,7 @@ + [% INCLUDE modals/cancel_booking.inc %] [% MACRO jsinclude BLOCK %] [% Asset.js("lib/dayjs/dayjs.min.js") | $raw %] @@ -61,6 +62,7 @@ [% INCLUDE 'select2.inc' %] [% INCLUDE 'js-date-format.inc' %] [% Asset.js("js/place_booking_modal.js") | $raw %] + [% Asset.js("js/cancel_booking_modal.js") | $raw %]