From 6ed771467abc47b2d5e1174480a3302f6ab5ed96 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期三, 21 五月 2025 17:02:00 +0800
Subject: [PATCH] 提交
---
h5/pages/appointmentDetails/appointmentDetails.vue | 116 +++++++++++++++++++++++++++++++++++++++++++++++++++------
1 files changed, 103 insertions(+), 13 deletions(-)
diff --git a/h5/pages/appointmentDetails/appointmentDetails.vue b/h5/pages/appointmentDetails/appointmentDetails.vue
index 997d0f0..acf56d9 100644
--- a/h5/pages/appointmentDetails/appointmentDetails.vue
+++ b/h5/pages/appointmentDetails/appointmentDetails.vue
@@ -1,12 +1,12 @@
<template>
<view class="box">
- <view class="head_wrap head_success" v-if="info.status == 2">
- <view class="h1">璁垮棰勭害瀹℃牳閫氳繃</view>
+ <view class="head_wrap head_success" v-if="info.status == 2 || info.status == 5">
+ <view class="h1">璁垮棰勭害{{ info.status == 2 ? '瀹℃牳閫氳繃' : '涓嬪彂鎴愬姛' }}</view>
<view class="h2"
- >鎮ㄧ殑鏉ヨ鐢宠宸插鏍搁�氳繃锛岃鍦ㄨ瀹㈡満绛惧埌鍏ュ巶銆傚閬囩壒娈婃儏鍐碉紝鍙仈绯昏璁夸汉鎴栧畨淇濅汉鍛�</view
+ >鎮ㄧ殑鏉ヨ鐢宠宸瞷{ info.status == 2 ? '瀹℃牳閫氳繃' : '涓嬪彂鎴愬姛' }}锛岃鍦ㄨ瀹㈡満绛惧埌鍏ュ洯銆傚閬囩壒娈婃儏鍐碉紝鍙仈绯昏璁夸汉鎴栧畨淇濅汉鍛�</view
>
</view>
- <view class="qr_wrap" v-if="info.status == 2">
+ <view class="qr_wrap" v-if="info.status == 2 || info.status == 5">
<canvas class="box_head_qrcode" canvas-id="img"></canvas>
<view class="text">浣跨敤璁垮鏈烘壂鐮佺鍒�</view>
</view>
@@ -14,15 +14,39 @@
<view class="h1">璁垮棰勭害寰呭鏍�</view>
<view class="h2">鎮ㄧ殑棰勭害鍗曞凡鎻愪氦瀹℃牳锛岃绛夊緟琚浜哄鏍�</view>
</view>
+ <view class="head_wrap head_padding" v-if="info.status == 1">
+ <view class="h1">璁垮棰勭害瀹℃壒涓�</view>
+ <view class="h2">鎮ㄧ殑鏉ヨ鐢宠姝e湪瀹℃牳</view>
+ </view>
<view class="head_wrap head_error" v-if="info.status == 3">
<view class="h1">璁垮棰勭害瀹℃牳涓嶉�氳繃</view>
<view class="h2">鎮ㄧ殑鏉ヨ鐢宠宸茶椹冲洖锛屽鏈夌枒闂紝鍙仈绯昏璁夸汉</view>
</view>
+ <view class="head_wrap head_error" v-if="info.status == 4">
+ <view class="h1">璁垮棰勭害瀹℃牳宸插彇娑�</view>
+ <view class="h2">鎮ㄧ殑鏉ヨ鐢宠宸插彇娑堬紝璇烽噸鏂扮敵璇�</view>
+ </view>
+ <view class="head_wrap head_success" v-if="info.status == 7">
+ <view class="h1">璁垮棰勭害鎷滆涓�</view>
+ <view class="h2">浣犵殑璁跨敵璇锋鍦ㄨ繘琛�,濡傛湁鐤戦棶锛屽彲鑱旂郴琚浜�</view>
+ </view>
+ <view class="head_wrap head_success" v-if="info.status == 8">
+ <view class="h1">璁垮棰勭害宸茬绂�</view>
+ <view class="h2">鎮ㄧ殑鏉ヨ鐢宠宸插け鏁堬紝璇烽噸鏂扮敵璇�</view>
+ </view>
+ <view class="head_wrap head_error" v-if="info.status == 9">
+ <view class="h1">璁垮棰勭害宸插け鏁�</view>
+ <view class="h2">鎮ㄧ殑鏉ヨ鐢宠宸插け鏁堬紝璇烽噸鏂扮敵璇�</view>
+ </view>
+ <view class="head_wrap head_error" v-if="info.status == 6">
+ <view class="h1">璁垮涓嬪彂澶辫触</view>
+ <view class="h2">鎮ㄧ殑鏉ヨ鐢宠宸插け鏁堬紝璇烽噸鏂扮敵璇�</view>
+ </view>
<view class="box_list">
<view class="box_list_label">鎷滆淇℃伅</view>
- <view class="box_list_tips" v-if="info.status == 6 || info.status == 3"
+ <!-- <view class="box_list_tips" v-if="info.status == 6 || info.status == 3"
>璇锋敞鎰忔煡鐪嬪嚭鍏ラ棬绂佷笅鍙戞儏鍐碉紝濡傝嫢涓嬪彂澶辫触闇�閲嶆柊鐢宠</view
- >
+ > -->
<view class="box_list_item">
<view class="box_list_item_label">琚浜哄憳锛�</view>
<view class="box_list_item_val"
@@ -48,37 +72,69 @@
</view>
<view class="box_list_item">
<view class="box_list_item_label">鏂藉伐浜哄憳锛�</view>
- <view class="box_list_item_val">{{ info.type == 0 ? '鍚�' : '鏄�'}}</view>
+ <view class="box_list_item_val">{{
+ info.type == 0 ? "鍚�" : "鏄�"
+ }}</view>
</view>
- <view class="box_list_item" v-if="info.type == '1'">
+ <view class="box_list_item" v-if="info.type == '1'">
<view class="box_list_item_label">鏂藉伐鍐呭锛�</view>
- <view class="box_list_item_val">{{ info.constructionReason}}</view>
+ <view class="box_list_item_val">{{ info.constructionReason }}</view>
</view>
<view class="box_list_item">
<view class="box_list_item_label">闅忚杞﹁締锛�</view>
<view class="box_list_item_val">{{ info.carNos }}</view>
</view>
</view>
+ <view class="padding_wrap">
+ <view class="btn" v-if="[0,1,2,5].includes(info.status)" @click="cancelShow = true">鍙栨秷棰勭害</view>
+ </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>
<script>
import wxcode from 'uniapp-qrcode'
-import { getVisitedDetail } from '@/api'
+import { getVisitedDetail, visitsSelfCancel } from '@/api'
export default {
data() {
return {
+ id: null,
info: {},
- show: false
+ show: false,
+ detail: '',
+ cancelShow: false
}
},
+ onBackPress(options) {
+ if (this.detail == 1) {
+ uni.redirectTo({
+ url: '/pages/applicationRecord/applicationRecord'
+ })
+ } else {
+ uni.redirectTo({
+ url: '/pages/index/index'
+ })
+ }
+
+ return true
+ },
onLoad(option) {
+ uni.setStorageSync('ywinfo',{})
+ this.detail = option.detail || ''
+ this.id = option.id
this.getDetail(option.id)
// visitorSubDetail({ id: option.id })
// .then(res => {
@@ -94,6 +150,14 @@
},
methods: {
+ // 鍙栨秷棰勭害
+ cancel() {
+ const member = uni.getStorageSync('member');
+ visitsSelfCancel(this.id, this.$store.state.openId).then(res => {
+ this.cancelShow = false
+ this.getDetail(this.id)
+ })
+ },
close() {
this.show = false
},
@@ -128,6 +192,28 @@
<style lang="scss" scoped>
.box {
width: 100%;
+ .padding_wrap {
+ position: fixed;
+ z-index: 999;
+ padding: 0 30rpx 64rpx;
+ bottom: 0;
+ left: 0;
+ width: 100%;
+ display: flex;
+ justify-content: space-between;
+
+ .btn {
+ height: 96rpx;
+ line-height: 96rpx;
+ text-align: center;
+ width: 100%;
+ font-size: 36rpx;
+ color: #333333;
+ background: #ffffff;
+ border-radius: 48rpx;
+ border: 1rpx solid #999999;
+ }
+ }
.qrocde {
width: 300rpx;
height: 300rpx;
@@ -145,7 +231,7 @@
.box_head_qrcode {
width: 320rpx;
height: 320rpx;
- margin: 20rpx auto;
+ margin: 20rpx auto;
}
.text {
font-size: 30rpx;
@@ -175,6 +261,10 @@
color: #ffffff;
}
}
+ .head_gray{
+ background-color: #666666;
+ color: #fff;
+ }
.head_error {
background: #fdeded;
.h1 {
@@ -214,7 +304,7 @@
}
.box_list_label {
font-size: 32rpx;
- font-weight: 500;
+ font-weight: 600;
color: #222222;
}
.box_list_item {
--
Gitblit v1.9.3