From: Galen Charlton Date: Mon, 25 Jan 2016 18:55:23 +0000 (-0500) Subject: webstaff: tweak egGrid's row-click handler X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=8e370cfd9a5031bb638286e570093f001adc7ecd;p=working%2FEvergreen.git webstaff: tweak egGrid's row-click handler With this patch, multiselect-enabled grids now *toggle* the selection status of affected rows, rather than select only that row while deselecting the rest. This in turn allows the double-click handler (if supplied) to act on all selected rows if it wants to. Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/web/js/ui/default/staff/services/grid.js b/Open-ILS/web/js/ui/default/staff/services/grid.js index d02841e50c..f59418ede9 100644 --- a/Open-ILS/web/js/ui/default/staff/services/grid.js +++ b/Open-ILS/web/js/ui/default/staff/services/grid.js @@ -795,7 +795,11 @@ angular.module('egGridMod', } } else { - grid.selectOneItem(index); + if ($scope.canMultiSelect) { + grid.toggleSelectOneItem(index); + } else { + grid.selectOneItem(index); + } grid.lastSelectedItemIndex = index; } }