@feedmepos/mf-connect 0.1.98-beta.2 → 0.1.98-beta.21

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.
Files changed (108) hide show
  1. package/dist/{App-BWBeJksP.js → App-B3f8GWoR.js} +794 -654
  2. package/dist/{AuditLogs-CWVUX5o0.js → AuditLogs-LRHzzpqj.js} +9 -9
  3. package/dist/{Bin-jXmZpGfg.js → Bin-Y761Ua4-.js} +8 -8
  4. package/dist/{Broadcast-C76pTADb.js → Broadcast-CdRuG42N.js} +38 -36
  5. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-9kfq8OXE.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CsULDH9l.js} +5 -5
  6. package/dist/{Card-qXn83BYu.js → Card-GZ3ZLnBl.js} +18 -18
  7. package/dist/{Collections-DGXUQSbz.js → Collections-B59fL-oS.js} +7 -7
  8. package/dist/{Credit-CpmrPZx9.js → Credit-DJxzXBam.js} +48 -48
  9. package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-DAnw5TFZ.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-C3d8frgZ.js} +30 -30
  10. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-BCAotF0P.js → EffectSheet.vue_vue_type_style_index_0_lang-DKUFvacX.js} +6 -6
  11. package/dist/{Experience-CuOq7hd3.js → Experience-lzpvYFPP.js} +9 -9
  12. package/dist/{FileSaver.min-Cjv6SzrG.js → FileSaver.min-BXoEv5ve.js} +1 -1
  13. package/dist/{Game-D0KfLD-b.js → Game-KCxIpXEC.js} +10 -10
  14. package/dist/{Grab-L1h7bHD7.js → Grab-BQgS104D.js} +8 -8
  15. package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-DMAaHxzm.js → ImageInput.vue_vue_type_script_setup_true_lang-Cz9iB9ox.js} +1 -1
  16. package/dist/{Index-DxwMHEV3.js → Index-B5UTBbUy.js} +10 -10
  17. package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-i9-B25xO.js → LocationPicker.vue_vue_type_script_setup_true_lang-CLLhy4-v.js} +1 -1
  18. package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-D84v7zC_.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BiIqs4zW.js} +1 -1
  19. package/dist/{LoyaltyDashboard-B5wg1EUC.js → LoyaltyDashboard-DPHWpaNJ.js} +4 -4
  20. package/dist/{MainLayout-Cgi3Z3EM.js → MainLayout-AvQ4_-oT.js} +1 -1
  21. package/dist/{Marketing-Cl5OSBI1.js → Marketing-Bn1ygF8d.js} +4 -4
  22. package/dist/{MarketingMaterialEdit-CzYTbdJd.js → MarketingMaterialEdit-Cw-VPVqE.js} +6 -6
  23. package/dist/{Member-D29x5Cic.js → Member-CpEXFHIF.js} +11 -11
  24. package/dist/{MemberList-DDPe6Ymr.js → MemberList-gSEw_idJ.js} +25 -25
  25. package/dist/{MemberTransactions-3mboVWAx.js → MemberTransactions-DEMzj9-y.js} +1 -1
  26. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-C2HlA9O8.js → MessageInput.vue_vue_type_script_setup_true_lang-B4Y5KPpw.js} +5737 -5552
  27. package/dist/{Mission-CMPc4NLe.js → Mission-DMtpauNQ.js} +10 -10
  28. package/dist/Overview-CMudFYOc.js +969 -0
  29. package/dist/{Overview-sJ2kuP4U.js → Overview-DjNcF88f.js} +18 -18
  30. package/dist/{Point-BBP4UEhf.js → Point-CgdTrgXc.js} +9 -9
  31. package/dist/{Promotion-Bt0RLGsd.js → Promotion-DDQodFDb.js} +10 -10
  32. package/dist/{Queue-CzVsoIDM.js → Queue-BjoAJoVe.js} +14 -14
  33. package/dist/{Record-CAoGgaxo.js → Record-CfZFuwy_.js} +9 -9
  34. package/dist/Review-pIAxbjVU.js +45 -0
  35. package/dist/ReviewFacebookCallback-BRW4T-5-.js +238 -0
  36. package/dist/ReviewGoogleCallback-B-6EojXR.js +213 -0
  37. package/dist/{Reward-CrpFlr0a.js → Reward-_pdE2XZp.js} +16 -16
  38. package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-DW-WFNI6.js → RewardGroup.vue_vue_type_script_setup_true_lang-S5dh0IGc.js} +11 -11
  39. package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-DlcsO8fk.js → RuleGroup.vue_vue_type_script_setup_true_lang-C9B7NmF0.js} +13 -13
  40. package/dist/{Segment-Cy-QwYQQ.js → Segment-B1EMe-LZ.js} +23 -23
  41. package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-ovvxxcrQ.js → SelectItems.vue_vue_type_script_setup_true_lang-DAmjk8b3.js} +2 -2
  42. package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-D69bJtyd.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-C7sgPf8l.js} +12 -12
  43. package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-DQyoPZ_6.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-DVYTZr_E.js} +4 -4
  44. package/dist/{Setting-DEQIJ4fY.js → Setting-CQQ6zacB.js} +14 -14
  45. package/dist/{SettingAdvertisements-NuwjCPLN.js → SettingAdvertisements-9Wl9VWbM.js} +12 -12
  46. package/dist/Settings-Bvj2ChDR.js +228 -0
  47. package/dist/{Store-Cw2J_ecA.js → Store-BdUZ22g6.js} +21 -21
  48. package/dist/{StoreRewards-BK5rDAaK.js → StoreRewards-DsUS_Lu1.js} +15 -15
  49. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-B3jwaYHX.js → StoreTransactions.vue_vue_type_script_setup_true_lang-Zw-lIDCN.js} +190 -187
  50. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-D_OdWctk.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BECp3eqQ.js} +2 -2
  51. package/dist/{Tier-CwZ40RYc.js → Tier-2-mJ3SNK.js} +22 -22
  52. package/dist/{Title-DU7KmsK2.js → Title-BjeEDjxl.js} +19 -19
  53. package/dist/{Transaction-Uh5Ozt93.js → Transaction--U_kJKec.js} +2 -2
  54. package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-BtnUNkcS.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-BkLyvjA5.js} +6 -6
  55. package/dist/{Voucher-BF6ARaRe.js → Voucher-INa3N_6V.js} +13 -13
  56. package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-C7msPJdi.js → VoucherEditor.vue_vue_type_script_setup_true_lang-4Quzmc7-.js} +12 -12
  57. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-BrR2WA1K.js → ZodTextField.vue_vue_type_script_setup_true_lang-CPCnBExY.js} +2 -2
  58. package/dist/{app-DlECkPwT.js → app-Dlqr-LX4.js} +1551 -1223
  59. package/dist/app.js +1 -1
  60. package/dist/{business-BSe9C-xG.js → business-DWrfGEe_.js} +1 -1
  61. package/dist/{campaign-BNS2RxKc.js → campaign-DtNt-BqN.js} +10 -10
  62. package/dist/{campaign-CXw3jpdr.js → campaign-un9Ji1KF.js} +1 -1
  63. package/dist/{campaign.enum-CnMa2Tia.js → campaign.enum-B9-ZpK0C.js} +1 -1
  64. package/dist/{campaign.fn-CNOinW8t.js → campaign.fn-COxaWmi_.js} +93 -93
  65. package/dist/{collectible.enum-BIvEz79q.js → collectible.enum-CF0VF-r7.js} +1 -1
  66. package/dist/{duplicateCampaign-Co2TdbrL.js → duplicateCampaign-8ciT68QF.js} +2 -2
  67. package/dist/{effect-Bt8PE3-M.js → effect-CaSn-84h.js} +1 -1
  68. package/dist/{email-addresses-Dh95ALqP.js → email-addresses-BiMQ8xIx.js} +2 -2
  69. package/dist/{export-DIIgAwP7.js → export-BwBNgCo5.js} +3 -3
  70. package/dist/google-BQK68wbe.js +5 -0
  71. package/dist/{helper-8zEdQ9jm.js → helper-CajV_0CM.js} +1 -1
  72. package/dist/{index-BP5qSDQw.js → index-B0ohh62P.js} +216 -194
  73. package/dist/{index-VS1hWlhk.js → index-B6ldAC8Y.js} +1 -1
  74. package/dist/{index-rwlkBKrS.js → index-B6tm_U_M.js} +3 -3
  75. package/dist/{index-Bqxe3Gbq.js → index-BP5rdioN.js} +3 -3
  76. package/dist/{index-ZKJoXi1-.js → index-Bqcfsd4p.js} +3 -3
  77. package/dist/{index-DDp0nMys.js → index-CQIciFrH.js} +1 -1
  78. package/dist/{index-DdCPfF8x.js → index-CQj9BQlQ.js} +2 -2
  79. package/dist/{index-BAlFstx4.js → index-CjW6Mj-1.js} +1 -1
  80. package/dist/{index-SsUBL4IR.js → index-D1--K-QL.js} +1 -1
  81. package/dist/{index-CfxDirFl.js → index-D1vhLY7l.js} +1 -1
  82. package/dist/{index-CWypTyOP.js → index-D90p28Hr.js} +31 -37
  83. package/dist/{index-0BNEvaYc.js → index-DBUTFa2h.js} +2 -2
  84. package/dist/{index-DW4-mTTG.js → index-DWBKko92.js} +26 -17
  85. package/dist/{index-IPOrNVQw.js → index-J8pSZ3WO.js} +1 -1
  86. package/dist/{index.esm2017-CgR02aQB.js → index.esm2017-QlPanYiW.js} +105 -105
  87. package/dist/{loading-CxY9qhzD.js → loading-CqqkzWSm.js} +1 -1
  88. package/dist/{lodash-CELsN1M_.js → lodash-DmbW2QhA.js} +1 -1
  89. package/dist/{membership-BoQMuerb.js → membership-Dcwyu-rr.js} +3 -3
  90. package/dist/{money-CH913hGN.js → money-DWr1gi--.js} +1 -1
  91. package/dist/{number-CO-WbLdr.js → number-CHhHAd1q.js} +1 -1
  92. package/dist/objectid-BsiuHVH8.js +145 -0
  93. package/dist/{plugins-YK45gSb1.js → plugins-BxmMI8fo.js} +3 -3
  94. package/dist/{reward-3aFPahH6.js → reward-DX0FjsNT.js} +1 -1
  95. package/dist/{rule-DC9my0Vg.js → rule-DDLcqiHH.js} +3 -3
  96. package/dist/{template-tDq12e1p.js → template-C0lF82yv.js} +6 -6
  97. package/dist/{trigger-DoPHRgKt.js → trigger-CsJcg_RY.js} +5 -5
  98. package/dist/{useMarketingMaterialActions-CEd6ODsz.js → useMarketingMaterialActions-B0iV6YzB.js} +3 -3
  99. package/dist/{usePagination-C8FUj5q_.js → usePagination-4EISkyGW.js} +1 -1
  100. package/dist/{user-Dhlhrnf8.js → user-DZuSeqRY.js} +1 -1
  101. package/dist/{vue-i18n-B-92uhPn.js → vue-i18n-BKcwYlp1.js} +252 -252
  102. package/dist/{xlsx-Dmxne1eM.js → xlsx-C-7dia55.js} +1 -1
  103. package/dist/{zod-Dcdy9Dm3.js → zod-DPxXVSRw.js} +1 -1
  104. package/package.json +3 -3
  105. package/dist/Review-CVBJlwGK.js +0 -959
  106. package/dist/ReviewFacebookCallback-RGWdxXYf.js +0 -243
  107. package/dist/ReviewGoogleCallback-L7_Jjbkx.js +0 -208
  108. package/dist/objectid-BM2Ygj-U.js +0 -145
@@ -1,38 +1,38 @@
1
- import { z as e, F as n, m, a as L } from "./index-Bqxe3Gbq.js";
2
- import { B as x, C as D, E as w, G as A, H as g, I as T, J as G } from "./index-CWypTyOP.js";
3
- import { _ as M, l as H, a as F } from "./index-rwlkBKrS.js";
4
- import { i as p } from "./helper-8zEdQ9jm.js";
5
- import { a as f } from "./index-ZKJoXi1-.js";
6
- function _(o, a) {
1
+ import { z as e, F as n, m, a as R } from "./index-BP5rdioN.js";
2
+ import { B as L, C as x, E as D, G as w, H as g } from "./index-D90p28Hr.js";
3
+ import { _ as A, l as C, a as G } from "./index-B6tm_U_M.js";
4
+ import { i as p } from "./helper-CajV_0CM.js";
5
+ import { a as H } from "./index-Bqcfsd4p.js";
6
+ function f(o, a) {
7
7
  let i = "", r = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
8
8
  const l = r.length;
9
9
  for (let c = 0; c < o; c++)
10
10
  i += r.charAt(Math.floor(Math.random() * l));
11
11
  return i;
12
12
  }
13
- function y(o) {
13
+ function b(o) {
14
14
  return !o.property && "rules" in o;
15
15
  }
16
- function k(o) {
16
+ function M(o) {
17
17
  return "property" in o && !!o.property;
18
18
  }
19
- const B = "g_schedule";
20
- function V(o) {
19
+ const F = "g_schedule";
20
+ function k(o) {
21
21
  return o.split(/\r?\n/).filter((a) => !a.trim().toUpperCase().startsWith("DTSTART")).join(`
22
22
  `).trim();
23
23
  }
24
- function Y(o, a = !1) {
25
- const i = M.cloneDeep(o);
26
- if (k(i)) {
24
+ function B(o, a = !1) {
25
+ const i = A.cloneDeep(o);
26
+ if (M(i)) {
27
27
  const r = i.conditions;
28
- return !a && r && typeof r._rrule == "string" && (r._rrule = V(
28
+ return !a && r && typeof r._rrule == "string" && (r._rrule = k(
29
29
  r._rrule
30
30
  )), i;
31
31
  }
32
- if (y(i))
32
+ if (b(i))
33
33
  for (const r in i.rules) {
34
- const l = i.rules[r], c = a || y(l) && l.name === B;
35
- i.rules[r] = Y(
34
+ const l = i.rules[r], c = a || b(l) && l.name === F;
35
+ i.rules[r] = B(
36
36
  l,
37
37
  c
38
38
  );
@@ -42,14 +42,14 @@ function Y(o, a = !1) {
42
42
  class t {
43
43
  static scaffoldGroup(a) {
44
44
  return {
45
- name: a ?? `g_${_(4)}`,
45
+ name: a ?? `g_${f(4)}`,
46
46
  rules: {},
47
47
  logic: ""
48
48
  };
49
49
  }
50
50
  static scaffoldEntry(a) {
51
51
  return {
52
- name: `r_${_(4)}`,
52
+ name: `r_${f(4)}`,
53
53
  property: a ?? "",
54
54
  conditions: {},
55
55
  negated: !1
@@ -57,7 +57,7 @@ class t {
57
57
  }
58
58
  static constructEntry(a, i, r, l) {
59
59
  return {
60
- name: l ?? `e_${_(4)}`,
60
+ name: l ?? `e_${f(4)}`,
61
61
  property: a,
62
62
  conditions: {
63
63
  [i]: r
@@ -70,16 +70,16 @@ class t {
70
70
  }
71
71
  static constructLogic(a, i) {
72
72
  const r = i ?? t.getLogic(a);
73
- return Object.entries(a.rules).map(([l, c]) => y(c) ? l : `${c.negated ? "!" : ""}${l}`).join(` ${r} `);
73
+ return Object.entries(a.rules).map(([l, c]) => b(c) ? l : `${c.negated ? "!" : ""}${l}`).join(` ${r} `);
74
74
  }
75
75
  static setRuleToGroup(a, i, r) {
76
- let l = H.cloneDeep(a);
76
+ let l = C.cloneDeep(a);
77
77
  return Object.keys(l.rules).length === 0 && (l = t.scaffoldGroup(l.name)), Array.isArray(i) ? i.forEach((c) => {
78
78
  l.rules[c.name] = c;
79
79
  }) : l.rules[i.name] = i, l.logic = t.constructLogic(l, r), l;
80
80
  }
81
81
  static removeEntry(a, i, r) {
82
- const l = H.cloneDeep(a);
82
+ const l = C.cloneDeep(a);
83
83
  return delete l.rules[i], l.logic = t.constructLogic(l, r), l;
84
84
  }
85
85
  static constructRule(a) {
@@ -111,18 +111,18 @@ class t {
111
111
  static isRuleExceed(a, i) {
112
112
  const l = Object.keys(a.rules).length + (Array.isArray(i) ? i.length : 1);
113
113
  if (l > 10)
114
- throw new K(10, l);
114
+ throw new V(10, l);
115
115
  return !0;
116
116
  }
117
117
  }
118
- class K extends Error {
118
+ class V extends Error {
119
119
  constructor(a, i) {
120
120
  super(
121
121
  `Maximum of ${a} rules allowed per group. Attempted to add ${i} rules.`
122
122
  ), this.name = "MaxRulesExceededError";
123
123
  }
124
124
  }
125
- const W = {
125
+ const Y = {
126
126
  collectionName: "AuditLogs",
127
127
  transform: {
128
128
  _id: "oid",
@@ -135,7 +135,7 @@ const W = {
135
135
  fromCollection: "Businesses"
136
136
  }
137
137
  }
138
- }, X = e.enum([
138
+ }, K = e.enum([
139
139
  "GET",
140
140
  "POST",
141
141
  "PUT",
@@ -144,7 +144,7 @@ const W = {
144
144
  "OPTIONS",
145
145
  "HEAD",
146
146
  "ALL"
147
- ]), q = e.enum([
147
+ ]), W = e.enum([
148
148
  "CAMPAIGN",
149
149
  "LOCATION",
150
150
  "MARKETING MATERIALS",
@@ -154,15 +154,15 @@ const W = {
154
154
  "SETTINGS",
155
155
  "SEGMENTATION",
156
156
  "USER"
157
- ]), Q = e.object({
158
- httpMethod: X,
157
+ ]), X = e.object({
158
+ httpMethod: K,
159
159
  url: e.string().min(1),
160
160
  userAgent: e.string(),
161
161
  host: e.string().min(1),
162
162
  params: e.object({}).passthrough().nullish(),
163
163
  query: e.object({}).passthrough().nullish(),
164
164
  body: e.object({}).passthrough().nullish()
165
- }), $ = e.object({
165
+ }), q = e.object({
166
166
  statusCode: e.number().int().min(100).max(599),
167
167
  body: e.object({}).passthrough().nullish()
168
168
  });
@@ -170,14 +170,14 @@ e.object({
170
170
  _id: n,
171
171
  user: e.string().length(28),
172
172
  userName: e.string().min(1),
173
- userPhoneNumber: e.string().refine((o) => x(o)).nullish(),
174
- moduleType: q,
173
+ userPhoneNumber: e.string().refine((o) => L(o)).nullish(),
174
+ moduleType: W,
175
175
  business: n.nullish(),
176
176
  clientIp: e.string().nullish(),
177
177
  timestamp: e.string().datetime(),
178
- request: Q,
179
- response: $
180
- }).describe(m.describe(W));
178
+ request: X,
179
+ response: q
180
+ }).describe(m.describe(Y));
181
181
  const We = {
182
182
  PROMOTION: {
183
183
  name: "Promotion Template",
@@ -2117,7 +2117,7 @@ t.setRuleToGroup(t.scaffoldGroup(), [
2117
2117
  ({
2118
2118
  ...t.scaffoldGroup()
2119
2119
  });
2120
- const Z = e.enum([
2120
+ const Q = e.enum([
2121
2121
  "MEMBER_REWARD",
2122
2122
  "PAID_LOYALTY",
2123
2123
  "COLLECT_FEEDBACK",
@@ -2127,7 +2127,7 @@ const Z = e.enum([
2127
2127
  "BROADCAST",
2128
2128
  "BIRTHDAY",
2129
2129
  "GAME"
2130
- ]), ee = e.enum([
2130
+ ]), $ = e.enum([
2131
2131
  "text",
2132
2132
  "number",
2133
2133
  "textarea",
@@ -2157,28 +2157,28 @@ const Z = e.enum([
2157
2157
  "grab_effect",
2158
2158
  "grab_quota",
2159
2159
  "grab_conditions"
2160
- ]), te = e.object({
2160
+ ]), Z = e.object({
2161
2161
  label: e.string().optional(),
2162
2162
  label_locale: e.record(e.string()).nullish(),
2163
2163
  property: e.string().or(e.any()),
2164
- type: ee,
2164
+ type: $,
2165
2165
  extras: e.string().optional(),
2166
2166
  isRuleChildren: e.boolean().optional()
2167
- }), z = e.object({
2167
+ }), T = e.object({
2168
2168
  not: e.boolean().optional(),
2169
2169
  property: e.string(),
2170
2170
  value: e.any()
2171
- }), ae = e.object({
2171
+ }), ee = e.object({
2172
2172
  name: e.string().optional(),
2173
2173
  name_locale: e.record(e.string()).nullish(),
2174
- fields: e.array(te),
2175
- condition: z.optional().or(
2176
- e.array(z)
2174
+ fields: e.array(Z),
2175
+ condition: T.optional().or(
2176
+ e.array(T)
2177
2177
  )
2178
- }), ne = e.object({
2178
+ }), te = e.object({
2179
2179
  name: e.string(),
2180
2180
  name_locale: e.record(e.string()).nullish(),
2181
- groups: e.array(ae)
2181
+ groups: e.array(ee)
2182
2182
  });
2183
2183
  e.object({
2184
2184
  _id: n,
@@ -2186,11 +2186,11 @@ e.object({
2186
2186
  name_locale: e.record(e.string()).nullish(),
2187
2187
  description: e.string().nullish(),
2188
2188
  description_locale: e.record(e.string()).nullish(),
2189
- steps: e.array(ne).min(1),
2190
- intention: e.array(Z),
2189
+ steps: e.array(te).min(1),
2190
+ intention: e.array(Q),
2191
2191
  defaultValue: e.any()
2192
2192
  }).describe(JSON.stringify({ collectionName: "MarketingTemplates" }));
2193
- const oe = {
2193
+ const ae = {
2194
2194
  collectionName: "Businesses",
2195
2195
  transform: {
2196
2196
  _id: "oid"
@@ -2202,27 +2202,27 @@ e.object({
2202
2202
  name: e.string(),
2203
2203
  credit: e.number(),
2204
2204
  forceSend: e.boolean().optional()
2205
- }).describe(m.describe(oe));
2206
- const v = e.enum(["PHONE"]), ie = e.enum([
2205
+ }).describe(m.describe(ae));
2206
+ const S = e.enum(["PHONE"]), ne = e.enum([
2207
2207
  "MOCEAN",
2208
2208
  "SLACK",
2209
2209
  "SMS",
2210
2210
  "EMAIL",
2211
2211
  "WHATSAPP"
2212
- ]), le = e.enum(["PENDING", "COMPLETED", "FAILED"]), re = e.enum([
2212
+ ]), oe = e.enum(["PENDING", "COMPLETED", "FAILED"]), ie = e.enum([
2213
2213
  "General",
2214
2214
  "Otp",
2215
2215
  "Marketing",
2216
2216
  "Ordering",
2217
2217
  "MemberInvitation",
2218
2218
  "MarketingPromotion"
2219
- ]), ce = e.object({
2220
- type: v
2221
- }), S = ce.extend({
2222
- type: e.literal(v.enum.PHONE),
2223
- provider: ie,
2224
- usage: re.optional()
2225
- }), pe = {
2219
+ ]), le = e.object({
2220
+ type: S
2221
+ }), N = le.extend({
2222
+ type: e.literal(S.enum.PHONE),
2223
+ provider: ne,
2224
+ usage: ie.optional()
2225
+ }), re = {
2226
2226
  collectionName: "Notifications",
2227
2227
  transform: { _id: "oid", business: "oid" }
2228
2228
  };
@@ -2232,39 +2232,39 @@ e.object({
2232
2232
  target: e.string(),
2233
2233
  title: e.string().optional(),
2234
2234
  message: e.string(),
2235
- option: S,
2236
- status: le,
2235
+ option: N,
2236
+ status: oe,
2237
2237
  ref: e.string().optional()
2238
- }).describe(m.describe(pe));
2239
- const me = e.object({
2238
+ }).describe(m.describe(re));
2239
+ const ce = e.object({
2240
2240
  target: e.string(),
2241
2241
  title: e.string().optional(),
2242
2242
  message: e.string(),
2243
- option: S,
2243
+ option: N,
2244
2244
  ref: e.string().optional()
2245
2245
  });
2246
2246
  e.object({
2247
2247
  campaignId: e.string(),
2248
- notification: me,
2248
+ notification: ce,
2249
2249
  business: e.string()
2250
2250
  });
2251
2251
  e.object({
2252
2252
  phone: e.string(),
2253
2253
  message: e.string()
2254
2254
  });
2255
- const C = e.object({
2255
+ const v = e.object({
2256
2256
  name: e.string().optional(),
2257
2257
  address: e.string()
2258
- }), se = e.object({
2258
+ }), pe = e.object({
2259
2259
  filename: e.string(),
2260
2260
  content: e.instanceof(Uint8Array)
2261
2261
  });
2262
2262
  e.object({
2263
- from: C.optional(),
2264
- to: e.array(C),
2263
+ from: v.optional(),
2264
+ to: e.array(v),
2265
2265
  subject: e.string(),
2266
2266
  html: e.string().optional(),
2267
- attachments: e.array(se).optional()
2267
+ attachments: e.array(pe).optional()
2268
2268
  });
2269
2269
  e.object({
2270
2270
  subject: e.string(),
@@ -2304,7 +2304,7 @@ e.object({
2304
2304
  billId: e.string()
2305
2305
  });
2306
2306
  e.object({
2307
- amount: L,
2307
+ amount: R,
2308
2308
  member: e.string(),
2309
2309
  bill: e.string(),
2310
2310
  otp: e.string().nullish(),
@@ -2313,15 +2313,15 @@ e.object({
2313
2313
  e.object({
2314
2314
  orderId: e.string()
2315
2315
  });
2316
- var N = /* @__PURE__ */ ((o) => (o[o.feedMe = 0] = "feedMe", o[o.business = 1] = "business", o[o.restaurant = 2] = "restaurant", o))(N || {});
2317
- e.nativeEnum(N);
2316
+ var U = /* @__PURE__ */ ((o) => (o[o.feedMe = 0] = "feedMe", o[o.business = 1] = "business", o[o.restaurant = 2] = "restaurant", o))(U || {});
2317
+ e.nativeEnum(U);
2318
2318
  e.enum(["manage", "create", "read", "update", "delete"]);
2319
2319
  e.enum(["all", "restaurant", "business", "delivery", "agent"]);
2320
2320
  e.enum(["quota"]);
2321
- var U = /* @__PURE__ */ ((o) => (o.marketing = "business::marketing", o.campaign = "business::campaign", o.counter = "business::counter", o.permission = "business::permission", o.role = "business::role", o))(U || {});
2322
- e.nativeEnum(U);
2321
+ var P = /* @__PURE__ */ ((o) => (o.marketing = "business::marketing", o.campaign = "business::campaign", o.counter = "business::counter", o.permission = "business::permission", o.role = "business::role", o))(P || {});
2322
+ e.nativeEnum(P);
2323
2323
  e.enum(["restaurant"]);
2324
- const ge = e.object({
2324
+ const me = e.object({
2325
2325
  label: e.string(),
2326
2326
  subject: e.union([e.string(), e.array(e.string())]),
2327
2327
  actions: e.union([e.string(), e.array(e.string())]),
@@ -2336,7 +2336,7 @@ e.object({
2336
2336
  userId: e.string(),
2337
2337
  email: e.string().nullish(),
2338
2338
  phoneNo: e.string().nullish(),
2339
- permissions: e.array(e.lazy(() => ge))
2339
+ permissions: e.array(e.lazy(() => me))
2340
2340
  }).describe(
2341
2341
  m.describe({
2342
2342
  collectionName: "PermissionUsers",
@@ -2345,27 +2345,27 @@ e.object({
2345
2345
  }
2346
2346
  })
2347
2347
  );
2348
- const P = e.object({
2348
+ const j = e.object({
2349
2349
  userId: e.string(),
2350
2350
  level: e.number(),
2351
2351
  role: e.string().optional(),
2352
2352
  businessId: e.string().optional(),
2353
2353
  restaurantId: e.string().optional()
2354
- }), de = e.function().args(e.any(), P).returns(e.boolean()), ue = e.function().args(P).returns(e.promise(e.array(e.any())));
2354
+ }), se = e.function().args(e.any(), j).returns(e.boolean()), ge = e.function().args(j).returns(e.promise(e.array(e.any())));
2355
2355
  e.object({
2356
- isAdmin: de,
2357
- getRules: ue
2356
+ isAdmin: se,
2357
+ getRules: ge
2358
2358
  });
2359
2359
  e.object({
2360
- transactions: e.array(D),
2361
- collections: e.array(w)
2360
+ transactions: e.array(x),
2361
+ collections: e.array(D)
2362
2362
  });
2363
- const j = e.enum([
2363
+ const J = e.enum([
2364
2364
  "ROCK_PAPER_SCISSOR"
2365
2365
  ]);
2366
- j.enum.ROCK_PAPER_SCISSOR + "";
2366
+ J.enum.ROCK_PAPER_SCISSOR + "";
2367
2367
  e.object({
2368
- type: j
2368
+ type: J
2369
2369
  });
2370
2370
  e.object({
2371
2371
  host: e.string().url(),
@@ -2374,7 +2374,7 @@ e.object({
2374
2374
  roomId: e.string()
2375
2375
  });
2376
2376
  e.enum(["FACEBOOK", "INSTAGRAM", "TV", "BRAND_APP"]);
2377
- const he = {
2377
+ const de = {
2378
2378
  collectionName: "MarketingMaterials",
2379
2379
  transform: {
2380
2380
  _id: "oid",
@@ -2388,7 +2388,7 @@ e.object({
2388
2388
  headline: e.string(),
2389
2389
  caption: e.string(),
2390
2390
  editedAt: e.coerce.date()
2391
- }).describe(m.describe(he));
2391
+ }).describe(m.describe(de));
2392
2392
  e.object({
2393
2393
  id: e.number(),
2394
2394
  name: e.string(),
@@ -2408,12 +2408,12 @@ e.object({
2408
2408
  phone: e.string().optional(),
2409
2409
  email: e.string().optional()
2410
2410
  });
2411
- const _e = e.enum([
2411
+ const ue = e.enum([
2412
2412
  "PENDING",
2413
2413
  "SUCCESS",
2414
2414
  "FAILED",
2415
2415
  "RETRYING"
2416
- ]), ye = {
2416
+ ]), he = {
2417
2417
  collectionName: "WebhookLogs",
2418
2418
  transform: {
2419
2419
  _id: "oid",
@@ -2425,18 +2425,18 @@ e.object({
2425
2425
  business: n,
2426
2426
  type: e.string(),
2427
2427
  payload: e.record(e.any()),
2428
- status: _e,
2428
+ status: ue,
2429
2429
  response: e.any().optional(),
2430
2430
  error: e.string().optional()
2431
- }).describe(m.describe(ye));
2432
- const fe = e.enum(["AUTO", "MANUAL"]);
2431
+ }).describe(m.describe(he));
2432
+ const _e = e.enum(["AUTO", "MANUAL"]);
2433
2433
  e.enum(["IN_PROGRESS", "COMPLETED"]);
2434
- const J = e.object({
2434
+ const E = e.object({
2435
2435
  _id: n,
2436
2436
  name: e.string().min(1, "Name is required").max(50),
2437
- type: fe,
2438
- event: A.optional()
2439
- }), be = e.object({
2437
+ type: _e,
2438
+ event: w.optional()
2439
+ }), ye = e.object({
2440
2440
  from: e.number().int("Must be integer").min(1, "Min referral count need to start from 1"),
2441
2441
  to: e.number().int("Must be integer").nullish()
2442
2442
  }).superRefine((o, a) => {
@@ -2444,16 +2444,16 @@ const J = e.object({
2444
2444
  code: "custom",
2445
2445
  message: "Max referral count must be more than min referral count"
2446
2446
  });
2447
- }), He = e.object({
2448
- threshold: be,
2447
+ }), fe = e.object({
2448
+ threshold: ye,
2449
2449
  rewards: e.array(n),
2450
- pf_reward: e.array(f).optional()
2451
- }), b = e.object({
2450
+ pf_reward: e.array(H).optional()
2451
+ }), z = e.object({
2452
2452
  id: e.string(),
2453
2453
  name: e.string().min(1, "Name is required").max(50, "Name must be less than 50 characters"),
2454
- rule: F.optional(),
2455
- rewards: e.array(He)
2456
- }), ze = {
2454
+ rule: G.optional(),
2455
+ rewards: e.array(fe)
2456
+ }), be = {
2457
2457
  collectionName: "ReferralRecords",
2458
2458
  transform: {
2459
2459
  _id: "oid",
@@ -2462,25 +2462,25 @@ const J = e.object({
2462
2462
  referee: "oid",
2463
2463
  refereeReward: "oid"
2464
2464
  }
2465
- }, Ce = e.object({
2465
+ }, He = e.object({
2466
2466
  completedAt: e.coerce.date(),
2467
2467
  criteria: n,
2468
2468
  ref: e.string()
2469
- }), Te = e.object({
2469
+ }), ze = e.object({
2470
2470
  _id: n,
2471
2471
  business: n,
2472
2472
  referer: n,
2473
2473
  referee: n,
2474
- criteria: e.array(J),
2475
- reward: e.array(b),
2474
+ criteria: e.array(E),
2475
+ reward: e.array(z),
2476
2476
  refereeReward: e.array(n).optional(),
2477
- criteria_progress: e.array(Ce),
2477
+ criteria_progress: e.array(He),
2478
2478
  status: e.string(),
2479
2479
  pf_referer: g.optional(),
2480
2480
  pf_referee: g.optional(),
2481
- pf_refereeReward: e.array(f).optional()
2482
- }).describe(m.describe(ze));
2483
- Te.pick({
2481
+ pf_refereeReward: e.array(H).optional()
2482
+ }).describe(m.describe(be));
2483
+ ze.pick({
2484
2484
  _id: !0,
2485
2485
  business: !0,
2486
2486
  referer: !0,
@@ -2495,33 +2495,33 @@ Te.pick({
2495
2495
  photoUrl: !0
2496
2496
  })
2497
2497
  });
2498
- const ve = {
2498
+ const Ce = {
2499
2499
  collectionName: "ReferralProgram",
2500
2500
  transform: {
2501
2501
  _id: "oid",
2502
2502
  business: "oid"
2503
2503
  }
2504
- }, E = e.object({
2504
+ }, O = e.object({
2505
2505
  _id: n,
2506
2506
  business: n,
2507
2507
  term_and_condition: e.string().optional(),
2508
2508
  refereeReward: e.array(n).optional(),
2509
- reward: e.array(b),
2510
- criteria: e.array(J)
2511
- }).describe(m.describe(ve));
2509
+ reward: e.array(z),
2510
+ criteria: e.array(E)
2511
+ }).describe(m.describe(Ce));
2512
2512
  e.object({
2513
2513
  referer: n,
2514
2514
  referee: n,
2515
2515
  business: n
2516
2516
  });
2517
2517
  e.object({
2518
- program: E.pick({
2518
+ program: O.pick({
2519
2519
  _id: !0,
2520
2520
  business: !0,
2521
2521
  term_and_condition: !0
2522
2522
  }).extend({
2523
- reward: b.optional(),
2524
- pf_refereeReward: e.array(f).optional()
2523
+ reward: z.optional(),
2524
+ pf_refereeReward: e.array(H).optional()
2525
2525
  }),
2526
2526
  referralCount: e.number(),
2527
2527
  successReferralCount: e.number(),
@@ -2532,33 +2532,33 @@ e.object({
2532
2532
  photoUrl: !0
2533
2533
  }).optional()
2534
2534
  });
2535
- E.extend({
2535
+ O.extend({
2536
2536
  updateReferralRecord: e.boolean().optional()
2537
2537
  });
2538
- const Se = e.object({
2538
+ const Te = e.object({
2539
2539
  facebookPageId: e.string(),
2540
2540
  pageName: e.string(),
2541
2541
  pageProfileImageUrl: e.string(),
2542
2542
  pageAccessToken: e.string().optional(),
2543
2543
  locationIds: e.array(n)
2544
- }), Ne = e.object({
2544
+ }), ve = e.object({
2545
2545
  locationId: n.nullable(),
2546
2546
  googleLocationName: e.string(),
2547
2547
  displayName: e.string().optional()
2548
- }), Ue = e.object({
2548
+ }), Se = e.object({
2549
2549
  accessToken: e.string().nullable(),
2550
2550
  refreshToken: e.string().nullable(),
2551
2551
  accessTokenExpiresAt: e.date().nullable(),
2552
- locations: e.array(Ne)
2553
- }), Pe = e.object({
2552
+ locations: e.array(ve)
2553
+ }), Ne = e.object({
2554
2554
  token: e.string().nullable(),
2555
- pages: e.array(Se)
2555
+ pages: e.array(Te)
2556
2556
  });
2557
2557
  e.object({
2558
2558
  _id: n,
2559
2559
  businessId: n,
2560
- google: Ue.nullable(),
2561
- facebook: Pe.nullable()
2560
+ google: Se.nullable(),
2561
+ facebook: Ne.nullable()
2562
2562
  }).describe(
2563
2563
  m.describe({
2564
2564
  collectionName: "ReviewSourceConfig",
@@ -2618,14 +2618,15 @@ e.object({
2618
2618
  )
2619
2619
  }).nullable()
2620
2620
  });
2621
- const O = e.object({
2621
+ const d = e.object({
2622
2622
  name: e.string(),
2623
- pictureUrl: e.string()
2624
- }), je = O.extend({
2623
+ pictureUrl: e.string(),
2624
+ phoneNumber: e.string().optional()
2625
+ }), Ue = d.extend({
2625
2626
  isAnonymous: e.boolean().optional()
2626
- }), Je = O.extend({
2627
+ }), Pe = d.extend({
2627
2628
  id: e.string().optional()
2628
- }), d = e.object({
2629
+ }), u = e.object({
2629
2630
  comment: e.string(),
2630
2631
  updateTime: e.coerce.date()
2631
2632
  }), s = e.object({
@@ -2633,22 +2634,13 @@ const O = e.object({
2633
2634
  thumbnailUrl: e.string(),
2634
2635
  thumbnailLabel: e.string(),
2635
2636
  videoUrl: e.string().optional()
2636
- }), Ee = {
2637
+ }), je = {
2637
2638
  collectionName: "Reviews",
2638
2639
  transform: {
2639
2640
  _id: "oid",
2641
+ businessId: "oid",
2640
2642
  reviewerId: "oid",
2641
- locationId: "oid"
2642
- },
2643
- lookups: {
2644
- reviewerId: {
2645
- as: "reviewer",
2646
- fromCollection: "UsersV2"
2647
- },
2648
- locationId: {
2649
- as: "location",
2650
- fromCollection: "Locations"
2651
- }
2643
+ restaurantId: "oid"
2652
2644
  }
2653
2645
  }, I = e.enum([
2654
2646
  "google",
@@ -2658,7 +2650,7 @@ const O = e.object({
2658
2650
  ]);
2659
2651
  I.options;
2660
2652
  e.enum(["google", "facebook"]);
2661
- const Oe = e.enum([
2653
+ const Je = e.enum([
2662
2654
  "createTime_desc",
2663
2655
  "createTime_asc",
2664
2656
  "rating_asc",
@@ -2666,50 +2658,70 @@ const Oe = e.enum([
2666
2658
  ]);
2667
2659
  e.object({
2668
2660
  source: I.array().optional(),
2669
- dateFrom: e.coerce.date().optional(),
2670
- dateTo: e.coerce.date().optional(),
2661
+ dateFrom: e.string().datetime({ offset: !0 }).optional(),
2662
+ dateTo: e.string().datetime({ offset: !0 }).optional(),
2671
2663
  locationId: e.string().optional(),
2672
- sort: Oe.optional(),
2664
+ excludeDeleted: e.boolean().optional(),
2665
+ sort: Je.optional(),
2673
2666
  limit: e.coerce.number().int().positive().optional(),
2674
2667
  skip: e.coerce.number().int().min(0).optional()
2675
2668
  });
2676
- const R = e.object({
2669
+ const Xe = e.object({
2670
+ averageScore: e.number(),
2671
+ total: e.number().int().nonnegative(),
2672
+ starCounts: e.array(
2673
+ e.object({
2674
+ star: e.number().int().min(1).max(5),
2675
+ count: e.number().int().nonnegative()
2676
+ })
2677
+ )
2678
+ }), h = e.object({
2677
2679
  name: e.string(),
2678
- pictureUrl: e.string()
2679
- }), Ie = R.extend({
2680
+ pictureUrl: e.string().optional(),
2681
+ phoneNumber: e.string().optional()
2682
+ }), Ee = h.extend({
2683
+ _id: e.string().optional()
2684
+ }), Oe = h.extend({
2685
+ _id: e.string()
2686
+ }), Ie = h.extend({
2680
2687
  isAnonymous: e.boolean().optional()
2681
- }), Re = R.extend({
2688
+ }), Re = h.extend({
2682
2689
  id: e.string().optional()
2683
- }), u = e.object({
2690
+ }), _ = e.object({
2684
2691
  _id: n,
2685
2692
  comment: e.string(),
2686
2693
  createTime: e.coerce.date(),
2687
- locationId: n
2688
- }), Le = u.extend({
2694
+ updateTime: e.coerce.date().nullish(),
2695
+ restaurantId: n,
2696
+ restaurantName: e.string()
2697
+ }), Le = _.extend({
2689
2698
  source: e.literal("google"),
2699
+ externalId: e.string().min(1),
2700
+ translatedComment: e.string().optional(),
2690
2701
  reviewer: Ie.optional(),
2691
- reply: d.optional(),
2702
+ reply: u.optional(),
2692
2703
  mediaItems: e.array(s),
2693
2704
  starRating: e.number(),
2694
2705
  locationName: e.string(),
2695
2706
  locationDisplayName: e.string()
2696
- }), xe = u.extend({
2707
+ }), xe = _.extend({
2697
2708
  source: e.literal("facebook"),
2709
+ externalId: e.string().min(1),
2698
2710
  reviewer: Re.optional(),
2699
2711
  isPositive: e.boolean().optional(),
2700
2712
  pageId: e.string(),
2701
2713
  pageName: e.string()
2702
- }), De = u.extend({
2714
+ }), De = _.extend({
2703
2715
  source: e.literal("feedme"),
2704
- reviewer: T,
2705
- reply: d.optional(),
2716
+ reviewer: Ee.optional(),
2717
+ reply: u.optional(),
2706
2718
  starRating: e.number(),
2707
- location: G.optional(),
2708
2719
  mediaItems: e.array(s),
2709
2720
  billId: e.string()
2710
- }), we = u.extend({
2721
+ }), we = _.extend({
2711
2722
  source: e.literal("feedvibe"),
2712
- reviewer: T.optional(),
2723
+ externalId: e.string().min(1),
2724
+ reviewer: Oe.optional(),
2713
2725
  rating: e.object({
2714
2726
  overall: e.number(),
2715
2727
  food: e.number(),
@@ -2729,44 +2741,53 @@ e.object({
2729
2741
  comment: e.string(),
2730
2742
  starRating: e.number(),
2731
2743
  billId: e.string(),
2744
+ isAnonymous: e.boolean(),
2732
2745
  mediaItems: e.array(s).optional()
2733
2746
  });
2734
- const h = e.object({
2747
+ e.object({
2748
+ name: e.string().trim().min(1),
2749
+ phoneNumber: e.string().trim().min(1).optional()
2750
+ });
2751
+ const y = e.object({
2735
2752
  _id: n,
2736
- externalId: e.string().optional(),
2753
+ businessId: n,
2737
2754
  comment: e.string(),
2738
2755
  createTime: e.coerce.date(),
2739
- // The marketing Location the review belongs to. For feedme reviews this is
2740
- // the restaurantId (Location._id === restaurantId); for google/facebook it
2741
- // is resolved from the review-source location/page mapping at sync time.
2742
- locationId: n
2743
- }), Ae = h.extend({
2756
+ updateTime: e.coerce.date().nullish(),
2757
+ restaurantId: n,
2758
+ restaurantName: e.string(),
2759
+ deletedAt: e.coerce.date().optional()
2760
+ }), Ae = y.extend({
2744
2761
  source: e.literal("google"),
2745
- reviewer: je.optional(),
2746
- reply: d.optional(),
2762
+ externalId: e.string().min(1),
2763
+ translatedComment: e.string().optional(),
2764
+ reviewer: Ue.optional(),
2765
+ reply: u.optional(),
2747
2766
  mediaItems: e.array(s),
2748
2767
  starRating: e.number(),
2749
2768
  locationName: e.string(),
2750
2769
  locationDisplayName: e.string()
2751
- }), Ge = h.extend({
2770
+ }), Ge = y.extend({
2752
2771
  source: e.literal("facebook"),
2753
- reviewer: Je.optional(),
2772
+ externalId: e.string().min(1),
2773
+ reviewer: Pe.optional(),
2754
2774
  isPositive: e.boolean().optional(),
2755
2775
  pageId: e.string(),
2756
2776
  pageName: e.string()
2757
- }), Me = h.extend({
2777
+ }), Me = y.extend({
2758
2778
  source: e.literal("feedme"),
2759
- reviewerId: n,
2760
- reviewer: e.any().optional(),
2761
- reply: d.optional(),
2779
+ isAnonymous: e.boolean(),
2780
+ reviewerId: n.optional(),
2781
+ reviewer: d.optional(),
2782
+ reply: u.optional(),
2762
2783
  starRating: e.number(),
2763
2784
  billId: e.string(),
2764
- location: e.any().optional(),
2765
2785
  mediaItems: e.array(s)
2766
- }), Fe = h.extend({
2786
+ }), Fe = y.extend({
2767
2787
  source: e.literal("feedvibe"),
2788
+ externalId: e.string().min(1),
2768
2789
  reviewerId: n,
2769
- reviewer: e.any().optional(),
2790
+ reviewer: d,
2770
2791
  rating: e.object({
2771
2792
  overall: e.number(),
2772
2793
  food: e.number(),
@@ -2781,17 +2802,18 @@ e.discriminatedUnion("source", [
2781
2802
  Ge,
2782
2803
  Me,
2783
2804
  Fe
2784
- ]).describe(m.describe(Ee));
2805
+ ]).describe(m.describe(je));
2785
2806
  export {
2786
- Z as F,
2807
+ Q as F,
2787
2808
  t as R,
2788
2809
  We as T,
2789
- k as a,
2790
- He as b,
2791
- J as c,
2792
- b as d,
2793
- X as e,
2794
- q as f,
2795
- y as i,
2796
- Y as s
2810
+ M as a,
2811
+ fe as b,
2812
+ E as c,
2813
+ z as d,
2814
+ K as e,
2815
+ W as f,
2816
+ Xe as g,
2817
+ b as i,
2818
+ B as s
2797
2819
  };