|
|
|
|
@ -359,7 +359,7 @@ import { getCrmCustomerInfoList } from '@/api/oa/crm/customerInfo';
|
|
|
|
|
import { getWmsWarehouseInfoList } from '@/api/wms/warehouseInfo';
|
|
|
|
|
import WmsInventorySelect from '@/components/WmsInventorySelect/index.vue';
|
|
|
|
|
import { ElMessage } from 'element-plus';
|
|
|
|
|
import { getWmsOutStockDetailsList } from '@/api/wms/outStockDetails';
|
|
|
|
|
import { countUnOutStockDetails, getWmsOutStockDetailsList } from '@/api/wms/outStockDetails';
|
|
|
|
|
|
|
|
|
|
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
|
|
|
|
const { wms_out_bill_status, out_stock_type, flow_status } = toRefs<any>(proxy?.useDict('wms_out_bill_status', 'out_stock_type', 'flow_status'));
|
|
|
|
|
@ -618,6 +618,19 @@ const handleUpdate = async (row?: OutStockBillVO) => {
|
|
|
|
|
Object.assign(form.value, res.data);
|
|
|
|
|
const chiildRes = await getWmsOutStockDetailsList({ outStockBillId: _outStockBillId });
|
|
|
|
|
selectInventorys.value = chiildRes.data || [];
|
|
|
|
|
// 查询锁定库存数量
|
|
|
|
|
for (const item of selectInventorys.value) {
|
|
|
|
|
try {
|
|
|
|
|
const lockRes = await countUnOutStockDetails({
|
|
|
|
|
inventoryDetailsId: item.inventoryDetailsId,
|
|
|
|
|
outStockDetailsId: item.outStockDetailsId
|
|
|
|
|
});
|
|
|
|
|
item.lockedAmount = lockRes.data.outStockAmount || 0;
|
|
|
|
|
} catch (error) {
|
|
|
|
|
console.error('查询锁定库存失败:', error);
|
|
|
|
|
item.lockedAmount = 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
dialog.visible = true;
|
|
|
|
|
dialog.title = '修改出库单';
|
|
|
|
|
};
|
|
|
|
|
|