如果是通过request提交:
success: function (response,option){
var rs = Ext.util.JSON.decode(response.responseText);
if(rs.success=='true'){
Ext.Msg.alert('提示',rs.msg);
win.hide();
songsStore.reload();
}else{
Ext.Msg.alert('提示',rs.msg);
}
},
如果是通过表单提交:
handler : function() {
fm.getForm().submit({
success : function(form, action) {
if (action.result.success == "true") {
Ext.Msg.alert('提示',
action.result.msg);
grid.store.reload();
win.close();
} else {
Ext.Msg.alert('',
action.result.msg);
}
},
params : {
id : id
},
failure : function(form, action) {
Ext.Msg.alert("提示",
"编辑失败!");
win.close();
}
});
}