@feedmepos/mf-connect 0.1.38-beta.7 → 0.1.38-beta.70
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-NNi-22sK.js → Analytic-qVhEo_im.js} +16 -16
- package/dist/{App-Bu14Mro_.js → App-Ixv1jrHc.js} +625 -619
- package/dist/AuditLogs-B2D62tMF.js +1991 -0
- package/dist/{Bin-CnAQA85j.js → Bin-Lj7jtS9m.js} +10 -10
- package/dist/Broadcast-BpP9VJsx.js +267 -0
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DC_fReu7.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BB43gKXv.js} +6 -6
- package/dist/{Card-DqAGiETA.js → Card-CjArjpou.js} +144 -140
- package/dist/Collections-CFzUAHxz.js +540 -0
- package/dist/Credit-D43x-T3d.js +261 -0
- package/dist/CustomSelect.vue_vue_type_script_setup_true_lang-Du7fRSZC.js +128 -0
- package/dist/{DateRangeChip.vue_vue_type_script_setup_true_lang-BUzUIIUW.js → DateRangeChip.vue_vue_type_script_setup_true_lang-eIoPtgO5.js} +1 -1
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-DlgTeQLe.js +3167 -0
- package/dist/EffectSheet.vue_vue_type_style_index_0_lang-9UhSzClJ.js +351 -0
- package/dist/Experience-BaUbRoHV.js +260 -0
- package/dist/{FileSaver.min-NlMItPOc.js → FileSaver.min-BO_rbswB.js} +1 -1
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js +129 -0
- package/dist/Game-DaVqgPWQ.js +331 -0
- package/dist/GenerateMaterial-DJM8fZyl.js +589 -0
- package/dist/Grab-CykZDrWI.js +301 -0
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-rWUkV9gn.js → ImageInput.vue_vue_type_script_setup_true_lang-C51yGAp9.js} +49 -48
- package/dist/{Index-loHkiwyo.js → Index-Do3WIIfM.js} +54 -54
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-CyGJxUol.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BjdBaj4c.js} +1 -1
- package/dist/{MainLayout-B1aJoR95.js → MainLayout-DD-OlYxZ.js} +1 -1
- package/dist/Marketing-C9bsnUaQ.js +145 -0
- package/dist/MarketingMaterialEdit-CbSh8dpn.js +746 -0
- package/dist/{Member-BQjQQdoA.js → Member-IcVRwAAS.js} +38 -37
- package/dist/{MemberList-WPsEUKf_.js → MemberList-C_A4PrQN.js} +158 -159
- package/dist/{MemberTransactions-BtM7dugy.js → MemberTransactions-CBoaY-gv.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-Bl9sFIwG.js → MessageInput.vue_vue_type_script_setup_true_lang-Dx28XNPi.js} +13463 -10597
- package/dist/Mission-COY_uhwz.js +335 -0
- package/dist/{Overview-Bsf5IPOg.js → Overview-DDSz2R4K.js} +24 -25
- package/dist/Point-C-KEwgx4.js +263 -0
- package/dist/Promotion-BpW9qWzf.js +397 -0
- package/dist/{Queue-XFVbSuDw.js → Queue-CO32O8i6.js} +14 -15
- package/dist/{Record-CQzujESE.js → Record-BrT5DR9L.js} +10 -10
- package/dist/{Reward-Dj_h_May.js → Reward-CbrEw-If.js} +16 -16
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-Clxk-oYM.js → RewardGroup.vue_vue_type_script_setup_true_lang-CpNjlbjZ.js} +13 -14
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-BS5jsRiN.js +1912 -0
- package/dist/{Segment-D_DUu_Sp.js → Segment-Cu9_qwXc.js} +273 -274
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-D3C2mVlv.js → SelectItems.vue_vue_type_script_setup_true_lang-BH-hzxSs.js} +23 -23
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-C0vsl8oV.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-DGm3gujH.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-5HkJROSb.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-DcUb8X-q.js} +4 -4
- package/dist/Setting-CQKfb5b_.js +1999 -0
- package/dist/SettingAdvertisements-BxR6Gl-5.js +263 -0
- package/dist/Store-6TUpmqAr.js +1995 -0
- package/dist/StoreRewards-BOThAOWU.js +534 -0
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-BYD229dz.js +1034 -0
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-CAamZtdf.js +7005 -0
- package/dist/{Tier-YQsLRt06.js → Tier-MF-ad-xm.js} +561 -480
- package/dist/{Title-C5gxYNvh.js → Title-MkjTHBzb.js} +149 -147
- package/dist/{Transaction-CZ_QdIii.js → Transaction-trYJwTrc.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-DqUu7wSt.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-DwlNK1TC.js} +7 -7
- package/dist/Voucher-BD5dTdht.js +422 -0
- package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-BhR_s48Q.js +421 -0
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-DCtdp-LK.js → ZodTextField.vue_vue_type_script_setup_true_lang-CcTe5TJL.js} +2 -2
- package/dist/app-CybjF-6Q.js +59071 -0
- package/dist/app.js +1 -1
- package/dist/{business-DZYFoAKz.js → business-2hCbD0JX.js} +11 -8
- package/dist/{campaign-Ca4l6UUg.js → campaign-Bv-8uM2S.js} +29 -25
- package/dist/campaign-h1J8NTAo.js +253 -0
- package/dist/campaign.enum-Dea0E4o1.js +26 -0
- package/dist/campaign.fn-DqxZMyu0.js +776 -0
- package/dist/{collectible.enum-DnIeDAB-.js → collectible.enum-DOyAoz4F.js} +1 -1
- package/dist/{collection.fn-mQfXEwJv.js → collection.fn-DU2HuZod.js} +2 -2
- package/dist/dto-CT65-FHY.js +222 -0
- package/dist/duplicateCampaign-YJGHvOqb.js +51 -0
- package/dist/effect-XZ767UQ4.js +89 -0
- package/dist/{email-addresses-CQYqi2rN.js → email-addresses-DSgkxSnV.js} +2 -2
- package/dist/{export-BsikVZw2.js → export-4gx5C9s9.js} +9 -10
- package/dist/{helper-n74IteBU.js → helper-HOLsJca3.js} +22 -7
- package/dist/index-BO7N-s4K.js +8912 -0
- package/dist/{index-Dt6wui_L.js → index-BfRa1sI3.js} +3 -3
- package/dist/index-BnCtmlvU.js +28897 -0
- package/dist/{index-Bg3fAg5z.js → index-C5VvGYtP.js} +1 -1
- package/dist/index-CSzvYzf4.js +3419 -0
- package/dist/{index-Do7TcKmg.js → index-CrdkPXsx.js} +4 -1
- package/dist/index-CuvNtC_M.js +61 -0
- package/dist/{index-DTErPYrT.js → index-CxE-VVlL.js} +1 -1
- package/dist/{index-DRrSsoqp.js → index-Djenbz3F.js} +1 -1
- package/dist/{index-BJ-IAF-1.js → index-IHteBJ_D.js} +1 -1
- package/dist/{index-BpjT8Rx0.js → index-dUhOAfj9.js} +455 -245
- package/dist/index-wm4nGBB_.js +30289 -0
- package/dist/{index-CrHCbDIs.js → index-xTrAj026.js} +3 -3
- package/dist/index-yViT18i_.js +36 -0
- package/dist/{index.esm2017-T7F54Aqa.js → index.esm2017-Wq4FUMEv.js} +185 -185
- package/dist/loading-D22xapd8.js +215 -0
- package/dist/{lodash-B5I3zXaY.js → lodash-HM6bxuWV.js} +1 -1
- package/dist/{membership-BRy4jMt2.js → membership-CX464ZBI.js} +3 -3
- package/dist/{moment-BWErdI6_.js → moment-D7p2TMB-.js} +6 -1
- package/dist/{money-B9Auav5u.js → money-B3cPZAZu.js} +1 -1
- package/dist/{number-BdhIBsUp.js → number-DT65dEZt.js} +1 -1
- package/dist/objectid-DZWw4iLL.js +145 -0
- package/dist/{campaign-162kZMje.js → plugins-D-4BlIGs.js} +784 -777
- package/dist/remy-D_Deb3ue.js +13 -0
- package/dist/{reward-UuqZUHsq.js → reward-C6B-kn0X.js} +1 -1
- package/dist/{rule-D158NIpm.js → rule-B94SrDX1.js} +505 -487
- package/dist/rule-builder-CQ3uHeX4.js +102 -0
- package/dist/style.css +11 -2
- package/dist/template-CXB2Ez2S.js +188 -0
- package/dist/timezone-D3NuV-rx.js +1154 -0
- package/dist/trigger-BsCVC_nU.js +213 -0
- package/dist/usePagination-BOZ0-D67.js +223 -0
- package/dist/user-Dxp7kluY.js +55 -0
- package/dist/vue-i18n-DpCWu1gI.js +2365 -0
- package/dist/{xlsx-Ddqi5i8p.js → xlsx-Cc2a2IL9.js} +1 -1
- package/dist/{zod-Bg2FbC-D.js → zod-BCSHGdXs.js} +32 -31
- package/package.json +14 -6
- package/dist/AuditLogs-Cai9CVBl.js +0 -1887
- package/dist/Broadcast-DskXjXn4.js +0 -227
- package/dist/Collections-DuaIQAk7.js +0 -465
- package/dist/Credit-D40Vzu2g.js +0 -222
- package/dist/CustomSelect.vue_vue_type_script_setup_true_lang-DLnvDVgf.js +0 -108
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-BsQ4iAsV.js +0 -2185
- package/dist/EffectSheet.vue_vue_type_style_index_0_lang-CDCX5B5k.js +0 -347
- package/dist/Experience-B9yHQPuj.js +0 -223
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-d8rh38tD.js +0 -114
- package/dist/Game-e9-Q3qmO.js +0 -278
- package/dist/Marketing-CipbukIV.js +0 -20073
- package/dist/Mission-B_DJ3Yu_.js +0 -296
- package/dist/Point-DMphcWjy.js +0 -226
- package/dist/Promotion-B33A-Jwe.js +0 -289
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-CGAXTOLN.js +0 -1751
- package/dist/Setting-CtdC4G3W.js +0 -1936
- package/dist/Store-DCksWACh.js +0 -1842
- package/dist/StoreRewards-CHWKYKet.js +0 -423
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-D1TDyD6N.js +0 -1029
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-D59sGO3F.js +0 -139
- package/dist/Voucher-BzV8yZ3o.js +0 -384
- package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-DjBj_3EF.js +0 -419
- package/dist/_commonjsHelpers-BkfeUUK-.js +0 -28
- package/dist/app-FFOpPHwj.js +0 -33357
- package/dist/app-az9e8Yfl.js +0 -7086
- package/dist/campaign.enum-DWjyDV2D.js +0 -20
- package/dist/campaign.fn-DWWJ74z-.js +0 -758
- package/dist/dto-mKZIPV4o.js +0 -214
- package/dist/effect-B8UexeyG.js +0 -78
- package/dist/index-5ShiAY8U.js +0 -8861
- package/dist/index-Bf6AmJwX.js +0 -32260
- package/dist/index-C5gjIb5d.js +0 -146
- package/dist/index-C9YrDtDN.js +0 -38
- package/dist/index-CK-MAqWE.js +0 -3120
- package/dist/index-CsaQJMAR.js +0 -66
- package/dist/index-f4MzX8IY.js +0 -30038
- package/dist/loading-BEAayQS-.js +0 -71
- package/dist/objectid-K-JVTsfA.js +0 -145
- package/dist/plugins-CWlRYif_.js +0 -208
- package/dist/remy-vue-client-Cpppk9h-.js +0 -1693
- package/dist/rule-builder-DNeViq0I.js +0 -89
- package/dist/template-B02wYF7G.js +0 -190
- package/dist/trigger-BDjnKHLI.js +0 -144
- package/dist/usePagination-BeF5K3M7.js +0 -223
- package/dist/user-DbP37Ohh.js +0 -54
- package/dist/vue-i18n-BbhkYWlk.js +0 -2365
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { defineComponent as C, ref as c, h as s, onMounted as x, resolveComponent as d, openBlock as S, createElementBlock as B, Fragment as M, createVNode as l, unref as o, createElementVNode as u } from "vue";
|
|
2
2
|
import { components as p } from "@feedmepos/ui-library";
|
|
3
|
-
import { u as K } from "./loading-
|
|
4
|
-
import { u as R } from "./business-
|
|
5
|
-
import { C as A } from "./campaign-
|
|
6
|
-
import { _ as P } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-
|
|
3
|
+
import { u as K } from "./loading-D22xapd8.js";
|
|
4
|
+
import { u as R } from "./business-2hCbD0JX.js";
|
|
5
|
+
import { C as A } from "./campaign-h1J8NTAo.js";
|
|
6
|
+
import { _ as P } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-DlgTeQLe.js";
|
|
7
7
|
import { _ as U } from "./ChipMenu.vue_vue_type_script_setup_true_lang-BPpZZNkr.js";
|
|
8
|
-
import { _ as Y } from "./SendVoucherSheet.vue_vue_type_script_setup_true_lang-
|
|
9
|
-
import { u as D } from "./vue-i18n-
|
|
10
|
-
import { h as E } from "./moment-
|
|
11
|
-
import { p as I } from "./plugins-
|
|
12
|
-
import { c as g } from "./index-
|
|
8
|
+
import { _ as Y } from "./SendVoucherSheet.vue_vue_type_script_setup_true_lang-DcUb8X-q.js";
|
|
9
|
+
import { u as D } from "./vue-i18n-DpCWu1gI.js";
|
|
10
|
+
import { h as E } from "./moment-D7p2TMB-.js";
|
|
11
|
+
import { p as I } from "./plugins-D-4BlIGs.js";
|
|
12
|
+
import { c as g } from "./index-CrdkPXsx.js";
|
|
13
13
|
const T = { class: "px-24 flex flex-col gap-y-16" }, $ = { class: "flex items-center justify-between w-full" }, j = { class: "flex gap-8 overflow-x-auto" }, oe = /* @__PURE__ */ C({
|
|
14
14
|
__name: "Bin",
|
|
15
15
|
setup(H) {
|
|
@@ -115,7 +115,7 @@ const T = { class: "px-24 flex flex-col gap-y-16" }, $ = { class: "flex items-ce
|
|
|
115
115
|
l(h, {
|
|
116
116
|
modelValue: o(a).searchKey,
|
|
117
117
|
"onUpdate:modelValue": t[0] || (t[0] = (r) => o(a).searchKey = r),
|
|
118
|
-
class: "hidden xs
|
|
118
|
+
class: "hidden xs:!block border-b-2 border-fm-color-neutral-gray-100",
|
|
119
119
|
placeholder: o(n)("connect.voucher.search"),
|
|
120
120
|
collapsible: ""
|
|
121
121
|
}, null, 8, ["modelValue", "placeholder"]),
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
import { defineComponent as H, ref as C, computed as q, onMounted as z, resolveComponent as m, openBlock as d, createElementBlock as h, Fragment as v, createVNode as i, unref as a, createElementVNode as n, withCtx as x, renderList as G, createBlock as S, resolveDynamicComponent as J, toDisplayString as u, createCommentVNode as Q, h as k } from "vue";
|
|
2
|
+
import { _ as W } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { useDialog as X, components as L } from "@feedmepos/ui-library";
|
|
4
|
+
import { p as Y } from "./plugins-D-4BlIGs.js";
|
|
5
|
+
import { u as Z } from "./loading-D22xapd8.js";
|
|
6
|
+
import { u as ee } from "./business-2hCbD0JX.js";
|
|
7
|
+
import { u as te } from "./campaign-Bv-8uM2S.js";
|
|
8
|
+
import { b as V, c as R, a as ae } from "./campaign-h1J8NTAo.js";
|
|
9
|
+
import { c as oe, p as ne } from "./duplicateCampaign-YJGHvOqb.js";
|
|
10
|
+
import { u as se } from "./vue-i18n-DpCWu1gI.js";
|
|
11
|
+
import { _ as ce } from "./FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js";
|
|
12
|
+
import { _ as ie } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-DlgTeQLe.js";
|
|
13
|
+
import { u as re } from "./template-CXB2Ez2S.js";
|
|
14
|
+
import { c as f } from "./index-CrdkPXsx.js";
|
|
15
|
+
const le = { class: "px-24 flex flex-col gap-y-16" }, me = { class: "flex items-center justify-between w-full" }, de = { class: "flex gap-8 overflow-x-auto" }, pe = { class: "space-y-8" }, ue = { class: "flex w-full gap-4 items-center" }, fe = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ge = { class: "space-y-4" }, ye = { class: "fm-typo-en-body-lg-600" }, _e = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, he = { class: "flex items-center gap-8" }, we = { key: 0 }, be = { class: "text-fm-color-typo-secondary fm-typo-en-body-md-600" }, Ce = { class: "flex flex-col gap-16 text-center" }, ve = { class: "fm-typo-en-title-sm-800" }, xe = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, je = /* @__PURE__ */ H({
|
|
16
|
+
__name: "Broadcast",
|
|
17
|
+
setup(Se) {
|
|
18
|
+
const { t: s } = se(), O = {
|
|
19
|
+
label: s("connect.campaign.common.createCampaign"),
|
|
20
|
+
value: "create",
|
|
21
|
+
isPrimary: !0,
|
|
22
|
+
prependIcon: "add"
|
|
23
|
+
}, T = re("BROADCAST", X()), I = ee(), p = te(), { global: K, minor: F } = Z, B = C((/* @__PURE__ */ new Date()).toISOString()), r = C({
|
|
24
|
+
searchKey: "",
|
|
25
|
+
location: []
|
|
26
|
+
});
|
|
27
|
+
function P(e) {
|
|
28
|
+
const t = r.value.location;
|
|
29
|
+
return !t || t.length === 0 || !e.targetLocation ? !0 : Array.isArray(t) ? t.some((l) => {
|
|
30
|
+
var c;
|
|
31
|
+
return (c = e == null ? void 0 : e.targetLocation) == null ? void 0 : c.includes(l);
|
|
32
|
+
}) : e.targetLocation.includes(t);
|
|
33
|
+
}
|
|
34
|
+
const g = q(
|
|
35
|
+
() => p.campaigns.broadcast.filter((e) => P(e))
|
|
36
|
+
), $ = [
|
|
37
|
+
{
|
|
38
|
+
header: "Broadcast title",
|
|
39
|
+
accessorFn: (e) => e.name
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
header: "Status",
|
|
43
|
+
accessorFn: (e) => ae(e),
|
|
44
|
+
cell(e) {
|
|
45
|
+
return V(e.row.original);
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
header: "Summary",
|
|
50
|
+
accessorFn: (e) => R(e)
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
header: "Message sent",
|
|
54
|
+
accessorFn: (e) => e.currentReceive ?? "N/A"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
header: "Actions",
|
|
58
|
+
cell(e) {
|
|
59
|
+
return k("div", { class: "flex items-center gap-8 justify-end" }, [
|
|
60
|
+
k(L.FmButton, {
|
|
61
|
+
variant: "tertiary",
|
|
62
|
+
icon: "content_copy",
|
|
63
|
+
iconColor: "neutral-gray-400",
|
|
64
|
+
onClick: async (t) => {
|
|
65
|
+
t.stopPropagation(), await D(e.row.original);
|
|
66
|
+
}
|
|
67
|
+
}),
|
|
68
|
+
k(L.FmButton, {
|
|
69
|
+
variant: "tertiary",
|
|
70
|
+
icon: "delete",
|
|
71
|
+
iconColor: "neutral-gray-400",
|
|
72
|
+
onClick: (t) => {
|
|
73
|
+
t.stopPropagation(), A(e.row.original);
|
|
74
|
+
}
|
|
75
|
+
})
|
|
76
|
+
]);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
], w = C();
|
|
80
|
+
async function A(e) {
|
|
81
|
+
await Y.remove(
|
|
82
|
+
s("connect.campaign.common.remove.confirm", { name: e.name })
|
|
83
|
+
) && await F(
|
|
84
|
+
async () => {
|
|
85
|
+
await f.delete(e._id), await p.read("BROADCAST");
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
message: s("connect.campaign.common.remove.removing", { name: e.name }),
|
|
89
|
+
successMessage: s("connect.campaign.common.remove.removed", {
|
|
90
|
+
name: e.name
|
|
91
|
+
})
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
}
|
|
95
|
+
async function y(e) {
|
|
96
|
+
B.value = (/* @__PURE__ */ new Date()).toISOString(), e ? await t() : T.open(async (l) => {
|
|
97
|
+
await t(l);
|
|
98
|
+
});
|
|
99
|
+
async function t(l) {
|
|
100
|
+
var c;
|
|
101
|
+
(c = w.value) == null || c.showSheet(
|
|
102
|
+
!0,
|
|
103
|
+
"BROADCAST",
|
|
104
|
+
e ? await f.readById(e._id) : void 0,
|
|
105
|
+
l
|
|
106
|
+
);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
async function D(e) {
|
|
110
|
+
var c;
|
|
111
|
+
if (!await oe(e.name))
|
|
112
|
+
return;
|
|
113
|
+
B.value = (/* @__PURE__ */ new Date()).toISOString();
|
|
114
|
+
const t = await f.readById(e._id), l = ne(t);
|
|
115
|
+
(c = w.value) == null || c.showSheet(
|
|
116
|
+
!0,
|
|
117
|
+
"BROADCAST",
|
|
118
|
+
l,
|
|
119
|
+
t.template
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
async function j(e) {
|
|
123
|
+
await F(
|
|
124
|
+
async () => {
|
|
125
|
+
e.campaign._id ? await f.update(e.campaign._id, e) : await f.create(e), await p.read("BROADCAST");
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
message: s(
|
|
129
|
+
`connect.campaign.broadcast.update.${e.campaign._id ? "updating" : "creating"}`
|
|
130
|
+
),
|
|
131
|
+
successMessage: s("connect.campaign.broadcast.update.success", {
|
|
132
|
+
action: e.campaign._id ? "updated" : "created"
|
|
133
|
+
})
|
|
134
|
+
}
|
|
135
|
+
);
|
|
136
|
+
}
|
|
137
|
+
return z(async () => {
|
|
138
|
+
await K(async () => {
|
|
139
|
+
await p.read("BROADCAST");
|
|
140
|
+
});
|
|
141
|
+
}), (e, t) => {
|
|
142
|
+
const l = m("FmPageHead"), c = m("FmSearch"), M = m("FmTable"), b = m("FmButton"), N = m("FmListItem"), U = m("FmList"), E = m("FmCard");
|
|
143
|
+
return d(), h(v, null, [
|
|
144
|
+
i(l, {
|
|
145
|
+
title: a(s)("connect.campaign.broadcast.title"),
|
|
146
|
+
actions: a(g).length > 0 ? [O] : [],
|
|
147
|
+
"onClick:action": t[0] || (t[0] = () => y())
|
|
148
|
+
}, null, 8, ["title", "actions"]),
|
|
149
|
+
n("div", le, [
|
|
150
|
+
i(c, {
|
|
151
|
+
modelValue: a(r).searchKey,
|
|
152
|
+
"onUpdate:modelValue": t[1] || (t[1] = (o) => a(r).searchKey = o),
|
|
153
|
+
class: "hidden xs:!block sm:!block border-b-2 border-fm-color-neutral-gray-100",
|
|
154
|
+
placeholder: a(s)("connect.campaign.common.search"),
|
|
155
|
+
collapsible: ""
|
|
156
|
+
}, null, 8, ["modelValue", "placeholder"]),
|
|
157
|
+
a(p).campaigns.broadcast && a(p).campaigns.broadcast.length > 0 ? (d(), h(v, { key: 0 }, [
|
|
158
|
+
n("div", me, [
|
|
159
|
+
n("div", de, [
|
|
160
|
+
i(ce, {
|
|
161
|
+
label: `${a(s)("connect.campaign.common.location")}: `,
|
|
162
|
+
"right-icon": "keyboard_arrow_down",
|
|
163
|
+
modelValue: a(r).location,
|
|
164
|
+
"onUpdate:modelValue": t[2] || (t[2] = (o) => a(r).location = o),
|
|
165
|
+
icon: "storefront",
|
|
166
|
+
"show-item-label": !0,
|
|
167
|
+
items: a(I).locationOptions
|
|
168
|
+
}, null, 8, ["label", "modelValue", "items"])
|
|
169
|
+
]),
|
|
170
|
+
i(c, {
|
|
171
|
+
modelValue: a(r).searchKey,
|
|
172
|
+
"onUpdate:modelValue": t[3] || (t[3] = (o) => a(r).searchKey = o),
|
|
173
|
+
class: "xs:hidden sm:hidden",
|
|
174
|
+
placeholder: "search",
|
|
175
|
+
collapsible: ""
|
|
176
|
+
}, null, 8, ["modelValue"])
|
|
177
|
+
]),
|
|
178
|
+
i(M, {
|
|
179
|
+
class: "xs:hidden sm:hidden",
|
|
180
|
+
"row-data": a(g),
|
|
181
|
+
"column-defs": $,
|
|
182
|
+
"search-value": a(r).searchKey,
|
|
183
|
+
"column-filter": [],
|
|
184
|
+
onRowClick: t[4] || (t[4] = (o) => y(o.original)),
|
|
185
|
+
"hide-footer": !0
|
|
186
|
+
}, null, 8, ["row-data", "search-value"]),
|
|
187
|
+
i(U, { class: "hidden xs:!flex sm:!flex flex-col mx-[-24px]" }, {
|
|
188
|
+
default: x(() => [
|
|
189
|
+
(d(!0), h(v, null, G(a(g).filter(
|
|
190
|
+
(o) => o.name.toLowerCase().includes(a(r).searchKey.toLowerCase())
|
|
191
|
+
), (o) => (d(), S(N, {
|
|
192
|
+
key: o._id.toString(),
|
|
193
|
+
onClick: (_) => y(o),
|
|
194
|
+
class: "py-12 px-16 flex items-center justify-between border-b border-fm-color-neutral-gray-100"
|
|
195
|
+
}, {
|
|
196
|
+
default: x(() => [
|
|
197
|
+
n("div", pe, [
|
|
198
|
+
n("div", ue, [
|
|
199
|
+
(d(), S(J(a(V)(o)))),
|
|
200
|
+
n("div", fe, u(o.currentReceive ?? 0) + " sent ", 1)
|
|
201
|
+
]),
|
|
202
|
+
n("div", ge, [
|
|
203
|
+
n("div", ye, u(o.name), 1),
|
|
204
|
+
n("div", _e, u(a(R)(o)), 1)
|
|
205
|
+
])
|
|
206
|
+
]),
|
|
207
|
+
n("div", he, [
|
|
208
|
+
i(b, {
|
|
209
|
+
icon: "content_copy",
|
|
210
|
+
"icon-color": "neutral-gray-400",
|
|
211
|
+
variant: "tertiary",
|
|
212
|
+
onClick: async (_) => {
|
|
213
|
+
_.stopPropagation(), await D(o);
|
|
214
|
+
}
|
|
215
|
+
}, null, 8, ["onClick"]),
|
|
216
|
+
i(b, {
|
|
217
|
+
icon: "delete",
|
|
218
|
+
"icon-color": "neutral-gray-400",
|
|
219
|
+
variant: "tertiary",
|
|
220
|
+
onClick: (_) => (_.stopPropagation(), A(o))
|
|
221
|
+
}, null, 8, ["onClick"])
|
|
222
|
+
])
|
|
223
|
+
]),
|
|
224
|
+
_: 2
|
|
225
|
+
}, 1032, ["onClick"]))), 128))
|
|
226
|
+
]),
|
|
227
|
+
_: 1
|
|
228
|
+
}),
|
|
229
|
+
a(g).length == 0 ? (d(), h("div", we, [
|
|
230
|
+
n("div", be, u(a(s)("connect.campaign.common.noResults")), 1)
|
|
231
|
+
])) : Q("", !0)
|
|
232
|
+
], 64)) : (d(), S(E, {
|
|
233
|
+
key: 1,
|
|
234
|
+
variant: "outlined",
|
|
235
|
+
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
236
|
+
}, {
|
|
237
|
+
default: x(() => [
|
|
238
|
+
t[6] || (t[6] = n("img", {
|
|
239
|
+
src: W,
|
|
240
|
+
class: "aspect-square w-[150px]"
|
|
241
|
+
}, null, -1)),
|
|
242
|
+
n("div", Ce, [
|
|
243
|
+
n("div", ve, u(a(s)("connect.campaign.broadcast.create.title")), 1),
|
|
244
|
+
n("div", xe, u(a(s)("connect.campaign.broadcast.create.description")), 1)
|
|
245
|
+
]),
|
|
246
|
+
i(b, {
|
|
247
|
+
variant: "primary",
|
|
248
|
+
label: a(s)("connect.campaign.broadcast.create.button"),
|
|
249
|
+
icon: "add",
|
|
250
|
+
onClick: t[5] || (t[5] = (o) => y())
|
|
251
|
+
}, null, 8, ["label"])
|
|
252
|
+
]),
|
|
253
|
+
_: 1
|
|
254
|
+
})),
|
|
255
|
+
i(ie, {
|
|
256
|
+
ref_key: "sheetRef",
|
|
257
|
+
ref: w,
|
|
258
|
+
"onSubmit:modelValue": j
|
|
259
|
+
}, null, 512)
|
|
260
|
+
])
|
|
261
|
+
], 64);
|
|
262
|
+
};
|
|
263
|
+
}
|
|
264
|
+
});
|
|
265
|
+
export {
|
|
266
|
+
je as default
|
|
267
|
+
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { R as RuleOperator, _ } from "./index-
|
|
2
|
-
import { i as isRuleGroup } from "./rule-builder-
|
|
1
|
+
import { R as RuleOperator, _ } from "./index-BO7N-s4K.js";
|
|
2
|
+
import { i as isRuleGroup } from "./rule-builder-CQ3uHeX4.js";
|
|
3
3
|
import { defineComponent, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, createElementBlock, Fragment, renderList, createVNode, toDisplayString } from "vue";
|
|
4
4
|
import { useDialog } from "@feedmepos/ui-library";
|
|
5
|
-
import "./index-
|
|
6
|
-
import { a as F_RUNNABLE_CAMPAIGN_TYPE } from "./index-
|
|
7
|
-
import "./index-
|
|
8
|
-
import "./index-
|
|
5
|
+
import "./index-dUhOAfj9.js";
|
|
6
|
+
import { a as F_RUNNABLE_CAMPAIGN_TYPE } from "./index-CSzvYzf4.js";
|
|
7
|
+
import "./index-wm4nGBB_.js";
|
|
8
|
+
import "./index-BfRa1sI3.js";
|
|
9
9
|
function validateRule(data, r, date) {
|
|
10
10
|
const rules = new RuleOperator(date ?? /* @__PURE__ */ new Date());
|
|
11
11
|
function meetConditions(e) {
|