@feedmepos/mf-connect 0.1.0-beta.7 → 0.1.0-beta.71
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/Analytic-CnF_WeRZ.js +427 -0
- package/dist/{App-DalxIjTu.js → App-DJwSTuRa.js} +445 -420
- package/dist/AuditLogs-RarW2PHL.js +1886 -0
- package/dist/Bin-BaixTvHW.js +166 -0
- package/dist/{Broadcast-uMAvsC--.js → Broadcast-8DEAMhyM.js} +56 -54
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-JxbENan8.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DPXoOupI.js} +6 -8
- package/dist/Card-DRwLZ-Mn.js +896 -0
- package/dist/Collections-WsPM9v03.js +459 -0
- package/dist/{Credit-QlnatflM.js → Credit-DMxRdTzt.js} +36 -34
- package/dist/CustomSelect.vue_vue_type_script_setup_true_lang-DLnvDVgf.js +108 -0
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-BUzUIIUW.js +58 -0
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-Bcj6o4Xi.js +2181 -0
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-BE07lc4M.js → EffectSheet.vue_vue_type_style_index_0_lang-CuJ8curT.js} +49 -49
- package/dist/{Experience-Czy41ifp.js → Experience-B0BV4Tc_.js} +32 -30
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-BrPLkFX8.js +118 -0
- package/dist/Game-Bu6kJJHx.js +278 -0
- package/dist/Index-CX-aPFQt.js +259 -0
- package/dist/Marketing-CiVFwl6S.js +20071 -0
- package/dist/Member-DZfTtt13.js +333 -0
- package/dist/MemberList-CscwsZnv.js +1598 -0
- package/dist/MemberTransactions-BWNs6bUm.js +45 -0
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-CtM73bcN.js → MessageInput.vue_vue_type_script_setup_true_lang-BrbRudIU.js} +134 -122
- package/dist/Mission-CyJ-9Qfl.js +296 -0
- package/dist/Overview-DLyt6VId.js +1078 -0
- package/dist/{Point-By6ogYy_.js → Point-Cc_0-RKm.js} +55 -53
- package/dist/Promotion-KqA8nev2.js +289 -0
- package/dist/Queue-i8--zps9.js +249 -0
- package/dist/Record-CLUO1JVc.js +340 -0
- package/dist/Reward-BEdUKQ3M.js +442 -0
- package/dist/RewardGroup.vue_vue_type_script_setup_true_lang-B9vnSbWj.js +150 -0
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-B8zw1TmO.js +1727 -0
- package/dist/Segment-B8sYajZG.js +568 -0
- package/dist/SelectItems.vue_vue_type_script_setup_true_lang-CmmI5Vwl.js +181 -0
- package/dist/SendCollectionSheet.vue_vue_type_script_setup_true_lang-CIcXjbJG.js +186 -0
- package/dist/SendVoucherSheet.vue_vue_type_script_setup_true_lang-DY3FMuIf.js +147 -0
- package/dist/Setting-DT8dRb2A.js +1931 -0
- package/dist/Store-BhsPWRkR.js +1841 -0
- package/dist/StoreRewards-Cx2WDZ3p.js +423 -0
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-Byb7GOoh.js +1028 -0
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-nEdCD6la.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-Cb-FGTO9.js} +1 -1
- package/dist/{Tier-DvAs0-yx.js → Tier-kQy1vGwo.js} +327 -318
- package/dist/{Title-B_Trr39o.js → Title-DKv8FqpX.js} +224 -209
- package/dist/{Transaction-DCJw-b3H.js → Transaction-CSLllOgl.js} +2 -2
- package/dist/UserRuleGroup.vue_vue_type_script_setup_true_lang-CvpBdNBn.js +130 -0
- package/dist/Voucher-BP6fmSwu.js +354 -0
- package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-CxQEg_HW.js +419 -0
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-DXkhu8e9.js → ZodTextField.vue_vue_type_script_setup_true_lang-aurdXO2X.js} +1 -1
- package/dist/app-B3qgrQOd.js +7079 -0
- package/dist/app-s3iL79De.js +33357 -0
- package/dist/app.js +1 -1
- package/dist/business-DG2w8U-i.js +79 -0
- package/dist/campaign-BP6Rz-AH.js +1810 -0
- package/dist/{campaign--0_yMbMV.js → campaign-WPRZ4BRF.js} +2 -2
- package/dist/campaign.enum-CoqrWNTZ.js +20 -0
- package/dist/campaign.fn-BRPigTOA.js +758 -0
- package/dist/collectible.enum-Dy4sxF43.js +19 -0
- package/dist/{collection.fn-3TwPe7aF.js → collection.fn-DGnLyYgV.js} +2 -2
- package/dist/dto-xZ9I6-Jr.js +214 -0
- package/dist/{effect-BeR0LK61.js → effect-C0XoYTus.js} +33 -16
- package/dist/email-addresses-CJ87c7W1.js +705 -0
- package/dist/{export-xeLLhqvh.js → export-qlV-AbEl.js} +5 -5
- package/dist/{helper-B5iqfKh8.js → helper-DzYe8aNx.js} +1 -1
- package/dist/{index-BOdtpNkP.js → index-4vdSri7m.js} +266 -173
- package/dist/{index-CU_d8jjU.js → index-BfSj7cUl.js} +1 -1
- package/dist/index-Bj0ULpXi.js +29556 -0
- package/dist/index-BnZ4yaMH.js +115 -0
- package/dist/index-Bo5DJXxs.js +54 -0
- package/dist/{index-Ct_wR519.js → index-BuvJH6SU.js} +24 -21
- package/dist/index-C2GEs8di.js +32 -0
- package/dist/{index-CyKZ-SsN.js → index-CJuOTcCE.js} +1 -1
- package/dist/index-CsaQJMAR.js +66 -0
- package/dist/{index-DP-dGMJC.js → index-DReysUPw.js} +2230 -871
- package/dist/{index-CAn5heDe.js → index-DgCjRb3o.js} +48 -4
- package/dist/index-IwITtvVu.js +56 -0
- package/dist/{index-Bh-uaaBG.js → index-n3wiQlbk.js} +1506 -1480
- package/dist/index-vh86FiIQ.js +10 -0
- package/dist/{index.esm2017-5jeDA5Zo.js → index.esm2017-CkJhTmme.js} +154 -154
- package/dist/loading-DwJdwl4G.js +71 -0
- package/dist/{membership-D0nqqWNZ.js → membership-DvPK3h8f.js} +54 -46
- package/dist/money-C_WIbr_x.js +15 -0
- package/dist/number-ZeVoGhzP.js +12 -0
- package/dist/objectid-8lkX6otO.js +145 -0
- package/dist/{loading-C-JDVajU.js → plugins-D20keyDW.js} +2990 -3062
- package/dist/remy-vue-client-Cpppk9h-.js +1693 -0
- package/dist/reward-CqnMEq_w.js +36 -0
- package/dist/{rule-Dn_GgBCe.js → rule-D7htGgWz.js} +185 -178
- package/dist/{rule-builder-BXt29Es4.js → rule-builder-BbJpYQ0n.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{template-D2Oi3dxP.js → template-BWQCVHm7.js} +5 -5
- package/dist/trigger-DMuv0_O7.js +144 -0
- package/dist/user-C_v2C0qN.js +54 -0
- package/dist/vue-i18n-N8_TEEd0.js +2365 -0
- package/dist/{xlsx-CCRCidY2.js → xlsx-CsPDNSTo.js} +1 -1
- package/package.json +11 -7
- package/dist/Analytic-BMpS6jWb.js +0 -622
- package/dist/Card-DV8-g69L.js +0 -825
- package/dist/Collections-DRafEHT1.js +0 -453
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-TDoMehSB.js +0 -2813
- package/dist/Game-CD3zSitz.js +0 -255
- package/dist/Marketing-NNes8z6Q.js +0 -316
- package/dist/Member-CTqBgYuV.js +0 -69
- package/dist/MemberList-B99tS5ce.js +0 -1733
- package/dist/MemberTransactions-D1YCXPOg.js +0 -38
- package/dist/Mission-XbBVKBiE.js +0 -261
- package/dist/Promotion-DKcBr-RI.js +0 -247
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-D1ESqEFO.js +0 -1753
- package/dist/Segment-B8cszL-F.js +0 -437
- package/dist/Setting-aZYABlMW.js +0 -1901
- package/dist/Store-Bx2tyJwe.js +0 -1511
- package/dist/StoreRewards-DTp9G6gw.js +0 -401
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-B2W7ly5Z.js +0 -890
- package/dist/Voucher-jqv3ji90.js +0 -490
- package/dist/app-WlcUVbFb.js +0 -5764
- package/dist/app-_w0hjM7u.js +0 -53428
- package/dist/business-BC4-i1cU.js +0 -78
- package/dist/dto-Ns2dLn1B.js +0 -2770
- package/dist/index-BWb9vRCi.js +0 -29193
- package/dist/index-CpU9aqyW.js +0 -206
- package/dist/index-CqO_ZvtD.js +0 -99
- package/dist/index-CuvNtC_M.js +0 -61
- package/dist/index-DsNsA2uX.js +0 -298
- package/dist/index-WAMr3npT.js +0 -762
- package/dist/money-hdbrblud.js +0 -15
- package/dist/number-CRWGOZaW.js +0 -12
- package/dist/user-Bm4KttFq.js +0 -37
- package/dist/vue-i18n-Dud8fvmw.js +0 -2365
|
@@ -1,113 +1,66 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import "./index-
|
|
4
|
-
import { R as t } from "./rule-builder-
|
|
5
|
-
import { i
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}, z = { class: "rounded-md bg-white shadow-md max-h-[300px] overflow-y-scroll pl-4 py-12" }, _e = /* @__PURE__ */ V({
|
|
14
|
-
__name: "CustomSelect",
|
|
15
|
-
props: {
|
|
16
|
-
label: {
|
|
17
|
-
type: String,
|
|
18
|
-
required: !1
|
|
19
|
-
},
|
|
20
|
-
placeholder: {
|
|
21
|
-
type: String,
|
|
22
|
-
required: !1
|
|
23
|
-
},
|
|
24
|
-
items: {
|
|
25
|
-
type: Object,
|
|
26
|
-
required: !0
|
|
27
|
-
},
|
|
28
|
-
modelValue: {
|
|
29
|
-
type: Object
|
|
30
|
-
},
|
|
31
|
-
zIndex: {
|
|
32
|
-
type: Number
|
|
33
|
-
},
|
|
34
|
-
multiselect: {
|
|
35
|
-
type: Boolean
|
|
36
|
-
}
|
|
1
|
+
import { z as e, F as n, m as o, e as v } from "./plugins-D20keyDW.js";
|
|
2
|
+
import { B as E, D as O, E as I, G as L, H as p } from "./index-DReysUPw.js";
|
|
3
|
+
import { c as h } from "./index-n3wiQlbk.js";
|
|
4
|
+
import { R as t } from "./rule-builder-BbJpYQ0n.js";
|
|
5
|
+
import { i } from "./helper-DzYe8aNx.js";
|
|
6
|
+
import { a as r } from "./index-Bo5DJXxs.js";
|
|
7
|
+
const T = {
|
|
8
|
+
collectionName: "AuditLogs",
|
|
9
|
+
transform: {
|
|
10
|
+
_id: "oid",
|
|
11
|
+
business: "oid",
|
|
12
|
+
timestamp: "date"
|
|
37
13
|
},
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
return p(), O(B, {
|
|
44
|
-
"show-popover": I(m),
|
|
45
|
-
onPopoverChanged: b[0] || (b[0] = (a) => m.value = a),
|
|
46
|
-
"z-index": n.zIndex
|
|
47
|
-
}, {
|
|
48
|
-
"popover-button": g(() => [
|
|
49
|
-
L(v.$slots, "popover-button", {}, () => [
|
|
50
|
-
n.label ? (p(), d("div", X, u(n.label), 1)) : H("", !0),
|
|
51
|
-
h(U, null, {
|
|
52
|
-
append: g(() => [
|
|
53
|
-
L(v.$slots, "append"),
|
|
54
|
-
h(N, {
|
|
55
|
-
name: I(m) ? "expand_less" : "expand_more",
|
|
56
|
-
size: "md",
|
|
57
|
-
color: "black"
|
|
58
|
-
}, null, 8, ["name"])
|
|
59
|
-
]),
|
|
60
|
-
default: g(() => {
|
|
61
|
-
var a;
|
|
62
|
-
return [
|
|
63
|
-
n.multiselect ? (p(), d("div", q, u(n.items.filter((i) => {
|
|
64
|
-
var r;
|
|
65
|
-
return (r = n.modelValue) == null ? void 0 : r.includes(i.value);
|
|
66
|
-
}).map((i) => i.label).join(", ")), 1)) : (p(), d("div", {
|
|
67
|
-
key: 0,
|
|
68
|
-
class: x(["fm-typo-en-body-lg-400", {
|
|
69
|
-
"text-fm-color-typo-secondary": !n.items.find(
|
|
70
|
-
(i) => i.value == n.modelValue
|
|
71
|
-
)
|
|
72
|
-
}])
|
|
73
|
-
}, u(((a = n.items.find((i) => i.value == n.modelValue)) == null ? void 0 : a.label) || n.placeholder), 3))
|
|
74
|
-
];
|
|
75
|
-
}),
|
|
76
|
-
_: 3
|
|
77
|
-
})
|
|
78
|
-
])
|
|
79
|
-
]),
|
|
80
|
-
default: g(() => [
|
|
81
|
-
k("div", z, [
|
|
82
|
-
(p(!0), d(Y, null, j(n.items, (a) => {
|
|
83
|
-
var i, r;
|
|
84
|
-
return p(), O(F, {
|
|
85
|
-
class: x(`${n.multiselect ? (i = n.modelValue) != null && i.some((l) => l == a.value) ? "bg-fm-color-system-warning-100" : "" : n.modelValue == a.value}`),
|
|
86
|
-
"has-checkbox": n.multiselect,
|
|
87
|
-
key: a.value,
|
|
88
|
-
"model-value": n.multiselect ? (r = n.modelValue) == null ? void 0 : r.some((l) => l == a.value) : n.modelValue == a.value,
|
|
89
|
-
label: a.label,
|
|
90
|
-
onClick: (l) => {
|
|
91
|
-
var E;
|
|
92
|
-
if (l.stopPropagation(), !n.multiselect)
|
|
93
|
-
m.value = !1, _("update:model-value", a.value);
|
|
94
|
-
else {
|
|
95
|
-
const P = (E = n.modelValue) == null ? void 0 : E.some((y) => y == a.value);
|
|
96
|
-
_(
|
|
97
|
-
"update:model-value",
|
|
98
|
-
P ? (n.modelValue ?? []).filter((y) => y !== a.value) : [...n.modelValue ?? [], a.value]
|
|
99
|
-
);
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
}, null, 8, ["class", "has-checkbox", "model-value", "label", "onClick"]);
|
|
103
|
-
}), 128))
|
|
104
|
-
])
|
|
105
|
-
]),
|
|
106
|
-
_: 3
|
|
107
|
-
}, 8, ["show-popover", "z-index"]);
|
|
108
|
-
};
|
|
14
|
+
lookups: {
|
|
15
|
+
business: {
|
|
16
|
+
as: "pf_business",
|
|
17
|
+
fromCollection: "Businesses"
|
|
18
|
+
}
|
|
109
19
|
}
|
|
110
|
-
}
|
|
20
|
+
}, R = e.enum([
|
|
21
|
+
"GET",
|
|
22
|
+
"POST",
|
|
23
|
+
"PUT",
|
|
24
|
+
"PATCH",
|
|
25
|
+
"DELETE",
|
|
26
|
+
"OPTIONS",
|
|
27
|
+
"HEAD",
|
|
28
|
+
"ALL"
|
|
29
|
+
]), C = e.enum([
|
|
30
|
+
"CAMPAIGN",
|
|
31
|
+
"LOCATION",
|
|
32
|
+
"MARKETING MATERIALS",
|
|
33
|
+
"MEMBERSHIP",
|
|
34
|
+
"STORE",
|
|
35
|
+
"TRANSACTION",
|
|
36
|
+
"SETTINGS",
|
|
37
|
+
"SEGMENTATION",
|
|
38
|
+
"USER"
|
|
39
|
+
]), x = e.object({
|
|
40
|
+
httpMethod: R,
|
|
41
|
+
url: e.string().min(1),
|
|
42
|
+
userAgent: e.string(),
|
|
43
|
+
host: e.string().min(1),
|
|
44
|
+
params: e.object({}).passthrough().nullish(),
|
|
45
|
+
query: e.object({}).passthrough().nullish(),
|
|
46
|
+
body: e.object({}).passthrough().nullish()
|
|
47
|
+
}), D = e.object({
|
|
48
|
+
statusCode: e.number().int().min(100).max(599),
|
|
49
|
+
body: e.object({}).passthrough().nullish()
|
|
50
|
+
});
|
|
51
|
+
e.object({
|
|
52
|
+
_id: n,
|
|
53
|
+
user: e.string().length(28),
|
|
54
|
+
userName: e.string().min(1),
|
|
55
|
+
userPhoneNumber: e.string().refine((a) => E(a)).nullish(),
|
|
56
|
+
moduleType: C,
|
|
57
|
+
business: n.nullish(),
|
|
58
|
+
clientIp: e.string().nullish(),
|
|
59
|
+
timestamp: e.string().datetime(),
|
|
60
|
+
request: x,
|
|
61
|
+
response: D
|
|
62
|
+
}).describe(o.describe(T));
|
|
63
|
+
const pe = {
|
|
111
64
|
PROMOTION: {
|
|
112
65
|
name: "Promotion Template",
|
|
113
66
|
description: "Promotion template for campaign creation.",
|
|
@@ -502,7 +455,7 @@ const X = {
|
|
|
502
455
|
// },
|
|
503
456
|
hideInApp: !0
|
|
504
457
|
},
|
|
505
|
-
configs:
|
|
458
|
+
configs: i("VOUCHER", {
|
|
506
459
|
name: "",
|
|
507
460
|
business: null,
|
|
508
461
|
noCampaign: !1
|
|
@@ -1216,7 +1169,9 @@ const X = {
|
|
|
1216
1169
|
amount: 1
|
|
1217
1170
|
},
|
|
1218
1171
|
config: {
|
|
1219
|
-
validityOption: {
|
|
1172
|
+
validityOption: {
|
|
1173
|
+
validForDay: 1
|
|
1174
|
+
}
|
|
1220
1175
|
}
|
|
1221
1176
|
}
|
|
1222
1177
|
}
|
|
@@ -1440,7 +1395,7 @@ const X = {
|
|
|
1440
1395
|
rewards: []
|
|
1441
1396
|
}
|
|
1442
1397
|
},
|
|
1443
|
-
configs:
|
|
1398
|
+
configs: i("GAME", {
|
|
1444
1399
|
name: "Token",
|
|
1445
1400
|
business: null,
|
|
1446
1401
|
noCampaign: !1
|
|
@@ -1681,27 +1636,27 @@ const X = {
|
|
|
1681
1636
|
type: "timeframe"
|
|
1682
1637
|
}
|
|
1683
1638
|
},
|
|
1684
|
-
configs:
|
|
1639
|
+
configs: i("STAMP", {
|
|
1685
1640
|
business: null,
|
|
1686
1641
|
noCampaign: !1
|
|
1687
1642
|
})
|
|
1688
1643
|
}
|
|
1689
1644
|
}
|
|
1690
1645
|
};
|
|
1691
|
-
t.scaffoldGroup(),
|
|
1646
|
+
t.scaffoldGroup(), i("STAMP", {
|
|
1692
1647
|
business: null,
|
|
1693
1648
|
noCampaign: !1
|
|
1694
1649
|
});
|
|
1695
1650
|
({
|
|
1696
1651
|
...t.scaffoldGroup()
|
|
1697
|
-
},
|
|
1652
|
+
}, i("VOUCHER", {
|
|
1698
1653
|
name: "",
|
|
1699
1654
|
business: null,
|
|
1700
1655
|
noCampaign: !1
|
|
1701
1656
|
}));
|
|
1702
1657
|
({
|
|
1703
1658
|
...t.scaffoldGroup()
|
|
1704
|
-
},
|
|
1659
|
+
}, i("VOUCHER", {
|
|
1705
1660
|
name: "",
|
|
1706
1661
|
business: null,
|
|
1707
1662
|
noCampaign: !1
|
|
@@ -1744,7 +1699,7 @@ t.setRuleToGroup(t.scaffoldGroup(), [
|
|
|
1744
1699
|
});
|
|
1745
1700
|
({
|
|
1746
1701
|
...t.scaffoldGroup()
|
|
1747
|
-
},
|
|
1702
|
+
}, i("VOUCHER", {
|
|
1748
1703
|
name: "",
|
|
1749
1704
|
business: null,
|
|
1750
1705
|
noCampaign: !1
|
|
@@ -1790,14 +1745,14 @@ t.setRuleToGroup(
|
|
|
1790
1745
|
"&&"
|
|
1791
1746
|
)
|
|
1792
1747
|
);
|
|
1793
|
-
t.scaffoldGroup(), t.scaffoldGroup(),
|
|
1748
|
+
t.scaffoldGroup(), t.scaffoldGroup(), i("GAME", {
|
|
1794
1749
|
name: "Token",
|
|
1795
1750
|
business: null,
|
|
1796
1751
|
noCampaign: !1
|
|
1797
1752
|
});
|
|
1798
1753
|
({
|
|
1799
1754
|
...t.scaffoldGroup()
|
|
1800
|
-
},
|
|
1755
|
+
}, i("VOUCHER", {
|
|
1801
1756
|
name: "",
|
|
1802
1757
|
business: null,
|
|
1803
1758
|
noCampaign: !1
|
|
@@ -1826,7 +1781,7 @@ t.setRuleToGroup(t.scaffoldGroup(), [
|
|
|
1826
1781
|
],
|
|
1827
1782
|
"&&"
|
|
1828
1783
|
)
|
|
1829
|
-
]),
|
|
1784
|
+
]), i("VOUCHER", {
|
|
1830
1785
|
name: "",
|
|
1831
1786
|
business: null,
|
|
1832
1787
|
noCampaign: !1
|
|
@@ -1849,7 +1804,7 @@ t.setRuleToGroup(t.scaffoldGroup(), [
|
|
|
1849
1804
|
({
|
|
1850
1805
|
...t.scaffoldGroup()
|
|
1851
1806
|
});
|
|
1852
|
-
const
|
|
1807
|
+
const S = e.enum([
|
|
1853
1808
|
"MEMBER_REWARD",
|
|
1854
1809
|
"PAID_LOYALTY",
|
|
1855
1810
|
"COLLECT_FEEDBACK",
|
|
@@ -1859,7 +1814,7 @@ const Q = e.enum([
|
|
|
1859
1814
|
"BROADCAST",
|
|
1860
1815
|
"BIRTHDAY",
|
|
1861
1816
|
"GAME"
|
|
1862
|
-
]),
|
|
1817
|
+
]), A = e.enum([
|
|
1863
1818
|
"text",
|
|
1864
1819
|
"number",
|
|
1865
1820
|
"textarea",
|
|
@@ -1886,95 +1841,95 @@ const Q = e.enum([
|
|
|
1886
1841
|
"rule_feedback",
|
|
1887
1842
|
"rule_birthday",
|
|
1888
1843
|
"promotion_game_type"
|
|
1889
|
-
]),
|
|
1844
|
+
]), M = e.object({
|
|
1890
1845
|
label: e.string().optional(),
|
|
1891
1846
|
property: e.string().or(e.any()),
|
|
1892
|
-
type:
|
|
1847
|
+
type: A,
|
|
1893
1848
|
extras: e.string().optional(),
|
|
1894
1849
|
isRuleChildren: e.boolean().optional()
|
|
1895
|
-
}),
|
|
1850
|
+
}), N = e.object({
|
|
1896
1851
|
name: e.string().optional(),
|
|
1897
|
-
fields: e.array(
|
|
1852
|
+
fields: e.array(M),
|
|
1898
1853
|
condition: e.object({
|
|
1899
1854
|
not: e.boolean().optional(),
|
|
1900
1855
|
property: e.string(),
|
|
1901
1856
|
value: e.any()
|
|
1902
1857
|
}).optional()
|
|
1903
|
-
}),
|
|
1858
|
+
}), w = e.object({
|
|
1904
1859
|
name: e.string(),
|
|
1905
|
-
groups: e.array(
|
|
1860
|
+
groups: e.array(N)
|
|
1906
1861
|
});
|
|
1907
1862
|
e.object({
|
|
1908
|
-
_id:
|
|
1863
|
+
_id: n,
|
|
1909
1864
|
name: e.string(),
|
|
1910
1865
|
description: e.string().nullish(),
|
|
1911
|
-
steps: e.array(
|
|
1912
|
-
intention: e.array(
|
|
1866
|
+
steps: e.array(w).min(1),
|
|
1867
|
+
intention: e.array(S),
|
|
1913
1868
|
defaultValue: e.any()
|
|
1914
1869
|
}).describe(JSON.stringify({ collectionName: "MarketingTemplates" }));
|
|
1915
|
-
const
|
|
1870
|
+
const U = {
|
|
1916
1871
|
collectionName: "Businesses",
|
|
1917
1872
|
transform: {
|
|
1918
1873
|
_id: "oid"
|
|
1919
1874
|
}
|
|
1920
1875
|
};
|
|
1921
1876
|
e.object({
|
|
1922
|
-
_id:
|
|
1877
|
+
_id: n,
|
|
1923
1878
|
ownerId: e.string(),
|
|
1924
1879
|
name: e.string(),
|
|
1925
1880
|
credit: e.number(),
|
|
1926
1881
|
forceSend: e.boolean().optional()
|
|
1927
|
-
}).describe(
|
|
1928
|
-
const
|
|
1882
|
+
}).describe(o.describe(U));
|
|
1883
|
+
const m = e.enum(["PHONE"]), F = e.enum(["MOCEAN", "SLACK", "SMS", "EMAIL"]), P = e.enum(["PENDING", "COMPLETED", "FAILED"]), G = e.enum([
|
|
1929
1884
|
"General",
|
|
1930
1885
|
"Otp",
|
|
1931
1886
|
"Marketing",
|
|
1932
1887
|
"Ordering",
|
|
1933
1888
|
"MemberInvitation"
|
|
1934
|
-
]),
|
|
1935
|
-
type:
|
|
1936
|
-
}),
|
|
1937
|
-
type: e.literal(
|
|
1938
|
-
provider:
|
|
1939
|
-
usage:
|
|
1940
|
-
}),
|
|
1889
|
+
]), B = e.object({
|
|
1890
|
+
type: m
|
|
1891
|
+
}), s = B.extend({
|
|
1892
|
+
type: e.literal(m.enum.PHONE),
|
|
1893
|
+
provider: F,
|
|
1894
|
+
usage: G.optional()
|
|
1895
|
+
}), H = {
|
|
1941
1896
|
collectionName: "Notifications",
|
|
1942
1897
|
transform: { _id: "oid", business: "oid" }
|
|
1943
1898
|
};
|
|
1944
1899
|
e.object({
|
|
1945
|
-
_id:
|
|
1946
|
-
business:
|
|
1900
|
+
_id: n,
|
|
1901
|
+
business: n,
|
|
1947
1902
|
target: e.string(),
|
|
1948
1903
|
title: e.string().optional(),
|
|
1949
1904
|
message: e.string(),
|
|
1950
|
-
option:
|
|
1951
|
-
status:
|
|
1905
|
+
option: s,
|
|
1906
|
+
status: P,
|
|
1952
1907
|
ref: e.string().optional()
|
|
1953
|
-
}).describe(
|
|
1908
|
+
}).describe(o.describe(H));
|
|
1954
1909
|
e.object({
|
|
1955
1910
|
target: e.string(),
|
|
1956
1911
|
title: e.string().optional(),
|
|
1957
1912
|
message: e.string(),
|
|
1958
|
-
option:
|
|
1913
|
+
option: s,
|
|
1959
1914
|
ref: e.string().optional()
|
|
1960
1915
|
});
|
|
1961
1916
|
e.object({
|
|
1962
1917
|
phone: e.string(),
|
|
1963
1918
|
message: e.string()
|
|
1964
1919
|
});
|
|
1965
|
-
const
|
|
1966
|
-
name: e.string(),
|
|
1920
|
+
const c = e.object({
|
|
1921
|
+
name: e.string().optional(),
|
|
1967
1922
|
address: e.string()
|
|
1968
|
-
}),
|
|
1923
|
+
}), V = e.object({
|
|
1969
1924
|
filename: e.string(),
|
|
1970
1925
|
content: e.instanceof(Uint8Array)
|
|
1971
1926
|
});
|
|
1972
1927
|
e.object({
|
|
1973
|
-
from:
|
|
1974
|
-
to: e.array(
|
|
1928
|
+
from: c.optional(),
|
|
1929
|
+
to: e.array(c),
|
|
1975
1930
|
subject: e.string(),
|
|
1976
1931
|
html: e.string().optional(),
|
|
1977
|
-
attachments: e.array(
|
|
1932
|
+
attachments: e.array(V).optional()
|
|
1978
1933
|
});
|
|
1979
1934
|
e.object({
|
|
1980
1935
|
subject: e.string(),
|
|
@@ -2007,15 +1962,22 @@ e.object({
|
|
|
2007
1962
|
claimIds: e.array(e.string()),
|
|
2008
1963
|
billId: e.string()
|
|
2009
1964
|
});
|
|
2010
|
-
|
|
2011
|
-
|
|
1965
|
+
e.object({
|
|
1966
|
+
amount: v,
|
|
1967
|
+
member: e.string(),
|
|
1968
|
+
bill: e.string(),
|
|
1969
|
+
otp: e.string().nullish(),
|
|
1970
|
+
businessId: e.string()
|
|
1971
|
+
});
|
|
1972
|
+
var g = /* @__PURE__ */ ((a) => (a[a.feedMe = 0] = "feedMe", a[a.business = 1] = "business", a[a.restaurant = 2] = "restaurant", a))(g || {});
|
|
1973
|
+
e.nativeEnum(g);
|
|
2012
1974
|
e.enum(["manage", "create", "read", "update", "delete"]);
|
|
2013
1975
|
e.enum(["all", "restaurant", "business", "delivery", "agent"]);
|
|
2014
1976
|
e.enum(["quota"]);
|
|
2015
|
-
var
|
|
2016
|
-
e.nativeEnum(
|
|
1977
|
+
var d = /* @__PURE__ */ ((a) => (a.marketing = "business::marketing", a.campaign = "business::campaign", a.counter = "business::counter", a.permission = "business::permission", a.role = "business::role", a))(d || {});
|
|
1978
|
+
e.nativeEnum(d);
|
|
2017
1979
|
e.enum(["restaurant"]);
|
|
2018
|
-
const
|
|
1980
|
+
const k = e.object({
|
|
2019
1981
|
label: e.string(),
|
|
2020
1982
|
subject: e.union([e.string(), e.array(e.string())]),
|
|
2021
1983
|
actions: e.union([e.string(), e.array(e.string())]),
|
|
@@ -2025,41 +1987,41 @@ const le = e.object({
|
|
|
2025
1987
|
reason: e.string().optional()
|
|
2026
1988
|
});
|
|
2027
1989
|
e.object({
|
|
2028
|
-
_id:
|
|
1990
|
+
_id: n,
|
|
2029
1991
|
businessId: e.string(),
|
|
2030
1992
|
userId: e.string(),
|
|
2031
1993
|
email: e.string().nullish(),
|
|
2032
1994
|
phoneNo: e.string().nullish(),
|
|
2033
|
-
permissions: e.array(e.lazy(() =>
|
|
1995
|
+
permissions: e.array(e.lazy(() => k))
|
|
2034
1996
|
}).describe(
|
|
2035
|
-
|
|
1997
|
+
o.describe({
|
|
2036
1998
|
collectionName: "PermissionUsers",
|
|
2037
1999
|
transform: {
|
|
2038
2000
|
_id: "oid"
|
|
2039
2001
|
}
|
|
2040
2002
|
})
|
|
2041
2003
|
);
|
|
2042
|
-
const
|
|
2004
|
+
const y = e.object({
|
|
2043
2005
|
userId: e.string(),
|
|
2044
2006
|
level: e.number(),
|
|
2045
2007
|
role: e.string().optional(),
|
|
2046
2008
|
businessId: e.string().optional(),
|
|
2047
2009
|
restaurantId: e.string().optional()
|
|
2048
|
-
}),
|
|
2010
|
+
}), j = e.function().args(e.any(), y).returns(e.boolean()), Y = e.function().args(y).returns(e.promise(e.array(e.any())));
|
|
2049
2011
|
e.object({
|
|
2050
|
-
isAdmin:
|
|
2051
|
-
getRules:
|
|
2012
|
+
isAdmin: j,
|
|
2013
|
+
getRules: Y
|
|
2052
2014
|
});
|
|
2053
2015
|
e.object({
|
|
2054
|
-
transactions: e.array(
|
|
2055
|
-
collections: e.array(
|
|
2016
|
+
transactions: e.array(O),
|
|
2017
|
+
collections: e.array(I)
|
|
2056
2018
|
});
|
|
2057
|
-
const
|
|
2019
|
+
const u = e.enum([
|
|
2058
2020
|
"ROCK_PAPER_SCISSOR"
|
|
2059
2021
|
]);
|
|
2060
|
-
|
|
2022
|
+
u.enum.ROCK_PAPER_SCISSOR + "";
|
|
2061
2023
|
e.object({
|
|
2062
|
-
type:
|
|
2024
|
+
type: u
|
|
2063
2025
|
});
|
|
2064
2026
|
e.object({
|
|
2065
2027
|
host: e.string().url(),
|
|
@@ -2086,8 +2048,139 @@ e.object({
|
|
|
2086
2048
|
phone: e.string().optional(),
|
|
2087
2049
|
email: e.string().optional()
|
|
2088
2050
|
});
|
|
2051
|
+
const K = e.enum([
|
|
2052
|
+
"PENDING",
|
|
2053
|
+
"SUCCESS",
|
|
2054
|
+
"FAILED",
|
|
2055
|
+
"RETRYING"
|
|
2056
|
+
]), W = {
|
|
2057
|
+
collectionName: "WebhookLogs",
|
|
2058
|
+
transform: {
|
|
2059
|
+
_id: "oid",
|
|
2060
|
+
business: "oid"
|
|
2061
|
+
}
|
|
2062
|
+
};
|
|
2063
|
+
e.object({
|
|
2064
|
+
_id: n,
|
|
2065
|
+
business: n,
|
|
2066
|
+
type: e.string(),
|
|
2067
|
+
payload: e.record(e.any()),
|
|
2068
|
+
status: K,
|
|
2069
|
+
response: e.any().optional(),
|
|
2070
|
+
error: e.string().optional()
|
|
2071
|
+
}).describe(o.describe(W));
|
|
2072
|
+
const X = e.enum(["AUTO", "MANUAL"]);
|
|
2073
|
+
e.enum(["IN_PROGRESS", "COMPLETED"]);
|
|
2074
|
+
const f = e.object({
|
|
2075
|
+
_id: n,
|
|
2076
|
+
name: e.string().min(1, "Name is required").max(50),
|
|
2077
|
+
type: X,
|
|
2078
|
+
event: L.optional()
|
|
2079
|
+
}), q = e.object({
|
|
2080
|
+
from: e.number().int("Must be integer").min(1, "Min referral count need to start from 1"),
|
|
2081
|
+
to: e.number().int("Must be integer").nullish()
|
|
2082
|
+
}).superRefine((a, b) => {
|
|
2083
|
+
a.from && a.to && a.from > a.to && b.addIssue({
|
|
2084
|
+
code: "custom",
|
|
2085
|
+
message: "Max referral count must be more than min referral count"
|
|
2086
|
+
});
|
|
2087
|
+
}), Q = e.object({
|
|
2088
|
+
threshold: q,
|
|
2089
|
+
rewards: e.array(n),
|
|
2090
|
+
pf_reward: e.array(r).optional()
|
|
2091
|
+
}), l = e.object({
|
|
2092
|
+
id: e.string(),
|
|
2093
|
+
name: e.string().min(1, "Name is required").max(50, "Name must be less than 50 characters"),
|
|
2094
|
+
rule: h.optional(),
|
|
2095
|
+
rewards: e.array(Q)
|
|
2096
|
+
}), J = {
|
|
2097
|
+
collectionName: "ReferralRecords",
|
|
2098
|
+
transform: {
|
|
2099
|
+
_id: "oid",
|
|
2100
|
+
business: "oid",
|
|
2101
|
+
referer: "oid",
|
|
2102
|
+
referee: "oid",
|
|
2103
|
+
refereeReward: "oid"
|
|
2104
|
+
}
|
|
2105
|
+
}, z = e.object({
|
|
2106
|
+
completedAt: e.coerce.date(),
|
|
2107
|
+
criteria: n,
|
|
2108
|
+
ref: e.string()
|
|
2109
|
+
}), Z = e.object({
|
|
2110
|
+
_id: n,
|
|
2111
|
+
business: n,
|
|
2112
|
+
referer: n,
|
|
2113
|
+
referee: n,
|
|
2114
|
+
criteria: e.array(f),
|
|
2115
|
+
reward: e.array(l),
|
|
2116
|
+
refereeReward: e.array(n).optional(),
|
|
2117
|
+
criteria_progress: e.array(z),
|
|
2118
|
+
status: e.string(),
|
|
2119
|
+
pf_referer: p.optional(),
|
|
2120
|
+
pf_referee: p.optional(),
|
|
2121
|
+
pf_refereeReward: e.array(r).optional()
|
|
2122
|
+
}).describe(o.describe(J));
|
|
2123
|
+
Z.pick({
|
|
2124
|
+
_id: !0,
|
|
2125
|
+
business: !0,
|
|
2126
|
+
referer: !0,
|
|
2127
|
+
referee: !0,
|
|
2128
|
+
criteria_progress: !0,
|
|
2129
|
+
criteria: !0
|
|
2130
|
+
}).extend({
|
|
2131
|
+
pf_referee: p.pick({
|
|
2132
|
+
_id: !0,
|
|
2133
|
+
name: !0,
|
|
2134
|
+
phoneNumber: !0,
|
|
2135
|
+
photoUrl: !0
|
|
2136
|
+
})
|
|
2137
|
+
});
|
|
2138
|
+
const $ = {
|
|
2139
|
+
collectionName: "ReferralProgram",
|
|
2140
|
+
transform: {
|
|
2141
|
+
_id: "oid",
|
|
2142
|
+
business: "oid"
|
|
2143
|
+
}
|
|
2144
|
+
}, _ = e.object({
|
|
2145
|
+
_id: n,
|
|
2146
|
+
business: n,
|
|
2147
|
+
term_and_condition: e.string().optional(),
|
|
2148
|
+
refereeReward: e.array(n).optional(),
|
|
2149
|
+
reward: e.array(l),
|
|
2150
|
+
criteria: e.array(f)
|
|
2151
|
+
}).describe(o.describe($));
|
|
2152
|
+
e.object({
|
|
2153
|
+
referer: n,
|
|
2154
|
+
referee: n,
|
|
2155
|
+
business: n
|
|
2156
|
+
});
|
|
2157
|
+
e.object({
|
|
2158
|
+
program: _.pick({
|
|
2159
|
+
_id: !0,
|
|
2160
|
+
business: !0,
|
|
2161
|
+
term_and_condition: !0
|
|
2162
|
+
}).extend({
|
|
2163
|
+
reward: l.optional(),
|
|
2164
|
+
pf_refereeReward: e.array(r).optional()
|
|
2165
|
+
}),
|
|
2166
|
+
referralCount: e.number(),
|
|
2167
|
+
successReferralCount: e.number(),
|
|
2168
|
+
referredBy: p.pick({
|
|
2169
|
+
_id: !0,
|
|
2170
|
+
name: !0,
|
|
2171
|
+
phoneNumber: !0,
|
|
2172
|
+
photoUrl: !0
|
|
2173
|
+
}).optional()
|
|
2174
|
+
});
|
|
2175
|
+
_.extend({
|
|
2176
|
+
updateReferralRecord: e.boolean().optional()
|
|
2177
|
+
});
|
|
2089
2178
|
export {
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2179
|
+
S as F,
|
|
2180
|
+
pe as T,
|
|
2181
|
+
Q as a,
|
|
2182
|
+
f as b,
|
|
2183
|
+
l as c,
|
|
2184
|
+
R as d,
|
|
2185
|
+
C as e
|
|
2093
2186
|
};
|