From da92619f9a115715942ec0f2b218355dfdd3d820 Mon Sep 17 00:00:00 2001
From: zhang_li <2235006734@qqq.com>
Date: Tue, 15 Oct 2024 15:37:07 +0800
Subject: [PATCH] =?UTF-8?q?YT-403pda=20=E6=89=AB=E6=8F=8F2=E4=B8=AA?=
=?UTF-8?q?=E6=89=B9=E6=AC=A1=EF=BC=8C=E6=B2=A1=E6=9C=89=E5=8C=BA=E5=88=86?=
=?UTF-8?q?=E6=89=B9=E6=AC=A1=E6=98=BE=E7=A4=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../balance/recommendBalanceBatch.vue | 4 +-
.../coms/comDeliverDetailCardBatch.vue | 5 +-
.../deliver/coms/comScanDeliverPackBatch.vue | 54 ++++++++++++-------
src/pages/deliver/job/deliverDetailBatch.vue | 3 +-
4 files changed, 40 insertions(+), 26 deletions(-)
diff --git a/src/mycomponents/balance/recommendBalanceBatch.vue b/src/mycomponents/balance/recommendBalanceBatch.vue
index 10acdfd1..b682d4d2 100644
--- a/src/mycomponents/balance/recommendBalanceBatch.vue
+++ b/src/mycomponents/balance/recommendBalanceBatch.vue
@@ -6,8 +6,8 @@
推荐
-
-
+
+
diff --git a/src/pages/deliver/coms/comDeliverDetailCardBatch.vue b/src/pages/deliver/coms/comDeliverDetailCardBatch.vue
index 76008fbb..f8138715 100644
--- a/src/pages/deliver/coms/comDeliverDetailCardBatch.vue
+++ b/src/pages/deliver/coms/comDeliverDetailCardBatch.vue
@@ -3,11 +3,11 @@
-
+
+ @click="swipeClick($event,item,index)" style='padding:20rpx 0px 5px 0px;align-items: center;'>
r.itemCode == itemCode);
- item.scaned =true
+ // item.scaned =true
let fromLocation = that.toLocation.find(l => l.fromLocationCode == that.fromLocationCode);
// 成品发货任务--同一物料,可以扫描提交不在任务中的库位
if(!fromLocation){
@@ -334,7 +334,6 @@
item.Locations.push(fromLocation)
}
if (fromLocation != undefined) {
- console.log(34444)
let batch = fromLocation.batch;
if (batch != undefined) {
that.addRecord(item.batch, label, balance, packageInfo)
@@ -402,27 +401,30 @@
balance.packQty = packageInfo.packQty
balance.packUnit = packageInfo.packUnit
let record = {
- scaned: true,
- itemCode: label.itemCode,
- packingNumber: label.packingNumber,
- batch: label.batch,
- qty: Number(label.qty) > Number(balance.qty) ? Number(balance.qty) : Number(label.qty),
- uom: balance.uom,
- inventoryStatus: balance.inventoryStatus,
- balance: balance,
- toLocationCode: this.toLocationCode,
- supplierCode: label.supplierCode,
- packUnit: packageInfo.packUnit,
- packQty: packageInfo.packQty,
- singlePrice:balance.singlePrice,
- amount:balance.amount
+ scaned: true,
+ itemCode: label.itemCode,
+ packingNumber: label.packingNumber,
+ parentPackingNumber: packageInfo.parentNumber,
+ batch: label.batch,
+ // qty: Number(balance.qty),
+ // qty: Number(label.qty) > Number(balance.qty) ? Number(balance.qty) : Number(label.qty),
+ qty: Number(balance.qty),
+ handleQty:0,
+ uom: balance.uom,
+ inventoryStatus: balance.inventoryStatus,
+ balance: balance,
+ toLocationCode: this.toLocationCode,
+ supplierCode: label.supplierCode,
+ packUnit: packageInfo.packUnit,
+ packQty: packageInfo.packQty,
+ fromLocationCode:balance.locationCode,
}
return record;
},
calcBatchHandleQty(batch,label,balance) {
this.dataContent.subList.forEach(item => {
- if(item.itemCode == balance.itemCode&&item.batch == batch){
+ if(item.itemCode == label.itemCode&&item.batch == label.batch){
item.handleQty = item.handleQty || 0
item.handleQty = calc.add(item.handleQty, label.qty);
}
@@ -430,8 +432,22 @@
},
addRecord(batch, label, balance, packageInfo) {
- this.calcBatchHandleQty(batch,label,balance);
- this.getfocus();
+ var checkData = this.dataContent.subList.find(r => {
+ if (r.batch == balance.batch) {
+ return r;
+ }
+ })
+ if (checkData) {
+ checkData.scaned = true
+ this.calcBatchHandleQty(batch,label,balance);
+ this.getfocus();
+ } else {
+ let record = this.creatRecord(label, balance, packageInfo);
+ this.dataContent.subList.push(record);
+ this.calcBatchHandleQty(batch,label,balance);
+ this.getfocus();
+ this.$emit("afterScan");
+ }
},
getfocus() {
diff --git a/src/pages/deliver/job/deliverDetailBatch.vue b/src/pages/deliver/job/deliverDetailBatch.vue
index 0ae33379..ef0be975 100644
--- a/src/pages/deliver/job/deliverDetailBatch.vue
+++ b/src/pages/deliver/job/deliverDetailBatch.vue
@@ -312,7 +312,7 @@
}
subItem.recordList = []
let record = {};
- record.handleQty = r.qty;
+ record.handleQty = r.handleQty;
record.toContainerNumber = r.ContainerNumber;
record.toInventoryStatus = r.inventoryStatus;
record.toLocationCode = subItem.toLocationCode;
@@ -438,7 +438,6 @@
var datacontent = {}
//克隆对象,深度克隆,防止双向绑定同一个变量
// Object.assign(datacontent, this.detailSource);
- console.log(2323)
this.$refs.comScanIssuePack.openScanPopup(this.detailSource, this.jobContent);
},
closeScanPopup() {