@feedmepos/mf-connect 0.1.98-beta.7 → 0.1.98-beta.71
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-BonFFUVJ.js → App-B-Onur9k.js} +812 -666
- package/dist/{AuditLogs-CaQisyMC.js → AuditLogs-BnEeKG1C.js} +14 -13
- package/dist/{Bin-Mu8gAiHw.js → Bin-BH9_nATR.js} +8 -8
- package/dist/Broadcast-Gt2ZLLpZ.js +302 -0
- package/dist/CampaignAnalytic-BT6zTgNk.js +1830 -0
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BoLZVrCU.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-nNLLEzii.js} +6 -5
- package/dist/Card-dD52oor7.js +1084 -0
- package/dist/{Collections-CByXxRW_.js → Collections-7bwYNl3M.js} +14 -13
- package/dist/Credit-qZdlqXqR.js +286 -0
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-DeNn_k19.js +53 -0
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-C09W9Qja.js +4213 -0
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-BXsAX1Xa.js → EffectSheet.vue_vue_type_style_index_0_lang-Bz1HRBMa.js} +35 -35
- package/dist/{Experience-B7J-aqPK.js → Experience-CAaWgWXP.js} +112 -86
- package/dist/{FileSaver.min-D_F_MSZt.js → FileSaver.min-BpfY6VnX.js} +1 -1
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-3bH-tZAm.js +138 -0
- package/dist/Game-fhrbFb_5.js +356 -0
- package/dist/GiftCardSetup-CTwmNKim.js +736 -0
- package/dist/{Grab-C45MmlD9.js → Grab-BnPfb92x.js} +33 -32
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-CPPcB3PC.js → ImageInput.vue_vue_type_script_setup_true_lang-BySju1oT.js} +1 -1
- package/dist/{Index-vQ6uP49O.js → Index-DRwvmm_j.js} +10 -10
- package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-Cj3hN3tg.js → LocationPicker.vue_vue_type_script_setup_true_lang-Ya4r9NNE.js} +1 -1
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-DU9eIein.js → LottieAnimation.vue_vue_type_script_setup_true_lang-CDwtqqLQ.js} +1 -1
- package/dist/LoyaltyDashboard-8jn6SIWo.js +2865 -0
- package/dist/MainLayout-Bf42AcB1.js +143 -0
- package/dist/{Marketing-B6xMdQvW.js → Marketing-DruTMjiR.js} +7 -6
- package/dist/{MarketingMaterialEdit-0cZN4bek.js → MarketingMaterialEdit-moEHd_gP.js} +15 -14
- package/dist/Member-C9VTQqIm.js +654 -0
- package/dist/MemberDetailSheet.vue_vue_type_script_setup_true_lang-DEsVSWmv.js +1279 -0
- package/dist/MemberImportHistory-DZVwya9v.js +187 -0
- package/dist/MemberList-KusIfy1u.js +334 -0
- package/dist/{MemberTransactions-Bg-ziZy8.js → MemberTransactions-msyjdzlI.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-jbDJkbZh.js → MessageInput.vue_vue_type_script_setup_true_lang-DbV-m3cC.js} +5928 -5644
- package/dist/MetricInfoTooltip.vue_vue_type_script_setup_true_lang-1DYGpJnD.js +40 -0
- package/dist/Mission-CUUxpBUF.js +360 -0
- package/dist/{Overview-nsyJGSCq.js → Overview-C9jyKXHX.js} +21 -20
- package/dist/Overview-CYKoF8Hp.js +1316 -0
- package/dist/Point-CPpQ07yp.js +288 -0
- package/dist/Promotion-CJ95m9Qb.js +423 -0
- package/dist/{Queue-Dkipt6fw.js → Queue-CX39ILh_.js} +14 -13
- package/dist/{Record-BFqx6vM-.js → Record-6I0qyXB5.js} +9 -9
- package/dist/Review-DoWu2XNT.js +45 -0
- package/dist/ReviewFacebookCallback-Co-5TnI7.js +238 -0
- package/dist/ReviewGoogleCallback-Ca7ZuMcF.js +213 -0
- package/dist/{Reward-DjFEE7I_.js → Reward-Cx_N6qBJ.js} +35 -35
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-BzZ6VH80.js → RewardGroup.vue_vue_type_script_setup_true_lang-Cn5Yp37p.js} +14 -13
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-A9jQX4jt.js → RuleGroup.vue_vue_type_script_setup_true_lang-M0c67Dyl.js} +196 -186
- package/dist/{Segment-BAjdUfZ6.js → Segment-Bx0EW966.js} +275 -276
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-CAQPFzRH.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-ahvrEUGa.js} +37 -36
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-Gkz8jhES.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-C7zSfZdl.js} +4 -4
- package/dist/{Setting-BK7y0XC-.js → Setting-DzEK3dWj.js} +14 -14
- package/dist/{SettingAdvertisements-DfQ645xr.js → SettingAdvertisements-BNALbI88.js} +12 -12
- package/dist/Settings-Cw85-xzq.js +230 -0
- package/dist/Store-BSqW1gwf.js +2612 -0
- package/dist/{StoreRewards-usHKOGmB.js → StoreRewards-CJXnS8Qf.js} +15 -15
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-C6tUwHEj.js +1329 -0
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-DrcWUZuR.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-iylphGuV.js} +2 -2
- package/dist/{Tier-BF3V430O.js → Tier-DfitNxp2.js} +2580 -754
- package/dist/{Title-DwPuqKfJ.js → Title-QCbtOvKB.js} +39 -37
- package/dist/Transaction-dOCzlidD.js +45 -0
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-DToNRTJS.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-Be5X1C-Y.js} +26 -26
- package/dist/{Voucher-DnhVIl_o.js → Voucher-BfoCDwjg.js} +156 -133
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-Btb3UZCn.js → VoucherEditor.vue_vue_type_script_setup_true_lang-0EIYoZ0F.js} +118 -124
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-EFUW9DMY.js → ZodTextField.vue_vue_type_script_setup_true_lang-UdStgKbX.js} +2 -2
- package/dist/{app-i3r-6ZVm.js → app-BxTElIm-.js} +45168 -37577
- package/dist/app.js +1 -1
- package/dist/base.export-BmUK8hMh.js +75 -0
- package/dist/{business-i0Gxk7gG.js → business-DjAiT8tR.js} +5 -5
- package/dist/campaign-DlR3KF9m.js +368 -0
- package/dist/campaign-tAmQNoq7.js +100 -0
- package/dist/{campaign.enum-CbUTfxek.js → campaign.enum-BjwEQd11.js} +1 -1
- package/dist/{campaign.fn-BjHSIDd1.js → campaign.fn-C6kWWIQx.js} +53 -53
- package/dist/{collectible.enum-DN7E_kHg.js → collectible.enum-BrtXpT9S.js} +1 -1
- package/dist/collection.fn-CDhfM3Eq.js +26 -0
- package/dist/currency-10nX5QnT.js +7 -0
- package/dist/{duplicateCampaign-DmdJQEIA.js → duplicateCampaign-6oMZOvfM.js} +11 -11
- package/dist/{effect-DM4AzeQl.js → effect-T4YzuTc5.js} +1 -1
- package/dist/{email-addresses-BlqVJhwZ.js → email-addresses-BjODnJMM.js} +209 -201
- package/dist/google-C3S8u0mT.js +4 -0
- package/dist/{helper-CkdISSVP.js → helper-BCl5r5yZ.js} +1 -1
- package/dist/{index-DgzNGQgE.js → index-B9ZMIUMa.js} +2083 -2559
- package/dist/{index-CB7ytKOE.js → index-BBsK7TUw.js} +1588 -1522
- package/dist/index-BQk6zTgf.js +32437 -0
- package/dist/index-Bd4clHfr.js +901 -0
- package/dist/index-BeVWchv7.js +14550 -0
- package/dist/index-Bht1Z11w.js +72 -0
- package/dist/{index-FD50UHqf.js → index-BiolIgqR.js} +105 -123
- package/dist/{index-Cl8t41Sk.js → index-BxU--5J5.js} +5 -5
- package/dist/index-Bz6oSli7.js +151 -0
- package/dist/index-C5IfNJUl.js +53 -0
- package/dist/{index-BWsj6lCJ.js → index-CRvUvCMA.js} +14 -14
- package/dist/{index-B6xi1soU.js → index-CnaQt4Pn.js} +1 -1
- package/dist/{index-4EtrCy_K.js → index-Ctja--IE.js} +4 -4
- package/dist/{index-D6qeYVNz.js → index-D8rGhchh.js} +1 -1
- package/dist/{index-BrboOmPq.js → index-DJdTDF9C.js} +347 -216
- package/dist/index-DXiJa8Cw.js +137 -0
- package/dist/{index-CxdLExX0.js → index-DeQKLilv.js} +24 -9
- package/dist/{index-vI-ndGu_.js → index-DhtKt4OL.js} +5 -5
- package/dist/{index.esm2017-BX5CyKoc.js → index.esm2017-CEOegJjn.js} +132 -132
- package/dist/{loading-DTKDhqew.js → loading-Dx4SCvZY.js} +1 -1
- package/dist/{lodash-CCPBsqhe.js → lodash-Dq8OKCKK.js} +1 -1
- package/dist/member-import-DX-jn2uk.js +187 -0
- package/dist/membership-CltAa-gH.js +274 -0
- package/dist/{money-wMK3QkZ5.js → money-DsaAjJTI.js} +1 -1
- package/dist/{number-DjKVlWn0.js → number-DmhHKYgY.js} +1 -1
- package/dist/objectid-BdNv-dZX.js +145 -0
- package/dist/{plugins-D25PaNJk.js → plugins-BFKVM3uC.js} +13 -12
- package/dist/remy-Qz_pNsUS.js +13 -0
- package/dist/{reward-E63jqJHm.js → reward--SjvIeyy.js} +1 -1
- package/dist/{rule-RVvPtAnk.js → rule-CAKdNobZ.js} +335 -275
- package/dist/style.css +1 -1
- package/dist/{template-zNxOQaqe.js → template-Cfxc5eM8.js} +6 -6
- package/dist/timezone-D2b-V5XD.js +20 -0
- package/dist/transaction.fn-B5mLY7bz.js +71 -0
- package/dist/{trigger-BXV02FhP.js → trigger-DvYcjRBZ.js} +17 -17
- package/dist/useMarketingMaterialActions-DtqnjMSt.js +96 -0
- package/dist/{usePagination-BPcPhEnp.js → usePagination-DKX24g31.js} +1 -1
- package/dist/{user-Bd8S7R5u.js → user-fWb1NxGO.js} +1 -1
- package/dist/vue-i18n-wJReAVJw.js +2365 -0
- package/dist/{xlsx-_tQC9Ezf.js → xlsx-Mthhu4JR.js} +440 -440
- package/dist/{zod-C1j2GLZP.js → zod-CVpVUgBZ.js} +1 -1
- package/package.json +10 -6
- package/dist/Broadcast-Cy-i-WOT.js +0 -266
- package/dist/Card-f2XOtWxp.js +0 -910
- package/dist/Credit-CcZF4aQS.js +0 -260
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-eIoPtgO5.js +0 -58
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-C7KZ8GMx.js +0 -3377
- package/dist/FilterChip.vue_vue_type_script_setup_true_lang-DaU-9GzO.js +0 -129
- package/dist/Game-CUW7NeVG.js +0 -330
- package/dist/LoyaltyDashboard-GqyUwvXz.js +0 -1082
- package/dist/MainLayout-R5NxIBR-.js +0 -41
- package/dist/Member-CC5F6Bmz.js +0 -280
- package/dist/MemberList-Cq4zxopX.js +0 -1601
- package/dist/Mission-DcCZ6tAG.js +0 -334
- package/dist/Point-D1vLd5hL.js +0 -262
- package/dist/Promotion-Cv7MW5RJ.js +0 -397
- package/dist/Review-CKhakUMe.js +0 -1123
- package/dist/ReviewFacebookCallback-xgRpXQAg.js +0 -243
- package/dist/ReviewGoogleCallback-Cqi_43qi.js +0 -208
- package/dist/SelectItems.vue_vue_type_script_setup_true_lang-DDqK4kV1.js +0 -181
- package/dist/Store-uTRQ6KbC.js +0 -1996
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-Bb2sTsuA.js +0 -1130
- package/dist/Transaction-CnTEfMGU.js +0 -39
- package/dist/campaign-CbMlARNI.js +0 -219
- package/dist/campaign-f7FT91GR.js +0 -277
- package/dist/export-DQR-0lmK.js +0 -97
- package/dist/index-COrXX9MR.js +0 -52
- package/dist/index-CWiaP-aV.js +0 -28900
- package/dist/index-jVfDVEtz.js +0 -85
- package/dist/membership-rifuatxU.js +0 -255
- package/dist/objectid-DjpWkCxH.js +0 -145
- package/dist/useMarketingMaterialActions-5TFNqZVo.js +0 -107
- package/dist/vue-i18n-CgMK-TaC.js +0 -2365
|
@@ -1,63 +1,64 @@
|
|
|
1
|
-
import { defineComponent as le, ref as
|
|
2
|
-
import { _ as
|
|
3
|
-
import { n as
|
|
4
|
-
import { u as
|
|
5
|
-
import { FmButtonVariant as
|
|
6
|
-
import { u as
|
|
7
|
-
import { u as
|
|
8
|
-
import { R as
|
|
9
|
-
import { i as
|
|
10
|
-
import "./index-
|
|
11
|
-
import { F as
|
|
12
|
-
import "./index-
|
|
13
|
-
import
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import { _ as
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
1
|
+
import { defineComponent as le, ref as X, resolveComponent as h, openBlock as r, createElementBlock as k, createElementVNode as s, createVNode as d, unref as e, createCommentVNode as K, withCtx as $, Fragment as ee, renderList as ue, createBlock as V, toDisplayString as E, normalizeClass as ie, computed as z, onMounted as Se, isRef as Ie, createSlots as Me, h as B, onBeforeMount as Te } from "vue";
|
|
2
|
+
import { _ as De } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { n as Ee, p as $e } from "./plugins-BFKVM3uC.js";
|
|
4
|
+
import { u as Ae } from "./loading-Dx4SCvZY.js";
|
|
5
|
+
import { FmButtonVariant as ce, useSnackbar as Pe, components as ae } from "@feedmepos/ui-library";
|
|
6
|
+
import { u as be, _ as we } from "./usePagination-DKX24g31.js";
|
|
7
|
+
import { u as me } from "./vue-i18n-wJReAVJw.js";
|
|
8
|
+
import { R as pe } from "./index-DJdTDF9C.js";
|
|
9
|
+
import { i as Re, j as U, D as Ne, k as Be } from "./index-B9ZMIUMa.js";
|
|
10
|
+
import "./index-BBsK7TUw.js";
|
|
11
|
+
import { F as fe, z as Ue } from "./index-BxU--5J5.js";
|
|
12
|
+
import { a as ye } from "./index-Bd4clHfr.js";
|
|
13
|
+
import "./index-DhtKt4OL.js";
|
|
14
|
+
import { u as re, w as Fe } from "./xlsx-Mthhu4JR.js";
|
|
15
|
+
import { e as Ve, M as Le } from "./email-addresses-BjODnJMM.js";
|
|
16
|
+
import { Z as Ye } from "./zod-CVpVUgBZ.js";
|
|
17
|
+
import { u as ze } from "./app-wDQR6dpb.js";
|
|
18
|
+
import { _ as Oe } from "./ZodTextField.vue_vue_type_script_setup_true_lang-UdStgKbX.js";
|
|
19
|
+
import { a as je } from "./RuleGroup.vue_vue_type_script_setup_true_lang-M0c67Dyl.js";
|
|
20
|
+
import { u as qe, v as Ge, w as He } from "./index.esm2017-CEOegJjn.js";
|
|
21
|
+
import { F as Je } from "./FileSaver.min-BpfY6VnX.js";
|
|
21
22
|
import { h as se } from "./moment-D7p2TMB-.js";
|
|
22
|
-
import { s as
|
|
23
|
-
import { o as
|
|
24
|
-
import { J as
|
|
25
|
-
import { u as
|
|
26
|
-
import { f as
|
|
27
|
-
import { t as
|
|
28
|
-
import "./index-
|
|
29
|
-
import { useRouter as
|
|
30
|
-
import { m as
|
|
31
|
-
import { R as
|
|
32
|
-
const
|
|
33
|
-
_id:
|
|
34
|
-
business:
|
|
35
|
-
file:
|
|
23
|
+
import { s as Y, u as Ke } from "./membership-CltAa-gH.js";
|
|
24
|
+
import { o as Qe } from "./objectId-dwaoBfJX.js";
|
|
25
|
+
import { J as We } from "./JsonViewer-v8_C7l5N.js";
|
|
26
|
+
import { u as Ce } from "./business-DjAiT8tR.js";
|
|
27
|
+
import { f as Ze } from "./number-DmhHKYgY.js";
|
|
28
|
+
import { t as Xe } from "./money-DsaAjJTI.js";
|
|
29
|
+
import "./index-D8rGhchh.js";
|
|
30
|
+
import { useRouter as et } from "vue-router";
|
|
31
|
+
import { m as ge } from "./index-DXiJa8Cw.js";
|
|
32
|
+
import { R as ve } from "./app-BxTElIm-.js";
|
|
33
|
+
const tt = Re.extend({
|
|
34
|
+
_id: fe.optional(),
|
|
35
|
+
business: fe.optional(),
|
|
36
|
+
file: Ue.any().nullish()
|
|
36
37
|
});
|
|
37
|
-
var
|
|
38
|
-
const
|
|
38
|
+
var ot = { firebase: { apiKey: "AIzaSyAj8JdCHtP0Vc5vZobCfgoLzWxPIn0WUG4", authDomain: "feedme-dev-4c3ef.firebaseapp.com", databaseURL: "https://feedme-dev-4c3ef.firebaseio.com", projectId: "feedme-dev-4c3ef", storageBucket: "feedme-dev-4c3ef.appspot.com", messagingSenderId: "458797803788", appId: "1:458797803788:web:37f2af2926a84288f0c129", measurementId: "G-J2QG09D2Q7" }, assetBucketUrl: "feedme-dev-4c3ef.appspot.com", importFilesBucketUrl: "feedme-dev-4c3ef.appspot.com", clientId: "1a362d621873497b277ea55258cc82594ba148d235257f7bd44ea2acc132d8a4" };
|
|
39
|
+
const nt = { class: "flex flex-col space-y-16" }, at = {
|
|
39
40
|
key: 0,
|
|
40
|
-
class: /* @__PURE__ */
|
|
41
|
+
class: /* @__PURE__ */ ie([
|
|
41
42
|
"p-16 pl-24 space-x-8",
|
|
42
43
|
"bg-fm-color-primary-oats rounded-lg",
|
|
43
44
|
"flex items-center",
|
|
44
45
|
"justify-between"
|
|
45
46
|
])
|
|
46
|
-
},
|
|
47
|
+
}, st = { class: "flex justify-end" }, lt = {
|
|
47
48
|
key: 1,
|
|
48
|
-
class: /* @__PURE__ */
|
|
49
|
+
class: /* @__PURE__ */ ie([
|
|
49
50
|
"flex items-center",
|
|
50
51
|
"border border-fm-color-neutral-gray-300",
|
|
51
52
|
"p-16 space-x-16 rounded-md"
|
|
52
53
|
])
|
|
53
|
-
},
|
|
54
|
+
}, it = { class: "fm-typo-en-body-lg-400 flex-1 truncate" }, ct = /* @__PURE__ */ le({
|
|
54
55
|
__name: "ImportSegment",
|
|
55
56
|
props: {
|
|
56
57
|
importFile: {}
|
|
57
58
|
},
|
|
58
59
|
emits: ["update:file"],
|
|
59
60
|
setup(t, { emit: f }) {
|
|
60
|
-
const c = t, M = f, { t:
|
|
61
|
+
const c = t, M = f, { t: S } = me(), _ = X(null), u = X(null), T = ["Id"], D = [
|
|
61
62
|
{
|
|
62
63
|
label: "CSV",
|
|
63
64
|
icon: "csv",
|
|
@@ -72,10 +73,10 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
72
73
|
async function a() {
|
|
73
74
|
if (c.importFile)
|
|
74
75
|
try {
|
|
75
|
-
const y =
|
|
76
|
+
const y = qe(void 0, ot.importFilesBucketUrl), p = Ge(y, c.importFile), g = await He(p);
|
|
76
77
|
window.open(g, "_blank");
|
|
77
78
|
} catch (y) {
|
|
78
|
-
console.log(y),
|
|
79
|
+
console.log(y), Ee.error("Failed to download uploaded file");
|
|
79
80
|
}
|
|
80
81
|
}
|
|
81
82
|
async function m(y) {
|
|
@@ -84,11 +85,11 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
84
85
|
const p = new Blob([T.join(",")], {
|
|
85
86
|
type: "text/csv;charset=utf-8;"
|
|
86
87
|
});
|
|
87
|
-
|
|
88
|
+
Je.saveAs(p, "ImportSegmentTemplate.csv");
|
|
88
89
|
break;
|
|
89
90
|
case "xlsx":
|
|
90
|
-
const g =
|
|
91
|
-
|
|
91
|
+
const g = re.aoa_to_sheet([T]), x = re.book_new();
|
|
92
|
+
re.book_append_sheet(x, g, "Sheet1"), Fe(x, "ImportSegmentTemplate.xlsx");
|
|
92
93
|
break;
|
|
93
94
|
}
|
|
94
95
|
}
|
|
@@ -101,20 +102,20 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
101
102
|
i(p);
|
|
102
103
|
}
|
|
103
104
|
return (y, p) => {
|
|
104
|
-
const g =
|
|
105
|
-
return r(), k("div",
|
|
105
|
+
const g = h("FmButton"), x = h("FmMenuItem"), q = h("FmMenu"), G = h("FmDropField");
|
|
106
|
+
return r(), k("div", nt, [
|
|
106
107
|
p[2] || (p[2] = s("div", { class: "fm-typo-en-title-sm-800" }, "Upload File", -1)),
|
|
107
|
-
t.importFile ? (r(), k("div",
|
|
108
|
+
t.importFile ? (r(), k("div", at, [
|
|
108
109
|
d(g, {
|
|
109
|
-
label: e(
|
|
110
|
-
variant: e(
|
|
110
|
+
label: e(S)("View uploaded file"),
|
|
111
|
+
variant: e(ce).Plain,
|
|
111
112
|
icon: "file_present",
|
|
112
113
|
onClick: a
|
|
113
114
|
}, null, 8, ["label", "variant"])
|
|
114
|
-
])) :
|
|
115
|
+
])) : K("", !0),
|
|
115
116
|
s("div", null, [
|
|
116
|
-
s("div",
|
|
117
|
-
d(
|
|
117
|
+
s("div", st, [
|
|
118
|
+
d(q, { class: "" }, {
|
|
118
119
|
"menu-button": $(() => [
|
|
119
120
|
d(g, {
|
|
120
121
|
variant: "tertiary",
|
|
@@ -123,31 +124,31 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
123
124
|
})
|
|
124
125
|
]),
|
|
125
126
|
default: $(() => [
|
|
126
|
-
(r(), k(
|
|
127
|
+
(r(), k(ee, null, ue(D, (I) => d(x, {
|
|
127
128
|
key: I.value,
|
|
128
129
|
icon: I.icon,
|
|
129
130
|
label: I.label,
|
|
130
|
-
onClick: (
|
|
131
|
+
onClick: (H) => m(I.value),
|
|
131
132
|
selectable: ""
|
|
132
133
|
}, null, 8, ["icon", "label", "onClick"])), 64))
|
|
133
134
|
]),
|
|
134
135
|
_: 1
|
|
135
136
|
})
|
|
136
137
|
]),
|
|
137
|
-
_.value ? (r(), k("div",
|
|
138
|
+
_.value ? (r(), k("div", lt, [
|
|
138
139
|
d(g, {
|
|
139
|
-
variant: e(
|
|
140
|
+
variant: e(ce).Tertiary,
|
|
140
141
|
"prepend-icon": "attach_file"
|
|
141
142
|
}, null, 8, ["variant"]),
|
|
142
|
-
s("p",
|
|
143
|
+
s("p", it, E(_.value.name), 1),
|
|
143
144
|
s("label", {
|
|
144
145
|
ref_key: "fileLabelRef",
|
|
145
146
|
ref: u,
|
|
146
147
|
htmlFor: "file"
|
|
147
148
|
}, [
|
|
148
149
|
d(g, {
|
|
149
|
-
variant: e(
|
|
150
|
-
label: e(
|
|
150
|
+
variant: e(ce).Plain,
|
|
151
|
+
label: e(S)("Replace File"),
|
|
151
152
|
onClick: p[1] || (p[1] = () => {
|
|
152
153
|
var I;
|
|
153
154
|
return (I = u.value) == null ? void 0 : I.click();
|
|
@@ -162,7 +163,7 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
162
163
|
onChange: A
|
|
163
164
|
}, null, 32)
|
|
164
165
|
], 512)
|
|
165
|
-
])) : (r(), V(
|
|
166
|
+
])) : (r(), V(G, {
|
|
166
167
|
key: 0,
|
|
167
168
|
onFileUpload: p[0] || (p[0] = (I) => i(I)),
|
|
168
169
|
accept: ".csv, .xlsx",
|
|
@@ -172,18 +173,18 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
172
173
|
]);
|
|
173
174
|
};
|
|
174
175
|
}
|
|
175
|
-
}),
|
|
176
|
+
}), rt = { class: "space-y-16 pr-12" }, dt = { class: "fm-typo-en-title-md-800" }, ut = { class: "flex space-x-8" }, mt = { class: "fm-typo-en-title-md-800 text-fm-color-primary" }, pt = { class: "text-fm-color-typo-secondary" }, _e = /* @__PURE__ */ le({
|
|
176
177
|
__name: "ReviewSegment",
|
|
177
178
|
props: {
|
|
178
179
|
title: {},
|
|
179
180
|
segment: {}
|
|
180
181
|
},
|
|
181
182
|
setup(t) {
|
|
182
|
-
const f = t, c =
|
|
183
|
+
const f = t, c = z(
|
|
183
184
|
() => f.segment.memberCount ?? f.segment.members.length
|
|
184
|
-
), M =
|
|
185
|
+
), M = z(
|
|
185
186
|
() => f.segment.lastUpdated ? se(f.segment.lastUpdated).format("DD MMM YYYY") : "Not refreshed yet"
|
|
186
|
-
),
|
|
187
|
+
), S = [
|
|
187
188
|
{
|
|
188
189
|
header: "Name",
|
|
189
190
|
accessorFn: (i) => i.name
|
|
@@ -194,7 +195,7 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
194
195
|
},
|
|
195
196
|
{
|
|
196
197
|
header: "Customer Since",
|
|
197
|
-
accessorFn: (i) => se(
|
|
198
|
+
accessorFn: (i) => se(Qe(i._id.toString())).format("DD MMM YYYY")
|
|
198
199
|
},
|
|
199
200
|
{
|
|
200
201
|
header: "Phone",
|
|
@@ -210,7 +211,7 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
210
211
|
}
|
|
211
212
|
];
|
|
212
213
|
async function _(i) {
|
|
213
|
-
return f.segment._id ? (console.log(i), await
|
|
214
|
+
return f.segment._id ? (console.log(i), await Y.paginateSegmentUsers(
|
|
214
215
|
f.segment._id,
|
|
215
216
|
i
|
|
216
217
|
)) : {
|
|
@@ -224,32 +225,32 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
224
225
|
}
|
|
225
226
|
};
|
|
226
227
|
}
|
|
227
|
-
const { tableMeta: u, rowData: T, onSort:
|
|
228
|
-
return
|
|
228
|
+
const { tableMeta: u, rowData: T, onSort: D, debouncedFetchData: a, onSearch: m } = be(_);
|
|
229
|
+
return Se(async () => {
|
|
229
230
|
await a();
|
|
230
|
-
}), (i, A) => (r(), k("div",
|
|
231
|
-
s("div",
|
|
232
|
-
s("div",
|
|
233
|
-
s("div",
|
|
234
|
-
s("div",
|
|
231
|
+
}), (i, A) => (r(), k("div", rt, [
|
|
232
|
+
s("div", dt, E(f.title), 1),
|
|
233
|
+
s("div", ut, [
|
|
234
|
+
s("div", mt, E(e(c)), 1),
|
|
235
|
+
s("div", pt, [
|
|
235
236
|
A[1] || (A[1] = s("div", null, "contacts in your segment", -1)),
|
|
236
|
-
s("div", null, "as of " +
|
|
237
|
+
s("div", null, "as of " + E(e(M)), 1)
|
|
237
238
|
])
|
|
238
239
|
]),
|
|
239
|
-
d(
|
|
240
|
+
d(we, {
|
|
240
241
|
loading: e(u).isLoading,
|
|
241
242
|
"row-data": e(T),
|
|
242
243
|
"row-count": e(u).totalRows,
|
|
243
|
-
"column-defs":
|
|
244
|
+
"column-defs": S,
|
|
244
245
|
"page-size": e(u).pageSize,
|
|
245
246
|
"page-count": e(u).pageCount,
|
|
246
247
|
"page-index": e(u).pageIndex,
|
|
247
|
-
onSortChange: e(
|
|
248
|
+
onSortChange: e(D),
|
|
248
249
|
onPageChange: A[0] || (A[0] = (y) => e(a)({ pageSize: y.pageSize, pageIndex: y.pageIndex }))
|
|
249
250
|
}, null, 8, ["loading", "row-data", "row-count", "page-size", "page-count", "page-index", "onSortChange"])
|
|
250
251
|
]));
|
|
251
252
|
}
|
|
252
|
-
}),
|
|
253
|
+
}), ft = { class: "space-y-24" }, yt = { class: "grid grid-cols-2 gap-16" }, gt = { class: "fm-typo-en-title-sm-800" }, vt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, _t = /* @__PURE__ */ le({
|
|
253
254
|
__name: "SegmentTypeOption",
|
|
254
255
|
props: {
|
|
255
256
|
modelValue: {},
|
|
@@ -257,7 +258,7 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
257
258
|
},
|
|
258
259
|
emits: ["update:model-value"],
|
|
259
260
|
setup(t, { emit: f }) {
|
|
260
|
-
const c = t, M = f,
|
|
261
|
+
const c = t, M = f, S = [
|
|
261
262
|
{
|
|
262
263
|
label: "Dynamic",
|
|
263
264
|
sublabel: "Segment statistics are based on rules configured and will be recalculated automatically when rule changes.",
|
|
@@ -273,13 +274,13 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
273
274
|
u !== c.modelValue && M("update:model-value", u);
|
|
274
275
|
}
|
|
275
276
|
return (u, T) => {
|
|
276
|
-
const
|
|
277
|
-
return r(), k("div",
|
|
278
|
-
s("div",
|
|
279
|
-
(r(), k(
|
|
277
|
+
const D = h("FmCard"), a = h("FmHelperText");
|
|
278
|
+
return r(), k("div", ft, [
|
|
279
|
+
s("div", yt, [
|
|
280
|
+
(r(), k(ee, null, ue(S, (m) => d(D, {
|
|
280
281
|
variant: "outlined",
|
|
281
|
-
class:
|
|
282
|
-
"col-span-2":
|
|
282
|
+
class: ie(["p-16 space-y-8 h-full cursor-pointer select-none xs:col-span-2", {
|
|
283
|
+
"col-span-2": S.length == 1,
|
|
283
284
|
"border-fm-color-primary bg-fm-color-system-warning-100 hover:border-[var(--fm-color-system-orange-300)]": t.modelValue === m.value,
|
|
284
285
|
"hover:bg-fm-color-opacity-sm": t.modelValue !== m.value
|
|
285
286
|
}]),
|
|
@@ -287,8 +288,8 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
287
288
|
key: m.value
|
|
288
289
|
}, {
|
|
289
290
|
default: $(() => [
|
|
290
|
-
s("div",
|
|
291
|
-
s("div",
|
|
291
|
+
s("div", gt, E(m.label), 1),
|
|
292
|
+
s("div", vt, E(m.sublabel), 1)
|
|
292
293
|
]),
|
|
293
294
|
_: 2
|
|
294
295
|
}, 1032, ["class", "onClick"])), 64))
|
|
@@ -298,47 +299,47 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
298
299
|
class: "!mt-4",
|
|
299
300
|
text: t.errorText,
|
|
300
301
|
state: "error"
|
|
301
|
-
}, null, 8, ["text"])) :
|
|
302
|
+
}, null, 8, ["text"])) : K("", !0)
|
|
302
303
|
]);
|
|
303
304
|
};
|
|
304
305
|
}
|
|
305
|
-
}),
|
|
306
|
+
}), xt = { class: "flex items-center gap-x-8" }, ht = {
|
|
306
307
|
key: 0,
|
|
307
308
|
class: "space-y-16 pr-12"
|
|
308
|
-
},
|
|
309
|
+
}, St = {
|
|
309
310
|
key: 0,
|
|
310
311
|
class: "flex flex-col gap-12"
|
|
311
|
-
},
|
|
312
|
+
}, bt = { class: "flex flex-wrap items-center gap-8" }, wt = { class: "fm-typo-en-title-sm-800" }, Ft = { class: "flex flex-col gap-4" }, Ct = { class: "fm-typo-en-body-md-600 text-fm-color-typo-primary" }, kt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, It = {
|
|
312
313
|
key: 2,
|
|
313
314
|
class: "flex flex-col space-y-16"
|
|
314
|
-
},
|
|
315
|
+
}, Mt = {
|
|
315
316
|
key: 3,
|
|
316
317
|
class: "flex flex-col space-y-16"
|
|
317
|
-
},
|
|
318
|
+
}, Tt = {
|
|
318
319
|
key: 4,
|
|
319
320
|
class: "flex flex-col space-y-16"
|
|
320
|
-
},
|
|
321
|
+
}, Dt = {
|
|
321
322
|
key: 5,
|
|
322
323
|
class: "flex flex-col space-y-16"
|
|
323
|
-
},
|
|
324
|
+
}, Et = { class: "flex items-center gap-8" }, $t = /* @__PURE__ */ le({
|
|
324
325
|
__name: "SegmentSheet",
|
|
325
326
|
emits: ["update:model-value"],
|
|
326
327
|
setup(t, { expose: f, emit: c }) {
|
|
327
|
-
const M =
|
|
328
|
+
const M = ze(), { t: S } = me(), _ = X(!1), u = X(!1), T = {
|
|
328
329
|
name: "",
|
|
329
330
|
isActive: !0,
|
|
330
331
|
type: U.enum.DYNAMIC,
|
|
331
|
-
rule:
|
|
332
|
+
rule: pe.scaffoldGroup(),
|
|
332
333
|
members: []
|
|
333
|
-
},
|
|
334
|
+
}, D = tt, a = X(T), m = z(() => !!a.value.defaultKey), i = z(
|
|
334
335
|
() => a.value.defaultKey ? `connect.loyalty.segment.default_segments.${a.value.defaultKey.toLowerCase()}` : void 0
|
|
335
|
-
), A =
|
|
336
|
-
() => i.value ?
|
|
337
|
-
), y =
|
|
336
|
+
), A = z(
|
|
337
|
+
() => i.value ? S(`${i.value}.name`) : a.value.name
|
|
338
|
+
), y = z(() => {
|
|
338
339
|
const v = a.value.defaultKey;
|
|
339
|
-
return v ?
|
|
340
|
-
}), p =
|
|
341
|
-
const v =
|
|
340
|
+
return v ? S(Ne[v]) : a.value.description ?? "";
|
|
341
|
+
}), p = z(() => {
|
|
342
|
+
const v = D.safeParse(a.value);
|
|
342
343
|
return v.success ? [] : v.error.errors;
|
|
343
344
|
});
|
|
344
345
|
function g(v) {
|
|
@@ -351,42 +352,42 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
351
352
|
function x() {
|
|
352
353
|
_.value = !1;
|
|
353
354
|
}
|
|
354
|
-
async function
|
|
355
|
-
|
|
355
|
+
async function q() {
|
|
356
|
+
D.safeParse(a.value).success && (u.value = !0);
|
|
356
357
|
}
|
|
357
|
-
function
|
|
358
|
+
function G(v) {
|
|
358
359
|
v === U.enum.STATIC ? x() : u.value = !1;
|
|
359
360
|
}
|
|
360
361
|
async function I() {
|
|
361
|
-
a.value.type === U.enum.STATIC ? (a.value.rule =
|
|
362
|
+
a.value.type === U.enum.STATIC ? (a.value.rule = pe.scaffoldGroup(), a.value.isActive = !0) : a.value.file = void 0, Q("update:model-value", a.value);
|
|
362
363
|
}
|
|
363
|
-
async function
|
|
364
|
+
async function H(v) {
|
|
364
365
|
a.value.type = v;
|
|
365
366
|
}
|
|
366
|
-
|
|
367
|
+
Se(async () => {
|
|
367
368
|
});
|
|
368
|
-
const
|
|
369
|
+
const Q = c;
|
|
369
370
|
return f({
|
|
370
371
|
showSheet: g,
|
|
371
372
|
hideSheet: x
|
|
372
373
|
}), (v, l) => {
|
|
373
|
-
const P =
|
|
374
|
+
const P = h("FmButton"), te = h("FmChip"), oe = h("FmCard"), ne = h("FmSwitch"), o = h("FmSideSheet");
|
|
374
375
|
return r(), V(o, {
|
|
375
376
|
modelValue: e(_),
|
|
376
|
-
"onUpdate:modelValue": l[9] || (l[9] = (n) =>
|
|
377
|
-
header: e(m) ? e(
|
|
377
|
+
"onUpdate:modelValue": l[9] || (l[9] = (n) => Ie(_) ? _.value = n : null),
|
|
378
|
+
header: e(m) ? e(S)("connect.loyalty.segment.default_segments.default_segment") : e(a)._id ? "Edit segment" : "Add segment",
|
|
378
379
|
"dismiss-away": "",
|
|
379
380
|
"close-button": !0,
|
|
380
381
|
"max-width": 1100
|
|
381
|
-
},
|
|
382
|
+
}, Me({
|
|
382
383
|
"side-sheet-footer": $(() => [
|
|
383
|
-
s("div",
|
|
384
|
+
s("div", Et, [
|
|
384
385
|
e(m) ? (r(), V(P, {
|
|
385
386
|
key: 0,
|
|
386
|
-
label: e(
|
|
387
|
+
label: e(S)("connect.loyalty.segment.default_segments.close"),
|
|
387
388
|
onClick: l[6] || (l[6] = (n) => x()),
|
|
388
389
|
variant: "tertiary"
|
|
389
|
-
}, null, 8, ["label"])) : e(u) || e(a).type === e(U).enum.STATIC ? (r(), k(
|
|
390
|
+
}, null, 8, ["label"])) : e(u) || e(a).type === e(U).enum.STATIC ? (r(), k(ee, { key: 1 }, [
|
|
390
391
|
d(P, {
|
|
391
392
|
label: "Save Segment",
|
|
392
393
|
onClick: I,
|
|
@@ -395,14 +396,14 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
395
396
|
}, null, 8, ["loading", "disabled"]),
|
|
396
397
|
d(P, {
|
|
397
398
|
label: "Cancel",
|
|
398
|
-
onClick: l[7] || (l[7] = (n) =>
|
|
399
|
+
onClick: l[7] || (l[7] = (n) => G(e(a).type)),
|
|
399
400
|
variant: "tertiary"
|
|
400
401
|
})
|
|
401
|
-
], 64)) : (r(), k(
|
|
402
|
+
], 64)) : (r(), k(ee, { key: 2 }, [
|
|
402
403
|
d(P, {
|
|
403
404
|
label: "Review Segment",
|
|
404
405
|
disabled: e(p).length > 0 || e(M).isLoading,
|
|
405
|
-
onClick:
|
|
406
|
+
onClick: q
|
|
406
407
|
}, null, 8, ["disabled"]),
|
|
407
408
|
d(P, {
|
|
408
409
|
label: "Cancel",
|
|
@@ -415,82 +416,82 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
415
416
|
default: $(() => {
|
|
416
417
|
var n, F;
|
|
417
418
|
return [
|
|
418
|
-
d(
|
|
419
|
-
e(u) ? (r(), V(
|
|
419
|
+
d(We, { json: e(a) }, null, 8, ["json"]),
|
|
420
|
+
e(u) ? (r(), V(_e, {
|
|
420
421
|
key: 1,
|
|
421
422
|
title: e(a).name,
|
|
422
423
|
segment: e(a)
|
|
423
|
-
}, null, 8, ["title", "segment"])) : (r(), k("div",
|
|
424
|
-
e(m) ? (r(), k("div",
|
|
425
|
-
s("div",
|
|
426
|
-
s("div",
|
|
427
|
-
d(
|
|
428
|
-
label: e(
|
|
424
|
+
}, null, 8, ["title", "segment"])) : (r(), k("div", ht, [
|
|
425
|
+
e(m) ? (r(), k("div", St, [
|
|
426
|
+
s("div", bt, [
|
|
427
|
+
s("div", wt, E(e(A)), 1),
|
|
428
|
+
d(te, {
|
|
429
|
+
label: e(S)("connect.loyalty.segment.default_segments.system"),
|
|
429
430
|
compact: "",
|
|
430
431
|
class: "text-fm-color-typo-info bg-fm-color-system-info-100"
|
|
431
432
|
}, null, 8, ["label"])
|
|
432
433
|
]),
|
|
433
|
-
d(
|
|
434
|
+
d(oe, {
|
|
434
435
|
variant: "outlined",
|
|
435
436
|
class: "p-16"
|
|
436
437
|
}, {
|
|
437
438
|
default: $(() => [
|
|
438
|
-
s("div",
|
|
439
|
-
s("div",
|
|
440
|
-
s("div",
|
|
439
|
+
s("div", Ft, [
|
|
440
|
+
s("div", Ct, E(e(S)("connect.loyalty.segment.default_segments.description")), 1),
|
|
441
|
+
s("div", kt, E(e(y)), 1)
|
|
441
442
|
])
|
|
442
443
|
]),
|
|
443
444
|
_: 1
|
|
444
445
|
})
|
|
445
|
-
])) : (r(), V(
|
|
446
|
+
])) : (r(), V(Oe, {
|
|
446
447
|
key: 1,
|
|
447
448
|
modelValue: e(a).name,
|
|
448
|
-
"onUpdate:modelValue": l[1] || (l[1] = (
|
|
449
|
+
"onUpdate:modelValue": l[1] || (l[1] = (b) => e(a).name = b),
|
|
449
450
|
label: "Segment title",
|
|
450
|
-
schema: e(
|
|
451
|
+
schema: e(Ye).typeAtPath(e(D), "name")
|
|
451
452
|
}, null, 8, ["modelValue", "schema"])),
|
|
452
|
-
e(m) ?
|
|
453
|
+
e(m) ? K("", !0) : (r(), k("div", It, [
|
|
453
454
|
l[11] || (l[11] = s("div", { class: "fm-typo-en-title-sm-800" }, "Segment Type", -1)),
|
|
454
|
-
d(
|
|
455
|
+
d(_t, {
|
|
455
456
|
"model-value": e(a).type,
|
|
456
|
-
"onUpdate:modelValue": l[2] || (l[2] = (
|
|
457
|
-
|
|
457
|
+
"onUpdate:modelValue": l[2] || (l[2] = (b) => {
|
|
458
|
+
H(b);
|
|
458
459
|
})
|
|
459
460
|
}, null, 8, ["model-value"])
|
|
460
461
|
])),
|
|
461
|
-
e(a).type === e(U).enum.DYNAMIC && !e(m) ? (r(), k("div",
|
|
462
|
+
e(a).type === e(U).enum.DYNAMIC && !e(m) ? (r(), k("div", Mt, [
|
|
462
463
|
l[12] || (l[12] = s("div", { class: "fm-typo-en-title-sm-800" }, "Segment Filter", -1)),
|
|
463
|
-
d(
|
|
464
|
+
d(je, {
|
|
464
465
|
"trigger-type": "MEMBERSHIP_JOINED",
|
|
465
466
|
includeOnly: "user",
|
|
466
467
|
"model-value": (n = e(a)) == null ? void 0 : n.rule,
|
|
467
|
-
"onUpdate:modelValue": l[3] || (l[3] = (
|
|
468
|
-
e(a).rule =
|
|
468
|
+
"onUpdate:modelValue": l[3] || (l[3] = (b) => {
|
|
469
|
+
e(a).rule = b;
|
|
469
470
|
})
|
|
470
471
|
}, null, 8, ["model-value"])
|
|
471
|
-
])) : e(m) ?
|
|
472
|
-
d(
|
|
472
|
+
])) : e(m) ? K("", !0) : (r(), k("div", Tt, [
|
|
473
|
+
d(ct, {
|
|
473
474
|
importFile: e(a).importFile,
|
|
474
|
-
"onUpdate:file": l[4] || (l[4] = (
|
|
475
|
-
e(a).file =
|
|
475
|
+
"onUpdate:file": l[4] || (l[4] = (b) => {
|
|
476
|
+
e(a).file = b;
|
|
476
477
|
})
|
|
477
478
|
}, null, 8, ["importFile"])
|
|
478
479
|
])),
|
|
479
|
-
e(a).type === e(U).enum.DYNAMIC && !e(m) ? (r(), k("div",
|
|
480
|
+
e(a).type === e(U).enum.DYNAMIC && !e(m) ? (r(), k("div", Dt, [
|
|
480
481
|
l[13] || (l[13] = s("div", { class: "fm-typo-en-title-sm-800" }, "Segment Status", -1)),
|
|
481
|
-
d(
|
|
482
|
+
d(ne, {
|
|
482
483
|
"model-value": e(a).isActive ?? !0,
|
|
483
|
-
"onUpdate:modelValue": l[5] || (l[5] = (
|
|
484
|
+
"onUpdate:modelValue": l[5] || (l[5] = (b) => e(a).isActive = b),
|
|
484
485
|
label: "Active",
|
|
485
486
|
sublabel: "When enabled, this will recalculate the segment statistics daily.",
|
|
486
487
|
"label-placement": "right"
|
|
487
488
|
}, null, 8, ["model-value"])
|
|
488
|
-
])) :
|
|
489
|
-
e(m) ? (r(), V(
|
|
489
|
+
])) : K("", !0),
|
|
490
|
+
e(m) ? (r(), V(_e, {
|
|
490
491
|
key: (F = e(a)._id) == null ? void 0 : F.toString(),
|
|
491
|
-
title: e(
|
|
492
|
+
title: e(S)("connect.loyalty.segment.default_segments.members"),
|
|
492
493
|
segment: e(a)
|
|
493
|
-
}, null, 8, ["title", "segment"])) :
|
|
494
|
+
}, null, 8, ["title", "segment"])) : K("", !0)
|
|
494
495
|
]))
|
|
495
496
|
];
|
|
496
497
|
}),
|
|
@@ -499,7 +500,7 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
499
500
|
e(u) && !e(m) ? {
|
|
500
501
|
name: "side-sheet-header",
|
|
501
502
|
fn: $(() => [
|
|
502
|
-
s("div",
|
|
503
|
+
s("div", xt, [
|
|
503
504
|
d(P, {
|
|
504
505
|
icon: "arrow_back",
|
|
505
506
|
variant: "tertiary",
|
|
@@ -513,79 +514,77 @@ const st = { class: "flex flex-col space-y-16" }, lt = {
|
|
|
513
514
|
]), 1032, ["modelValue", "header"]);
|
|
514
515
|
};
|
|
515
516
|
}
|
|
516
|
-
}),
|
|
517
|
-
function
|
|
517
|
+
}), xe = Ke(), At = Ce();
|
|
518
|
+
function de(t) {
|
|
518
519
|
const f = se(t);
|
|
519
520
|
return f.isValid() ? f.format("DD/MM/YYYY") : "";
|
|
520
521
|
}
|
|
521
|
-
const
|
|
522
|
+
const Pt = {
|
|
522
523
|
mapMemberExportRow: (t) => {
|
|
523
|
-
var a, m, i, A, y, p, g, x,
|
|
524
|
-
const f =
|
|
524
|
+
var a, m, i, A, y, p, g, x, q, G, I, H, Q, v, l, P, te, oe, ne, o, n, F, b, R, J, L;
|
|
525
|
+
const f = z(() => At.locations.map((C) => ({
|
|
525
526
|
label: C.name,
|
|
526
527
|
value: C._id
|
|
527
|
-
}))), c = (a =
|
|
528
|
+
}))), c = (a = Ve.parseOneAddress(
|
|
528
529
|
t == null ? void 0 : t.email
|
|
529
530
|
)) != null && a.domain.includes("feedmepos.com") ? void 0 : t.email, M = (i = ((m = t == null ? void 0 : t.collection) == null ? void 0 : m.TITLE) || []) == null ? void 0 : i.reduce(
|
|
530
531
|
(C, N) => {
|
|
531
|
-
var
|
|
532
|
-
const
|
|
533
|
-
(
|
|
534
|
-
)) == null ? void 0 :
|
|
535
|
-
return !
|
|
532
|
+
var j, W;
|
|
533
|
+
const O = (W = (j = xe.sortedTitles) == null ? void 0 : j.find(
|
|
534
|
+
(w) => w._id === N.collectible
|
|
535
|
+
)) == null ? void 0 : W.name;
|
|
536
|
+
return !O || N.balance <= 0 || C.push(O), C;
|
|
536
537
|
},
|
|
537
538
|
[]
|
|
538
|
-
),
|
|
539
|
+
), S = (xe.sortedTitles || []).reduce(
|
|
539
540
|
(C, N) => {
|
|
540
|
-
var
|
|
541
|
-
const
|
|
542
|
-
(
|
|
543
|
-
)) == null ? void 0 :
|
|
544
|
-
return C[N.name] =
|
|
541
|
+
var j, W, w, Z;
|
|
542
|
+
const O = (Z = (w = (W = (((j = t == null ? void 0 : t.collection) == null ? void 0 : j.TITLE) || []).find(
|
|
543
|
+
(ke) => ke.collectible === N._id
|
|
544
|
+
)) == null ? void 0 : W.expiryBalance) == null ? void 0 : w[0]) == null ? void 0 : Z.expiredAt;
|
|
545
|
+
return C[N.name] = O ? se(O).format("DD/MM/YYYY") : "", C;
|
|
545
546
|
},
|
|
546
547
|
{}
|
|
547
|
-
), _ = ((p = (y = (A = t.collection) == null ? void 0 : A.CREDIT) == null ? void 0 : y.at(0)) == null ? void 0 : p.balance) || 0, u = ((
|
|
548
|
+
), _ = ((p = (y = (A = t.collection) == null ? void 0 : A.CREDIT) == null ? void 0 : y.at(0)) == null ? void 0 : p.balance) || 0, u = ((G = (q = (x = (g = t.collection) == null ? void 0 : g.CREDIT) == null ? void 0 : x.at(0)) == null ? void 0 : q.expiryBalance) == null ? void 0 : G.reduce(
|
|
548
549
|
(C, N) => C + N.amount,
|
|
549
550
|
0
|
|
550
|
-
)) || 0, T =
|
|
551
|
+
)) || 0, T = Ze(_, 2);
|
|
551
552
|
return {
|
|
552
553
|
ID: t._id.toString(),
|
|
553
554
|
Name: ((I = t.name) == null ? void 0 : I.trim()) || "",
|
|
554
|
-
Phone: ((
|
|
555
|
+
Phone: ((H = t == null ? void 0 : t.phoneNumber) == null ? void 0 : H.trim()) || "",
|
|
555
556
|
Email: c || "",
|
|
556
557
|
Gender: t.gender || "",
|
|
557
558
|
CardNo: t.cardNo || "",
|
|
558
|
-
Birthday: t != null && t.birthday ?
|
|
559
|
+
Birthday: t != null && t.birthday ? de(t == null ? void 0 : t.birthday) : "",
|
|
559
560
|
Credit: parseFloat((Number(T) - Number(u)).toFixed(2)),
|
|
560
561
|
FreeCredit: Number(u.toFixed(2)),
|
|
561
562
|
TotalCredit: Number(T),
|
|
562
|
-
Exp: t != null && t.collection ? ((l = (v = (
|
|
563
|
-
Point: t != null && t.collection ? ((
|
|
564
|
-
Level: t != null && t.collection ? ((n = (o = (
|
|
565
|
-
Tier: t != null && t.collection ? ((R = (
|
|
563
|
+
Exp: t != null && t.collection ? ((l = (v = (Q = t.collection) == null ? void 0 : Q.POINT) == null ? void 0 : v.at(0)) == null ? void 0 : l.balance) ?? 0 : 0,
|
|
564
|
+
Point: t != null && t.collection ? ((oe = (te = (P = t.collection) == null ? void 0 : P.COIN) == null ? void 0 : te.at(0)) == null ? void 0 : oe.balance) ?? 0 : 0,
|
|
565
|
+
Level: t != null && t.collection ? ((n = (o = (ne = t.collection) == null ? void 0 : ne.TIER) == null ? void 0 : o.at(0)) == null ? void 0 : n.balance) ?? 0 : 0,
|
|
566
|
+
Tier: t != null && t.collection ? ((R = (b = (F = t.collection) == null ? void 0 : F.TIER) == null ? void 0 : b.at(0)) == null ? void 0 : R.balance) ?? 0 : 0,
|
|
566
567
|
Titles: M.join(","),
|
|
567
|
-
...
|
|
568
|
+
...S,
|
|
568
569
|
TotalTransaction: t.stats.visitCount,
|
|
569
|
-
AvgSpent:
|
|
570
|
+
AvgSpent: Xe(Number(t.stats.avgBillSize || 0)).toFormat(
|
|
570
571
|
!1
|
|
571
572
|
),
|
|
572
573
|
TotalSpent: t.stats.avgBillSize * t.stats.visitCount,
|
|
573
|
-
LastVisit:
|
|
574
|
-
Feedback: ((
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
JoinedAt: ue(t.joinAt || void 0),
|
|
578
|
-
JoinedAtLocation: t.location && ((ne = f.value.find((C) => C.value == t.location)) == null ? void 0 : ne.label) || "-",
|
|
574
|
+
LastVisit: de(t.stats.lastVisit),
|
|
575
|
+
Feedback: ((J = t.stats) == null ? void 0 : J.feedbackCount) || 0,
|
|
576
|
+
JoinedAt: de(t.joinAt || void 0),
|
|
577
|
+
JoinedAtLocation: t.location && ((L = f.value.find((C) => C.value == t.location)) == null ? void 0 : L.label) || "-",
|
|
579
578
|
VisitFrequency: `${Number(
|
|
580
579
|
Math.ceil(t.stats.avgVisitFrequency).toFixed(0)
|
|
581
580
|
)}`
|
|
582
581
|
};
|
|
583
582
|
}
|
|
584
|
-
},
|
|
583
|
+
}, Rt = { class: "flex items-center" }, Nt = { class: "fm-typo-en-title-md-600 fm-step-title line-clamp-2 mr-8" }, Bt = { class: "px-24 flex flex-col gap-y-16" }, Ut = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, Vt = { class: "flex flex-wrap items-center gap-8" }, Lt = { class: "fm-typo-en-body-md-600" }, Yt = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, zt = { class: "flex flex-col gap-16 text-center" }, Ot = { class: "fm-typo-en-title-sm-800" }, jt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, he = "text-fm-color-typo-info bg-fm-color-system-info-100", Fo = /* @__PURE__ */ le({
|
|
585
584
|
__name: "Segment",
|
|
586
585
|
setup(t) {
|
|
587
|
-
const { minor: f } =
|
|
588
|
-
function
|
|
586
|
+
const { minor: f } = Ae, { t: c } = me(), M = Ce(), { mapMemberExportRow: S } = Pt, _ = Pe(), u = et(), T = X(0);
|
|
587
|
+
function D(o) {
|
|
589
588
|
return !!o.defaultKey;
|
|
590
589
|
}
|
|
591
590
|
function a(o) {
|
|
@@ -605,9 +604,9 @@ const Nt = {
|
|
|
605
604
|
cell(o) {
|
|
606
605
|
return B("div", { class: "flex flex-wrap items-center gap-8" }, [
|
|
607
606
|
B("span", m(o.row.original)),
|
|
608
|
-
...
|
|
607
|
+
...D(o.row.original) ? [
|
|
609
608
|
B(ae.FmChip, {
|
|
610
|
-
class:
|
|
609
|
+
class: he,
|
|
611
610
|
label: c("connect.loyalty.segment.default_segments.system"),
|
|
612
611
|
compact: !0
|
|
613
612
|
})
|
|
@@ -661,7 +660,7 @@ const Nt = {
|
|
|
661
660
|
ae.FmMenuItem,
|
|
662
661
|
{
|
|
663
662
|
onClick: async (n) => {
|
|
664
|
-
n.stopPropagation(),
|
|
663
|
+
n.stopPropagation(), Q(o.row.original);
|
|
665
664
|
}
|
|
666
665
|
},
|
|
667
666
|
{
|
|
@@ -674,12 +673,12 @@ const Nt = {
|
|
|
674
673
|
)
|
|
675
674
|
}
|
|
676
675
|
),
|
|
677
|
-
...
|
|
676
|
+
...D(o.row.original) ? [] : [
|
|
678
677
|
B(
|
|
679
678
|
ae.FmMenuItem,
|
|
680
679
|
{
|
|
681
680
|
onClick: async (n) => {
|
|
682
|
-
n.stopPropagation(),
|
|
681
|
+
n.stopPropagation(), H(o.row.original);
|
|
683
682
|
}
|
|
684
683
|
},
|
|
685
684
|
{
|
|
@@ -699,15 +698,15 @@ const Nt = {
|
|
|
699
698
|
]);
|
|
700
699
|
}
|
|
701
700
|
}
|
|
702
|
-
], y =
|
|
703
|
-
|
|
704
|
-
),
|
|
701
|
+
], y = X(null), { tableMeta: p, rowData: g, debouncedFetchData: x } = be(
|
|
702
|
+
Y.readAll
|
|
703
|
+
), q = z(() => g.value.length === 0 ? !1 : Be.some(
|
|
705
704
|
(o) => !g.value.some((n) => n.defaultKey === o)
|
|
706
705
|
));
|
|
707
|
-
async function
|
|
706
|
+
async function G() {
|
|
708
707
|
var o;
|
|
709
708
|
try {
|
|
710
|
-
await
|
|
709
|
+
await Y.refreshSegments(), _.open({ type: "info", title: "Segment refresh queued" });
|
|
711
710
|
} catch (n) {
|
|
712
711
|
if (((n == null ? void 0 : n.status) ?? ((o = n == null ? void 0 : n.response) == null ? void 0 : o.status)) === 409) {
|
|
713
712
|
_.open({
|
|
@@ -725,7 +724,7 @@ const Nt = {
|
|
|
725
724
|
async function I() {
|
|
726
725
|
await f(
|
|
727
726
|
async () => {
|
|
728
|
-
await
|
|
727
|
+
await Y.startDefaultSegments(), await x({ pageSize: 10, pageIndex: 0 });
|
|
729
728
|
},
|
|
730
729
|
{
|
|
731
730
|
message: c(
|
|
@@ -737,10 +736,10 @@ const Nt = {
|
|
|
737
736
|
}
|
|
738
737
|
);
|
|
739
738
|
}
|
|
740
|
-
async function
|
|
741
|
-
await
|
|
739
|
+
async function H(o) {
|
|
740
|
+
await $e.remove(`Are you sure you want to remove ${o.name}?`) && await f(
|
|
742
741
|
async () => {
|
|
743
|
-
await
|
|
742
|
+
await Y.delete(o._id), await x({ pageSize: 10, pageIndex: 0 });
|
|
744
743
|
},
|
|
745
744
|
{
|
|
746
745
|
message: `Removing ${o.name}`,
|
|
@@ -748,41 +747,41 @@ const Nt = {
|
|
|
748
747
|
}
|
|
749
748
|
);
|
|
750
749
|
}
|
|
751
|
-
async function
|
|
750
|
+
async function Q(o) {
|
|
752
751
|
const n = {
|
|
753
752
|
sortBy: "_id",
|
|
754
753
|
descending: !1,
|
|
755
754
|
rowsPerPage: 1e3,
|
|
756
755
|
page: 1,
|
|
757
756
|
rowsNumber: 0
|
|
758
|
-
}, F = new
|
|
757
|
+
}, F = new Le(), b = m(o), R = (await ge.read({
|
|
759
758
|
limit: 1,
|
|
760
759
|
skip: 0,
|
|
761
760
|
sortBy: n.sortBy,
|
|
762
761
|
descending: n.descending
|
|
763
|
-
})).meta.totalResources ?? 0,
|
|
762
|
+
})).meta.totalResources ?? 0, J = n.rowsPerPage;
|
|
764
763
|
await f(
|
|
765
764
|
async () => {
|
|
766
|
-
for (let L = 0; L < R; L +=
|
|
767
|
-
const
|
|
765
|
+
for (let L = 0; L < R; L += J) {
|
|
766
|
+
const C = {
|
|
768
767
|
...n,
|
|
769
|
-
limit:
|
|
768
|
+
limit: J,
|
|
770
769
|
skip: n.page - 1,
|
|
771
770
|
sortBy: n.sortBy,
|
|
772
771
|
descending: n.descending
|
|
773
|
-
},
|
|
772
|
+
}, N = await Y.paginateSegmentUsers(
|
|
774
773
|
o._id,
|
|
775
|
-
|
|
774
|
+
C
|
|
776
775
|
);
|
|
777
|
-
for (const
|
|
778
|
-
const
|
|
779
|
-
F.addRecord(
|
|
776
|
+
for (const O of N.resources) {
|
|
777
|
+
const j = S(O);
|
|
778
|
+
F.addRecord(j);
|
|
780
779
|
}
|
|
781
780
|
n.page++;
|
|
782
781
|
}
|
|
783
|
-
await
|
|
782
|
+
await Fe(
|
|
784
783
|
F.buildExcel(),
|
|
785
|
-
`[${
|
|
784
|
+
`[${b}]-members-${(/* @__PURE__ */ new Date()).toISOString()}.xlsx`,
|
|
786
785
|
{
|
|
787
786
|
bookType: "xlsx",
|
|
788
787
|
bookSST: !1,
|
|
@@ -803,11 +802,11 @@ const Nt = {
|
|
|
803
802
|
if (o.type === U.enum.STATIC) {
|
|
804
803
|
const F = new FormData();
|
|
805
804
|
if (F.append("file", o.file), o._id) {
|
|
806
|
-
const { members:
|
|
807
|
-
F.append("segment", JSON.stringify(L)), await
|
|
805
|
+
const { members: b, _id: R, file: J, ...L } = o;
|
|
806
|
+
F.append("segment", JSON.stringify(L)), await Y.updateStatic(o._id, F);
|
|
808
807
|
} else {
|
|
809
|
-
const { file:
|
|
810
|
-
F.append("segment", JSON.stringify(R)), await
|
|
808
|
+
const { file: b, ...R } = o;
|
|
809
|
+
F.append("segment", JSON.stringify(R)), await Y.createStatic(F);
|
|
811
810
|
}
|
|
812
811
|
o.file && _.open({
|
|
813
812
|
type: "info",
|
|
@@ -815,16 +814,16 @@ const Nt = {
|
|
|
815
814
|
action: "View",
|
|
816
815
|
onAction: async () => {
|
|
817
816
|
await u.push({
|
|
818
|
-
name:
|
|
819
|
-
query: { type: [
|
|
817
|
+
name: ve["$connect-QUEUE"],
|
|
818
|
+
query: { type: [ye.enum.SEGMENTATION_IMPORTED] }
|
|
820
819
|
});
|
|
821
820
|
}
|
|
822
821
|
});
|
|
823
822
|
} else if (o._id) {
|
|
824
|
-
const { members: F, _id:
|
|
825
|
-
await
|
|
823
|
+
const { members: F, _id: b, ...R } = o;
|
|
824
|
+
await Y.update(o._id, R);
|
|
826
825
|
} else
|
|
827
|
-
await
|
|
826
|
+
await Y.create(o);
|
|
828
827
|
await x({ pageSize: 10, pageIndex: 0 }), (n = y.value) == null || n.hideSheet();
|
|
829
828
|
},
|
|
830
829
|
{
|
|
@@ -842,16 +841,16 @@ const Nt = {
|
|
|
842
841
|
value: "queue",
|
|
843
842
|
isPrimary: !1,
|
|
844
843
|
prependIcon: "work_history"
|
|
845
|
-
},
|
|
844
|
+
}, te = {
|
|
846
845
|
label: c("connect.loyalty.segment.default_segments.get_started.action"),
|
|
847
846
|
value: "start-default-segments",
|
|
848
847
|
isPrimary: !1,
|
|
849
848
|
prependIcon: "auto_awesome"
|
|
850
|
-
},
|
|
849
|
+
}, oe = z(() => {
|
|
851
850
|
if (!M.isPremium)
|
|
852
851
|
return [];
|
|
853
852
|
const o = [P];
|
|
854
|
-
return
|
|
853
|
+
return q.value && o.push(te), o.push(
|
|
855
854
|
{
|
|
856
855
|
label: c("connect.loyalty.segment.actions.refresh"),
|
|
857
856
|
value: "refresh",
|
|
@@ -865,18 +864,18 @@ const Nt = {
|
|
|
865
864
|
}
|
|
866
865
|
), o;
|
|
867
866
|
});
|
|
868
|
-
function
|
|
867
|
+
function ne(o) {
|
|
869
868
|
switch (o) {
|
|
870
869
|
case "add":
|
|
871
870
|
l();
|
|
872
871
|
break;
|
|
873
872
|
case "refresh":
|
|
874
|
-
|
|
873
|
+
G();
|
|
875
874
|
break;
|
|
876
875
|
case "queue":
|
|
877
876
|
u.push({
|
|
878
|
-
name:
|
|
879
|
-
query: { type: [
|
|
877
|
+
name: ve["$connect-QUEUE"],
|
|
878
|
+
query: { type: [ye.enum.SEGMENTATION_IMPORTED] }
|
|
880
879
|
});
|
|
881
880
|
break;
|
|
882
881
|
case "start-default-segments":
|
|
@@ -884,8 +883,8 @@ const Nt = {
|
|
|
884
883
|
break;
|
|
885
884
|
}
|
|
886
885
|
}
|
|
887
|
-
return
|
|
888
|
-
const { meta: o } = await
|
|
886
|
+
return Te(async () => {
|
|
887
|
+
const { meta: o } = await ge.read({
|
|
889
888
|
limit: 1,
|
|
890
889
|
skip: 0,
|
|
891
890
|
sortBy: "_id",
|
|
@@ -894,24 +893,24 @@ const Nt = {
|
|
|
894
893
|
});
|
|
895
894
|
T.value = o.totalResources ?? 0, await x({ pageSize: 10, pageIndex: 0 }), await M.readPremium(), await M.readLocations();
|
|
896
895
|
}), (o, n) => {
|
|
897
|
-
const F =
|
|
898
|
-
return r(), k(
|
|
899
|
-
d(
|
|
896
|
+
const F = h("FmPill"), b = h("FmPageHead"), R = h("FmChip"), J = h("FmIcon"), L = h("FmMenuItem"), C = h("FmMenu"), N = h("FmListItem"), O = h("FmList"), j = h("FmButton"), W = h("FmCard");
|
|
897
|
+
return r(), k(ee, null, [
|
|
898
|
+
d(b, {
|
|
900
899
|
title: "Segments",
|
|
901
|
-
actions: e(
|
|
902
|
-
"onClick:action": n[0] || (n[0] = (
|
|
900
|
+
actions: e(oe),
|
|
901
|
+
"onClick:action": n[0] || (n[0] = (w) => ne(w))
|
|
903
902
|
}, {
|
|
904
903
|
title: $(() => [
|
|
905
|
-
s("div",
|
|
906
|
-
s("span",
|
|
904
|
+
s("div", Rt, [
|
|
905
|
+
s("span", Nt, E(e(c)("connect.loyalty.segment.title")), 1),
|
|
907
906
|
d(F, { variant: "premium" })
|
|
908
907
|
])
|
|
909
908
|
]),
|
|
910
909
|
_: 1
|
|
911
910
|
}, 8, ["actions"]),
|
|
912
|
-
s("div",
|
|
913
|
-
e(g).length > 0 || e(p).searchValue || e(p).isLoading ? (r(), k(
|
|
914
|
-
d(
|
|
911
|
+
s("div", Bt, [
|
|
912
|
+
e(g).length > 0 || e(p).searchValue || e(p).isLoading ? (r(), k(ee, { key: 0 }, [
|
|
913
|
+
d(we, {
|
|
915
914
|
loading: e(p).isLoading,
|
|
916
915
|
"row-data": e(g),
|
|
917
916
|
"row-count": e(p).totalRows,
|
|
@@ -920,49 +919,49 @@ const Nt = {
|
|
|
920
919
|
"page-count": e(p).pageCount,
|
|
921
920
|
"page-index": e(p).pageIndex,
|
|
922
921
|
"page-size": e(p).pageSize,
|
|
923
|
-
onRowClick: n[1] || (n[1] = (
|
|
924
|
-
l(
|
|
922
|
+
onRowClick: n[1] || (n[1] = (w) => {
|
|
923
|
+
l(w.original);
|
|
925
924
|
}),
|
|
926
925
|
onPageChange: e(x)
|
|
927
926
|
}, null, 8, ["loading", "row-data", "row-count", "page-count", "page-index", "page-size", "onPageChange"]),
|
|
928
|
-
d(
|
|
927
|
+
d(O, { class: "w-full hidden xs:!block" }, {
|
|
929
928
|
default: $(() => [
|
|
930
|
-
(r(!0), k(
|
|
931
|
-
key:
|
|
929
|
+
(r(!0), k(ee, null, ue(e(g), (w) => (r(), V(N, {
|
|
930
|
+
key: w._id.toString(),
|
|
932
931
|
tag: "label",
|
|
933
|
-
onClick: (
|
|
932
|
+
onClick: (Z) => l(w)
|
|
934
933
|
}, {
|
|
935
934
|
default: $(() => [
|
|
936
935
|
s("div", null, [
|
|
937
|
-
s("div",
|
|
938
|
-
s("div",
|
|
939
|
-
s("span",
|
|
940
|
-
|
|
936
|
+
s("div", Ut, E((w.memberCount ?? 0).toLocaleString()) + " total customers ", 1),
|
|
937
|
+
s("div", Vt, [
|
|
938
|
+
s("span", Lt, E(m(w)), 1),
|
|
939
|
+
D(w) ? (r(), V(R, {
|
|
941
940
|
key: 0,
|
|
942
|
-
class:
|
|
941
|
+
class: ie(he),
|
|
943
942
|
label: e(c)("connect.loyalty.segment.default_segments.system"),
|
|
944
943
|
compact: ""
|
|
945
|
-
}, null, 8, ["label"])) :
|
|
944
|
+
}, null, 8, ["label"])) : K("", !0)
|
|
946
945
|
]),
|
|
947
|
-
s("div",
|
|
946
|
+
s("div", Yt, E(i(w.memberCount)) + "% of customers ", 1)
|
|
948
947
|
])
|
|
949
948
|
]),
|
|
950
949
|
append: $(() => [
|
|
951
|
-
d(
|
|
950
|
+
d(C, { "stop-click-propagation": !0 }, {
|
|
952
951
|
"menu-button": $(() => [
|
|
953
|
-
d(
|
|
952
|
+
d(J, { name: "more_vert" })
|
|
954
953
|
]),
|
|
955
954
|
default: $(() => [
|
|
956
955
|
d(L, {
|
|
957
956
|
class: "fm-typo-en-body-md-400",
|
|
958
957
|
label: "Export",
|
|
959
|
-
"onUpdate:modelValue": (
|
|
958
|
+
"onUpdate:modelValue": (Z) => Z && Q(w)
|
|
960
959
|
}, null, 8, ["onUpdate:modelValue"]),
|
|
961
|
-
|
|
960
|
+
D(w) ? K("", !0) : (r(), V(L, {
|
|
962
961
|
key: 0,
|
|
963
962
|
class: "text-fm-color-typo-error fm-typo-en-body-md-400",
|
|
964
963
|
label: "Remove",
|
|
965
|
-
"onUpdate:modelValue": (
|
|
964
|
+
"onUpdate:modelValue": (Z) => Z && H(w)
|
|
966
965
|
}, null, 8, ["onUpdate:modelValue"]))
|
|
967
966
|
]),
|
|
968
967
|
_: 2
|
|
@@ -973,33 +972,33 @@ const Nt = {
|
|
|
973
972
|
]),
|
|
974
973
|
_: 1
|
|
975
974
|
})
|
|
976
|
-
], 64)) : (r(), V(
|
|
975
|
+
], 64)) : (r(), V(W, {
|
|
977
976
|
key: 1,
|
|
978
977
|
variant: "outlined",
|
|
979
978
|
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
980
979
|
}, {
|
|
981
980
|
default: $(() => [
|
|
982
981
|
n[3] || (n[3] = s("img", {
|
|
983
|
-
src:
|
|
982
|
+
src: De,
|
|
984
983
|
class: "aspect-square w-[150px]"
|
|
985
984
|
}, null, -1)),
|
|
986
|
-
s("div",
|
|
987
|
-
s("div",
|
|
988
|
-
s("div",
|
|
985
|
+
s("div", zt, [
|
|
986
|
+
s("div", Ot, E(e(c)("connect.loyalty.segment.default_segments.get_started.title")), 1),
|
|
987
|
+
s("div", jt, E(e(c)(
|
|
989
988
|
"connect.loyalty.segment.default_segments.get_started.description"
|
|
990
989
|
)), 1)
|
|
991
990
|
]),
|
|
992
|
-
d(
|
|
991
|
+
d(j, {
|
|
993
992
|
variant: "primary",
|
|
994
993
|
label: e(c)("connect.loyalty.segment.default_segments.get_started.action"),
|
|
995
994
|
disabled: !e(M).isPremium,
|
|
996
995
|
icon: "auto_awesome",
|
|
997
|
-
onClick: n[2] || (n[2] = (
|
|
996
|
+
onClick: n[2] || (n[2] = (w) => I())
|
|
998
997
|
}, null, 8, ["label", "disabled"])
|
|
999
998
|
]),
|
|
1000
999
|
_: 1
|
|
1001
1000
|
})),
|
|
1002
|
-
d(
|
|
1001
|
+
d($t, {
|
|
1003
1002
|
ref_key: "sheetRef",
|
|
1004
1003
|
ref: y,
|
|
1005
1004
|
"onUpdate:modelValue": v
|
|
@@ -1010,5 +1009,5 @@ const Nt = {
|
|
|
1010
1009
|
}
|
|
1011
1010
|
});
|
|
1012
1011
|
export {
|
|
1013
|
-
|
|
1012
|
+
Fo as default
|
|
1014
1013
|
};
|