Browse Source

修改盘点编辑功能

wms3.0_pda
niexiting 8 months ago
parent
commit
62172dbef4
  1. 130
      pages/count/job/countDetail.vue

130
pages/count/job/countDetail.vue

@ -328,18 +328,21 @@
} else {
let subItem = item.subList.find(item => {
if (item.packingNumber == that.label.packingNumber &&
item.batch == that.label.batch) {
item.batch == that.label.batch && item.scaned == true) {
return item;
}
})
if (subItem != undefined && subItem.scaned) {
if (subItem != undefined) {
this.$refs.comMessage.showQuestionMessage("箱码【" + that.label.packingNumber +
"】已经完成盘点,是否要编辑盘点结果?",
res => {
if (res) {
this.$refs.countQtyEdit.openEditPopupShowSeconds(subItem,
this.currentEditItem = subItem;
this.$refs.countQtyEdit.openEditPopup(subItem,
item.subList);
// this.$refs.countQtyEdit.openEditPopupShowSeconds(subItem,
// item.subList);
} else {
this.scanPopupGetFocus();
}
@ -390,46 +393,36 @@
editConfirm(qty, inventoryStatus, mode) {
let that = this;
var detail = that.detailSource.find(r => r.itemCode == that.package.itemCode);
//
if (detail == undefined) {
//
that.addNewItemCodeToList(qty, inventoryStatus)
} else {
var itemEditInfo = detail.subList.find(item => {
if (item.packingNumber == that.package.number &&
item.batch == that.package.batch &&
item.inventoryStatus == inventoryStatus) {
return item;
}
})
//
if (mode == 'edit') {
this.currentEditItem.handleQty = qty;
this.currentEditItem.inventoryStatus = inventoryStatus;
} else { //
//
var detail = that.detailSource.find(r => r.itemCode == that.package.itemCode);
if (detail == undefined) {
//
that.addNewItemCodeToList(qty, inventoryStatus)
} else {
var itemEditInfo = detail.subList.find(item => {
if (item.packingNumber == that.package.number &&
item.batch == that.package.batch &&
item.inventoryStatus == inventoryStatus) {
return item;
}
})
if (itemEditInfo == undefined) {
//
if (mode == 'edit') {
that.currentEditItem.handleQty = qty;
that.currentEditItem.inventoryStatus = inventoryStatus;
} else {
if (itemEditInfo == undefined) {
//
that.addExistItemCodeToList(detail, qty, inventoryStatus);
} else { //
itemEditInfo.scaned = true;
itemEditInfo.handleQty = qty;
itemEditInfo.inventoryStatus = inventoryStatus;
itemEditInfo.balanceQty = that.balance.qty;
itemEditInfo.stdPackQty = that.package.stdPackQty;
itemEditInfo.stdPackUnit = that.package.stdPackUnit;
}
} else {
itemEditInfo.scaned = true;
itemEditInfo.handleQty = qty;
itemEditInfo.inventoryStatus = inventoryStatus;
itemEditInfo.balanceQty = that.balance.qty;
itemEditInfo.stdPackQty = that.package.stdPackQty;
itemEditInfo.stdPackUnit = that.package.stdPackUnit;
//0
if (mode == 'edit') {
itemEditInfo.scaned = false;
that.currentEditItem.handleQty = 0;
}
// this.$refs.countQtyEdit.openEditPopupShowSeconds(itemEditInfo, detail
// .subList);
that.updateData()
}
setTimeout(r => {
@ -437,8 +430,64 @@
this.scanPopupGetFocus();
}, 100)
}
},
// editConfirm(qty, inventoryStatus, mode) {
// let that = this;
// var detail = that.detailSource.find(r => r.itemCode == that.package.itemCode);
// //
// if (detail == undefined) {
// //
// that.addNewItemCodeToList(qty, inventoryStatus)
// } else {
// var itemEditInfo = detail.subList.find(item => {
// if (item.packingNumber == that.package.number &&
// item.batch == that.package.batch &&
// item.inventoryStatus == inventoryStatus) {
// return item;
// }
// })
// if (itemEditInfo == undefined) {
// //
// if (mode == 'edit') {
// that.currentEditItem.handleQty = qty;
// that.currentEditItem.inventoryStatus = inventoryStatus;
// } else {
// that.addExistItemCodeToList(detail, qty, inventoryStatus);
// }
// } else { //
// if (itemEditInfo.scaned) {
// }
// itemEditInfo.scaned = true;
// itemEditInfo.handleQty = qty;
// itemEditInfo.inventoryStatus = inventoryStatus;
// itemEditInfo.balanceQty = that.balance.qty;
// itemEditInfo.stdPackQty = that.package.stdPackQty;
// itemEditInfo.stdPackUnit = that.package.stdPackUnit;
// //0
// if (mode == 'edit') {
// itemEditInfo.scaned = false;
// that.currentEditItem.handleQty = 0;
// }
// // this.$refs.countQtyEdit.openEditPopupShowSeconds(itemEditInfo, detail
// // .subList);
// that.updateData()
// }
// setTimeout(r => {
// this.calcHandleQty();
// this.scanPopupGetFocus();
// }, 100)
// }
// },
editClose() {
this.scanPopupGetFocus();
},
@ -554,7 +603,6 @@
return totalCount;
},
commit() {
this.scanCount = this.getScanCount();

Loading…
Cancel
Save