This commit is contained in:
曹辉 2023-03-06 15:46:43 +08:00
parent 44225d644e
commit af7c13d45d
2 changed files with 4 additions and 4 deletions

View File

@ -2,9 +2,9 @@ import request from "../request.js"
//新人优惠券 //新人优惠券
export function couponByUseStatus(patientId) { export function couponByUseStatus(pageNum, pageSize, patientId) {
return request({ return request({
url: `/nurseApplet/patientInfo/couponByUseStatus?patientId=${patientId}`, url: `/nurseApplet/patientInfo/couponByUseStatus?pageNum=${pageNum}&pageSize=${pageSize}patientId=${patientId}`,
method: 'get' method: 'get'
}) })
} }

View File

@ -152,7 +152,7 @@
} }
}, },
getlist() { getlist() {
couponByUseStatus(this.patientId).then(res => { couponByUseStatus(this.pageNum, this.pageSize, this.patientId).then(res => {
this.couponlist = res.rows this.couponlist = res.rows
this.total = res.total this.total = res.total
}) })
@ -181,7 +181,7 @@
onReachBottom() { // onReachBottom() { //
if (this.couponlist.length >= this.total) {} else { if (this.couponlist.length >= this.total) {} else {
this.pageNum++; this.pageNum++;
couponByUseStatus(this.patientId).then(res => { couponByUseStatus(this.pageNum, this.pageSize, this.patientId).then(res => {
res.rows.forEach(e => { res.rows.forEach(e => {
this.couponlist.push(e) this.couponlist.push(e)
}) })