翻页式分页
//这是data中的数据
pageIndex: 0,
pageSize: 10,
async getDataList() {
this.loading = true
let params = {
size: this.pageSize,
offSet: this.pageSize * this.pageIndex,
describe: this.describe ? this.describe : '',
}
const res = await this.$http.get('pcPaySlip/pagePaySlip', {
params: {
...params,
},
})
console.log('工资条分页', res)
if (res.data.code == 1000) {
this.loading = false
this.dataList = res.data.data.paySlipList
this.total = res.data.data.total
} else {
this.$message.error(res.message)
this.loading = true
}
},
//翻页