@feedmepos/mf-connect 0.1.96-prod → 0.1.98-beta.1
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/{App-NtFnJR3D.js → App-EPNXLOQz.js} +118 -106
- package/dist/AuditLogs-CadZXkap.js +2013 -0
- package/dist/{Bin-DvJgE8J0.js → Bin-CEWFX1MK.js} +8 -8
- package/dist/{Broadcast-BygITJjC.js → Broadcast-DC8W46mc.js} +18 -17
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BVuhePfe.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DsojUEnT.js} +5 -6
- package/dist/{Card-BY8qbjNS.js → Card-BLFHOVL5.js} +19 -19
- package/dist/{Collections-CXZxfQmy.js → Collections-CVQV9gAI.js} +197 -185
- package/dist/{Credit-Dj4gJd18.js → Credit-Bvd1uiUU.js} +18 -17
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-eIoPtgO5.js +58 -0
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-DMHQ36PW.js +3377 -0
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-IH5P2GQ4.js → EffectSheet.vue_vue_type_style_index_0_lang-L8fftBYg.js} +105 -101
- package/dist/{Experience-CKLT-XKN.js → Experience-bKhm3DP2.js} +35 -34
- package/dist/{FileSaver.min-CqZKU_4D.js → FileSaver.min-CgnAdnBE.js} +1 -1
- package/dist/{Game-CMXXSxs7.js → Game-BTZ5Ftp5.js} +16 -15
- package/dist/Grab-DMuSoVGl.js +300 -0
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-B4u8lwM_.js → ImageInput.vue_vue_type_script_setup_true_lang-hMmCNoZI.js} +1 -1
- package/dist/{Index-CFGAKZTu.js → Index-BNh-_EZa.js} +10 -10
- package/dist/LocationPicker.vue_vue_type_script_setup_true_lang-COoygUYu.js +48 -0
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-UfQtiVK3.js → LottieAnimation.vue_vue_type_script_setup_true_lang-D0wKkrBj.js} +1 -1
- package/dist/LoyaltyDashboard-Do06Mjzo.js +1082 -0
- package/dist/{MainLayout-UCAW-wwn.js → MainLayout-C_Zu8e2b.js} +1 -1
- package/dist/{Marketing-HU2MkAbE.js → Marketing-DHTow_lX.js} +4 -4
- package/dist/{MarketingMaterialEdit-CS7hzmeA.js → MarketingMaterialEdit-BZqVEaXl.js} +214 -211
- package/dist/{Member-BG1gvC8G.js → Member-DNQICbO9.js} +20 -20
- package/dist/{MemberList-C7l5YNJF.js → MemberList-B5f-zT_3.js} +50 -51
- package/dist/{MemberTransactions-RQD9xfSN.js → MemberTransactions-BmmgHC1I.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-CcTrvGEk.js → MessageInput.vue_vue_type_script_setup_true_lang-DhlFz8So.js} +11 -11
- package/dist/{Mission-B2ynmUaz.js → Mission-CyUldhj4.js} +35 -34
- package/dist/{Overview-DI1MMGCM.js → Overview-If_YcRY8.js} +19 -19
- package/dist/{Point-DkLfnk6D.js → Point-DXgR4D2b.js} +30 -29
- package/dist/{Promotion-BDsMtw76.js → Promotion-8KrS5PGT.js} +111 -105
- package/dist/{Queue-Bu5PffRS.js → Queue-ypegp0sQ.js} +43 -43
- package/dist/{Record-C9zk5pr8.js → Record-C1eVdBIL.js} +10 -10
- package/dist/Review-fsYAsdHU.js +871 -0
- package/dist/ReviewFacebookCallback-zNKnoxr_.js +243 -0
- package/dist/ReviewGoogleCallback-CpCT0ZYL.js +213 -0
- package/dist/{Reward-DLyMbKCK.js → Reward-B_k-VLJn.js} +17 -17
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-XWcV6P7K.js → RewardGroup.vue_vue_type_script_setup_true_lang-BUl5B7lH.js} +12 -12
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-D93zAujE.js +1911 -0
- package/dist/{Segment-CkvTGYMI.js → Segment-PJLbJ6YE.js} +77 -78
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-CmoGA4QY.js → SelectItems.vue_vue_type_script_setup_true_lang-BLwf6QCO.js} +21 -21
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-D0fupqWp.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-VoddUHxA.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-CdPBhSHS.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-DOXfYdxf.js} +4 -4
- package/dist/{Setting-3aaebMiz.js → Setting-DItVUJHA.js} +259 -248
- package/dist/{SettingAdvertisements-B1rlNyFd.js → SettingAdvertisements-Bfvr60OW.js} +13 -13
- package/dist/{Store-7BnWIZ7G.js → Store-hyTJyNWv.js} +24 -24
- package/dist/{StoreRewards-CjcrPRwJ.js → StoreRewards-B7c20AF5.js} +16 -16
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-Bl438tVa.js +1130 -0
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-DBb3Zfuz.js +7007 -0
- package/dist/{Tier-BJpbCCsL.js → Tier-CuulnY8J.js} +544 -469
- package/dist/{Title-CqpbvePy.js → Title-Bf9ZiFGW.js} +93 -92
- package/dist/{Transaction-B8gpL3cS.js → Transaction-reVAaf86.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-DDoia_qu.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-BZP9jfwG.js} +6 -6
- package/dist/{Voucher-DQ6i1GyQ.js → Voucher-E8R2cCl-.js} +28 -27
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-BudfxMvl.js → VoucherEditor.vue_vue_type_script_setup_true_lang-1mclPYkp.js} +12 -12
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-B43ehs2w.js → ZodTextField.vue_vue_type_script_setup_true_lang-xP5smS4G.js} +2 -2
- package/dist/{app-Cdi9yyaa.js → app-BdRRCAGj.js} +47089 -32960
- package/dist/app.js +4 -3
- package/dist/{business-BPhMhPp8.js → business-caUtvXxX.js} +1 -1
- package/dist/{campaign-DHqBhgh5.js → campaign-CDFEhdIH.js} +13 -7
- package/dist/{campaign-DLWpOBzd.js → campaign-CPtzFxiR.js} +114 -64
- package/dist/campaign.enum-p1buII_I.js +26 -0
- package/dist/campaign.fn-DerIK7yj.js +776 -0
- package/dist/{collectible.enum-EoZwnXkR.js → collectible.enum-CJ30_XmW.js} +1 -1
- package/dist/duplicateCampaign-DLfhHm07.js +51 -0
- package/dist/effect-BJC34M9S.js +89 -0
- package/dist/{email-addresses-CuhtzvMR.js → email-addresses-D1aYCi0p.js} +2 -2
- package/dist/{export-D2wb3Zzg.js → export-ChFEuUc5.js} +3 -3
- package/dist/{helper-B80tn5O6.js → helper-BNWd3eM2.js} +1 -1
- package/dist/{timezone-BIzl2Gac.js → index-0SZADZbB.js} +21 -20
- package/dist/{index-B85ryzLj.js → index-6ZSFSZ-H.js} +769 -205
- package/dist/index-B4dazSVT.js +48 -0
- package/dist/{index-C7XyuCH8.js → index-B9xvXnEM.js} +3 -3
- package/dist/{index-Dg-VScjz.js → index-BWQK3rqq.js} +3 -3
- package/dist/{index-D1_JoBc_.js → index-BoeHTTcl.js} +1 -1
- package/dist/{index-CCfDzgJb.js → index-Br17eSOV.js} +1 -1
- package/dist/{index-HzTI8A55.js → index-CAVSuo6k.js} +1996 -1968
- package/dist/{index-B0S0BGjb.js → index-CIin0Pv0.js} +1 -1
- package/dist/{index-BVXwb1vw.js → index-CeSEAz_T.js} +1 -1
- package/dist/{index-DDLHaeVd.js → index-DNsYSxpY.js} +1539 -1267
- package/dist/index-Dcn4qaYt.js +67 -0
- package/dist/{index-DA5sHUgD.js → index-Do2cnzep.js} +1 -1
- package/dist/{index-v9zPLkiJ.js → index-Dp3CLZSg.js} +7 -7
- package/dist/{index.esm2017-CfogVJWR.js → index.esm2017-CYGo-PcK.js} +173 -173
- package/dist/{loading-_HLw0JNH.js → loading-DtPQnEA5.js} +1 -1
- package/dist/{lodash-7LLl_N0k.js → lodash-BvTKz5Pn.js} +1 -1
- package/dist/{membership-Dl34LatD.js → membership-Csnvqeql.js} +3 -3
- package/dist/{money-Ca4jlK9c.js → money-CwRxILG1.js} +1 -1
- package/dist/{number-CWjqupZw.js → number-qcECHCpu.js} +1 -1
- package/dist/object-BYyQ0PZp.js +18 -0
- package/dist/objectid-BKWyHH4F.js +145 -0
- package/dist/{plugins-uNooTC4W.js → plugins-BBpKk0ld.js} +94 -95
- package/dist/{reward-BRIYprM8.js → reward-CX1axU5-.js} +1 -1
- package/dist/{rule-CkUScWS-.js → rule-pKsATz8r.js} +505 -487
- package/dist/style.css +1 -1
- package/dist/template-BSuapoPb.js +188 -0
- package/dist/{trigger-Dd92AYz3.js → trigger-DnMktlx-.js} +5 -5
- package/dist/{useMarketingMaterialActions-DlEYiRxQ.js → useMarketingMaterialActions-Bu0-ny3z.js} +3 -3
- package/dist/{usePagination--trERWY4.js → usePagination-CzfJhepV.js} +1 -1
- package/dist/{user-CI-tPhnX.js → user-BLDWqYm_.js} +1 -1
- package/dist/vue-i18n-bssxjuw_.js +2365 -0
- package/dist/{xlsx-BtsmiXIl.js → xlsx-xNwsJDub.js} +1 -1
- package/dist/{zod-Cq4jls5y.js → zod-Cu18aMVT.js} +1 -1
- package/package.json +8 -4
- package/dist/Analytic-l10g_BkW.js +0 -426
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-Djcv8RCR.js +0 -2223
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-BW2MrhuC.js +0 -1888
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-C3mmS25r.js +0 -1118
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-TVsbx26f.js +0 -142
- package/dist/campaign.enum-C7BourYN.js +0 -20
- package/dist/campaign.fn-PjAM2LtF.js +0 -776
- package/dist/collection.fn-Ds616d3q.js +0 -26
- package/dist/dto-5fg5RWhP.js +0 -216
- package/dist/effect-BJva6Fjl.js +0 -78
- package/dist/index-CmGQazKB.js +0 -55
- package/dist/object-qECH92oz.js +0 -26
- package/dist/objectid-BGNEnJDn.js +0 -145
- package/dist/rule-builder-Ds-h-MuV.js +0 -102
- package/dist/template-0zuNVS82.js +0 -236
- package/dist/vue-i18n-BIM-SckA.js +0 -2365
|
@@ -0,0 +1,300 @@
|
|
|
1
|
+
import { defineComponent as q, ref as L, computed as z, h as J, onMounted as Q, resolveComponent as u, openBlock as f, createElementBlock as k, Fragment as F, createVNode as l, unref as i, withCtx as x, createElementVNode as m, renderList as W, createBlock as O, resolveDynamicComponent as X, toDisplayString as Y } from "vue";
|
|
2
|
+
import { _ as Z } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { useDialog as ee, components as te } from "@feedmepos/ui-library";
|
|
4
|
+
import { p as P } from "./plugins-BBpKk0ld.js";
|
|
5
|
+
import { u as oe } from "./loading-DtPQnEA5.js";
|
|
6
|
+
import { u as ne } from "./business-caUtvXxX.js";
|
|
7
|
+
import { u as ae, c as C } from "./campaign-CDFEhdIH.js";
|
|
8
|
+
import { u as se } from "./vue-i18n-bssxjuw_.js";
|
|
9
|
+
import { h as d } from "./moment-D7p2TMB-.js";
|
|
10
|
+
import { a as re, b as V } from "./campaign-CPtzFxiR.js";
|
|
11
|
+
import { s as ie, _ as ce } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-DMHQ36PW.js";
|
|
12
|
+
import { u as le } from "./template-BSuapoPb.js";
|
|
13
|
+
import { _ as $ } from "./FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js";
|
|
14
|
+
const me = { class: "px-24 flex flex-col gap-y-16" }, ue = { class: "flex items-center justify-between w-full" }, de = { class: "flex gap-8 overflow-x-auto" }, pe = { class: "space-y-8" }, fe = { class: "flex w-full gap-4 items-center" }, ge = { class: "flex flex-col gap-16 text-center" }, ye = { class: "fm-typo-en-title-sm-800" }, be = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye = /* @__PURE__ */ q({
|
|
15
|
+
__name: "Grab",
|
|
16
|
+
setup(_e) {
|
|
17
|
+
const { t: o } = se(), I = {
|
|
18
|
+
label: o("connect.grab.createCampaign"),
|
|
19
|
+
value: "create",
|
|
20
|
+
isPrimary: !0,
|
|
21
|
+
prependIcon: "add"
|
|
22
|
+
}, A = le("GRAB", ee()), S = ne(), g = ae(), { global: R, minor: T } = oe, K = [
|
|
23
|
+
{
|
|
24
|
+
label: "Bill promotion",
|
|
25
|
+
value: "BILL"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
label: "Item promotion",
|
|
29
|
+
value: "ITEM"
|
|
30
|
+
}
|
|
31
|
+
], c = L({
|
|
32
|
+
searchKey: "",
|
|
33
|
+
location: [],
|
|
34
|
+
effectType: []
|
|
35
|
+
});
|
|
36
|
+
function E(e) {
|
|
37
|
+
const t = c.value.location;
|
|
38
|
+
return !t || t.length === 0 || !e.targetLocation ? !0 : Array.isArray(t) ? t.some((a) => {
|
|
39
|
+
var r;
|
|
40
|
+
return (r = e == null ? void 0 : e.targetLocation) == null ? void 0 : r.includes(a);
|
|
41
|
+
}) : e.targetLocation.includes(t);
|
|
42
|
+
}
|
|
43
|
+
function j(e) {
|
|
44
|
+
var r, s;
|
|
45
|
+
const t = c.value.effectType;
|
|
46
|
+
if (!t || t.length === 0) return !0;
|
|
47
|
+
const a = (s = (r = e.effect) == null ? void 0 : r.options) == null ? void 0 : s.target;
|
|
48
|
+
return t.includes(a);
|
|
49
|
+
}
|
|
50
|
+
const p = z(
|
|
51
|
+
() => g.campaigns.grab.filter(
|
|
52
|
+
(e) => E(e) && j(e)
|
|
53
|
+
)
|
|
54
|
+
), G = [
|
|
55
|
+
{
|
|
56
|
+
header: o("connect.grab.promotionTitle"),
|
|
57
|
+
accessorFn: (e) => e.name
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
header: o("connect.grab.period"),
|
|
61
|
+
accessorFn: (e) => {
|
|
62
|
+
const t = d(e.timeframeOptions.start).format("DD/MM/YYYY"), a = d(e.timeframeOptions.end).format("DD/MM/YYYY");
|
|
63
|
+
return `${t} - ${a}`;
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
header: o("connect.grab.status"),
|
|
68
|
+
accessorFn: (e) => re(e),
|
|
69
|
+
cell(e) {
|
|
70
|
+
return V(e.row.original);
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
header: o("connect.grab.summary"),
|
|
75
|
+
cell(e) {
|
|
76
|
+
const t = ie(e.row.original.discount);
|
|
77
|
+
return t ? `${t.type} - ${t.adjustment}` : "-";
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
header: o("connect.grab.actions"),
|
|
82
|
+
cell(e) {
|
|
83
|
+
return J(te.FmButton, {
|
|
84
|
+
variant: "tertiary",
|
|
85
|
+
icon: "delete",
|
|
86
|
+
iconColor: "neutral-gray-400",
|
|
87
|
+
onClick: (t) => {
|
|
88
|
+
t.stopPropagation(), D(e.row.original);
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
], B = L();
|
|
94
|
+
async function D(e) {
|
|
95
|
+
await P.remove(o("connect.grab.confirmRemove", { name: e.name })) && await T(
|
|
96
|
+
async () => {
|
|
97
|
+
await C.delete(e._id), await g.read("PROMOTION");
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
message: o("connect.grab.removing", { name: e.name }),
|
|
101
|
+
successMessage: o("connect.grab.removedSuccessfully", {
|
|
102
|
+
name: e.name
|
|
103
|
+
})
|
|
104
|
+
}
|
|
105
|
+
);
|
|
106
|
+
}
|
|
107
|
+
async function b(e) {
|
|
108
|
+
e ? await t() : A.open(async (a) => {
|
|
109
|
+
await t(a);
|
|
110
|
+
});
|
|
111
|
+
async function t(a) {
|
|
112
|
+
var r;
|
|
113
|
+
(r = B.value) == null || r.showSheet(
|
|
114
|
+
!0,
|
|
115
|
+
"GRAB",
|
|
116
|
+
e ? await C.readById(e._id) : void 0,
|
|
117
|
+
a
|
|
118
|
+
);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
async function N(e) {
|
|
122
|
+
var a;
|
|
123
|
+
const t = await U(e.campaign);
|
|
124
|
+
if (t.length > 0) {
|
|
125
|
+
const r = t.map(
|
|
126
|
+
(s) => `"${s.name}" (${d(s.timeframeOptions.start).format("DD/MM/YYYY")} - ${d(s.timeframeOptions.end).format("DD/MM/YYYY")})`
|
|
127
|
+
).join(`
|
|
128
|
+
`);
|
|
129
|
+
return await ((a = P.dialog) == null ? void 0 : a.open({
|
|
130
|
+
title: o("connect.grab.conflictDetected"),
|
|
131
|
+
message: o("connect.grab.conflictMessage", {
|
|
132
|
+
conflicts: r
|
|
133
|
+
}),
|
|
134
|
+
closeButton: !0,
|
|
135
|
+
overlay: !0,
|
|
136
|
+
primaryActions: {
|
|
137
|
+
close: !0,
|
|
138
|
+
text: "OK"
|
|
139
|
+
}
|
|
140
|
+
})), !1;
|
|
141
|
+
}
|
|
142
|
+
await T(
|
|
143
|
+
async () => (e.campaign._id ? await C.update(e.campaign._id, e) : await C.create(e), await g.read("PROMOTION"), !0),
|
|
144
|
+
{
|
|
145
|
+
message: o(
|
|
146
|
+
e.campaign._id ? "connect.grab.updating" : "connect.grab.creating"
|
|
147
|
+
),
|
|
148
|
+
successMessage: o(
|
|
149
|
+
e.campaign._id ? "connect.grab.updatedSuccessfully" : "connect.grab.createdSuccessfully"
|
|
150
|
+
)
|
|
151
|
+
}
|
|
152
|
+
);
|
|
153
|
+
}
|
|
154
|
+
async function U(e) {
|
|
155
|
+
const t = g.campaigns.grab, a = [], r = !!e._id;
|
|
156
|
+
for (const s of t) {
|
|
157
|
+
if (r && s._id === e._id) continue;
|
|
158
|
+
const _ = d(e.timeframeOptions.start), y = d(e.timeframeOptions.end), h = d(s.timeframeOptions.start), v = d(s.timeframeOptions.end);
|
|
159
|
+
if (_.isBefore(v) && y.isAfter(h) || h.isBefore(y) && v.isAfter(_)) {
|
|
160
|
+
const n = e.discount, w = s.discount;
|
|
161
|
+
n.scope.type === w.scope.type && a.push(s);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
return a;
|
|
165
|
+
}
|
|
166
|
+
async function H(e) {
|
|
167
|
+
switch (e) {
|
|
168
|
+
case "create":
|
|
169
|
+
b();
|
|
170
|
+
break;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
return Q(async () => {
|
|
174
|
+
await R(async () => {
|
|
175
|
+
await S.readLocations(), await g.read("PROMOTION");
|
|
176
|
+
});
|
|
177
|
+
}), (e, t) => {
|
|
178
|
+
const a = u("FmPill"), r = u("FmPageHead"), s = u("FmSearch"), _ = u("FmTable"), y = u("FmButton"), h = u("FmListItem"), v = u("FmList"), M = u("FmCard");
|
|
179
|
+
return f(), k(F, null, [
|
|
180
|
+
l(r, {
|
|
181
|
+
title: i(o)("connect.grab.title"),
|
|
182
|
+
actions: i(p).length > 0 ? [I] : [],
|
|
183
|
+
"onClick:action": H
|
|
184
|
+
}, {
|
|
185
|
+
prepend: x(() => [
|
|
186
|
+
l(a, { variant: "beta" }),
|
|
187
|
+
l(a, { variant: "premium" })
|
|
188
|
+
]),
|
|
189
|
+
_: 1
|
|
190
|
+
}, 8, ["title", "actions"]),
|
|
191
|
+
m("div", me, [
|
|
192
|
+
l(s, {
|
|
193
|
+
modelValue: c.value.searchKey,
|
|
194
|
+
"onUpdate:modelValue": t[0] || (t[0] = (n) => c.value.searchKey = n),
|
|
195
|
+
class: "hidden xs:block border-b-2 border-fm-color-neutral-gray-100",
|
|
196
|
+
placeholder: i(o)("connect.grab.search"),
|
|
197
|
+
collapsible: ""
|
|
198
|
+
}, null, 8, ["modelValue", "placeholder"]),
|
|
199
|
+
i(p) && i(p).length > 0 ? (f(), k(F, { key: 0 }, [
|
|
200
|
+
m("div", ue, [
|
|
201
|
+
m("div", de, [
|
|
202
|
+
l($, {
|
|
203
|
+
label: `${i(o)("connect.common.location")}: `,
|
|
204
|
+
"right-icon": "keyboard_arrow_down",
|
|
205
|
+
modelValue: c.value.location,
|
|
206
|
+
"onUpdate:modelValue": t[1] || (t[1] = (n) => c.value.location = n),
|
|
207
|
+
icon: "storefront",
|
|
208
|
+
"show-item-label": !0,
|
|
209
|
+
items: i(S).locationOptions
|
|
210
|
+
}, null, 8, ["label", "modelValue", "items"]),
|
|
211
|
+
l($, {
|
|
212
|
+
label: "Type:",
|
|
213
|
+
"right-icon": "keyboard_arrow_down",
|
|
214
|
+
modelValue: c.value.effectType,
|
|
215
|
+
"onUpdate:modelValue": t[2] || (t[2] = (n) => c.value.effectType = n),
|
|
216
|
+
icon: "filter_list",
|
|
217
|
+
"show-item-label": !0,
|
|
218
|
+
items: K
|
|
219
|
+
}, null, 8, ["modelValue"])
|
|
220
|
+
]),
|
|
221
|
+
l(s, {
|
|
222
|
+
modelValue: c.value.searchKey,
|
|
223
|
+
"onUpdate:modelValue": t[3] || (t[3] = (n) => c.value.searchKey = n),
|
|
224
|
+
class: "xs:hidden",
|
|
225
|
+
placeholder: "search",
|
|
226
|
+
collapsible: ""
|
|
227
|
+
}, null, 8, ["modelValue"])
|
|
228
|
+
]),
|
|
229
|
+
l(_, {
|
|
230
|
+
class: "xs:hidden",
|
|
231
|
+
"row-data": i(p),
|
|
232
|
+
"column-defs": G,
|
|
233
|
+
"search-value": c.value.searchKey,
|
|
234
|
+
"column-filter": [],
|
|
235
|
+
onRowClick: t[4] || (t[4] = (n) => b(n.original)),
|
|
236
|
+
"hide-footer": i(p).length < 10
|
|
237
|
+
}, null, 8, ["row-data", "search-value", "hide-footer"]),
|
|
238
|
+
l(v, { class: "hidden xs:flex flex-col mx-[-24px]" }, {
|
|
239
|
+
default: x(() => [
|
|
240
|
+
(f(!0), k(F, null, W(i(p).filter(
|
|
241
|
+
(n) => n.name.toLowerCase().includes(c.value.searchKey.toLowerCase())
|
|
242
|
+
), (n) => (f(), O(h, {
|
|
243
|
+
key: n._id.toString(),
|
|
244
|
+
onClick: (w) => b(n),
|
|
245
|
+
class: "py-12 px-16 flex items-center justify-between border-b border-fm-color-neutral-gray-100"
|
|
246
|
+
}, {
|
|
247
|
+
default: x(() => [
|
|
248
|
+
m("div", pe, [
|
|
249
|
+
m("div", fe, [
|
|
250
|
+
(f(), O(X(i(V)(n))))
|
|
251
|
+
])
|
|
252
|
+
]),
|
|
253
|
+
l(y, {
|
|
254
|
+
icon: "delete",
|
|
255
|
+
"icon-color": "neutral-gray-400",
|
|
256
|
+
variant: "tertiary",
|
|
257
|
+
onClick: (w) => (w.stopPropagation(), D(n))
|
|
258
|
+
}, null, 8, ["onClick"])
|
|
259
|
+
]),
|
|
260
|
+
_: 2
|
|
261
|
+
}, 1032, ["onClick"]))), 128))
|
|
262
|
+
]),
|
|
263
|
+
_: 1
|
|
264
|
+
})
|
|
265
|
+
], 64)) : (f(), O(M, {
|
|
266
|
+
key: 1,
|
|
267
|
+
variant: "outlined",
|
|
268
|
+
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
269
|
+
}, {
|
|
270
|
+
default: x(() => [
|
|
271
|
+
t[6] || (t[6] = m("img", {
|
|
272
|
+
src: Z,
|
|
273
|
+
class: "aspect-square w-[150px]"
|
|
274
|
+
}, null, -1)),
|
|
275
|
+
m("div", ge, [
|
|
276
|
+
m("div", ye, Y(i(o)("connect.grab.createPromotionCampaign")), 1),
|
|
277
|
+
m("div", be, Y(i(o)("connect.grab.description")), 1)
|
|
278
|
+
]),
|
|
279
|
+
l(y, {
|
|
280
|
+
variant: "primary",
|
|
281
|
+
label: i(o)("connect.grab.createPromotionCampaign"),
|
|
282
|
+
icon: "add",
|
|
283
|
+
onClick: t[5] || (t[5] = (n) => b())
|
|
284
|
+
}, null, 8, ["label"])
|
|
285
|
+
]),
|
|
286
|
+
_: 1
|
|
287
|
+
}))
|
|
288
|
+
]),
|
|
289
|
+
l(ce, {
|
|
290
|
+
ref_key: "sheetRef",
|
|
291
|
+
ref: B,
|
|
292
|
+
"onSubmit:modelValue": N
|
|
293
|
+
}, null, 512)
|
|
294
|
+
], 64);
|
|
295
|
+
};
|
|
296
|
+
}
|
|
297
|
+
});
|
|
298
|
+
export {
|
|
299
|
+
Ye as default
|
|
300
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { openBlock as l, createElementBlock as o, createElementVNode as r, defineComponent as $, ref as b, onMounted as I, resolveComponent as f, renderSlot as x, toDisplayString as s, createCommentVNode as h, normalizeStyle as V, unref as i, Fragment as w, createVNode as F, withCtx as g, createTextVNode as p, normalizeClass as z, createBlock as k } from "vue";
|
|
2
|
-
import { u as R } from "./vue-i18n-
|
|
2
|
+
import { u as R } from "./vue-i18n-bssxjuw_.js";
|
|
3
3
|
import { _ as H } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
4
|
const N = {}, D = { class: "animate-pulse flex space-x-4 bg-gray-300 dark:bg-gray-700 items-center justify-center rounded w-full h-full" };
|
|
5
5
|
function L(e, d) {
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { defineComponent as U, ref as g, watch as O, onMounted as I, resolveComponent as m, openBlock as b, createBlock as j, withCtx as P, createTextVNode as z, toDisplayString as B, createElementVNode as c, createVNode as o, unref as e, createElementBlock as F, createCommentVNode as W, normalizeClass as G, computed as L, Fragment as q, isRef as J } from "vue";
|
|
2
|
-
import { u as H } from "./vue-i18n-
|
|
3
|
-
import "./index-
|
|
2
|
+
import { u as H } from "./vue-i18n-bssxjuw_.js";
|
|
3
|
+
import "./index-Br17eSOV.js";
|
|
4
4
|
import { useRouter as K } from "vue-router";
|
|
5
|
-
import { u as Q } from "./loading-
|
|
6
|
-
import { f as V, p as X } from "./plugins-
|
|
7
|
-
import { u as Y, _ as Z } from "./RewardGroup.vue_vue_type_script_setup_true_lang-
|
|
5
|
+
import { u as Q } from "./loading-DtPQnEA5.js";
|
|
6
|
+
import { f as V, p as X } from "./plugins-BBpKk0ld.js";
|
|
7
|
+
import { u as Y, _ as Z } from "./RewardGroup.vue_vue_type_script_setup_true_lang-BUl5B7lH.js";
|
|
8
8
|
import { useDialog as ee, useSnackbar as ne, FmButtonVariant as p } from "@feedmepos/ui-library";
|
|
9
|
-
import { r as N } from "./index-
|
|
10
|
-
import { u as ae } from "./reward-
|
|
11
|
-
import { u as oe } from "./business-
|
|
12
|
-
import { u as te } from "./membership-
|
|
13
|
-
import { R as $ } from "./app-
|
|
9
|
+
import { r as N } from "./index-Do2cnzep.js";
|
|
10
|
+
import { u as ae } from "./reward-CX1axU5-.js";
|
|
11
|
+
import { u as oe } from "./business-caUtvXxX.js";
|
|
12
|
+
import { u as te } from "./membership-Csnvqeql.js";
|
|
13
|
+
import { R as $ } from "./app-BdRRCAGj.js";
|
|
14
14
|
const re = { class: "space-y-24" }, le = {
|
|
15
15
|
key: 0,
|
|
16
16
|
class: /* @__PURE__ */ G([
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { defineComponent as g, openBlock as t, createElementBlock as o, createElementVNode as i, toDisplayString as r, unref as c, createCommentVNode as m, Fragment as y, renderList as _, normalizeClass as d, createVNode as b } from "vue";
|
|
2
|
+
import { u as x } from "./vue-i18n-bssxjuw_.js";
|
|
3
|
+
import { components as h } from "@feedmepos/ui-library";
|
|
4
|
+
const k = { class: "border-t border-fm-color-neutral-gray-200 bg-fm-color-neutral-gray-50 p-12 flex flex-col gap-8" }, v = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-500 px-4" }, S = {
|
|
5
|
+
key: 0,
|
|
6
|
+
class: "fm-typo-en-body-sm-400 text-fm-color-neutral-gray-400 px-4 py-8"
|
|
7
|
+
}, C = ["onClick"], I = { class: "fm-typo-en-body-md-400 flex-1 truncate" }, L = {
|
|
8
|
+
key: 0,
|
|
9
|
+
class: "fm-typo-en-body-sm-400 text-fm-color-neutral-gray-400 shrink-0"
|
|
10
|
+
}, F = /* @__PURE__ */ g({
|
|
11
|
+
__name: "LocationPicker",
|
|
12
|
+
props: {
|
|
13
|
+
locations: {},
|
|
14
|
+
selectedIds: {}
|
|
15
|
+
},
|
|
16
|
+
emits: ["toggle"],
|
|
17
|
+
setup(n, { emit: p }) {
|
|
18
|
+
const f = n, { t: a } = x(), u = p;
|
|
19
|
+
function s(l) {
|
|
20
|
+
return f.selectedIds.includes(l);
|
|
21
|
+
}
|
|
22
|
+
return (l, w) => (t(), o("div", k, [
|
|
23
|
+
i("p", v, r(c(a)("connect.review.selectLocations")), 1),
|
|
24
|
+
n.locations.length === 0 ? (t(), o("p", S, r(c(a)("connect.review.noAvailableLocations")), 1)) : m("", !0),
|
|
25
|
+
(t(!0), o(y, null, _(n.locations, (e) => (t(), o("button", {
|
|
26
|
+
key: e._id.toString(),
|
|
27
|
+
class: d([
|
|
28
|
+
"flex items-center gap-12 p-12 rounded-lg bg-white border text-left transition-colors",
|
|
29
|
+
s(e._id.toString()) ? "border-fm-color-primary-500 bg-fm-color-primary-50" : "border-fm-color-neutral-gray-200 hover:border-fm-color-primary-300"
|
|
30
|
+
]),
|
|
31
|
+
onClick: (N) => u("toggle", e)
|
|
32
|
+
}, [
|
|
33
|
+
b(c(h).FmIcon, {
|
|
34
|
+
name: s(e._id.toString()) ? "check_box" : "check_box_outline_blank",
|
|
35
|
+
class: d([
|
|
36
|
+
s(e._id.toString()) ? "text-fm-color-primary-500" : "text-fm-color-neutral-gray-300",
|
|
37
|
+
"shrink-0"
|
|
38
|
+
])
|
|
39
|
+
}, null, 8, ["name", "class"]),
|
|
40
|
+
i("span", I, r(e.name), 1),
|
|
41
|
+
e.code ? (t(), o("span", L, r(e.code), 1)) : m("", !0)
|
|
42
|
+
], 10, C))), 128))
|
|
43
|
+
]));
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
export {
|
|
47
|
+
F as _
|
|
48
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, ref, watchEffect, computed, watch, openBlock, createElementBlock, normalizeStyle, onBeforeUnmount, resolveComponent, unref, createBlock } from "vue";
|
|
2
|
-
import { c as commonjsGlobal, g as getDefaultExportFromCjs } from "./app-
|
|
2
|
+
import { c as commonjsGlobal, g as getDefaultExportFromCjs } from "./app-BdRRCAGj.js";
|
|
3
3
|
const v = "4.8.0", meta = {
|
|
4
4
|
g: "LottieFiles AE ",
|
|
5
5
|
a: "",
|