From d916428e822cdc8004768ac9d52d98eb52644129 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期三, 28 八月 2024 15:37:49 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
server/system_service/src/main/java/com/doumee/core/utils/Constants.java | 65 +++++++++++++
h5/pages/driver/taskDetail.vue | 35 +++++-
h5/pages/staffLogin/login.vue | 7
h5/api/driver.js | 24 ++++
h5/pages/driver/index.vue | 59 +++++------
h5/pages/staff/task/driver.vue | 3
h5/pages/driver/reserved.vue | 23 +++
h5/pages/driver/reservedDetail.vue | 40 +++++---
h5/pages/driver/login.vue | 2
h5/pages/driver/queueUp.vue | 10 ++
h5/store/index.js | 2
11 files changed, 204 insertions(+), 66 deletions(-)
diff --git a/h5/api/driver.js b/h5/api/driver.js
index 5c9bd7f..99bc2ca 100644
--- a/h5/api/driver.js
+++ b/h5/api/driver.js
@@ -49,6 +49,14 @@
data
})
}
+// 鐗╂祦杞﹂绾︿慨鏀�
+export const driverCarApplyEdit = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/applyEdit',
+ method: 'post',
+ data
+ })
+}
// 鐗╂祦杞︽挙閿�
export const driverCarRevoke= (data) => {
return http({
@@ -72,4 +80,20 @@
method: 'get',
data
})
+}
+// 鏈堝彴 鎺掗槦鎯呭喌
+export const driverLineUpDetail = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/lineUpDetail',
+ method: 'post',
+ data
+ })
+}
+// 鏈堝彴 浠诲姟璇︽儏
+export const driverTaskJobDetail = (data) => {
+ return http({
+ url: 'visitsAdmin/cloudService/web/driverPlatform/jobDetail',
+ method: 'post',
+ data
+ })
}
\ No newline at end of file
diff --git a/h5/pages/driver/index.vue b/h5/pages/driver/index.vue
index 2df909e..43cd875 100644
--- a/h5/pages/driver/index.vue
+++ b/h5/pages/driver/index.vue
@@ -13,53 +13,37 @@
<!-- -->
<view class="task_list">
<swiper circular class="task_swiper">
- <swiper-item>
+ <swiper-item v-for="item in taskList" :key="item.id">
<view class="item">
<view class="head">
- <view class="name">杩愯緭鍗�222</view>
+ <view class="name">杩愯緭鍗晎{ item.contractNum }}</view>
<view class="status">
- <view class="text">璇风‘璁や换鍔�</view>
- <view class="time">棰勮绛夊緟锛�12灏忔椂</view>
+ <view class="text" v-if="item.status == 0">璇风‘璁や换鍔�</view>
+ <view class="text" v-if="item.status == 1">璇蜂簬{{item.arriveDate.slice(5,11)}}鐜板満绛惧埌</view>
+ <view class="text" v-if="item.status == 2">鍓嶆柟鎺掗槦锛歿{item.lineUpNum}}杈�</view>
+ <view class="text" v-if="item.status == 3">璇峰叆鍥繘鍏ョ瓑寰呭尯</view>
+ <view class="text" v-if="item.status == 4">璇峰叆鍥仠闈�1鍙锋湀鍙颁綔涓�</view>
+ <view class="text" v-if="item.status == 5">1鍙锋湀鍙颁綔涓氫腑</view>
+ <view class="text" v-if="item.status == 6">浣滀笟宸插畬鎴�</view>
+ <view class="time" v-if="item.waitTime">{{ item.waitTime }}</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>
+ <text>{{ item.carCodeFront }}</text>
</view>
<view class="plate">
<image src="@/static/driver/wuliu_ic_huowu@2x.png" class="icon" mode=""></image>
- <text>3000涓�</text>
+ <text>{{ item.totalNum }}涓囨敮</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 class="time" v-if="item.arriveDate">{{ item.arriveDate.slice(5) }}</view>
+ <view v-if="item.status == 0" class="sub_btn" @click="handleTask(item)">纭浠诲姟</view>
+ <view v-if="item.status == 1" class="sub_btn" @click="handleSign(item)">绔嬪嵆绛惧埌</view>
+ <view v-if="item.status == 2" class="sub_btn" @click="handleQueup(item)">鏌ョ湅鎺掗槦</view>
</view>
</view>
</view>
@@ -112,13 +96,21 @@
export default {
data() {
return {
- driverInfo: uni.getStorageSync('driverInfo')
+ taskList: [],
+ driverInfo: uni.getStorageSync('driverInfo'),
+
};
},
created() {
this.initData();
},
methods: {
+ handleSign(item) {
+ uni.navigateTo({
+ url: '/pages/driver/taskDetail?id=' + item.id
+ });
+ },
+ handleQueup(item) {},
initData() {
driverHomeData().then(res => {
if (res.code == 200) {
@@ -126,6 +118,7 @@
bookingTips: res.data.bookingTips,
reservationMap: res.data.reservationMap
});
+ this.taskList = res.data.platformJobList || []
}
});
},
diff --git a/h5/pages/driver/login.vue b/h5/pages/driver/login.vue
index 4dede46..1372f80 100644
--- a/h5/pages/driver/login.vue
+++ b/h5/pages/driver/login.vue
@@ -37,7 +37,7 @@
data() {
return {
form: {
- username: '13996529050',
+ username: '13333333333',
password: '1'
},
isShowProtocol: false,
diff --git a/h5/pages/driver/queueUp.vue b/h5/pages/driver/queueUp.vue
index 3b836b1..2b13d91 100644
--- a/h5/pages/driver/queueUp.vue
+++ b/h5/pages/driver/queueUp.vue
@@ -35,13 +35,23 @@
</template>
<script>
+ import { driverLineUpDetail } from '@/api'
export default {
data() {
return {
}
},
+ onLoad() {
+ this.getData()
+ },
methods: {
+ getData() {
+ driverLineUpDetail({
+ mobile: uni.getStorageSync('driverInfo').mobile,
+ queryType: 0
+ })
+ },
handleCheck() {
uni.navigateTo({
url: "/pages/driver/queueUpRecord"
diff --git a/h5/pages/driver/reserved.vue b/h5/pages/driver/reserved.vue
index 813062c..3477489 100644
--- a/h5/pages/driver/reserved.vue
+++ b/h5/pages/driver/reserved.vue
@@ -121,7 +121,7 @@
<script>
import keyboardInput from '@/components/keyboard-input/keyboard-input.vue';
-import { uploadUrl, driverCarApply, driverReasonList } from '@/api';
+import { uploadUrl, driverCarApply,driverCarApplyEdit, driverReasonList, driverApplyDetail } from '@/api';
import dayjs from 'dayjs'
export default {
components: {
@@ -142,7 +142,10 @@
inputType: ''
};
},
- created() {
+ onLoad(option) {
+ if(option && option.id){
+ this.getDetail(option.id, option.type)
+ }
this.initData()
},
methods: {
@@ -158,9 +161,21 @@
if (!param.carCodeBack) return this.showToast('璇疯緭鍏ヨ溅鍚庣墝鍙�')
if (!param.transportImgFull) return this.showToast('璇蜂笂浼犲噯杩愯瘉鐓х墖')
param.arriveDate = param.arriveDate + ':00'
- driverCarApply({...param}).then(res => {
+ let fn = param.id ? driverCarApplyEdit : driverCarApply
+ fn({...param}).then(res => {
if(res && res.code === 200){
- uni.navigateBack()
+ setTimeout(() => {
+ this.showToast('棰勭害鐢宠鎴愬姛')
+ })
+ this.$jump('/pages/driver/reservedRecord')
+ }
+ })
+ },
+ getDetail(id, type) {
+ driverApplyDetail({id}).then(res => {
+ this.param = { ...res.data, transportImgFull: res.data.prefixUrl + res.data.transportImg }
+ if(type && type == 'reject'){
+ this.$set(this.param, 'id', null)
}
})
},
diff --git a/h5/pages/driver/reservedDetail.vue b/h5/pages/driver/reservedDetail.vue
index 2303e6f..bf1c851 100644
--- a/h5/pages/driver/reservedDetail.vue
+++ b/h5/pages/driver/reservedDetail.vue
@@ -134,21 +134,32 @@
},
methods: {
handleCancel(){
+ const { info } = this
uni.showModal({
title: '鎻愮ず',
- content: '杩欐槸涓�涓ā鎬佸脊绐�',
+ content: '鎮ㄧ‘璁よ鎾ゅ洖褰撳墠鐢宠鍚楋紵',
success: function (res) {
if (res.confirm) {
- console.log('鐢ㄦ埛鐐瑰嚮纭畾');
+ driverCarRevoke({
+ id: info.id, info: ''
+ })
} else if (res.cancel) {
console.log('鐢ㄦ埛鐐瑰嚮鍙栨秷');
}
}
});
- // driverCarRevoke
},
- handleEdit(){},
- handleAga(){},
+ handleEdit(){
+ uni.navigateTo({
+ url: '/pages/driver/reserved?id=' + this.info.id
+ })
+ },
+ handleAga(){
+ const { info } = this
+ uni.navigateTo({
+ url: `/pages/driver/reserved?id=${info.id}&type=reject`
+ })
+ },
getDetail(id) {
driverApplyDetail({id}).then(res => {
this.info = res.data
@@ -200,7 +211,15 @@
.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;
@@ -222,15 +241,6 @@
bottom: 0;
}
- .separate {
- position: absolute;
- width: 4rpx;
- height: 100%;
- background-color: #eeeeee;
- left: 50%;
- transform: translate(-50%, 0);
- bottom: -80rpx;
- }
}
.content {
diff --git a/h5/pages/driver/taskDetail.vue b/h5/pages/driver/taskDetail.vue
index 9985e40..0365e8f 100644
--- a/h5/pages/driver/taskDetail.vue
+++ b/h5/pages/driver/taskDetail.vue
@@ -6,34 +6,40 @@
src="../../static/driver/bg_renwu@2x.png"
mode=""
></image>
- <view class="name">浣滀笟宸插畬鎴�</view>
- <view class="id_card">鐨朅D1212</view>
- <view class="status">浣滀笟瀹屾垚</view>
+ <view class="name" v-if="param.status == 1">璇蜂笌{{ param.arriveDate.slice(0,11) }}鐜板満绛惧埌</view>
+ <view class="name" v-if="param.status == 2">鍓嶆柟鎺掗槦锛歿{param.lineUpNum}}杈�</view>
+ <view class="name" v-if="param.status == 5">鏈堝彴浣滀笟涓�</view>
+ <view class="name" v-if="param.status == 6">浣滀笟宸插畬鎴�</view>
+ <view class="id_card">{{ param.carCodeFront }}</view>
+ <view class="status" v-if="param.status == 1">绛夊緟绛惧埌</view>
+ <view class="status" v-if="param.status == 2">绛夊緟鍙彿</view>
+ <view class="status" v-if="param.status == 5">浣滀笟涓�</view>
+ <view class="status" v-if="param.status == 6">浣滀笟瀹屾垚</view>
</view>
<!-- -->
<view class="main_content">
<view class="line">
<view class="label">鍙告満濮撳悕</view>
- <view class="value">鍒樻煇</view>
+ <view class="value">{{param.lineUpNum}}</view>
</view>
<view class="line">
<view class="label">鎵嬫満鍙�</view>
- <view class="value">188</view>
+ <view class="value">{{param.lineUpNum}}</view>
</view>
<view class="line">
<view class="label">杩愯緭鍗曞彿</view>
<view class="value" @click="showDetail = true">
- <text class="waybill_num">Y111</text>
+ <text class="waybill_num">{{param.lineUpNum}}</text>
<text class="btn">杩愬崟璇︽儏</text>
</view>
</view>
<view class="line">
<view class="label">浣滀笟绫诲瀷</view>
- <view class="value">鍏ュ洯瑁呰揣</view>
+ <view class="value">{{param.lineUpNum}}</view>
</view>
<view class="line">
<view class="label">杞︾墝鐓�</view>
- <view class="value">鍓嶏細鐨朅21</view>
+ <view class="value">{{param.lineUpNum}}</view>
</view>
<!-- -->
<view class="line">
@@ -147,6 +153,7 @@
</template>
<script>
+ import { driverTaskJobDetail } from '@/api'
export default {
data() {
return {
@@ -156,16 +163,26 @@
showDetail: false,
}
},
+ onLoad(option) {
+ this.getLocation(option.id)
+ },
methods: {
handleSignIn() {
const { param } = this
this.param.status = param.status == '0' ? '1' : '0'
},
- getLocation() {
+ getLocation(jobId) {
uni.getLocation({
type: 'wgs84',
success: function (res) {
+ driverTaskJobDetail({
+ jobId,
+ lat: res.latitude,
+ lnt: res.longitude,
+ }).then(ress => {
+ this.param = { ...ress.data }
+ })
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
index 6532036..20d2264 100644
--- a/h5/pages/staff/task/driver.vue
+++ b/h5/pages/staff/task/driver.vue
@@ -121,6 +121,7 @@
<view class="appr_modal">
<view class="title">{{ this.flag == '0' ? '鎷掔粷' : '鍚屾剰' }}</view>
<textarea
+ v-model="checkInfo"
:placeholder="this.flag == '0' ? '鎷掔粷璇存槑锛屽繀濉�' : '鍚屾剰璇存槑锛岄潪蹇呭~'"
placeholder-class="placeholder9"
/>
@@ -176,7 +177,7 @@
},
handleAppy() {
const {flag,checkInfo, type,info } = this
- if(flag == 0 && !checkInfo) return this.showToast('鎷掔粷璇存槑蹇呭~')
+ if(flag == 0 && checkInfo == '') return this.showToast('鎷掔粷璇存槑蹇呭~')
carUseBookAppr({
checkInfo,objId: info.id,objType: 6,status: flag == 0 ? 3 : 2
}).then(res => {
diff --git a/h5/pages/staffLogin/login.vue b/h5/pages/staffLogin/login.vue
index d4a0c8b..6ab5bd1 100644
--- a/h5/pages/staffLogin/login.vue
+++ b/h5/pages/staffLogin/login.vue
@@ -71,11 +71,12 @@
data() {
return {
form: {
- account: '',
- password: '',
+ username: '13996529050',
+ password: '123456',
+ code: 1
},
isShowProtocol: false,
- ProtocolFlag: false,
+ ProtocolFlag: true,
captcha: {},
htmlText: ''
}
diff --git a/h5/store/index.js b/h5/store/index.js
index 0da49e4..37588ba 100644
--- a/h5/store/index.js
+++ b/h5/store/index.js
@@ -82,7 +82,9 @@
empty(state) {
state.token = ''
state.userInfo = {}
+ state.driverInfo = {}
uni.removeStorageSync('userInfo')
+ uni.removeStorageSync('driverInfo')
uni.removeStorageSync('token')
}
},
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 7d0eb08..e8788fc 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
@@ -154,6 +154,8 @@
// 瓒呮椂棰勮閰嶇疆
public static final String TIMEOUT_WARNING = "TIMEOUT_WARNING";
// FTP鏂囦欢鏈嶅姟鍣ㄨ祫婧愯闂湴鍧�
+
+
public static String getRandom6Num( ) {
Random random = new Random();
StringBuilder sb = new StringBuilder();
@@ -741,6 +743,69 @@
/**
* 鏈堝彴浣滀笟 鐘舵��
+ * 0浠诲姟鍒涘缓 1鍙告満纭浠诲姟 2鍙告満绛惧埌 3鍏ュ洯绛夊緟 4鏈堝彴鍙彿 5寮�濮嬩綔涓� 6浣滀笟瀹屾垚 7鏈堝彴杞Щ 8浠诲姟鎸傝捣 9涓嬪彂鎺堟潈绂诲洯 10绂诲洯
+ */
+ public enum PlatformJobLogType {
+ CREATE(0, "浠诲姟鍒涘缓","浠诲姟鍒涘缓" ),
+ CONFIRM_TASK(1, "鍙告満纭浠诲姟","鍙告満纭浠诲姟" ),
+ SIGN(2, "鍙告満绛惧埌","鍙告満绛惧埌"),
+ IN_WAIT(3, "鍏ュ洯绛夊緟","鍏ュ洯绛夊緟" ),
+ CALLED(4, "鏈堝彴鍙彿","鏈堝彴鍙彿" ),
+ WORKING(5, "寮�濮嬩綔涓�","寮�濮嬩綔涓�" ),
+ DONE(6, "浣滀笟瀹屾垚 ","浣滀笟瀹屾垚 " ),
+ TRANSFERING(7, "鏈堝彴杞Щ","鏈堝彴杞Щ" ),
+ EXCEPTION(8, "浠诲姟鎸傝捣","浠诲姟鎸傝捣" ),
+ AUTHED_LEAVE(9, "涓嬪彂鎺堟潈绂诲洯","涓嬪彂鎺堟潈绂诲洯" ),
+ LEAVED(10, "宸茬鍥� ","宸茬鍥� " ),
+ ;
+
+ // 鎴愬憳鍙橀噺
+ private int key;
+ private String name;
+ private String info;
+
+ // 鏋勯�犳柟娉�
+ PlatformJobLogType(int key, String name,String info ) {
+ this.key = key;
+ this.info = info;
+ this.name = name;
+ }
+ public static String getName(int index) {
+ for (PlatformJobLogType c : PlatformJobLogType.values()) {
+ if (c.getKey() == index) {
+ return c.name;
+ }
+ }
+ return null;
+ }
+
+ public int getKey() {
+ return key;
+ }
+
+ public void setKey(int key) {
+ this.key = key;
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public String getInfo() {
+ return info;
+ }
+
+ public void setInfo(String info) {
+ this.info = info;
+ }
+ }
+
+ /**
+ * 鏈堝彴浣滀笟 鐘舵��
* 0寰呯‘璁� 1寰呯鍒� 2绛夊緟鍙彿 3鍏ュ洯绛夊緟 4宸插彨鍙� 5浣滀笟涓� 6浣滀笟瀹屾垚 7杞Щ涓� 8寮傚父鎸傝捣 9宸叉巿鏉冪鍥� 10宸茬鍥� 11 宸茶繃鍙�
*/
public enum PlatformJobStatus {
--
Gitblit v1.9.3