From 8b38eec31474e132d95d183841fb9d20595347c6 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 18 Aug 2023 11:04:01 +0100 Subject: [PATCH] Bug 29002: Display patron rather than booking id in timeline This patch improves the display of the bookings timeline to display who the booking is for rather than a cryptic booking id. Test plan 1) Follow the previous test plans 2) Navigate to the bookings display tab 3) Note that the timeline now displays each booking with the patron title as expected as apposed to "Booking XX" 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 --- koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) 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 3cea863c7a..86ff239d19 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/bookings/list.tt @@ -76,6 +76,7 @@ }); var bookings = $.ajax({ url: '/api/v1/biblios/[% biblionumber | uri %]/bookings', + headers: { 'x-koha-embed': 'patron' }, dataType: 'json', type: 'GET', }); @@ -101,7 +102,10 @@ patron: booking.patron_id, start: dayjs(booking.start_date).toDate(), end: dayjs(booking.end_date).toDate(), - content: 'Booking: ' + booking.booking_id, + content: $patron_to_html(booking.patron, { + display_cardnumber: true, + url: false + }), editable: { remove: true, updateTime: true }, type: 'range', group: booking.item_id ? booking.item_id : 0 -- 2.39.5