From 3a992a2be8c1cc815719ac76cd7242dd7a2f7c2d Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期二, 27 八月 2024 17:33:27 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
server/system_service/src/main/java/com/doumee/core/utils/Constants.java | 15
h5/main.js | 7
h5/api/driver.js | 75 +
h5/pages/driver/reservedGuide.vue | 10
h5/pages/driver/forgetPsd.vue | 241 +++++
h5/pages/driver/reserved.vue | 184 ++-
h5/.gitignore | 1
h5/store/index.js | 7
server/system_service/src/main/java/com/doumee/core/model/LoginUserInfo.java | 13
h5/pages/staff/task/visitorApprove.vue | 7
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/ApproveServiceImpl.java | 62 +
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java | 205 ++++
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitReasonServiceImpl.java | 4
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformGroupServiceImpl.java | 12
h5/pages/staff/task/driver.vue | 445 ++++++++++
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformBooksServiceImpl.java | 62 +
server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java | 39
server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformBooks.java | 4
h5/pages/driver/register.vue | 11
server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/response/DriverHomeVO.java | 7
h5/pages.json | 18
h5/api/index.js | 1
server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/dto/ApproveDTO.java | 2
server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformJob.java | 13
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/PlatformJobService.java | 12
server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/PdaPlatformController.java | 23
server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/Approve.java | 4
h5/pages/driver/index.vue | 616 +++++++------
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/MemberServiceImpl.java | 1
server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/reqeust/PlatformBooksApplyDTO.java | 2
h5/pages/driver/reservedDetail.vue | 216 ++--
server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/ApproveTempl.java | 4
server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/admin/PlatformCloudController.java | 13
server/system_service/src/main/java/com/doumee/core/utils/DateUtil.java | 19
server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/DriverPlatformController.java | 28
h5/pages/driver/taskDetail.vue | 2
h5/pages/staff/task/index.vue | 23
server/system_service/src/main/java/com/doumee/service/system/SystemLoginService.java | 1
h5/pages/driver/reservedRecord.vue | 95 +-
server/system_gateway/src/main/java/com/doumee/api/gateway/JwtAuthController.java | 19
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/ApproveService.java | 2
h5/App.vue | 3
h5/pages/driver/login.vue | 57
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformReasonServiceImpl.java | 1
44 files changed, 1,973 insertions(+), 613 deletions(-)
diff --git a/h5/.gitignore b/h5/.gitignore
index dc260c4..951e49c 100644
--- a/h5/.gitignore
+++ b/h5/.gitignore
@@ -1,6 +1,7 @@
.DS_Store
coderd.json
node_modules
+uni_modules
.env.development
uview-ui
diff --git a/h5/App.vue b/h5/App.vue
index 0d25d8c..fbec5c3 100644
--- a/h5/App.vue
+++ b/h5/App.vue
@@ -122,7 +122,7 @@
}
.placeholder9 {
- color: #999999;
+ color: #999999 !important;
font-size: 28rpx;
}
@@ -197,7 +197,6 @@
width: 64rpx;
height: 64rpx;
border-radius: 50%;
- overflow: hidden;
margin-right: 20rpx;
display: flex;
justify-content: center;
diff --git a/h5/api/driver.js b/h5/api/driver.js
new file mode 100644
index 0000000..5c9bd7f
--- /dev/null
+++ b/h5/api/driver.js
@@ -0,0 +1,75 @@
+import { http } from '@/utils/service.js'
+
+// 鍙告満娉ㄥ唽
+export const driverRegister = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/business/member/registerDriver',
+ method: 'post',
+ data
+ })
+}
+// 鍙告満鐧诲綍
+export const driverLogin = (data) => {
+ return http({
+ url: 'loginDriver',
+ method: 'post',
+ data
+ })
+}
+// 鍙告満棣栭〉
+export const driverHomeData = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/driverHome',
+ method: 'get',
+ data
+ })
+}
+
+// 鐗╂祦杞� 鍏ュ洯鍘熷洜
+export const driverReasonList = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/platformReasonList',
+ method: 'get',
+ data
+ })
+}
+// 鏌ヨ鍙绾﹂噺
+export const checkSurplusNum = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/checkSurplusNum',
+ method: 'post',
+ data
+ })
+}
+// 鐗╂祦杞﹂绾�
+export const driverCarApply = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/apply',
+ method: 'post',
+ data
+ })
+}
+// 鐗╂祦杞︽挙閿�
+export const driverCarRevoke= (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/revoke',
+ method: 'post',
+ data
+ })
+}
+// 棰勭害 璁板綍
+export const driverApplyRecord = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/page',
+ method: 'post',
+ data
+ })
+}
+// 棰勭害 璇︽儏
+export const driverApplyDetail = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/getDetail',
+ method: 'get',
+ data
+ })
+}
\ No newline at end of file
diff --git a/h5/api/index.js b/h5/api/index.js
index 3734784..e373597 100644
--- a/h5/api/index.js
+++ b/h5/api/index.js
@@ -3,6 +3,7 @@
export * from './visitor'
export * from './staff'
export * from './meeting'
+export * from './driver'
diff --git a/h5/main.js b/h5/main.js
index 4c90c6f..41c035c 100644
--- a/h5/main.js
+++ b/h5/main.js
@@ -17,6 +17,13 @@
Vue.prototype.$store = store
Vue.prototype.$jump = (url) => {uni.navigateTo({url})}
Vue.prototype.$goBack = () => { uni.navigateBack() }
+Vue.prototype.showToast = (str) => {
+ uni.showToast({
+ title: str,
+ icon: 'none',
+ duration: 2000
+ })
+}
Vue.prototype.$eventBus = new Vue()
Vue.prototype.$onWait = new Promise((resolve) => {
Vue.prototype.$reslove = resolve
diff --git a/h5/pages.json b/h5/pages.json
index a7a6648..3c94d9d 100644
--- a/h5/pages.json
+++ b/h5/pages.json
@@ -423,6 +423,24 @@
}
}
+ ,{
+ "path" : "pages/driver/forgetPsd",
+ "style" :
+ {
+ "navigationBarTitleText": "鎵惧洖瀵嗙爜",
+ "enablePullDownRefresh": false
+ }
+
+ }
+ ,{
+ "path" : "pages/staff/task/driver",
+ "style" :
+ {
+ "navigationBarTitleText": "鍏ュ洯瀹℃壒",
+ "enablePullDownRefresh": false
+ }
+
+ }
],
"subPackages": [
{
diff --git a/h5/pages/driver/forgetPsd.vue b/h5/pages/driver/forgetPsd.vue
new file mode 100644
index 0000000..7512424
--- /dev/null
+++ b/h5/pages/driver/forgetPsd.vue
@@ -0,0 +1,241 @@
+<template>
+ <view class="login">
+ <image class="login_bg" src="@/static/login_bg@2x.png" />
+ <image class="login_logo" src="@/static/logo@2x.png" mode="widthFix" />
+ <view class="login_title">瀹夋嘲鐗╂祦鏅烘収鍥尯</view>
+ <view class="login_title">鐗╂祦杞﹀徃鏈�</view>
+ <view class="login_list">
+ <view class="login_list_item">
+ <image src="@/static/login_ic_phone@2x.png" mode="widthFix" />
+ <input v-model="form.phone" maxlength="18" placeholder="璇疯緭鍏ユ墜鏈哄彿" />
+ </view>
+ <view class="login_list_item">
+ <image src="@/static/ic_captcha.png" mode="widthFix"></image>
+ <input
+ v-model="form.validCode"
+ placeholder="璇疯緭鍏ラ獙璇佺爜"
+ type="text"
+ />
+ <text class="captcha" v-if="countDown == 0" @click="initCaptcha"
+ >鑾峰彇楠岃瘉鐮�</text
+ >
+ <text class="placeholder9" v-else>{{ countDown }}</text>
+ </view>
+ <view class="login_list_item">
+ <image src="@/static/login_ic_password@2x.png" mode="widthFix" />
+ <input
+ v-model="form.password"
+ type="password"
+ placeholder="璇疯緭鍏ユ柊瀵嗙爜"
+ />
+ </view>
+ <view class="login_list_item">
+ <image src="@/static/login_ic_password@2x.png" mode="widthFix" />
+ <input
+ v-model="form.newPassword"
+ type="password"
+ placeholder="璇峰啀娆¤緭鍏ユ柊瀵嗙爜"
+ />
+ </view>
+ </view>
+ <view class="login_btn">
+ <view class="login_btn_n" @click="onLogin">纭淇敼</view>
+ </view>
+ </view>
+</template>
+
+<script>
+import { resetPassword, sendSms } from '@/api'
+export default {
+ data() {
+ return {
+ form: {
+ },
+ countDown: 0
+ }
+ },
+
+ onLoad() {
+ },
+
+ methods: {
+ dealChange(e) {
+ console.log(e)
+ },
+ initCaptcha() {
+ if (!this.form.phone) return uni.showToast({
+ title: '鎵嬫満鍙蜂笉鑳戒负绌�',
+ icon: 'none'
+ })
+ sendSms({ phone: this.form.phone }).then(res => {
+ this.countDown = 60
+ setInterval(() => {
+ if (this.countDown == 0) return
+ this.countDown--
+ }, 1000)
+ })
+ },
+
+ onLogin() {
+ const { form } = this
+ if (!form.phone) return uni.showToast({
+ title: '鎵嬫満鍙蜂笉鑳戒负绌�',
+ icon: 'none'
+ })
+ if (!form.validCode) return uni.showToast({
+ title: '楠岃瘉鐮佷笉鑳戒负绌�',
+ icon: 'none'
+ })
+ if (!form.password) return uni.showToast({
+ title: '鏂板瘑鐮佷笉鑳戒负绌�',
+ icon: 'none'
+ })
+ if (!form.newPassword) return uni.showToast({
+ title: '纭瀵嗙爜涓嶈兘涓虹┖',
+ icon: 'none'
+ })
+ if (form.password != form.newPassword) return uni.showToast({
+ title: '涓ゆ杈撳叆瀵嗙爜涓嶄竴鑷�',
+ icon: 'none'
+ })
+ resetPassword({
+ ...form
+ }).then(res => {
+ if (res && res.code == 200) {
+ setTimeout(() => {
+ uni.showToast({
+ title: '瀵嗙爜淇敼鎴愬姛,璇烽噸鏂扮櫥褰�',
+ icon: 'success',
+ duration: 2000
+ })
+ })
+ uni.redirectTo({
+ url: "/pages/staffLogin/login"
+ })
+ }
+ })
+ }
+ }
+}
+</script>
+
+<style lang="scss" scoped>
+.login {
+ width: 100%;
+ display: flex;
+ padding-top: 100rpx;
+ box-sizing: border-box;
+ align-items: center;
+ flex-direction: column;
+ background: linear-gradient(
+ 180deg,
+ rgba(39, 155, 170, 0.2) 0%,
+ rgba(39, 155, 170, 0) 100%
+ );
+ .login_logo {
+ width: 180rpx;
+ height: 180rpx;
+ margin-bottom: 40rpx;
+ }
+ .login_bg {
+ position: absolute;
+ top: 0;
+ width: 750rpx;
+ }
+ .login_title {
+ font-size: 44rpx;
+ font-weight: 600;
+ color: #333333;
+ }
+ .login_list {
+ margin-top: 60rpx;
+ width: 100%;
+ padding: 0 60rpx;
+ box-sizing: border-box;
+ .login_list_item {
+ width: 100%;
+ border-radius: 50rpx;
+ height: 98rpx;
+ padding: 0 40rpx;
+ box-sizing: border-box;
+ background: #ffffff;
+ margin-bottom: 40rpx;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ &:last-child {
+ margin-bottom: 0 !important;
+ }
+ image {
+ flex-shrink: 0;
+ width: 40rpx;
+ height: 40rpx;
+ }
+ .captcha {
+ color: $uni-color-primary;
+ }
+ input {
+ flex: 1;
+ height: 100%;
+ color: #666666;
+ margin-left: 24rpx;
+ border: none;
+ }
+ }
+ }
+ .login_btn {
+ width: 100%;
+ padding: 0 60rpx;
+ box-sizing: border-box;
+ margin-top: 80rpx;
+ .for_psd {
+ color: $uni-color-primary;
+ margin-top: 40rpx;
+ width: 140rpx;
+ text-align: center;
+ margin: 40rpx auto;
+ }
+ .login_btn_n {
+ width: 100%;
+ height: 98rpx;
+ background: $uni-color-primary;
+ box-shadow: 0rpx 12rpx 24rpx 0rpx rgba(39, 155, 170, 0.2);
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #ffffff;
+ border-radius: 50rpx;
+ }
+ }
+ .deal_wrap {
+ position: absolute;
+ width: 100%;
+ left: 0;
+ text-align: center;
+ bottom: 108rpx;
+ .deal {
+ color: $uni-color-primary;
+ }
+ }
+ .btns{
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ position: fixed;
+ bottom: 60rpx;
+ left: 0;
+ width: 100%;
+ .btn{
+ font-size: 30rpx;
+ color: $uni-color-primary;
+ }
+ .separate{ margin: 0 8rpx; }
+ }
+}
+.modal {
+ padding: 32rpx;
+}
+</style>
+
diff --git a/h5/pages/driver/index.vue b/h5/pages/driver/index.vue
index 42ee41e..2df909e 100644
--- a/h5/pages/driver/index.vue
+++ b/h5/pages/driver/index.vue
@@ -1,312 +1,346 @@
<template>
- <view class="main_app">
- <view class="title_wrap">
- <view class="name">鏌愭煇鏌愶紝娆㈣繋鐧诲綍锝�</view>
- <view class="btn" @click="loginOut">閫�鍑虹櫥褰�</view>
- </view>
- <!-- -->
- <view class="banner_wrap">
- <view class="h1">瀹夋嘲鐗╂祦鏅烘収鍥尯</view>
- <view class="h2">鐗╂祦杞︿笓鍖�</view>
- <image
- class="banner"
- src="../../static/driver/wuliuche_banner@2x.png"
- mode="widthFix"
- ></image>
- </view>
- <!-- -->
- <view class="task_list">
- <view class="item">
- <view class="head">
- <view class="name">杩愯緭鍗�222</view>
- <view class="status">
- <view class="text">璇风‘璁や换鍔�</view>
- <view class="time">棰勮绛夊緟锛�12灏忔椂</view>
- </view>
- </view>
- <view class="content">
- <view class="info">
- <view class="plate">
- <image
- src="@/static/driver/wuliu_ic_car@2x.png"
- class="icon"
- mode=""
- ></image>
- <text>鐨朅D</text>
- </view>
- <view class="plate">
- <image
- src="@/static/driver/wuliu_ic_huowu@2x.png"
- class="icon"
- mode=""
- ></image>
- <text>3000涓�</text>
- </view>
- </view>
- <view class="sub">
- <view class="time">02-01 08:11:11</view>
- <view class="sub_btn" @click="handleTask()">纭浠诲姟</view>
- </view>
- </view>
- </view>
- </view>
- <!-- -->
- <view class="title_wrap"><view class="name">涓氬姟鍔炵悊</view></view>
- <view class="container1">
- <view class="left">
- <view class="img_wrap img1" @click="$jump('/pages/driver/reserved')">
- <image
- src="@/static/driver/wuliu_ic_ruyuanyuyue@2x.png"
- class="img"
- ></image>
- <view class="h1">鍏ュ洯椤荤煡</view>
- <view class="h2">RESERVATION</view>
- </view>
- <view
- class="img_wrap img2"
- @click="$jump('/pages/driver/reservedGuide')"
- >
- <image
- src="@/static/driver/wuliu_ic_zhinan@2x.png"
- class="img"
- ></image>
- <view class="h1">棰勭害鎸囧崡</view>
- <view class="h2">APPOINTMENT GUIDE</view>
- </view>
- </view>
- <view class="right">
- <view
- class="img_wrap img2"
- @click="$jump('/pages/driver/reservedRecord')"
- >
- <image
- src="@/static/driver/wuliu_ic_yuyuejilu@2x.png"
- class="img"
- ></image>
- <view class="h1">棰勭害璁板綍</view>
- <view class="h2">APPOINTMENT RECORD</view>
- </view>
- <view class="img_wrap img2" @click="$jump('/pages/driver/queueUp')">
- <image
- src="@/static/driver/wuliu_ic_paidui@2x.png"
- class="img"
- ></image>
- <view class="h1">鏈堝彴鎺掗槦鎯呭喌</view>
- <view class="h2">HIDDEN DANGER</view>
- </view>
- <view class="img_wrap img2">
- <image
- src="@/static/driver/wuliu_ic_daolan@2x.png"
- class="img"
- ></image>
- <view class="h1">鍥尯瀵艰鍥�</view>
- <view class="h2">GUIDE MAP</view>
- </view>
- </view>
- </view>
- <!-- -->
- <view class="copyright">
- <image src="@/static/logo_s@2x.png" class="mr6" mode="widthFix" />
- <text>瀹夊窘瀹夋嘲鐗╂祦鏈夐檺璐d换鍏徃鐗堟潈鎵�鏈�</text>
- </view>
- </view>
+ <view class="main_app">
+ <view class="title_wrap">
+ <view class="name">{{ driverInfo.realname }}锛屾杩庣櫥褰曪綖</view>
+ <view class="btn" @click="loginOut">閫�鍑虹櫥褰�</view>
+ </view>
+ <!-- -->
+ <view class="banner_wrap">
+ <view class="h1">瀹夋嘲鐗╂祦鏅烘収鍥尯</view>
+ <view class="h2">鐗╂祦杞︿笓鍖�</view>
+ <image class="banner" src="../../static/driver/wuliuche_banner@2x.png" mode="widthFix"></image>
+ </view>
+ <!-- -->
+ <view class="task_list">
+ <swiper circular class="task_swiper">
+ <swiper-item>
+ <view class="item">
+ <view class="head">
+ <view class="name">杩愯緭鍗�222</view>
+ <view class="status">
+ <view class="text">璇风‘璁や换鍔�</view>
+ <view class="time">棰勮绛夊緟锛�12灏忔椂</view>
+ </view>
+ </view>
+ <view class="content">
+ <view class="info">
+ <view class="plate">
+ <image src="@/static/driver/wuliu_ic_car@2x.png" class="icon" mode=""></image>
+ <text>鐨朅D</text>
+ </view>
+ <view class="plate">
+ <image src="@/static/driver/wuliu_ic_huowu@2x.png" class="icon" mode=""></image>
+ <text>3000涓�</text>
+ </view>
+ </view>
+ <view class="sub">
+ <view class="time">02-01 08:11:11</view>
+ <view class="sub_btn" @click="handleTask()">纭浠诲姟</view>
+ </view>
+ </view>
+ </view>
+ </swiper-item>
+ <swiper-item>
+ <view class="item">
+ <view class="head">
+ <view class="name">杩愯緭鍗�222</view>
+ <view class="status"><view class="text">璇蜂笌鐜板満绛惧埌</view></view>
+ </view>
+ <view class="content">
+ <view class="info">
+ <view class="plate">
+ <image src="@/static/driver/wuliu_ic_car@2x.png" class="icon" mode=""></image>
+ <text>鐨朅D</text>
+ </view>
+ <view class="plate">
+ <image src="@/static/driver/wuliu_ic_huowu@2x.png" class="icon" mode=""></image>
+ <text>3000涓�</text>
+ </view>
+ </view>
+ <view class="sub">
+ <view class="time">02-01 08:11:11</view>
+ <view class="sub_btn" @click="handleTask(1)">绔嬪嵆绛惧埌</view>
+ </view>
+ </view>
+ </view>
+ </swiper-item>
+ </swiper>
+ </view>
+ <!-- -->
+ <view class="title_wrap"><view class="name">涓氬姟鍔炵悊</view></view>
+ <view class="container1">
+ <view class="left">
+ <view class="img_wrap img1" @click="$jump('/pages/driver/reserved')">
+ <image src="@/static/driver/wuliu_ic_ruyuanyuyue@2x.png" class="img"></image>
+ <view class="h1">鍏ュ洯椤荤煡</view>
+ <view class="h2">RESERVATION</view>
+ </view>
+ <view class="img_wrap img2" @click="$jump('/pages/driver/reservedGuide?str=bookingTips')">
+ <image src="@/static/driver/wuliu_ic_zhinan@2x.png" class="img"></image>
+ <view class="h1">棰勭害鎸囧崡</view>
+ <view class="h2">APPOINTMENT GUIDE</view>
+ </view>
+ </view>
+ <view class="right">
+ <view class="img_wrap img2" @click="$jump('/pages/driver/reservedRecord')">
+ <image src="@/static/driver/wuliu_ic_yuyuejilu@2x.png" class="img"></image>
+ <view class="h1">棰勭害璁板綍</view>
+ <view class="h2">APPOINTMENT RECORD</view>
+ </view>
+ <view class="img_wrap img2" @click="$jump('/pages/driver/queueUp')">
+ <image src="@/static/driver/wuliu_ic_paidui@2x.png" class="img"></image>
+ <view class="h1">鏈堝彴鎺掗槦鎯呭喌</view>
+ <view class="h2">HIDDEN DANGER</view>
+ </view>
+ <view class="img_wrap img2" @click="$jump('/pages/driver/reservedGuide?str=reservationMap')">
+ <image src="@/static/driver/wuliu_ic_daolan@2x.png" class="img"></image>
+ <view class="h1">鍥尯瀵艰鍥�</view>
+ <view class="h2">GUIDE MAP</view>
+ </view>
+ </view>
+ </view>
+ <!-- -->
+ <view class="copyright">
+ <image src="@/static/logo_s@2x.png" class="mr6" mode="widthFix" />
+ <text>瀹夊窘瀹夋嘲鐗╂祦鏈夐檺璐d换鍏徃鐗堟潈鎵�鏈�</text>
+ </view>
+ </view>
</template>
<script>
+import { logoutPost, driverHomeData } from '@/api';
export default {
- data() {
- return {
-
- }
- },
- methods: {
- handleTask() {
- uni.navigateTo({
- url: '/pages/driver/taskConfirm'
- })
- }
- }
-}
+ data() {
+ return {
+ driverInfo: uni.getStorageSync('driverInfo')
+ };
+ },
+ created() {
+ this.initData();
+ },
+ methods: {
+ initData() {
+ driverHomeData().then(res => {
+ if (res.code == 200) {
+ uni.setStorageSync('driverGuide', {
+ bookingTips: res.data.bookingTips,
+ reservationMap: res.data.reservationMap
+ });
+ }
+ });
+ },
+ loginOut() {
+ this.$store.commit('empty');
+ logoutPost();
+ uni.redirectTo({
+ url: '/pages/driver/login'
+ });
+ },
+ handleTask(status) {
+ if (status == 1) {
+ return uni.navigateTo({
+ url: '/pages/driver/taskDetail'
+ });
+ }
+ uni.navigateTo({
+ url: '/pages/driver/taskConfirm'
+ });
+ }
+ }
+};
</script>
<style lang="scss">
.title_wrap {
- display: flex;
- justify-content: space-between;
- align-items: center;
- margin-bottom: 24rpx;
- .name {
- font-weight: 600;
- font-size: 34rpx;
- color: #222222;
- }
- .btn {
- width: 144rpx;
- height: 56rpx;
- border-radius: 36rpx;
- border: 1rpx solid $uni-color-primary;
- font-size: 26rpx;
- color: $uni-color-primary;
- display: flex;
- justify-content: center;
- align-items: center;
- }
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ margin-bottom: 24rpx;
+ .name {
+ font-weight: 600;
+ font-size: 34rpx;
+ color: #222222;
+ }
+ .btn {
+ width: 144rpx;
+ height: 56rpx;
+ border-radius: 36rpx;
+ border: 1rpx solid $uni-color-primary;
+ font-size: 26rpx;
+ color: $uni-color-primary;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ }
}
.main_app {
- padding-top: 12rpx;
+ padding-top: 12rpx;
}
.banner_wrap {
- padding: 54rpx 44rpx;
- color: #fff;
- position: relative;
- width: 688rpx;
- height: 270rpx;
- margin-bottom: 40rpx;
- .h1 {
- font-weight: bold;
- line-height: 66rpx;
- font-size: 44rpx;
- margin-bottom: 14rpx;
- }
- .h2 {
- font-weight: 600;
- font-size: 28rpx;
- width: 192rpx;
- color: $uni-color-primary;
- height: 48rpx;
- line-height: 48rpx;
- text-align: center;
- background: #ffffff;
- box-shadow: 0rpx 4rpx 8rpx 0rpx rgba(39, 155, 170, 0.31);
- border-radius: 24rpx;
- }
- .banner {
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- z-index: -1;
- }
+ padding: 54rpx 44rpx;
+ color: #fff;
+ position: relative;
+ width: 688rpx;
+ height: 270rpx;
+ margin-bottom: 40rpx;
+ .h1 {
+ font-weight: bold;
+ line-height: 66rpx;
+ font-size: 44rpx;
+ margin-bottom: 14rpx;
+ }
+ .h2 {
+ font-weight: 600;
+ font-size: 28rpx;
+ width: 192rpx;
+ color: $uni-color-primary;
+ height: 48rpx;
+ line-height: 48rpx;
+ text-align: center;
+ background: #ffffff;
+ box-shadow: 0rpx 4rpx 8rpx 0rpx rgba(39, 155, 170, 0.31);
+ border-radius: 24rpx;
+ }
+ .banner {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 100%;
+ z-index: -1;
+ }
}
.container1 {
- display: flex;
- flex-wrap: wrap;
- view {
- width: 336rpx;
- }
- .left {
- margin-right: 18rpx;
- }
- .img_wrap {
- position: relative;
- padding: 24rpx 0rpx 0 28rpx;
- border-radius: 8rpx;
- overflow: hidden;
- .h1 {
- font-weight: 600;
- font-size: 32rpx;
- color: #222222;
- line-height: 48rpx;
- margin-bottom: 4rpx;
- }
- .h2 {
- font-size: 22rpx;
- color: #7b9da1;
- line-height: 34rpx;
- }
- .img {
- width: 100%;
- height: 100%;
- position: absolute;
- top: 0;
- left: 0;
- z-index: -1;
- }
- }
- .img1 {
- width: 336rpx;
- height: 296rpx;
- margin-bottom: 16rpx;
- }
- .img2 {
- width: 336rpx;
- height: 140rpx;
- margin-bottom: 16rpx;
- }
+ display: flex;
+ flex-wrap: wrap;
+ view {
+ width: 336rpx;
+ }
+ .left {
+ margin-right: 18rpx;
+ }
+ .img_wrap {
+ position: relative;
+ padding: 24rpx 0rpx 0 28rpx;
+ border-radius: 8rpx;
+ overflow: hidden;
+ .h1 {
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ line-height: 48rpx;
+ margin-bottom: 4rpx;
+ }
+ .h2 {
+ font-size: 22rpx;
+ color: #7b9da1;
+ line-height: 34rpx;
+ }
+ .img {
+ width: 100%;
+ height: 100%;
+ position: absolute;
+ top: 0;
+ left: 0;
+ z-index: -1;
+ }
+ }
+ .img1 {
+ width: 336rpx;
+ height: 296rpx;
+ margin-bottom: 16rpx;
+ }
+ .img2 {
+ width: 336rpx;
+ height: 140rpx;
+ margin-bottom: 16rpx;
+ }
}
.task_list {
- margin-bottom: 48rpx;
- .item {
- background: #ffffff;
- box-shadow: 0rpx 4rpx 32rpx 0rpx rgba(39, 155, 170, 0.18);
- border-radius: 16rpx;
- .head {
- display: flex;
- justify-content: space-between;
- align-items: center;
- background: linear-gradient(270deg, #fefeff 0%, #e1f7fe 100%);
- padding: 20rpx 30rpx;
- .name {
- font-weight: 600;
- font-size: 36rpx;
- color: #222222;
- }
- .status {
- color: $uni-color-primary;
- font-weight: 600;
- .time {
- font-size: 24rpx;
- font-weight: 360;
- }
- }
- }
- .content {
- .info {
- display: flex;
- padding: 24rpx 30rpx;
- .plate {
- flex: 1;
- display: flex;
- align-items: center;
- .icon {
- width: 26rpx;
- height: 26rpx;
- margin-right: 10rpx;
- }
- }
- }
- .sub {
- display: flex;
- justify-content: space-between;
- align-items: center;
- padding: 0 30rpx 24rpx;
- .time {
- font-size: 26rpx;
- color: #999999;
- }
- .sub_btn {
- height: 68rpx;
- line-height: 68rpx;
- padding: 0 34rpx;
- color: #ffffff;
- background: $uni-color-primary;
- box-shadow: 0rpx 4rpx 12rpx 0rpx rgba(39, 155, 170, 0.4);
- border-radius: 40rpx;
- }
- }
- }
- }
+ margin-bottom: 48rpx;
+ .task_swiper {
+ padding: 16rpx 10rpx;
+ height: 320rpx;
+ width: 730rpx;
+ margin-left: -20rpx;
+ box-sizing: border-box;
+ }
+ .item {
+ background: #ffffff;
+ box-shadow: 0rpx 0rpx 12rpx 0rpx rgba(39, 155, 170, 0.32);
+ border-radius: 16rpx;
+ height: 280rpx;
+ width: 98%;
+ margin-left: 1%;
+ .head {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ background: linear-gradient(270deg, #fefeff 0%, #e1f7fe 100%);
+ padding: 0rpx 30rpx;
+ height: 92rpx;
+ .name {
+ font-weight: 600;
+ font-size: 36rpx;
+ color: #222222;
+ }
+ .status {
+ color: $uni-color-primary;
+ font-weight: 600;
+ text-align: right;
+ .time {
+ font-size: 24rpx;
+ font-weight: 360;
+ }
+ }
+ }
+ .content {
+ height: 180rpx;
+ .info {
+ display: flex;
+ padding: 24rpx 30rpx;
+ .plate {
+ flex: 1;
+ display: flex;
+ align-items: center;
+ .icon {
+ width: 26rpx;
+ height: 26rpx;
+ margin-right: 10rpx;
+ }
+ }
+ }
+ .sub {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ padding: 0 30rpx 24rpx;
+ .time {
+ font-size: 26rpx;
+ color: #999999;
+ }
+ .sub_btn {
+ height: 68rpx;
+ line-height: 68rpx;
+ padding: 0 34rpx;
+ color: #ffffff;
+ background: $uni-color-primary;
+ box-shadow: 0rpx 4rpx 12rpx 0rpx rgba(39, 155, 170, 0.4);
+ border-radius: 40rpx;
+ }
+ }
+ }
+ }
}
.copyright {
- display: flex;
- align-items: center;
- justify-content: center;
- margin-top: 44rpx;
- font-size: 24rpx;
- color: #666666;
- image {
- width: 40rpx;
- height: 40rpx;
- }
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ margin-top: 44rpx;
+ font-size: 24rpx;
+ color: #666666;
+ image {
+ width: 40rpx;
+ height: 40rpx;
+ }
}
</style>
diff --git a/h5/pages/driver/login.vue b/h5/pages/driver/login.vue
index cc0ff66..4dede46 100644
--- a/h5/pages/driver/login.vue
+++ b/h5/pages/driver/login.vue
@@ -7,7 +7,7 @@
<view class="login_list">
<view class="login_list_item">
<image src="@/static/login_ic_phone@2x.png" mode="widthFix" />
- <input v-model="form.phone" maxlength="18" placeholder="鎵嬫満鍙�" />
+ <input v-model="form.username" maxlength="18" placeholder="鎵嬫満鍙�" />
</view>
<view class="login_list_item">
<image src="@/static/login_ic_password@2x.png" mode="widthFix" />
@@ -25,52 +25,53 @@
<view class="btns">
<view class="btn" @click="handleRegister">绔嬪嵆娉ㄥ唽</view>
<view class="btn separate"> | </view>
- <view class="btn">蹇樿瀵嗙爜</view>
+ <view class="btn" @click="handleSetPsd">蹇樿瀵嗙爜</view>
</view>
</view>
</template>
<script>
-import { resetPassword, sendSms } from '@/api'
+import { driverLogin, loginCaptcha, getUserInfo } from '@/api'
+import { mapState, mapMutations } from 'vuex'
export default {
data() {
return {
form: {
+ username: '13996529050',
+ password: '1'
},
isShowProtocol: false,
countDown: 0
}
},
-
onLoad() {
+ this.initCaptcha()
},
-
+
methods: {
+ ...mapMutations(["setToken", "setDriverInfo"]),
handleRegister() {
uni.navigateTo({
url: "/pages/driver/register"
+ })
+ },
+ handleSetPsd() {
+ uni.navigateTo({
+ url: "/pages/driver/forgetPsd"
})
},
dealChange(e) {
console.log(e)
},
initCaptcha() {
- if (!this.form.phone) return uni.showToast({
- title: '鎵嬫満鍙蜂笉鑳戒负绌�',
- icon: 'none'
- })
- sendSms({ phone: this.form.phone }).then(res => {
- this.countDown = 60
- setInterval(() => {
- if (this.countDown == 0) return
- this.countDown--
- }, 1000)
+ loginCaptcha().then(res => {
+ this.captcha = res.data
})
},
onLogin() {
const { form } = this
- if (!form.phone) return uni.showToast({
+ if (!form.username) return uni.showToast({
title: '鎵嬫満鍙蜂笉鑳戒负绌�',
icon: 'none'
})
@@ -78,19 +79,21 @@
title: '瀵嗙爜涓嶈兘涓虹┖',
icon: 'none'
})
- resetPassword({
- ...form
+ driverLogin({
+ ...form,
+ uuid: this.captcha.uuid,
+ code: '1'
}).then(res => {
- if (res && res.code == 200) {
- setTimeout(() => {
- uni.showToast({
- title: '瀵嗙爜淇敼鎴愬姛,璇烽噸鏂扮櫥褰�',
- icon: 'success',
- duration: 2000
+ if (res.code === 200) {
+ this.setToken(res.data)
+ getUserInfo().then(ress => {
+ setTimeout(() => {
+ this.showToast('鐧诲綍鎴愬姛')
+ })
+ this.setDriverInfo(ress.data)
+ uni.redirectTo({
+ url: "/pages/driver/index"
})
- })
- uni.redirectTo({
- url: "/pages/staffLogin/login"
})
}
})
diff --git a/h5/pages/driver/register.vue b/h5/pages/driver/register.vue
index ae1b1a5..89fe60a 100644
--- a/h5/pages/driver/register.vue
+++ b/h5/pages/driver/register.vue
@@ -49,12 +49,11 @@
</template>
<script>
-import { resetPassword, sendSms } from '@/api'
+import { driverRegister, sendSms } from '@/api'
export default {
data() {
return {
- form: {
- },
+ form: {},
isShowProtocol: false,
countDown: 0
}
@@ -84,7 +83,7 @@
onLogin() {
const { form } = this
if (!form.name) return uni.showToast({
- title: '鎵嬫満鍙峰鍚�',
+ title: '濮撳悕涓嶈兘涓虹┖',
icon: 'none'
})
if (!form.phone) return uni.showToast({
@@ -99,14 +98,14 @@
title: '瀵嗙爜涓嶈兘涓虹┖',
icon: 'none'
})
- resetPassword({
+ driverRegister({
...form
}).then(res => {
if (res && res.code == 200) {
setTimeout(() => {
uni.showToast({
title: '娉ㄥ唽鎴愬姛,璇峰墠寰�鐧诲綍',
- icon: 'success',
+ icon: 'none',
duration: 2000
})
})
diff --git a/h5/pages/driver/reserved.vue b/h5/pages/driver/reserved.vue
index c201b32..813062c 100644
--- a/h5/pages/driver/reserved.vue
+++ b/h5/pages/driver/reserved.vue
@@ -5,9 +5,19 @@
<view class="line">
<view class="label">
<text>*</text>
+ <text>鍏ュ洯鍘熷洜</text>
+ </view>
+ <view class="value" @click="showReason = true">
+ <text class="mr6" :style="{ color: param.inReason ? '#000000' : '#999999' }">{{ param.inReason ? param.inReason : '璇烽�夋嫨' }}</text>
+ <u-icon name="arrow-right" color="#CCCCCC" size="16"></u-icon>
+ </view>
+ </view>
+ <view class="line">
+ <view class="label">
+ <text>*</text>
<text>鍚堝悓鍙�</text>
</view>
- <view class="value"><input type="text" placeholder="璇疯緭鍏ユ偍鐨勫悎鍚屽彿" v-model="param.receptMemberName" placeholder-style="color: #999999;" /></view>
+ <view class="value"><input type="text" placeholder="璇疯緭鍏ユ偍鐨勫悎鍚屽彿" v-model="param.contractNum" placeholder-style="color: #999999;" /></view>
</view>
<!-- -->
<view class="line">
@@ -16,7 +26,7 @@
<text>鍒板満鏃堕棿</text>
</view>
<view class="value" @click="showDatetime = true">
- <text class="mr6" :style="{ color: param.area ? '#000000' : '#999999' }">{{ param.area ? param.area : '璇烽�夋嫨' }}</text>
+ <text class="mr6" :style="{ color: param.arriveDate ? '#000000' : '#999999' }">{{ param.arriveDate ? param.arriveDate : '璇烽�夋嫨' }}</text>
<u-icon name="arrow-right" color="#CCCCCC" size="16"></u-icon>
</view>
</view>
@@ -27,8 +37,8 @@
</view>
<view class="value">
<view class="btns">
- <view class="btn active">鏁存墭鐩�</view>
- <view class="btn">浠剁儫</view>
+ <view @click="inTypeClick(0)" :class="{ active: param.inType == 0 }" class="btn">鏁存墭鐩�</view>
+ <view @click="inTypeClick(1)" :class="{ active: param.inType == 1 }" class="btn">浠剁儫</view>
</view>
</view>
</view>
@@ -38,7 +48,7 @@
<text>鎬昏繍杈撻噺</text>
</view>
<view class="value">
- <input type="text" placeholder="璇疯緭鍏ユ�昏繍杈撻噺" v-model="param.receptMemberName" placeholder-style="color: #999999;" />
+ <input type="number" placeholder="璇疯緭鍏ユ�昏繍杈撻噺" v-model="param.totalNum" placeholder-style="color: #999999;" />
<text class="unit">涓囨敮</text>
</view>
</view>
@@ -47,8 +57,9 @@
<text>*</text>
<text>鍑嗚繍璇佺収鐗�</text>
</view>
- <view class="value">
- <view class="upload_wrap"><u-icon name="plus" size="20" color="#999999"></u-icon></view>
+ <view class="value" @click="handleUpload">
+ <image v-if="param.transportImgFull" class="upload_wrap" :src="param.transportImgFull" alt="">
+ <view v-else class="upload_wrap"><u-icon name="plus" size="20" color="#999999"></u-icon></view>
</view>
</view>
<view class="empty"></view>
@@ -58,14 +69,14 @@
<text>*</text>
<text>鍙告満濮撳悕</text>
</view>
- <view class="value"><input type="text" placeholder="璇疯緭鍏ユ偍鐨勭湡瀹炲鍚�" v-model="param.receptMemberName" placeholder-style="color: #999999;" /></view>
+ <view class="value"><input type="text" placeholder="璇疯緭鍏ユ偍鐨勭湡瀹炲鍚�" v-model="param.driverName" placeholder-style="color: #999999;" /></view>
</view>
<view class="line">
<view class="label">
<text>*</text>
<text>鎵嬫満鍙�</text>
</view>
- <view class="value"><input type="text" placeholder="璇疯緭鍏ユ偍鐨勬墜鏈哄彿" v-model="param.receptMemberName" placeholder-style="color: #999999;" /></view>
+ <view class="value"><input type="number" placeholder="璇疯緭鍏ユ偍鐨勬墜鏈哄彿" v-model="param.driverPhone" placeholder-style="color: #999999;" /></view>
</view>
<!-- -->
<view class="line">
@@ -74,7 +85,7 @@
<text>杞﹀墠鐗岀収鍙�</text>
</view>
<view class="value" @click="openInput(1)">
- <text :style="{ color: param.carNos ? '#000000' : '' }">{{ param.carNos ? param.carNos : '璇疯緭鍏ヨ溅鐗屽彿鐮�' }}</text>
+ <text :style="{ color: param.carCodeFront ? '#000000' : '#999999' }">{{ param.carCodeFront ? param.carCodeFront : '璇疯緭鍏ヨ溅鐗屽彿鐮�' }}</text>
</view>
</view>
<view class="line">
@@ -82,18 +93,19 @@
<text>*</text>
<text>杞﹀悗鐗岀収鍙�</text>
</view>
- <view class="value" @click="openInput(1)">
- <text :style="{ color: param.carNos ? '#000000' : '' }">{{ param.carNos ? param.carNos : '璇疯緭鍏ヨ溅鐗屽彿鐮�' }}</text>
+ <view class="value" @click="openInput(2)">
+ <text :style="{ color: param.carCodeBack ? '#000000' : '#999999' }">{{ param.carCodeBack ? param.carCodeBack : '璇疯緭鍏ヨ溅鐗屽彿鐮�' }}</text>
</view>
</view>
<view class="copy" @click="copy">澶嶅埗杞﹀墠鐗岀収鍙�</view>
<view class="perch"></view>
- <view class="handle_sub">
+ <view class="handle_sub" @click="onSubmit">
鎻愪氦
</view>
-
- <!-- -->
</view>
+
+ <!-- -->
+ <u-picker :show="showReason" keyName="reason" :columns="reasonList" @confirm="reasonConfirm"></u-picker>
<u-datetime-picker
:show="showDatetime"
closeOnClickOverlay
@@ -109,74 +121,130 @@
<script>
import keyboardInput from '@/components/keyboard-input/keyboard-input.vue';
-import { uploadUrl } from '@/api';
+import { uploadUrl, driverCarApply, driverReasonList } from '@/api';
+import dayjs from 'dayjs'
export default {
components: {
keyboardInput
},
data() {
return {
- param: {},
+ param: {
+ inType: 0,
+ driverName: uni.getStorageSync('driverInfo').realname,
+ driverPhone: uni.getStorageSync('driverInfo').username,
+ },
+ reasonIndex: -1,
+ reasonList: [],
showDatetime: false,
+ showReason: false,
inputType: ''
};
},
+ created() {
+ this.initData()
+ },
methods: {
- copy(){
- this.param.carNos = this.param.carNos
- uni.showToast({
- title: '澶嶅埗鎴愬姛',
- duration: 1000
- });
- },
- handleUpload() {
- uni.chooseImage({
- success: chooseImageRes => {
- uni.showLoading({ title: '涓婁紶涓�', mask: true });
- for (let i = 0; i < chooseImageRes.tempFilePaths.length; i++) {
- uni.uploadFile({
- url: `${uploadUrl}visitsAdmin/cloudService/web/public/uploadFtp.do`,
- filePath: chooseImageRes.tempFilePaths[i],
- name: 'file',
- formData: {
- folderCode: 'MEMBER_IMG'
- },
- success: uploadFileRes => {
- console.log('uploadFileRes', uploadFileRes);
- let res = JSON.parse(uploadFileRes.data);
- if (type === 'faceImg') {
- this.param.faceImg = res.data.halfPath;
- this.param.faceImgUrl = res.data.prefixPath + res.data.folder + res.data.halfPath;
- } else {
- this.param.imgurl = res.data.halfPath;
- this.param.imgurlUrl = res.data.prefixPath + res.data.folder + res.data.halfPath;
- }
- },
- complete() {
- if (i === chooseImageRes.tempFilePaths.length - 1) {
- uni.hideLoading();
- }
- }
- });
- }
+ onSubmit() {
+ const param = { ...this.param }
+ if (!param.arriveDate) return this.showToast('璇烽�夋嫨鍒板満鏃堕棿')
+ if (!param.inType && param.inType != 0) return this.showToast('璇烽�夋嫨鍏ュ簱绫诲瀷')
+ if (!param.contractNum) return this.showToast('璇疯緭鍏ュ悎鍚屽彿')
+ if (!param.totalNum) return this.showToast('璇疯緭鍏ユ�昏繍杈撻噺')
+ if (!param.driverName) return this.showToast('璇疯緭鍏ュ徃鏈哄鍚�')
+ if (!param.driverPhone) return this.showToast('璇疯緭鍏ユ墜鏈哄彿')
+ if (!param.carCodeFront) return this.showToast('璇疯緭鍏ヨ溅鍓嶇墝鍙�')
+ if (!param.carCodeBack) return this.showToast('璇疯緭鍏ヨ溅鍚庣墝鍙�')
+ if (!param.transportImgFull) return this.showToast('璇蜂笂浼犲噯杩愯瘉鐓х墖')
+ param.arriveDate = param.arriveDate + ':00'
+ driverCarApply({...param}).then(res => {
+ if(res && res.code === 200){
+ uni.navigateBack()
}
- });
+ })
},
- setinDate(e) {},
+ initData(){
+ driverReasonList().then(res => {
+ this.reasonList = [res.data]
+ })
+ },
+ reasonConfirm(e) {
+ const reasonList = this.reasonList[0]
+ const index = e.indexs[0]
+ this.$set(this.param, 'inReason', reasonList[index].reason)
+ this.$set(this.param, 'reasonId', reasonList[index].id)
+ this.showReason = false
+ },
+ setinDate(e) {
+ this.$set(this.param, 'arriveDate', dayjs(e.value).format('YYYY-MM-DD HH:mm'))
+ this.showDatetime = false
+ },
+ inTypeClick(e) {
+ this.param.inType = e
+ },
openInput(type) {
this.inputType = type;
this.$refs.keyboard.open();
},
setPlate(e) {
if (this.inputType === 1) {
- this.param.carNos = e;
+ this.$set(this.param, 'carCodeFront', e)
} else if (this.inputType === 2) {
- this.param.carNos = e;
+ this.$set(this.param, 'carCodeBack', e)
}
this.$forceUpdate();
this.closeInput();
},
+ copy(){
+ if(this.param.carCodeFront){
+ this.$set(this.param, 'carCodeBack', this.param.carCodeFront)
+ this.showToast('澶嶅埗鎴愬姛');
+ }
+
+ },
+ handleUpload() {
+ let token = uni.getStorageSync('token') || ''
+ uni.chooseImage({
+ count: 1,
+ success: (chooseImageRes) => {
+ uni.showLoading({ title: '涓婁紶涓�', mask: true })
+ const tempFilePaths = chooseImageRes.tempFilePaths
+ let imgs = tempFilePaths.map((value, index) => {
+ return {
+ name: 'file',
+ uri: value
+ }
+ })
+ uni.uploadFile({
+ url: `${uploadUrl}`,
+ files: imgs,
+ name: 'file',
+ formData: {
+ folder: 'PLATFORM'
+ },
+ header: {
+ Dm_user_token: token
+ },
+ success: (uploadFileRes) => {
+ let res = JSON.parse(uploadFileRes.data)
+ console.log('res', res.data)
+ if (res.data && res.data.length > 0) {
+ this.$set(this.param, 'transportImg', res.data[0].imgaddr)
+ this.$set(this.param, 'transportImgFull', res.data[0].url)
+ }
+ },
+ fail(err) {
+ console.log('err', err)
+ },
+ complete() {
+ uni.hideLoading()
+ }
+ })
+ // }
+ }
+ })
+ },
closeInput() {
this.$refs.keyboard.close();
}
diff --git a/h5/pages/driver/reservedDetail.vue b/h5/pages/driver/reservedDetail.vue
index e87dc36..2303e6f 100644
--- a/h5/pages/driver/reservedDetail.vue
+++ b/h5/pages/driver/reservedDetail.vue
@@ -1,142 +1,171 @@
<template>
<view class="main_app">
<view class="status_wrap">
- <view class="name">涓佹仼鍑殑璁垮鐢宠</view>
- <view class="desc">绛夊緟鎴戝鐞�</view>
- <view class="status">瀹℃壒涓�</view>
+ <view class="name">{{info.driverName}}鐨勫叆鍥绾�</view>
+ <view class="desc">{{info.carCodeFront}}</view>
+ <view class="status">{{ statusMap[info.status] }}</view>
</view>
<!-- -->
<view class="emyty"></view>
<view class="module_list">
<view class="item">
- <view class="label">鎷滆浜�</view>
- <view class="value">寤栨垚鐟�</view>
+ <view class="label">鍏ュ洯鍘熷洜</view>
+ <view class="value">{{info.inReason}}</view>
</view>
<view class="item">
- <view class="label">棰勮鍏�/绂诲洯鏃堕棿</view>
- <view class="value">05/01 8:00 - 05/01 18:00</view>
+ <view class="label">鍚堝悓缂栧彿</view>
+ <view class="value">{{info.contractNum}}</view>
</view>
+ <view class="item">
+ <view class="label">鍒板満鏃堕棿</view>
+ <view class="value" v-if="info.arriveDate">{{info.arriveDate.slice(0,16)}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鍑嗚繍璇佺収鐗�</view>
+ <view class="value">
+ <image
+ v-if="info.transportImg"
+ class="avatar_wrap"
+ :src="info.prefixUrl + info.transportImg"
+ ></image>
+ </view>
+ </view>
+ <view class="item">
+ <view class="label">鍏ュ簱绫诲瀷</view>
+ <view class="value">{{info.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鎬昏繍鏁伴噺</view>
+ <view class="value">{{info.totalNum}}涓囨敮</view>
+ </view>
<view class="emyty"></view>
<view class="item">
- <view class="label">璁垮淇℃伅</view>
- <view class="value">
- <image
- class="avatar"
- src="@/static/logo@2x.png"
- mode="widthFix"
- ></image>
- <view class="info">
- <text class="name">瀛欏織 18177665678</text>
- <text>韬唤璇佸彿锛�3309****2910</text>
- <text>鍏ュ洯杞﹁締锛氱殩A88789</text>
- </view>
+ <view class="label">鍙告満濮撳悕</view>
+ <view class="value">{{info.driverName}}
</view>
</view>
<view class="item">
- <view class="label">鍏徃鍚嶇О</view>
- <view class="value">涓浗绉诲姩</view>
+ <view class="label">鎵嬫満鍙�</view>
+ <view class="value">{{info.driverPhone}}</view>
</view>
- <view class="item">
- <view class="label">鏂藉伐浜哄憳</view>
- <view class="value">鍚�</view>
- </view>
- <view class="item">
- <view class="label">鏉ヨ浜嬬敱</view>
- <view class="value">涓氬姟娲借皥</view>
- </view>
+ <view class="item">
+ <view class="label">杞︾墝鐓�</view>
+ <view class="value">鍓� {{info.carCodeFront}}锛屽悗 {{info.carCodeBack}}</view>
+ </view>
</view>
<!-- 娴佺▼ -->
<view class="flow_wrap">
<view class="flow_title">娴佺▼</view>
- <view class="list">
- <view class="item">
- <view class="avatar">
- <image class="img" src="@/static/logo@2x.png" mode="widthFix" />
+ <view class="list" v-if="info.approveDateVO != null && info.approveDateVO.approveList != null">
+ <view class="item" v-for="item,index in info.approveDateVO.approveList">
+ <view v-if="index != info.approveDateVO.approveList.length - 1" class="separate"></view>
+ <view class="avatar_wrap">
<image
+ class="img"
+ :src="
+ item.faceImg
+ ? item.faceImg
+ : require('@/static/meeting/common/default_user@2x.png')
+ "
+ />
+ <image
+ v-if="item.status == 2"
class="status"
src="@/static/staff/liucheng_success@2x.png"
mode="widthFix"
/>
- <view class="separate"></view>
+ <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">鏌愭煇鎻愪氦鐨勬嫓璁跨敵璇�</view>
- <view class="time">time</view>
+ <view class="event">{{ item.title }}</view>
+ <view class="time">{{item.createDate}}</view>
</view>
<view class="name_wrap">
- <text>鏉庝笢(<text class="status">澶勭悊涓�</text>)</text>
+ <text>{{item.memberName}}<text v-if="item.statusInfo" class="status">({{item.statusInfo}})</text></text>
</view>
- <view class="remark">鍚屾剰鏀捐</view>
- </view>
- </view>
- <view class="item">
- <view class="avatar">
- <image class="img" src="@/static/logo@2x.png" mode="widthFix" />
- <image
- class="status"
- src="@/static/staff/liucheng_success@2x.png"
- mode="widthFix"
- />
- </view>
- <view class="content">
- <view class="head">
- <view class="event">鏌愭煇鎻愪氦鐨勬嫓璁跨敵璇�</view>
- <view class="time">time</view>
- </view>
- <view class="name_wrap">
- <text>鏉庝笢(<text class="status">澶勭悊涓�</text>)</text>
- </view>
- <view class="carbon">
- <view class="carbon_item" v-for="i in 12">
- <image src="@/static/logo@2x.png" mode="widthFix"></image>
- <view class="text">name</view>
- </view>
- </view>
+ <view v-if="item.approveType == 1" class="carbon">
+ <view class="carbon_item" v-for="child in item.approveList"
+ :key="child.id">
+ <image :src="
+ child.faceImg
+ ? child.faceImg
+ : require('@/static/meeting/common/default_user@2x.png')
+ "></image>
+ <view class="text">{{ child.memberName }}</view>
+ </view>
+ </view>
</view>
</view>
</view>
</view>
<view class="emyty"></view>
<view class="main_footer">
- <view class="btn" @click="handleSub('0')">鎷掔粷</view>
- <view class="btn agree" @click="handleSub('1')">鍚屾剰</view>
+ <view v-if="info.status == 0 || info.status == 1" class="btn" @click="handleCancel">鎾ゅ洖鐢宠</view>
+ <view v-if="info.status == 0 || info.status == 1" class="btn agree" @click="handleEdit">淇敼</view>
+ <view v-if="info.status == 3" class="btn agree aga" @click="handleAga">鍐嶆鐢宠</view>
</view>
-
- <!-- -->
- <u-popup
- :show="showApprModal"
- :round="10"
- :safeAreaInsetBottom="true"
- mode="bottom"
- @close="showApprModal = false"
- >
- <view class="appr_modal">
- <view class="title">鍚屾剰</view>
- <textarea
- placeholder="鍚屾剰璇存槑锛岄潪蹇呭~"
- placeholder-class="placeholder9"
- />
- <view class="main_footer">
- <view class="btn" @click="showApprModal = false">鍙栨秷</view>
- <view class="btn agree">鎻愪氦</view>
- </view>
- </view>
- </u-popup>
</view>
</template>
<script>
+ import { driverApplyDetail, driverCarRevoke } from '@/api'
export default {
data() {
return {
showApprModal: false,
- param: {}
+ info: {},
+ statusMap: {
+ 0: '寰呭鎵�',
+ 1: '瀹℃壒涓�',
+ 2: '瀹℃壒閫氳繃',
+ 3: '瀹℃壒涓嶉�氳繃',
+ 4: '宸插彇娑�',
+ },
}
},
+ onLoad(option) {
+ this.getDetail(option.id)
+ },
methods: {
+ handleCancel(){
+ uni.showModal({
+ title: '鎻愮ず',
+ content: '杩欐槸涓�涓ā鎬佸脊绐�',
+ success: function (res) {
+ if (res.confirm) {
+ console.log('鐢ㄦ埛鐐瑰嚮纭畾');
+ } else if (res.cancel) {
+ console.log('鐢ㄦ埛鐐瑰嚮鍙栨秷');
+ }
+ }
+ });
+ // driverCarRevoke
+ },
+ handleEdit(){},
+ handleAga(){},
+ getDetail(id) {
+ driverApplyDetail({id}).then(res => {
+ this.info = res.data
+ if(this.info.approveDateVO && this.info.approveDateVO.approveList.length > 0 ){
+ this.info.approveDateVO.approveList.forEach(item => {
+ if(item.approveList && item.approveList.length == 1 && item.type !== 1){
+ item.title = item.approveList[0].title
+ item.faceImg = item.approveList[0].faceImg
+ item.memberName = item.approveList[0].memberName
+ item.statusInfo = item.approveList[0].statusInfo
+ item.approveList = []
+ }
+ })
+ }
+ })
+ },
handleSub(flag) {
- // this.param.flag =
if (flag === '1') {
} else {
@@ -172,7 +201,7 @@
display: flex;
margin-bottom: 48rpx;
- .avatar {
+ .avatar_wrap {
width: 80rpx;
height: 80rpx;
position: relative;
@@ -281,7 +310,7 @@
display: flex;
align-items: center;
- .avatar {
+ .avatar_wrap {
margin-right: 20rpx;
width: 120rpx;
height: 120rpx;
@@ -319,7 +348,7 @@
.desc {
font-size: 26rpx;
- color: #ed4545;
+ color: #999999;
}
.status {
@@ -339,7 +368,7 @@
padding-bottom: 64rpx;
display: flex;
justify-content: space-between;
-
+
.btn {
width: 336rpx;
height: 88rpx;
@@ -357,6 +386,9 @@
color: #fff;
border: 1rpx solid $uni-color-primary;
}
+ .aga{
+ width: 100%;
+ }
}
.appr_modal {
diff --git a/h5/pages/driver/reservedGuide.vue b/h5/pages/driver/reservedGuide.vue
index 8c3b35f..73789e1 100644
--- a/h5/pages/driver/reservedGuide.vue
+++ b/h5/pages/driver/reservedGuide.vue
@@ -1,6 +1,6 @@
<template>
<view>
-
+ <mp-html :content="content" />
</view>
</template>
@@ -8,8 +8,14 @@
export default {
data() {
return {
-
+ content: ''
};
+ },
+ onLoad(option) {
+ this.content = uni.getStorageSync('driverGuide')[option.str]
+ },
+ methods: {
+
}
}
</script>
diff --git a/h5/pages/driver/reservedRecord.vue b/h5/pages/driver/reservedRecord.vue
index f76ba2e..0d19bd6 100644
--- a/h5/pages/driver/reservedRecord.vue
+++ b/h5/pages/driver/reservedRecord.vue
@@ -4,74 +4,77 @@
<view class="box_list">
<view
class="box_list_item"
- v-for="(item, index) in 3"
+ v-for="(item, index) in datalist"
:key="index"
- @click="handleDetail()"
+ @click="handleDetail(item.id)"
>
<view class="box_list_item_head">
- <text>涓佹仼鍑殑鍔冲姟鍏ュ洯鐢宠</text>
- <text class="loading">寰呭鏍�</text>
+ <text>{{item.driverName}}鐨勫叆鍥绾�</text>
+ <text class="loading">{{ statusMap[item.status] }}</text>
</view>
<view class="box_list_item_nr">
<view class="box_list_item_nr_item">
- <text>琚闂汉锛�</text>
- <text>浜轰簨閮�-鐜嬩簹钃�</text>
+ <text>鍚堝悓缂栧彿锛�</text>
+ <text>{{item.contractNum}}</text>
</view>
<view class="box_list_item_nr_item">
- <text>杩涘巶鏃堕棿锛�</text>
- <text>12-12 09:00</text>
+ <text>鍒板満鏃堕棿锛�</text>
+ <text>{{item.arriveDate.slice(5,16)}}</text>
</view>
<view class="box_list_item_nr_item">
- <text>绂诲洯鏃堕棿锛�</text>
- <text>12-12 12:00</text>
+ <text>鍙告満濮撳悕锛�</text>
+ <text>{{item.driverName}}</text>
</view>
<view class="box_list_item_nr_item">
- <text>鏉ヨ浜嬬敱锛�</text>
- <text>涓氬姟鏉ュ線</text>
+ <text>杞﹁締淇℃伅锛�</text>
+ <text>{{item.carCodeFront}}</text>
</view>
<view class="box_list_item_nr_item">
- <text>闅忚杞﹁締锛�</text>
- <text>鐨朅88888</text>
+ <text class="placeholder9">{{item.createDate.slice(0,16)}}鎻愪氦</text>
</view>
</view>
</view>
</view>
- <!-- 閫夋嫨杞﹁締 -->
- <u-picker
- keyName="name"
- closeOnClickOverlay
- @close="isShowCar = false"
- :show="isShowCar"
- :columns="carList"
- @confirm="seletedCar"
- @cancel="isShowCar = false"
- ></u-picker>
- <!-- 鏃ユ湡 -->
- <u-datetime-picker
- :show="isShowDate"
- :minDate="minDate"
- @confirm="confirmDate"
- @cancel="isShowDate = false"
- mode="date"
- ></u-datetime-picker>
</view>
</template>
<script>
+ import { driverApplyRecord } from "@/api"
export default {
data() {
return {
isShowCar: false,
isShowDate: false,
param: {},
- carList: [[{ name: 'aa', value: '11' }]],
- timeList: [{ time: '08:30-09:00' }, { time: '08:30-09:00' }, { time: '08:30-09:00' }, { time: '08:30-09:00' }]
+ page: 1,
+ capacity: 10,
+ total: 0,
+ datalist: [],
+ statusMap: {
+ 0: '寰呭鎵�',
+ 1: '瀹℃壒涓�',
+ 2: '瀹℃壒閫氳繃',
+ 3: '瀹℃壒涓嶉�氳繃',
+ 4: '宸插彇娑�',
+ }
}
},
+ created() {
+ this.getList()
+ },
methods: {
- handleDetail() {
+ getList() {
+ const { page, capacity } = this
+ driverApplyRecord({
+ page, capacity,model: {}
+ }).then(res => {
+ this.datalist = res.data.records
+ this.total = res.data.total
+ })
+ },
+ handleDetail(id) {
uni.navigateTo({
- url: "/pages/driver/reservedDetail"
+ url: `/pages/driver/reservedDetail?id=${id}`
})
},
confirmDate(e) {
@@ -89,6 +92,9 @@
</script>
<style lang="scss">
+ page{
+ background: #f7f7f7;
+ }
.main_app {
background: #f7f7f7;
padding: 0;
@@ -151,7 +157,7 @@
}
}
.box_list_item_nr {
- padding: 30rpx;
+ padding: 30rpx 30rpx 10rpx;
width: 100%;
box-sizing: border-box;
background-color: #ffffff;
@@ -159,18 +165,11 @@
width: 100%;
display: flex;
align-items: center;
- margin-bottom: 20rpx;
+ margin-bottom: 16rpx;
text {
- &:nth-child(1) {
- font-size: 26rpx;
- font-weight: 400;
- color: #666666;
- }
- &:nth-child(2) {
- font-size: 26rpx;
- font-weight: 400;
- color: #333333;
- }
+ font-size: 26rpx;
+ font-weight: 400;
+ color: #666666;
}
}
}
diff --git a/h5/pages/driver/taskDetail.vue b/h5/pages/driver/taskDetail.vue
index 8734397..9985e40 100644
--- a/h5/pages/driver/taskDetail.vue
+++ b/h5/pages/driver/taskDetail.vue
@@ -164,7 +164,9 @@
getLocation() {
uni.getLocation({
type: 'wgs84',
+
success: function (res) {
+ console.log(res);
console.log('褰撳墠浣嶇疆鐨勭粡搴︼細' + res.longitude)
console.log('褰撳墠浣嶇疆鐨勭含搴︼細' + res.latitude)
}
diff --git a/h5/pages/staff/task/driver.vue b/h5/pages/staff/task/driver.vue
new file mode 100644
index 0000000..6532036
--- /dev/null
+++ b/h5/pages/staff/task/driver.vue
@@ -0,0 +1,445 @@
+<template>
+ <view class="main_app">
+ <view class="status_wrap">
+ <view class="name">{{info.driverName}}鐨勫叆鍥绾�</view>
+ <view class="desc">{{info.carCodeFront}}</view>
+ <view class="status">{{ statusMap[info.status] }}</view>
+ </view>
+ <!-- -->
+ <view class="emyty"></view>
+ <view class="module_list">
+ <view class="item">
+ <view class="label">鍏ュ洯鍘熷洜</view>
+ <view class="value">{{info.inReason}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鍚堝悓缂栧彿</view>
+ <view class="value">{{info.contractNum}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鍒板満鏃堕棿</view>
+ <view v-if="info.arriveDate" class="value">{{info.arriveDate.slice(0,16)}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鍑嗚繍璇佺収鐗�</view>
+ <view class="value">
+ <image
+ v-if="info.transportImg"
+ class="avatar_wrap"
+ :src="info.prefixUrl + info.transportImg"
+ ></image>
+ </view>
+ </view>
+ <view class="item">
+ <view class="label">鍏ュ簱绫诲瀷</view>
+ <view class="value">{{info.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'}}</view>
+ </view>
+ <view class="item">
+ <view class="label">鎬昏繍鏁伴噺</view>
+ <view class="value">{{info.totalNum}}涓囨敮</view>
+ </view>
+ <view class="emyty"></view>
+ <view class="item">
+ <view class="label">鍙告満濮撳悕</view>
+ <view class="value">{{info.driverName}}
+ </view>
+ </view>
+ <view class="item">
+ <view class="label">鎵嬫満鍙�</view>
+ <view class="value">{{info.driverPhone}}</view>
+ </view>
+ <view class="item">
+ <view class="label">杞︾墝鐓�</view>
+ <view class="value">鍓� {{info.carCodeFront}}锛屽悗 {{info.carCodeBack}}</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">
+ <view v-if="index != info.approveDateVO.approveList.length - 1" class="separate"></view>
+ <view class="avatar_wrap">
+ <image
+ class="img"
+ :src="
+ item.faceImg
+ ? item.faceImg
+ : require('@/static/meeting/common/default_user@2x.png')
+ "
+ />
+ <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.createDate}}</view>
+ </view>
+ <view class="name_wrap">
+ <text>{{item.memberName}}<text v-if="item.statusInfo" class="status">({{item.statusInfo}})</text></text>
+ </view>
+ <view v-if="item.approveType == 1" class="carbon">
+ <view class="carbon_item" v-for="child in item.approveList"
+ :key="child.id">
+ <image :src="
+ child.faceImg
+ ? child.faceImg
+ : require('@/static/meeting/common/default_user@2x.png')
+ "></image>
+ <view class="text">{{ child.memberName }}</view>
+ </view>
+ </view>
+ </view>
+ </view>
+ </view>
+ </view>
+ <view class="emyty"></view>
+ <view class="main_footer">
+ <view class="btn" @click="handleSub('0')">鎷掔粷</view>
+ <view class="btn agree" @click="handleSub('1')">鍚屾剰</view>
+ </view>
+
+ <!-- -->
+ <u-popup
+ :show="showApprModal"
+ :round="10"
+ :safeAreaInsetBottom="true"
+ mode="bottom"
+ @close="showApprModal = false"
+ >
+ <view class="appr_modal">
+ <view class="title">{{ this.flag == '0' ? '鎷掔粷' : '鍚屾剰' }}</view>
+ <textarea
+ :placeholder="this.flag == '0' ? '鎷掔粷璇存槑锛屽繀濉�' : '鍚屾剰璇存槑锛岄潪蹇呭~'"
+ placeholder-class="placeholder9"
+ />
+ <view class="main_footer">
+ <view class="btn" @click="showApprModal = false">鍙栨秷</view>
+ <view class="btn agree" @click="handleAppy">鎻愪氦</view>
+ </view>
+ </view>
+ </u-popup>
+ </view>
+</template>
+
+<script>
+ import { driverApplyDetail, carUseBookAppr } from '@/api'
+export default {
+ data() {
+ return {
+ showApprModal: false,
+ checkInfo: '',
+ flag: '1',
+ info: {},
+ type: 0,
+ statusMap: {
+ 0: '寰呭鎵�',
+ 1: '瀹℃壒涓�',
+ 2: '瀹℃壒閫氳繃',
+ 3: '瀹℃壒涓嶉�氳繃',
+ 4: '宸插彇娑�',
+ },
+ }
+ },
+ onLoad(option) {
+ this.type = option.objType
+ this.getDetail(option.id)
+ },
+ methods: {
+ getDetail(id) {
+ driverApplyDetail({id}).then(res => {
+ this.info = res.data
+ if(this.info.approveDateVO && this.info.approveDateVO.approveList.length > 0 ){
+ this.info.approveDateVO.approveList.forEach(item => {
+ if(item.approveList && item.approveList.length == 1 && item.type !== 1){
+ item.title = item.approveList[0].title
+ item.faceImg = item.approveList[0].faceImg
+ item.memberName = item.approveList[0].memberName
+ item.statusInfo = item.approveList[0].statusInfo
+ item.approveList = []
+ }
+ })
+ }
+ console.log('this.info.approveDateVO', this.info.approveDateVO.approveList);
+ })
+ },
+ handleAppy() {
+ const {flag,checkInfo, type,info } = this
+ if(flag == 0 && !checkInfo) return this.showToast('鎷掔粷璇存槑蹇呭~')
+ carUseBookAppr({
+ checkInfo,objId: info.id,objType: 6,status: flag == 0 ? 3 : 2
+ }).then(res => {
+ if(res.code == 200){
+ setTimeout(() => {
+ this.showToast('鎿嶄綔鎴愬姛')
+ })
+ this.showApprModal = false
+ uni.navigateBack()
+ }
+ })
+ },
+ handleSub(flag) {
+ this.flag = flag
+ this.checkInfo = ''
+ if (flag === '1') {
+
+ } else {
+
+ }
+ this.showApprModal = true
+ }
+ },
+}
+</script>
+<style>
+page {
+ background-color: #f7f7f7;
+}
+</style>
+<style lang="scss">
+.main_app {
+ background-color: #fff;
+ padding-bottom: 0;
+
+ .flow_wrap {
+ padding: 30rpx 0;
+
+ .flow_title {
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ margin-bottom: 24rpx;
+ }
+
+ .list {
+ .item {
+ display: flex;
+ margin-bottom: 48rpx;
+ position: relative;
+ .separate {
+ position: absolute;
+ width: 4rpx;
+ height: calc( 100% - 52rpx );
+ background-color: #eeeeee;
+ left: 40rpx;
+ top: 90rpx;
+ }
+ .avatar_wrap {
+ width: 80rpx;
+ height: 80rpx;
+ position: relative;
+ margin-right: 20rpx;
+ .img {
+ width: 80rpx;
+ height: 80rpx;
+ border-radius: 50%;
+ }
+
+ .status {
+ width: 28rpx;
+ height: 28rpx;
+ border-radius: 50%;
+ position: absolute;
+ right: 0;
+ bottom: 0;
+ }
+
+ }
+
+ .content {
+ flex: 1;
+
+ .head {
+ display: flex;
+ justify-content: space-between;
+ margin-bottom: 4rpx;
+
+ .event {
+ font-size: 30rpx;
+ }
+
+ .time {
+ font-size: 26rpx;
+ color: #999999;
+ }
+ }
+
+ .name_wrap {
+ font-size: 26rpx;
+ color: #777777;
+
+ .status {
+ color: $uni-color-primary;
+ }
+ }
+
+ .remark {
+ margin-top: 12rpx;
+ background-color: #f7f7f7;
+ padding: 14rpx 20rpx;
+ border-radius: 8rpx;
+ font-size: 26rpx;
+ color: #666666;
+ line-height: 36rpx;
+ }
+ }
+ .carbon {
+ display: flex;
+ width: 590rpx;
+ overflow-x: auto;
+ margin-top: 12rpx;
+ .carbon_item {
+ text-align: center;
+ flex-shrink: 0;
+ width: 100rpx;
+ image {
+ width: 60rpx;
+ height: 60rpx;
+ margin: 0 auto;
+ }
+ view {
+ font-size: 26rpx;
+ color: #777777;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ .module_list {
+ .item {
+ padding: 30rpx 0;
+ border-bottom: 1rpx solid #e5e5e5;
+
+ .label {
+ font-size: 26rpx;
+ color: #666666;
+ margin-bottom: 20rpx;
+ }
+
+ .value {
+ font-size: 30rpx;
+ display: flex;
+ align-items: center;
+
+ .avatar_wrap {
+ margin-right: 20rpx;
+ width: 120rpx;
+ height: 120rpx;
+ border-radius: 8rpx;
+ border: 2rpx solid #e5e5e5;
+ }
+
+ .info {
+ flex: 1;
+ display: flex;
+ flex-direction: column;
+ justify-content: space-between;
+ font-size: 26rpx;
+ color: #666666;
+
+ .name {
+ font-size: 30rpx;
+ color: #333333;
+ }
+ }
+ }
+ }
+ }
+
+ .status_wrap {
+ position: relative;
+ padding: 30rpx 0;
+
+ .name {
+ font-weight: 600;
+ font-size: 32rpx;
+ margin-bottom: 20rpx;
+ color: #222222;
+ }
+
+ .desc {
+ font-size: 26rpx;
+ 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;
+ }
+ }
+
+ .main_footer {
+ padding-bottom: 64rpx;
+ display: flex;
+ justify-content: space-between;
+
+ .btn {
+ width: 336rpx;
+ height: 88rpx;
+ line-height: 88rpx;
+ background: #ffffff;
+ border-radius: 44rpx;
+ border: 1rpx solid #999999;
+ font-size: 32rpx;
+ text-align: center;
+ margin: 16rpx 0;
+ }
+
+ .agree {
+ background: $uni-color-primary;
+ color: #fff;
+ border: 1rpx solid $uni-color-primary;
+ }
+ }
+
+ .appr_modal {
+ padding: 36rpx 30rpx 0;
+
+ .title {
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ margin-bottom: 40rpx;
+ text-align: center;
+ }
+
+ textarea {
+ box-sizing: border-box;
+ width: 690rpx;
+ background-color: #f7f7f7;
+ font-size: 28rpx;
+ color: #333333;
+ padding: 24rpx;
+ border-radius: 8rpx;
+ margin-bottom: 30rpx;
+ }
+ }
+
+ .emyty {
+ width: 750rpx;
+ height: 20rpx;
+ background-color: #f7f7f7;
+ margin: 0 -30rpx;
+ }
+}
+</style>
diff --git a/h5/pages/staff/task/index.vue b/h5/pages/staff/task/index.vue
index b0b64bb..854541f 100644
--- a/h5/pages/staff/task/index.vue
+++ b/h5/pages/staff/task/index.vue
@@ -76,6 +76,23 @@
<view class="info loading">{{ item.info }}</view>
</view>
<view class="box_list_item_nr">
+ <view v-if="item.param1.arriveDate" class="box_list_item_nr_item">
+ <text></text>
+ <text>{{ item.param1.arriveDate }}</text>
+ </view>
+ <view v-if="item.param1.inType" class="box_list_item_nr_item">
+ <text></text>
+ <text>{{ item.param1.inType }}</text>
+ </view>
+ <view v-if="item.param1.totalNum" class="box_list_item_nr_item">
+ <text></text>
+ <text>{{ item.param1.totalNum }}</text>
+ </view>
+ <view v-if="item.param1.carNum" class="box_list_item_nr_item">
+ <text></text>
+ <text>{{ item.param1.carNum }}</text>
+ </view>
+
<view v-if="item.param1.name" class="box_list_item_nr_item">
<text></text>
<text>{{ item.param1.name }}</text>
@@ -342,7 +359,11 @@
uni.navigateTo({
url: `/pages/staff/task/vDangetAppr?id=${objId}&objType=${objType}`
})
- } else {
+ } else if (objType === 6 || objType === 5) {
+ uni.navigateTo({
+ url: `/pages/staff/task/driver?id=${objId}&objType=${objType}`
+ })
+ }else {
uni.navigateTo({
url: `/pages/staff/task/visitorApprove?id=${objId}&objType=${objType}`
})
diff --git a/h5/pages/staff/task/visitorApprove.vue b/h5/pages/staff/task/visitorApprove.vue
index 82883a4..4b75f1c 100644
--- a/h5/pages/staff/task/visitorApprove.vue
+++ b/h5/pages/staff/task/visitorApprove.vue
@@ -94,10 +94,17 @@
"
/>
<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">
diff --git a/h5/store/index.js b/h5/store/index.js
index 44fb682..0da49e4 100644
--- a/h5/store/index.js
+++ b/h5/store/index.js
@@ -13,6 +13,7 @@
const token = uni.getStorageSync('token')
const time = uni.getStorageSync('time')
const userInfo = uni.getStorageSync('userInfo')
+const driverInfo = uni.getStorageSync('driverInfo')
const sessionKey = uni.getStorageSync('sessionKey')
const store = new Vuex.Store({
@@ -26,6 +27,7 @@
token: token || null,
time: time || null,
userInfo: userInfo || {},
+ driverInfo: driverInfo || {},
height: height || '0',
sessionKey: sessionKey || '',
primaryColor: '#279baa'
@@ -66,6 +68,11 @@
state.userInfo = obj
uni.setStorageSync('userInfo', obj)
},
+ // 璁剧疆鍙告満淇℃伅
+ setDriverInfo(state, obj) {
+ state.driverInfo = obj
+ uni.setStorageSync('driverInfo', obj)
+ },
// 璁剧疆SessionKey
setSessionKey(state, val) {
state.sessionKey = val
diff --git a/server/system_gateway/src/main/java/com/doumee/api/gateway/JwtAuthController.java b/server/system_gateway/src/main/java/com/doumee/api/gateway/JwtAuthController.java
index 15152c8..1032835 100644
--- a/server/system_gateway/src/main/java/com/doumee/api/gateway/JwtAuthController.java
+++ b/server/system_gateway/src/main/java/com/doumee/api/gateway/JwtAuthController.java
@@ -59,6 +59,7 @@
public ApiResponse<String> login (@Validated @RequestBody LoginDTO dto, ServerWebExchange serverWebExchange) {
try {
ServerHttpRequest request = serverWebExchange.getRequest();
+ dto.setCheckCode(true);
LoginUserInfo user = systemLoginService.loginByPasswordNew(dto,request);
String token = jwtTokenUtil.generateToken(user);
return ApiResponse.success(token);
@@ -90,6 +91,24 @@
}
}
+ @PreventRepeat(limit = 10, lockTime = 10000)
+ @ApiOperation("鍙告満鐧诲綍")
+ @PostMapping("/loginDriver")
+ @LoginNoRequired
+ public ApiResponse<String> loginDriver (@Validated @RequestBody LoginDTO dto, ServerWebExchange serverWebExchange) {
+ try {
+ ServerHttpRequest request = serverWebExchange.getRequest();
+ dto.setCheckCode(false);
+ LoginUserInfo user = systemLoginService.driverLogin(dto,request);
+ String token = jwtTokenUtil.generateToken(user);
+ return ApiResponse.success(token);
+ }catch (BusinessException e){
+ return ApiResponse.failed(e.getCode(),e.getMessage());
+ }catch (Exception e){
+ e.printStackTrace();
+ return ApiResponse.failed(ResponseStatus.SERVER_ERROR);
+ }
+ }
/**
* 鍒锋柊JWT浠ょ墝,鐢ㄦ棫鐨勪护鐗屾崲鏂扮殑浠ょ墝
diff --git a/server/system_service/src/main/java/com/doumee/core/model/LoginUserInfo.java b/server/system_service/src/main/java/com/doumee/core/model/LoginUserInfo.java
index 6d84788..907be16 100644
--- a/server/system_service/src/main/java/com/doumee/core/model/LoginUserInfo.java
+++ b/server/system_service/src/main/java/com/doumee/core/model/LoginUserInfo.java
@@ -4,6 +4,7 @@
import com.doumee.dao.system.model.SystemPermission;
import com.doumee.dao.system.model.SystemRole;
import com.doumee.dao.system.model.SystemUser;
+import com.github.xiaoymin.knife4j.core.util.CollectionUtils;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.beans.BeanUtils;
@@ -59,15 +60,19 @@
loginUserInfo.setCompany(company);
// 璁剧疆瑙掕壊淇℃伅
List<String> rs = new ArrayList<>();
- for (SystemRole role : roles) {
- rs.add(role.getCode());
+ if(CollectionUtils.isNotEmpty(roles)){
+ for (SystemRole role : roles) {
+ rs.add(role.getCode());
+ }
}
loginUserInfo.setSessionId(sessionId);
loginUserInfo.setRoles(rs);
// 璁剧疆鏉冮檺淇℃伅
List<String> pms = new ArrayList<>();
- for (SystemPermission permission : permissions) {
- pms.add(permission.getCode());
+ if(CollectionUtils.isNotEmpty(permissions)){
+ for (SystemPermission permission : permissions) {
+ pms.add(permission.getCode());
+ }
}
loginUserInfo.setPermissions(pms);
return loginUserInfo;
diff --git a/server/system_service/src/main/java/com/doumee/core/utils/Constants.java b/server/system_service/src/main/java/com/doumee/core/utils/Constants.java
index f76dfc4..43106c6 100644
--- a/server/system_service/src/main/java/com/doumee/core/utils/Constants.java
+++ b/server/system_service/src/main/java/com/doumee/core/utils/Constants.java
@@ -1,14 +1,16 @@
package com.doumee.core.utils;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.doumee.core.model.LoginUserInfo;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.PropertyNamingStrategy;
import io.swagger.models.auth.In;
import org.apache.batik.util.Platform;
-import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
+import org.springframework.util.CollectionUtils;
import java.io.IOException;
import java.math.BigDecimal;
@@ -152,6 +154,11 @@
// 瓒呮椂棰勮閰嶇疆
public static final String TIMEOUT_WARNING = "TIMEOUT_WARNING";
// FTP鏂囦欢鏈嶅姟鍣ㄨ祫婧愯闂湴鍧�
+ //鏈堝彴棰勭害鎸囧崡
+ public static final String PLATFORM_BOOKING_TIPS = "PLATFORM_BOOKING_TIPS";
+ //鏈堝彴瀵艰鍥�
+ public static final String PLATFORM_GUIDEMAP = "PLATFORM_GUIDEMAP";
+
public static String getRandom6Num( ) {
Random random = new Random();
@@ -453,6 +460,7 @@
int cityUseCar = 3;//甯傚唴鐢ㄨ溅
int unCityUseCar = 4;//甯傚鐢ㄨ溅
int logisticsCarUse = 5;//鐗╂祦杞﹂绾�
+ int reason = 6;//鍏ュ洯鍘熷洜
}
@@ -466,6 +474,10 @@
}else if(Constants.equalsInteger(approveType,Constants.approveObjectType.cityUseCar)
||Constants.equalsInteger(approveType,Constants.approveObjectType.unCityUseCar)){
return Constants.noticesObjectType.useCar;
+ }else if(Constants.equalsInteger(approveType,Constants.approveObjectType.logisticsCarUse)){
+ return Constants.noticesObjectType.logisticsCarUse;
+ }else if(Constants.equalsInteger(approveType, approveObjectType.reason)){
+ return noticesObjectType.reason;
}else {
return Constants.noticesObjectType.system;
}
@@ -481,6 +493,7 @@
int dangerDeal = 3;//闅愭偅澶勭悊
int logisticsCarUse = 4;//鐗╂祦杞﹀鎵�
int system = 5;//绯荤粺娑堟伅
+ int reason = 6;//鍏ュ洯鍘熷洜
}
diff --git a/server/system_service/src/main/java/com/doumee/core/utils/DateUtil.java b/server/system_service/src/main/java/com/doumee/core/utils/DateUtil.java
index 11635cf..a4cd38c 100644
--- a/server/system_service/src/main/java/com/doumee/core/utils/DateUtil.java
+++ b/server/system_service/src/main/java/com/doumee/core/utils/DateUtil.java
@@ -1823,14 +1823,6 @@
// StringUtil.getNotNullStr(request.getParameter(strParamName));
// return getDateByString(strStr);
// }
- /**
- * 寰楀埌褰撳墠鏃ユ湡锛屾牸寮弝yyy-MM-dd銆�
- *
- * @return String 鏍煎紡鍖栫殑鏃ユ湡瀛楃涓�
- */
- public static String getCurrDate() {
- return getFormattedDate(getDateByString(""));
- }
/**
* 寰楀埌褰撳墠鏃ユ湡锛屾牸寮弝yyy-MM-dd銆�
@@ -1897,6 +1889,17 @@
}
/**
+ * 寰楀埌褰撳墠鏃ユ湡鏃堕棿,鏍煎紡涓簓yyy-MM-dd.
+ *
+ * @return String
+ */
+ public static String getCurrDate() {
+ Timestamp date = new Timestamp(System.currentTimeMillis());
+ SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+ return formatter.format(date);
+ }
+
+ /**
* 寰楀埌鎸囧畾鐨勬棩鏈燂紝濡備竴骞翠笁涓湀闆朵節澶╁悗(浠yyy/MM/dd鏍煎紡鏄剧ず)鍙傛暟涓�("yyyy/MM/dd",1,3,9)
*
* @param strFormat
diff --git a/server/system_service/src/main/java/com/doumee/service/system/SystemLoginService.java b/server/system_service/src/main/java/com/doumee/service/system/SystemLoginService.java
index 15316fd..f6ebaca 100644
--- a/server/system_service/src/main/java/com/doumee/service/system/SystemLoginService.java
+++ b/server/system_service/src/main/java/com/doumee/service/system/SystemLoginService.java
@@ -23,6 +23,7 @@
LoginUserInfo loginByPasswordNew (LoginDTO dto, ServerHttpRequest request);
+ LoginUserInfo driverLogin(LoginDTO dto, ServerHttpRequest request);
/**
* 鏍规嵁 openId鐧诲綍
* @param userId
diff --git a/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java b/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java
index 452cc27..0519b92 100644
--- a/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java
+++ b/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java
@@ -125,7 +125,7 @@
loginLog.setOsInfo(Utils.User_Client.getOS(request));
}
loginLog.setServerIp(Utils.Server.getIP());
- if(isDebug == null || !isDebug){
+ if(isDebug == null || !isDebug && dto.getCheckCode()){
// 鏍¢獙楠岃瘉鐮�
try {
captchaService.check(dto.getUuid(), dto.getCode());
@@ -171,6 +171,43 @@
}
+
+ @Override
+ public LoginUserInfo driverLogin(LoginDTO dto, ServerHttpRequest request) {
+ SystemLoginLog loginLog = new SystemLoginLog();
+ loginLog.setLoginUsername(dto.getUsername());
+ loginLog.setLoginTime(new Date());
+ loginLog.setSystemVersion(systemVersion);
+ loginLog.setLocation(Utils.Location.getLocationString(loginLog.getIp()));
+ if(request!=null&&request.getHeaders()!=null && request.getHeaders().size()>0){
+ loginLog.setIp(Utils.User_Client.getIP(request));
+ loginLog.setPlatform(Utils.User_Client.getPlatform(request));
+ loginLog.setClientInfo(Utils.User_Client.getBrowser(request));
+ loginLog.setOsInfo(Utils.User_Client.getOS(request));
+ }
+ loginLog.setServerIp(Utils.Server.getIP());
+ // 鏍规嵁鐢ㄦ埛鍚嶆煡璇㈢敤鎴峰璞�
+ SystemUser queryDto = new SystemUser();
+ queryDto.setUsername(dto.getUsername());
+ queryDto.setDeleted(Boolean.FALSE);
+ SystemUser user = systemUserService.findOne(queryDto);
+ if (user == null) {
+ throw new BusinessException(ResponseStatus.ACCOUNT_INCORRECT);
+ }
+ String pwd = Utils.Secure.encryptPassword(new String(dto.getPassword()), user.getSalt());
+ // 姣旇緝瀵嗙爜
+ if( !StringUtils.equals(pwd, user.getPassword())){
+ throw new BusinessException(ResponseStatus.ACCOUNT_INCORRECT);
+ }
+ Company company = new Company();
+ if(Objects.nonNull(user.getCompanyId())){
+ company = companyMapper.selectById(user.getCompanyId());
+ }
+ LoginUserInfo userInfo = LoginUserInfo.from(user, null, null,company,null);
+ return userInfo;
+ }
+
+
/**
* 鍐呴儴浜哄憳 涓� 鍙告満 鏍规嵁code鏌ヨopenId鍚庤繘琛岀櫥褰曟帴鍙�
* @return
diff --git a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/admin/PlatformCloudController.java b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/admin/PlatformCloudController.java
index dd7a89f..3ac0fde 100644
--- a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/admin/PlatformCloudController.java
+++ b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/admin/PlatformCloudController.java
@@ -9,6 +9,7 @@
import com.doumee.core.model.PageWrap;
import com.doumee.core.utils.Constants;
import com.doumee.dao.business.model.Platform;
+import com.doumee.service.business.PlatformJobService;
import com.doumee.service.business.PlatformService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
@@ -16,6 +17,7 @@
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
+import java.util.List;
/**
* @author 姹熻箘韫�
@@ -28,6 +30,9 @@
@Autowired
private PlatformService platformService;
+
+ @Autowired
+ private PlatformJobService platformJobService;
@PreventRepeat
@ApiOperation("鏂板缓")
@@ -77,6 +82,14 @@
return ApiResponse.success(platformService.findPage(pageWrap));
}
+
+ @ApiOperation("鏍规嵁鏈堝彴缁勮幏鍙栨湀鍙板垪琛ㄤ俊鎭�")
+ @GetMapping("/listByGroupId")
+ @CloudRequiredPermission("business:platform:query")
+ public ApiResponse<List<Platform>> listByGroupId (@RequestParam Integer groupId, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){
+ return ApiResponse.success(platformJobService.getPlatformList(groupId,this.getLoginUser(token)));
+ }
+
@ApiOperation("瀵煎嚭Excel")
@PostMapping("/exportExcel")
@CloudRequiredPermission("business:platform:exportExcel")
diff --git a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/DriverPlatformController.java b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/DriverPlatformController.java
index 422d503..688be9f 100644
--- a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/DriverPlatformController.java
+++ b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/DriverPlatformController.java
@@ -1,17 +1,17 @@
package com.doumee.cloud.web;
+import cn.hutool.http.useragent.Platform;
import com.doumee.api.BaseController;
import com.doumee.config.annotation.LoginNoRequired;
import com.doumee.config.annotation.LoginRequired;
import com.doumee.core.annotation.trace.Trace;
import com.doumee.core.model.ApiResponse;
+import com.doumee.core.model.LoginUserInfo;
import com.doumee.core.model.PageData;
import com.doumee.core.model.PageWrap;
import com.doumee.core.utils.Constants;
import com.doumee.core.utils.DateUtil;
-import com.doumee.dao.business.model.PlatformBooks;
-import com.doumee.dao.business.model.PlatformJob;
-import com.doumee.dao.business.model.Visits;
+import com.doumee.dao.business.model.*;
import com.doumee.dao.web.reqeust.*;
import com.doumee.dao.web.response.DriverHomeVO;
import com.doumee.dao.web.response.LineUpVO;
@@ -27,6 +27,7 @@
import java.math.BigDecimal;
import java.util.Date;
+import java.util.List;
/**
* Created by IntelliJ IDEA.
@@ -52,13 +53,24 @@
@Autowired
private PlatformBooksService platformBooksService;
+ @Autowired
+ private PlatformReasonService platformReasonService;
+
+
+
+ @ApiOperation("鍏ュ洯鍘熷洜")
+ @GetMapping("/platformReasonList")
+ public ApiResponse<List<PlatformReason>> platformReasonList (@RequestHeader(Constants.HEADER_USER_TOKEN) String token) {
+ List<PlatformReason> platformReasons = platformReasonService.findList(null);
+ return ApiResponse.success(platformReasons);
+ }
+
@ApiOperation("鍙告満棣栭〉淇℃伅")
@GetMapping("/driverHome")
public ApiResponse<DriverHomeVO> driverHome (@RequestHeader(Constants.HEADER_USER_TOKEN) String token) {
- DriverHomeVO driverHomeVO = platformJobService.getDriverHome(getLoginUser(token).getMemberId());
+ DriverHomeVO driverHomeVO = platformJobService.getDriverHome(getLoginUser(token));
return ApiResponse.success(driverHomeVO);
}
-
@ApiOperation("鏌ヨ鍙绾﹂噺")
@PostMapping("/checkSurplusNum")
@@ -69,14 +81,18 @@
@ApiOperation("鐗╂祦杞﹂绾�")
@PostMapping("/apply")
public ApiResponse<Integer> apply (@RequestBody PlatformBooksApplyDTO platformBooksApplyDTO , @RequestHeader(Constants.HEADER_USER_TOKEN) String token) {
- platformBooksApplyDTO.setUserId(getLoginUser(token).getMemberId());
+ LoginUserInfo loginUserInfo = getLoginUser(token);
+ platformBooksApplyDTO.setUserId(loginUserInfo.getMemberId());
+ platformBooksApplyDTO.setDriverId(loginUserInfo.getMemberId());
return ApiResponse.success(platformBooksService.apply(platformBooksApplyDTO));
}
@ApiOperation("鐗╂祦杞﹂绾﹁褰�")
@PostMapping("/page")
public ApiResponse<PageData<PlatformBooks>> findPage (@RequestBody PageWrap<PlatformBooks> pageWrap, @RequestHeader(Constants.HEADER_USER_TOKEN) String token) {
+ LoginUserInfo loginUserInfo = this.getLoginUser(token);
pageWrap.getModel().setQueryDate(DateUtil.getBeforDay(new Date(),30));
+ pageWrap.getModel().setDriverPhone(loginUserInfo.getMobile());
return ApiResponse.success(platformBooksService.findPage(pageWrap));
}
diff --git a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/PdaPlatformController.java b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/PdaPlatformController.java
index 8e81e40..bee4a37 100644
--- a/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/PdaPlatformController.java
+++ b/server/visits/dmvisit_admin/src/main/java/com/doumee/cloud/web/PdaPlatformController.java
@@ -8,10 +8,7 @@
import com.doumee.core.model.PageWrap;
import com.doumee.core.utils.Constants;
import com.doumee.core.utils.DateUtil;
-import com.doumee.dao.business.model.PlatformBooks;
-import com.doumee.dao.business.model.PlatformGroup;
-import com.doumee.dao.business.model.PlatformJob;
-import com.doumee.dao.business.model.PlatformShowParam;
+import com.doumee.dao.business.model.*;
import com.doumee.dao.web.reqeust.*;
import com.doumee.dao.web.response.DriverHomeVO;
import com.doumee.dao.web.response.LineUpVO;
@@ -54,10 +51,8 @@
@Autowired
private PlatformShowParamService platformShowParamService;
-
-
-
-
+ @Autowired
+ private PlatformService platformService;
@ApiOperation("鑾峰彇鏈堝彴缁勪俊鎭�")
@ApiImplicitParams({
@@ -69,9 +64,16 @@
}
@ApiOperation("鏇存柊鏈堝彴閰嶇疆淇℃伅")
- @GetMapping("/updUserPlatformConfig")
+ @PostMapping("/updUserPlatformConfig")
public ApiResponse updUserPlatformConfig (@RequestBody List<Integer> ids, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){
platformShowParamService.updUserConfig(ids,getLoginUser(token));
+ return ApiResponse.success("鎿嶄綔鎴愬姛");
+ }
+
+ @ApiOperation("淇敼绂佸惎鐢ㄧ姸鎬�")
+ @PostMapping("/updPlatformStatus")
+ public ApiResponse updPlatformStatus (@RequestBody Platform platform, @RequestHeader(Constants.HEADER_USER_TOKEN) String token){
+ platformService.updateStatusById(platform);
return ApiResponse.success("鎿嶄綔鎴愬姛");
}
@@ -131,9 +133,6 @@
platformJobService.platformInPark(jobOperateDTO);
return ApiResponse.success("鎿嶄綔鎴愬姛");
}
-
-
-
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/dto/ApproveDTO.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/dto/ApproveDTO.java
index e73c8fb..f88a2a0 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/dto/ApproveDTO.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/dto/ApproveDTO.java
@@ -18,7 +18,7 @@
@ApiModelProperty(value = "鍏宠仈涓氬姟涓婚敭")
private Integer objId;
- @ApiModelProperty(value = "鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害")
+ @ApiModelProperty(value = "鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害 6鍏ュ洯棰勭害")
private Integer objType;
@ApiModelProperty(value = "2瀹℃壒閫氳繃 3瀹℃壒鏈�氳繃")
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/Approve.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/Approve.java
index 0c89c3b..1836078 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/Approve.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/Approve.java
@@ -117,8 +117,8 @@
@ExcelColumn(name="鏄惁淇敼鐩殑鍦� 0鍚� 1鏄�")
private Integer addrParam;
- @ApiModelProperty(value = "鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害", example = "1")
- @ExcelColumn(name="鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害")
+ @ApiModelProperty(value = "鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害 6鍏ュ洯鍘熷洜", example = "1")
+ @ExcelColumn(name="鍏宠仈涓氬姟绫诲瀷锛�0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害 6鍏ュ洯鍘熷洜")
private Integer objType;
@ApiModelProperty(value = "绫诲瀷 0瀹℃壒 1鎶勯��", example = "1")
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/ApproveTempl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/ApproveTempl.java
index eef7d41..4bb6efd 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/ApproveTempl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/ApproveTempl.java
@@ -52,8 +52,8 @@
@ExcelColumn(name="澶囨敞")
private String remark;
- @ApiModelProperty(value = "鍚嶇О 0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1鏂藉伐浜哄憳璁垮鐢宠 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害", example = "1")
- @ExcelColumn(name="鍚嶇О 0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1鏂藉伐浜哄憳璁垮鐢宠 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害")
+ @ApiModelProperty(value = "鍚嶇О 0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1鏂藉伐浜哄憳璁垮鐢宠 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害 6鍏ュ洯鍘熷洜", example = "1")
+ @ExcelColumn(name="鍚嶇О 0闈炴柦宸ヤ汉鍛樿瀹㈢敵璇� 1鏂藉伐浜哄憳璁垮鐢宠 2璁垮鎶ュ 3鍏溅甯傚唴鐢ㄨ溅 4鍏溅瀹ゅ鐢ㄨ溅 5甯傚叕鍙哥墿娴佽溅棰勭害 6鍏ュ洯鍘熷洜")
private Integer type;
@ApiModelProperty(value = "鍚嶇О")
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformBooks.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformBooks.java
index cea4575..12e06bd 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformBooks.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformBooks.java
@@ -136,6 +136,10 @@
@TableField(exist = false)
private String queryDate;
+ @ApiModelProperty(value = "鍥剧墖鍓嶇紑")
+ @TableField(exist = false)
+ private String prefixUrl;
+
@ApiModelProperty(value = "瀹℃壒淇℃伅鏁版嵁")
@TableField(exist = false)
private ApproveDataVO approveDateVO;
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformJob.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformJob.java
index 57cfc6d..f3e24c0 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformJob.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/business/model/PlatformJob.java
@@ -264,7 +264,15 @@
@ApiModelProperty(value = "鍓嶆柟鎺掗槦鏁伴噺", example = "1")
@TableField(exist = false)
- private Long lineUpNum;
+ private Integer lineUpNum;
+
+ @ApiModelProperty(value = "棰勮绛夊緟鏃堕棿", example = "1")
+ @TableField(exist = false)
+ private String waitTime;
+
+ @ApiModelProperty(value = "棰勮瀹屾垚鏃堕棿", example = "1")
+ @TableField(exist = false)
+ private String finishTimeStr;
@ApiModelProperty(value = "鍏宠仈鏈堝彴缁勭紪鐮侊紙鍏宠仈platform_group琛級", example = "1")
@TableField(exist = false)
@@ -278,6 +286,9 @@
@TableField(exist = false)
private BigDecimal getDistance;
+ @ApiModelProperty(value = "鏈堝彴浣滀笟鏁堢巼锛堜竾鏀�/灏忔椂锛�", hidden = true)
+ @TableField(exist = false)
+ private BigDecimal workRate;
@ApiModelProperty(value = "涓氬姟瑙﹀彂鏃堕棿 鏃堕棿")
@TableField(exist = false)
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/reqeust/PlatformBooksApplyDTO.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/reqeust/PlatformBooksApplyDTO.java
index 6273b5f..0d46c53 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/reqeust/PlatformBooksApplyDTO.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/reqeust/PlatformBooksApplyDTO.java
@@ -19,6 +19,8 @@
@Api(tags = "鍏ュ洯棰勭害鐢宠淇℃伅" )
public class PlatformBooksApplyDTO {
+ @ApiModelProperty(value = "涓婚敭 - 淇敼浣跨敤")
+ private Integer id;
@ApiModelProperty(value = "鍚堝悓鍙�")
private String contractNum;
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/response/DriverHomeVO.java b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/response/DriverHomeVO.java
index e677f12..430b316 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/response/DriverHomeVO.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/dao/web/response/DriverHomeVO.java
@@ -19,4 +19,11 @@
@ApiModelProperty(value = "鏈堝彴浠诲姟鍒楄〃")
private List<PlatformJob> platformJobList;
+ @ApiModelProperty(value = "棰勭害鎸囧崡")
+ private String bookingTips;
+
+ @ApiModelProperty(value = "鍥尯瀵艰鍥�")
+ private String reservationMap;
+
+
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/ApproveService.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/ApproveService.java
index 6b2fb66..e6e7570 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/ApproveService.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/ApproveService.java
@@ -112,6 +112,8 @@
void createApproveFlow(Integer tempType,Integer businessId,Integer createMemberId);
+ void createApproveForPlatfrom(Integer tempId,Integer businessId,Integer createMemberId);
+
ApproveDataVO arrangeApprovedData(Integer businessId, Integer businessType, Integer memberId);
void approved(ApproveDTO approveDTO);
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/PlatformJobService.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/PlatformJobService.java
index ac8a7a8..a842e2d 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/PlatformJobService.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/PlatformJobService.java
@@ -1,7 +1,9 @@
package com.doumee.service.business;
+import com.doumee.core.model.LoginUserInfo;
import com.doumee.core.model.PageData;
import com.doumee.core.model.PageWrap;
+import com.doumee.dao.business.model.Platform;
import com.doumee.dao.business.model.PlatformJob;
import com.doumee.dao.web.reqeust.JobDetailDTO;
import com.doumee.dao.web.reqeust.JobOperateDTO;
@@ -102,7 +104,7 @@
*/
long count(PlatformJob platformJob);
- DriverHomeVO getDriverHome(Integer memberId);
+ DriverHomeVO getDriverHome(LoginUserInfo loginUserInfo);
/**
* 璺濈绛惧埌
@@ -172,4 +174,12 @@
*/
void finishWork(JobOperateDTO jobOperateDTO);
+ /**
+ * 鑾峰彇鏈堝彴涓嬬殑浠诲姟淇℃伅
+ * @param groupId
+ * @param loginUserInfo
+ * @return
+ */
+ List<Platform> getPlatformList(Integer groupId, LoginUserInfo loginUserInfo);
+
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/ApproveServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/ApproveServiceImpl.java
index 804ee30..b698dd5 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/ApproveServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/ApproveServiceImpl.java
@@ -31,6 +31,7 @@
import com.github.xiaoymin.knife4j.core.util.CollectionUtils;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
import io.swagger.models.auth.In;
+import javafx.application.Platform;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.apache.xpath.operations.Bool;
@@ -388,6 +389,52 @@
}
+ @Override
+ @Transactional(rollbackFor = {Exception.class,BusinessException.class})
+ public void createApproveForPlatfrom(Integer tempId,Integer businessId,Integer createMemberId){
+ //鏌ヨ澶勭悊妯℃澘
+ ApproveTempl approveTempl = approveTemplMapper.selectById(tempId);
+ if(Objects.isNull(approveTempl)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鏈煡璇㈠埌瀹℃壒娴侀厤缃ā鏉�");
+ }
+ //鏌ヨ閰嶇疆娴佺▼
+ List<ApproveParam> approveParamAllList = approveParamMapper.selectList(new QueryWrapper<ApproveParam>()
+ .lambda().eq(ApproveParam::getIsdeleted,Constants.ZERO)
+ .eq(ApproveParam::getTemplId,approveTempl.getId())
+ .orderByAsc(ApproveParam::getType)
+ .orderByAsc(ApproveParam::getLevel)
+ );
+ if(Objects.isNull(approveParamAllList)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鏈厤缃鎵规祦绋�");
+ }
+ //瀹℃壒閰嶇疆
+ List<ApproveParam> approveParamList = approveParamAllList.stream().filter(i->i.getType().equals(Constants.ZERO)).collect(Collectors.toList());
+ if(Objects.isNull(approveParamList)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鏈厤缃鎵规祦绋�");
+ }
+ List<ApproveParam> approveCopyList = approveParamAllList.stream().filter(i->i.getType().equals(Constants.ONE)).collect(Collectors.toList());
+
+ Member createMember = memberMapper.selectById(createMemberId);
+ if(Objects.isNull(createMember)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鐢宠浜虹粍缁囦俊鎭紓甯�");
+ }
+ List<Approve> approveList = new ArrayList<>();
+
+ this.organizeApproveData(approveTempl,approveParamList,createMember,businessId,approveList);
+
+ if(CollectionUtils.isEmpty(approveList)){
+ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀹℃壒娴侀厤缃敊璇�");
+ }
+
+ //澶勭悊鎶勯�佹暟鎹�
+ if(CollectionUtils.isNotEmpty(approveCopyList)){
+ this.organizeApproveCopyData(approveTempl,approveCopyList,businessId,approveList);
+ }
+ approveJoinMapper.insert(approveList);
+
+ }
+
+
/**
* 缁勭粐瀹℃壒娴佹暟鎹�
* @param approveTempl
@@ -555,8 +602,17 @@
jsonMap.put("eTime", "缁撴潫鏃堕棿:" + DateUtil.DateToStr(carUseBook.getEndTime() , "yyyy-MM-dd HH:mm"));
jsonMap.put("usrNum", StringUtils.isBlank(carUseBook.getMemberIds())?"涔樿溅浜烘暟: 0浜�": "涔樿溅浜烘暟: " +carUseBook.getMemberIds().split(",").length +"浜�");
jsonMap.put("mdd", StringUtils.isBlank(carUseBook.getAddr())?"鐩殑鍦�: - ": "鐩殑鍦�:" +carUseBook.getAddr());
- }else {
- throw new BusinessException(ResponseStatus.NOT_ALLOWED);
+ }else if(Constants.equalsInteger(noticeType,Constants.noticesObjectType.reason)){
+ //鐗╂祦杞﹂绾�
+ PlatformBooks platformBooks = platformBooksMapper.selectById(businessId);
+ if(Objects.isNull(platformBooks)){
+ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"鏈煡璇㈠埌涓氬姟鏁版嵁淇℃伅");
+ }
+ title = "銆愮墿娴佽溅鍏ュ洯棰勭害銆戠敵璇蜂汉 - " + platformBooks.getDriverName();
+ jsonMap.put("inType", "鍏ュ簱绫诲瀷锛�"+(Constants.equalsInteger(platformBooks.getInType(),Constants.ZERO)?"鏁存墭鐩�":"浠剁儫"));
+ jsonMap.put("totalNum", "鎬昏繍杈撻噺锛�"+platformBooks.getTotalNum()+"涓囨敮");
+ jsonMap.put("arriveDate", "鍒板満鏃堕棿锛�" + DateUtil.DateToStr(platformBooks.getArriveDate() , "yyyy-MM-dd HH:mm"));
+ jsonMap.put("carNum", "杞︾墝鐓э細"+platformBooks.getCarCodeFront());
}
return title;
}
@@ -1345,7 +1401,7 @@
}else if(approveDTO.getObjType().equals(Constants.approveObjectType.cityUseCar)||approveDTO.getObjType().equals(
Constants.approveObjectType.unCityUseCar)){
this.updDriver(approveDTO,approve,true);
- }else if(approveDTO.getObjType().equals(Constants.approveObjectType.logisticsCarUse)){
+ }else if(approveDTO.getObjType().equals(Constants.approveObjectType.reason)){
//鐗╂祦杞﹂绾�
PlatformBooks platformBooks = platformBooksMapper.selectById(approveDTO.getObjId());
if(Objects.isNull(platformBooks)){
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/MemberServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/MemberServiceImpl.java
index 693f779..a7ccd11 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/MemberServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/MemberServiceImpl.java
@@ -2002,6 +2002,7 @@
systemUser.setUsername(registerDriverDTO.getPhone());
systemUser.setRealname(registerDriverDTO.getName());
systemUser.setMemberId(member.getId());
+ systemUser.setMobile(registerDriverDTO.getPhone());
systemUser.setSalt(salt);
systemUser.setPassword(member.getPassward());
systemUser.setStatus(Constants.ZERO);
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformBooksServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformBooksServiceImpl.java
index a155825..68318b2 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformBooksServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformBooksServiceImpl.java
@@ -186,7 +186,7 @@
}
//鏌ヨ姣忔棩閰嶇疆鐨勬�婚绾﹂噺
PlatformReason platformReason = platformReasonMapper.selectById(platformBooksCheckNumDTO.getReasonId());
- if(Objects.isNull(platformReason)|| Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){
+ if(Objects.isNull(platformReason)|| !Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){
throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"鍏ュ洯鍘熷洜淇℃伅寮傚父,璇峰埛鏂伴噸璇�");
}
List<PlatformBooks> platformBooksList = platformBooksMapper.selectList(new QueryWrapper<PlatformBooks>().lambda()
@@ -225,23 +225,15 @@
throw new BusinessException(ResponseStatus.BAD_REQUEST);
}
PlatformReason platformReason = platformReasonMapper.selectById(platformBooksApplyDTO.getReasonId());
- if(Objects.isNull(platformReason)|| Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){
+ if(Objects.isNull(platformReason)|| !Constants.equalsInteger(platformReason.getIsdeleted(),Constants.ZERO)){
throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"鍏ュ洯鍘熷洜淇℃伅寮傚父,璇峰埛鏂伴噸璇�");
}
- ApproveTempl approveTempl = approveTemplMapper.selectOne(new QueryWrapper<ApproveTempl>().lambda()
- .eq(ApproveTempl::getIsdeleted,Constants.ZERO)
- .eq(ApproveTempl::getObjId,platformReason.getId())
- .last(" limit 1")
- );
+ ApproveTempl approveTempl = approveTemplMapper.selectById(platformReason.getId());
if(Objects.isNull(approveTempl)){
throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"鏈厤缃鎵规祦,璇疯仈绯荤鐞嗗憳");
}
-
- if(Constants.equalsInteger(platformBooksApplyDTO.getUserId(),platformBooksApplyDTO.getDriverId())){
- throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"浜哄憳淇℃伅鍖归厤閿欒");
- }
- if(Objects.nonNull(platformReason.getLimitNum())&&platformReason.getLimitNum().compareTo(platformBooksApplyDTO.getTotalNum())>0){
- throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瓒呭嚭鍏ュ洯鐢宠绾胯川閲�");
+ if(!Constants.equalsInteger(approveTempl.getIsdeleted(),Constants.ZERO)){
+ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀹℃壒娴佸凡鍋滅敤,璇疯仈绯荤鐞嗗憳");
}
PlatformBooks platformBooks = new PlatformBooks();
BeanUtils.copyProperties(platformBooksApplyDTO,platformBooks);
@@ -252,9 +244,45 @@
platformBooksMapper.insert(platformBooks);
//鍒涘缓瀹℃壒娴佷俊鎭�
- approveService.createApproveFlow(5,platformBooks.getId(),platformBooks.getDriverId());
+ approveService.createApproveForPlatfrom(platformReason.getApproveTemplId(),platformBooks.getId(),platformBooks.getDriverId());
return platformBooks.getId();
}
+
+
+
+// @Override
+ @Transactional(rollbackFor = {BusinessException.class,Exception.class})
+ public Integer edit(PlatformBooksApplyDTO platformBooksApplyDTO){
+ if(Objects.isNull(platformBooksApplyDTO)
+ || Objects.isNull(platformBooksApplyDTO.getId())
+ || StringUtils.isBlank(platformBooksApplyDTO.getContractNum())
+ || Objects.isNull(platformBooksApplyDTO.getArriveDate())
+ || Objects.isNull(platformBooksApplyDTO.getInType())
+ || Objects.isNull(platformBooksApplyDTO.getTotalNum())
+ || StringUtils.isBlank(platformBooksApplyDTO.getCarCodeFront())
+ || StringUtils.isBlank(platformBooksApplyDTO.getCarCodeBack())
+ || Objects.isNull(platformBooksApplyDTO.getDriverId())
+ || StringUtils.isBlank(platformBooksApplyDTO.getDriverPhone())
+ || StringUtils.isBlank(platformBooksApplyDTO.getDriverName())
+ || StringUtils.isBlank(platformBooksApplyDTO.getTransportImg())
+ || Objects.isNull(platformBooksApplyDTO.getReasonId())
+ || StringUtils.isBlank(platformBooksApplyDTO.getInReason())
+ ){
+ throw new BusinessException(ResponseStatus.BAD_REQUEST);
+ }
+ PlatformBooks platformBooks = platformBooksMapper.selectById(platformBooksApplyDTO.getId());
+ if(Objects.isNull(platformBooks)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY);
+ }
+ if(!Constants.equalsInteger(platformBooks.getStatus(),Constants.ZERO)){
+ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"涓氬姟鐘舵�佸凡娴佽浆");
+ }
+ BeanUtils.copyProperties(platformBooksApplyDTO,platformBooks);
+ platformBooks.setEditDate(new Date());
+ platformBooksMapper.insert(platformBooks);
+ return platformBooks.getId();
+ }
+
@Override
@@ -263,8 +291,12 @@
if(Objects.isNull(model)){
throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鏈煡璇㈠埌棰勭害璁板綍");
}
+ String prefixUrl = systemDictDataBiz.queryByCode(Constants.FTP,Constants.FTP_RESOURCE_PATH).getCode() +
+ systemDictDataBiz.queryByCode(Constants.FTP,Constants.PLATFORM).getCode();
+ model.setPrefixUrl(prefixUrl);
+
ApproveDataVO approveDataVO = approveService.arrangeApprovedData(id,
- 5,
+ 6,
memberId);
model.setApproveDateVO(approveDataVO);
List<Approve> approveList = approveDataVO.getApproveList();
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformGroupServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformGroupServiceImpl.java
index 7dcc045..05ad10f 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformGroupServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformGroupServiceImpl.java
@@ -6,19 +6,24 @@
import com.doumee.core.model.PageData;
import com.doumee.core.model.PageWrap;
import com.doumee.core.utils.Constants;
+import com.doumee.core.utils.DateUtil;
import com.doumee.core.utils.Utils;
import com.doumee.dao.business.PlatformGroupMapper;
import com.doumee.dao.business.PlatformShowParamMapper;
+import com.doumee.dao.business.join.PlatformJobJoinMapper;
import com.doumee.dao.business.join.PlatformJoinMapper;
import com.doumee.dao.business.model.Platform;
import com.doumee.dao.business.model.PlatformGroup;
+import com.doumee.dao.business.model.PlatformJob;
import com.doumee.dao.business.model.PlatformShowParam;
import com.doumee.service.business.PlatformGroupService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.doumee.service.business.PlatformJobService;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
+import lombok.extern.java.Log;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
@@ -44,6 +49,9 @@
@Autowired
private PlatformShowParamMapper platformShowParamMapper;
+
+ @Autowired
+ private PlatformJobJoinMapper platformJobJoinMapper;
@Override
public Integer create(PlatformGroup platformGroup) {
@@ -206,7 +214,6 @@
.selectAll(Platform.class)
.select(" ( select count(1) from platform_job pj where t.id = pj.PLATFORM_ID and pj.STATUS = "+Constants.PlatformJobStatus.WORKING.getKey()+" ) as workStatus ")
.eq(Platform::getIsdeleted, Constants.ZERO)
- .eq(Platform::getStatus, Constants.ZERO)
.eq(Objects.nonNull(queryType)&&!Constants.equalsInteger(queryType,Constants.ZERO),Platform::getStatus,Constants.ZERO)
);
//澶勭悊鎴戠殑鏈堝彴淇℃伅 鏄惁閰嶇疆闅愯棌
@@ -240,4 +247,7 @@
}
+
+
+
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java
index d8e0284..2544ffb 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java
@@ -4,6 +4,7 @@
import com.doumee.biz.system.SystemDictDataBiz;
import com.doumee.core.constants.ResponseStatus;
import com.doumee.core.exception.BusinessException;
+import com.doumee.core.model.LoginUserInfo;
import com.doumee.core.model.PageData;
import com.doumee.core.model.PageWrap;
import com.doumee.core.utils.Constants;
@@ -12,6 +13,7 @@
import com.doumee.core.utils.Utils;
import com.doumee.dao.business.*;
import com.doumee.dao.business.join.PlatformJobJoinMapper;
+import com.doumee.dao.business.join.PlatformJoinMapper;
import com.doumee.dao.business.model.*;
import com.doumee.dao.web.reqeust.JobDetailDTO;
import com.doumee.dao.web.reqeust.JobOperateDTO;
@@ -33,6 +35,7 @@
import org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
+import java.math.RoundingMode;
import java.util.Date;
import java.util.List;
import java.util.Objects;
@@ -58,8 +61,9 @@
@Autowired
private SystemDictDataBiz systemDictDataBiz;
+
@Autowired
- private PlatformMapper platformMapper;
+ private PlatformJoinMapper platformJoinMapper;
@Autowired
private PlatformLogMapper platformLogMapper;
@@ -69,6 +73,12 @@
@Autowired
private PlatformWmsDetailMapper platformWmsDetailMapper;
+
+ @Autowired
+ private PlatformGroupMapper platformGroupMapper;
+
+ @Autowired
+ private PlatformShowParamMapper platformShowParamMapper;
@Override
@@ -131,9 +141,13 @@
@Override
public PageData<PlatformJob> findPage(PageWrap<PlatformJob> pageWrap) {
IPage<PlatformJob> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity());
- QueryWrapper<PlatformJob> queryWrapper = new QueryWrapper<>();
+ MPJLambdaWrapper<PlatformJob> queryWrapper = new MPJLambdaWrapper<>();
Utils.MP.blankToNull(pageWrap.getModel());
- queryWrapper.lambda()
+ queryWrapper
+ .selectAll(PlatformJob.class)
+ .selectAs(Platform::getName,PlatformJob::getPlatformName)
+ .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate)
+ .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId)
.eq(pageWrap.getModel().getId() != null, PlatformJob::getId, pageWrap.getModel().getId())
.eq(pageWrap.getModel().getCreator() != null, PlatformJob::getCreator, pageWrap.getModel().getCreator())
.ge(pageWrap.getModel().getCreateDate() != null, PlatformJob::getCreateDate, Utils.Date.getStart(pageWrap.getModel().getCreateDate()))
@@ -216,13 +230,18 @@
queryWrapper.orderByAsc(sortData.getProperty());
}
}
-
- PageData<PlatformJob> pageData = PageData.from(platformJobMapper.selectPage(page, queryWrapper));
- pageData.getRecords().forEach(i->{
+ IPage<PlatformJob> platformJobIPage = platformJobJoinMapper.selectJoinPage(page,PlatformJob.class,queryWrapper);
+ platformJobIPage.getRecords().forEach(i->{
i.dealTime();
this.getWmsJobData(i);
});
- return pageData;
+ return PageData.from(platformJobIPage);
+// PageData<PlatformJob> pageData = PageData.from(platformJobMapper.selectPage(page, queryWrapper));
+// pageData.getRecords().forEach(i->{
+// i.dealTime();
+// this.getWmsJobData(i);
+// });
+// return pageData;
}
@@ -250,12 +269,60 @@
platformWmsJob.setPlatformWmsDetailList(platformWmsDetailList);
platformJob.setPlatformWmsJob(platformWmsJob);
}
- }
-
-
+ }
}
+ public void queryWaitNum(PlatformJob platformJob){
+ if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WAIT_CALL.getKey())){
+ //鏌ヨ鍓嶆柟鎺掗槦鏁伴噺
+ List<PlatformJob> lineUpNum = platformJobMapper.selectList(new QueryWrapper<PlatformJob>().lambda()
+ .eq(PlatformJob::getIsdeleted,Constants.ZERO)
+ .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CALL.getKey()
+ ,Constants.PlatformJobStatus.IN_WAIT.getKey()
+ ,Constants.PlatformJobStatus.TRANSFERING.getKey())
+ .gt(PlatformJob::getSignDate,platformJob.getSignDate())
+ .eq(PlatformJob::getPlatformGroupId,platformJob.getPlatformGroupId())
+ .like(PlatformJob::getArriveDate,DateUtil.getDate(platformJob.getArriveDate(),"yyyy-MM-dd")));
+ platformJob.setLineUpNum(lineUpNum.size());
+ BigDecimal sumWorkRate = platformJob.getTotalNum();
+ for (PlatformJob linePlatformJob:lineUpNum) {
+ this.getWmsJobData(linePlatformJob);
+ sumWorkRate = sumWorkRate.add(linePlatformJob.getTotalNum());
+ }
+ //璁$畻棰勮绛夊緟鏃堕棿
+ List<Platform> platformList = platformJoinMapper.selectList(new QueryWrapper<Platform>().lambda().eq(Platform::getIsdeleted,Constants.ZERO).eq(Platform::getGroupId,platformJob.getPlatformGroupId()));
+ BigDecimal workRate = platformList.stream().map(m->m.getWorkRate()).reduce(BigDecimal.ZERO,BigDecimal::add);
+ if(sumWorkRate.compareTo(BigDecimal.ZERO) == Constants.ZERO|| workRate.compareTo(BigDecimal.ZERO) == Constants.ZERO ){
+ BigDecimal sumMinute = sumWorkRate.divide(workRate,1, RoundingMode.HALF_DOWN).multiply(BigDecimal.valueOf(60L));
+ Integer sumMinuteInteger = sumMinute.intValue();
+ Integer hours = sumMinuteInteger/60;
+ Integer minus = sumMinuteInteger%60;
+ String waitTime = "棰勮绛夊緟锛�";
+ if(!Constants.equalsInteger(hours,Constants.ZERO)){
+ waitTime = waitTime + hours + "灏忔椂";
+ }
+ if(!Constants.equalsInteger(hours,Constants.ZERO)){
+ waitTime = waitTime + minus + "鍒嗛挓";
+ }
+ platformJob.setWaitTime(waitTime);
+ }
+ }else if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WORKING.getKey())){
+ //鏌ヨ鏈�鍚庡紑濮嬩换鍔$殑鏈堝彴璁板綍 鏃ュ織琛� 鍥犱负瀛樺湪寮傚父鎸傝捣 杞Щ 绛夐棶棰�
+ PlatformLog platformLog = platformLogMapper.selectOne(new QueryWrapper<PlatformLog>().lambda()
+ .eq(PlatformLog::getJobId,platformJob.getId())
+ .eq(PlatformLog::getObjType,Constants.PlatformJobStatus.WORKING.getKey())
+ .orderByDesc(PlatformLog::getCreateDate)
+ .last(" limit 1")
+ );
+ if(Objects.nonNull(platformLog)){
+ BigDecimal sumMinute = platformJob.getTotalNum().divide(platformJob.getWorkRate(),1, RoundingMode.HALF_DOWN).multiply(BigDecimal.valueOf(60L));
+ platformJob.setFinishTimeStr(DateUtil.DateToStr(DateUtil.afterMinutesDate(platformLog.getCreateDate(),sumMinute.intValue()),"HH:mm"));
+ }
+ }
+ }
+
+
@Override
public long count(PlatformJob platformJob) {
QueryWrapper<PlatformJob> wrapper = new QueryWrapper<>(platformJob);
@@ -264,17 +331,34 @@
//TODO
@Override
- public DriverHomeVO getDriverHome(Integer memberId){
+ public DriverHomeVO getDriverHome(LoginUserInfo loginUserInfo){
DriverHomeVO driverHomeVO = new DriverHomeVO();
//TODO 杞挱鍥�
- List<PlatformJob> platformJobList = platformJobMapper.selectList(new QueryWrapper<PlatformJob>()
- .lambda()
- .eq(PlatformJob::getDriverId,memberId)
-// .like(PlatformJob::get)
- .orderByDesc(PlatformJob::getId));
+ List<PlatformJob> platformJobList = platformJobJoinMapper.selectJoinList(PlatformJob.class,new MPJLambdaWrapper<PlatformJob>()
+ .selectAll(PlatformJob.class)
+ .selectAs(Platform::getName,PlatformJob::getPlatformName)
+ .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate)
+ .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId)
+ .eq(PlatformJob::getIsdeleted,Constants.ZERO)
+ .eq(PlatformJob::getDrivierPhone,loginUserInfo.getMobile())
+ .like(PlatformJob::getArriveDate,DateUtil.getCurrDate())
+ .orderByDesc(PlatformJob::getId)
+ );
+ for (PlatformJob platformJob:platformJobList) {
+ //澶勭悊WSM鏁伴噺
+ this.getWmsJobData(platformJob);
+ //鏌ヨ鍓嶆柟鎺掗槦鏁伴噺
+ this.queryWaitNum(platformJob);
+ }
+
+
driverHomeVO.setPlatformJobList(platformJobList);
+ // 鍥尯瀵艰鍥� 鍥剧墖
+ driverHomeVO.setReservationMap(systemDictDataBiz.queryByCode(Constants.PLATFORM,Constants.PLATFORM_GUIDEMAP).getCode());
+ // 棰勭害鎸囧崡 鏂囨湰
+ driverHomeVO.setBookingTips(systemDictDataBiz.queryByCode(Constants.PLATFORM,Constants.PLATFORM_BOOKING_TIPS).getCode());
return driverHomeVO;
}
@@ -369,18 +453,12 @@
}
}else if( Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WAIT_CALL.getKey())
|| Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.IN_WAIT.getKey())
- ){//鏌ヨ鎺掗槦鎯呭喌
- Long lineUpNum = platformJobMapper.selectCount(new QueryWrapper<PlatformJob>().lambda()
- .eq(PlatformJob::getIsdeleted,Constants.ZERO)
- .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CALL.getKey()
- ,Constants.PlatformJobStatus.IN_WAIT.getKey()
- ,Constants.PlatformJobStatus.TRANSFERING.getKey())
- .gt(PlatformJob::getSignDate,platformJob.getSignDate())
- .like(PlatformJob::getArriveDate,DateUtil.getDate(platformJob.getArriveDate(),"yyyy-MM-dd")));
- platformJob.setLineUpNum(lineUpNum);
+ ){
+ //鏌ヨ鍓嶆柟鎺掗槦鏁伴噺
+ this.queryWaitNum(platformJob);
}else if(Constants.equalsInteger(platformJob.getStatus(),Constants.PlatformJobStatus.WORKING.getKey())){
//浣滀笟鏈堝彴淇℃伅
- Platform platform = platformMapper.selectById(platformJob.getPlatformId());
+ Platform platform = platformJoinMapper.selectById(platformJob.getPlatformId());
if(Objects.nonNull(platform)){
platformJob.setPlatformName(platform.getName());
}
@@ -417,7 +495,7 @@
);
//鑾峰彇鎵�鏈夋湀鍙扮粍
List<Integer> platformIdList = platformJobList.stream().map(m->m.getPlatformGroupId()).collect(Collectors.toList());
- List<Platform> platformList = platformMapper.selectList(new QueryWrapper<Platform>().lambda()
+ List<Platform> platformList = platformJoinMapper.selectList(new QueryWrapper<Platform>().lambda()
.eq(Platform::getIsdeleted,Constants.ZERO)
.in(Platform::getId,platformIdList));
@@ -841,8 +919,79 @@
}
+ @Override
+ public List<Platform> getPlatformList(Integer groupId, LoginUserInfo loginUserInfo){
+ //鏌ヨ鏈堝彴缁勪笅鎵�鏈夋湀鍙�
+ List<Platform> allPlatformList = platformJoinMapper.selectJoinList(Platform.class,
+ new MPJLambdaWrapper<Platform>()
+ .selectAll(Platform.class)
+ .select(" ( select count(1) from platform_job pj where t.id = pj.PLATFORM_ID and pj.STATUS = "+Constants.PlatformJobStatus.WORKING.getKey()+" ) as workStatus ")
+ .eq(Platform::getIsdeleted, Constants.ZERO)
+ .eq(Platform::getStatus,Constants.ZERO)
+ .eq(Platform::getGroupId,groupId)
+ );
+ this.getPlatformShow(allPlatformList,loginUserInfo);
+ for (Platform platform:allPlatformList) {
+ this.getJobByPlatform(platform,loginUserInfo);
+ }
+ return allPlatformList;
+ }
+
+ /**
+ * 鏌ヨ鏈堝彴鐨勫紑鍚儏鍐�
+ * @param allPlatformList
+ * @param loginUserInfo
+ */
+ public void getPlatformShow(List<Platform> allPlatformList , LoginUserInfo loginUserInfo){
+ //澶勭悊鎴戠殑鏈堝彴淇℃伅 鏄惁閰嶇疆闅愯棌
+ List<PlatformShowParam> platformShowParamList = platformShowParamMapper.selectList(new QueryWrapper<PlatformShowParam>()
+ .lambda()
+ .eq(PlatformShowParam::getIsdeleted, Constants.ZERO)
+ .eq(PlatformShowParam::getMemberId,loginUserInfo.getMemberId())
+ );
+ //濡傛灉鏈厤缃鏁版嵁 鍒欏叏閮ㄦ樉绀�
+ if(CollectionUtils.isEmpty(platformShowParamList)){
+ for (Platform platform:allPlatformList) {
+ platform.setShowConfig(true);
+ }
+ }else{
+ //鏍规嵁閰嶇疆鏄剧ず鏁版嵁
+ for (PlatformShowParam platformShowParam:platformShowParamList) {
+ for (Platform platform:allPlatformList) {
+ if(Constants.equalsInteger(platform.getId(),platformShowParam.getPlatformId())){
+ platform.setShowConfig(true);
+ break;
+ }
+ }
+ }
+ }
+ }
-
+ /**
+ * 鑾峰彇鏈堝彴涓嬬殑浠诲姟鍒楄〃
+ * @param platform
+ * @param loginUserInfo
+ */
+ public void getJobByPlatform(Platform platform,LoginUserInfo loginUserInfo){
+ List<PlatformJob> platformJobList = platformJobJoinMapper.selectJoinList(PlatformJob.class,new MPJLambdaWrapper<PlatformJob>()
+ .selectAll(PlatformJob.class)
+ .selectAs(Platform::getName,PlatformJob::getPlatformName)
+ .selectAs(Platform::getWorkRate,PlatformJob::getWorkRate)
+ .leftJoin(Platform.class,Platform::getId,PlatformJob::getPlatformId)
+ .eq(PlatformJob::getPlatformId,platform.getId())
+ .eq(PlatformJob::getIsdeleted,Constants.ZERO)
+ .eq(PlatformJob::getDrivierPhone,loginUserInfo.getMobile())
+ .like(PlatformJob::getArriveDate, DateUtil.getCurrDate())
+ .orderByDesc(PlatformJob::getId)
+ );
+ for (PlatformJob platformJob:platformJobList) {
+ //澶勭悊WSM鏁伴噺
+ this.getWmsJobData(platformJob);
+ //鏌ヨ鍓嶆柟鎺掗槦鏁伴噺
+ this.queryWaitNum(platformJob);
+ }
+ platform.setWorkJobList(platformJobList);
+ }
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformReasonServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformReasonServiceImpl.java
index aaa5b1e..7500514 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformReasonServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformReasonServiceImpl.java
@@ -106,6 +106,7 @@
@Override
public List<PlatformReason> findList(PlatformReason platformReason) {
QueryWrapper<PlatformReason> wrapper = new QueryWrapper<>(platformReason);
+ wrapper.eq("isdeleted",Constants.ZERO);
return platformReasonMapper.selectList(wrapper);
}
diff --git a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitReasonServiceImpl.java b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitReasonServiceImpl.java
index e34a01b..49d54a6 100644
--- a/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitReasonServiceImpl.java
+++ b/server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitReasonServiceImpl.java
@@ -139,4 +139,8 @@
QueryWrapper<VisitReason> wrapper = new QueryWrapper<>(visitReason);
return visitReasonMapper.selectCount(wrapper);
}
+
+
+
+
}
--
Gitblit v1.9.3