diff --git a/package.json b/package.json index 096afb2..c9ad9c3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wms-pda", - "version": "1.0.136", + "version": "1.0.137", "private": true, "description": "天豹云仓 WMS_PDA(uni-app Vue2 + @vue/cli 4.5)", "scripts": { diff --git a/src/manifest.json b/src/manifest.json index c8f6b61..976049d 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -2,8 +2,8 @@ "name" : "WMS_PDA", "appid" : "__UNI__0B3DAD3", "description" : "多平台快速开发的UI框架", - "versionName" : "1.0.136", - "versionCode" : 1000136, + "versionName" : "1.0.137", + "versionCode" : 1000137, "transformPx" : false, "app-plus" : { "optimization" : { diff --git a/src/pages/warehouse/inventoryCount-comps/CountWorkCard.vue b/src/pages/warehouse/inventoryCount-comps/CountWorkCard.vue index c325fcb..e8511be 100644 --- a/src/pages/warehouse/inventoryCount-comps/CountWorkCard.vue +++ b/src/pages/warehouse/inventoryCount-comps/CountWorkCard.vue @@ -66,16 +66,18 @@ {{ child.statusText }} + 待拣货 {{ child.amount.systemLabel || '账面' }} {{ child.amount.systemText }} · 已盘 {{ child.amount.checkedText }} 实盘 {{ child.quantityText }} {{ child.amount.bookHint }} + {{ pickingHint(child) }} + 待拣货 @@ -215,6 +228,12 @@ export default { background: #fdecec; } +/* 静态盘点拣货未完成(后端会拒绝上报) */ +.work-card__tag--picking { + color: #e64340; + background: #fdecec; +} + .work-card__meta { margin-top: 10rpx; display: flex; @@ -406,6 +425,16 @@ export default { color: #b8811a; } +/* 拣货未完成提示:红色(与账面口径提示区分) */ +.work-child__hint--picking { + color: #e64340; +} + +/* 拣货未完成时的录入框占位(不可录入) */ +.work-input__readonly--picking { + color: #e64340; +} + .work-child__side .work-card__amount { margin-left: 16rpx; } diff --git a/src/pages/warehouse/inventoryCount-comps/countModel.js b/src/pages/warehouse/inventoryCount-comps/countModel.js index 22533f6..50b51ae 100644 --- a/src/pages/warehouse/inventoryCount-comps/countModel.js +++ b/src/pages/warehouse/inventoryCount-comps/countModel.js @@ -677,7 +677,7 @@ function buildWorkAmount(systemQuantity, checkedQuantity, diffQuantity, open, me } /** 录入单元:detailId + location + 输入值(original 用于判断是否已修改) */ -function buildWorkUnit(detailId, location, currentQuantity, reported, stockId, spaceId) { +function buildWorkUnit(detailId, location, currentQuantity, reported, stockId, spaceId, pickingPending = false) { const value = toNumberString(currentQuantity); const done = !!reported; return { @@ -689,7 +689,9 @@ function buildWorkUnit(detailId, location, currentQuantity, reported, stockId, s inputValue: done ? value : '', original: done ? value : '', reported: done, - reporting: false + reporting: false, + // 静态盘点拣货未完成(0.3.320):录入框置灰,report 会被后端拒绝 + pickingPending: !!pickingPending }; } @@ -757,6 +759,7 @@ function normalizeSpaceWorkRow(item, index, open, options = {}) { const checkedRaw = good.checked_quantity !== undefined ? good.checked_quantity : good.checkedQuantity; const done = String(good.status || '').trim().toLowerCase() === 'checked'; const bookMeta = pickBookMeta(good, options.isStatic); + const pickingMeta = pickPickingMeta(good); return { key: `${spaceCode}-${detailId || goodIndex + 1}`, title: firstValue(good, ['item_name', 'itemName']) || '--', @@ -770,8 +773,13 @@ function normalizeSpaceWorkRow(item, index, open, options = {}) { open, bookMeta ), + // 静态盘点拣货完成标记(0.3.320) + hasPickingFlag: pickingMeta.hasPickingFlag, + pickingCompleted: pickingMeta.pickingCompleted, + pickingPending: pickingMeta.pickingPending, + lockedQuantity: pickingMeta.lockedQuantity, quantityText: '', - unit: buildWorkUnit(detailId, spaceCode, checkedRaw, done, firstValue(good, ['stock_id', 'stockId']), rowSpaceId) + unit: buildWorkUnit(detailId, spaceCode, checkedRaw, done, firstValue(good, ['stock_id', 'stockId']), rowSpaceId, pickingMeta.pickingPending) }; }); // 库位统计(口径=商品条数):商品 status=checked 即该明细在该库位已有作业记录 @@ -779,6 +787,8 @@ function normalizeSpaceWorkRow(item, index, open, options = {}) { const checkedCount = rawGoods.filter(row => String((row && row.status) || '').trim().toLowerCase() === 'checked').length; const uncheckedCount = Math.max(0, total - checkedCount); const allDone = total > 0 && checkedCount === total; + // 静态盘点:该库位下拣货未完成的商品数(宫格与作业页提示用) + const pickingPendingCount = children.filter(child => child.pickingPending).length; const spaceName = firstValue(source, ['custom_name', 'customName']); return { key: `space-${firstValue(source, ['id']) || spaceCode}`, @@ -808,6 +818,8 @@ function normalizeSpaceWorkRow(item, index, open, options = {}) { unknownCount: 0, checkedCount, uncheckedCount, + // 静态盘点拣货未完成的商品数(>0 时宫格/作业页提示「待拣货」) + pickingPendingCount, gridText: spaceName || spaceCode, gridCode: spaceCode, gridLabel: shortLocationLabel(spaceCode), diff --git a/src/pages/warehouse/inventoryCountSpace.vue b/src/pages/warehouse/inventoryCountSpace.vue index 86d7af9..f017bd9 100644 --- a/src/pages/warehouse/inventoryCountSpace.vue +++ b/src/pages/warehouse/inventoryCountSpace.vue @@ -34,6 +34,10 @@ 当前盘点任务状态不可作业,仅可查看 + + 静态盘点:{{ pickingPendingCount }} 项商品尚未完成拣货,仅这些商品暂不能上报 + + 加载中... @@ -108,6 +112,11 @@ export default { progressText() { if (!this.row) return '--'; return this.row.gridProgressText || `${this.row.goodsCount || 0} 项`; + }, + // 静态盘点:本库位下拣货未完成的商品数(>0 时顶部提示) + pickingPendingCount() { + const children = this.row && Array.isArray(this.row.children) ? this.row.children : []; + return children.filter(child => child && child.pickingPending).length; } }, onLoad(options = {}) { @@ -227,6 +236,12 @@ export default { // ===== 录入上报(check.report)===== async handleWorkReport(unit) { if (!this.editable || !unit || unit.reporting) return; + // 静态盘点拣货未完成:后端会拒绝上报,这里先给明确提示 + if (unit.pickingPending) { + uni.showToast({ title: '商品尚未完成拣货,请等待拣货完成', icon: 'none' }); + this.speakMessage('拣货未完成,暂不能上报', { force: true, minInterval: 0 }); + return; + } const raw = String(unit.inputValue || '').trim(); if (raw === '') return; if (raw === String(unit.original || '')) return;