Browse Source

stock take batch save fix

production
CANCERYS\kw093 3 weeks ago
parent
commit
4f374cdff9
1 changed files with 5 additions and 3 deletions
  1. +5
    -3
      src/app/api/stockTake/actions.ts

+ 5
- 3
src/app/api/stockTake/actions.ts View File

@@ -85,6 +85,7 @@ export const getInventoryLotDetailsBySection = async (
pageSize?: number, pageSize?: number,
stockTakeRoundId?: number | null stockTakeRoundId?: number | null
) => { ) => {
/*
console.log('🌐 [API] getInventoryLotDetailsBySection called with:', { console.log('🌐 [API] getInventoryLotDetailsBySection called with:', {
stockTakeSection, stockTakeSection,
stockTakeId, stockTakeId,
@@ -92,7 +93,7 @@ export const getInventoryLotDetailsBySection = async (
pageNum, pageNum,
pageSize pageSize
}); });
*/
const encodedSection = encodeURIComponent(stockTakeSection); const encodedSection = encodeURIComponent(stockTakeSection);
let url = `${BASE_API_URL}/stockTakeRecord/inventoryLotDetailsBySection?stockTakeSection=${encodedSection}&pageNum=${pageNum}&pageSize=${pageSize}`; let url = `${BASE_API_URL}/stockTakeRecord/inventoryLotDetailsBySection?stockTakeSection=${encodedSection}&pageNum=${pageNum}&pageSize=${pageSize}`;
if (stockTakeId != null && stockTakeId > 0) { if (stockTakeId != null && stockTakeId > 0) {
@@ -102,7 +103,7 @@ export const getInventoryLotDetailsBySection = async (
url += `&stockTakeRoundId=${stockTakeRoundId}`; url += `&stockTakeRoundId=${stockTakeRoundId}`;
} }
console.log(' [API] Full URL:', url);
//console.log(' [API] Full URL:', url);
const response = await serverFetchJson<RecordsRes<InventoryLotDetailResponse>>( const response = await serverFetchJson<RecordsRes<InventoryLotDetailResponse>>(
url, url,
@@ -499,7 +500,8 @@ export interface BatchSaveApproverStockTakeAllRequest {
export interface BatchSaveApproverStockTakeByIdsRequest { export interface BatchSaveApproverStockTakeByIdsRequest {
stockTakeId: number; stockTakeId: number;
approverId: number; approverId: number;
recordIds: number[];
recordIds?: number[];
records?: SaveApproverStockTakeRecordRequest[];
} }
export const saveApproverStockTakeRecord = async ( export const saveApproverStockTakeRecord = async (
request: SaveApproverStockTakeRecordRequest, request: SaveApproverStockTakeRecordRequest,


Loading…
Cancel
Save