@feedmepos/mf-connect 0.1.38-beta.61 → 0.1.38-beta.63
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-CM7mh-iO.js → Analytic-99208ZGh.js} +14 -14
- package/dist/{App-CeCzzsDu.js → App-BkTi1rTp.js} +7 -7
- package/dist/{AuditLogs-VWx8DFKA.js → AuditLogs-BqKgDkGp.js} +9 -9
- package/dist/{Bin-vUuol_I9.js → Bin-C_vWkAOc.js} +8 -8
- package/dist/Broadcast-_s9fmcsY.js +267 -0
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CV-zhJ15.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CgDMf3Yl.js} +6 -6
- package/dist/{Card-CeIeGET1.js → Card-RfSe4_GI.js} +17 -17
- package/dist/{Collections-CF_OcAL3.js → Collections-DgWI87e9.js} +7 -7
- package/dist/Credit-DBy_Xcpq.js +261 -0
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-0DMFuBoG.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-D5T444y0.js} +203 -199
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-BZfchHlT.js → EffectSheet.vue_vue_type_style_index_0_lang-BwSXXdG-.js} +6 -6
- package/dist/Experience-DBg5cZxJ.js +260 -0
- package/dist/{FileSaver.min-lgg_oBvT.js → FileSaver.min-Bzi1BTgf.js} +1 -1
- package/dist/Game-CSilatA5.js +331 -0
- package/dist/{GenerateMaterial-B5A7mx2y.js → GenerateMaterial-7DLj60E8.js} +6 -6
- package/dist/{Grab-BgiMqwvj.js → Grab-CM0RcU3-.js} +9 -9
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-DZ8DHrQ_.js → ImageInput.vue_vue_type_script_setup_true_lang-D3lV7JVV.js} +1 -1
- package/dist/{Index-B85ops8K.js → Index-DIpMb8rL.js} +10 -10
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-B5rIjxYd.js → LottieAnimation.vue_vue_type_script_setup_true_lang-D6L3PiGD.js} +1 -1
- package/dist/{MainLayout-CXGVkD-W.js → MainLayout-C0Bq_pRh.js} +1 -1
- package/dist/{Marketing-Bnijl7lA.js → Marketing-CiOCRSE8.js} +4 -4
- package/dist/{MarketingMaterialEdit-BlUKwSoP.js → MarketingMaterialEdit-BHJPku7e.js} +4 -4
- package/dist/{Member-sT853g51.js → Member-Blcc8M5S.js} +11 -11
- package/dist/{MemberList-DYT5_fSP.js → MemberList--Ua0eKo0.js} +25 -25
- package/dist/{MemberTransactions-Cqce5ebe.js → MemberTransactions-C0_OArai.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-Dq0Hswj8.js → MessageInput.vue_vue_type_script_setup_true_lang-CO8MuZju.js} +9834 -9724
- package/dist/Mission-Dp7QTUdu.js +335 -0
- package/dist/{Overview-B0rwrHR1.js → Overview-B-puEtTe.js} +18 -18
- package/dist/Point-BMUeLRXE.js +263 -0
- package/dist/Promotion-CZjW5Eny.js +397 -0
- package/dist/{Queue-SVqRUlD_.js → Queue-CZ8a1tcg.js} +10 -10
- package/dist/{Record-BTjg4ihy.js → Record-BJXOqe51.js} +9 -9
- package/dist/{Reward-DW58VMRO.js → Reward-CYaP48K9.js} +16 -16
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-s1RI55Rc.js → RewardGroup.vue_vue_type_script_setup_true_lang-Bvq4GrL1.js} +11 -11
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-Os17lXBX.js → RuleGroup.vue_vue_type_script_setup_true_lang-DnfvXZOL.js} +14 -14
- package/dist/{Segment-Dny8pxP1.js → Segment-D4vjzSgr.js} +24 -24
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-Czx7rqiq.js → SelectItems.vue_vue_type_script_setup_true_lang-iDaC99DI.js} +2 -2
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-EgVxUG_N.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-mkt1o9sO.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-CO0fgI3K.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-UHTvMbYY.js} +4 -4
- package/dist/{Setting-CjcnxK34.js → Setting-BxTVlSNI.js} +13 -13
- package/dist/{SettingAdvertisements-CIyDF4C8.js → SettingAdvertisements-DvuFXOGs.js} +11 -11
- package/dist/{Store-B8k5YVqU.js → Store-xF8dYQbN.js} +20 -20
- package/dist/{StoreRewards-BW08rwpL.js → StoreRewards-BxW_FxY3.js} +14 -14
- package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-BfFSfE2H.js → StoreTransactions.vue_vue_type_script_setup_true_lang-DvPC3YQN.js} +19 -19
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-CZkKjUNQ.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-CDgL0WOA.js} +1 -1
- package/dist/{Tier-DKzu4tYw.js → Tier-C73TRPVo.js} +23 -23
- package/dist/{Title-BK-TXatJ.js → Title-DD4gP_Kc.js} +20 -20
- package/dist/{Transaction-Duayg1jd.js → Transaction-BGheiJ8F.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-BAR9h1TV.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-ne1fn7b7.js} +6 -6
- package/dist/{Voucher-BEVAkNeJ.js → Voucher-CRatGWk7.js} +164 -142
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-DvFy9Z6X.js → VoucherEditor.vue_vue_type_script_setup_true_lang-2_F9hEkK.js} +12 -12
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-CU_Sx2PM.js → ZodTextField.vue_vue_type_script_setup_true_lang-DNEs_60Z.js} +2 -2
- package/dist/{app-IvbII0ql.js → app-UaX9LGGa.js} +7966 -7880
- package/dist/app.js +1 -1
- package/dist/{business-BFIwFfkq.js → business-bUX6raMw.js} +1 -1
- package/dist/{campaign-RuIwxc4y.js → campaign-BwqSJn1x.js} +8 -8
- package/dist/{campaign-w9j4I4jn.js → campaign-DUDuTel5.js} +2 -2
- package/dist/{campaign.enum-IHLsfdik.js → campaign.enum-1k6333ca.js} +1 -1
- package/dist/{campaign.fn-B_P1MkRV.js → campaign.fn-CgJi24jv.js} +31 -31
- package/dist/{collectible.enum-CUgSjO08.js → collectible.enum-DkQ5IEM4.js} +1 -1
- package/dist/{collection.fn-CrfnNb41.js → collection.fn-Cc4UF4PF.js} +2 -2
- package/dist/{dto-jwO_sX9I.js → dto-BauGrz7j.js} +4 -4
- package/dist/duplicateCampaign-C1zAMcB8.js +51 -0
- package/dist/{effect--0g8PNyt.js → effect-BzcguSGr.js} +1 -1
- package/dist/{email-addresses-HtsxvXw9.js → email-addresses-BxvYeGJM.js} +2 -2
- package/dist/{export-CFEwMRmd.js → export-CtEjDYVF.js} +2 -2
- package/dist/{helper-CCfb24PO.js → helper-B9MQjEoz.js} +1 -1
- package/dist/{index-BZEM0T2A.js → index-BhKOx9rm.js} +1 -1
- package/dist/{index-Bflu4Rft.js → index-Bx_lUMxi.js} +3 -3
- package/dist/{index-wzSeRJAd.js → index-CJIGs8yP.js} +1 -1
- package/dist/{index-CkuPY85X.js → index-COST516f.js} +1 -1
- package/dist/{index-BR3UbZ0F.js → index-CR8jJQP8.js} +1 -1
- package/dist/{index-CZPcwcUo.js → index-CRGgyR29.js} +3 -3
- package/dist/{index-DpjYgKTN.js → index-Cr9kGG1v.js} +1 -1
- package/dist/{index-CppLPpqB.js → index-Cvcgqzy5.js} +3 -3
- package/dist/{index-DDYH-IEX.js → index-DJqWLQvn.js} +1 -1
- package/dist/{index-CR3f3BXQ.js → index-DNrDjbLS.js} +1023 -1023
- package/dist/{index-B-AMMFfT.js → index-DYDOXl_b.js} +4 -4
- package/dist/{index-DdZdHioZ.js → index-hOEO4SV6.js} +6 -6
- package/dist/{index-Dic_WcAL.js → index-lbAEZ5CZ.js} +1 -1
- package/dist/{index.esm2017-CUnjzfU-.js → index.esm2017-6u5qxmWE.js} +1 -1
- package/dist/{loading-CivgDw5C.js → loading-Cpe50hSj.js} +2 -2
- package/dist/{lodash-BSbv_9TG.js → lodash-Bdhnyywe.js} +1 -1
- package/dist/{membership-j2w1YUO-.js → membership-C_VLzMwg.js} +3 -3
- package/dist/{money-DL-x8hiT.js → money-C2cELkXt.js} +1 -1
- package/dist/{number-D1yoFGEr.js → number-BFQi0hyw.js} +1 -1
- package/dist/objectid-WFNy_Dkj.js +145 -0
- package/dist/{plugins-P-V4XWmW.js → plugins-CTcRVNU6.js} +3 -3
- package/dist/{reward-BqMlBQRu.js → reward-zY_9dHpb.js} +1 -1
- package/dist/{rule-CztsLdki.js → rule-UZYsfn59.js} +3 -3
- package/dist/{rule-builder-DANv7Rmz.js → rule-builder-BW49BaXF.js} +1 -1
- package/dist/{template-Dbz3FhHK.js → template-CjZH_5cu.js} +6 -6
- package/dist/{timezone-BgVqObBq.js → timezone-CQrMBJum.js} +2 -2
- package/dist/{trigger-CbriUibd.js → trigger-BHqKZjrT.js} +5 -5
- package/dist/{usePagination-DtNK7W0U.js → usePagination-HabuQYCy.js} +1 -1
- package/dist/{user-CVapqHfr.js → user-YZUgk9lA.js} +1 -1
- package/dist/{vue-i18n-tpDAnnmD.js → vue-i18n-C1KlZBjR.js} +252 -252
- package/dist/{xlsx-EewcN2uY.js → xlsx-CMv5r9NR.js} +1 -1
- package/dist/{zod-D-wiCQRJ.js → zod-jH-8jgB1.js} +1 -1
- package/package.json +3 -3
- package/dist/Broadcast-6VXz4-IG.js +0 -233
- package/dist/Credit-BUqGOyp_.js +0 -226
- package/dist/Experience-BxiFH_uV.js +0 -225
- package/dist/Game-BzYW0LfY.js +0 -300
- package/dist/Mission-Q5_sGgrm.js +0 -304
- package/dist/Point-BGYFMvev.js +0 -228
- package/dist/Promotion-0acd63nA.js +0 -364
- package/dist/objectid-CHab6j3r.js +0 -145
|
@@ -1,71 +1,72 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { _ as
|
|
3
|
-
import { useDialog as
|
|
4
|
-
import { _ as
|
|
5
|
-
import { a as
|
|
6
|
-
import { useCoreStore as
|
|
7
|
-
import { u as
|
|
8
|
-
import { u as
|
|
9
|
-
import { u as
|
|
10
|
-
import { a as
|
|
11
|
-
import "./
|
|
12
|
-
import
|
|
13
|
-
import {
|
|
14
|
-
import { _ as
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
|
|
21
|
-
|
|
1
|
+
import { defineComponent as te, ref as U, computed as ne, h as m, onMounted as ae, resolveComponent as d, openBlock as u, createElementBlock as T, Fragment as P, createVNode as l, unref as t, createElementVNode as c, withCtx as R, renderList as re, createBlock as h, resolveDynamicComponent as ce, createCommentVNode as L, toDisplayString as v } from "vue";
|
|
2
|
+
import { _ as ie } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { useDialog as se, components as p } from "@feedmepos/ui-library";
|
|
4
|
+
import { _ as H } from "./FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js";
|
|
5
|
+
import { a as le, p as me } from "./plugins-CTcRVNU6.js";
|
|
6
|
+
import { useCoreStore as ue } from "@feedmepos/mf-common";
|
|
7
|
+
import { u as de } from "./loading-Cpe50hSj.js";
|
|
8
|
+
import { u as pe } from "./business-bUX6raMw.js";
|
|
9
|
+
import { u as fe } from "./campaign-DUDuTel5.js";
|
|
10
|
+
import { a as ye, b as $, c as D } from "./campaign-BwqSJn1x.js";
|
|
11
|
+
import { c as he, p as ge } from "./duplicateCampaign-C1zAMcB8.js";
|
|
12
|
+
import "./index-BhKOx9rm.js";
|
|
13
|
+
import { u as ve } from "./template-CjZH_5cu.js";
|
|
14
|
+
import { _ as _e } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-D5T444y0.js";
|
|
15
|
+
import { _ as Ce } from "./SendVoucherSheet.vue_vue_type_script_setup_true_lang-UHTvMbYY.js";
|
|
16
|
+
import { u as we } from "./vue-i18n-C1KlZBjR.js";
|
|
17
|
+
import { T as be } from "./trigger-BHqKZjrT.js";
|
|
18
|
+
import { useRouter as ke } from "vue-router";
|
|
19
|
+
import { c as _ } from "./index-Cr9kGG1v.js";
|
|
20
|
+
import { R as K } from "./app-UaX9LGGa.js";
|
|
21
|
+
var xe = { 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 Fe = { class: "px-24 flex flex-col gap-y-16" }, Ve = { class: "flex items-center justify-between w-full" }, Se = { class: "flex gap-8 overflow-x-auto" }, Ue = { class: "space-y-8" }, Te = { class: "flex w-full gap-4 items-center" }, Pe = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Re = { class: "space-y-4" }, Le = { class: "fm-typo-en-body-lg-600" }, Ie = { 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" }, Ae = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ro = /* @__PURE__ */ te({
|
|
22
23
|
__name: "Voucher",
|
|
23
|
-
setup(
|
|
24
|
-
const { t: a } =
|
|
24
|
+
setup(Me) {
|
|
25
|
+
const { t: a } = we(), N = {
|
|
25
26
|
label: a("connect.voucher.createCampaign"),
|
|
26
27
|
value: "create",
|
|
27
28
|
isPrimary: !0,
|
|
28
29
|
prependIcon: "add"
|
|
29
|
-
},
|
|
30
|
+
}, I = se(), j = ve("VOUCHER", I), q = pe(), y = fe(), { global: G, minor: E } = de, B = ke(), s = U({
|
|
30
31
|
searchKey: "",
|
|
31
32
|
location: [],
|
|
32
33
|
triggerType: []
|
|
33
|
-
}),
|
|
34
|
-
() =>
|
|
35
|
-
(e) =>
|
|
34
|
+
}), C = ne(
|
|
35
|
+
() => y.campaigns.voucher.filter(
|
|
36
|
+
(e) => W(e) && z(e)
|
|
36
37
|
)
|
|
37
|
-
),
|
|
38
|
+
), X = be.VOUCHER.map((e) => ({
|
|
38
39
|
label: e.name,
|
|
39
40
|
value: e.value
|
|
40
41
|
}));
|
|
41
|
-
function
|
|
42
|
-
const o =
|
|
42
|
+
function W(e) {
|
|
43
|
+
const o = s.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 i;
|
|
47
|
+
return (i = e == null ? void 0 : e.targetLocation) == null ? void 0 : i.includes(r);
|
|
47
48
|
}
|
|
48
49
|
) : e.targetLocation.includes(o);
|
|
49
50
|
}
|
|
50
|
-
function
|
|
51
|
+
function k(e) {
|
|
51
52
|
return e.hideInApp === !1;
|
|
52
53
|
}
|
|
53
54
|
function x(e) {
|
|
54
|
-
return e.event.type === "SIMPLE_CLAIM" && !
|
|
55
|
+
return e.event.type === "SIMPLE_CLAIM" && !k(e);
|
|
55
56
|
}
|
|
56
|
-
function
|
|
57
|
-
const o =
|
|
57
|
+
function z(e) {
|
|
58
|
+
const o = s.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 Q = [
|
|
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 k(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 we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
76
77
|
},
|
|
77
78
|
{
|
|
78
79
|
header: a("connect.voucher.status"),
|
|
79
|
-
accessorFn: (e) =>
|
|
80
|
+
accessorFn: (e) => ye(e),
|
|
80
81
|
cell(e) {
|
|
81
|
-
return
|
|
82
|
+
return $(e.row.original);
|
|
82
83
|
}
|
|
83
84
|
},
|
|
84
85
|
{
|
|
85
86
|
header: a("connect.voucher.summary"),
|
|
86
|
-
accessorFn: (e) =>
|
|
87
|
+
accessorFn: (e) => D(e)
|
|
87
88
|
},
|
|
88
89
|
{
|
|
89
90
|
header: a("connect.voucher.quota"),
|
|
@@ -108,8 +109,8 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
108
109
|
variant: "tertiary",
|
|
109
110
|
iconColor: "neutral-gray-400",
|
|
110
111
|
onClick: async (o) => {
|
|
111
|
-
o.stopPropagation(), await
|
|
112
|
-
name:
|
|
112
|
+
o.stopPropagation(), await B.push({
|
|
113
|
+
name: K["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
113
114
|
params: { id: e.row.original._id }
|
|
114
115
|
});
|
|
115
116
|
}
|
|
@@ -130,11 +131,17 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
130
131
|
}),
|
|
131
132
|
default: () => {
|
|
132
133
|
const o = [
|
|
134
|
+
m(p.FmMenuItem, {
|
|
135
|
+
label: a("connect.voucher.duplicate"),
|
|
136
|
+
onClick: async (r) => {
|
|
137
|
+
r.stopPropagation(), await A(e.row.original);
|
|
138
|
+
}
|
|
139
|
+
}),
|
|
133
140
|
m(
|
|
134
141
|
p.FmMenuItem,
|
|
135
142
|
{
|
|
136
143
|
onClick: async (r) => {
|
|
137
|
-
r.stopPropagation(),
|
|
144
|
+
r.stopPropagation(), O(e.row.original);
|
|
138
145
|
}
|
|
139
146
|
},
|
|
140
147
|
{
|
|
@@ -152,8 +159,8 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
152
159
|
m(p.FmMenuItem, {
|
|
153
160
|
label: a("connect.voucher.send"),
|
|
154
161
|
onClick: async (r) => {
|
|
155
|
-
var
|
|
156
|
-
r.stopPropagation(), (
|
|
162
|
+
var i;
|
|
163
|
+
r.stopPropagation(), (i = V.value) == null || i.showSheet({
|
|
157
164
|
campaignId: e.row.original._id
|
|
158
165
|
});
|
|
159
166
|
}
|
|
@@ -162,8 +169,8 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
162
169
|
m(p.FmMenuItem, {
|
|
163
170
|
label: a("connect.voucher.share"),
|
|
164
171
|
onClick: async (r) => {
|
|
165
|
-
r.stopPropagation(), await
|
|
166
|
-
`https://${
|
|
172
|
+
r.stopPropagation(), await le(
|
|
173
|
+
`https://${ue().currentBusiness.value._id}.${xe.appUrl}/vouchers/${e.row.original._id}`,
|
|
167
174
|
{
|
|
168
175
|
successMessage: "Voucher link copied to clipboard"
|
|
169
176
|
}
|
|
@@ -177,11 +184,11 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
177
184
|
]);
|
|
178
185
|
}
|
|
179
186
|
}
|
|
180
|
-
],
|
|
181
|
-
async function
|
|
182
|
-
await
|
|
187
|
+
], F = U(), V = U();
|
|
188
|
+
async function O(e) {
|
|
189
|
+
await me.remove(a("connect.voucher.confirmRemove", { name: e.name })) && await E(
|
|
183
190
|
async () => {
|
|
184
|
-
await
|
|
191
|
+
await _.delete(e._id), await y.read("VOUCHER");
|
|
185
192
|
},
|
|
186
193
|
{
|
|
187
194
|
message: a("connect.voucher.removing", { name: e.name }),
|
|
@@ -191,23 +198,30 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
191
198
|
}
|
|
192
199
|
);
|
|
193
200
|
}
|
|
194
|
-
async function
|
|
195
|
-
e ? await o() :
|
|
196
|
-
await o(r);
|
|
201
|
+
async function w(e) {
|
|
202
|
+
e ? await o(await _.readById(e._id)) : j.open(async (r) => {
|
|
203
|
+
await o(void 0, r);
|
|
197
204
|
});
|
|
198
|
-
async function o(r) {
|
|
199
|
-
var
|
|
200
|
-
(
|
|
201
|
-
!0,
|
|
202
|
-
"VOUCHER",
|
|
203
|
-
e ? await b.readById(e._id) : void 0,
|
|
204
|
-
r
|
|
205
|
-
);
|
|
205
|
+
async function o(r, i) {
|
|
206
|
+
var b;
|
|
207
|
+
(b = F.value) == null || b.showSheet(!0, "VOUCHER", r, i);
|
|
206
208
|
}
|
|
207
209
|
}
|
|
208
|
-
async function
|
|
210
|
+
async function A(e) {
|
|
211
|
+
var i;
|
|
212
|
+
if (!await he(e.name))
|
|
213
|
+
return;
|
|
214
|
+
const o = await _.readById(e._id), r = ge(o);
|
|
215
|
+
(i = F.value) == null || i.showSheet(
|
|
216
|
+
!0,
|
|
217
|
+
"VOUCHER",
|
|
218
|
+
r,
|
|
219
|
+
o.template
|
|
220
|
+
);
|
|
221
|
+
}
|
|
222
|
+
async function Z(e) {
|
|
209
223
|
e.campaign._id && await new Promise((o) => {
|
|
210
|
-
|
|
224
|
+
I.open({
|
|
211
225
|
title: "Confirmation",
|
|
212
226
|
message: "This will change all future vouchers? Would you like to update previous claimed vouchers expiry date and discount?",
|
|
213
227
|
primaryActions: { text: "Update all", close: !0 },
|
|
@@ -218,9 +232,9 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
218
232
|
}).onSecondary(async () => {
|
|
219
233
|
o();
|
|
220
234
|
});
|
|
221
|
-
}), await
|
|
235
|
+
}), await E(
|
|
222
236
|
async () => {
|
|
223
|
-
e.campaign._id ? await
|
|
237
|
+
e.campaign._id ? await _.update(e.campaign._id, e) : await _.create(e), await y.read("VOUCHER");
|
|
224
238
|
},
|
|
225
239
|
{
|
|
226
240
|
message: a(
|
|
@@ -232,123 +246,131 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
232
246
|
}
|
|
233
247
|
);
|
|
234
248
|
}
|
|
235
|
-
return
|
|
236
|
-
await
|
|
237
|
-
await
|
|
249
|
+
return ae(async () => {
|
|
250
|
+
await G(async () => {
|
|
251
|
+
await y.read("VOUCHER");
|
|
238
252
|
});
|
|
239
253
|
}), (e, o) => {
|
|
240
|
-
const r = d("FmPageHead"),
|
|
241
|
-
return u(),
|
|
254
|
+
const r = d("FmPageHead"), i = d("FmSearch"), b = d("FmTable"), J = d("FmChip"), g = d("FmButton"), Y = d("FmListItem"), ee = d("FmList"), oe = d("FmCard");
|
|
255
|
+
return u(), T(P, null, [
|
|
242
256
|
l(r, {
|
|
243
257
|
title: t(a)("connect.voucher.title"),
|
|
244
|
-
actions: t(
|
|
245
|
-
"onClick:action": o[0] || (o[0] = () =>
|
|
258
|
+
actions: t(C).length > 0 ? [N] : [],
|
|
259
|
+
"onClick:action": o[0] || (o[0] = () => w())
|
|
246
260
|
}, null, 8, ["title", "actions"]),
|
|
247
|
-
c("div",
|
|
248
|
-
l(
|
|
249
|
-
modelValue: t(
|
|
250
|
-
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(
|
|
261
|
+
c("div", Fe, [
|
|
262
|
+
l(i, {
|
|
263
|
+
modelValue: t(s).searchKey,
|
|
264
|
+
"onUpdate:modelValue": o[1] || (o[1] = (n) => t(s).searchKey = n),
|
|
251
265
|
class: "hidden xs:!block sm:!block border-b-2 border-fm-color-neutral-gray-100",
|
|
252
266
|
placeholder: t(a)("connect.voucher.search"),
|
|
253
267
|
collapsible: ""
|
|
254
268
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
255
|
-
t(
|
|
256
|
-
c("div",
|
|
257
|
-
c("div",
|
|
258
|
-
l(
|
|
269
|
+
t(y).campaigns.voucher && t(y).campaigns.voucher.length > 0 ? (u(), T(P, { key: 0 }, [
|
|
270
|
+
c("div", Ve, [
|
|
271
|
+
c("div", Se, [
|
|
272
|
+
l(H, {
|
|
259
273
|
label: `${t(a)("connect.common.location")}: `,
|
|
260
274
|
"right-icon": "keyboard_arrow_down",
|
|
261
|
-
modelValue: t(
|
|
262
|
-
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(
|
|
275
|
+
modelValue: t(s).location,
|
|
276
|
+
"onUpdate:modelValue": o[2] || (o[2] = (n) => t(s).location = n),
|
|
263
277
|
icon: "storefront",
|
|
264
278
|
"show-item-label": !0,
|
|
265
|
-
items: t(
|
|
279
|
+
items: t(q).locationOptions
|
|
266
280
|
}, null, 8, ["label", "modelValue", "items"]),
|
|
267
|
-
l(
|
|
281
|
+
l(H, {
|
|
268
282
|
label: "Type:",
|
|
269
283
|
"right-icon": "keyboard_arrow_down",
|
|
270
|
-
modelValue: t(
|
|
271
|
-
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(
|
|
284
|
+
modelValue: t(s).triggerType,
|
|
285
|
+
"onUpdate:modelValue": o[3] || (o[3] = (n) => t(s).triggerType = n),
|
|
272
286
|
icon: "filter_list",
|
|
273
287
|
"show-item-label": !0,
|
|
274
|
-
items: t(
|
|
288
|
+
items: t(X)
|
|
275
289
|
}, null, 8, ["modelValue", "items"])
|
|
276
290
|
]),
|
|
277
|
-
l(
|
|
278
|
-
modelValue: t(
|
|
279
|
-
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(
|
|
291
|
+
l(i, {
|
|
292
|
+
modelValue: t(s).searchKey,
|
|
293
|
+
"onUpdate:modelValue": o[4] || (o[4] = (n) => t(s).searchKey = n),
|
|
280
294
|
class: "xs:hidden sm:hidden",
|
|
281
295
|
placeholder: t(a)("connect.voucher.search"),
|
|
282
296
|
collapsible: ""
|
|
283
297
|
}, null, 8, ["modelValue", "placeholder"])
|
|
284
298
|
]),
|
|
285
|
-
l(
|
|
299
|
+
l(b, {
|
|
286
300
|
class: "xs:hidden sm:hidden",
|
|
287
|
-
"row-data": t(
|
|
288
|
-
"column-defs":
|
|
289
|
-
"search-value": t(
|
|
301
|
+
"row-data": t(C),
|
|
302
|
+
"column-defs": Q,
|
|
303
|
+
"search-value": t(s).searchKey,
|
|
290
304
|
"column-filter": [],
|
|
291
|
-
onRowClick: o[5] || (o[5] = (n) =>
|
|
292
|
-
"hide-footer": t(
|
|
305
|
+
onRowClick: o[5] || (o[5] = (n) => w(n.original)),
|
|
306
|
+
"hide-footer": t(C).length < 10
|
|
293
307
|
}, null, 8, ["row-data", "search-value", "hide-footer"]),
|
|
294
|
-
l(
|
|
295
|
-
default:
|
|
296
|
-
(u(!0),
|
|
297
|
-
(n) => n.name.toLowerCase().includes(t(
|
|
298
|
-
), (n) => (u(), h(
|
|
308
|
+
l(ee, { class: "hidden xs:!flex sm:!flex flex-col mx-[-24px]" }, {
|
|
309
|
+
default: R(() => [
|
|
310
|
+
(u(!0), T(P, null, re(t(C).filter(
|
|
311
|
+
(n) => n.name.toLowerCase().includes(t(s).searchKey.toLowerCase())
|
|
312
|
+
), (n) => (u(), h(Y, {
|
|
299
313
|
key: n._id.toString(),
|
|
300
|
-
onClick: (
|
|
314
|
+
onClick: (S) => w(n),
|
|
301
315
|
class: "py-12 px-16 flex items-center justify-between border-b border-fm-color-neutral-gray-100"
|
|
302
316
|
}, {
|
|
303
|
-
default:
|
|
304
|
-
var
|
|
317
|
+
default: R(() => {
|
|
318
|
+
var S;
|
|
305
319
|
return [
|
|
306
|
-
c("div",
|
|
307
|
-
c("div",
|
|
308
|
-
(u(), h(
|
|
309
|
-
|
|
320
|
+
c("div", Ue, [
|
|
321
|
+
c("div", Te, [
|
|
322
|
+
(u(), h(ce(t($)(n)))),
|
|
323
|
+
k(n) ? (u(), h(J, {
|
|
310
324
|
key: 0,
|
|
311
325
|
label: "Feedvibe",
|
|
312
326
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
313
327
|
compact: ""
|
|
314
|
-
})) :
|
|
315
|
-
c("div",
|
|
328
|
+
})) : L("", !0),
|
|
329
|
+
c("div", Pe, v(((S = n.pf_collectible) == null ? void 0 : S.currentReceive) ?? 0) + " claimed ", 1)
|
|
316
330
|
]),
|
|
317
|
-
c("div",
|
|
318
|
-
c("div",
|
|
319
|
-
c("div",
|
|
331
|
+
c("div", Re, [
|
|
332
|
+
c("div", Le, v(n.name), 1),
|
|
333
|
+
c("div", Ie, v(t(D)(n)), 1)
|
|
320
334
|
])
|
|
321
335
|
]),
|
|
322
|
-
c("div",
|
|
323
|
-
|
|
336
|
+
c("div", Ee, [
|
|
337
|
+
l(g, {
|
|
338
|
+
icon: "content_copy",
|
|
339
|
+
"icon-color": "neutral-gray-400",
|
|
340
|
+
variant: "tertiary",
|
|
341
|
+
onClick: async (f) => {
|
|
342
|
+
f.stopPropagation(), await A(n);
|
|
343
|
+
}
|
|
344
|
+
}, null, 8, ["onClick"]),
|
|
345
|
+
x(n) ? (u(), h(g, {
|
|
324
346
|
key: 0,
|
|
325
347
|
icon: "visibility",
|
|
326
348
|
"icon-color": "neutral-gray-400",
|
|
327
349
|
variant: "tertiary",
|
|
328
|
-
onClick: async (
|
|
329
|
-
|
|
330
|
-
name: t(
|
|
350
|
+
onClick: async (f) => {
|
|
351
|
+
f.stopPropagation(), await t(B).push({
|
|
352
|
+
name: t(K)["$connect-CAMPAIGN_VOUCHER_COLLECTIONS"],
|
|
331
353
|
params: { id: n._id }
|
|
332
354
|
});
|
|
333
355
|
}
|
|
334
|
-
}, null, 8, ["onClick"])) :
|
|
335
|
-
x(n) ? (u(), h(
|
|
356
|
+
}, null, 8, ["onClick"])) : L("", !0),
|
|
357
|
+
x(n) ? (u(), h(g, {
|
|
336
358
|
key: 1,
|
|
337
359
|
icon: "send",
|
|
338
360
|
"icon-color": "neutral-gray-400",
|
|
339
361
|
variant: "tertiary",
|
|
340
|
-
onClick: (
|
|
341
|
-
var
|
|
342
|
-
|
|
362
|
+
onClick: (f) => {
|
|
363
|
+
var M;
|
|
364
|
+
f.stopPropagation(), (M = t(V)) == null || M.showSheet({
|
|
343
365
|
campaignId: n._id
|
|
344
366
|
});
|
|
345
367
|
}
|
|
346
|
-
}, null, 8, ["onClick"])) :
|
|
347
|
-
l(
|
|
368
|
+
}, null, 8, ["onClick"])) : L("", !0),
|
|
369
|
+
l(g, {
|
|
348
370
|
icon: "delete",
|
|
349
371
|
"icon-color": "neutral-gray-400",
|
|
350
372
|
variant: "tertiary",
|
|
351
|
-
onClick: (
|
|
373
|
+
onClick: (f) => (f.stopPropagation(), O(n))
|
|
352
374
|
}, null, 8, ["onClick"])
|
|
353
375
|
])
|
|
354
376
|
];
|
|
@@ -358,37 +380,37 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
358
380
|
]),
|
|
359
381
|
_: 1
|
|
360
382
|
})
|
|
361
|
-
], 64)) : (u(), h(
|
|
383
|
+
], 64)) : (u(), h(oe, {
|
|
362
384
|
key: 1,
|
|
363
385
|
variant: "outlined",
|
|
364
386
|
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
365
387
|
}, {
|
|
366
|
-
default:
|
|
388
|
+
default: R(() => [
|
|
367
389
|
o[7] || (o[7] = c("img", {
|
|
368
|
-
src:
|
|
390
|
+
src: ie,
|
|
369
391
|
class: "aspect-square w-[150px]"
|
|
370
392
|
}, null, -1)),
|
|
371
|
-
c("div",
|
|
372
|
-
c("div",
|
|
373
|
-
c("div",
|
|
393
|
+
c("div", Be, [
|
|
394
|
+
c("div", Oe, v(t(a)("connect.voucher.createVoucherCampaign")), 1),
|
|
395
|
+
c("div", Ae, v(t(a)("connect.voucher.description")), 1)
|
|
374
396
|
]),
|
|
375
|
-
l(
|
|
397
|
+
l(g, {
|
|
376
398
|
variant: "primary",
|
|
377
399
|
label: t(a)("connect.voucher.createVoucherCampaign"),
|
|
378
400
|
icon: "add",
|
|
379
|
-
onClick: o[6] || (o[6] = (n) =>
|
|
401
|
+
onClick: o[6] || (o[6] = (n) => w())
|
|
380
402
|
}, null, 8, ["label"])
|
|
381
403
|
]),
|
|
382
404
|
_: 1
|
|
383
405
|
})),
|
|
384
|
-
l(
|
|
406
|
+
l(_e, {
|
|
385
407
|
ref_key: "sheetRef",
|
|
386
|
-
ref:
|
|
387
|
-
"onSubmit:modelValue":
|
|
408
|
+
ref: F,
|
|
409
|
+
"onSubmit:modelValue": Z
|
|
388
410
|
}, null, 512),
|
|
389
|
-
l(
|
|
411
|
+
l(Ce, {
|
|
390
412
|
ref_key: "sendVoucherSheetRef",
|
|
391
|
-
ref:
|
|
413
|
+
ref: V
|
|
392
414
|
}, null, 512)
|
|
393
415
|
])
|
|
394
416
|
], 64);
|
|
@@ -396,5 +418,5 @@ const we = { class: "px-24 flex flex-col gap-y-16" }, xe = { class: "flex items-
|
|
|
396
418
|
}
|
|
397
419
|
});
|
|
398
420
|
export {
|
|
399
|
-
|
|
421
|
+
ro as default
|
|
400
422
|
};
|
|
@@ -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-C1KlZBjR.js";
|
|
3
|
+
import { c as j } from "./index-Cvcgqzy5.js";
|
|
4
|
+
import { e as W, F as Y } from "./index-Bx_lUMxi.js";
|
|
5
|
+
import { C as ee } from "./membership-C_VLzMwg.js";
|
|
6
|
+
import { Z as V } from "./zod-jH-8jgB1.js";
|
|
7
|
+
import { _ as te } from "./SelectItems.vue_vue_type_script_setup_true_lang-iDaC99DI.js";
|
|
8
|
+
import { u as le } from "./business-bUX6raMw.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-DNEs_60Z.js";
|
|
11
|
+
import { _ as ae } from "./ImageInput.vue_vue_type_script_setup_true_lang-D3lV7JVV.js";
|
|
12
|
+
import { _ as ie, a as se } from "./EffectSheet.vue_vue_type_style_index_0_lang-BwSXXdG-.js";
|
|
13
|
+
import { _ as me } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-CDgL0WOA.js";
|
|
14
|
+
import { i as re } from "./helper-B9MQjEoz.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-jH-8jgB1.js";
|
|
3
|
+
import { u as V } from "./vue-i18n-C1KlZBjR.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"
|