This commit is contained in:
曹辉 2023-03-20 15:43:07 +08:00
parent 2ead27f329
commit 0a540064ff

View File

@ -31,7 +31,7 @@
已过期 已过期
</view> </view>
</view> </view>
<view class="rollup" v-if="couponlist.length>0"> <view class="rollup" v-if="couponlist">
<view class="item" v-for="(item,index) in couponlist" :key="index" <view class="item" v-for="(item,index) in couponlist" :key="index"
:style="item.useStatus!='NOT_USED'?'height:180rpx':''"> :style="item.useStatus!='NOT_USED'?'height:180rpx':''">
<view class="top" :style="item.useStatus!='NOT_USED'?'background: #EFECEC;color: #4B4B4B;':''"> <view class="top" :style="item.useStatus!='NOT_USED'?'background: #EFECEC;color: #4B4B4B;':''">
@ -67,7 +67,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="noorder" v-if="couponlist.length==0"> <view class="noorder" v-else>
<u-empty mode="coupon" icon-size='220'></u-empty> <u-empty mode="coupon" icon-size='220'></u-empty>
</view> </view>
</view> </view>
@ -83,7 +83,7 @@
return { return {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
couponlist: [], couponlist: null,
total: 0, total: 0,
couponstatus: '', // couponstatus: '', //
patientId: null, patientId: null,
@ -107,7 +107,9 @@
methods: { methods: {
getlist() { getlist() {
selectCoupon(this.pageNum, this.pageSize, this.patientId, this.couponstatus).then(res => { selectCoupon(this.pageNum, this.pageSize, this.patientId, this.couponstatus).then(res => {
this.couponlist = res.rows if (res.rows.length > 0) {
this.couponlist = res.rows
}
this.total = res.total this.total = res.total
}) })
}, },