Bug 3134: highlight all selected reports when confirming deletion of multiple reports

This patch adds the same behavior when deleting 1 or more reports.
When checkboxes are checked and the "delete selected" button is pressed,
checked lines are hightlighted in red.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
Jonathan Druart 2013-08-21 10:23:11 +02:00 committed by Galen Charlton
parent 0d88109018
commit fb2bcc05c1

View file

@ -129,7 +129,13 @@ $(document).ready(function(){
alert(_("You must select one or more reports to delete"));
return false;
}
return confirm(_("Are you sure you want to delete the selected reports?"));
$(checkedItems).parents('tr').addClass("warn");
if( confirm(_("Are you sure you want to delete the selected reports?")) ) {
return true;
} else {
$(checkedItems).parents('tr').removeClass("warn");
return false;
}
});
[% END %]