From 7381a33a2fc6babb0f8e43b7b6a6b63c249988c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=93=E5=B9=B3=E8=89=BA?= <52643018@qq.com> Date: Thu, 12 Aug 2021 18:11:42 +0800 Subject: [PATCH] =?UTF-8?q?[=E6=96=B0=E5=A2=9E]=20=E4=BE=9B=E5=BA=94?= =?UTF-8?q?=E5=95=86=E4=BE=9B=E8=B4=A7=E5=8F=91=E8=B4=A7=E6=97=B6=E5=88=A4?= =?UTF-8?q?=E6=96=AD=E5=BD=93=E5=89=8D=E6=97=B6=E9=97=B4=E5=92=8C=E9=A2=84?= =?UTF-8?q?=E8=AE=A1=E6=94=B6=E8=B4=A7=E6=97=B6=E9=97=B4=EF=BC=8C=E4=B8=8D?= =?UTF-8?q?=E5=90=8C=E6=97=B6=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- supplier/pages/gonghuo/detail.vue | 32 ++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/supplier/pages/gonghuo/detail.vue b/supplier/pages/gonghuo/detail.vue index bd801ec..a07865d 100644 --- a/supplier/pages/gonghuo/detail.vue +++ b/supplier/pages/gonghuo/detail.vue @@ -116,8 +116,11 @@ - 发货提醒 - 请填写车辆信息、司机信息 + 送货信息 + + + + 车牌号 @@ -132,8 +135,8 @@ - 取消 - 确定 + {{ is_atypism ? '取消发货' : '取消' }} + {{ is_atypism ? '继续发货' : '确定' }} @@ -198,7 +201,9 @@ driver_phone: '', canteen_voucher: [], // 食堂端凭证 supplier_voucher: [], // 供应端凭证 - button_click: false + button_click: false, + receiving_desc: '请填写车辆信息、司机信息', + is_atypism: false } }, onLoad(options){ @@ -267,6 +272,18 @@ return obj; }); this.contents = contents; + + // 校验当前收货时间是否在预计收货时间内 + if(order.state == '备货中' && order.deadline_text){ + // 获取预计收货时间23:59分时间 + let estimateTime = new Date(new Date(order.deadline_text).toLocaleDateString()).getTime() + 24 * 60 * 60 * 1000 - 1; + let actualTime = new Date(new Date().toLocaleDateString()).getTime() + 24 * 60 * 60 * 1000 - 1; // 获取今天23:59时间 + let day_text = this.$shared.recordTime(new Date(), '-', 'date'); + if(estimateTime != actualTime){ + this.receiving_desc = `食堂方的预计收货为 ${order.deadline_text},今天是 ${day_text},请与食堂方确认好收货日期,以免造成不必要的损失!`; + this.is_atypism = true; + } + } }); }, // 上传凭证图片 @@ -510,7 +527,8 @@ color: #555555; text-align: center; margin-top: 20rpx; - margin-bottom: 18rpx; + margin-bottom: 40rpx; + padding: 0 30rpx; } .popup-images{ display: flex; @@ -547,7 +565,7 @@ } } .popup-input{ - padding: 0 60rpx; + padding: 0 30rpx; box-sizing: border-box; height: 90rpx; font-size: 28rpx;