From e9a516e61ef207c4db87602cd5ea84378f6ef2a8 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 24 Jan 2019 15:11:21 -0300 Subject: [PATCH] Bug 20006: (follow-up) Fix holds.js This patch makes holds.js call the endpoint with 'pickup_library_id' instead of the old 'branchcode' property. To test: - Place a hold - Go to the patron's detail page - Go to the Holds tab - Change the pickup location => SUCCESS: It works! Signed-off-by: Josef Moravec Signed-off-by: Martin Renvoize --- koha-tmpl/intranet-tmpl/prog/js/holds.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/holds.js b/koha-tmpl/intranet-tmpl/prog/js/holds.js index c6bc3e5d0f..75b9097a13 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/holds.js +++ b/koha-tmpl/intranet-tmpl/prog/js/holds.js @@ -202,7 +202,7 @@ $(document).ready(function() { var res_id = $(this).attr('reserve_id'); $(this).after('
'); var api_url = '/api/v1/holds/'+res_id; - var update_info = JSON.stringify({ branchcode: $(this).val(), priority: parseInt($(this).attr("priority"),10) }); + var update_info = JSON.stringify({ pickup_library_id: $(this).val(), priority: parseInt($(this).attr("priority"),10) }); $.ajax({ method: "PUT", url: api_url, -- 2.21.0