@feedmepos/mf-connect 0.1.98-beta.21 → 0.1.98-beta.22
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-B3f8GWoR.js → App-DkvPrOD_.js} +10 -9
- package/dist/{AuditLogs-LRHzzpqj.js → AuditLogs-CWYsiJmS.js} +9 -9
- package/dist/{Bin-Y761Ua4-.js → Bin-BeuBpKQM.js} +8 -8
- package/dist/{Broadcast-CdRuG42N.js → Broadcast-Dm-HdR4q.js} +13 -12
- package/dist/CampaignAnalytic-DipDONF1.js +1656 -0
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CsULDH9l.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-D4wbIGp6.js} +6 -5
- package/dist/{Card-GZ3ZLnBl.js → Card-i5EhYfDp.js} +18 -18
- package/dist/{Collections-B59fL-oS.js → Collections-B4lpotjz.js} +14 -13
- package/dist/{Credit-DJxzXBam.js → Credit-DbK_BdJJ.js} +119 -93
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-C3d8frgZ.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-B8Soqc5E.js} +34 -30
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-DKUFvacX.js → EffectSheet.vue_vue_type_style_index_0_lang-DzdJH_eS.js} +6 -6
- package/dist/{Experience-lzpvYFPP.js → Experience-W3vkkzi6.js} +112 -86
- package/dist/{FileSaver.min-BXoEv5ve.js → FileSaver.min-BI4NzqgX.js} +1 -1
- package/dist/Game-fftjNIOx.js +356 -0
- package/dist/{Grab-BQgS104D.js → Grab-CMQ8P4g9.js} +32 -31
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-Cz9iB9ox.js → ImageInput.vue_vue_type_script_setup_true_lang-DUi11pWY.js} +1 -1
- package/dist/{Index-B5UTBbUy.js → Index-Cnztjepd.js} +10 -10
- package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-CLLhy4-v.js → LocationPicker.vue_vue_type_script_setup_true_lang-Dy8WW9eT.js} +1 -1
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-BiIqs4zW.js → LottieAnimation.vue_vue_type_script_setup_true_lang-DTHvv2lB.js} +1 -1
- package/dist/LoyaltyDashboard-1gKZWq0g.js +1339 -0
- package/dist/{MainLayout-AvQ4_-oT.js → MainLayout-CfKJ6l-r.js} +1 -1
- package/dist/{Marketing-Bn1ygF8d.js → Marketing-Dk_nSJuC.js} +4 -4
- package/dist/{MarketingMaterialEdit-Cw-VPVqE.js → MarketingMaterialEdit-DnO9DNuB.js} +6 -6
- package/dist/{Member-CpEXFHIF.js → Member-CpXKw34e.js} +11 -11
- package/dist/{MemberList-gSEw_idJ.js → MemberList-8ppDIsaQ.js} +36 -35
- package/dist/{MemberTransactions-DEMzj9-y.js → MemberTransactions-B52DV6hR.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-B4Y5KPpw.js → MessageInput.vue_vue_type_script_setup_true_lang-Di0tBK7t.js} +4400 -4431
- package/dist/MetricInfoTooltip.vue_vue_type_script_setup_true_lang-B1Yj3odA.js +38 -0
- package/dist/Mission-dT284_xH.js +360 -0
- package/dist/{Overview-CMudFYOc.js → Overview-CUXmQ5AN.js} +3 -3
- package/dist/{Overview-DjNcF88f.js → Overview-CePgs6nV.js} +18 -18
- package/dist/Point-BLr01-Fi.js +288 -0
- package/dist/Promotion-BJUWwJir.js +423 -0
- package/dist/{Queue-BjoAJoVe.js → Queue-DpjzPA9X.js} +16 -16
- package/dist/{Record-CfZFuwy_.js → Record-D5iz3VhQ.js} +9 -9
- package/dist/{Review-pIAxbjVU.js → Review-BIDSfZ-d.js} +2 -2
- package/dist/{ReviewFacebookCallback-BRW4T-5-.js → ReviewFacebookCallback-Cl4apd5U.js} +5 -5
- package/dist/{ReviewGoogleCallback-B-6EojXR.js → ReviewGoogleCallback-CxQ3jv5Z.js} +5 -5
- package/dist/{Reward-_pdE2XZp.js → Reward-FhUo0v2c.js} +16 -16
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-S5dh0IGc.js → RewardGroup.vue_vue_type_script_setup_true_lang-9Fdl4-Zk.js} +11 -11
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-C9B7NmF0.js → RuleGroup.vue_vue_type_script_setup_true_lang-Bh1rez91.js} +16 -15
- package/dist/{Segment-B1EMe-LZ.js → Segment-XrwahyNZ.js} +39 -37
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-DAmjk8b3.js → SelectItems.vue_vue_type_script_setup_true_lang-Bd_O16Eo.js} +2 -2
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-C7sgPf8l.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-CB0bY0pg.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-DVYTZr_E.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-B1-fwLJq.js} +4 -4
- package/dist/{Setting-CQQ6zacB.js → Setting-Cs5abyWq.js} +40 -40
- package/dist/{SettingAdvertisements-9Wl9VWbM.js → SettingAdvertisements-C0NbeiB9.js} +12 -12
- package/dist/{Settings-Bvj2ChDR.js → Settings-xdy_sV8_.js} +5 -5
- package/dist/{Store-BdUZ22g6.js → Store-BVn4DGJN.js} +21 -21
- package/dist/{StoreRewards-DsUS_Lu1.js → StoreRewards-BnEDugiP.js} +15 -15
- package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-Zw-lIDCN.js → StoreTransactions.vue_vue_type_script_setup_true_lang-B63UqQ0d.js} +21 -21
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-BECp3eqQ.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BOIUqr5c.js} +2 -2
- package/dist/{Tier-2-mJ3SNK.js → Tier-BdyyZ6S8.js} +36 -34
- package/dist/{Title-BjeEDjxl.js → Title-Y7GfS9n5.js} +39 -37
- package/dist/{Transaction--U_kJKec.js → Transaction-DF217QY1.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-BkLyvjA5.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-QrbU0JEl.js} +6 -6
- package/dist/{Voucher-INa3N_6V.js → Voucher-q9JMtbmK.js} +156 -133
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-4Quzmc7-.js → VoucherEditor.vue_vue_type_script_setup_true_lang-Cm040eE9.js} +12 -12
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-CPCnBExY.js → ZodTextField.vue_vue_type_script_setup_true_lang-DibJzz40.js} +2 -2
- package/dist/{app-Dlqr-LX4.js → app-BZJkvDm7.js} +3279 -3135
- package/dist/app.js +1 -1
- package/dist/{business-DWrfGEe_.js → business-akMhlJ-M.js} +1 -1
- package/dist/{campaign-DtNt-BqN.js → campaign-BDXIKhhi.js} +74 -96
- package/dist/campaign-hm_reShF.js +100 -0
- package/dist/{campaign.enum-B9-ZpK0C.js → campaign.enum-Dx-Zo68Q.js} +1 -1
- package/dist/{campaign.fn-COxaWmi_.js → campaign.fn-BFI2Flc_.js} +126 -126
- package/dist/{collectible.enum-CF0VF-r7.js → collectible.enum-Liy2wH3s.js} +1 -1
- package/dist/collection.fn-RUGxb2Zd.js +26 -0
- package/dist/{duplicateCampaign-8ciT68QF.js → duplicateCampaign-DsGtbLbP.js} +2 -2
- package/dist/{effect-CaSn-84h.js → effect-8iyz8Uq4.js} +1 -1
- package/dist/{email-addresses-BiMQ8xIx.js → email-addresses-gyl-C-R_.js} +2 -2
- package/dist/{export-BwBNgCo5.js → export-wupBk3du.js} +3 -3
- package/dist/{helper-CajV_0CM.js → helper-CaxDAXPt.js} +1 -1
- package/dist/{index-CQIciFrH.js → index-BMin5EVt.js} +1 -1
- package/dist/{index-CQj9BQlQ.js → index-BO9SkdZr.js} +105 -123
- package/dist/index-BOcaalDh.js +146 -0
- package/dist/{index-B6ldAC8Y.js → index-BQmxPtoj.js} +1 -1
- package/dist/{index-B6tm_U_M.js → index-Bic6MeUk.js} +18 -17
- package/dist/{index-D1vhLY7l.js → index-C4drX0Ls.js} +1 -1
- package/dist/index-C8cXXcLk.js +45 -0
- package/dist/{index-DBUTFa2h.js → index-CG66mIC4.js} +2 -2
- package/dist/index-C_H8jFYf.js +2743 -0
- package/dist/{index-Bqcfsd4p.js → index-Cw-UC5sx.js} +8 -7
- package/dist/{index-D1--K-QL.js → index-D4BfoKjK.js} +1 -1
- package/dist/{index-DWBKko92.js → index-DhQlBP7P.js} +6 -6
- package/dist/{index-J8pSZ3WO.js → index-Dvf0YXyw.js} +1 -1
- package/dist/{index-BP5rdioN.js → index-J3y4ZPL5.js} +8027 -10766
- package/dist/{index-CjW6Mj-1.js → index-bZhlsMWI.js} +1 -1
- package/dist/{index-B0ohh62P.js → index-xGCLj50g.js} +230 -351
- package/dist/{index-D90p28Hr.js → index-yYZu6iPh.js} +205 -229
- package/dist/{index.esm2017-QlPanYiW.js → index.esm2017-DgAjf49-.js} +1 -1
- package/dist/{loading-CqqkzWSm.js → loading-DIme5B41.js} +1 -1
- package/dist/{lodash-DmbW2QhA.js → lodash-ssnk3xgl.js} +1 -1
- package/dist/{membership-Dcwyu-rr.js → membership-CNHGvM-v.js} +3 -3
- package/dist/{money-DWr1gi--.js → money-CxE1yyP-.js} +1 -1
- package/dist/{number-CHhHAd1q.js → number-MuiSu5EH.js} +1 -1
- package/dist/{objectid-BsiuHVH8.js → objectid-BKst2tcL.js} +9 -9
- package/dist/{plugins-BxmMI8fo.js → plugins-J8P61v6q.js} +3 -3
- package/dist/{reward-DX0FjsNT.js → reward-CvyDLx6u.js} +1 -1
- package/dist/{rule-DDLcqiHH.js → rule-CidUfHRV.js} +3 -3
- package/dist/rule-builder-CzSwZHFX.js +126 -0
- package/dist/{template-C0lF82yv.js → template-DDFGgRca.js} +6 -6
- package/dist/timezone-C55-EXUa.js +20 -0
- package/dist/{trigger-CsJcg_RY.js → trigger-BHmznST2.js} +5 -5
- package/dist/{useMarketingMaterialActions-B0iV6YzB.js → useMarketingMaterialActions-CRGy07Kl.js} +3 -3
- package/dist/{usePagination-4EISkyGW.js → usePagination-nKd3ToBL.js} +1 -1
- package/dist/{user-DZuSeqRY.js → user-CxxLM4oI.js} +1 -1
- package/dist/{vue-i18n-BKcwYlp1.js → vue-i18n-BIqCnVyc.js} +300 -300
- package/dist/{xlsx-C-7dia55.js → xlsx-CUqEhJg1.js} +1 -1
- package/dist/{zod-DPxXVSRw.js → zod-B3g-tD-1.js} +1 -1
- package/package.json +1 -1
- package/dist/Game-KCxIpXEC.js +0 -330
- package/dist/LoyaltyDashboard-DPHWpaNJ.js +0 -1082
- package/dist/Mission-DMtpauNQ.js +0 -334
- package/dist/Point-CgdTrgXc.js +0 -262
- package/dist/Promotion-DDQodFDb.js +0 -397
- package/dist/campaign-un9Ji1KF.js +0 -219
|
@@ -1,71 +1,72 @@
|
|
|
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 { a as
|
|
11
|
-
import { c as
|
|
12
|
-
import "./index-
|
|
13
|
-
import { u as ve } from "./template-
|
|
14
|
-
import { _ as
|
|
15
|
-
import { _ as
|
|
16
|
-
import { u as
|
|
17
|
-
import { T as
|
|
18
|
-
import { useRouter as
|
|
19
|
-
import {
|
|
20
|
-
|
|
21
|
-
|
|
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 i, withCtx as I, renderList as ie, createBlock as g, resolveDynamicComponent as ce, 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-DaU-9GzO.js";
|
|
5
|
+
import { c as me, p as ue } from "./plugins-J8P61v6q.js";
|
|
6
|
+
import { useCoreStore as de } from "@feedmepos/mf-common";
|
|
7
|
+
import { u as pe } from "./loading-DIme5B41.js";
|
|
8
|
+
import { u as fe } from "./business-akMhlJ-M.js";
|
|
9
|
+
import { u as ye } from "./campaign-hm_reShF.js";
|
|
10
|
+
import { a as he, b as D, c as K } from "./campaign-BDXIKhhi.js";
|
|
11
|
+
import { c as ge, p as _e } from "./duplicateCampaign-DsGtbLbP.js";
|
|
12
|
+
import "./index-BMin5EVt.js";
|
|
13
|
+
import { u as ve } from "./template-DDFGgRca.js";
|
|
14
|
+
import { _ as Ce } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-B8Soqc5E.js";
|
|
15
|
+
import { _ as we } from "./SendVoucherSheet.vue_vue_type_script_setup_true_lang-B1-fwLJq.js";
|
|
16
|
+
import { u as be } from "./vue-i18n-BIqCnVyc.js";
|
|
17
|
+
import { T as ke } from "./trigger-BHmznST2.js";
|
|
18
|
+
import { useRouter as xe } from "vue-router";
|
|
19
|
+
import { c as v } from "./index-BOcaalDh.js";
|
|
20
|
+
import { R as A } from "./app-BZJkvDm7.js";
|
|
21
|
+
var Fe = { authUrl: "https://portal-v2-dev.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "feedmedev.vip", crmUrl: "crm.feedmedev.cc", paymentPortalUrl: "https://portal.feedmedev.cc/payment/payout-account", licensePortalUrl: "https://license.feedmedev.cc/", marketingV1Portal: "https://marketing-v1.feedmedev.cc", voucherAppUrl: "https://voucher.feedmedev.cc/" };
|
|
22
|
+
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" }, io = /* @__PURE__ */ ne({
|
|
22
23
|
__name: "Voucher",
|
|
23
|
-
setup(
|
|
24
|
-
const { t: a } =
|
|
24
|
+
setup(He) {
|
|
25
|
+
const { t: a } = be(), j = {
|
|
25
26
|
label: a("connect.voucher.createCampaign"),
|
|
26
27
|
value: "create",
|
|
27
28
|
isPrimary: !0,
|
|
28
29
|
prependIcon: "add"
|
|
29
|
-
},
|
|
30
|
+
}, E = le(), q = ve("VOUCHER", E), G = fe(), y = ye(), { global: X, minor: B } = pe, k = xe(), l = T({
|
|
30
31
|
searchKey: "",
|
|
31
32
|
location: [],
|
|
32
33
|
triggerType: []
|
|
33
|
-
}), C =
|
|
34
|
+
}), C = ae(
|
|
34
35
|
() => y.campaigns.voucher.filter(
|
|
35
|
-
(e) =>
|
|
36
|
+
(e) => z(e) && Q(e)
|
|
36
37
|
)
|
|
37
|
-
),
|
|
38
|
+
), W = ke.VOUCHER.map((e) => ({
|
|
38
39
|
label: e.name,
|
|
39
40
|
value: e.value
|
|
40
41
|
}));
|
|
41
|
-
function
|
|
42
|
-
const o =
|
|
42
|
+
function z(e) {
|
|
43
|
+
const o = l.value.location;
|
|
43
44
|
return !o || o.length === 0 || !e.targetLocation ? !0 : Array.isArray(o) ? o.some(
|
|
44
45
|
(r) => {
|
|
45
|
-
var
|
|
46
|
-
return (
|
|
46
|
+
var c;
|
|
47
|
+
return (c = e == null ? void 0 : e.targetLocation) == null ? void 0 : c.includes(r);
|
|
47
48
|
}
|
|
48
49
|
) : e.targetLocation.includes(o);
|
|
49
50
|
}
|
|
50
|
-
function
|
|
51
|
+
function x(e) {
|
|
51
52
|
return e.hideInApp === !1;
|
|
52
53
|
}
|
|
53
|
-
function
|
|
54
|
-
return e.event.type === "SIMPLE_CLAIM" && !
|
|
54
|
+
function F(e) {
|
|
55
|
+
return e.event.type === "SIMPLE_CLAIM" && !x(e);
|
|
55
56
|
}
|
|
56
|
-
function
|
|
57
|
-
const o =
|
|
57
|
+
function Q(e) {
|
|
58
|
+
const o = l.value.triggerType;
|
|
58
59
|
if (!o || o.length === 0) return !0;
|
|
59
60
|
const r = e.event.type;
|
|
60
61
|
return o.includes(r);
|
|
61
62
|
}
|
|
62
|
-
const
|
|
63
|
+
const Y = [
|
|
63
64
|
{
|
|
64
65
|
header: a("connect.voucher.voucherTitle"),
|
|
65
66
|
accessorFn: (e) => e.name,
|
|
66
67
|
cell(e) {
|
|
67
68
|
const o = [e.row.original.name];
|
|
68
|
-
return
|
|
69
|
+
return x(e.row.original) && o.push(
|
|
69
70
|
m(p.FmChip, {
|
|
70
71
|
label: "Feedvibe",
|
|
71
72
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
@@ -76,14 +77,14 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
76
77
|
},
|
|
77
78
|
{
|
|
78
79
|
header: a("connect.voucher.status"),
|
|
79
|
-
accessorFn: (e) =>
|
|
80
|
+
accessorFn: (e) => he(e),
|
|
80
81
|
cell(e) {
|
|
81
|
-
return
|
|
82
|
+
return D(e.row.original);
|
|
82
83
|
}
|
|
83
84
|
},
|
|
84
85
|
{
|
|
85
86
|
header: a("connect.voucher.summary"),
|
|
86
|
-
accessorFn: (e) =>
|
|
87
|
+
accessorFn: (e) => K(e)
|
|
87
88
|
},
|
|
88
89
|
{
|
|
89
90
|
header: a("connect.voucher.quota"),
|
|
@@ -103,13 +104,21 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
103
104
|
header: a("connect.voucher.actions"),
|
|
104
105
|
cell(e) {
|
|
105
106
|
return m("div", { class: "flex items-center justify-end" }, [
|
|
107
|
+
m(p.FmButton, {
|
|
108
|
+
icon: "insights",
|
|
109
|
+
variant: "tertiary",
|
|
110
|
+
iconColor: "neutral-gray-400",
|
|
111
|
+
onClick: async (o) => {
|
|
112
|
+
o.stopPropagation(), await M(e.row.original);
|
|
113
|
+
}
|
|
114
|
+
}),
|
|
106
115
|
m(p.FmButton, {
|
|
107
116
|
icon: "visibility",
|
|
108
117
|
variant: "tertiary",
|
|
109
118
|
iconColor: "neutral-gray-400",
|
|
110
119
|
onClick: async (o) => {
|
|
111
|
-
o.stopPropagation(), await
|
|
112
|
-
name:
|
|
120
|
+
o.stopPropagation(), await k.push({
|
|
121
|
+
name: A["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
113
122
|
params: { id: e.row.original._id }
|
|
114
123
|
});
|
|
115
124
|
}
|
|
@@ -133,7 +142,7 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
133
142
|
m(p.FmMenuItem, {
|
|
134
143
|
label: a("connect.voucher.duplicate"),
|
|
135
144
|
onClick: async (r) => {
|
|
136
|
-
r.stopPropagation(), await
|
|
145
|
+
r.stopPropagation(), await H(e.row.original);
|
|
137
146
|
}
|
|
138
147
|
}),
|
|
139
148
|
m(
|
|
@@ -154,12 +163,12 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
154
163
|
}
|
|
155
164
|
)
|
|
156
165
|
];
|
|
157
|
-
return
|
|
166
|
+
return F(e.row.original) && (o.unshift(
|
|
158
167
|
m(p.FmMenuItem, {
|
|
159
168
|
label: a("connect.voucher.send"),
|
|
160
169
|
onClick: async (r) => {
|
|
161
|
-
var
|
|
162
|
-
r.stopPropagation(), (
|
|
170
|
+
var c;
|
|
171
|
+
r.stopPropagation(), (c = S.value) == null || c.showSheet({
|
|
163
172
|
campaignId: e.row.original._id
|
|
164
173
|
});
|
|
165
174
|
}
|
|
@@ -168,8 +177,8 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
168
177
|
m(p.FmMenuItem, {
|
|
169
178
|
label: a("connect.voucher.share"),
|
|
170
179
|
onClick: async (r) => {
|
|
171
|
-
r.stopPropagation(), await
|
|
172
|
-
`https://${
|
|
180
|
+
r.stopPropagation(), await me(
|
|
181
|
+
`https://${de().currentBusiness.value._id}.${Fe.appUrl}/vouchers/${e.row.original._id}`,
|
|
173
182
|
{
|
|
174
183
|
successMessage: "Voucher link copied to clipboard"
|
|
175
184
|
}
|
|
@@ -183,11 +192,11 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
183
192
|
]);
|
|
184
193
|
}
|
|
185
194
|
}
|
|
186
|
-
],
|
|
195
|
+
], V = T(), S = T();
|
|
187
196
|
async function O(e) {
|
|
188
|
-
await
|
|
197
|
+
await ue.remove(a("connect.voucher.confirmRemove", { name: e.name })) && await B(
|
|
189
198
|
async () => {
|
|
190
|
-
await
|
|
199
|
+
await v.delete(e._id), await y.read("VOUCHER");
|
|
191
200
|
},
|
|
192
201
|
{
|
|
193
202
|
message: a("connect.voucher.removing", { name: e.name }),
|
|
@@ -198,20 +207,26 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
198
207
|
);
|
|
199
208
|
}
|
|
200
209
|
async function w(e) {
|
|
201
|
-
e ? await o(await
|
|
210
|
+
e ? await o(await v.readById(e._id)) : q.open(async (r) => {
|
|
202
211
|
await o(void 0, r);
|
|
203
212
|
});
|
|
204
|
-
async function o(r,
|
|
213
|
+
async function o(r, c) {
|
|
205
214
|
var b;
|
|
206
|
-
(b =
|
|
215
|
+
(b = V.value) == null || b.showSheet(!0, "VOUCHER", r, c);
|
|
207
216
|
}
|
|
208
217
|
}
|
|
209
|
-
async function
|
|
210
|
-
|
|
211
|
-
|
|
218
|
+
async function M(e) {
|
|
219
|
+
await k.push({
|
|
220
|
+
name: A["$connect-CAMPAIGN_VOUCHER_ANALYTIC"],
|
|
221
|
+
params: { id: e._id }
|
|
222
|
+
});
|
|
223
|
+
}
|
|
224
|
+
async function H(e) {
|
|
225
|
+
var c;
|
|
226
|
+
if (!await ge(e.name))
|
|
212
227
|
return;
|
|
213
|
-
const o = await
|
|
214
|
-
(
|
|
228
|
+
const o = await v.readById(e._id), r = _e(o);
|
|
229
|
+
(c = V.value) == null || c.showSheet(
|
|
215
230
|
!0,
|
|
216
231
|
"VOUCHER",
|
|
217
232
|
r,
|
|
@@ -220,7 +235,7 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
220
235
|
}
|
|
221
236
|
async function Z(e) {
|
|
222
237
|
e.campaign._id && await new Promise((o) => {
|
|
223
|
-
|
|
238
|
+
E.open({
|
|
224
239
|
title: "Confirmation",
|
|
225
240
|
message: "This will change all future vouchers? Would you like to update previous claimed vouchers expiry date and discount?",
|
|
226
241
|
primaryActions: { text: "Update all", close: !0 },
|
|
@@ -231,9 +246,9 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
231
246
|
}).onSecondary(async () => {
|
|
232
247
|
o();
|
|
233
248
|
});
|
|
234
|
-
}), await
|
|
249
|
+
}), await B(
|
|
235
250
|
async () => {
|
|
236
|
-
e.campaign._id ? await
|
|
251
|
+
e.campaign._id ? await v.update(e.campaign._id, e) : await v.create(e), await y.read("VOUCHER");
|
|
237
252
|
},
|
|
238
253
|
{
|
|
239
254
|
message: a(
|
|
@@ -245,131 +260,139 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
245
260
|
}
|
|
246
261
|
);
|
|
247
262
|
}
|
|
248
|
-
return
|
|
249
|
-
await
|
|
263
|
+
return re(async () => {
|
|
264
|
+
await X(async () => {
|
|
250
265
|
await y.read("VOUCHER");
|
|
251
266
|
});
|
|
252
267
|
}), (e, o) => {
|
|
253
|
-
const r =
|
|
254
|
-
return
|
|
255
|
-
|
|
268
|
+
const r = f("FmPageHead"), c = f("FmSearch"), b = f("FmTable"), J = f("FmChip"), h = f("FmButton"), ee = f("FmListItem"), oe = f("FmList"), te = f("FmCard");
|
|
269
|
+
return d(), P(R, null, [
|
|
270
|
+
s(r, {
|
|
256
271
|
title: t(a)("connect.voucher.title"),
|
|
257
|
-
actions: t(C).length > 0 ? [
|
|
272
|
+
actions: t(C).length > 0 ? [j] : [],
|
|
258
273
|
"onClick:action": o[0] || (o[0] = () => w())
|
|
259
274
|
}, null, 8, ["title", "actions"]),
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
modelValue: t(
|
|
263
|
-
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(
|
|
275
|
+
i("div", Ve, [
|
|
276
|
+
s(c, {
|
|
277
|
+
modelValue: t(l).searchKey,
|
|
278
|
+
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(l).searchKey = n),
|
|
264
279
|
class: "hidden xs:!block sm:!block border-b-2 border-fm-color-neutral-gray-100",
|
|
265
280
|
placeholder: t(a)("connect.voucher.search"),
|
|
266
281
|
collapsible: ""
|
|
267
282
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
268
|
-
t(y).campaigns.voucher && t(y).campaigns.voucher.length > 0 ? (
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
283
|
+
t(y).campaigns.voucher && t(y).campaigns.voucher.length > 0 ? (d(), P(R, { key: 0 }, [
|
|
284
|
+
i("div", Se, [
|
|
285
|
+
i("div", Ue, [
|
|
286
|
+
s(N, {
|
|
272
287
|
label: `${t(a)("connect.common.location")}: `,
|
|
273
288
|
"right-icon": "keyboard_arrow_down",
|
|
274
|
-
modelValue: t(
|
|
275
|
-
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(
|
|
289
|
+
modelValue: t(l).location,
|
|
290
|
+
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(l).location = n),
|
|
276
291
|
icon: "storefront",
|
|
277
292
|
"show-item-label": !0,
|
|
278
|
-
items: t(
|
|
293
|
+
items: t(G).locationOptions
|
|
279
294
|
}, null, 8, ["label", "modelValue", "items"]),
|
|
280
|
-
|
|
295
|
+
s(N, {
|
|
281
296
|
label: "Type:",
|
|
282
297
|
"right-icon": "keyboard_arrow_down",
|
|
283
|
-
modelValue: t(
|
|
284
|
-
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(
|
|
298
|
+
modelValue: t(l).triggerType,
|
|
299
|
+
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(l).triggerType = n),
|
|
285
300
|
icon: "filter_list",
|
|
286
301
|
"show-item-label": !0,
|
|
287
|
-
items: t(
|
|
302
|
+
items: t(W)
|
|
288
303
|
}, null, 8, ["modelValue", "items"])
|
|
289
304
|
]),
|
|
290
|
-
|
|
291
|
-
modelValue: t(
|
|
292
|
-
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(
|
|
305
|
+
s(c, {
|
|
306
|
+
modelValue: t(l).searchKey,
|
|
307
|
+
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(l).searchKey = n),
|
|
293
308
|
class: "xs:hidden sm:hidden",
|
|
294
309
|
placeholder: t(a)("connect.voucher.search"),
|
|
295
310
|
collapsible: ""
|
|
296
311
|
}, null, 8, ["modelValue", "placeholder"])
|
|
297
312
|
]),
|
|
298
|
-
|
|
313
|
+
s(b, {
|
|
299
314
|
class: "xs:hidden sm:hidden",
|
|
300
315
|
"row-data": t(C),
|
|
301
|
-
"column-defs":
|
|
302
|
-
"search-value": t(
|
|
316
|
+
"column-defs": Y,
|
|
317
|
+
"search-value": t(l).searchKey,
|
|
303
318
|
"column-filter": [],
|
|
304
319
|
onRowClick: o[5] || (o[5] = (n) => w(n.original)),
|
|
305
320
|
"hide-footer": t(C).length < 10
|
|
306
321
|
}, null, 8, ["row-data", "search-value", "hide-footer"]),
|
|
307
|
-
|
|
308
|
-
default:
|
|
309
|
-
(
|
|
310
|
-
(n) => n.name.toLowerCase().includes(t(
|
|
311
|
-
), (n) => (
|
|
322
|
+
s(oe, { class: "hidden xs:!flex sm:!flex flex-col mx-[-24px]" }, {
|
|
323
|
+
default: I(() => [
|
|
324
|
+
(d(!0), P(R, null, ie(t(C).filter(
|
|
325
|
+
(n) => n.name.toLowerCase().includes(t(l).searchKey.toLowerCase())
|
|
326
|
+
), (n) => (d(), g(ee, {
|
|
312
327
|
key: n._id.toString(),
|
|
313
|
-
onClick: (
|
|
328
|
+
onClick: (U) => w(n),
|
|
314
329
|
class: "py-12 px-16 flex items-center justify-between border-b border-fm-color-neutral-gray-100"
|
|
315
330
|
}, {
|
|
316
|
-
default:
|
|
317
|
-
var
|
|
331
|
+
default: I(() => {
|
|
332
|
+
var U;
|
|
318
333
|
return [
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
(
|
|
322
|
-
|
|
334
|
+
i("div", Te, [
|
|
335
|
+
i("div", Pe, [
|
|
336
|
+
(d(), g(ce(t(D)(n)))),
|
|
337
|
+
x(n) ? (d(), g(J, {
|
|
323
338
|
key: 0,
|
|
324
339
|
label: "Feedvibe",
|
|
325
340
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
326
341
|
compact: ""
|
|
327
342
|
})) : L("", !0),
|
|
328
|
-
|
|
343
|
+
i("div", Re, _(((U = n.pf_collectible) == null ? void 0 : U.currentReceive) ?? 0) + " claimed ", 1)
|
|
329
344
|
]),
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
345
|
+
i("div", Ie, [
|
|
346
|
+
i("div", Le, _(n.name), 1),
|
|
347
|
+
i("div", Ae, _(t(K)(n)), 1)
|
|
333
348
|
])
|
|
334
349
|
]),
|
|
335
|
-
|
|
336
|
-
|
|
350
|
+
i("div", Ee, [
|
|
351
|
+
s(h, {
|
|
352
|
+
icon: "insights",
|
|
353
|
+
"icon-color": "neutral-gray-400",
|
|
354
|
+
variant: "tertiary",
|
|
355
|
+
onClick: async (u) => {
|
|
356
|
+
u.stopPropagation(), await M(n);
|
|
357
|
+
}
|
|
358
|
+
}, null, 8, ["onClick"]),
|
|
359
|
+
s(h, {
|
|
337
360
|
icon: "content_copy",
|
|
338
361
|
"icon-color": "neutral-gray-400",
|
|
339
362
|
variant: "tertiary",
|
|
340
|
-
onClick: async (
|
|
341
|
-
|
|
363
|
+
onClick: async (u) => {
|
|
364
|
+
u.stopPropagation(), await H(n);
|
|
342
365
|
}
|
|
343
366
|
}, null, 8, ["onClick"]),
|
|
344
|
-
|
|
367
|
+
F(n) ? (d(), g(h, {
|
|
345
368
|
key: 0,
|
|
346
369
|
icon: "visibility",
|
|
347
370
|
"icon-color": "neutral-gray-400",
|
|
348
371
|
variant: "tertiary",
|
|
349
|
-
onClick: async (
|
|
350
|
-
|
|
351
|
-
name: t(
|
|
372
|
+
onClick: async (u) => {
|
|
373
|
+
u.stopPropagation(), await t(k).push({
|
|
374
|
+
name: t(A)["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
352
375
|
params: { id: n._id }
|
|
353
376
|
});
|
|
354
377
|
}
|
|
355
378
|
}, null, 8, ["onClick"])) : L("", !0),
|
|
356
|
-
|
|
379
|
+
F(n) ? (d(), g(h, {
|
|
357
380
|
key: 1,
|
|
358
381
|
icon: "send",
|
|
359
382
|
"icon-color": "neutral-gray-400",
|
|
360
383
|
variant: "tertiary",
|
|
361
|
-
onClick: (
|
|
362
|
-
var
|
|
363
|
-
|
|
384
|
+
onClick: (u) => {
|
|
385
|
+
var $;
|
|
386
|
+
u.stopPropagation(), ($ = t(S)) == null || $.showSheet({
|
|
364
387
|
campaignId: n._id
|
|
365
388
|
});
|
|
366
389
|
}
|
|
367
390
|
}, null, 8, ["onClick"])) : L("", !0),
|
|
368
|
-
|
|
391
|
+
s(h, {
|
|
369
392
|
icon: "delete",
|
|
370
393
|
"icon-color": "neutral-gray-400",
|
|
371
394
|
variant: "tertiary",
|
|
372
|
-
onClick: (
|
|
395
|
+
onClick: (u) => (u.stopPropagation(), O(n))
|
|
373
396
|
}, null, 8, ["onClick"])
|
|
374
397
|
])
|
|
375
398
|
];
|
|
@@ -379,21 +402,21 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
379
402
|
]),
|
|
380
403
|
_: 1
|
|
381
404
|
})
|
|
382
|
-
], 64)) : (
|
|
405
|
+
], 64)) : (d(), g(te, {
|
|
383
406
|
key: 1,
|
|
384
407
|
variant: "outlined",
|
|
385
408
|
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
386
409
|
}, {
|
|
387
|
-
default:
|
|
388
|
-
o[7] || (o[7] =
|
|
389
|
-
src:
|
|
410
|
+
default: I(() => [
|
|
411
|
+
o[7] || (o[7] = i("img", {
|
|
412
|
+
src: se,
|
|
390
413
|
class: "aspect-square w-[150px]"
|
|
391
414
|
}, null, -1)),
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
415
|
+
i("div", Be, [
|
|
416
|
+
i("div", Oe, _(t(a)("connect.voucher.createVoucherCampaign")), 1),
|
|
417
|
+
i("div", Me, _(t(a)("connect.voucher.description")), 1)
|
|
395
418
|
]),
|
|
396
|
-
|
|
419
|
+
s(h, {
|
|
397
420
|
variant: "primary",
|
|
398
421
|
label: t(a)("connect.voucher.createVoucherCampaign"),
|
|
399
422
|
icon: "add",
|
|
@@ -402,14 +425,14 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
402
425
|
]),
|
|
403
426
|
_: 1
|
|
404
427
|
})),
|
|
405
|
-
|
|
428
|
+
s(Ce, {
|
|
406
429
|
ref_key: "sheetRef",
|
|
407
|
-
ref:
|
|
430
|
+
ref: V,
|
|
408
431
|
"onSubmit:modelValue": Z
|
|
409
432
|
}, null, 512),
|
|
410
|
-
|
|
433
|
+
s(we, {
|
|
411
434
|
ref_key: "sendVoucherSheetRef",
|
|
412
|
-
ref:
|
|
435
|
+
ref: S
|
|
413
436
|
}, null, 512)
|
|
414
437
|
])
|
|
415
438
|
], 64);
|
|
@@ -417,5 +440,5 @@ const Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-
|
|
|
417
440
|
}
|
|
418
441
|
});
|
|
419
442
|
export {
|
|
420
|
-
|
|
443
|
+
io as default
|
|
421
444
|
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { defineComponent as B, ref as k, resolveComponent as g, openBlock as d, createBlock as F, withCtx as y, renderSlot as J, createVNode as m, createTextVNode as U, toDisplayString as f, createElementVNode as s, computed as N, createElementBlock as P, Fragment as w, renderList as K, unref as e, normalizeClass as Q, createCommentVNode as I, resolveDynamicComponent as H } from "vue";
|
|
2
|
-
import { u as G } from "./vue-i18n-
|
|
3
|
-
import { c as j } from "./index-
|
|
4
|
-
import { e as W, F as Y } from "./index-
|
|
5
|
-
import { C as ee } from "./membership-
|
|
6
|
-
import { Z as V } from "./zod-
|
|
7
|
-
import { _ as te } from "./SelectItems.vue_vue_type_script_setup_true_lang-
|
|
8
|
-
import { u as le } from "./business-
|
|
2
|
+
import { u as G } from "./vue-i18n-BIqCnVyc.js";
|
|
3
|
+
import { c as j } from "./index-CG66mIC4.js";
|
|
4
|
+
import { e as W, F as Y } from "./index-Bic6MeUk.js";
|
|
5
|
+
import { C as ee } from "./membership-CNHGvM-v.js";
|
|
6
|
+
import { Z as V } from "./zod-B3g-tD-1.js";
|
|
7
|
+
import { _ as te } from "./SelectItems.vue_vue_type_script_setup_true_lang-Bd_O16Eo.js";
|
|
8
|
+
import { u as le } from "./business-akMhlJ-M.js";
|
|
9
9
|
import { useCoreStore as oe } from "@feedmepos/mf-common";
|
|
10
|
-
import { _ as ne } from "./ZodTextField.vue_vue_type_script_setup_true_lang-
|
|
11
|
-
import { _ as ae } from "./ImageInput.vue_vue_type_script_setup_true_lang-
|
|
12
|
-
import { _ as ie, a as se } from "./EffectSheet.vue_vue_type_style_index_0_lang-
|
|
13
|
-
import { _ as me } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-
|
|
14
|
-
import { i as re } from "./helper-
|
|
10
|
+
import { _ as ne } from "./ZodTextField.vue_vue_type_script_setup_true_lang-DibJzz40.js";
|
|
11
|
+
import { _ as ae } from "./ImageInput.vue_vue_type_script_setup_true_lang-DUi11pWY.js";
|
|
12
|
+
import { _ as ie, a as se } from "./EffectSheet.vue_vue_type_style_index_0_lang-DzdJH_eS.js";
|
|
13
|
+
import { _ as me } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-BOIUqr5c.js";
|
|
14
|
+
import { i as re } from "./helper-CaxDAXPt.js";
|
|
15
15
|
const ue = { class: "flex justify-end gap-8 w-full" }, ce = /* @__PURE__ */ B({
|
|
16
16
|
__name: "MenuSheet",
|
|
17
17
|
props: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as f, useAttrs as y, resolveComponent as b, openBlock as l, createBlock as v, mergeProps as x, unref as t, createSlots as g, withCtx as h, createElementVNode as a, toDisplayString as n, renderSlot as k, createElementBlock as F, createCommentVNode as S } from "vue";
|
|
2
|
-
import { Z as d } from "./zod-
|
|
3
|
-
import { u as V } from "./vue-i18n-
|
|
2
|
+
import { Z as d } from "./zod-B3g-tD-1.js";
|
|
3
|
+
import { u as V } from "./vue-i18n-BIqCnVyc.js";
|
|
4
4
|
const B = { class: "fm-typo-en-body-lg-400 flex gap-4 text-fm-color-typo-primary items-center" }, C = {
|
|
5
5
|
key: 0,
|
|
6
6
|
class: "text-fm-color-typo-tertiary"
|