Browse Source

修改数量显示错误

wms3.0_pda
lijuncheng 10 months ago
parent
commit
ad191070a8
  1. 6
      common/detail.js
  2. 8
      common/record.js
  3. 931
      pages/count/job/countDetail.vue
  4. 11
      pages/count/record/countRecord.vue
  5. 3
      pages/issue/coms/comScanIssuePack.vue
  6. 3
      pages/transfer/job/transferDetail.vue
  7. 8
      pages/unPlanned/record/receiptRecord.vue

6
common/detail.js

@ -58,10 +58,12 @@ import {
//计算实际数量 //计算实际数量
export function calcHandleQty(detailSource) { export function calcHandleQty(detailSource) {
for (let item of detailSource) { for (let item of detailSource) {
item.handleQty = 0; item.handleQty = new Decimal(0).toNumber();
item.qty = new Decimal(0).toNumber();
for (let detail of item.subList) { for (let detail of item.subList) {
if (detail != undefined && detail.scaned) { if (detail != undefined && detail.scaned) {
item.handleQty = calc.add(item.handleQty, detail.handleQty) item.handleQty = calc.add(item.handleQty,detail.handleQty);
item.qty = calc.add(item.qty,detail.qty);
} }
} }
} }

8
common/record.js

@ -44,9 +44,13 @@ export function createDetailInfo(balance, pack) {
export function calcHandleQty(detailSource) { export function calcHandleQty(detailSource) {
for (let item of detailSource) { for (let item of detailSource) {
item.handleQty = new Decimal(0).toNumber(); item.handleQty = new Decimal(0).toNumber();
item.qty = new Decimal(0).toNumber();
for (let detail of item.subList) { for (let detail of item.subList) {
if (detail != undefined && detail.scaned) { if(detail!=undefined){
item.handleQty = calc.add(item.handleQty,detail.handleQty); if(detail.scaned){
item.handleQty = calc.add(item.handleQty,detail.handleQty);
}
item.qty = calc.add(item.qty,detail.qty);
} }
} }
} }

931
pages/count/job/countDetail.vue

File diff suppressed because it is too large

11
pages/count/record/countRecord.vue

@ -156,11 +156,14 @@
calcHandleQty() { calcHandleQty() {
for (let item of this.detailSource) { for (let item of this.detailSource) {
item.handleQty = 0; item.handleQty = new Decimal(0).toNumber();
item.qty = new Decimal(0).toNumber();
for (let detail of item.subList) { for (let detail of item.subList) {
if (item.scaned) { ifdetail=undefined){
if(detail.scaned){
item.handleQty = calc.add(item.handleQty,detail.qty) item.handleQty = calc.add(item.handleQty,detail.handleQty);
}
item.qty = calc.add(item.qty,detail.qty);
} }
} }
} }

3
pages/issue/coms/comScanIssuePack.vue

@ -389,7 +389,8 @@
itemCode: label.itemCode, itemCode: label.itemCode,
packingNumber: label.packingNumber, packingNumber: label.packingNumber,
batch: label.batch, batch: label.batch,
qty: Number(label.qty) > Number(balance.qty) ? Number(balance.qty) : Number(label.qty), qty: Number(balance.qty),
// qty: Number(label.qty) > Number(balance.qty) ? Number(balance.qty) : Number(label.qty),
uom: balance.uom, uom: balance.uom,
inventoryStatus: balance.inventoryStatus, inventoryStatus: balance.inventoryStatus,
balance: balance, balance: balance,

3
pages/transfer/job/transferDetail.vue

@ -245,11 +245,12 @@
calcHandleQty() { calcHandleQty() {
for (let item of this.detailSource) { for (let item of this.detailSource) {
item.handleQty = 0; item.handleQty = new Decimal(0).toNumber();
for (let detail of item.subList) { for (let detail of item.subList) {
if (detail.record != undefined) { if (detail.record != undefined) {
item.handleQty = calc.add(item.handleQty,detail.record.qty) item.handleQty = calc.add(item.handleQty,detail.record.qty)
} }
} }
} }
this.continueScan() this.continueScan()

8
pages/unPlanned/record/receiptRecord.vue

@ -68,8 +68,10 @@
import { import {
calc calc
} from '@/common/calc.js'; } from '@/common/calc.js';
import { Decimal } from 'decimal.js';// import {
Decimal
} from 'decimal.js'; //
import { import {
goHome, goHome,
updateTitle, updateTitle,
@ -202,9 +204,11 @@
calcHandleQty() { calcHandleQty() {
for (let item of this.detailSource) { for (let item of this.detailSource) {
item.handleQty = new Decimal(0).toNumber(); item.handleQty = new Decimal(0).toNumber();
item.qty = new Decimal(0).toNumber();
for (let detail of item.subList) { for (let detail of item.subList) {
if (detail != undefined) { if (detail != undefined) {
item.handleQty = calc.add(item.handleQty, detail.handleQty) item.handleQty = calc.add(item.handleQty, detail.handleQty)
item.qty = calc.add(item.qty, detail.qty);
} }
} }
} }

Loading…
Cancel
Save