| | |
| | | <image v-else src="@/static/waybill/ic_dingdan@2x.png" mode=""></image>
|
| | | </view>
|
| | | <view class="content">
|
| | | <view class="name">{{item.receiveLocation}}</view>
|
| | | <view class="name" :class="{primaryColor: (info.logisticsStatus == 1 && item.actualArrivedDate) || info.logisticsStatus == 2}">{{item.receiveLocation}}</view>
|
| | | <view class="status">
|
| | | <view v-if="info.logisticsStatus == 0" class="btn">到货</view>
|
| | | <view v-else-if="info.logisticsStatus == 1 && !item.actualArrivedDate" @click="startAri(item.stopNumber)"
|
| | |
| | | </view>
|
| | | <view class="top1">
|
| | | <view class="left_icon"></view>
|
| | | <view class="time">到货时间:{{ item.actualArrivedDate || '-' }}</view>
|
| | | <view class="time" v-if="item.actualArrivedDate">到货时间:{{ item.actualArrivedDate}}</view> |
| | | <view class="time" style="margin-top: -10rpx;" v-else>-</view>
|
| | | </view>
|
| | | </view>
|
| | | </view>
|
| | | </view>
|
| | | <view v-if="info.logisticsStatus == 0" @click="startTrans" class="start_btn">启运</view>
|
| | | <!-- --> |
| | | <view v-if="showTip" class="tip_wrap"> |
| | | <view class="title">提示</view> |
| | | <view class="text">车辆刚启运,暂无法进行到</view> |
| | | <view class="text">货操作,请5分钟后再试</view> |
| | | <view class="btn" @click="showTip = false">我知道了</view> |
| | | </view> |
| | | <view v-if="showTip" class="shade"></view> |
| | | </view>
|
| | | </template>
|
| | |
|
| | |
| | | putTaskDetail,
|
| | | putDriverArrival,
|
| | | putDriverStart,
|
| | |
|
| | | } from '@/api'
|
| | | export default {
|
| | | data() {
|
| | |
| | | info: {
|
| | | productDetails: [],
|
| | | transportStop: []
|
| | | }
|
| | | }, |
| | | showTip: false
|
| | | };
|
| | | },
|
| | | onLoad(options) {
|
| | |
| | | id: this.id,
|
| | | optType: 0
|
| | | }).then((ress) => {
|
| | | if (ress.code == 200) {
|
| | | this.showToast('启运成功')
|
| | | if (ress.code == 200) { |
| | | const transportList = uni.getStorageSync('transportList') || [] |
| | | transportList.push({ id: this.id, time: new Date().getTime() }) |
| | | uni.setStorageSync('transportList', transportList)
|
| | | this.showToast('启运成功') |
| | | this.getDetail()
|
| | | }
|
| | | })
|
| | | }
|
| | |
| | | title: '提示',
|
| | | content: '确认到货么?',
|
| | | success: (res) => {
|
| | | if (res.confirm) {
|
| | | if (res.confirm) { |
| | | const transportList = uni.getStorageSync('transportList') || [] |
| | | const item = transportList.find(i => i.id == this.id) |
| | | if(item && item.id){ |
| | | const timeN = new Date().getTime() - item.time |
| | | if(timeN < 5 * 60 * 1000){ |
| | | this.showTip = true |
| | | return |
| | | } |
| | | }
|
| | | putDriverArrival({
|
| | | stopNumber,
|
| | | optType: 1,
|
| | | id: this.id
|
| | | }).then(ress => {
|
| | | if (ress.code == 200) {
|
| | | this.showToast('到货成功')
|
| | | this.showToast('到货成功') |
| | | this.getDetail()
|
| | | }
|
| | | })
|
| | | }
|
| | |
| | | <style lang="scss">
|
| | | page {
|
| | | background-color: #f7f7f7;
|
| | | } |
| | | .shade{ |
| | | width: 100vw; |
| | | height: 100vh; |
| | | background: #000000; |
| | | opacity: 0.4; |
| | | position: fixed; |
| | | left: 0; |
| | | top: 0; |
| | | z-index: 99; |
| | | }
|
| | |
|
| | | .tip_wrap{ |
| | | position: fixed; |
| | | top: 0; |
| | | left: 0; |
| | | bottom: 0; |
| | | right: 0; |
| | | margin: auto; |
| | | width: 560rpx; |
| | | height: 328rpx; |
| | | background: #FFFFFF; |
| | | border-radius: 24rpx; |
| | | text-align: center; |
| | | z-index: 999; |
| | | .title{ |
| | | font-weight: 500; |
| | | font-size: 32rpx; |
| | | color: #111111; |
| | | margin: 40rpx 0 30rpx; |
| | | } |
| | | .text{ |
| | | font-weight: 400; |
| | | font-size: 28rpx; |
| | | color: #333333; |
| | | } |
| | | .btn{ |
| | | margin-top: 32rpx; |
| | | height: 100rpx; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | border-top: 1rpx solid #E5E5E5; |
| | | color: #279BAA; |
| | | font-size: 32rpx; |
| | | } |
| | | }
|
| | | .head_bg {
|
| | | width: 750rpx;
|
| | | height: 240rpx;
|
| | |
| | | position: absolute;
|
| | | top: 0;
|
| | | left: 0;
|
| | | z-index: -1;
|
| | | }
|
| | |
|
| | | .info {
|
| | |
| | | overflow: hidden;
|
| | | margin-top: 30rpx;
|
| | | background: #FFFFFF;
|
| | |
|
| | | position: relative; |
| | | z-index: 1;
|
| | | .head {
|
| | | display: flex;
|
| | | justify-content: space-between;
|
| | |
| | | color: #222222;
|
| | |
|
| | | .line {
|
| | | height: 68rpx;
|
| | | min-height: 68rpx;
|
| | | align-items: center;
|
| | | display: flex;
|
| | | border-bottom: 1px solid #E5E5E5;
|
| | |
| | | border-radius: 16rpx;
|
| | | padding: 30rpx;
|
| | | margin-top: 20rpx;
|
| | |
|
| | | margin-bottom: 20rpx;
|
| | | .title {
|
| | | font-weight: 500;
|
| | | font-size: 32rpx;
|
| | |
| | | .list {
|
| | | .item {
|
| | | position: relative;
|
| | |
|
| | | padding-bottom: 24rpx; |
| | | &:nth-last-child(1){ |
| | | padding-bottom: 0; |
| | | }
|
| | | .dian {
|
| | | border: 1rpx dashed #CCCCCC;
|
| | | height: calc(100% - 48rpx);
|
| | |
| | |
|
| | | .top1 {
|
| | | display: flex;
|
| | |
|
| | | .left_icon {
|
| | | width: 78rpx;
|
| | |
|
| | |
| | | flex: 1;
|
| | | display: flex;
|
| | | justify-content: space-between;
|
| | | align-items: center;
|
| | | // align-items: center;
|
| | | margin-bottom: 12rpx;
|
| | |
|
| | | .name {
|
| | |
| | |
|
| | | .status {
|
| | | display: flex;
|
| | | align-items: center;
|
| | | // align-items: center;
|
| | | font-size: 26rpx;
|
| | |
|
| | | .btn {
|
| | |
| | |
|
| | | .pri {
|
| | | color: #fff;
|
| | | background-color: $uni-color-primary;
|
| | | background-color: $uni-color-primary; |
| | | border: 1rpx solid $uni-color-primary;
|
| | | }
|
| | |
|
| | | image {
|