pengjun 2 years ago
parent
commit
da8f313739
  1. 21
      src/components/report/PatientRegisterListNobtn.vue

21
src/components/report/PatientRegisterListNobtn.vue

@ -192,8 +192,6 @@ export default {
//
mounted() {
this.$nextTick(() => {
this.scrollFull()
})
@ -234,9 +232,9 @@ export default {
},
async load() {
this.loadOpts.skipCount++
await this.btnQuery()
await this.Query()
},
//
scrollFull() {
this.dom = this.$refs['info'].bodyWrapper
@ -265,8 +263,13 @@ export default {
//
async btnQuery() {
this.loadOpts.skipCount = 0
this.Query()
},
async Query() {
if (this.fromType == 'report') {
await this.reportQuery()
this.reportQuery()
return
}
@ -319,8 +322,10 @@ export default {
//
reportQuery() {
if (this.loadOpts.skipCount != 0 && this.loadOpts.skipCount * this.loadOpts.maxResultCount >= this.loadOpts.totalCount) return
console.log('reportQuery', this.loadOpts)
if (this.loadOpts.skipCount != 0 && this.loadOpts.skipCount * this.loadOpts.maxResultCount >= this.loadOpts.totalCount) {
this.$message.info({ showClose: true, message: "数据已全部拉取!" })
return
}
let body = {
skipCount: this.loadOpts.skipCount,
@ -371,7 +376,7 @@ export default {
this.patientRegister.prList = [];
}
this.patientRegister.prList = this.patientRegister.prList.concat(res.data.items)
this.loadOpts.skipCount++
}
})
},

Loading…
Cancel
Save