@feedmepos/mf-connect 0.1.0-beta.6 → 0.1.0-beta.61

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 (119) hide show
  1. package/dist/Analytic-u9mtlxSv.js +427 -0
  2. package/dist/{App-C2616cfr.js → App-BwTQE7Ft.js} +445 -420
  3. package/dist/AuditLogs-BVMRclSw.js +1886 -0
  4. package/dist/Bin-Cca-XOkz.js +166 -0
  5. package/dist/{Broadcast-CqSwLTAq.js → Broadcast-DRQgpwdP.js} +56 -54
  6. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DrR9Pmtb.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CeUu_T1u.js} +6 -8
  7. package/dist/Card-CnbB_u31.js +896 -0
  8. package/dist/Collections-BjlfOSC3.js +459 -0
  9. package/dist/{Credit-CPcLgnsq.js → Credit-BoElrcx9.js} +36 -34
  10. package/dist/CustomSelect.vue_vue_type_script_setup_true_lang-DLnvDVgf.js +108 -0
  11. package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-BUzUIIUW.js +58 -0
  12. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-B3WVwem6.js +2181 -0
  13. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-D2buK6Dj.js → EffectSheet.vue_vue_type_style_index_0_lang-CGfpziKs.js} +18 -18
  14. package/dist/{Experience-BoBikt-x.js → Experience-SdGBf4vU.js} +32 -30
  15. package/dist/FilterChip.vue_vue_type_script_setup_true_lang-BrPLkFX8.js +118 -0
  16. package/dist/{Game-DR8PyYZa.js → Game-ChLHibpB.js} +39 -37
  17. package/dist/Index-D7Kq6uyf.js +259 -0
  18. package/dist/Marketing-BDajIqR_.js +20071 -0
  19. package/dist/Member-BPZryqWL.js +317 -0
  20. package/dist/MemberList-C52Dop8Z.js +1598 -0
  21. package/dist/MemberTransactions-DHU78kgS.js +45 -0
  22. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-DhtIZCjT.js → MessageInput.vue_vue_type_script_setup_true_lang-js1F2E4N.js} +83 -71
  23. package/dist/{Mission-CMpvz9zN.js → Mission-BQR3qjAu.js} +101 -87
  24. package/dist/Overview-BbLYWXjG.js +1078 -0
  25. package/dist/{Point-DkZn6p9s.js → Point-DbTcWJbQ.js} +55 -53
  26. package/dist/{Promotion-B7YzwPc_.js → Promotion-CIrpWBQD.js} +65 -57
  27. package/dist/Queue-B0Mfq2Vn.js +244 -0
  28. package/dist/Record-Z6ZrJeLc.js +340 -0
  29. package/dist/Reward-D6k0QFQA.js +442 -0
  30. package/dist/RewardGroup.vue_vue_type_script_setup_true_lang-GJ6j_jOh.js +150 -0
  31. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-gQxmX9ur.js +1637 -0
  32. package/dist/Segment-D6MF-EO8.js +568 -0
  33. package/dist/SelectItems.vue_vue_type_script_setup_true_lang-BWG-pz6F.js +181 -0
  34. package/dist/SendVoucherSheet.vue_vue_type_script_setup_true_lang-HgorlHNz.js +147 -0
  35. package/dist/Setting--OFDS95z.js +1931 -0
  36. package/dist/Store-BqlRTC-c.js +1751 -0
  37. package/dist/{StoreRewards-6BzVwZqr.js → StoreRewards-BTu0IdDN.js} +33 -32
  38. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-BX053DJA.js +943 -0
  39. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-B6cAveco.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BAkuqLwy.js} +1 -1
  40. package/dist/{Tier-CW-46oJS.js → Tier-CE9LYAEX.js} +327 -318
  41. package/dist/{Title-CE9rWVdi.js → Title-DOOASUMI.js} +199 -184
  42. package/dist/{Transaction-B21RrC4M.js → Transaction-DPxUOBP-.js} +2 -2
  43. package/dist/UserRuleGroup.vue_vue_type_script_setup_true_lang-CKwf0F_i.js +130 -0
  44. package/dist/Voucher-D69DD02z.js +354 -0
  45. package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-CFL0Nsez.js +419 -0
  46. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-BiVZwBuG.js → ZodTextField.vue_vue_type_script_setup_true_lang-Byh6_EJM.js} +1 -1
  47. package/dist/app-C2u1t47T.js +7059 -0
  48. package/dist/app-DgfmbHZe.js +33357 -0
  49. package/dist/app.js +1 -1
  50. package/dist/{business-aHhRUXc0.js → business-BqCJB_vA.js} +1 -1
  51. package/dist/{campaign-DH9NUNf_.js → campaign-CWMPCmmU.js} +2 -2
  52. package/dist/campaign-D0dTbl5b.js +1810 -0
  53. package/dist/campaign.enum-DhE8N4pA.js +20 -0
  54. package/dist/campaign.fn-BpO-RQih.js +758 -0
  55. package/dist/collectible.enum-rWEc6Tsw.js +19 -0
  56. package/dist/{collection.fn-CYlsA-kW.js → collection.fn-biX2iFDQ.js} +2 -2
  57. package/dist/dto-3m7xZwfI.js +214 -0
  58. package/dist/{effect-LSc9YanX.js → effect-ZMGRxKCZ.js} +9 -9
  59. package/dist/email-addresses-lgY03bkq.js +705 -0
  60. package/dist/{export-Cf0-C5Ly.js → export-BOzeYUy8.js} +5 -5
  61. package/dist/{helper-CiZpeMCM.js → helper-CO29wun4.js} +1 -1
  62. package/dist/index-B3V7krW_.js +29000 -0
  63. package/dist/index-BVbiAxW8.js +115 -0
  64. package/dist/{index-D_83JP2i.js → index-Bvch9tuP.js} +48 -4
  65. package/dist/index-CYOwwy3h.js +44 -0
  66. package/dist/{index-D6cEOHP4.js → index-CbYXYVYp.js} +1501 -1480
  67. package/dist/{index-DtsDOuDx.js → index-ChrOXJDq.js} +24 -21
  68. package/dist/index-CsaQJMAR.js +66 -0
  69. package/dist/index-DNGenFnf.js +32 -0
  70. package/dist/{index-BVb5-Ht8.js → index-Dd22X409.js} +259 -173
  71. package/dist/{index-kPhrD63q.js → index-LYAWIqjk.js} +1 -1
  72. package/dist/index-Xh9cW6Y9.js +54 -0
  73. package/dist/{index-gxwjKu3-.js → index-XhqaicYu.js} +2212 -871
  74. package/dist/{index-DW3PRjPL.js → index-YsC4VklJ.js} +1 -1
  75. package/dist/index-vh86FiIQ.js +10 -0
  76. package/dist/{index.esm2017-B7oVYIbY.js → index.esm2017-CJ1flA6S.js} +121 -121
  77. package/dist/loading-CUs_CN1k.js +71 -0
  78. package/dist/{membership-Dw1ylJ9Y.js → membership-D-GVacos.js} +54 -46
  79. package/dist/money-CMtSALkX.js +15 -0
  80. package/dist/number-CDwwgAYM.js +12 -0
  81. package/dist/objectid-Bf9yKD81.js +145 -0
  82. package/dist/{loading-7yq1tinq.js → plugins-9sQTEyth.js} +3871 -3943
  83. package/dist/remy-vue-client-Cpppk9h-.js +1693 -0
  84. package/dist/reward-DblXGhWc.js +36 -0
  85. package/dist/{rule-C0Q_SHow.js → rule-Cy8cTzuw.js} +180 -177
  86. package/dist/{rule-builder-iu17XIof.js → rule-builder-Cn5vZgFN.js} +1 -1
  87. package/dist/style.css +1 -1
  88. package/dist/{template-CyOanTMu.js → template-Cal94dUy.js} +5 -5
  89. package/dist/trigger-C1nwLSP8.js +144 -0
  90. package/dist/user-ir4Rn5bP.js +54 -0
  91. package/dist/{vue-i18n-B0fLJH7a.js → vue-i18n-eOHBBaH5.js} +243 -243
  92. package/dist/{xlsx-BYO_bB9J.js → xlsx-DulnT75_.js} +1 -1
  93. package/package.json +11 -7
  94. package/dist/Analytic-muDf0oMG.js +0 -622
  95. package/dist/Card-bhLoK0ZV.js +0 -825
  96. package/dist/Collections-DjtsAiol.js +0 -453
  97. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-U_QZneS6.js +0 -2813
  98. package/dist/Marketing-Dny2nMUl.js +0 -316
  99. package/dist/Member-CP_smyk8.js +0 -69
  100. package/dist/MemberList-CR3eYI9p.js +0 -1733
  101. package/dist/MemberTransactions-RTx_lKFb.js +0 -38
  102. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-Cs67_GLE.js +0 -1753
  103. package/dist/Segment-Bb4gHt5V.js +0 -437
  104. package/dist/Setting-Xj0AVzh3.js +0 -1901
  105. package/dist/Store-BWRHQ6Ie.js +0 -1511
  106. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-BsFnT8BS.js +0 -890
  107. package/dist/Voucher-KK9fBI0u.js +0 -490
  108. package/dist/app-CjhXHUQv.js +0 -53428
  109. package/dist/app-Dvf_JNMf.js +0 -5764
  110. package/dist/dto-DArfyZAI.js +0 -2770
  111. package/dist/index-Bi_LGEtY.js +0 -99
  112. package/dist/index-CiQDG7Cm.js +0 -762
  113. package/dist/index-CuvNtC_M.js +0 -61
  114. package/dist/index-DQfjSSMF.js +0 -206
  115. package/dist/index-DcxssxPi.js +0 -29193
  116. package/dist/index-DqJVH2kv.js +0 -298
  117. package/dist/money-CPd0XTNv.js +0 -15
  118. package/dist/number-BgXY4un8.js +0 -12
  119. package/dist/user-Bm4KttFq.js +0 -37
@@ -0,0 +1,19 @@
1
+ import { z as e } from "./plugins-9sQTEyth.js";
2
+ const E = e.enum([
3
+ "VOUCHER",
4
+ "CREDIT",
5
+ "POINT",
6
+ "COIN",
7
+ "TIER",
8
+ "TITLE",
9
+ "COIN",
10
+ "GAME",
11
+ "STAMP",
12
+ "REFERRAL"
13
+ ]);
14
+ E.enum.VOUCHER + "", E.enum.CREDIT + "", E.enum.POINT + "", E.enum.COIN + "", E.enum.TIER + "", E.enum.TITLE + "", E.enum.GAME + "", E.enum.STAMP + "", E.enum.REFERRAL + "";
15
+ const R = e.enum(["FORTUNE_WHEEL", "ROCK_PAPER_SCISSORS"]);
16
+ export {
17
+ E as F,
18
+ R as a
19
+ };
@@ -1,5 +1,5 @@
1
- import "./index-D6cEOHP4.js";
2
- import "./loading-7yq1tinq.js";
1
+ import "./index-CbYXYVYp.js";
2
+ import "./plugins-9sQTEyth.js";
3
3
  function r(e) {
4
4
  switch (e) {
5
5
  case "PROMOTION":
@@ -0,0 +1,214 @@
1
+ import { F as i, z as t } from "./plugins-9sQTEyth.js";
2
+ import { x as C, a as r, y as h } from "./index-XhqaicYu.js";
3
+ import { F as u } from "./index-CbYXYVYp.js";
4
+ import { i as I, R as d } from "./rule-builder-Cn5vZgFN.js";
5
+ function N(a, e) {
6
+ var c, l;
7
+ if (!a) return;
8
+ const n = a.campaign;
9
+ if (!n) return;
10
+ const o = n.event.rule;
11
+ if (!o || !I(o)) {
12
+ e.addIssue({
13
+ code: "custom",
14
+ path: ["campaign", "event", "rule"],
15
+ params: {
16
+ i18n: { key: "zodCustom.campaign.rule_required", values: { type: n.event.type } }
17
+ }
18
+ });
19
+ return;
20
+ }
21
+ switch (n.type) {
22
+ case "MISSION": {
23
+ n.earningOption.amount > n.mission.end && e.addIssue({
24
+ code: "custom",
25
+ path: ["campaign", "earningOption"],
26
+ params: {
27
+ i18n: { key: "zodCustom.campaign.earning_amount_exceed", values: { max: n.mission.end } }
28
+ }
29
+ });
30
+ break;
31
+ }
32
+ case "CREDIT": {
33
+ const p = (c = n.config) == null ? void 0 : c.validityOption;
34
+ (!p || ["validForDay", "validBefore"].every((g) => p[g] == null)) && e.addIssue({
35
+ code: "custom",
36
+ path: ["campaign", "config", "validityOption"],
37
+ params: {
38
+ i18n: { key: "zodCustom.campaign.credit_validity_required" }
39
+ }
40
+ });
41
+ }
42
+ }
43
+ switch (n.event.type) {
44
+ case "BILL_COMPLETED":
45
+ n.type === "MISSION" && n.rewards.length && (n.rewards.forEach((p, m) => {
46
+ (p.threshold < 0 || p.threshold > n.mission.end) && e.addIssue({
47
+ code: "custom",
48
+ path: ["campaign", "rewards", m, "threshold"],
49
+ params: {
50
+ i18n: { key: "zodCustom.campaign.reward_threshold_range" }
51
+ }
52
+ });
53
+ }), (l = n.config) != null && l.validityOption.followFirstReceive || e.addIssue({
54
+ code: "custom",
55
+ path: ["campaign", "config", "validityOption"],
56
+ params: {
57
+ i18n: { key: "zodCustom.campaign.mission_first_receive" }
58
+ }
59
+ }));
60
+ break;
61
+ case "SCHEDULE": {
62
+ if (!o.rules.g_schedule) {
63
+ e.addIssue({
64
+ code: "custom",
65
+ path: ["campaign", "event", "rule"],
66
+ params: {
67
+ i18n: { key: "zodCustom.campaign.schedule_period_required" }
68
+ },
69
+ fatal: !0
70
+ });
71
+ return;
72
+ }
73
+ const p = d.getRules(
74
+ o.rules.g_schedule
75
+ ), m = [
76
+ {
77
+ property: "trigger.date",
78
+ operator: ["_isOnDate", "_rrule"]
79
+ },
80
+ {
81
+ property: "trigger.time",
82
+ operator: ["_isOnTime"]
83
+ }
84
+ ];
85
+ m.length == p.length && m.every((O) => p.some((y) => {
86
+ const f = d.simplify(y);
87
+ return f.property === O.property && O.operator.includes(f.operator);
88
+ })) || e.addIssue({
89
+ code: "custom",
90
+ path: ["campaign", "event", "rule"],
91
+ params: {
92
+ i18n: { key: "zodCustom.campaign.active_period_invalid" }
93
+ }
94
+ });
95
+ break;
96
+ }
97
+ default: {
98
+ "earningOption" in n && n.earningOption.type != "FIXED" && e.addIssue({
99
+ code: "custom",
100
+ path: ["campaign", "earningOption"],
101
+ params: {
102
+ i18n: { key: "zodCustom.campaign.fixed_earning_required" }
103
+ }
104
+ });
105
+ break;
106
+ }
107
+ }
108
+ }
109
+ function D(a) {
110
+ var n;
111
+ if (a.campaign.type === "VOUCHER" && "configs" in a) {
112
+ const o = a.configs;
113
+ o.extras.targetLocation = a.campaign.targetLocation;
114
+ const c = Math.max(
115
+ a.campaign.earningOption.amount,
116
+ o.options.maxUse ?? 1
117
+ );
118
+ a.campaign.earningOption.amount = c, o.options.maxUse = c, a.campaign.earningOption = {
119
+ type: "FIXED",
120
+ amount: 1
121
+ };
122
+ }
123
+ if (a.campaign.type == "MISSION" && "configs" in a) {
124
+ const o = a.configs;
125
+ o.options.validityOption = (n = a.campaign.config) == null ? void 0 : n.validityOption;
126
+ }
127
+ const e = a.campaign.event;
128
+ return e.type != "BILL_COMPLETED" && e.rule && I(e.rule) && (e.rule = d.removeEntry(e.rule, "g_bill"), a.campaign.event = e), a;
129
+ }
130
+ function s(a) {
131
+ const e = h.optionsMap.get(a).extend({
132
+ _id: i.optional(),
133
+ collectible: t.string().nullish()
134
+ });
135
+ switch (a) {
136
+ case "VOUCHER":
137
+ return t.object({
138
+ campaign: e,
139
+ templateId: i,
140
+ configs: u,
141
+ updateCollections: t.boolean().optional(),
142
+ code: t.string().optional()
143
+ });
144
+ case "PROMOTION":
145
+ return t.object({
146
+ campaign: e,
147
+ templateId: i
148
+ });
149
+ case "POINT":
150
+ return t.object({
151
+ campaign: e,
152
+ templateId: i
153
+ });
154
+ case "CREDIT":
155
+ return t.object({
156
+ campaign: e,
157
+ templateId: i
158
+ });
159
+ case "BROADCAST":
160
+ return t.object({
161
+ campaign: e,
162
+ templateId: i
163
+ });
164
+ case "COIN":
165
+ return t.object({
166
+ campaign: e,
167
+ templateId: i
168
+ });
169
+ case "REWARD_POOL":
170
+ return t.object({
171
+ campaign: e,
172
+ templateId: i,
173
+ updateCollections: t.boolean().optional()
174
+ });
175
+ case "GAME":
176
+ return t.object({
177
+ campaign: e,
178
+ configs: u,
179
+ templateId: i,
180
+ updateCollections: t.boolean().optional()
181
+ });
182
+ case "MISSION":
183
+ return t.object({
184
+ campaign: e,
185
+ configs: u,
186
+ templateId: i,
187
+ updateCollections: t.boolean().optional()
188
+ });
189
+ default:
190
+ throw new Error("Not implemented");
191
+ }
192
+ }
193
+ const T = C.extend({
194
+ _id: i.optional(),
195
+ name: t.string().min(1).max(300),
196
+ business: i.optional(),
197
+ campaigns: t.array(i).optional()
198
+ }), A = {
199
+ [r.enum.VOUCHER]: s("VOUCHER"),
200
+ [r.enum.PROMOTION]: s("PROMOTION"),
201
+ [r.enum.POINT]: s("POINT"),
202
+ [r.enum.CREDIT]: s("CREDIT"),
203
+ [r.enum.BROADCAST]: s("BROADCAST"),
204
+ [r.enum.COIN]: s("COIN"),
205
+ [r.enum.REWARD_POOL]: s("REWARD_POOL"),
206
+ [r.enum.GAME]: s("GAME"),
207
+ [r.enum.MISSION]: s("MISSION")
208
+ };
209
+ export {
210
+ A as C,
211
+ T as F,
212
+ D as a,
213
+ N as c
214
+ };
@@ -1,10 +1,10 @@
1
- import { r as c, e as o } from "./index-DcxssxPi.js";
2
- function a(e) {
1
+ import { c as o } from "./index-B3V7krW_.js";
2
+ function c(e) {
3
3
  if (!e)
4
4
  return null;
5
- const n = c.getCountry().currency.symbol;
5
+ const n = o.Config.getCountry().currency.symbol;
6
6
  function s(t) {
7
- const r = o.fromFdoDecimal({ decimal: t.adjustment.amount });
7
+ const r = o.Dinero.fromFdoDecimal({ decimal: t.adjustment.amount });
8
8
  switch (t.adjustment.type) {
9
9
  case "BY_PERCENTAGE":
10
10
  return `${r.toObject().amount}% discount`;
@@ -38,7 +38,7 @@ function a(e) {
38
38
  }
39
39
  function u(t) {
40
40
  if (t.options.target === "BILL" || t.options.target === "PAYMENT") {
41
- const r = o.fromFdoDecimal({
41
+ const r = o.Dinero.fromFdoDecimal({
42
42
  decimal: t.options.minPurchase
43
43
  });
44
44
  return r.toUnit() > 0 ? `min spend ${n}${r.toUnit()}` : "no min spend";
@@ -51,11 +51,11 @@ function a(e) {
51
51
  requirements: u(e)
52
52
  };
53
53
  }
54
- function f(e) {
55
- const n = a(e);
54
+ function m(e) {
55
+ const n = c(e);
56
56
  return !e || !n ? null : Object.values(n).filter(Boolean).join(" | ");
57
57
  }
58
58
  export {
59
- f as e,
60
- a as s
59
+ m as e,
60
+ c as s
61
61
  };