|
|
@@ -436,7 +436,7 @@ const StockLedgerFixPageClient: React.FC = () => { |
|
|
try { |
|
|
try { |
|
|
const res = await runStockLedgerFixInventory(); |
|
|
const res = await runStockLedgerFixInventory(); |
|
|
setInventoryMessage( |
|
|
setInventoryMessage( |
|
|
`inventory 1.0 完成:回填 stockUomId ${res.patchedStockUomId} 列、新增 ${res.inserted} 列、重算 ${res.updated} 列、之後仍缺 UOM ${res.missingUomPairsAfter}、仍 NULL stockUomId ${res.nullStockUomIdAfter}`, |
|
|
|
|
|
|
|
|
`inventory 1.0 完成:回填 stockUomId ${res.patchedStockUomId} 列、新增 ${res.inserted} 列、殘列 deleted ${res.orphansDeleted ?? 0}、重算 ${res.updated} 列、之後仍缺 UOM ${res.missingUomPairsAfter}、仍 NULL stockUomId ${res.nullStockUomIdAfter}`, |
|
|
); |
|
|
); |
|
|
await loadInventory(); |
|
|
await loadInventory(); |
|
|
} catch (e) { |
|
|
} catch (e) { |
|
|
@@ -713,7 +713,8 @@ const StockLedgerFixPageClient: React.FC = () => { |
|
|
<Typography variant="h6">1.0 inventory(方案 A)</Typography> |
|
|
<Typography variant="h6">1.0 inventory(方案 A)</Typography> |
|
|
<Typography variant="body2" color="text.secondary"> |
|
|
<Typography variant="body2" color="text.secondary"> |
|
|
保留現有 id;lot 有、inventory 沒有的 UOM 會新增;onHand = Σ(in−out) 按 |
|
|
保留現有 id;lot 有、inventory 沒有的 UOM 會新增;onHand = Σ(in−out) 按 |
|
|
item+UOM。沒有 lot 的列會變成 0。請在進出倉暫停時執行,再逐日 Fix。 |
|
|
|
|
|
|
|
|
item+UOM。沒有 lot 的列會變成 0。同一料多顆舊列時只留一顆 stock UOM |
|
|
|
|
|
桶,其餘 deleted=1。請在進出倉暫停時執行,再逐日 Fix。 |
|
|
</Typography> |
|
|
</Typography> |
|
|
{inventoryError && <Alert severity="error">{inventoryError}</Alert>} |
|
|
{inventoryError && <Alert severity="error">{inventoryError}</Alert>} |
|
|
{inventoryMessage && ( |
|
|
{inventoryMessage && ( |
|
|
|