您需要将回调注册到JsonStore 的加载和异常事件.像这样的东西:
var grid = new Ext.grid.GridPanel({
store: new Ext.data.JsonStore({
[...]
listeners: {
load: this.onLoadSuccess.crateDelegate(this),
exception: this.onLoadException.createDelegate(this)
}
}),
onLoadSuccess: function () {
// success
},
onLoadException: function () {
// error
},
[...]
}
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
21044 次 |
最近记录: |