mirror of
https://github.com/colymba/GridFieldBulkEditingTools.git
synced 2024-10-22 09:05:57 +00:00
FIX added destructive action confim dialog
This commit is contained in:
parent
ac84765dc1
commit
7332ed0b8c
@ -112,11 +112,20 @@
|
|||||||
cacheBuster = new Date().getTime()
|
cacheBuster = new Date().getTime()
|
||||||
;
|
;
|
||||||
|
|
||||||
|
if ( $btn.hasClass('ss-ui-action-destructive') )
|
||||||
|
{
|
||||||
|
if( !confirm(ss.i18n._t('GridFieldBulkManager.CONFIRM_DESTRUCTIVE_ACTION')) )
|
||||||
|
{
|
||||||
|
e.preventDefault();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$btn.addClass('loading');
|
$btn.addClass('loading');
|
||||||
|
|
||||||
if ( ids.length <= 0 )
|
if ( ids.length <= 0 )
|
||||||
{
|
{
|
||||||
alert( ss.i18n._t('GridFieldBulkTools.BULKACTION_EMPTY_SELECT') );
|
alert( ss.i18n._t('GridFieldBulkManager.BULKACTION_EMPTY_SELECT') );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,6 +5,7 @@ if(typeof(ss) == 'undefined' || typeof(ss.i18n) == 'undefined') {
|
|||||||
'GridFieldBulkTools.FINISH_CONFIRM': "You have unsaved changes. Continuing will loose all unsaved data.\n\nDo your really want to continue?",
|
'GridFieldBulkTools.FINISH_CONFIRM': "You have unsaved changes. Continuing will loose all unsaved data.\n\nDo your really want to continue?",
|
||||||
'GridFieldBulkTools.EDIT_CHANGED': 'Modified',
|
'GridFieldBulkTools.EDIT_CHANGED': 'Modified',
|
||||||
'GridFieldBulkTools.EDIT_UPDATED': 'Saved',
|
'GridFieldBulkTools.EDIT_UPDATED': 'Saved',
|
||||||
'GridFieldBulkTools.BULKACTION_EMPTY_SELECT': 'You must select at least one record.'
|
'GridFieldBulkManager.BULKACTION_EMPTY_SELECT': 'You must select at least one record.',
|
||||||
|
'GridFieldBulkManager.CONFIRM_DESTRUCTIVE_ACTION': 'The data will be lost permanently. Do you want to continue?'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,7 @@ if(typeof(ss) == 'undefined' || typeof(ss.i18n) == 'undefined') {
|
|||||||
'GridFieldBulkTools.FINISH_CONFIRM': "Vous avez des changements non enregistrés. En continuant vous allez perdre toutes vos données non enregistrées.\n\nVoulez-vous vraiment continuer?",
|
'GridFieldBulkTools.FINISH_CONFIRM': "Vous avez des changements non enregistrés. En continuant vous allez perdre toutes vos données non enregistrées.\n\nVoulez-vous vraiment continuer?",
|
||||||
'GridFieldBulkTools.EDIT_CHANGED': 'Changé',
|
'GridFieldBulkTools.EDIT_CHANGED': 'Changé',
|
||||||
'GridFieldBulkTools.EDIT_UPDATED': 'Enregisté',
|
'GridFieldBulkTools.EDIT_UPDATED': 'Enregisté',
|
||||||
'GridFieldBulkTools.BULKACTION_EMPTY_SELECT': 'Vous devez séléctionner au moins un élément.'
|
'GridFieldBulkManager.BULKACTION_EMPTY_SELECT': 'Vous devez séléctionner au moins un élément.',
|
||||||
|
'GridFieldBulkManager.CONFIRM_DESTRUCTIVE_ACTION': 'Vos données seront perdues définitivement. Voulez-vous continuer?'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,7 @@ if(typeof(ss) == 'undefined' || typeof(ss.i18n) == 'undefined') {
|
|||||||
'GridFieldBulkTools.FINISH_CONFIRM': "Er zijn niet-opgeslagen wijzigingen.\n\nDoorgaan zal al deze niet-opgeslagen wijzigingen vergeten.\n\nWeet je zeker dat je de pagina wilt verlaten?",
|
'GridFieldBulkTools.FINISH_CONFIRM': "Er zijn niet-opgeslagen wijzigingen.\n\nDoorgaan zal al deze niet-opgeslagen wijzigingen vergeten.\n\nWeet je zeker dat je de pagina wilt verlaten?",
|
||||||
'GridFieldBulkTools.EDIT_CHANGED': 'Aangepast',
|
'GridFieldBulkTools.EDIT_CHANGED': 'Aangepast',
|
||||||
'GridFieldBulkTools.EDIT_UPDATED': 'Opgeslagen',
|
'GridFieldBulkTools.EDIT_UPDATED': 'Opgeslagen',
|
||||||
'GridFieldBulkTools.BULKACTION_EMPTY_SELECT': 'U moet minstens een item te selecteren.'
|
'GridFieldBulkManager.BULKACTION_EMPTY_SELECT': 'U moet minstens een item te selecteren.',
|
||||||
|
'GridFieldBulkManager.CONFIRM_DESTRUCTIVE_ACTION': 'De gegevens zullen permanent verloren. Weet je zeker dat je de pagina wilt verlaten?'
|
||||||
});
|
});
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user