From 5da830cb0b2fc7fbaba9e7836098bc21a3281b51 Mon Sep 17 00:00:00 2001 From: qb <1191961160@qq.com> Date: Tue, 7 May 2024 15:09:42 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=83=A8=E5=88=86=E5=B9=B2?= =?UTF-8?q?=E7=BA=BFbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/option/waybill/ChangeOrder.js | 118 +++++++----- .../waybill/WarehousingByTrainNumber.js | 175 +++++++----------- src/utils/util.js | 34 ++++ .../distribution/inventory/CreateOrder.vue | 57 +++--- .../addArteryDistrilbutionBillLadingList.vue | 4 +- src/views/waybill/ChangeOrder.vue | 33 +++- src/views/waybill/CreateZeroOrder.vue | 29 +-- 7 files changed, 234 insertions(+), 216 deletions(-) diff --git a/src/option/waybill/ChangeOrder.js b/src/option/waybill/ChangeOrder.js index 5468eafa..500c147c 100644 --- a/src/option/waybill/ChangeOrder.js +++ b/src/option/waybill/ChangeOrder.js @@ -15,9 +15,9 @@ export const columnList = [ fixed: true, }, { - prop: 'billladingCode', + prop: 'waybillNo', label: '运单号', - type: 6, + type: 13, values: '', width: '150', checkarr: [], @@ -26,7 +26,7 @@ export const columnList = [ head: false, }, { - prop: 'carNumber', + prop: 'openWarehouseName', label: '开单网点', type: 1, values: '', @@ -36,27 +36,49 @@ export const columnList = [ sortable: true, }, { - prop: 'driverName', + prop: 'checkStatusName', label: '状态', - type: 1, + type: 3, values: '', width: '130', - checkarr: [], + checkarr: [ + { + label: '待审核', + value: '0', + }, + { + label: '已通过', + value: '1', + }, + { + label: '未通过', + value: '2', + }, + ], fixed: false, sortable: true, }, { - prop: 'driverPhone', + prop: 'waybillTypeName', label: '开单类型', - type: 1, + type: 3, values: '', width: '130', - checkarr: [], + checkarr: [ + { + label: '有数据', + value: '1', + }, + { + label: '无数据', + value: '2', + }, + ], fixed: false, sortable: true, }, { - prop: 'warehouseName', + prop: 'agent', label: '制单员', type: 1, values: '', @@ -66,7 +88,7 @@ export const columnList = [ sortable: true, }, { - prop: 'lineNameTitle', + prop: 'openTime', label: '开单时间', type: 1, values: '', @@ -76,7 +98,7 @@ export const columnList = [ sortable: true, }, { - prop: 'nodeNub', + prop: 'applyTime', label: '申请时间', type: 1, values: '', @@ -86,7 +108,7 @@ export const columnList = [ sortable: true, }, { - prop: 'startTime', + prop: 'applyWarehouseName', label: '申请网点', type: 1, values: '', @@ -96,7 +118,7 @@ export const columnList = [ sortable: true, }, { - prop: 'endTime', + prop: 'createUserName', label: '申请人', type: 1, values: '', @@ -106,7 +128,7 @@ export const columnList = [ sortable: true, }, { - prop: 'planVolume', + prop: 'refer', label: '修改原因', type: 1, values: '', @@ -116,7 +138,7 @@ export const columnList = [ sortable: true, }, { - prop: 'billladingStatus', + prop: 'operationRemark', label: '修改内容', type: 1, values: '', @@ -125,18 +147,18 @@ export const columnList = [ fixed: false, sortable: true, }, + // { + // prop: 'chargeType', + // label: '审核网点', + // type: 1, + // values: '', + // width: '130', + // checkarr: [], + // fixed: false, + // sortable: true, + // }, { - prop: 'chargeType', - label: '审核网点', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'totalFee', + prop: 'checkTime', label: '审核时间', type: 1, values: '', @@ -145,28 +167,28 @@ export const columnList = [ fixed: false, sortable: true, }, + // { + // prop: 'remark', + // label: '审核人', + // type: 1, + // values: '', + // width: '130', + // checkarr: [], + // fixed: false, + // sortable: true, + // }, + // { + // prop: 'carrierName', + // label: '审核意见', + // type: 1, + // values: '', + // width: '130', + // checkarr: [], + // fixed: false, + // sortable: true, + // }, { - prop: 'remark', - label: '审核人', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'carrierName', - label: '审核意见', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'createUserName', + prop: '', label: '操作', type: 6, values: '', diff --git a/src/option/waybill/WarehousingByTrainNumber.js b/src/option/waybill/WarehousingByTrainNumber.js index 9b0fd507..835d06d6 100644 --- a/src/option/waybill/WarehousingByTrainNumber.js +++ b/src/option/waybill/WarehousingByTrainNumber.js @@ -18,7 +18,7 @@ export const columnList = [ { prop: 'orderCode', label: '订单自编号', - type: 1, + type: 2, values: '', width: '150', checkarr: [], @@ -27,9 +27,9 @@ export const columnList = [ head: false, }, { - prop: 'carNumber', + prop: 'serviceNum', label: '服务号', - type: 1, + type: 2, values: '', width: '150', checkarr: [], @@ -37,19 +37,22 @@ export const columnList = [ sortable: true, }, { - prop: 'driverName', + prop: 'isGcpName', label: '是否干仓配', - type: 1, + type: 3, values: '', width: '130', - checkarr: [], + checkarr: [ + { label: '是', value: '1' }, + { label: '否', value: '0' }, + ], fixed: false, sortable: true, }, { - prop: 'driverPhone', + prop: 'totalNum', label: '数量', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -59,7 +62,7 @@ export const columnList = [ { prop: 'warehouseName', label: '导入仓库', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -67,9 +70,9 @@ export const columnList = [ sortable: true, }, { - prop: 'lineNameTitle', + prop: 'orderType', label: '订单类型', - type: 1, + type: 2, values: '', width: '180', checkarr: [], @@ -77,19 +80,9 @@ export const columnList = [ sortable: true, }, { - prop: 'startTime', + prop: 'siteName', label: '订单来源', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'nodeNub', - label: '订单类型名称', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -97,19 +90,22 @@ export const columnList = [ sortable: true, }, { - prop: 'endTime', - label: '遗留', - type: 1, + prop: 'legacyStatus', + label: '是否遗留', + type: 3, values: '', width: '130', - checkarr: [], + checkarr: [ + { label: '是', value: '1' }, + { label: '否', value: '0' }, + ], fixed: false, sortable: true, }, { - prop: 'planVolume', + prop: 'dealerName', label: '商场名称', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -117,9 +113,9 @@ export const columnList = [ sortable: true, }, { - prop: 'planVolume', + prop: 'customerName', label: '顾客名称', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -127,9 +123,9 @@ export const columnList = [ sortable: true, }, { - prop: 'billladingStatus', + prop: 'customerPhone', label: '顾客电话', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -137,9 +133,9 @@ export const columnList = [ sortable: true, }, { - prop: 'chargeType', + prop: 'customerAddress', label: '顾客地址', - type: 1, + type: 2, values: '', width: '180', checkarr: [], @@ -147,29 +143,9 @@ export const columnList = [ sortable: true, }, { - prop: 'planVolume', + prop: 'storeName', label: '门店名称', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'totalFee', - label: '交期', - type: 1, - values: '', - width: '150', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'planVolume', - label: 'MSCS订单号', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -177,39 +153,22 @@ export const columnList = [ sortable: true, }, { - prop: 'planVolume', - label: '订单类型名称', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'planVolume', - label: '齐套方式', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'planVolume', - label: 'MTDS单号', - type: 1, + prop: 'matingType', + label: '是否齐套', + type: 3, values: '', width: '130', - checkarr: [], + checkarr: [ + { label: '是', value: '1' }, + { label: '否', value: '0' }, + ], fixed: false, sortable: true, }, { - prop: 'remark', + prop: 'dealerCode', label: '商场编码', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -217,9 +176,9 @@ export const columnList = [ sortable: true, }, { - prop: 'planVolume', + prop: 'carrierName', label: '承运商', - type: 1, + type: 2, values: '', width: '130', checkarr: [], @@ -227,37 +186,37 @@ export const columnList = [ sortable: true, }, { - prop: 'carrierName', + prop: 'storeCode', label: '门店编码', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'planVolume', - label: '序列号', - type: 1, - values: '', - width: '130', - checkarr: [], - fixed: false, - sortable: true, - }, - { - prop: 'planVolume', - label: '合同号', - type: 1, + type: 2, values: '', width: '130', checkarr: [], fixed: false, sortable: true, }, + // { + // prop: 'planVolume', + // label: '序列号', + // type: 1, + // values: '', + // width: '130', + // checkarr: [], + // fixed: false, + // sortable: true, + // }, + // { + // prop: 'planVolume', + // label: '合同号', + // type: 1, + // values: '', + // width: '130', + // checkarr: [], + // fixed: false, + // sortable: true, + // }, { - prop: 'totalVolume', + prop: 'createTime', label: '创建时间', type: 1, values: '', diff --git a/src/utils/util.js b/src/utils/util.js index 334b1865..07b4a9f3 100644 --- a/src/utils/util.js +++ b/src/utils/util.js @@ -715,3 +715,37 @@ export function hanleTextLineFeed(className, num) { value.innerHTML = addText; } } + +/** + * 转译数据中下拉框的值 + * @param {Array} data + * @param {Array} columnList + * @param {Function} fn 执行的函数 + */ +export function handleTranslationDataSeclect(data, columnList, fn = (value, item) => {}) { + if (getObjType(columnList) !== 'array') + return console.log('columnList 参数类型错误 >>>', columnList); + if (getObjType(data) !== 'array') return console.log('data 参数类型错误 >>>', data); + + const filterArr = columnList.filter(val => val.type === 3); + + for (let i = 0; i < data.length; i++) { + const value = data[i]; + + for (let index = 0; index < filterArr.length; index++) { + const item = filterArr[index]; + + const _key = item.prop.replace('Name', ''); + + for (let j = 0; j < item.checkarr.length; j++) { + const val = item.checkarr[j]; + + if (value[_key] + '' !== val.value + '') continue; + value[item.prop] = val.label; + + fn(value, item); + break; + } + } + } +} diff --git a/src/views/distribution/inventory/CreateOrder.vue b/src/views/distribution/inventory/CreateOrder.vue index 5fa6a308..5a49156a 100644 --- a/src/views/distribution/inventory/CreateOrder.vue +++ b/src/views/distribution/inventory/CreateOrder.vue @@ -29,7 +29,12 @@