| | |
| | | <!-- --> |
| | | <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>皖AD</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>皖AD</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> |
| | |
| | | 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) { |
| | |
| | | bookingTips: res.data.bookingTips, |
| | | reservationMap: res.data.reservationMap |
| | | }); |
| | | this.taskList = res.data.platformJobList || [] |
| | | } |
| | | }); |
| | | }, |