From 6f1203d1cf895efc473fade3ab049fc30d92c618 Mon Sep 17 00:00:00 2001 From: MrShi <1878285526@qq.com> Date: 星期三, 26 三月 2025 16:48:23 +0800 Subject: [PATCH] 优化 --- h5/pages/appointmentDetails/appointmentDetails.vue | 36 +++++++++++++++++++++++++++++++++++- 1 files changed, 35 insertions(+), 1 deletions(-) diff --git a/h5/pages/appointmentDetails/appointmentDetails.vue b/h5/pages/appointmentDetails/appointmentDetails.vue index 451b063..35c0d1c 100644 --- a/h5/pages/appointmentDetails/appointmentDetails.vue +++ b/h5/pages/appointmentDetails/appointmentDetails.vue @@ -85,11 +85,26 @@ <view class="box_list_item_val">{{ info.carNos }}</view> </view> </view> + <view class="footer"> + <u-button + text="鍙栨秷棰勭害" + size="mini" + v-if="[0,1,2,5].includes(info.status)" + @click="cancelShow = true" /> + </view> <u-popup :show="show" mode="center" @close="close"> <view class="qrocde"> <canvas class="qrcode_img" canvas-id="img1"></canvas> </view> </u-popup> + <!-- 鍙栨秷棰勭害寮圭獥 --> + <u-modal + :show="cancelShow" + :showCancelButton="true" + title="绯荤粺鎻愮ず" + content='纭畾鍙栨秷褰撳墠棰勭害鍚楋紵' + @cancel="cancelShow = false" + @confirm="cancel" /> </view> </template> @@ -100,9 +115,11 @@ export default { data() { return { + id: null, info: {}, show: false, - detail: '' + detail: '', + cancelShow: false } }, onBackPress(options) { @@ -121,6 +138,7 @@ onLoad(option) { uni.setStorageSync('ywinfo',{}) this.detail = option.detail || '' + this.id = option.id this.getDetail(option.id) // visitorSubDetail({ id: option.id }) // .then(res => { @@ -136,6 +154,12 @@ }, methods: { + // 鍙栨秷棰勭害 + cancel() { + visitsCancel(this.id).then(res => { + this.getDetail(this.id) + }) + }, close() { this.show = false }, @@ -170,6 +194,16 @@ <style lang="scss" scoped> .box { width: 100%; + .footer { + position: fixed; + left: 0; + bottom: 0; + width: 100%; + height: 100rpx; + text-align: right; + background-color: #ffffff; + padding-bottom: calc(30rpx + env(safe-area-inset-bottom)); + } .qrocde { width: 300rpx; height: 300rpx; -- Gitblit v1.9.3