@timardex/cluemart-shared 1.7.62 → 1.7.63

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.
@@ -7,7 +7,7 @@ import {
7
7
  SCHOOL_MIN_STUDENT_COUNT,
8
8
  isValidIrdNumber,
9
9
  normalizeUrl
10
- } from "../chunk-H4UY76FG.mjs";
10
+ } from "../chunk-76HG44I2.mjs";
11
11
  import {
12
12
  dateFormat,
13
13
  timeFormat
@@ -20,10 +20,10 @@ import {
20
20
  EnumAffiliateParticipantType,
21
21
  EnumPostContentType,
22
22
  EnumPostType
23
- } from "../chunk-O2TNYFUH.mjs";
23
+ } from "../chunk-YG7YTCX5.mjs";
24
24
  import "../chunk-RAYUJODN.mjs";
25
25
  import "../chunk-DQ7ZHIXW.mjs";
26
- import "../chunk-GK773FVL.mjs";
26
+ import "../chunk-63CHIBEP.mjs";
27
27
  import "../chunk-6ALUN6LP.mjs";
28
28
  import {
29
29
  EnumEventDateStatus,
package/dist/index.cjs CHANGED
@@ -443,6 +443,7 @@ __export(index_exports, {
443
443
  useRequestMarketingMaterial: () => useRequestMarketingMaterial,
444
444
  useRequestPasswordReset: () => useRequestPasswordReset,
445
445
  useResetPassword: () => useResetPassword,
446
+ useRewardCoupon: () => useRewardCoupon,
446
447
  useScanCoupon: () => useScanCoupon,
447
448
  useSearchEvents: () => useSearchEvents,
448
449
  useSearchPartners: () => useSearchPartners,
@@ -8682,6 +8683,14 @@ var SCAN_COUPON_MUTATION = import_client79.gql`
8682
8683
  }
8683
8684
  }
8684
8685
  `;
8686
+ var REWARD_COUPON_MUTATION = import_client79.gql`
8687
+ mutation rewardCoupon($input: ProductCouponInputType!, $userId: ID!) {
8688
+ rewardCoupon(input: $input, userId: $userId) {
8689
+ data
8690
+ message
8691
+ }
8692
+ }
8693
+ `;
8685
8694
 
8686
8695
  // src/graphql/hooks/coupon/hooksMutation.ts
8687
8696
  var useCreateCoupon = () => {
@@ -8712,6 +8721,13 @@ var useScanCoupon = () => {
8712
8721
  });
8713
8722
  return { error, loading, scanCoupon };
8714
8723
  };
8724
+ var useRewardCoupon = () => {
8725
+ const [rewardCoupon, { loading, error }] = (0, import_client80.useMutation)(REWARD_COUPON_MUTATION, {
8726
+ awaitRefetchQueries: true,
8727
+ refetchQueries: [{ query: GET_COUPONS }]
8728
+ });
8729
+ return { error, loading, rewardCoupon };
8730
+ };
8715
8731
 
8716
8732
  // src/graphql/hooks/coupon/hooksQuery.ts
8717
8733
  var import_client81 = require("@apollo/client");
@@ -9705,6 +9721,7 @@ function canAccessAdminPath(roles, pathname) {
9705
9721
  useRequestMarketingMaterial,
9706
9722
  useRequestPasswordReset,
9707
9723
  useResetPassword,
9724
+ useRewardCoupon,
9708
9725
  useScanCoupon,
9709
9726
  useSearchEvents,
9710
9727
  useSearchPartners,