@omniumretail/shared-resources 0.1.34 → 0.1.36

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,8 @@
1
+ import { UseQueryOptions } from "@tanstack/react-query";
2
+ import { NotificationTitle, ResponseList } from "../../interfaces";
3
+ interface NotificationTitleQueryHookQueryProps extends Omit<UseQueryOptions<ResponseList<"NotificationTypes", NotificationTitle>>, "queryKey"> {
4
+ page?: number;
5
+ records?: number;
6
+ }
7
+ export declare const getNotificationTitleQueryHook: ({ page, records, ...options }: NotificationTitleQueryHookQueryProps) => import("@tanstack/react-query").UseQueryResult<ResponseList<"NotificationTypes", NotificationTitle>, unknown>;
8
+ export {};
@@ -54,3 +54,4 @@ export * from './Others/postCheckoutsMutateQuery.hook';
54
54
  export * from './Others/postVerifyUserQuery.hook';
55
55
  export * from './Others/postVerifyImageQuery.hook';
56
56
  export * from './Others/getWeeklyWorkloadQuery.hook';
57
+ export * from './Others/getNotificationTitleQuery.hook';
@@ -16,6 +16,7 @@ export interface EvaluationCycle {
16
16
  Status: string;
17
17
  Notifications: EvaluationNotifications[];
18
18
  NotificationAgenda: string;
19
+ NotificationId: string;
19
20
  TotalNumberOfUsers: number;
20
21
  TotalNumberOfAnswers: number;
21
22
  IsOnlyForUsers: boolean;
@@ -0,0 +1,7 @@
1
+ export interface NotificationTitle {
2
+ Id: string;
3
+ IsContentTypeHTML: boolean;
4
+ Subject: string;
5
+ Body: string;
6
+ Status: string;
7
+ }
@@ -28,3 +28,4 @@ export * from './VerifyUser';
28
28
  export * from './VerifyImage';
29
29
  export * from './Workload';
30
30
  export * from './AsvProductsStockDetails';
31
+ export * from './NotificationTitle';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omniumretail/shared-resources",
3
- "version": "0.1.34",
3
+ "version": "0.1.36",
4
4
  "private": false,
5
5
  "description": "Shared Components and services or utils to the frontend versions",
6
6
  "main": "dist/bundle.js",
@@ -0,0 +1,19 @@
1
+ import { useQuery, UseQueryOptions } from "@tanstack/react-query";
2
+ import { NotificationTitle, ResponseList } from "../../interfaces";
3
+ import { getAuth0 } from "../../services/ApiService";
4
+
5
+ interface NotificationTitleQueryHookQueryProps extends Omit<UseQueryOptions<ResponseList<"NotificationTypes", NotificationTitle>>, "queryKey"> {
6
+ page?: number;
7
+ records?: number;
8
+ }
9
+
10
+ export const getNotificationTitleQueryHook = ({ page, records, ...options }: NotificationTitleQueryHookQueryProps) => {
11
+ return useQuery(
12
+ ['NOTIFICATION_TITLE_QUERY', page, records],
13
+ () => getAuth0<ResponseList<"NotificationTypes", NotificationTitle>>('/APE/NotificationType', {
14
+ pPage: page || 1,
15
+ pRecords: records || 999999
16
+ }),
17
+ options
18
+ );
19
+ }
@@ -73,3 +73,4 @@ export * from './Others/postCheckoutsMutateQuery.hook';
73
73
  export * from './Others/postVerifyUserQuery.hook';
74
74
  export * from './Others/postVerifyImageQuery.hook';
75
75
  export * from './Others/getWeeklyWorkloadQuery.hook';
76
+ export * from './Others/getNotificationTitleQuery.hook';
@@ -14,6 +14,7 @@ export interface EvaluationCycle {
14
14
  Status: string;
15
15
  Notifications: EvaluationNotifications[];
16
16
  NotificationAgenda: string;
17
+ NotificationId: string;
17
18
  TotalNumberOfUsers: number;
18
19
  TotalNumberOfAnswers: number;
19
20
  IsOnlyForUsers: boolean;
@@ -0,0 +1,8 @@
1
+
2
+ export interface NotificationTitle {
3
+ Id: string;
4
+ IsContentTypeHTML: boolean;
5
+ Subject: string;
6
+ Body: string;
7
+ Status: string;
8
+ }
@@ -28,3 +28,4 @@ export * from './VerifyUser';
28
28
  export * from './VerifyImage';
29
29
  export * from './Workload';
30
30
  export * from './AsvProductsStockDetails';
31
+ export * from './NotificationTitle';