From 4477a4a90fe3c441c25c5cddddee05aa32c8113c Mon Sep 17 00:00:00 2001
From: zuozhengqing <a13193816592@163.com>
Date: 星期六, 28 十月 2023 18:24:50 +0800
Subject: [PATCH] 上架规则列表编辑,产品和产品类别只能展开有数据的
---
src/views/operate/inventoryAdjustment/index.vue | 18 +++++++++++++-----
1 files changed, 13 insertions(+), 5 deletions(-)
diff --git a/src/views/operate/inventoryAdjustment/index.vue b/src/views/operate/inventoryAdjustment/index.vue
index a4b1734..8e4e94d 100644
--- a/src/views/operate/inventoryAdjustment/index.vue
+++ b/src/views/operate/inventoryAdjustment/index.vue
@@ -144,6 +144,7 @@
this.adjustAmount = val - row.amount
this.tableList.tableData[row.index].adjustAmount = this.adjustAmount
// this.differenceAmount = val
+ this.differenceAmount=val
},
// 鏂板
addProductClick() {
@@ -178,10 +179,11 @@
this.addTitle = "鏂板缓"
this.showDiscard = false
let requestUrl = this.currentRowId === 0 ? addInventoryAdjustment : updateInventoryAdjustment
+
requestUrl({
- // amount: this.amount,
- adjustAmount: this.adjustAmount,
- // differenceAmount: this.differenceAmount,
+ amount: this.amount,
+ // adjustAmount: this.adjustAmount,
+ differenceAmount: this.differenceAmount,
locationId: this.locationId,
operationId: this.operationId,
productId: this.productId
@@ -214,6 +216,11 @@
},
// 鍙栨秷
discardBtnClick() {
+ this.tableList.tableData.forEach((item)=>{
+ item.differenceAmount=0;
+ item.adjustAmount=0
+ })
+ this.tableList
if (this.isRowClick) {
this.tableData.map((item) => {
item.isEdit = true
@@ -236,7 +243,7 @@
console.log("鍘嗗彶")
this.$router.push({
name: "inventoryAdjustmentHistory",
- params: { locationId: row.locationId, productId: row.productId }
+ params: { locationId: row.locationId, productId: row.productId,baseOperationType:row.baseOperationType}
})
}
},
@@ -251,7 +258,7 @@
handleUseClick(row) {
// scope.row.isSet = !scope.row.isSet
finishInventoryAdjustment({
- locationProductAmountId: row.locationProductAmount,
+ locationProductAmountId: row.locationProductAmountId,
operationId: row.operationId,
productId: row.productId
}).then((res) => {
@@ -268,6 +275,7 @@
},
// 琛岀偣鍑�
tableRowClick(row, rowIndex) {
+ this.locationId=row.locationId
this.rowIndex = rowIndex
this.isSel()
if (!this.isNoProduct && this.currentRowId === 0) {
--
Gitblit v1.8.0