element table删除本页最后一条数据,不能正常回到上一页,通过在watch里监听总数据条数total解决了这个问题
total() {
if (
this.total == (this.currentIndex - 1) * this.pageSize &&
this.total != 0
) {
this.currentIndex -= 1;
this.getData();
}
},