@omniumretail/shared-resources 0.3.26 → 0.3.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { TransferPickProducts } from '../../../interfaces/TransferPickProducts';
|
|
2
|
+
export interface UpdateMacroStatusProps {
|
|
3
|
+
macroId: string;
|
|
4
|
+
status: string;
|
|
5
|
+
}
|
|
6
|
+
export declare const updateMacroStatusQueryHook: ({ macroId, status }: UpdateMacroStatusProps) => import("@tanstack/react-query").UseMutationResult<TransferPickProducts, unknown, void, unknown>;
|
|
@@ -157,6 +157,8 @@ export * from "./Astt/Asgt/mutate/deleteProductASTTQuery.hook";
|
|
|
157
157
|
export * from "./Astt/Asgt/mutate/postReprocessASTTQuery.hook";
|
|
158
158
|
export * from "./Astt/Asgt/get/getReprocessNeededASTTQuery.hook";
|
|
159
159
|
export * from "./Astt/Asgt/get/getAllAdidasProductsQuery.hook";
|
|
160
|
+
export * from "./Astt/Asgt/mutate/finishPackageASTTQuery.hook";
|
|
161
|
+
export * from "./Astt/Asgt/mutate/postMissingProductsASTTQuery.hook";
|
|
160
162
|
export * from "./Asgt/get/getTransferDocumentsASGTQuery.hook";
|
|
161
163
|
export * from "./Asgt/get/getTransferDocumentsByIdASGTQuery.hook";
|
|
162
164
|
export * from "./Asgt/get/getTransferDocumentsByPackageASGTQuery.hook";
|
|
@@ -334,6 +336,7 @@ export * from './Orch/get/getMacrosQuery.hook';
|
|
|
334
336
|
export * from './Orch/get/getInstanceByIdQuery.hook';
|
|
335
337
|
export * from './Orch/others/runMacrosQuery.hook';
|
|
336
338
|
export * from './Orch/others/reprocessingInstanceQuery.hook';
|
|
339
|
+
export * from './Orch/others/updateMacroStatusQuery.hook';
|
|
337
340
|
export * from './Orch/get/getMacrosUserQuery.hook';
|
|
338
341
|
export * from './Orch/get/getMonitoringComponents.hook';
|
|
339
342
|
export * from "./Watson/get/getCloseSession.hook";
|
package/package.json
CHANGED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { useMutation, useQueryClient } from '@tanstack/react-query';
|
|
2
|
+
import { TransferPickProducts } from '../../../interfaces/TransferPickProducts';
|
|
3
|
+
import { postAuth0 } from '../../../services/ApiService';
|
|
4
|
+
|
|
5
|
+
export interface UpdateMacroStatusProps {
|
|
6
|
+
macroId: string;
|
|
7
|
+
status: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export const updateMacroStatusQueryHook = ({ macroId, status }: UpdateMacroStatusProps) => {
|
|
11
|
+
const queryClient = useQueryClient();
|
|
12
|
+
return useMutation<TransferPickProducts, unknown>(() => {
|
|
13
|
+
return postAuth0(`/ORQ/Macros/UpdateStatus?`, {
|
|
14
|
+
pMacroId: macroId,
|
|
15
|
+
pStatus: status
|
|
16
|
+
});
|
|
17
|
+
}, {
|
|
18
|
+
onSuccess: (data) => {
|
|
19
|
+
queryClient.setQueryData(
|
|
20
|
+
['UPDATE_STATUS_QUERY'], data);
|
|
21
|
+
},
|
|
22
|
+
});
|
|
23
|
+
}
|
package/src/hooks/index.ts
CHANGED
|
@@ -182,6 +182,8 @@ export * from "./Astt/Asgt/mutate/deleteProductASTTQuery.hook";
|
|
|
182
182
|
export * from "./Astt/Asgt/mutate/postReprocessASTTQuery.hook";
|
|
183
183
|
export * from "./Astt/Asgt/get/getReprocessNeededASTTQuery.hook";
|
|
184
184
|
export * from "./Astt/Asgt/get/getAllAdidasProductsQuery.hook";
|
|
185
|
+
export * from "./Astt/Asgt/mutate/finishPackageASTTQuery.hook";
|
|
186
|
+
export * from "./Astt/Asgt/mutate/postMissingProductsASTTQuery.hook";
|
|
185
187
|
|
|
186
188
|
//Asgt
|
|
187
189
|
export * from "./Asgt/get/getTransferDocumentsASGTQuery.hook";
|
|
@@ -391,6 +393,7 @@ export * from './Orch/get/getMacrosQuery.hook';
|
|
|
391
393
|
export * from './Orch/get/getInstanceByIdQuery.hook';
|
|
392
394
|
export * from './Orch/others/runMacrosQuery.hook';
|
|
393
395
|
export * from './Orch/others/reprocessingInstanceQuery.hook';
|
|
396
|
+
export * from './Orch/others/updateMacroStatusQuery.hook';
|
|
394
397
|
export * from './Orch/get/getMacrosUserQuery.hook';
|
|
395
398
|
export * from './Orch/get/getMonitoringComponents.hook';
|
|
396
399
|
|