From 7a125d7cc8d063188d7fff101e28562b89b6dcd7 Mon Sep 17 00:00:00 2001 From: Lucas Gass Date: Thu, 27 Feb 2025 22:34:37 +0000 Subject: [PATCH] Bug 39212: Explicitly set the contentType to JSON To test: 1. Make an item or item type 'Bookable' 2. Place a booking for that item 3. Go the 'Bookings' tab for that item. 4. Edit the booking 5. Submit the edit request and see at the top of the modal "Failure" 6. APPLY PATCH 7. Try editing bookings, now it should work. Signed-off-by: Kristi Krueger Signed-off-by: Martin Renvoize Signed-off-by: Katrin Fischer --- koha-tmpl/intranet-tmpl/prog/js/modals/place_booking.js | 1 + 1 file changed, 1 insertion(+) diff --git a/koha-tmpl/intranet-tmpl/prog/js/modals/place_booking.js b/koha-tmpl/intranet-tmpl/prog/js/modals/place_booking.js index 8bbb4547e9..3ce9cf0f1d 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/modals/place_booking.js +++ b/koha-tmpl/intranet-tmpl/prog/js/modals/place_booking.js @@ -1201,6 +1201,7 @@ $("#placeBookingForm").on("submit", function (e) { let putting = $.ajax({ method: "PUT", url: url, + contentType: "application/json", data: JSON.stringify({ booking_id: booking_id, start_date: start_date,