Bug 20115: Trigger "modified" when sort is changed

Signed-off-by: Jesse Maseto <jesse@bywatersolutions.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Jonathan Druart 2018-01-31 14:06:23 -03:00
parent 32c562bbe0
commit d407221be6
2 changed files with 6 additions and 1 deletions

View file

@ -162,7 +162,6 @@
});[% END %]
$(document).ready(function(){
$("dl.sortable").sortable();
$("select[multiple='multiple']").multipleSelect( {
placeholder: _("Please select ..."),
selectAllText: _("Select all"),

View file

@ -82,6 +82,12 @@ $( document ).ready( function () {
return false;
});
$("dl.sortable").sortable();
$("dl.sortable").on( "sortchange", function( event, ui ) {
// This is not exact but we just need to trigger a change
$(ui.item.find('input:first')).change();
} );
window.onbeforeunload = function () {
if ( KOHA.Preferences.Modified ) {
return MSG_MADE_CHANGES;