form.submit()异步提交返回值是false的话会走failure不走success

 1         form.submit({
 2             url: url,
 3             waitMsg: '数据在处理中,请稍后......',
 4             waitTitle: '提示',
 5             method: 'POST',
 6             success: function (form, options) {
 7                 var b = Ext.decode(options.response.responseText).success;
 8                 if (b) {
 9                     Ext.getCmp('editrole_window_id').close();
10                     Ext.getCmp('rolegrid').store.load({});
11                 } else {
12                     Ext.msg.show('提示', '保存失败');
13                 }
14             },
15             failure: function (form, options) {
16                 Ext.msg.show('提示', '调用出错');
17             }
18 
19         });

 

posted on 2018-01-23 13:43  辰舟  阅读(477)  评论(0编辑  收藏  举报