@omniumretail/shared-resources 0.2.57 → 0.2.59
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.
- package/dist/bundle.js +1 -1
- package/dist/types/hooks/Answer/others/postAnswersExportQuery.hook.d.ts +8 -0
- package/dist/types/hooks/Astt/get/getBarcodesPrintQuery.hook.d.ts +3 -0
- package/dist/types/hooks/index.d.ts +2 -0
- package/dist/types/interfaces/ReportBuilder.d.ts +1 -0
- package/package.json +1 -1
- package/src/hooks/Answer/others/postAnswersExportQuery.hook.ts +21 -0
- package/src/hooks/Astt/get/getBarcodesPrintQuery.hook.ts +12 -0
- package/src/hooks/index.ts +2 -0
- package/src/interfaces/ReportBuilder.ts +1 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { UseQueryOptions } from "@tanstack/react-query";
|
|
2
|
+
import { ReportBuilder } from "../../../interfaces";
|
|
3
|
+
export interface postAnswersExportQuery extends UseQueryOptions<ReportBuilder> {
|
|
4
|
+
evaluationId: string;
|
|
5
|
+
userId: string;
|
|
6
|
+
language?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const postAnswersExportQueryHook: ({ evaluationId, language, userId, ...options }: postAnswersExportQuery) => import("@tanstack/react-query").UseQueryResult<ReportBuilder, unknown>;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ReportBuilder } from '../../..';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare const getBarcodesPrintQuery: (transferId: string, { ...options }: UseQueryOptions<ReportBuilder>) => import("@tanstack/react-query").UseQueryResult<ReportBuilder, unknown>;
|
|
@@ -82,6 +82,7 @@ export * from "./Answer/mutate/useAnswerMutateQuery.hook";
|
|
|
82
82
|
export * from "./Answer/get/useAnswersUserSupervisorQuery.hook";
|
|
83
83
|
export * from "./Answer/others/openAnswerQuery.hook";
|
|
84
84
|
export * from "./Answer/others/showAnswerQuery.hook";
|
|
85
|
+
export * from "./Answer/others/postAnswersExportQuery.hook";
|
|
85
86
|
export * from "./AprProduct/get/useProductsQuery.hook";
|
|
86
87
|
export * from "./AprProduct/get/useProductHierarchies.hook";
|
|
87
88
|
export * from "./AprProduct/get/useProductRecommendations.hook";
|
|
@@ -120,6 +121,7 @@ export * from "./Astt/mutate/putTransferDocumentsStateMutateQuery.hook";
|
|
|
120
121
|
export * from "./Astt/get/getReportsBuilderQuery.hook";
|
|
121
122
|
export * from "./Astt/get/getRfidQuery.hook";
|
|
122
123
|
export * from "./Astt/get/getProductsListingQuery.hook";
|
|
124
|
+
export * from "./Astt/get/getBarcodesPrintQuery.hook";
|
|
123
125
|
export * from "./Asgt/get/getTransferDocumentsASGTQuery.hook";
|
|
124
126
|
export * from "./Asgt/get/getTransferDocumentsByIdASGTQuery.hook";
|
|
125
127
|
export * from "./Asgt/get/getTransferDocumentsByPackageASGTQuery.hook";
|
package/package.json
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { useQuery, UseQueryOptions } from "@tanstack/react-query";
|
|
2
|
+
import { ReportBuilder } from "../../../interfaces";
|
|
3
|
+
import { postAuth0 } from "../../../services/ApiService";
|
|
4
|
+
|
|
5
|
+
export interface postAnswersExportQuery extends UseQueryOptions<ReportBuilder> {
|
|
6
|
+
evaluationId: string;
|
|
7
|
+
userId: string;
|
|
8
|
+
language?: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export const postAnswersExportQueryHook = ({ evaluationId, language, userId, ...options }: postAnswersExportQuery) => {
|
|
12
|
+
return useQuery(
|
|
13
|
+
['POST_ANSWERS_EXPORT', evaluationId, language, userId, options],
|
|
14
|
+
() => postAuth0<ReportBuilder>('/APE/EvaluationCycle/AnswerExport?', {
|
|
15
|
+
pEvaluationCycleId: evaluationId,
|
|
16
|
+
pLanguage: language || "PT",
|
|
17
|
+
pUserId: userId
|
|
18
|
+
}),
|
|
19
|
+
options
|
|
20
|
+
);
|
|
21
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { getAuth0, ReportBuilder } from '../../..';
|
|
2
|
+
import { useQuery, UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
|
|
4
|
+
export const getBarcodesPrintQuery = (transferId: string, {...options} : UseQueryOptions<ReportBuilder>) => {
|
|
5
|
+
return useQuery(
|
|
6
|
+
['ASTT_BARCODES_PRINT', transferId, options],
|
|
7
|
+
() => getAuth0<ReportBuilder>(`/ASTT/ReportsBuilder/BarcodesPrinting`, {
|
|
8
|
+
pTransferDocumentId: transferId
|
|
9
|
+
}),
|
|
10
|
+
options
|
|
11
|
+
);
|
|
12
|
+
};
|
package/src/hooks/index.ts
CHANGED
|
@@ -93,6 +93,7 @@ export * from "./Answer/mutate/useAnswerMutateQuery.hook";
|
|
|
93
93
|
export * from "./Answer/get/useAnswersUserSupervisorQuery.hook";
|
|
94
94
|
export * from "./Answer/others/openAnswerQuery.hook";
|
|
95
95
|
export * from "./Answer/others/showAnswerQuery.hook";
|
|
96
|
+
export * from "./Answer/others/postAnswersExportQuery.hook";
|
|
96
97
|
|
|
97
98
|
//AprProducts
|
|
98
99
|
export * from "./AprProduct/get/useProductsQuery.hook";
|
|
@@ -143,6 +144,7 @@ export * from "./Astt/mutate/putTransferDocumentsStateMutateQuery.hook";
|
|
|
143
144
|
export * from "./Astt/get/getReportsBuilderQuery.hook";
|
|
144
145
|
export * from "./Astt/get/getRfidQuery.hook";
|
|
145
146
|
export * from "./Astt/get/getProductsListingQuery.hook";
|
|
147
|
+
export * from "./Astt/get/getBarcodesPrintQuery.hook";
|
|
146
148
|
|
|
147
149
|
//Asgt
|
|
148
150
|
export * from "./Asgt/get/getTransferDocumentsASGTQuery.hook";
|