From 47c3668aaab9d5f772c7d7e317d2bfa4b1cbeb28 Mon Sep 17 00:00:00 2001
From: qingyiay <2386314947@qq.com>
Date: 星期一, 25 九月 2023 17:49:45 +0800
Subject: [PATCH] 修改首页数据不刷新 超出预约时间提示
---
pages/driver-page/driver-index/driver-index.vue | 109 ++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 104 insertions(+), 5 deletions(-)
diff --git a/pages/driver-page/driver-index/driver-index.vue b/pages/driver-page/driver-index/driver-index.vue
index b00d209..95d9614 100644
--- a/pages/driver-page/driver-index/driver-index.vue
+++ b/pages/driver-page/driver-index/driver-index.vue
@@ -6,6 +6,25 @@
<view class="wait-collection"
style="background: url('https://mx.jzeg.cn:9095/appimg/image/banner/diverbanner.png') no-repeat;background-size:contain">
</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"
v-for="(item, index) in driverBillOfLoadingData.list1"
@@ -79,6 +98,7 @@
<combined-title title="寰呴绾︽彁鐓ゅ崟"></combined-title>
<u-empty mode="data"
icon="http://cdn.uviewui.com/uview/empty/data.png"
+ text="鏆傛棤鏁版嵁"
textSize="30"
iconSize="1000"
v-if="driverBillOfLoadingData.list3 ? (driverBillOfLoadingData.list3.length == 0 ? true : false) : true"></u-empty>
@@ -154,6 +174,7 @@
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"
@@ -218,6 +239,12 @@
</view>
</view>
<view class="white-block"></view>
+ <!-- 鍥剧墖棰勮寮瑰嚭妗� -->
+ <view class="previewImage-container">
+ <previewImage ref="previewImage"
+ :imgs="driverTourImgList"
+ :saveBtn='false'></previewImage>
+ </view>
</view>
</view>
</view>
@@ -227,10 +254,13 @@
<script>
import { customerId } from '@/utils/status';
import combinedTitle from '@/components/combined-title/combined-title.vue';
-
+ import previewImage from '@/components/kxj-previewImage/kxj-previewImage.vue';
+ import { mapState } from 'vuex'
+ import { BaseUrl } from '@/api/publicInterface.js'
export default {
components: {
- combinedTitle
+ combinedTitle,
+ previewImage
},
props: {
indexdriverBillOfLoadingData: {
@@ -247,6 +277,12 @@
immediate: true
}
},
+ computed: {
+ ...mapState(['driverTourImgList']),
+ roleType() {
+ return uni.getStorageSync('roleType');
+ },
+ },
data() {
return {
driverBillOfLoadingData: {
@@ -261,7 +297,9 @@
qiangDanOrderPlanId: null,
fleetId: '',
xsUserId: '',
- customerId: ''
+ customerId: '',
+ isFirstLogin: true, //鏄惁鏄涓�娆$櫥褰�
+ phone: ""
};
},
onShow() {
@@ -278,6 +316,7 @@
},
init() {
this.qiangDanList();
+ this.getLogOn()
},
// 鍙告満棣栭〉鍒楄〃
qiangDanList() {
@@ -335,7 +374,7 @@
},
list3CardIconClick(value) {
uni.navigateTo({
- url: `/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details?orderPlanId=${value.id}&yyId=${value.yyId}`
+ url: `/pages/driver-page/driver-index/bill-of-lading-details/bill-of-lading-details?orderPlanId=${value.id}&yyId=${value.yyId}&orderType=${value.orderType}`
});
},
// 鎻愮叅鍗曡鎯�
@@ -349,7 +388,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:9096/appimg/image/tour/driver/sj1.png')
+ },
+ 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>
@@ -717,11 +778,22 @@
color: #ffffff;
margin-right: vww(20);
}
+
+ .filedname {
+ width: 80%;
+ }
+ }
+
+ .map-icon {
+ position: absolute;
+ right: vww(-1);
+ top: vww(2)
}
}
.first-extra {
@include firstLine;
+ position: relative;
.main-information {
width: 100%;
@@ -742,6 +814,16 @@
color: #ffffff;
margin-right: vww(20);
}
+
+ .filedname {
+ width: 80%;
+ }
+ }
+
+ .map-icon {
+ position: absolute;
+ right: vww(-1);
+ top: vww(2)
}
}
@@ -749,6 +831,7 @@
@include firstLine;
margin: 0;
margin-left: vww(16);
+ position: relative;
.main-information {
width: 100%;
@@ -769,6 +852,16 @@
color: #ffffff;
margin-right: vww(20);
}
+
+ .filedname {
+ width: 80%;
+ }
+ }
+
+ .map-icon {
+ position: absolute;
+ right: vww(-1);
+ top: vww(2)
}
}
@@ -833,6 +926,12 @@
margin-top: vww(10);
}
}
+
+ .noob-tour {
+ margin-bottom: vww(10);
+ position: relative;
+ top: -240rpx;
+ }
}
}
</style>
\ No newline at end of file
--
Gitblit v1.9.1