From a71f34e6888abdf106b6d20e125eb4569a63b3f0 Mon Sep 17 00:00:00 2001 From: yangan <yangan0921@163.com> Date: 星期一, 13 十一月 2023 17:27:58 +0800 Subject: [PATCH] 修改签到页面传参,称重页面样式 --- pages/driver-page/driver-index/driver-index.vue | 175 +++++++++++++++++++++++++++++++++++++++++++++++++-------- 1 files changed, 149 insertions(+), 26 deletions(-) diff --git a/pages/driver-page/driver-index/driver-index.vue b/pages/driver-page/driver-index/driver-index.vue index b00d209..6cedf3a 100644 --- a/pages/driver-page/driver-index/driver-index.vue +++ b/pages/driver-page/driver-index/driver-index.vue @@ -2,9 +2,28 @@ <view class=""> <view class="driver-index"> <view class="driver-index-body"> - <!-- 寰呴鍙栨彁鐓ゅ崟 --> + <!-- 寰呴鍙栭�氱煡鍗� --> <view class="wait-collection" - style="background: url('https://mx.jzeg.cn:9095/appimg/image/banner/diverbanner.png') no-repeat;background-size:contain"> + :style="{ backgroundImage: `url(${onlineurl}/appimg/image/banner/diverbanner.png)`, backgroundSize: 'contain', backgroundRepeat: 'no-repeat' }"> + </view> + <!-- 寮曞椤� --> + <view class="noob-tour" + v-if="roleType===3&&isFirstLogin"> + <combined-title title="鎿嶄綔鎸囧紩"></combined-title> + <u-cell-group> + <u-cell title="鏂版墜鎸囧紩" + name='1' + :clickable="true" + @click="noobTour"> + <u-badge type="primary" + value="01" + slot='icon'></u-badge> + <u-icon slot="value" + name="arrow-right" + size="30" + color="#b8b8b8"></u-icon> + </u-cell> + </u-cell-group> </view> <view class="collection-form"> <view class="collection-form-item" @@ -45,9 +64,6 @@ </view> </view> </view> - <!-- <view class="second-line"> - <view class="coal-name">{{ item.coalName }}</view> - </view> --> <view class="third-line"> <view class="time-icon"><u-icon name="clock" color="#515151" @@ -58,7 +74,7 @@ </view> </view> <view class="fourth-line" - @click="qiangDanBtn(item)" + @click.stop="qiangDanBtn(item)" v-if="item.carNum - item.taskNum !== 0"> <view class="button-img">绔嬪嵆鎶㈠崟</view> </view> @@ -74,20 +90,25 @@ @cancel="qiangDanCancel"></u-modal> </view> - <!-- 寰呴绾︽彁鐓ゅ崟 --> + <!-- 寰呴绾﹂�氱煡鍗� --> <view class="wait-appointment"> - <combined-title title="寰呴绾︽彁鐓ゅ崟"></combined-title> + <combined-title title="寰呴绾﹂�氱煡鍗�"></combined-title> <u-empty mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png" textSize="30" iconSize="1000" + text="鏆傛棤鏁版嵁" v-if="driverBillOfLoadingData.list3 ? (driverBillOfLoadingData.list3.length == 0 ? true : false) : true"></u-empty> <view class="appointment-form"> <view class="appointment-form-item" v-for="(item, index) in driverBillOfLoadingData.list3" - :key="index"> + :key="index" + @click.stop="list3CardIconClick(item)" + > + <view class="main-divider"></view> + <view class="orderCode">璁㈠崟鍙凤細{{ item.orderCode }}</view> <view class="first-line"> <view class="main-information"> <view class="sign">瑁�</view> @@ -127,6 +148,11 @@ size="40"></u-icon></view> </view> </view> + <!-- <view class="status"> + <u-tag :text="coalStatus[item.statusWeigh] || ''" + plain> + </u-tag> + </view> --> <view class="third-line"> <view class="clock"> <view class="time-icon"><u-icon name="clock" @@ -140,20 +166,21 @@ </view> </view> <view class="fourth-line" - @click="toAppointmentClick(item)"> + @click.stop="toAppointmentClick(item)"> <view class="button-img">绔嬪嵆棰勭害</view> </view> </view> </view> </view> - <!-- 宸查绾︽彁鐓ゅ崟 --> + <!-- 宸查绾﹂�氱煡鍗� --> <view class="Reserved"> - <combined-title title="宸查绾︽彁鐓ゅ崟"></combined-title> + <combined-title title="宸查绾﹂�氱煡鍗�"></combined-title> <u-empty mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png" textSize="30" iconSize="1000" + text="鏆傛棤鏁版嵁" v-if="driverBillOfLoadingData.list2 ? (driverBillOfLoadingData.list2.length == 0 ? true : false) : true"></u-empty> <view class="appointment-form"> <view class="appointment-form-item" @@ -161,6 +188,7 @@ :key="index" @click="list3CardIconClick(item)"> <view class="main-divider"></view> + <view class="orderCode">璁㈠崟鍙凤細{{ item.orderCode }}</view> <view class="first-line"> <view class="main-information"> <view class="sign">瑁�</view> @@ -203,6 +231,11 @@ size="40"></u-icon></view> </view> </view> + <view class="status"> + <u-tag :text="coalStatus[item.statusWeigh] || ''" + plain> + </u-tag> + </view> <view class="third-line"> <view class="clock havedclock"> <view class="time-icon"><u-icon name="clock" @@ -219,6 +252,12 @@ </view> <view class="white-block"></view> </view> + <!-- 鍥剧墖棰勮寮瑰嚭妗� --> + <view class="previewImage-container"> + <previewImage ref="previewImage" + :imgs="driverTourImgList" + :saveBtn='false'></previewImage> + </view> </view> </view> </view> @@ -227,10 +266,15 @@ <script> import { customerId } from '@/utils/status'; import combinedTitle from '@/components/combined-title/combined-title.vue'; - + import { onlineurl } from '@/api/request.js' + import { BaseUrl } from '@/api/publicInterface.js' + import previewImage from '@/components/kxj-previewImage/kxj-previewImage.vue'; + import { mapState } from 'vuex'; + import { Debounce } from '../../../utils/util'; export default { components: { - combinedTitle + combinedTitle, + previewImage }, props: { indexdriverBillOfLoadingData: { @@ -245,7 +289,13 @@ }, deep: true, immediate: true - } + }, + }, + computed: { + ...mapState(['driverTourImgList']), + roleType() { + return uni.getStorageSync('roleType'); + }, }, data() { return { @@ -261,8 +311,17 @@ qiangDanOrderPlanId: null, fleetId: '', xsUserId: '', - customerId: '' + customerId: '', + coalStatus: ['鏈О閲�', '绉伴噸涓�', '楠岃川涓�', '绉伴噸瀹屾垚', '澶勭悊瀹屾垚'], + onlineurl, + phone: "", + isFirstLogin: true //鏄惁鏄涓�娆$櫥褰� }; + }, + mounted() { + // this.TourImgList = TourImgList + this.getLogOn() + }, onShow() { this.init(); @@ -290,7 +349,7 @@ }); }, // 鎶㈠崟鎸夐挳 - qiangDanBtn(value) { + qiangDanBtn:Debounce(function(value){ if (value.tmcCount == '0') { this.qiangDan(value.orderPlanId, value.fleetId, value.customerId === null ? '0' : value.customerId, value.xsUserId === null ? '0' : value.xsUserId); @@ -302,7 +361,9 @@ this.qiangDanShow = true; this.qiangDanContent = `宸叉姠${value.tmcCount}鍗曪紝纭畾鎶㈠崟锛焋; } - }, + } ,500) + + , // 鎶㈠崟妯℃�佹 qiangDanConfirm() { this.qiangDanContent = ''; @@ -338,7 +399,7 @@ url: `/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details?orderPlanId=${value.id}&yyId=${value.yyId}` }); }, - // 鎻愮叅鍗曡鎯� + // 閫氱煡鍗曡鎯� cardBodyClick(name) { uni.navigateTo({ url: `/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details?orderPlanId=${name}` @@ -349,7 +410,29 @@ uni.navigateTo({ url: `/pages/driver-page/appointment/appointment?takeCoalId=${value.id}&filedId=${value.filedId}&deptId=${value.deptId}&sendDate=${value.sendDate}` }); - } + }, + noobTour() { + this.$refs.previewImage.open('https://mx.jzeg.cn:9095/appimg/image/tour/driver/sj1.jpg') + }, + getLogOn() { + this.$reqGet('getUserEntity').then(res => { + this.phone = res.data.phone + }).then(() => { + uni.request({ + url: `${BaseUrl}/admin/log/getLogOnType?phone=${this.phone}`, + success: res => { + // res.data.data 涓�1 浠h〃绗竴娆$櫥褰� 涓�0鍙栨秷瀛︿範鎸囧紩 涓�2 浠h〃瀛樺湪 + if (res.data.data === 1) { + this.noobTour() + } else if (res.data.data === 2) { + this.isFirstLogin = true + } else { + this.isFirstLogin = false + } + } + }); + }) + }, } }; </script> @@ -433,6 +516,16 @@ } } + .fade-enter-active, + .fade-leave-active { + transition: opacity 0.5s; + } + + .fade-enter, + .fade-leave-to { + opacity: 0; + } + .exceedHide { white-space: nowrap; overflow: hidden; @@ -447,7 +540,7 @@ .driver-index-body { // margin-bottom: vww(56); - // 寰呴鍙栨彁鐓ゅ崟 + // 寰呴鍙栭�氱煡鍗� .wait-collection { width: 100%; height: 600rpx; @@ -461,7 +554,7 @@ .collection-form-item { width: vww(345); - height: vww(185); + height: vww(195); margin-top: vww(5); background: #ffffff; box-shadow: 4rpx 6rpx 25rpx 0rpx rgba(73, 120, 240, 0.15); @@ -561,8 +654,9 @@ align-items: center; .coal-name { + @include flex; min-width: vww(50); - height: 35rpx; + height: 100%; font-size: 30rpx; font-weight: 300; color: #515151; @@ -681,17 +775,19 @@ .appointment-form-item { @include formItem; - height: vww(191); + height: vww(240); justify-content: space-between; overflow: hidden; - .main-divider { width: 560rpx; height: 1rpx; background: #e3e3e3; position: absolute; - top: 122rpx; + top: 200rpx; left: 128rpx; + } + .orderCode{ + padding: 10px; } .first-line { @@ -772,6 +868,10 @@ } } + .status { + @include thirdLine; + } + .third-line { @include thirdLine; width: 94%; @@ -833,6 +933,29 @@ margin-top: vww(10); } } + + .noob-tour { + margin-bottom: vww(10); + position: relative; + top: -240rpx; + } + + .u-popup { + .u-transition { + .u-popup__content { + .editDriverPopup-container-box {} + + //closeIcon + .u-popup__content__close--top-right { + .u-icon { + .u-icon__icon { + font-size: vww(20) !important; + } + } + } + } + } + } } } </style> \ No newline at end of file -- Gitblit v1.9.1