@feedmepos/mf-connect 0.1.104-prod → 0.1.105-prod
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-B4UWz7ir.js → App-Bb5yBnOB.js} +10 -9
- package/dist/{Bin-D_eSutW-.js → Bin-DXIYjMm_.js} +8 -8
- package/dist/{Broadcast-DDQE_RLR.js → Broadcast-BpcvdGj_.js} +11 -11
- package/dist/CampaignAnalytic-BDqEZmHy.js +1830 -0
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-D2cTNgaS.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BBiIrN0a.js} +6 -6
- package/dist/{Card-CPozdg3m.js → Card-D2sggPws.js} +19 -19
- package/dist/{Collections-IrwF5bWH.js → Collections-BdZU2wR5.js} +9 -9
- package/dist/{Credit-BVXpy5tw.js → Credit-DeDCjtcp.js} +118 -93
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-DEwMzs6L.js +53 -0
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-CCe1rp0f.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-DbukUBK2.js} +815 -609
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-DwP64fmL.js → EffectSheet.vue_vue_type_style_index_0_lang-BNOrfkpI.js} +12 -12
- package/dist/{Experience-BR1JXdH5.js → Experience-CT_3fZPR.js} +109 -84
- package/dist/{FileSaver.min-CX-3gU49.js → FileSaver.min-C3sYNQw3.js} +1 -1
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-3bH-tZAm.js +138 -0
- package/dist/Game-C4v96zEu.js +355 -0
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-q5fF5d7d.js → ImageInput.vue_vue_type_script_setup_true_lang-6PmRI47X.js} +1 -1
- package/dist/{Index--Xl_8CFP.js → Index-C5DRA08U.js} +10 -10
- package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-C-xW5Tw8.js → LocationPicker.vue_vue_type_script_setup_true_lang-BXcpCtHI.js} +1 -1
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-DGVqQz1j.js → LottieAnimation.vue_vue_type_script_setup_true_lang-C8dm05l2.js} +1 -1
- package/dist/LoyaltyDashboard-BCPojLdm.js +2865 -0
- package/dist/{MainLayout-DB_Y2C3K.js → MainLayout-p92jJ4Mp.js} +3 -3
- package/dist/{Marketing-CjAGzfL7.js → Marketing-Z-TiSgs6.js} +4 -4
- package/dist/{MarketingMaterialEdit-BoF6kTOz.js → MarketingMaterialEdit-CS-hcbGU.js} +6 -6
- package/dist/{Member-DnypOK2I.js → Member-DwY0tXwr.js} +7 -7
- package/dist/MemberDetailSheet.vue_vue_type_script_setup_true_lang-DDSBw1sL.js +1286 -0
- package/dist/{MemberImportHistory-BJSyT6Ys.js → MemberImportHistory-BN85ZxpX.js} +8 -8
- package/dist/MemberList-DaIJCa_0.js +336 -0
- package/dist/{MemberTransactions-CbPxUrtd.js → MemberTransactions-DrgA6jX1.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-CVzfjs9D.js → MessageInput.vue_vue_type_script_setup_true_lang-rl8Sr_zl.js} +11 -11
- package/dist/MetricInfoTooltip.vue_vue_type_script_setup_true_lang-lGB6WCj6.js +40 -0
- package/dist/Mission-BFBmJTjP.js +359 -0
- package/dist/{Overview-BW2_y1_7.js → Overview-DaZA6Oxr.js} +5 -5
- package/dist/{Overview-DZxRuA5F.js → Overview-DtiqH8iJ.js} +19 -19
- package/dist/Point-DeaTc_Gj.js +287 -0
- package/dist/Promotion-BBIylJxt.js +417 -0
- package/dist/{Queue-CSF9M_Lc.js → Queue-WsDiZkdN.js} +11 -11
- package/dist/{Record-B-HdI5A4.js → Record-CzD7sYYG.js} +10 -10
- package/dist/{Review-D6RQbcP6.js → Review-BkPHrt33.js} +2 -2
- package/dist/{ReviewFacebookCallback-CkULwhF-.js → ReviewFacebookCallback-Bu8j9CLF.js} +5 -5
- package/dist/{ReviewGoogleCallback-DgPEXV_R.js → ReviewGoogleCallback-Bh3R06MN.js} +5 -5
- package/dist/{Reward-CZvM6GQ9.js → Reward-BHe9y1VN.js} +17 -17
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-C1y2_pHY.js → RewardGroup.vue_vue_type_script_setup_true_lang-DVNknaoM.js} +12 -12
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-Cvo6a7Nw.js → RuleGroup.vue_vue_type_script_setup_true_lang-DAXfiO8F.js} +279 -286
- package/dist/{Segment-D2bXEF1U.js → Segment-CjaPWdMt.js} +24 -24
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-Ytimazjg.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-srMHsTa6.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-Bn1IWAd_.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-C5taZCvV.js} +4 -4
- package/dist/{Setting-DelduRrh.js → Setting-Dr_lawoc.js} +57 -57
- package/dist/{SettingAdvertisements-gTDg1C60.js → SettingAdvertisements-BXJd1btw.js} +13 -13
- package/dist/{Settings-VUEo9wwx.js → Settings-DPJq4qbw.js} +5 -5
- package/dist/{Store-CXQZirbg.js → Store-BNq7oK2B.js} +22 -22
- package/dist/{StoreRewards-BDuZPA8S.js → StoreRewards-WExx61kV.js} +16 -16
- package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-C-yqZEn4.js → StoreTransactions.vue_vue_type_script_setup_true_lang-BaqyPTXc.js} +327 -386
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-BayrgH7m.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-CnCHFZL3.js} +2 -2
- package/dist/{Tier-DtPE4IJ5.js → Tier-BSLPHzsj.js} +102 -102
- package/dist/{Title-DNCnQeeR.js → Title-BQ_CVnIN.js} +22 -22
- package/dist/{Transaction-BkUaCGwl.js → Transaction-CvyyRq8P.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-B7TY_AGp.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-ByHFu7ry.js} +6 -6
- package/dist/{Voucher-BBuB9tf8.js → Voucher-DQ-yXZAC.js} +143 -121
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-Bu09bIut.js → VoucherEditor.vue_vue_type_script_setup_true_lang-BB0n73WF.js} +115 -121
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-BSKpAMJL.js → ZodTextField.vue_vue_type_script_setup_true_lang-nnWYrHgL.js} +2 -2
- package/dist/{app-CSLQmdYA.js → app-BxM9Ghdm.js} +27795 -25657
- package/dist/app.js +1 -1
- package/dist/{business-okSb42At.js → business-nbLS8l9h.js} +1 -1
- package/dist/{campaign-V7nlCdxR.js → campaign-C_IR2u8a.js} +49 -48
- package/dist/{campaign-Ck9GwZdI.js → campaign-Ki9WAmYl.js} +2 -2
- package/dist/{campaign.enum-BQ5khvqI.js → campaign.enum-CtgtWycO.js} +1 -1
- package/dist/{campaign.fn-DMDpxVSZ.js → campaign.fn-CJOfTzI6.js} +32 -32
- package/dist/{collectible.enum-lKz3vTQM.js → collectible.enum-a5dfnH3M.js} +1 -1
- package/dist/{collection.fn-BH5cqMNy.js → collection.fn-Cc-luweq.js} +2 -2
- package/dist/{effect-pUpfqkCF.js → effect-D66eImId.js} +1 -1
- package/dist/{email-addresses-CzBv1fzv.js → email-addresses-DNHwCrI5.js} +2 -2
- package/dist/{export-Du7ZAv-8.js → export-Bp-Fwp-h.js} +3 -3
- package/dist/{helper-BpthZPU4.js → helper-BpHRMtgf.js} +1 -1
- package/dist/{index-DSltrIkA.js → index-B8cXkkGF.js} +1 -1
- package/dist/{timezone-DYWqfGTu.js → index-BPV5Dkjl.js} +105 -122
- package/dist/{index-D7PksEV2.js → index-BdqanLnJ.js} +675 -677
- package/dist/{index-CWAdNVKN.js → index-BnH5UiZx.js} +6 -6
- package/dist/{index-v8QQ-4ZP.js → index-C1Bp0PPS.js} +10 -10
- package/dist/{index-BhuD1NhH.js → index-CA5atWo4.js} +1 -1
- package/dist/{index-ZTYDfSkT.js → index-CZ-SWULS.js} +4 -5
- package/dist/{index-CGK1kSCt.js → index-DB13tnmJ.js} +3 -3
- package/dist/{index-C0JgU0Z2.js → index-DFLwgFnq.js} +1 -1
- package/dist/{index-DCp9k5BB.js → index-DVcOSnAP.js} +2 -2
- package/dist/{index-DNdHiAXR.js → index-Dj3FzUo_.js} +18 -2
- package/dist/{index-CN5Zoynf.js → index-DyllcNwd.js} +2 -2
- package/dist/{index-OaZRtKP_.js → index-JU7Ed3Ex.js} +5 -5
- package/dist/{index--6uUWSMc.js → index-Oeiw4Epg.js} +1 -1
- package/dist/{index-izVlVA8-.js → index-VzLsGqcm.js} +1 -1
- package/dist/{index-DPgGmpyL.js → index-nUrA9Q7e.js} +9 -9
- package/dist/{index.esm2017-mpnkyDRb.js → index.esm2017-32NtkXiv.js} +34 -34
- package/dist/{loading-BG3Pj6qz.js → loading-CLZ5IFPe.js} +1 -1
- package/dist/{lodash-BfDdt-c9.js → lodash-k98YPjFm.js} +1 -1
- package/dist/{member-import-BNFdZ3Df.js → member-import-CxNPNPh5.js} +1 -1
- package/dist/membership-CjqXHl0l.js +274 -0
- package/dist/{money-CRftC-F0.js → money-zJomyMyN.js} +1 -1
- package/dist/{number-z7YZyGFS.js → number-BfHmokvl.js} +1 -1
- package/dist/object-BYyQ0PZp.js +18 -0
- package/dist/{objectid-BKMqp_oR.js → objectid-g-s-CuBk.js} +6 -6
- package/dist/{plugins-CWeDGuzy.js → plugins-DNZv50xL.js} +87 -87
- package/dist/{reward-BVTKTGi6.js → reward-BefNUdd_.js} +1 -1
- package/dist/{rule-YhhCOals.js → rule-DkLIl8GM.js} +3 -3
- package/dist/{rule-builder-ae8A0qoi.js → rule-builder-BVyNMiE8.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{template-CQrM_0hz.js → template-BmSOVHcp.js} +7 -7
- package/dist/timezone-DoX-vj_6.js +20 -0
- package/dist/transaction.fn-D15eS4nB.js +64 -0
- package/dist/{trigger-Clo3vSjw.js → trigger-BhReH6kZ.js} +5 -5
- package/dist/{useMarketingMaterialActions-HyqIT94N.js → useMarketingMaterialActions-DdcVqSlV.js} +3 -3
- package/dist/{usePagination-CWRrkbFL.js → usePagination-rx2JFS-5.js} +1 -1
- package/dist/{user-MVk5s412.js → user-B4gZia2L.js} +1 -1
- package/dist/{vue-i18n-BN9KLJoz.js → vue-i18n-JLM70-gr.js} +201 -201
- package/dist/{xlsx-s0BxKsa_.js → xlsx-CuKZcLfT.js} +440 -440
- package/dist/{zod-H4l78-by.js → zod-ByE_90T4.js} +1 -1
- package/package.json +3 -4
- package/dist/Analytic-1rqyus1X.js +0 -428
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-eIoPtgO5.js +0 -58
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js +0 -129
- package/dist/Game-8nvdSkbi.js +0 -330
- package/dist/MemberList-Bf_XyoxW.js +0 -1602
- package/dist/Mission-DE4O6XM6.js +0 -334
- package/dist/Point-BMEe6duo.js +0 -262
- package/dist/Promotion-lamxp48U.js +0 -392
- package/dist/SelectItems.vue_vue_type_script_setup_true_lang-BxOEEr9-.js +0 -181
- package/dist/dto-GksE6pni.js +0 -216
- package/dist/membership-tNeaKAeS.js +0 -255
- package/dist/object-qECH92oz.js +0 -26
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { _ as
|
|
3
|
-
import { useDialog as
|
|
4
|
-
import { _ as
|
|
5
|
-
import { c as
|
|
6
|
-
import { useCoreStore as
|
|
7
|
-
import { u as
|
|
8
|
-
import { u as
|
|
9
|
-
import { u as
|
|
10
|
-
import { g as
|
|
11
|
-
import { c as
|
|
12
|
-
import "./index
|
|
13
|
-
import { _ as
|
|
14
|
-
import { _ as
|
|
15
|
-
import { u as
|
|
16
|
-
import { T as
|
|
17
|
-
import { useRouter as
|
|
18
|
-
import { c as v } from "./index-
|
|
19
|
-
import { R as
|
|
20
|
-
var
|
|
21
|
-
const
|
|
1
|
+
import { defineComponent as ne, ref as T, computed as ae, h as m, onMounted as re, resolveComponent as f, openBlock as d, createElementBlock as P, Fragment as R, createVNode as s, unref as t, createElementVNode as c, withCtx as I, renderList as ce, createBlock as g, resolveDynamicComponent as ie, createCommentVNode as L, toDisplayString as _ } from "vue";
|
|
2
|
+
import { _ as se } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { useDialog as le, components as p } from "@feedmepos/ui-library";
|
|
4
|
+
import { _ as N } from "./FilterChip.vue_vue_type_script_setup_true_lang-3bH-tZAm.js";
|
|
5
|
+
import { c as me, p as ue } from "./plugins-DNZv50xL.js";
|
|
6
|
+
import { useCoreStore as de } from "@feedmepos/mf-common";
|
|
7
|
+
import { u as pe } from "./loading-CLZ5IFPe.js";
|
|
8
|
+
import { u as fe } from "./business-nbLS8l9h.js";
|
|
9
|
+
import { u as ye } from "./campaign-Ki9WAmYl.js";
|
|
10
|
+
import { g as he, a as D, b as K } from "./campaign-C_IR2u8a.js";
|
|
11
|
+
import { c as ge, p as _e, u as ve } from "./template-BmSOVHcp.js";
|
|
12
|
+
import "./index-Oeiw4Epg.js";
|
|
13
|
+
import { _ as Ce } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-DbukUBK2.js";
|
|
14
|
+
import { _ as we } from "./SendVoucherSheet.vue_vue_type_script_setup_true_lang-C5taZCvV.js";
|
|
15
|
+
import { u as be } from "./vue-i18n-JLM70-gr.js";
|
|
16
|
+
import { T as ke } from "./trigger-BhReH6kZ.js";
|
|
17
|
+
import { useRouter as xe } from "vue-router";
|
|
18
|
+
import { c as v } from "./index-Dj3FzUo_.js";
|
|
19
|
+
import { R as A } from "./app-BxM9Ghdm.js";
|
|
20
|
+
var Fe = { authUrl: "https://portal-v2.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedme.cc", crmUrl: "crm.feedme.cc", paymentPortalUrl: "https://portal.feedme.cc/payment/payout-account", licensePortalUrl: "https://license.feedme.cc/", marketingV1Portal: "https://marketing-v1.feedme.cc", voucherAppUrl: "https://voucher.feedme.cc/" };
|
|
21
|
+
const Ve = { class: "px-24 flex flex-col gap-y-16" }, Se = { class: "flex items-center justify-between w-full" }, Ue = { class: "flex gap-8 overflow-x-auto" }, Te = { class: "space-y-8" }, Pe = { class: "flex w-full gap-4 items-center" }, Re = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ie = { class: "space-y-4" }, Le = { class: "fm-typo-en-body-lg-600" }, Ae = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ee = { class: "flex gap-8 items-center" }, Be = { class: "flex flex-col gap-16 text-center" }, Oe = { class: "fm-typo-en-title-sm-800" }, Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ro = /* @__PURE__ */ ne({
|
|
22
22
|
__name: "Voucher",
|
|
23
|
-
setup(
|
|
24
|
-
const { t: a } =
|
|
23
|
+
setup(He) {
|
|
24
|
+
const { t: a } = be(), j = {
|
|
25
25
|
label: a("connect.voucher.createCampaign"),
|
|
26
26
|
value: "create",
|
|
27
27
|
isPrimary: !0,
|
|
28
28
|
prependIcon: "add"
|
|
29
|
-
},
|
|
29
|
+
}, E = le(), q = ve("VOUCHER", E), G = fe(), y = ye(), { global: X, minor: B } = pe, k = xe(), l = T({
|
|
30
30
|
searchKey: "",
|
|
31
31
|
location: [],
|
|
32
32
|
triggerType: []
|
|
33
|
-
}), C =
|
|
33
|
+
}), C = ae(
|
|
34
34
|
() => y.campaigns.voucher.filter(
|
|
35
|
-
(e) =>
|
|
35
|
+
(e) => z(e) && Q(e)
|
|
36
36
|
)
|
|
37
|
-
),
|
|
37
|
+
), W = ke.VOUCHER.map((e) => ({
|
|
38
38
|
label: e.name,
|
|
39
39
|
value: e.value
|
|
40
40
|
}));
|
|
41
|
-
function
|
|
42
|
-
const o =
|
|
41
|
+
function z(e) {
|
|
42
|
+
const o = l.value.location;
|
|
43
43
|
return !o || o.length === 0 || !e.targetLocation ? !0 : Array.isArray(o) ? o.some(
|
|
44
44
|
(r) => {
|
|
45
45
|
var i;
|
|
@@ -47,25 +47,25 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
47
47
|
}
|
|
48
48
|
) : e.targetLocation.includes(o);
|
|
49
49
|
}
|
|
50
|
-
function
|
|
50
|
+
function x(e) {
|
|
51
51
|
return e.hideInApp === !1;
|
|
52
52
|
}
|
|
53
|
-
function
|
|
54
|
-
return e.event.type === "SIMPLE_CLAIM" && !
|
|
53
|
+
function F(e) {
|
|
54
|
+
return e.event.type === "SIMPLE_CLAIM" && !x(e);
|
|
55
55
|
}
|
|
56
|
-
function
|
|
57
|
-
const o =
|
|
56
|
+
function Q(e) {
|
|
57
|
+
const o = l.value.triggerType;
|
|
58
58
|
if (!o || o.length === 0) return !0;
|
|
59
59
|
const r = e.event.type;
|
|
60
60
|
return o.includes(r);
|
|
61
61
|
}
|
|
62
|
-
const
|
|
62
|
+
const Y = [
|
|
63
63
|
{
|
|
64
64
|
header: a("connect.voucher.voucherTitle"),
|
|
65
65
|
accessorFn: (e) => e.name,
|
|
66
66
|
cell(e) {
|
|
67
67
|
const o = [e.row.original.name];
|
|
68
|
-
return
|
|
68
|
+
return x(e.row.original) && o.push(
|
|
69
69
|
m(p.FmChip, {
|
|
70
70
|
label: "Feedvibe",
|
|
71
71
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
@@ -76,14 +76,14 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
78
|
header: a("connect.voucher.status"),
|
|
79
|
-
accessorFn: (e) =>
|
|
79
|
+
accessorFn: (e) => he(e),
|
|
80
80
|
cell(e) {
|
|
81
|
-
return
|
|
81
|
+
return D(e.row.original);
|
|
82
82
|
}
|
|
83
83
|
},
|
|
84
84
|
{
|
|
85
85
|
header: a("connect.voucher.summary"),
|
|
86
|
-
accessorFn: (e) =>
|
|
86
|
+
accessorFn: (e) => K(e)
|
|
87
87
|
},
|
|
88
88
|
{
|
|
89
89
|
header: a("connect.voucher.quota"),
|
|
@@ -103,13 +103,21 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
103
103
|
header: a("connect.voucher.actions"),
|
|
104
104
|
cell(e) {
|
|
105
105
|
return m("div", { class: "flex items-center justify-end" }, [
|
|
106
|
+
m(p.FmButton, {
|
|
107
|
+
icon: "insights",
|
|
108
|
+
variant: "tertiary",
|
|
109
|
+
iconColor: "neutral-gray-400",
|
|
110
|
+
onClick: async (o) => {
|
|
111
|
+
o.stopPropagation(), await M(e.row.original);
|
|
112
|
+
}
|
|
113
|
+
}),
|
|
106
114
|
m(p.FmButton, {
|
|
107
115
|
icon: "visibility",
|
|
108
116
|
variant: "tertiary",
|
|
109
117
|
iconColor: "neutral-gray-400",
|
|
110
118
|
onClick: async (o) => {
|
|
111
|
-
o.stopPropagation(), await
|
|
112
|
-
name:
|
|
119
|
+
o.stopPropagation(), await k.push({
|
|
120
|
+
name: A["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
113
121
|
params: { id: e.row.original._id }
|
|
114
122
|
});
|
|
115
123
|
}
|
|
@@ -133,7 +141,7 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
133
141
|
m(p.FmMenuItem, {
|
|
134
142
|
label: a("connect.voucher.duplicate"),
|
|
135
143
|
onClick: async (r) => {
|
|
136
|
-
r.stopPropagation(), await
|
|
144
|
+
r.stopPropagation(), await H(e.row.original);
|
|
137
145
|
}
|
|
138
146
|
}),
|
|
139
147
|
m(
|
|
@@ -154,12 +162,12 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
154
162
|
}
|
|
155
163
|
)
|
|
156
164
|
];
|
|
157
|
-
return
|
|
165
|
+
return F(e.row.original) && (o.unshift(
|
|
158
166
|
m(p.FmMenuItem, {
|
|
159
167
|
label: a("connect.voucher.send"),
|
|
160
168
|
onClick: async (r) => {
|
|
161
169
|
var i;
|
|
162
|
-
r.stopPropagation(), (i =
|
|
170
|
+
r.stopPropagation(), (i = S.value) == null || i.showSheet({
|
|
163
171
|
campaignId: e.row.original._id
|
|
164
172
|
});
|
|
165
173
|
}
|
|
@@ -168,8 +176,8 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
168
176
|
m(p.FmMenuItem, {
|
|
169
177
|
label: a("connect.voucher.share"),
|
|
170
178
|
onClick: async (r) => {
|
|
171
|
-
r.stopPropagation(), await
|
|
172
|
-
`https://${
|
|
179
|
+
r.stopPropagation(), await me(
|
|
180
|
+
`https://${de().currentBusiness.value._id}.${Fe.appUrl}/vouchers/${e.row.original._id}`,
|
|
173
181
|
{
|
|
174
182
|
successMessage: "Voucher link copied to clipboard"
|
|
175
183
|
}
|
|
@@ -183,9 +191,9 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
183
191
|
]);
|
|
184
192
|
}
|
|
185
193
|
}
|
|
186
|
-
],
|
|
194
|
+
], V = T(), S = T();
|
|
187
195
|
async function O(e) {
|
|
188
|
-
await
|
|
196
|
+
await ue.remove(a("connect.voucher.confirmRemove", { name: e.name })) && await B(
|
|
189
197
|
async () => {
|
|
190
198
|
await v.delete(e._id), await y.read("VOUCHER");
|
|
191
199
|
},
|
|
@@ -198,20 +206,26 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
198
206
|
);
|
|
199
207
|
}
|
|
200
208
|
async function w(e) {
|
|
201
|
-
e ? await o(await v.readById(e._id)) :
|
|
209
|
+
e ? await o(await v.readById(e._id)) : q.open(async (r) => {
|
|
202
210
|
await o(void 0, r);
|
|
203
211
|
});
|
|
204
212
|
async function o(r, i) {
|
|
205
213
|
var b;
|
|
206
|
-
(b =
|
|
214
|
+
(b = V.value) == null || b.showSheet(!0, "VOUCHER", r, i);
|
|
207
215
|
}
|
|
208
216
|
}
|
|
209
|
-
async function
|
|
217
|
+
async function M(e) {
|
|
218
|
+
await k.push({
|
|
219
|
+
name: A["$connect-CAMPAIGN_VOUCHER_ANALYTIC"],
|
|
220
|
+
params: { id: e._id }
|
|
221
|
+
});
|
|
222
|
+
}
|
|
223
|
+
async function H(e) {
|
|
210
224
|
var i;
|
|
211
|
-
if (!await
|
|
225
|
+
if (!await ge(e.name))
|
|
212
226
|
return;
|
|
213
|
-
const o = await v.readById(e._id), r =
|
|
214
|
-
(i =
|
|
227
|
+
const o = await v.readById(e._id), r = _e(o);
|
|
228
|
+
(i = V.value) == null || i.showSheet(
|
|
215
229
|
!0,
|
|
216
230
|
"VOUCHER",
|
|
217
231
|
r,
|
|
@@ -220,7 +234,7 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
220
234
|
}
|
|
221
235
|
async function Z(e) {
|
|
222
236
|
e.campaign._id && await new Promise((o) => {
|
|
223
|
-
|
|
237
|
+
E.open({
|
|
224
238
|
title: "Confirmation",
|
|
225
239
|
message: "This will change all future vouchers? Would you like to update previous claimed vouchers expiry date and discount?",
|
|
226
240
|
primaryActions: { text: "Update all", close: !0 },
|
|
@@ -231,7 +245,7 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
231
245
|
}).onSecondary(async () => {
|
|
232
246
|
o();
|
|
233
247
|
});
|
|
234
|
-
}), await
|
|
248
|
+
}), await B(
|
|
235
249
|
async () => {
|
|
236
250
|
e.campaign._id ? await v.update(e.campaign._id, e) : await v.create(e), await y.read("VOUCHER");
|
|
237
251
|
},
|
|
@@ -245,131 +259,139 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
245
259
|
}
|
|
246
260
|
);
|
|
247
261
|
}
|
|
248
|
-
return
|
|
249
|
-
await
|
|
262
|
+
return re(async () => {
|
|
263
|
+
await X(async () => {
|
|
250
264
|
await y.read("VOUCHER");
|
|
251
265
|
});
|
|
252
266
|
}), (e, o) => {
|
|
253
|
-
const r =
|
|
254
|
-
return
|
|
255
|
-
|
|
267
|
+
const r = f("FmPageHead"), i = f("FmSearch"), b = f("FmTable"), J = f("FmChip"), h = f("FmButton"), ee = f("FmListItem"), oe = f("FmList"), te = f("FmCard");
|
|
268
|
+
return d(), P(R, null, [
|
|
269
|
+
s(r, {
|
|
256
270
|
title: t(a)("connect.voucher.title"),
|
|
257
|
-
actions: t(C).length > 0 ? [
|
|
271
|
+
actions: t(C).length > 0 ? [j] : [],
|
|
258
272
|
"onClick:action": o[0] || (o[0] = () => w())
|
|
259
273
|
}, null, 8, ["title", "actions"]),
|
|
260
|
-
c("div",
|
|
261
|
-
|
|
262
|
-
modelValue: t(
|
|
263
|
-
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(
|
|
274
|
+
c("div", Ve, [
|
|
275
|
+
s(i, {
|
|
276
|
+
modelValue: t(l).searchKey,
|
|
277
|
+
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(l).searchKey = n),
|
|
264
278
|
class: "hidden xs:!block sm:!block border-b-2 border-fm-color-neutral-gray-100",
|
|
265
279
|
placeholder: t(a)("connect.voucher.search"),
|
|
266
280
|
collapsible: ""
|
|
267
281
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
268
|
-
t(y).campaigns.voucher && t(y).campaigns.voucher.length > 0 ? (
|
|
269
|
-
c("div",
|
|
270
|
-
c("div",
|
|
271
|
-
|
|
282
|
+
t(y).campaigns.voucher && t(y).campaigns.voucher.length > 0 ? (d(), P(R, { key: 0 }, [
|
|
283
|
+
c("div", Se, [
|
|
284
|
+
c("div", Ue, [
|
|
285
|
+
s(N, {
|
|
272
286
|
label: `${t(a)("connect.common.location")}: `,
|
|
273
287
|
"right-icon": "keyboard_arrow_down",
|
|
274
|
-
modelValue: t(
|
|
275
|
-
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(
|
|
288
|
+
modelValue: t(l).location,
|
|
289
|
+
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(l).location = n),
|
|
276
290
|
icon: "storefront",
|
|
277
291
|
"show-item-label": !0,
|
|
278
|
-
items: t(
|
|
292
|
+
items: t(G).locationOptions
|
|
279
293
|
}, null, 8, ["label", "modelValue", "items"]),
|
|
280
|
-
|
|
294
|
+
s(N, {
|
|
281
295
|
label: "Type:",
|
|
282
296
|
"right-icon": "keyboard_arrow_down",
|
|
283
|
-
modelValue: t(
|
|
284
|
-
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(
|
|
297
|
+
modelValue: t(l).triggerType,
|
|
298
|
+
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(l).triggerType = n),
|
|
285
299
|
icon: "filter_list",
|
|
286
300
|
"show-item-label": !0,
|
|
287
|
-
items: t(
|
|
301
|
+
items: t(W)
|
|
288
302
|
}, null, 8, ["modelValue", "items"])
|
|
289
303
|
]),
|
|
290
|
-
|
|
291
|
-
modelValue: t(
|
|
292
|
-
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(
|
|
304
|
+
s(i, {
|
|
305
|
+
modelValue: t(l).searchKey,
|
|
306
|
+
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(l).searchKey = n),
|
|
293
307
|
class: "xs:hidden sm:hidden",
|
|
294
308
|
placeholder: t(a)("connect.voucher.search"),
|
|
295
309
|
collapsible: ""
|
|
296
310
|
}, null, 8, ["modelValue", "placeholder"])
|
|
297
311
|
]),
|
|
298
|
-
|
|
312
|
+
s(b, {
|
|
299
313
|
class: "xs:hidden sm:hidden",
|
|
300
314
|
"row-data": t(C),
|
|
301
|
-
"column-defs":
|
|
302
|
-
"search-value": t(
|
|
315
|
+
"column-defs": Y,
|
|
316
|
+
"search-value": t(l).searchKey,
|
|
303
317
|
"column-filter": [],
|
|
304
318
|
onRowClick: o[5] || (o[5] = (n) => w(n.original)),
|
|
305
319
|
"hide-footer": t(C).length < 10
|
|
306
320
|
}, null, 8, ["row-data", "search-value", "hide-footer"]),
|
|
307
|
-
|
|
308
|
-
default:
|
|
309
|
-
(
|
|
310
|
-
(n) => n.name.toLowerCase().includes(t(
|
|
311
|
-
), (n) => (
|
|
321
|
+
s(oe, { class: "hidden xs:!flex sm:!flex flex-col mx-[-24px]" }, {
|
|
322
|
+
default: I(() => [
|
|
323
|
+
(d(!0), P(R, null, ce(t(C).filter(
|
|
324
|
+
(n) => n.name.toLowerCase().includes(t(l).searchKey.toLowerCase())
|
|
325
|
+
), (n) => (d(), g(ee, {
|
|
312
326
|
key: n._id.toString(),
|
|
313
|
-
onClick: (
|
|
327
|
+
onClick: (U) => w(n),
|
|
314
328
|
class: "py-12 px-16 flex items-center justify-between border-b border-fm-color-neutral-gray-100"
|
|
315
329
|
}, {
|
|
316
|
-
default:
|
|
317
|
-
var
|
|
330
|
+
default: I(() => {
|
|
331
|
+
var U;
|
|
318
332
|
return [
|
|
319
|
-
c("div",
|
|
320
|
-
c("div",
|
|
321
|
-
(
|
|
322
|
-
|
|
333
|
+
c("div", Te, [
|
|
334
|
+
c("div", Pe, [
|
|
335
|
+
(d(), g(ie(t(D)(n)))),
|
|
336
|
+
x(n) ? (d(), g(J, {
|
|
323
337
|
key: 0,
|
|
324
338
|
label: "Feedvibe",
|
|
325
339
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
326
340
|
compact: ""
|
|
327
341
|
})) : L("", !0),
|
|
328
|
-
c("div",
|
|
342
|
+
c("div", Re, _(((U = n.pf_collectible) == null ? void 0 : U.currentReceive) ?? 0) + " claimed ", 1)
|
|
329
343
|
]),
|
|
330
|
-
c("div",
|
|
344
|
+
c("div", Ie, [
|
|
331
345
|
c("div", Le, _(n.name), 1),
|
|
332
|
-
c("div",
|
|
346
|
+
c("div", Ae, _(t(K)(n)), 1)
|
|
333
347
|
])
|
|
334
348
|
]),
|
|
335
349
|
c("div", Ee, [
|
|
336
|
-
|
|
350
|
+
s(h, {
|
|
351
|
+
icon: "insights",
|
|
352
|
+
"icon-color": "neutral-gray-400",
|
|
353
|
+
variant: "tertiary",
|
|
354
|
+
onClick: async (u) => {
|
|
355
|
+
u.stopPropagation(), await M(n);
|
|
356
|
+
}
|
|
357
|
+
}, null, 8, ["onClick"]),
|
|
358
|
+
s(h, {
|
|
337
359
|
icon: "content_copy",
|
|
338
360
|
"icon-color": "neutral-gray-400",
|
|
339
361
|
variant: "tertiary",
|
|
340
|
-
onClick: async (
|
|
341
|
-
|
|
362
|
+
onClick: async (u) => {
|
|
363
|
+
u.stopPropagation(), await H(n);
|
|
342
364
|
}
|
|
343
365
|
}, null, 8, ["onClick"]),
|
|
344
|
-
|
|
366
|
+
F(n) ? (d(), g(h, {
|
|
345
367
|
key: 0,
|
|
346
368
|
icon: "visibility",
|
|
347
369
|
"icon-color": "neutral-gray-400",
|
|
348
370
|
variant: "tertiary",
|
|
349
|
-
onClick: async (
|
|
350
|
-
|
|
351
|
-
name: t(
|
|
371
|
+
onClick: async (u) => {
|
|
372
|
+
u.stopPropagation(), await t(k).push({
|
|
373
|
+
name: t(A)["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
352
374
|
params: { id: n._id }
|
|
353
375
|
});
|
|
354
376
|
}
|
|
355
377
|
}, null, 8, ["onClick"])) : L("", !0),
|
|
356
|
-
|
|
378
|
+
F(n) ? (d(), g(h, {
|
|
357
379
|
key: 1,
|
|
358
380
|
icon: "send",
|
|
359
381
|
"icon-color": "neutral-gray-400",
|
|
360
382
|
variant: "tertiary",
|
|
361
|
-
onClick: (
|
|
362
|
-
var
|
|
363
|
-
|
|
383
|
+
onClick: (u) => {
|
|
384
|
+
var $;
|
|
385
|
+
u.stopPropagation(), ($ = t(S)) == null || $.showSheet({
|
|
364
386
|
campaignId: n._id
|
|
365
387
|
});
|
|
366
388
|
}
|
|
367
389
|
}, null, 8, ["onClick"])) : L("", !0),
|
|
368
|
-
|
|
390
|
+
s(h, {
|
|
369
391
|
icon: "delete",
|
|
370
392
|
"icon-color": "neutral-gray-400",
|
|
371
393
|
variant: "tertiary",
|
|
372
|
-
onClick: (
|
|
394
|
+
onClick: (u) => (u.stopPropagation(), O(n))
|
|
373
395
|
}, null, 8, ["onClick"])
|
|
374
396
|
])
|
|
375
397
|
];
|
|
@@ -379,21 +401,21 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
379
401
|
]),
|
|
380
402
|
_: 1
|
|
381
403
|
})
|
|
382
|
-
], 64)) : (
|
|
404
|
+
], 64)) : (d(), g(te, {
|
|
383
405
|
key: 1,
|
|
384
406
|
variant: "outlined",
|
|
385
407
|
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
386
408
|
}, {
|
|
387
|
-
default:
|
|
409
|
+
default: I(() => [
|
|
388
410
|
o[7] || (o[7] = c("img", {
|
|
389
|
-
src:
|
|
411
|
+
src: se,
|
|
390
412
|
class: "aspect-square w-[150px]"
|
|
391
413
|
}, null, -1)),
|
|
392
414
|
c("div", Be, [
|
|
393
415
|
c("div", Oe, _(t(a)("connect.voucher.createVoucherCampaign")), 1),
|
|
394
|
-
c("div",
|
|
416
|
+
c("div", Me, _(t(a)("connect.voucher.description")), 1)
|
|
395
417
|
]),
|
|
396
|
-
|
|
418
|
+
s(h, {
|
|
397
419
|
variant: "primary",
|
|
398
420
|
label: t(a)("connect.voucher.createVoucherCampaign"),
|
|
399
421
|
icon: "add",
|
|
@@ -402,14 +424,14 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
402
424
|
]),
|
|
403
425
|
_: 1
|
|
404
426
|
})),
|
|
405
|
-
|
|
427
|
+
s(Ce, {
|
|
406
428
|
ref_key: "sheetRef",
|
|
407
|
-
ref:
|
|
429
|
+
ref: V,
|
|
408
430
|
"onSubmit:modelValue": Z
|
|
409
431
|
}, null, 512),
|
|
410
|
-
|
|
432
|
+
s(we, {
|
|
411
433
|
ref_key: "sendVoucherSheetRef",
|
|
412
|
-
ref:
|
|
434
|
+
ref: S
|
|
413
435
|
}, null, 512)
|
|
414
436
|
])
|
|
415
437
|
], 64);
|
|
@@ -417,5 +439,5 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
417
439
|
}
|
|
418
440
|
});
|
|
419
441
|
export {
|
|
420
|
-
|
|
442
|
+
ro as default
|
|
421
443
|
};
|