From 66b1a213209f816cc474fb2ffef67eda61f7333c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=A3=E5=9C=A3=E5=8D=8E?= <752718920@qq.com> Date: Tue, 5 Dec 2023 00:28:04 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=99=E5=85=B6=E5=AE=83=E5=85=A5=E5=BA=93?= =?UTF-8?q?=E5=92=8C=E5=85=B6=E5=AE=83=E5=87=BA=E5=BA=93=E5=8D=95=E6=8D=AE?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=85=B3=E8=81=94=E5=8D=95=E6=8D=AE=E7=9A=84?= =?UTF-8?q?=E5=8A=9F=E8=83=BD=EF=BC=8C=E6=94=AF=E6=8C=81=E5=85=A8=E9=83=A8?= =?UTF-8?q?=E5=92=8C=E9=83=A8=E5=88=86=E5=85=B3=E8=81=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jshERP-web/src/views/bill/OtherInList.vue | 7 ++- jshERP-web/src/views/bill/OtherOutList.vue | 7 ++- .../src/views/bill/PurchaseBackList.vue | 6 ++- jshERP-web/src/views/bill/PurchaseInList.vue | 6 ++- jshERP-web/src/views/bill/SaleBackList.vue | 6 ++- jshERP-web/src/views/bill/SaleOutList.vue | 6 ++- .../src/views/bill/dialog/BillDetail.vue | 18 +++++-- .../src/views/bill/dialog/WaitBillList.vue | 4 +- .../src/views/bill/modules/OtherInModal.vue | 51 ++++++++----------- .../src/views/bill/modules/OtherOutModal.vue | 51 ++++++++----------- .../views/bill/modules/PurchaseInModal.vue | 2 +- .../views/bill/modules/PurchaseOrderModal.vue | 2 +- .../src/views/bill/modules/SaleOutModal.vue | 2 +- 13 files changed, 93 insertions(+), 75 deletions(-) diff --git a/jshERP-web/src/views/bill/OtherInList.vue b/jshERP-web/src/views/bill/OtherInList.vue index 03c15441..f3be38ec 100644 --- a/jshERP-web/src/views/bill/OtherInList.vue +++ b/jshERP-web/src/views/bill/OtherInList.vue @@ -219,7 +219,12 @@ scopedSlots: { customRender: 'action' }, }, { title: '供应商', dataIndex: 'organName',width:120, ellipsis:true}, - { title: '单据编号', dataIndex: 'number',width:160}, + { title: '单据编号', dataIndex: 'number',width:160, + customRender:function (text,record,index) { + text = record.linkNumber?text+"[转]":text + return text + } + }, { title: '关联单据', dataIndex: 'linkNumber',width:140}, { title: '商品信息', dataIndex: 'materialsList',width:220, ellipsis:true}, { title: '单据日期', dataIndex: 'operTimeStr',width:145}, diff --git a/jshERP-web/src/views/bill/OtherOutList.vue b/jshERP-web/src/views/bill/OtherOutList.vue index fdbca16c..cf5b6708 100644 --- a/jshERP-web/src/views/bill/OtherOutList.vue +++ b/jshERP-web/src/views/bill/OtherOutList.vue @@ -219,7 +219,12 @@ scopedSlots: { customRender: 'action' }, }, { title: '客户', dataIndex: 'organName',width:120, ellipsis:true}, - { title: '单据编号', dataIndex: 'number',width:160}, + { title: '单据编号', dataIndex: 'number',width:160, + customRender:function (text,record,index) { + text = record.linkNumber?text+"[转]":text + return text + } + }, { title: '关联单据', dataIndex: 'linkNumber',width:140}, { title: '商品信息', dataIndex: 'materialsList',width:220, ellipsis:true}, { title: '单据日期', dataIndex: 'operTimeStr',width:145}, diff --git a/jshERP-web/src/views/bill/PurchaseBackList.vue b/jshERP-web/src/views/bill/PurchaseBackList.vue index 46dcde3e..138482ea 100644 --- a/jshERP-web/src/views/bill/PurchaseBackList.vue +++ b/jshERP-web/src/views/bill/PurchaseBackList.vue @@ -52,7 +52,7 @@ - + {{ depot.depotName }} @@ -86,6 +86,8 @@ 未审核 已审核 + 部分出库 + 完成出库 @@ -161,6 +163,8 @@ diff --git a/jshERP-web/src/views/bill/PurchaseInList.vue b/jshERP-web/src/views/bill/PurchaseInList.vue index 89f3c5c9..eddcce16 100644 --- a/jshERP-web/src/views/bill/PurchaseInList.vue +++ b/jshERP-web/src/views/bill/PurchaseInList.vue @@ -52,7 +52,7 @@ - + {{ depot.depotName }} @@ -94,6 +94,8 @@ 未审核 已审核 + 部分入库 + 完成入库 @@ -180,6 +182,8 @@ diff --git a/jshERP-web/src/views/bill/SaleBackList.vue b/jshERP-web/src/views/bill/SaleBackList.vue index b91197a8..1ec72848 100644 --- a/jshERP-web/src/views/bill/SaleBackList.vue +++ b/jshERP-web/src/views/bill/SaleBackList.vue @@ -53,7 +53,7 @@ - + {{ depot.depotName }} @@ -87,6 +87,8 @@ 未审核 已审核 + 部分入库 + 完成入库 @@ -162,6 +164,8 @@ diff --git a/jshERP-web/src/views/bill/SaleOutList.vue b/jshERP-web/src/views/bill/SaleOutList.vue index 2f860e7f..ed79c7e4 100644 --- a/jshERP-web/src/views/bill/SaleOutList.vue +++ b/jshERP-web/src/views/bill/SaleOutList.vue @@ -53,7 +53,7 @@ - + {{ depot.depotName }} @@ -95,6 +95,8 @@ 未审核 已审核 + 部分出库 + 完成出库 @@ -181,6 +183,8 @@ diff --git a/jshERP-web/src/views/bill/dialog/BillDetail.vue b/jshERP-web/src/views/bill/dialog/BillDetail.vue index fafea390..e042d05f 100644 --- a/jshERP-web/src/views/bill/dialog/BillDetail.vue +++ b/jshERP-web/src/views/bill/dialog/BillDetail.vue @@ -1248,6 +1248,7 @@ { title: '有效期', dataIndex: 'expirationDate'}, { title: '多属性', dataIndex: 'sku'}, { title: '数量', dataIndex: 'operNumber'}, + { title: '已入库', dataIndex: 'finishNumber'}, { title: '单价', dataIndex: 'unitPrice'}, { title: '金额', dataIndex: 'allPrice'}, { title: '税率(%)', dataIndex: 'taxRate'}, @@ -1271,6 +1272,7 @@ { title: '有效期', dataIndex: 'expirationDate'}, { title: '多属性', dataIndex: 'sku'}, { title: '数量', dataIndex: 'operNumber'}, + { title: '已出库', dataIndex: 'finishNumber'}, { title: '单价', dataIndex: 'unitPrice'}, { title: '金额', dataIndex: 'allPrice'}, { title: '税率(%)', dataIndex: 'taxRate'}, @@ -1313,6 +1315,7 @@ { title: '有效期', dataIndex: 'expirationDate'}, { title: '多属性', dataIndex: 'sku'}, { title: '数量', dataIndex: 'operNumber'}, + { title: '已出库', dataIndex: 'finishNumber'}, { title: '单价', dataIndex: 'unitPrice'}, { title: '金额', dataIndex: 'allPrice'}, { title: '税率(%)', dataIndex: 'taxRate'}, @@ -1336,6 +1339,7 @@ { title: '有效期', dataIndex: 'expirationDate'}, { title: '多属性', dataIndex: 'sku'}, { title: '数量', dataIndex: 'operNumber'}, + { title: '已入库', dataIndex: 'finishNumber'}, { title: '单价', dataIndex: 'unitPrice'}, { title: '金额', dataIndex: 'allPrice'}, { title: '税率(%)', dataIndex: 'taxRate'}, @@ -1616,10 +1620,16 @@ this.form.setFieldsValue(pick(this.model, 'id')) }); let showType = 'basic' - if (item.status === '3') { - showType = 'basic' - } else if (item.purchaseStatus === '3') { - showType = 'purchase' + if(item.subType === '采购' || item.subType === '采购退货' || item.subType === '销售' || item.subType === '销售退货') { + if (item.status === '3') { + showType = 'other' + } + } else { + if (item.status === '3') { + showType = 'basic' + } else if (item.purchaseStatus === '3') { + showType = 'purchase' + } } let isReadOnly = '1' if(item.subType === '组装单' || item.subType === '拆卸单') { diff --git a/jshERP-web/src/views/bill/dialog/WaitBillList.vue b/jshERP-web/src/views/bill/dialog/WaitBillList.vue index 15e9987e..fb2327cc 100644 --- a/jshERP-web/src/views/bill/dialog/WaitBillList.vue +++ b/jshERP-web/src/views/bill/dialog/WaitBillList.vue @@ -182,7 +182,7 @@ methods: { show(type, subType, status) { this.selectType = 'list' - this.showType = 'basic' + this.showType = 'other' this.queryParam.type = type this.queryParam.subType = subType this.queryParam.status = status @@ -229,7 +229,7 @@ } else { if(this.selectedDetailRowKeys.length) { this.getSelectBillDetailRows() - this.$emit('ok', this.selectBillDetailRows, this.linkNumber, this.organId, this.discountMoney, this.deposit, this.remark) + this.$emit('ok', this.selectBillDetailRows, this.linkNumber, this.remark) this.close() } else { this.$message.warning('抱歉,请选择单据明细!') diff --git a/jshERP-web/src/views/bill/modules/OtherInModal.vue b/jshERP-web/src/views/bill/modules/OtherInModal.vue index 24f3dffb..3577d195 100644 --- a/jshERP-web/src/views/bill/modules/OtherInModal.vue +++ b/jshERP-web/src/views/bill/modules/OtherInModal.vue @@ -21,7 +21,7 @@ -
@@ -46,7 +46,7 @@ - + @@ -59,14 +59,14 @@ :minWidth="minWidth" :maxHeight="300" :rowNumber="false" - :rowSelection="true" - :actionButton="true" - :dragSort="true" + :rowSelection="rowCanEdit" + :actionButton="rowCanEdit" + :dragSort="rowCanEdit" @valueChange="onValueChange" @added="onAdded" @deleted="onDeleted"> @@ -156,6 +156,7 @@ operTimeStr: '', prefixNo: 'QTRK', fileList:[], + rowCanEdit: true, //出入库管理开关,适合独立仓管场景 inOutManageFlag: false, model: {}, @@ -190,12 +191,15 @@ { title: '批号', key: 'batchNumber', width: '7%', type: FormTypes.input }, { title: '有效期', key: 'expirationDate',width: '7%', type: FormTypes.date }, { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal }, + { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal }, + { title: '已入库', key: 'finishNumber', width: '4%', type: FormTypes.normal }, { title: '数量', key: 'operNumber', width: '5%', type: FormTypes.inputNumber, statistics: true, validateRules: [{ required: true, message: '${title}不能为空' }] }, { title: '单价', key: 'unitPrice', width: '5%', type: FormTypes.inputNumber}, { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true }, - { title: '备注', key: 'remark', width: '5%', type: FormTypes.input } + { title: '备注', key: 'remark', width: '5%', type: FormTypes.input }, + { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden }, ] }, confirmLoading: false, @@ -225,18 +229,25 @@ editAfter() { this.billStatus = '0' this.currentSelectDepotId = '' + this.rowCanEdit = true this.changeColumnHide() this.changeFormTypes(this.materialTable.columns, 'snList', 0) this.changeFormTypes(this.materialTable.columns, 'batchNumber', 0) this.changeFormTypes(this.materialTable.columns, 'expirationDate', 0) + this.changeFormTypes(this.materialTable.columns, 'preNumber', 0) + this.changeFormTypes(this.materialTable.columns, 'finishNumber', 0) if (this.action === 'add') { this.addInit(this.prefixNo) this.fileList = [] } else { + if(this.model.linkNumber) { + this.rowCanEdit = false + this.materialTable.columns[1].type = FormTypes.normal + } this.model.operTime = this.model.operTimeStr this.fileList = this.model.fileName this.$nextTick(() => { - this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark', + this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark', 'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount')) }); // 加载子表数据 @@ -288,14 +299,13 @@ this.$refs.waitBillList.show('入库', '采购,销售退货', "1,3") this.$refs.waitBillList.title = "选择采购入库或销售退货" }, - waitBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) { + waitBillListOk(selectBillDetailRows, linkNumber, remark) { this.rowCanEdit = false this.materialTable.columns[1].type = FormTypes.normal this.changeFormTypes(this.materialTable.columns, 'preNumber', 1) this.changeFormTypes(this.materialTable.columns, 'finishNumber', 1) if(selectBillDetailRows && selectBillDetailRows.length>0) { let listEx = [] - let allTaxLastMoney = 0 for(let j=0; j0) { @@ -304,32 +314,13 @@ info.unitPrice = 0 info.allPrice = 0 info.linkId = info.id - allTaxLastMoney += info.taxLastMoney listEx.push(info) this.changeColumnShow(info) } this.materialTable.dataSource = listEx - ///给优惠后金额重新赋值 - allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = 0 - if(allTaxLastMoney!==0) { - discount = (discountMoney / allTaxLastMoney * 100).toFixed(2) - 0 - } - let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 - let changeAmount = discountLastMoney - if(deposit) { - this.depositStatus = true - changeAmount = (discountLastMoney - deposit).toFixed(2)-0 - } this.$nextTick(() => { this.form.setFieldsValue({ - 'organId': organId, 'linkNumber': linkNumber, - 'discount': discount, - 'discountMoney': discountMoney, - 'discountLastMoney': discountLastMoney, - 'deposit': deposit, - 'changeAmount': changeAmount, 'remark': remark }) }) diff --git a/jshERP-web/src/views/bill/modules/OtherOutModal.vue b/jshERP-web/src/views/bill/modules/OtherOutModal.vue index ffa67f7b..7b62f21a 100644 --- a/jshERP-web/src/views/bill/modules/OtherOutModal.vue +++ b/jshERP-web/src/views/bill/modules/OtherOutModal.vue @@ -21,7 +21,7 @@ -
@@ -46,7 +46,7 @@ - + @@ -59,14 +59,14 @@ :minWidth="minWidth" :maxHeight="300" :rowNumber="false" - :rowSelection="true" - :actionButton="true" - :dragSort="true" + :rowSelection="rowCanEdit" + :actionButton="rowCanEdit" + :dragSort="rowCanEdit" @valueChange="onValueChange" @added="onAdded" @deleted="onDeleted"> @@ -156,6 +156,7 @@ operTimeStr: '', prefixNo: 'QTCK', fileList:[], + rowCanEdit: true, //出入库管理开关,适合独立仓管场景 inOutManageFlag: false, model: {}, @@ -190,12 +191,15 @@ { title: '批号', key: 'batchNumber', width: '7%', type: FormTypes.popupJsh, kind: 'batch', multi: false }, { title: '有效期', key: 'expirationDate',width: '7%', type: FormTypes.input, readonly: true }, { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal }, + { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal }, + { title: '已入库', key: 'finishNumber', width: '4%', type: FormTypes.normal }, { title: '数量', key: 'operNumber', width: '5%', type: FormTypes.inputNumber, statistics: true, validateRules: [{ required: true, message: '${title}不能为空' }] }, { title: '单价', key: 'unitPrice', width: '5%', type: FormTypes.inputNumber}, { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true }, - { title: '备注', key: 'remark', width: '5%', type: FormTypes.input } + { title: '备注', key: 'remark', width: '5%', type: FormTypes.input }, + { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden }, ] }, confirmLoading: false, @@ -225,18 +229,25 @@ editAfter() { this.billStatus = '0' this.currentSelectDepotId = '' + this.rowCanEdit = true this.changeColumnHide() this.changeFormTypes(this.materialTable.columns, 'snList', 0) this.changeFormTypes(this.materialTable.columns, 'batchNumber', 0) this.changeFormTypes(this.materialTable.columns, 'expirationDate', 0) + this.changeFormTypes(this.materialTable.columns, 'preNumber', 0) + this.changeFormTypes(this.materialTable.columns, 'finishNumber', 0) if (this.action === 'add') { this.addInit(this.prefixNo) this.fileList = [] } else { + if(this.model.linkNumber) { + this.rowCanEdit = false + this.materialTable.columns[1].type = FormTypes.normal + } this.model.operTime = this.model.operTimeStr this.fileList = this.model.fileName this.$nextTick(() => { - this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark', + this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark', 'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount')) }); // 加载子表数据 @@ -288,14 +299,13 @@ this.$refs.waitBillList.show('出库', '销售,采购退货', "1,3") this.$refs.waitBillList.title = "选择销售出库或采购退货" }, - waitBillListOk(selectBillDetailRows, linkNumber, organId, discountMoney, deposit, remark) { + waitBillListOk(selectBillDetailRows, linkNumber, remark) { this.rowCanEdit = false this.materialTable.columns[1].type = FormTypes.normal this.changeFormTypes(this.materialTable.columns, 'preNumber', 1) this.changeFormTypes(this.materialTable.columns, 'finishNumber', 1) if(selectBillDetailRows && selectBillDetailRows.length>0) { let listEx = [] - let allTaxLastMoney = 0 for(let j=0; j0) { @@ -304,32 +314,13 @@ info.unitPrice = 0 info.allPrice = 0 info.linkId = info.id - allTaxLastMoney += info.taxLastMoney listEx.push(info) this.changeColumnShow(info) } this.materialTable.dataSource = listEx - ///给优惠后金额重新赋值 - allTaxLastMoney = allTaxLastMoney?allTaxLastMoney:0 - let discount = 0 - if(allTaxLastMoney!==0) { - discount = (discountMoney / allTaxLastMoney * 100).toFixed(2) - 0 - } - let discountLastMoney = (allTaxLastMoney - discountMoney).toFixed(2)-0 - let changeAmount = discountLastMoney - if(deposit) { - this.depositStatus = true - changeAmount = (discountLastMoney - deposit).toFixed(2)-0 - } this.$nextTick(() => { this.form.setFieldsValue({ - 'organId': organId, 'linkNumber': linkNumber, - 'discount': discount, - 'discountMoney': discountMoney, - 'discountLastMoney': discountLastMoney, - 'deposit': deposit, - 'changeAmount': changeAmount, 'remark': remark }) }) diff --git a/jshERP-web/src/views/bill/modules/PurchaseInModal.vue b/jshERP-web/src/views/bill/modules/PurchaseInModal.vue index 62dc3a14..27620beb 100644 --- a/jshERP-web/src/views/bill/modules/PurchaseInModal.vue +++ b/jshERP-web/src/views/bill/modules/PurchaseInModal.vue @@ -89,7 +89,7 @@ 历史单据 - + 导入明细 diff --git a/jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue b/jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue index 3a0e48df..a0af9d7c 100644 --- a/jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue +++ b/jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue @@ -89,7 +89,7 @@ 历史单据 - + 导入明细 diff --git a/jshERP-web/src/views/bill/modules/SaleOutModal.vue b/jshERP-web/src/views/bill/modules/SaleOutModal.vue index 7b0f3266..f950a41a 100644 --- a/jshERP-web/src/views/bill/modules/SaleOutModal.vue +++ b/jshERP-web/src/views/bill/modules/SaleOutModal.vue @@ -90,7 +90,7 @@ 历史单据 - + 导入明细