|
|
@@ -171,21 +171,26 @@ Ext.define('school.view.interaction.timetable.List', {
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
- grid.setLoading(true);
|
|
|
- school.util.BaseUtil.request({
|
|
|
- // url: 'http://10.1.80.36:9520/api/school/curriculum/batchDelete',
|
|
|
- url: '/api/school/curriculum/batchDelete',
|
|
|
- method: 'POST',
|
|
|
- params: JSON.stringify({
|
|
|
- baseDTOs: data
|
|
|
- })
|
|
|
- }).then(function (res) {
|
|
|
- grid.setLoading(false);
|
|
|
- school.util.BaseUtil.showSuccessToast('成功删除' + data.length + '条记录');
|
|
|
- grid.store.loadPage(grid.store.currentPage);
|
|
|
- }).catch(function (e) {
|
|
|
- grid.setLoading(false);
|
|
|
- school.util.BaseUtil.showErrorToast('删除失败: ' + e.message);
|
|
|
+ school.util.BaseUtil.showConfirm('确认删除', '确定要删除这' + data.length + '条记录吗?')
|
|
|
+ .then(function(yes) {
|
|
|
+ if(yes == 'yes') {
|
|
|
+ grid.setLoading(true);
|
|
|
+ school.util.BaseUtil.request({
|
|
|
+ // url: 'http://10.1.80.36:9520/api/school/curriculum/batchDelete',
|
|
|
+ url: '/api/school/curriculum/batchDelete',
|
|
|
+ method: 'POST',
|
|
|
+ params: JSON.stringify({
|
|
|
+ baseDTOs: data
|
|
|
+ })
|
|
|
+ }).then(function (res) {
|
|
|
+ grid.setLoading(false);
|
|
|
+ school.util.BaseUtil.showSuccessToast('成功删除' + data.length + '条记录');
|
|
|
+ grid.store.loadPage(grid.store.currentPage);
|
|
|
+ }).catch(function (e) {
|
|
|
+ grid.setLoading(false);
|
|
|
+ school.util.BaseUtil.showErrorToast('删除失败: ' + e.message);
|
|
|
+ });
|
|
|
+ }
|
|
|
});
|
|
|
}
|
|
|
}],
|