table.render({
....
,done: function (res, curr, count) {
// 重新渲染的条件. 页码大于2, 成功的请求.
// 状态码字段code 和 数据字段data, 根据自己的情况改写
if ( (res.data == null || res.data.length == 0) && curr > 1 && res.code == 200) {
tableObj.reload({
where: {
// 设定异步数据接口的额外参数,任意设
// key: ''
},
page: {
curr: --curr//重新从第 CURR 页开始
}
});
}
}
,.....
}
版权声明:本文为f_h_h原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。