@omniumretail/shared-resources 0.1.100 → 0.2.1
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/interfaces/Employee.d.ts +1 -0
- package/package.json +1 -1
- package/src/hooks/Asta/Actions/others/deleteActionQuery.hook.ts +2 -2
- package/src/hooks/Asta/AnswerType/others/deleteAnswerTypeQuery.hook.ts +2 -2
- package/src/hooks/Asta/Inspection/others/deleteInspectionQuery.hook.ts +2 -2
- package/src/hooks/Asta/Template/others/deleteTemplateQuery.hook.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UseQueryOptions, useMutation, useQueryClient } from '@tanstack/react-query';
|
|
2
2
|
import { Actions } from '../../../../interfaces';
|
|
3
|
-
import {
|
|
3
|
+
import { putAuth0 } from '../../../../services/ApiService';
|
|
4
4
|
|
|
5
5
|
export interface DeleteActionProps extends UseQueryOptions<Actions> {
|
|
6
6
|
actionsIds: string[];
|
|
@@ -9,7 +9,7 @@ export interface DeleteActionProps extends UseQueryOptions<Actions> {
|
|
|
9
9
|
export const deleteActionMutateHook = ({ actionsIds }: DeleteActionProps) => {
|
|
10
10
|
const queryClient = useQueryClient();
|
|
11
11
|
return useMutation<Actions, unknown, string[]>(() => {
|
|
12
|
-
return
|
|
12
|
+
return putAuth0(`/ASTA/Actions/DeleteActionList`, undefined, actionsIds)
|
|
13
13
|
}, {
|
|
14
14
|
onSuccess: () => {
|
|
15
15
|
queryClient.invalidateQueries(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UseQueryOptions, useMutation, useQueryClient } from '@tanstack/react-query';
|
|
2
2
|
import { AnswerType } from '../../../../interfaces';
|
|
3
|
-
import {
|
|
3
|
+
import { putAuth0 } from '../../../../services/ApiService';
|
|
4
4
|
|
|
5
5
|
export interface DeleteAnswerTypeProps extends UseQueryOptions<AnswerType> {
|
|
6
6
|
answerTypeIds: string[];
|
|
@@ -9,7 +9,7 @@ export interface DeleteAnswerTypeProps extends UseQueryOptions<AnswerType> {
|
|
|
9
9
|
export const deleteAnswerTypeHook = ({ answerTypeIds }: DeleteAnswerTypeProps) => {
|
|
10
10
|
const queryClient = useQueryClient();
|
|
11
11
|
return useMutation<AnswerType, unknown, string[]>(() => {
|
|
12
|
-
return
|
|
12
|
+
return putAuth0(`/ASTA/AnswerType/Delete`, undefined, answerTypeIds)
|
|
13
13
|
}, {
|
|
14
14
|
onSuccess: () => {
|
|
15
15
|
queryClient.invalidateQueries(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UseQueryOptions, useMutation, useQueryClient } from '@tanstack/react-query';
|
|
2
2
|
import { Inspection } from '../../../../interfaces';
|
|
3
|
-
import {
|
|
3
|
+
import { putAuth0 } from '../../../../services/ApiService';
|
|
4
4
|
|
|
5
5
|
export interface DeleteInspectionProps extends UseQueryOptions<Inspection> {
|
|
6
6
|
inspectionIds: string[];
|
|
@@ -9,7 +9,7 @@ export interface DeleteInspectionProps extends UseQueryOptions<Inspection> {
|
|
|
9
9
|
export const deleteInspectionMutateHook = ({ inspectionIds }: DeleteInspectionProps) => {
|
|
10
10
|
const queryClient = useQueryClient();
|
|
11
11
|
return useMutation<Inspection, unknown, string[]>(() => {
|
|
12
|
-
return
|
|
12
|
+
return putAuth0(`/ASTA/Inspection/DeleteInspectionList`, undefined, inspectionIds)
|
|
13
13
|
}, {
|
|
14
14
|
onSuccess: () => {
|
|
15
15
|
queryClient.invalidateQueries(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { UseQueryOptions, useMutation, useQueryClient } from '@tanstack/react-query';
|
|
2
2
|
import { Template } from '../../../../interfaces';
|
|
3
|
-
import {
|
|
3
|
+
import { putAuth0 } from '../../../../services/ApiService';
|
|
4
4
|
|
|
5
5
|
export interface DeleteTemplateProps extends UseQueryOptions<Template> {
|
|
6
6
|
templatesIds: string[];
|
|
@@ -9,7 +9,7 @@ export interface DeleteTemplateProps extends UseQueryOptions<Template> {
|
|
|
9
9
|
export const deleteTemplateMutateHook = ({ templatesIds }: DeleteTemplateProps) => {
|
|
10
10
|
const queryClient = useQueryClient();
|
|
11
11
|
return useMutation<Template, unknown, string[]>(() => {
|
|
12
|
-
return
|
|
12
|
+
return putAuth0(`/ASTA/Template/DeleteTemplateList`, undefined, templatesIds)
|
|
13
13
|
}, {
|
|
14
14
|
onSuccess: () => {
|
|
15
15
|
queryClient.invalidateQueries(
|