From 0aef05d81135e422183985ac767f047cd5c5fdda Mon Sep 17 00:00:00 2001
From: liukangdong <898885815@qq.com>
Date: 星期三, 05 三月 2025 15:08:23 +0800
Subject: [PATCH] ll
---
h5/pages/staff/vehicle/sendACarDetail.vue | 238 ++++++++++++++++++++++++++++++-----------------------------
1 files changed, 120 insertions(+), 118 deletions(-)
diff --git a/h5/pages/staff/vehicle/sendACarDetail.vue b/h5/pages/staff/vehicle/sendACarDetail.vue
index 07bed90..10bc94a 100644
--- a/h5/pages/staff/vehicle/sendACarDetail.vue
+++ b/h5/pages/staff/vehicle/sendACarDetail.vue
@@ -1,20 +1,16 @@
<template>
<view class="main_app">
- <view class="status_wrap">
- <view class="name">{{ info.createMemberName }}鎻愪氦鐨勭敤杞︾敵璇�</view>
- <view
- class="desc"
- :class="{
- gray: info.status == '2' || info.status == '3' || info.status == '4',
- }"
- >{{ infoStatus }}</view
- >
- <view v-if="info.status == '0' || info.status == '1'" class="status">{{
- statusMap[info.status]
- }}</view>
- <image v-if="info.status == '2'" src="@/static/ic_passed@2x.png" mode="widthFix" class="status_img"></image>
- <image v-if="info.status == '3' || info.status == '6'" src="@/static/ic_refused@2x.png" mode="widthFix"
- class="status_img"></image>
+ <view class="status_wrap">
+ <view class="name">{{ info.createMemberName || info.creatorName || info.memberName}}鎻愪氦鐨勭敤杞︾敵璇�</view>
+ <view class="desc gray">{{ info.companyName }}</view>
+ <view class="desc" style="margin-top: 16rpx;" v-if="info.status == 0">澶勭悊涓�</view>
+ <view v-if="info.status == '0' || info.status == '1'" class="status">{{
+ statusMap[info.status]
+ }}</view>
+ <image v-if="info.status == '2'" src="@/static/ic_passed@2x.png" mode="widthFix" class="status_img"></image>
+ <image v-if="info.status == '4'" src="@/static/ic_cancel.png" mode="widthFix" class="status_img"></image>
+ <image v-if="info.status == '3' || info.status == '6'" src="@/static/ic_refused@2x.png" mode="widthFix"
+ class="status_img"></image>
</view>
<!-- -->
<view class="emyty"></view>
@@ -45,57 +41,57 @@
<view class="label">杞﹁締淇℃伅</view>
<view class="value">{{ info.carCode }}</view>
</view>
- <view class="item">
+ <view class="item" v-if="info.driverName">
<view class="label">鍙告満淇℃伅</view>
- <view class="value">{{ info.driverName }} {{ info.driverPhone }}</view>
+ <view class="value">{{ info.driverName }} {{ info.driverPhone || '' }}</view>
</view>
</view>
<!-- 娴佺▼ -->
<view class="flow_wrap">
<view class="flow_title">娴佺▼</view>
- <view class="list" v-if="
- info.approveDateVO != null && info.approveDateVO.approveList != null
- ">
- <view class="item" v-for="(item, index) in info.approveDateVO.approveList" :key="item.id">
- <view class="separate"></view>
- <view class="avatar">
- <image v-if="item.type == 1" class="img" src="@/static/staff/ic_chaosong@2x.png" />
- <image v-else-if="item.approveType == 1 || item.approveType == 0" class="img"
- src="@/static/staff/ic_shenpiren@2x.png" />
- <image v-else-if="item.faceImg" :src="item.faceImg" class="img"></image>
- <span v-else class="img_name">{{item.memberName && item.memberName.slice(0,1)}}</span>
- <image v-if="item.status == 2" class="status" src="@/static/staff/liucheng_success@2x.png"
- mode="widthFix" />
- <image v-if="item.status == 3" class="status" src="@/static/staff/liucheng_fail@2x.png" mode="widthFix" />
- </view>
- <view class="content">
- <view class="head">
- <view class="event">{{ item.title }}</view>
- <view class="time">{{ item.checkDate }}</view>
- </view>
- <view class="name_wrap">
- <text>{{ item.memberName
- }}<text :class="{ status: item.statusInfo == '澶勭悊涓�' || item.status == '1' }"
- v-if="item.statusInfo">({{ item.statusInfo }})</text></text>
- </view>
- <view v-if="item.checkInfo" class="remark">{{
- item.checkInfo
- }}</view>
- <!-- 鎶勯�佷汉 -->
- <view v-if="item.approveType == 0 || item.type == 1 || item.approveType == 1" class="children">
- <view class="child" v-for="child in item.approveList" :key="child.id">
- <image v-if="child.faceImg" class="child_img" :src="child.faceImg" />
- <view v-else class="child_name">{{ child.memberName && child.memberName.slice(0,1) }}</view>
- <view>{{ child.memberName }}</view>
- </view>
- </view>
- </view>
- </view>
+ <view class="list" v-if="
+ info.approveDateVO != null && info.approveDateVO.approveList != null
+ ">
+ <view class="item" v-for="(item, index) in info.approveDateVO.approveList" :key="item.id">
+ <view class="separate"></view>
+ <view class="avatar">
+ <image v-if="item.type == 1" class="img" src="@/static/staff/ic_chaosong@2x.png" />
+ <image v-else-if="item.approveType == 1 || item.approveType == 0" class="img"
+ src="@/static/staff/ic_shenpiren@2x.png" />
+ <image v-else-if="item.faceImg" :src="item.faceImg" class="img"></image>
+ <span v-else class="img_name">{{item.memberName && item.memberName.slice(0,1)}}</span>
+ <image v-if="item.status == 2" class="status" src="@/static/staff/liucheng_success@2x.png"
+ mode="widthFix" />
+ <image v-if="item.status == 3" class="status" src="@/static/staff/liucheng_fail@2x.png" mode="widthFix" />
+ </view>
+ <view class="content">
+ <view class="head">
+ <view class="event">{{ item.title }}</view>
+ <view class="time">{{ item.checkDate }}</view>
+ </view>
+ <view class="name_wrap">
+ <text>{{ item.memberName
+ }}<text :class="{ status: item.statusInfo == '澶勭悊涓�' || item.status == '1' }"
+ v-if="item.statusInfo">({{ item.statusInfo }})</text></text>
+ </view>
+ <view v-if="item.checkInfo" class="remark">{{
+ item.checkInfo
+ }}</view>
+ <!-- 鎶勯�佷汉 -->
+ <view v-if="item.approveType == 0 || item.type == 1 || item.approveType == 1" class="children">
+ <view class="child" v-for="child in item.approveList" :key="child.id">
+ <image v-if="child.faceImg" class="child_img" :src="child.faceImg" />
+ <view v-else class="child_name">{{ child.memberName && child.memberName.slice(0,1) }}</view>
+ <view>{{ child.memberName }}</view>
+ </view>
+ </view>
+ </view>
+ </view>
</view>
</view>
<view class="emyty"></view>
<view class="main_footer" v-if="
- info.approveDateVO != null &&
+ info.approveDateVO &&
info.approveDateVO.canBeApproved != null &&
info.approveDateVO.canBeApproved == 1
">
@@ -103,13 +99,14 @@
<view class="btn" @click="handleSub(3)">鎷掔粷</view>
<view class="btn agree" @click="handleSub(2)">鍚屾剰</view>
</template>
- </view>
- <template v-else>
- <view v-if="(info.approveDateVO.canBeApproved == 1 || userInfo.memberId == info.memberId) && info.status == 0" class="main_footer" @click="isShowBack = true">
- <view class="agree btn">鎾ゅ洖鐢ㄨ溅</view>
- </view>
- </template>
-
+ </view>
+ <template v-else>
+ <view v-if="info.approveDateVO && (info.approveDateVO.canBeApproved == 1 || userInfo.memberId == info.memberId) && info.status == 0"
+ class="main_footer" @click="isShowBack = true">
+ <view class="agree btn">鎾ゅ洖鐢ㄨ溅</view>
+ </view>
+ </template>
+
<!-- 鎾ら攢 -->
<u-popup :show="isShowBack" :round="10" :safeAreaInsetBottom="true" mode="bottom" @close="isShowBack = false">
@@ -126,10 +123,11 @@
<u-popup :show="showApprModal" :round="10" :safeAreaInsetBottom="true" mode="bottom" @close="showApprModal = false">
<view class="appr_modal">
<view class="title">{{ param.status == 2 ? "鍚屾剰" : "鎷掔粷" }}</view>
- <view v-if="param.status == 2" class="line" @click="isShowDrive = true">
- <text v-if="param.driverName">{{ param.driverName }}</text>
+ <view v-if="param.status == 2" class="line" @click="openModal">
+ <text :class="{placeholder9: info.approveDateVO.driverParam == 0}"
+ v-if="param.driverName">{{ param.driverName }}</text>
<text v-else class="placeholder9">娲捐溅鍙告満</text>
- <u-icon class="ml12" name="arrow-right" color="#999999" />
+ <u-icon v-if="info.approveDateVO.driverParam == 1" class="ml12" name="arrow-right" color="#999999" />
</view>
<textarea v-model="param.checkInfo" :placeholder="
param.status == 2 ? '鍚屾剰璇存槑锛岄潪蹇呭~' : '鎷掔粷璇存槑锛屽繀濉�'
@@ -159,11 +157,10 @@
showApprModal: false,
isShowBack: false,
backParam: {},
- isShowDrive: false,
+ isShowDrive: false,
userInfo: uni.getStorageSync('userInfo') || {},
id: '',
appr: '',
- infoStatus: '',
info: {},
param: {
status: ''
@@ -181,8 +178,7 @@
},
onLoad(option) {
this.id = option.id
- this.appr = option.appr || ''
- this.infoStatus = option.info
+ this.appr = 1
this.getDetail()
},
methods: {
@@ -207,6 +203,11 @@
})
}
})
+ },
+ openModal() {
+ if (this.info.approveDateVO.driverParam == 0) return
+ this.isShowDrive = true
+
},
onSubBack() {
carUseBookBack({
@@ -260,20 +261,20 @@
this.getDriveList()
} else {
- }
- if(this.info.driverId && this.info.driverName){
- this.$set(this.param, 'driverId', this.info.driverId)
- this.$set(this.param, 'driverName', this.info.driverName)
+ }
+ if (this.info.driverId && this.info.driverName) {
+ this.$set(this.param, 'driverId', this.info.driverId)
+ this.$set(this.param, 'driverName', this.info.driverName)
}
this.showApprModal = true
},
getDriveList() {
- driveListPost({}).then(res => {
+ driveListPost({}).then(res => {
const temp = res.data || []
- this.driveList = [res.data]
- if(this.param.driverId){
- const item = temp.find(i=>i.id == this.param.driverId)
- this.$set(this.param, 'driverName', item.name)
+ this.driveList = [res.data]
+ if (this.param.driverId) {
+ const item = temp.find(i => i.id == this.param.driverId)
+ this.$set(this.param, 'driverName', item.name)
}
})
},
@@ -500,45 +501,46 @@
}
}
- .status_wrap {
- position: relative;
- padding: 30rpx 0;
-
- .name {
- font-weight: 600;
- font-size: 32rpx;
- margin-bottom: 20rpx;
- color: #222222;
- }
-
- .desc {
- font-size: 26rpx;
- color: #ed4545;
- }
-
- .gray {
- color: #999999;
- }
-
- .status {
- position: absolute;
- right: -30rpx;
- top: 0;
- height: 60rpx;
- line-height: 60rpx;
- padding: 0 32rpx;
- border-radius: 0rpx 0rpx 0rpx 30rpx;
- background-color: #e9edff;
- color: $uni-color-primary;
- }
-
- .status_img {
- position: absolute;
- right: 0rpx;
- top: 20rpx;
- width: 120rpx;
- }
- }
+ .status_wrap {
+ position: relative;
+ padding: 30rpx 0;
+
+ .name {
+ font-weight: 600;
+ font-size: 32rpx;
+ margin-bottom: 20rpx;
+ color: #222222;
+ }
+
+ .desc {
+ font-size: 26rpx;
+ color: #ed4545;
+ }
+
+ .gray {
+ color: #999999;
+ }
+
+ .status {
+ position: absolute;
+ right: -30rpx;
+ top: 0;
+ height: 60rpx;
+ line-height: 60rpx;
+ padding: 0 32rpx;
+ border-radius: 0rpx 0rpx 0rpx 30rpx;
+ background-color: #e9edff;
+ color: $uni-color-primary;
+ }
+
+ .status_img {
+ position: absolute;
+ right: 0rpx;
+ top: 20rpx;
+ width: 120rpx;
+ }
+ }
+
.main_footer {
padding-bottom: 64rpx;
display: flex;
--
Gitblit v1.9.3