fix: 解除库存盘点弹窗500条限制并修复字段匹配
This commit is contained in:
@ -657,7 +657,7 @@ const resumeSession = async () => {
|
|||||||
const res: any = await request({
|
const res: any = await request({
|
||||||
url: '/v1/inbound/stock/draft/list',
|
url: '/v1/inbound/stock/draft/list',
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params: { page: 1, limit: 500 } // ★ 限制单次加载数量,防止内存溢出
|
params: { page: 1, limit: 99999 } // ★ 获取全量草稿数据
|
||||||
})
|
})
|
||||||
|
|
||||||
const drafts = res && res.items ? res.items : []
|
const drafts = res && res.items ? res.items : []
|
||||||
@ -985,7 +985,7 @@ const fetchInventoryList = async (silent = false) => {
|
|||||||
method: 'get',
|
method: 'get',
|
||||||
params: {
|
params: {
|
||||||
page: 1,
|
page: 1,
|
||||||
limit: 500, // ★ 限制单次加载数量,防止内存溢出
|
limit: 99999, // ★ 获取全量草稿数据
|
||||||
keyword: listKeyword.value,
|
keyword: listKeyword.value,
|
||||||
session_id: currentSessionId.value // ★ 必须传递 session_id 隔离会话
|
session_id: currentSessionId.value // ★ 必须传递 session_id 隔离会话
|
||||||
}
|
}
|
||||||
@ -1017,7 +1017,7 @@ const fetchInventoryList = async (silent = false) => {
|
|||||||
material_name: item.material_name,
|
material_name: item.material_name,
|
||||||
spec_model: item.spec_model,
|
spec_model: item.spec_model,
|
||||||
stock_qty: item.stock_qty, // 账面数(盲盘时隐藏)
|
stock_qty: item.stock_qty, // 账面数(盲盘时隐藏)
|
||||||
quantity: draft?.quantity || 0, // 实盘数
|
quantity: draft?.quantity ?? draft?.qty_actual ?? 0, // 兼容后端字段名
|
||||||
diff_qty: draft ? (draft.quantity - item.stock_qty) : -item.stock_qty, // 差异
|
diff_qty: draft ? (draft.quantity - item.stock_qty) : -item.stock_qty, // 差异
|
||||||
remark: draft?.remark || '',
|
remark: draft?.remark || '',
|
||||||
warehouse_location: item.warehouse_location
|
warehouse_location: item.warehouse_location
|
||||||
|
|||||||
Reference in New Issue
Block a user