diff --git a/src/router/views/index.js b/src/router/views/index.js index 1051ba49..277c17cb 100644 --- a/src/router/views/index.js +++ b/src/router/views/index.js @@ -1541,7 +1541,7 @@ export default [ { meta: { i18n: 'dict', - keepAlive: false, + keepAlive: true, }, path: '/financialsector/FinanceHome', name: '财务', diff --git a/src/views/basicdata/brand/basicClient.vue b/src/views/basicdata/brand/basicClient.vue index f04b44be..0e5edaa1 100644 --- a/src/views/basicdata/brand/basicClient.vue +++ b/src/views/basicdata/brand/basicClient.vue @@ -985,7 +985,7 @@ export default { if (!this.CustomerEntd) { setTimeout(async () => { const response = { valid: false }; // 假设校验通过 - await $_getListlistName({ code: a }).then(res => { + await $_getListlistName({ name: a }).then(res => { console.log("客户名称校验",res.data); if (res.data.data.length > 0) { reject(new Error('客户名称已存在')); // 校验不通过,调用 reject() 并传递错误信息 diff --git a/src/views/distribution/deliverylist/distributionDeliveryListedt.vue b/src/views/distribution/deliverylist/distributionDeliveryListedt.vue index 8454a660..8927af23 100644 --- a/src/views/distribution/deliverylist/distributionDeliveryListedt.vue +++ b/src/views/distribution/deliverylist/distributionDeliveryListedt.vue @@ -4700,13 +4700,14 @@ export default { }, // 复核签收确认弹窗 submitForm() { - if (!this.DoorstepPhoto.length) { - ElMessage({ - message: '至少上传一张上门照片', - type: 'warning', - }); - return; - } + // 取消上门照片规则 + // if (!this.DoorstepPhoto.length) { + // ElMessage({ + // message: '至少上传一张上门照片', + // type: 'warning', + // }); + // return; + // } if (!this.StackingPhoto.length) { ElMessage({ message: '至少上传一张堆码照片', diff --git a/src/views/distribution/turndelivery/deliveryDiscuss.vue b/src/views/distribution/turndelivery/deliveryDiscuss.vue index 127e11eb..478fcaec 100644 --- a/src/views/distribution/turndelivery/deliveryDiscuss.vue +++ b/src/views/distribution/turndelivery/deliveryDiscuss.vue @@ -1719,6 +1719,9 @@ onMounted(() => { getDeliveryList(route.query.id).then(res => { //司机配置 if (res.data.data.kind == 2) { + if(!res.data.data.deliveryTripartiteVO){ + return + } DataSubmit.value.tripartite.distributionCompany = res.data.data.distributionCompany; //外协来源 DataSubmit.value.tripartite.driverName = res.data.data.deliveryTripartiteVO.driverName; //司机名称 DataSubmit.value.tripartite.vehicleNum = res.data.data.deliveryTripartiteVO.vehicleNum; //司机车牌 @@ -1732,7 +1735,11 @@ onMounted(() => { numTab.value[0].name = '0'; //切换外协选项卡 numTab.value[1].name = '1'; kind.value = true; - res.data.data.deliverySelfVO.forEach(item => { + if(res.data.data.deliverySelfVO){ + if(!res.data.data.deliverySelfVO.length){ + return + } + res.data.data.deliverySelfVO.forEach(item => { console.log(item, '司机配置信息'); DriverTemporaryStorage.value.push({ driverId: item.driverId, //司机ID @@ -1755,24 +1762,35 @@ onMounted(() => { DataSubmit.value.masterVehicleNub = item.vehicleNub; //司机车牌号 } }); + } + } - wrapDataInfo.value = res.data.data.stockArticleList; // 订单包件 - dataInfo.value = res.data.data.stockArticleList; //订单列表 + console.log(res.data.data,'123'); + + wrapDataInfo.value = res.data.data.stockArticleList||''; // 订单包件 + dataInfo.value = res.data.data.stockArticleList||''; //订单列表 // dataInfoTemp.value=dataInfo.value;//把获取到的值传递给公共组件 - DataSubmit.value.stockup.loaderId = res.data.data.loadingTeamId; //装车班组ID - DataSubmit.value.stockup.loaderName = res.data.data.loadingTeamName; //装车班组名称 - DataSubmit.value.stockup.unloaderId = res.data.data.unloadingTeamId; //卸车班组ID - DataSubmit.value.stockup.unloaderName = res.data.data.unloadingTeamName; //卸车班组名称 + DataSubmit.value.stockup.loaderId = res.data.data.loadingTeamId||''; //装车班组ID + DataSubmit.value.stockup.loaderName = res.data.data.loadingTeamName||''; //装车班组名称 + DataSubmit.value.stockup.unloaderId = res.data.data.unloadingTeamId||''; //卸车班组ID + DataSubmit.value.stockup.unloaderName = res.data.data.unloadingTeamName||''; //卸车班组名称 DataSubmit.value.remarks = res.data.data.remarks; //备注信息 - DataSubmit.value.stockup.forkliftName = res.data.data.stockupInfo.forkliftName; //备货人员名称 - DataSubmit.value.stockup.forkliftId = res.data.data.stockupInfo.forkliftId; //备货人员ID - DataSubmit.value.stockup.goodsAreaId = res.data.data.stockupInfo.goodsAreaId; //备货区域ID - DataSubmit.value.stockup.goodsAreaName = res.data.data.stockupInfo.stockupArea; //备货区域名称 - DataSubmit.value.stockup.outboundDate = res.data.data.stockupInfo.outboundDate; //出库时间 - DataSubmit.value.stockup.stockupDate = res.data.data.stockupInfo.stockupDate; //备货时间 + if(!res.data.data.stockupInfo){ + return + } + DataSubmit.value.stockup.forkliftName = res.data.data.stockupInfo.forkliftName||''; //备货人员名称 + DataSubmit.value.stockup.forkliftId = res.data.data.stockupInfo.forkliftId||''; //备货人员ID + DataSubmit.value.stockup.goodsAreaId = res.data.data.stockupInfo.goodsAreaId||''; //备货区域ID + DataSubmit.value.stockup.goodsAreaName = res.data.data.stockupInfo.stockupArea||''; //备货区域名称 + DataSubmit.value.stockup.outboundDate = res.data.data.stockupInfo.outboundDate||''; //出库时间 + DataSubmit.value.stockup.stockupDate = res.data.data.stockupInfo.stockupDate||''; //备货时间 DataSubmit.value.taskTime = res.data.data.taskTime; //配送日期 editLoading.value = false; //所有信息获取完成关闭弹窗 tooSUM(); + }).catch(()=>{ + + }).finally(()=>{ + editLoading.value = false; //开启加载 }); } }); @@ -2964,22 +2982,19 @@ const SubmitCommercial = async () => { const res = await updateDeliveryList(DataSubmitRenamed); console.log(res, '修改之后提交的返回值'); code = res.data.code; + ElMessage({ + message: res.data.msg, + type: 'success', + }) + handleBack(); } else { // 新增信息 console.log(DataSubmit.value, '准备提交的信息'); const res = await deliveryBusinessTask(DataSubmit.value); code = res.data.code; - console.log(res, '新增之后的返回值'); - } - } catch (error) { - console.log('error :>> ', error); - } finally { - editLoading.value = false; //关闭提交加载 - - if (code !== 200) return; - state.value = false; //重置满足条件 - ElMessageBox.confirm( + if (code !== 200) return; + ElMessageBox.confirm( '计划添加成功,是否继续添加?', '提示', { @@ -3002,6 +3017,17 @@ sjInput.value='' handleBack(); }) + console.log(res, '新增之后的返回值'); + } + } catch (error) { + console.log('error :>> ', error); + } finally { + editLoading.value = false; //关闭提交加载 + + if (code !== 200) return; + state.value = false; //重置满足条件 + + } console.log(DataSubmit.value, '准备提交的信息'); diff --git a/src/views/financialsector/FinanceHome.vue b/src/views/financialsector/FinanceHome.vue index 462bfd16..70a8c212 100644 --- a/src/views/financialsector/FinanceHome.vue +++ b/src/views/financialsector/FinanceHome.vue @@ -1,5 +1,5 @@