Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
parent
ffd6354e88
commit
bd42ff8a52
@ -168,8 +168,8 @@ export const listProductBatches = (productId: string) =>
|
||||
export const createProductBatch = (productId: string, batch: ProductBatchInput) =>
|
||||
request<ApiResponse<{ id: string }>>(`/api/v1/inventory/products/${productId}/batches`, { method: 'POST', data: { batch } });
|
||||
|
||||
export const updateProductBatch = (productId: string, batchId: string, batch: ProductBatchInput & { status?: number }) =>
|
||||
request<ApiResponse>(`/api/v1/inventory/products/${productId}/batches/${batchId}`, { method: 'PUT', data: { batch, status: batch.status ?? 1 } });
|
||||
export const updateProductBatch = (productId: string, batchId: string, batch: ProductBatchInput, status?: number) =>
|
||||
request<ApiResponse>(`/api/v1/inventory/products/${productId}/batches/${batchId}`, { method: 'PUT', data: status === undefined ? { batch } : { batch, status } });
|
||||
|
||||
export const deleteProductBatch = (productId: string, batchId: string) =>
|
||||
request<ApiResponse>(`/api/v1/inventory/products/${productId}/batches/${batchId}`, { method: 'DELETE' });
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user