From: Jason Boyer Date: Thu, 13 Sep 2018 11:39:06 +0000 (-0400) Subject: LP1792371: Fix De-select Whole Page Action X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=5f4b487477d6504b91991c042441209e28c8c30b;p=evergreen%2Fmasslnc.git LP1792371: Fix De-select Whole Page Action When using the checkbox to select or de-select the entire page of results, the de-select action changes the check and highlight states of the items on page but doesn't actually remove the records from the basket. This branch corrects that so that you can select and de-select the entire page of results and your basket contents are what you would expect. Signed-off-by: Jason Boyer Signed-off-by: Terran McCanna Signed-off-by: Kathy Lussier --- diff --git a/Open-ILS/web/js/ui/default/opac/record_selectors.js b/Open-ILS/web/js/ui/default/opac/record_selectors.js index 6116b39a41..d0c5f2f068 100644 --- a/Open-ILS/web/js/ui/default/opac/record_selectors.js +++ b/Open-ILS/web/js/ui/default/opac/record_selectors.js @@ -199,13 +199,18 @@ if (rec_selector_block) rec_selector_block.classList.remove("hidden"); function deselectSelectedOnPage() { + var to_del = []; [].forEach.call(rec_selectors, function(el) { if (el.checked) { el.checked = false; adjustLegacyControlsVis('delete', el.value); toggleRowHighlighting(el); + to_del.push(el.value); } }); + if (to_del.length > 0) { + mungeList('delete', to_del); + } } if (select_all_records_el) {