@feedmepos/mf-connect 0.1.38-beta.68 → 0.1.38-beta.69
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-DDSSxM8U.js → Analytic-CHjBLSET.js} +14 -14
- package/dist/{App-3YNakqss.js → App-C1xIj-B0.js} +7 -7
- package/dist/{AuditLogs-BKIZ62qo.js → AuditLogs-Dki6qsI-.js} +9 -9
- package/dist/{Bin-lzY_2FbW.js → Bin-ttFSC2lf.js} +8 -8
- package/dist/{Broadcast-DHQFXAYM.js → Broadcast-Cz_pjrR6.js} +10 -10
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-B4DzR1H7.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-jQ8AgB-p.js} +6 -6
- package/dist/{Card-CtV8-Wdk.js → Card-BaNfbyIP.js} +17 -17
- package/dist/{Collections-Btv6q2lY.js → Collections-DZctA4hK.js} +7 -7
- package/dist/{Credit-BCoKxG0r.js → Credit-BYJWTi-b.js} +10 -10
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-DKVNUp4L.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-BXqC2jJb.js} +35 -35
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-DPwL7y2n.js → EffectSheet.vue_vue_type_style_index_0_lang-Cun-ghGF.js} +105 -101
- package/dist/{Experience-DUL-88xH.js → Experience-dWjLOoui.js} +10 -10
- package/dist/{FileSaver.min-wdxunVRb.js → FileSaver.min-BZHXGiQH.js} +1 -1
- package/dist/{Game-D05KVsLV.js → Game-DeXSmFww.js} +11 -11
- package/dist/{GenerateMaterial-Bqxy-HQl.js → GenerateMaterial-B_uWYDyj.js} +14 -14
- package/dist/{Grab-CRpoXnuQ.js → Grab-BKcVVW_I.js} +9 -9
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-OpPYe4Uj.js → ImageInput.vue_vue_type_script_setup_true_lang-Bbx9DDzu.js} +1 -1
- package/dist/{Index-BjLqY0Hk.js → Index-CSb87tjr.js} +10 -10
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-BF4nNYBF.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BCkKQUoM.js} +1 -1
- package/dist/{MainLayout-DmO4EqJ9.js → MainLayout-CpEOM8Wc.js} +1 -1
- package/dist/{Marketing-D0gCuI_X.js → Marketing-ClRXLCul.js} +4 -4
- package/dist/{MarketingMaterialEdit-CRxGq_2R.js → MarketingMaterialEdit-CJW-eGTF.js} +4 -4
- package/dist/{Member-CHgbhLlV.js → Member-_oGCdXUL.js} +11 -11
- package/dist/{MemberList-Dmrkw7sK.js → MemberList-C8m7EtI5.js} +25 -25
- package/dist/{MemberTransactions-CnIF9ZiL.js → MemberTransactions-COilUChO.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-CYTwDx2a.js → MessageInput.vue_vue_type_script_setup_true_lang-3awjwsoo.js} +8 -8
- package/dist/{Mission-BdmSWYnF.js → Mission-QhcGGV4d.js} +11 -11
- package/dist/{Overview-Payz8pfn.js → Overview-BAVHQHWB.js} +18 -18
- package/dist/{Point-BTzs4Ou7.js → Point-D0xZ5rrR.js} +10 -10
- package/dist/{Promotion-D2nP2e0f.js → Promotion-C4IE0Qbc.js} +11 -11
- package/dist/{Queue-C9II7ly9.js → Queue-DurTWu5p.js} +10 -10
- package/dist/{Record-BS9IB47x.js → Record-CFMWd4O2.js} +9 -9
- package/dist/{Reward-D8-g2yag.js → Reward-CHqVLyQb.js} +16 -16
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-CFQup7Ey.js → RewardGroup.vue_vue_type_script_setup_true_lang-BOs0aSOO.js} +11 -11
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-D1Ni5iQQ.js → RuleGroup.vue_vue_type_script_setup_true_lang-Dyfa78rG.js} +14 -14
- package/dist/{Segment-3wbAK-ru.js → Segment-DLPq88Ky.js} +24 -24
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-CG2DeiXX.js → SelectItems.vue_vue_type_script_setup_true_lang-D3CO54II.js} +20 -20
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-D68B8EQ-.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-LzGBxhRf.js} +12 -12
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-iCtUhdeJ.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-CL7fIjz8.js} +4 -4
- package/dist/{Setting-gi4ahgfG.js → Setting-BTmw7C4E.js} +13 -13
- package/dist/{SettingAdvertisements-BT-pT4Rv.js → SettingAdvertisements-DPzlV5EE.js} +11 -11
- package/dist/{Store-Lr21bL9O.js → Store-O1-8l-R3.js} +706 -679
- package/dist/{StoreRewards-Dxh1X2Pj.js → StoreRewards-l0gYOgXi.js} +14 -14
- package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-KZMv82FF.js → StoreTransactions.vue_vue_type_script_setup_true_lang-cQXkAOhr.js} +19 -19
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-DjcHY_oV.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BjawHGS0.js} +1 -1
- package/dist/{Tier-5AJlHnKi.js → Tier-hKiEGb6o.js} +23 -23
- package/dist/{Title-B1aG9RfZ.js → Title-D-KimgP5.js} +20 -20
- package/dist/{Transaction-B76rwD8i.js → Transaction-Cdd_JyrK.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-C92R5whE.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-CMW8EAdN.js} +6 -6
- package/dist/{Voucher-vBYXMxdg.js → Voucher-Dfc73Csg.js} +14 -14
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-CPSs8jr0.js → VoucherEditor.vue_vue_type_script_setup_true_lang-T8H35FPU.js} +12 -12
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-08F6xX_S.js → ZodTextField.vue_vue_type_script_setup_true_lang-BZNmcUU3.js} +2 -2
- package/dist/{app-4fFfKt_P.js → app-CPwdgRZv.js} +46199 -32540
- package/dist/app.js +1 -1
- package/dist/{business-EF0oafu7.js → business-BaWiU14d.js} +1 -1
- package/dist/{campaign-DRQrjx1T.js → campaign-CDz0jHT_.js} +8 -8
- package/dist/{campaign-Bd_DSi-h.js → campaign-CjorwtX0.js} +2 -2
- package/dist/campaign.enum-DYEesXC5.js +26 -0
- package/dist/{campaign.fn-DnZH6wsz.js → campaign.fn-DpVmqfwa.js} +67 -67
- package/dist/{collectible.enum-BDYWv_Vs.js → collectible.enum-C4KUmspK.js} +1 -1
- package/dist/{collection.fn-OZWH1lMk.js → collection.fn-DSYVoV0Q.js} +2 -2
- package/dist/{dto-DSdrUjCg.js → dto-Da7ErVjD.js} +4 -4
- package/dist/{duplicateCampaign-CVfnktSt.js → duplicateCampaign-9jH_zm0I.js} +2 -2
- package/dist/effect-DU7hFznC.js +89 -0
- package/dist/{email-addresses-BcT3YThk.js → email-addresses-DaG6NhSR.js} +2 -2
- package/dist/{export-h5etGBFq.js → export-DQ7mAt1L.js} +2 -2
- package/dist/{helper-Bt92KKiH.js → helper-DoitYM-F.js} +1 -1
- package/dist/{index-CYidpYJd.js → index-BHXZzBnz.js} +2346 -2318
- package/dist/{index-mkYBBpui.js → index-BkpmY2GE.js} +6 -6
- package/dist/{index-DEWQIP9p.js → index-BzjRqjaa.js} +1 -1
- package/dist/{index-BXINARQi.js → index-CDCOpWhV.js} +1 -1
- package/dist/{index-9v9lQSnC.js → index-COWak_tY.js} +1 -1
- package/dist/{index--F7J1iL3.js → index-CaZnCYlf.js} +1 -1
- package/dist/{index-BDqAWJZF.js → index-CkZ9FtS6.js} +3 -3
- package/dist/{index-CXoC9WN0.js → index-Cq6KrPV_.js} +1 -1
- package/dist/{index-BKNEcAih.js → index-D1fonJ2y.js} +4 -4
- package/dist/{index-7_M_cp1Q.js → index-D4IBwcT5.js} +3 -3
- package/dist/{index-BBEp8idk.js → index-DxSN3k9t.js} +2 -2
- package/dist/{index-DNMo12QR.js → index-T4Vlp9cv.js} +1 -1
- package/dist/{index-CMrJUcgp.js → index-YFu3E6Ag.js} +1 -1
- package/dist/{index.esm2017-Bg0SH2V2.js → index.esm2017-B4OXxsXJ.js} +38 -38
- package/dist/{loading-BtT3HsLR.js → loading-DlBFOncH.js} +2 -2
- package/dist/{lodash-D1Vi3odZ.js → lodash-DYkOiP6W.js} +1 -1
- package/dist/{membership-Dmh6o86-.js → membership-Ba48hky6.js} +3 -3
- package/dist/{money-DlH23fyf.js → money-DzYV_AqB.js} +1 -1
- package/dist/{number-Ds3PVttv.js → number-DZhr2aQi.js} +1 -1
- package/dist/{objectid-BvNQJW3a.js → objectid-lBGc5CTo.js} +12 -12
- package/dist/{plugins-BPcVgyi3.js → plugins-DnfvdXvl.js} +3 -3
- package/dist/{reward-DkYZJIPt.js → reward-BDRlCjZq.js} +1 -1
- package/dist/{rule-B2G7E5JS.js → rule-CXgUDav7.js} +3 -3
- package/dist/{rule-builder-B-sx8Fay.js → rule-builder-K8ZRQKcJ.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{template-C70M2IjW.js → template-B7SczDYk.js} +6 -6
- package/dist/{timezone-OmdQYEvP.js → timezone-CVrjbFra.js} +2 -2
- package/dist/{trigger--B0d2i3e.js → trigger-C07rM7Na.js} +5 -5
- package/dist/{usePagination-DDnVygse.js → usePagination-dYbEzX5Y.js} +1 -1
- package/dist/{user-B6jyhHiP.js → user-BSrjSLnx.js} +1 -1
- package/dist/{vue-i18n-CAr-uxyM.js → vue-i18n-DBanfH9w.js} +102 -102
- package/dist/{xlsx-DYNtfQX2.js → xlsx-PsqFEjbr.js} +440 -440
- package/dist/{zod-ClIl9cnW.js → zod-ph5Ab9oy.js} +1 -1
- package/package.json +2 -2
- package/dist/campaign.enum-DL60hi34.js +0 -21
- package/dist/effect-DOlyAYE4.js +0 -78
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
import { defineComponent as te, computed as L, resolveComponent as _, openBlock as
|
|
2
|
-
import { _ as
|
|
3
|
-
import { useDialog as
|
|
4
|
-
import { c as A, e as
|
|
5
|
-
import { m as
|
|
6
|
-
import { u as Te, C as
|
|
7
|
-
import { m as
|
|
8
|
-
import { a as
|
|
9
|
-
import { _ as ae } from "./lodash-
|
|
10
|
-
import { c as ue } from "./index-
|
|
11
|
-
import { u as xe } from "./vue-i18n-
|
|
12
|
-
import { Z as Q, g as G, a as X } from "./zod-
|
|
13
|
-
import { z as ee, R as
|
|
14
|
-
import { u as
|
|
15
|
-
import { _ as le } from "./ZodTextField.vue_vue_type_script_setup_true_lang-
|
|
16
|
-
import { a as
|
|
1
|
+
import { defineComponent as te, computed as L, resolveComponent as _, openBlock as x, createBlock as O, withCtx as B, createElementVNode as V, createElementBlock as D, createVNode as r, createCommentVNode as E, toDisplayString as K, unref as e, Fragment as Y, renderList as ce, ref as N, isRef as re, reactive as ze, onMounted as he, watch as Pe, toRaw as Je, createTextVNode as me, h as Ge } from "vue";
|
|
2
|
+
import { _ as Xe } from "./tier-BJDhpH6X.js";
|
|
3
|
+
import { useDialog as je, useDialogChild as Le, components as Ze } from "@feedmepos/ui-library";
|
|
4
|
+
import { c as A, e as Se, S as Qe } from "./index-DxSN3k9t.js";
|
|
5
|
+
import { m as ge, u as Ke } from "./loading-DlBFOncH.js";
|
|
6
|
+
import { u as Te, C as ye } from "./membership-Ba48hky6.js";
|
|
7
|
+
import { m as et, n as tt, o as nt, p as Ae, q as ot } from "./index-D1fonJ2y.js";
|
|
8
|
+
import { a as at, c as Fe } from "./object-qECH92oz.js";
|
|
9
|
+
import { _ as ae } from "./lodash-DYkOiP6W.js";
|
|
10
|
+
import { c as ue } from "./index-CkZ9FtS6.js";
|
|
11
|
+
import { u as xe } from "./vue-i18n-DBanfH9w.js";
|
|
12
|
+
import { Z as Q, g as G, a as X } from "./zod-ph5Ab9oy.js";
|
|
13
|
+
import { z as ee, R as lt } from "./app-CPwdgRZv.js";
|
|
14
|
+
import { u as _e } from "./app-wDQR6dpb.js";
|
|
15
|
+
import { _ as le } from "./ZodTextField.vue_vue_type_script_setup_true_lang-BZNmcUU3.js";
|
|
16
|
+
import { a as st, p as pe, n as rt, f as Ve } from "./plugins-DnfvdXvl.js";
|
|
17
17
|
import { J as ke } from "./JsonViewer-v8_C7l5N.js";
|
|
18
|
-
import { _ as
|
|
19
|
-
import { _ as
|
|
20
|
-
import { _ as
|
|
21
|
-
import { z as
|
|
22
|
-
import { F as
|
|
23
|
-
import { a as
|
|
24
|
-
import "./index-
|
|
25
|
-
import "./index-
|
|
26
|
-
import "./index-
|
|
27
|
-
import { m as
|
|
28
|
-
import { useRouter as
|
|
29
|
-
function
|
|
30
|
-
return ue.DineroFactory(
|
|
18
|
+
import { _ as it } from "./index-BHXZzBnz.js";
|
|
19
|
+
import { _ as dt } from "./ImageInput.vue_vue_type_script_setup_true_lang-Bbx9DDzu.js";
|
|
20
|
+
import { _ as ut } from "./ChipMenu.vue_vue_type_script_setup_true_lang-BPpZZNkr.js";
|
|
21
|
+
import { z as ct, a as mt } from "./money-DzYV_AqB.js";
|
|
22
|
+
import { F as pt } from "./number-DZhr2aQi.js";
|
|
23
|
+
import { a as ft, t as yt } from "./helper-DoitYM-F.js";
|
|
24
|
+
import "./index-Cq6KrPV_.js";
|
|
25
|
+
import "./index-BkpmY2GE.js";
|
|
26
|
+
import "./index-D4IBwcT5.js";
|
|
27
|
+
import { m as bt } from "./index-CDCOpWhV.js";
|
|
28
|
+
import { useRouter as gt } from "vue-router";
|
|
29
|
+
function He(C) {
|
|
30
|
+
return ue.DineroFactory(C).toUnit();
|
|
31
31
|
}
|
|
32
|
-
function
|
|
33
|
-
const
|
|
34
|
-
S.map((t) =>
|
|
35
|
-
),
|
|
36
|
-
(t,
|
|
37
|
-
var
|
|
32
|
+
function qe(C, S, o, b, s = [], v = []) {
|
|
33
|
+
const a = it.compact(
|
|
34
|
+
S.map((t) => C.find((c) => c.systemCode === t.systemCode && c.taxCode === t.taxCode)).filter((t) => !!t && v.includes(t.systemCode))
|
|
35
|
+
), m = a.reduce(
|
|
36
|
+
(t, c) => {
|
|
37
|
+
var y;
|
|
38
38
|
return Object.assign(t, {
|
|
39
|
-
[
|
|
40
|
-
inclusive: ((
|
|
39
|
+
[c.taxCode]: {
|
|
40
|
+
inclusive: ((y = s.find((u) => u.systemCode === c.systemCode)) == null ? void 0 : y.inclusive) || !1,
|
|
41
41
|
adjustment: {
|
|
42
42
|
level: 1,
|
|
43
43
|
type: {
|
|
44
44
|
type: "BY_MULTIPLIER",
|
|
45
45
|
amount: {
|
|
46
|
-
amount:
|
|
47
|
-
precision:
|
|
46
|
+
amount: c.rate.amount,
|
|
47
|
+
precision: c.rate.precision,
|
|
48
48
|
currency: "MYR"
|
|
49
49
|
}
|
|
50
50
|
}
|
|
@@ -62,17 +62,17 @@ function He(x, S, a, g, s = [], v = []) {
|
|
|
62
62
|
level: 0,
|
|
63
63
|
type: {
|
|
64
64
|
type: "BY_AMOUNT",
|
|
65
|
-
amount: ue.DineroFactory(
|
|
65
|
+
amount: ue.DineroFactory(o).subtract(ue.Dinero.fromNumber({ number: b }).toObject()).toObject()
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
},
|
|
69
|
-
taxes:
|
|
69
|
+
taxes: m
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
72
|
adjustments: {},
|
|
73
73
|
roundToNearest: 0
|
|
74
74
|
});
|
|
75
|
-
return
|
|
75
|
+
return a.map((t) => ({
|
|
76
76
|
setting: t,
|
|
77
77
|
systemCode: t.systemCode,
|
|
78
78
|
name: t.name,
|
|
@@ -83,87 +83,87 @@ function He(x, S, a, g, s = [], v = []) {
|
|
|
83
83
|
}).convertPrecision(2).toObject()
|
|
84
84
|
}));
|
|
85
85
|
}
|
|
86
|
-
function
|
|
87
|
-
return
|
|
86
|
+
function We(C, S, o) {
|
|
87
|
+
return C ? C.reduce((b, s) => {
|
|
88
88
|
var v;
|
|
89
|
-
return (v =
|
|
89
|
+
return (v = o.find((a) => a.systemCode === s.systemCode)) != null && v.inclusive || (b = ue.DineroFactory(b.toObject()).add(s.total)), b;
|
|
90
90
|
}, ue.DineroFactory(S)).toObject() : ue.DineroFactory(S).toObject();
|
|
91
91
|
}
|
|
92
|
-
const
|
|
92
|
+
const vt = { class: "relative h-[120px] aspect-video flex items-center justify-center border rounded-md border-fm-color-neutral-gray-300" }, ht = ["src"], xt = {
|
|
93
93
|
key: 2,
|
|
94
94
|
class: "absolute top-2 left-2"
|
|
95
|
-
},
|
|
95
|
+
}, Ct = { class: "absolute top-0 right-0" }, St = { class: "fm-typo-en-body-lg-600" }, _t = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ft = { class: "flex gap-8 items-center flex-wrap" }, Vt = /* @__PURE__ */ te({
|
|
96
96
|
__name: "StoreBundleCard",
|
|
97
97
|
props: {
|
|
98
98
|
bundle: { type: Object, required: !0 }
|
|
99
99
|
},
|
|
100
100
|
emits: ["edit", "delete", "send"],
|
|
101
|
-
setup(
|
|
102
|
-
const
|
|
103
|
-
const
|
|
104
|
-
return
|
|
105
|
-
`${A.Config.getCountry().currency.symbol}${
|
|
106
|
-
),
|
|
101
|
+
setup(C, { emit: S }) {
|
|
102
|
+
const o = C, b = S, s = L(() => {
|
|
103
|
+
const a = [];
|
|
104
|
+
return o.bundle.price.amount > 0 && a.push(
|
|
105
|
+
`${A.Config.getCountry().currency.symbol}${He(o.bundle.price)}`
|
|
106
|
+
), o.bundle.coinPrice && a.push(`${o.bundle.coinPrice} point(s)`), a.join(" or ");
|
|
107
107
|
}), v = L(() => {
|
|
108
|
-
var
|
|
109
|
-
const
|
|
110
|
-
if (
|
|
111
|
-
const t =
|
|
112
|
-
|
|
108
|
+
var m, i;
|
|
109
|
+
const a = [];
|
|
110
|
+
if (o.bundle.titles.length > 0 && a.push(`${o.bundle.titles.length} title(s)`), o.bundle.vouchers.length > 0 && a.push(`${o.bundle.vouchers.length} voucher(s)`), o.bundle.credit.normal || (m = o.bundle.credit.free) != null && m.amount) {
|
|
111
|
+
const t = o.bundle.credit.normal + (((i = o.bundle.credit.free) == null ? void 0 : i.amount) ?? 0);
|
|
112
|
+
a.push(`${t} credit(s)`);
|
|
113
113
|
}
|
|
114
|
-
return
|
|
114
|
+
return a;
|
|
115
115
|
});
|
|
116
|
-
return (
|
|
117
|
-
const i = _("FmIcon"), t = _("FmChip"),
|
|
118
|
-
return
|
|
116
|
+
return (a, m) => {
|
|
117
|
+
const i = _("FmIcon"), t = _("FmChip"), c = _("FmButton"), y = _("FmMenuItem"), u = _("FmMenu"), T = _("FmCard");
|
|
118
|
+
return x(), O(T, {
|
|
119
119
|
variant: "outlined",
|
|
120
120
|
class: "flex flex-col gap-y-8 p-16 min-h-[240px] h-full text-center items-center"
|
|
121
121
|
}, {
|
|
122
122
|
default: B(() => [
|
|
123
|
-
V("div",
|
|
124
|
-
|
|
123
|
+
V("div", vt, [
|
|
124
|
+
C.bundle.image ? (x(), D("img", {
|
|
125
125
|
key: 1,
|
|
126
|
-
src:
|
|
126
|
+
src: C.bundle.image,
|
|
127
127
|
class: "w-full h-full object-contain aspect-video"
|
|
128
|
-
}, null, 8,
|
|
128
|
+
}, null, 8, ht)) : (x(), O(i, {
|
|
129
129
|
key: 0,
|
|
130
130
|
name: "image",
|
|
131
131
|
outline: !0,
|
|
132
132
|
size: "md",
|
|
133
133
|
class: "text-fm-color-neutral-gray-200"
|
|
134
134
|
})),
|
|
135
|
-
|
|
135
|
+
C.bundle.isFeedvibe ? (x(), D("div", xt, [
|
|
136
136
|
r(t, {
|
|
137
137
|
label: "Feedvibe",
|
|
138
138
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
139
139
|
compact: ""
|
|
140
140
|
})
|
|
141
141
|
])) : E("", !0),
|
|
142
|
-
V("div",
|
|
143
|
-
r(
|
|
142
|
+
V("div", Ct, [
|
|
143
|
+
r(u, { placement: "bottom-end" }, {
|
|
144
144
|
"menu-button": B(() => [
|
|
145
|
-
r(
|
|
145
|
+
r(c, {
|
|
146
146
|
icon: "more_vert",
|
|
147
147
|
variant: "tertiary"
|
|
148
148
|
})
|
|
149
149
|
]),
|
|
150
150
|
default: B(() => [
|
|
151
|
-
r(
|
|
152
|
-
onClick:
|
|
151
|
+
r(y, {
|
|
152
|
+
onClick: m[0] || (m[0] = (l) => b("edit", C.bundle)),
|
|
153
153
|
icon: "edit",
|
|
154
154
|
label: "Edit"
|
|
155
155
|
}),
|
|
156
|
-
|
|
156
|
+
C.bundle.stripePriceId ? E("", !0) : (x(), O(y, {
|
|
157
157
|
key: 0,
|
|
158
|
-
onClick:
|
|
158
|
+
onClick: m[1] || (m[1] = (l) => b("send", C.bundle)),
|
|
159
159
|
icon: "send",
|
|
160
160
|
label: "Send"
|
|
161
161
|
})),
|
|
162
|
-
r(
|
|
163
|
-
onClick:
|
|
162
|
+
r(y, {
|
|
163
|
+
onClick: m[2] || (m[2] = (l) => b("delete", C.bundle)),
|
|
164
164
|
icon: "delete"
|
|
165
165
|
}, {
|
|
166
|
-
label: B(() => [...
|
|
166
|
+
label: B(() => [...m[3] || (m[3] = [
|
|
167
167
|
V("div", { class: "text-fm-color-typo-error fm-typo-en-body-md-400" }, " Delete ", -1)
|
|
168
168
|
])]),
|
|
169
169
|
_: 1
|
|
@@ -173,10 +173,10 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
173
173
|
})
|
|
174
174
|
])
|
|
175
175
|
]),
|
|
176
|
-
V("div",
|
|
176
|
+
V("div", St, K(C.bundle.name), 1),
|
|
177
177
|
V("div", _t, K(e(s) || "Free"), 1),
|
|
178
|
-
V("div",
|
|
179
|
-
(
|
|
178
|
+
V("div", Ft, [
|
|
179
|
+
(x(!0), D(Y, null, ce(e(v), (l, w) => (x(), O(t, {
|
|
180
180
|
key: w,
|
|
181
181
|
label: l
|
|
182
182
|
}, null, 8, ["label"]))), 128))
|
|
@@ -186,21 +186,21 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
186
186
|
});
|
|
187
187
|
};
|
|
188
188
|
}
|
|
189
|
-
}),
|
|
189
|
+
}), wt = /* @__PURE__ */ te({
|
|
190
190
|
__name: "AddBundleCard",
|
|
191
191
|
emits: ["create"],
|
|
192
|
-
setup(
|
|
193
|
-
const { t:
|
|
192
|
+
setup(C, { emit: S }) {
|
|
193
|
+
const { t: o } = xe(), b = S;
|
|
194
194
|
return (s, v) => {
|
|
195
|
-
const
|
|
196
|
-
return
|
|
195
|
+
const a = _("FmButton"), m = _("FmCard");
|
|
196
|
+
return x(), O(m, {
|
|
197
197
|
variant: "outlined",
|
|
198
198
|
class: "flex flex-col gap-y-8 p-16 h-full min-h-[240px] items-center justify-center"
|
|
199
199
|
}, {
|
|
200
200
|
default: B(() => [
|
|
201
|
-
r(
|
|
202
|
-
onClick: v[0] || (v[0] = (i) =>
|
|
203
|
-
label: e(
|
|
201
|
+
r(a, {
|
|
202
|
+
onClick: v[0] || (v[0] = (i) => b("create")),
|
|
203
|
+
label: e(o)("connect.store.actions.addBundle"),
|
|
204
204
|
icon: "add",
|
|
205
205
|
variant: "secondary"
|
|
206
206
|
}, null, 8, ["label"])
|
|
@@ -209,7 +209,7 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
209
209
|
});
|
|
210
210
|
};
|
|
211
211
|
}
|
|
212
|
-
}),
|
|
212
|
+
}), Pt = { class: "space-y-16" }, Tt = { class: "flex w-full justify-between pb-16" }, kt = { class: "flex items-center justify-end gap-8" }, $t = /* @__PURE__ */ te({
|
|
213
213
|
__name: "CategoryDialog",
|
|
214
214
|
props: {
|
|
215
215
|
action: {
|
|
@@ -221,41 +221,41 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
221
221
|
default: () => ""
|
|
222
222
|
}
|
|
223
223
|
},
|
|
224
|
-
setup(
|
|
225
|
-
const { t: S } = xe(),
|
|
224
|
+
setup(C) {
|
|
225
|
+
const { t: S } = xe(), o = C, b = je(), { emitData: s, emitAction: v } = Le(), a = N(o.initialValue), m = ee.string().min(1);
|
|
226
226
|
function i() {
|
|
227
|
-
s(
|
|
227
|
+
s(a.value), v("primary"), b.close();
|
|
228
228
|
}
|
|
229
229
|
function t() {
|
|
230
|
-
s(null), v("primary"),
|
|
230
|
+
s(null), v("primary"), b.close();
|
|
231
231
|
}
|
|
232
|
-
return (
|
|
233
|
-
const
|
|
234
|
-
return
|
|
235
|
-
r(
|
|
236
|
-
modelValue: e(
|
|
237
|
-
"onUpdate:modelValue":
|
|
232
|
+
return (c, y) => {
|
|
233
|
+
const u = _("FmTextField"), T = _("FmButton");
|
|
234
|
+
return x(), D("div", Pt, [
|
|
235
|
+
r(u, {
|
|
236
|
+
modelValue: e(a),
|
|
237
|
+
"onUpdate:modelValue": y[0] || (y[0] = (l) => re(a) ? a.value = l : null),
|
|
238
238
|
label: e(S)("connect.store.category.label"),
|
|
239
|
-
rules: [e(Q).toRule(e(
|
|
239
|
+
rules: [e(Q).toRule(e(m))]
|
|
240
240
|
}, null, 8, ["modelValue", "label", "rules"]),
|
|
241
|
-
V("div",
|
|
241
|
+
V("div", Tt, [
|
|
242
242
|
V("div", null, [
|
|
243
|
-
|
|
243
|
+
C.action == "edit" ? (x(), O(T, {
|
|
244
244
|
key: 0,
|
|
245
245
|
onClick: t,
|
|
246
246
|
label: e(S)("connect.common.delete"),
|
|
247
247
|
variant: "destructive"
|
|
248
248
|
}, null, 8, ["label"])) : E("", !0)
|
|
249
249
|
]),
|
|
250
|
-
V("div",
|
|
250
|
+
V("div", kt, [
|
|
251
251
|
r(T, {
|
|
252
252
|
label: e(S)("connect.common.cancel"),
|
|
253
253
|
variant: "tertiary",
|
|
254
|
-
onClick:
|
|
254
|
+
onClick: y[1] || (y[1] = (l) => e(b).close())
|
|
255
255
|
}, null, 8, ["label"]),
|
|
256
256
|
r(T, {
|
|
257
|
-
label:
|
|
258
|
-
disabled: !e(
|
|
257
|
+
label: C.action == "edit" ? e(S)("connect.common.edit") : e(S)("connect.common.add"),
|
|
258
|
+
disabled: !e(a),
|
|
259
259
|
onClick: i
|
|
260
260
|
}, null, 8, ["label", "disabled"])
|
|
261
261
|
])
|
|
@@ -263,38 +263,38 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
263
263
|
]);
|
|
264
264
|
};
|
|
265
265
|
}
|
|
266
|
-
}),
|
|
266
|
+
}), Ut = { class: "space-y-16" }, Rt = { class: "flex items-center justify-end gap-8 pb-16" }, It = /* @__PURE__ */ te({
|
|
267
267
|
__name: "SelectCategoryDialog",
|
|
268
|
-
setup(
|
|
269
|
-
const { emitData: S, emitAction:
|
|
270
|
-
() =>
|
|
271
|
-
label:
|
|
272
|
-
value:
|
|
268
|
+
setup(C) {
|
|
269
|
+
const { emitData: S, emitAction: o } = Le(), b = Te(), s = N(), v = L(
|
|
270
|
+
() => b.sortedStoreCategories.map((a, m) => ({
|
|
271
|
+
label: a.name,
|
|
272
|
+
value: m
|
|
273
273
|
}))
|
|
274
274
|
);
|
|
275
|
-
return (
|
|
275
|
+
return (a, m) => {
|
|
276
276
|
const i = _("FmSelect"), t = _("FmButton");
|
|
277
|
-
return
|
|
278
|
-
|
|
277
|
+
return x(), D("div", Ut, [
|
|
278
|
+
m[4] || (m[4] = V("div", { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, " Select a category to create FeedMe CNY 2025 bundle ", -1)),
|
|
279
279
|
r(i, {
|
|
280
280
|
placeholder: "Select a category",
|
|
281
281
|
items: e(v),
|
|
282
282
|
modelValue: e(s),
|
|
283
283
|
"onUpdate:modelValue": [
|
|
284
|
-
|
|
285
|
-
|
|
284
|
+
m[0] || (m[0] = (c) => re(s) ? s.value = c : null),
|
|
285
|
+
m[1] || (m[1] = (c) => e(S)(c))
|
|
286
286
|
],
|
|
287
287
|
label: "Category"
|
|
288
288
|
}, null, 8, ["items", "modelValue"]),
|
|
289
|
-
V("div",
|
|
289
|
+
V("div", Rt, [
|
|
290
290
|
r(t, {
|
|
291
291
|
variant: "tertiary",
|
|
292
292
|
label: "Cancel",
|
|
293
|
-
onClick:
|
|
293
|
+
onClick: m[2] || (m[2] = (c) => e(o)("tertiary"))
|
|
294
294
|
}),
|
|
295
295
|
r(t, {
|
|
296
296
|
label: "Select",
|
|
297
|
-
onClick:
|
|
297
|
+
onClick: m[3] || (m[3] = (c) => e(o)("primary")),
|
|
298
298
|
disabled: e(s) == null
|
|
299
299
|
}, null, 8, ["disabled"])
|
|
300
300
|
])
|
|
@@ -302,11 +302,11 @@ const gt = { class: "relative h-[120px] aspect-video flex items-center justify-c
|
|
|
302
302
|
};
|
|
303
303
|
}
|
|
304
304
|
});
|
|
305
|
-
function se(
|
|
306
|
-
return
|
|
305
|
+
function se(C) {
|
|
306
|
+
return C.states.map((S) => ({ label: S, value: S }));
|
|
307
307
|
}
|
|
308
|
-
const
|
|
309
|
-
[
|
|
308
|
+
const Bt = {
|
|
309
|
+
[Se.F_COUNTRY.enum.MY]: {
|
|
310
310
|
states: [
|
|
311
311
|
"Johor",
|
|
312
312
|
"Kedah",
|
|
@@ -329,7 +329,7 @@ const It = {
|
|
|
329
329
|
return se(this);
|
|
330
330
|
}
|
|
331
331
|
},
|
|
332
|
-
[
|
|
332
|
+
[Se.F_COUNTRY.enum.SG]: {
|
|
333
333
|
states: [],
|
|
334
334
|
get stateItems() {
|
|
335
335
|
return se(this);
|
|
@@ -365,7 +365,7 @@ const It = {
|
|
|
365
365
|
return se(this);
|
|
366
366
|
}
|
|
367
367
|
},
|
|
368
|
-
[
|
|
368
|
+
[Se.F_COUNTRY.enum.ID]: {
|
|
369
369
|
states: [
|
|
370
370
|
"Aceh",
|
|
371
371
|
"Bali",
|
|
@@ -405,7 +405,7 @@ const It = {
|
|
|
405
405
|
return se(this);
|
|
406
406
|
}
|
|
407
407
|
},
|
|
408
|
-
[
|
|
408
|
+
[Se.F_COUNTRY.enum.TH]: {
|
|
409
409
|
states: [
|
|
410
410
|
"Bangkok",
|
|
411
411
|
"Amnat Charoen",
|
|
@@ -489,40 +489,40 @@ const It = {
|
|
|
489
489
|
return se(this);
|
|
490
490
|
}
|
|
491
491
|
}
|
|
492
|
-
},
|
|
492
|
+
}, be = () => A.Config.getCountry(), ve = {
|
|
493
493
|
get fullCurrency() {
|
|
494
|
-
return
|
|
494
|
+
return be().currency;
|
|
495
495
|
},
|
|
496
496
|
get currency() {
|
|
497
|
-
return
|
|
497
|
+
return be().currency.code;
|
|
498
498
|
},
|
|
499
499
|
get fullTax() {
|
|
500
|
-
return A.Country.getCountryFlattenTaxes(
|
|
500
|
+
return A.Country.getCountryFlattenTaxes(be().code);
|
|
501
501
|
},
|
|
502
502
|
get taxSystem() {
|
|
503
|
-
return
|
|
503
|
+
return be().taxSystems;
|
|
504
504
|
},
|
|
505
|
-
taxInclusion(
|
|
505
|
+
taxInclusion(C) {
|
|
506
506
|
return ve.taxSystem.map((S) => ({
|
|
507
507
|
systemCode: S.code,
|
|
508
|
-
inclusive:
|
|
508
|
+
inclusive: C !== void 0 ? C : !1
|
|
509
509
|
}));
|
|
510
510
|
},
|
|
511
511
|
groupedTaxOptions() {
|
|
512
|
-
const
|
|
512
|
+
const C = A.Country.getCountryFlattenTaxes(be().code);
|
|
513
513
|
return ve.taxSystem.map((S) => ({
|
|
514
514
|
code: S.code,
|
|
515
|
-
options:
|
|
515
|
+
options: C.map((o) => ({ ...o, feedmeTaxCode: ve.generateCode(o) })).filter((o) => o.systemCode === S.code)
|
|
516
516
|
}));
|
|
517
517
|
},
|
|
518
|
-
systemDefaultCode(
|
|
519
|
-
const S = ve.groupedTaxOptions().find((
|
|
520
|
-
return S == null ? void 0 : S.options.find((
|
|
518
|
+
systemDefaultCode(C) {
|
|
519
|
+
const S = ve.groupedTaxOptions().find((o) => o.code === C);
|
|
520
|
+
return S == null ? void 0 : S.options.find((o) => o.default);
|
|
521
521
|
},
|
|
522
|
-
generateCode(
|
|
523
|
-
return `${
|
|
522
|
+
generateCode(C) {
|
|
523
|
+
return `${C.systemCode}/${C.taxCode}`;
|
|
524
524
|
}
|
|
525
|
-
}, W = ve,
|
|
525
|
+
}, W = ve, Nt = /* @__PURE__ */ te({
|
|
526
526
|
__name: "TaxInclusiveSetting",
|
|
527
527
|
props: {
|
|
528
528
|
modelValue: {
|
|
@@ -532,54 +532,54 @@ const It = {
|
|
|
532
532
|
}
|
|
533
533
|
},
|
|
534
534
|
emits: ["update:model-value"],
|
|
535
|
-
setup(
|
|
536
|
-
const
|
|
537
|
-
function
|
|
538
|
-
const
|
|
539
|
-
T >= 0 ?
|
|
540
|
-
systemCode:
|
|
541
|
-
inclusive:
|
|
542
|
-
}), v.value =
|
|
535
|
+
setup(C, { emit: S }) {
|
|
536
|
+
const o = C, b = W.taxSystem, s = S, v = N(o.modelValue);
|
|
537
|
+
function a(c, y) {
|
|
538
|
+
const u = ae.clone(o.modelValue), T = u.findIndex((l) => l.systemCode === c);
|
|
539
|
+
T >= 0 ? u[T].inclusive = y : u.push({
|
|
540
|
+
systemCode: c,
|
|
541
|
+
inclusive: y
|
|
542
|
+
}), v.value = u, s("update:model-value", u);
|
|
543
543
|
}
|
|
544
|
-
function
|
|
545
|
-
return
|
|
546
|
-
const
|
|
544
|
+
function m() {
|
|
545
|
+
return b.map((c) => {
|
|
546
|
+
const y = o.modelValue ? o.modelValue.find((u) => u.systemCode === c.code) : !1;
|
|
547
547
|
return {
|
|
548
|
-
label:
|
|
548
|
+
label: c.name,
|
|
549
549
|
config: {
|
|
550
|
-
value:
|
|
550
|
+
value: y ? y.inclusive : !1
|
|
551
551
|
},
|
|
552
|
-
input: (
|
|
553
|
-
|
|
552
|
+
input: (u) => {
|
|
553
|
+
a(c.code, u);
|
|
554
554
|
}
|
|
555
555
|
};
|
|
556
556
|
});
|
|
557
557
|
}
|
|
558
|
-
const i =
|
|
559
|
-
function t(
|
|
560
|
-
return `${
|
|
558
|
+
const i = ze(m());
|
|
559
|
+
function t(c, y) {
|
|
560
|
+
return `${c} ${y ? "Inclusive" : "Exclusive"}`;
|
|
561
561
|
}
|
|
562
562
|
return he(() => {
|
|
563
|
-
|
|
563
|
+
o.modelValue.length || a(b[0].code, !1);
|
|
564
564
|
}), Pe(
|
|
565
|
-
() =>
|
|
566
|
-
(
|
|
567
|
-
|
|
565
|
+
() => o.modelValue,
|
|
566
|
+
(c, y) => {
|
|
567
|
+
c != y && !c.length && a(b[0].code, !1);
|
|
568
568
|
}
|
|
569
|
-
), (
|
|
570
|
-
const
|
|
571
|
-
return
|
|
569
|
+
), (c, y) => {
|
|
570
|
+
const u = _("FmSwitch");
|
|
571
|
+
return x(!0), D(Y, null, ce(e(i), (T, l) => {
|
|
572
572
|
var w;
|
|
573
|
-
return
|
|
574
|
-
r(
|
|
573
|
+
return x(), D("div", { key: l }, [
|
|
574
|
+
r(u, {
|
|
575
575
|
"model-value": ((w = e(v)[l]) == null ? void 0 : w.inclusive) || !1,
|
|
576
576
|
"label-placement": "left",
|
|
577
|
-
"onUpdate:modelValue": (
|
|
577
|
+
"onUpdate:modelValue": (U) => T.input(U)
|
|
578
578
|
}, {
|
|
579
579
|
label: B(() => {
|
|
580
|
-
var
|
|
580
|
+
var U;
|
|
581
581
|
return [
|
|
582
|
-
V("div", null, K(t(T.label, ((
|
|
582
|
+
V("div", null, K(t(T.label, ((U = e(v)[l]) == null ? void 0 : U.inclusive) || !1)), 1)
|
|
583
583
|
];
|
|
584
584
|
}),
|
|
585
585
|
_: 2
|
|
@@ -589,44 +589,44 @@ const It = {
|
|
|
589
589
|
};
|
|
590
590
|
}
|
|
591
591
|
});
|
|
592
|
-
var
|
|
593
|
-
const
|
|
592
|
+
var Dt = { mode: "development", appMode: "mf" };
|
|
593
|
+
const Ot = { class: "space-y-8" }, Mt = {
|
|
594
594
|
key: 0,
|
|
595
595
|
class: "space-y-16"
|
|
596
|
-
},
|
|
596
|
+
}, At = /* @__PURE__ */ te({
|
|
597
597
|
__name: "StripeSetting",
|
|
598
598
|
props: {
|
|
599
599
|
modelValue: {}
|
|
600
600
|
},
|
|
601
601
|
emits: ["update:modelValue"],
|
|
602
|
-
setup(
|
|
603
|
-
const
|
|
604
|
-
Pe(s, (
|
|
605
|
-
|
|
602
|
+
setup(C, { emit: S }) {
|
|
603
|
+
const o = C, b = S, s = N(!1);
|
|
604
|
+
Pe(s, (a, m) => {
|
|
605
|
+
m != a && (!o.modelValue && a ? b("update:modelValue", {
|
|
606
606
|
apiKey: "",
|
|
607
607
|
webhookSecret: ""
|
|
608
|
-
}) :
|
|
608
|
+
}) : a || b("update:modelValue", void 0));
|
|
609
609
|
});
|
|
610
610
|
const v = L(() => {
|
|
611
|
-
const
|
|
612
|
-
return `https://marketing${
|
|
611
|
+
const a = Dt.mode === "development", m = A.Config.getCountry().code.toLowerCase(), i = m != "my" ? `.${m}` : "";
|
|
612
|
+
return `https://marketing${a ? "-dev" : ""}${i}.feedmeapi.com/stripe/${Qe.getBusinessId()}/webhook`;
|
|
613
613
|
});
|
|
614
614
|
return he(() => {
|
|
615
|
-
s.value = !!
|
|
616
|
-
}), (
|
|
617
|
-
const i = _("FmSwitch"), t = _("FmTextField"),
|
|
618
|
-
return
|
|
615
|
+
s.value = !!o.modelValue;
|
|
616
|
+
}), (a, m) => {
|
|
617
|
+
const i = _("FmSwitch"), t = _("FmTextField"), c = _("FmButton");
|
|
618
|
+
return x(), D("div", Ot, [
|
|
619
619
|
r(i, {
|
|
620
620
|
modelValue: e(s),
|
|
621
|
-
"onUpdate:modelValue":
|
|
621
|
+
"onUpdate:modelValue": m[0] || (m[0] = (y) => re(s) ? s.value = y : null),
|
|
622
622
|
value: "true",
|
|
623
623
|
label: "Enable Stripe"
|
|
624
624
|
}, null, 8, ["modelValue"]),
|
|
625
|
-
|
|
625
|
+
o.modelValue ? (x(), D("div", Mt, [
|
|
626
626
|
r(t, {
|
|
627
627
|
label: "API Key",
|
|
628
|
-
modelValue:
|
|
629
|
-
"onUpdate:modelValue":
|
|
628
|
+
modelValue: o.modelValue.apiKey,
|
|
629
|
+
"onUpdate:modelValue": m[1] || (m[1] = (y) => o.modelValue.apiKey = y),
|
|
630
630
|
"helper-text": "Go to Stripe Dashboard get your API Key and paste here."
|
|
631
631
|
}, null, 8, ["modelValue"]),
|
|
632
632
|
r(t, {
|
|
@@ -636,17 +636,17 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
636
636
|
"helper-text": "Copy this URL to your Stripe dashboard"
|
|
637
637
|
}, {
|
|
638
638
|
append: B(() => [
|
|
639
|
-
r(
|
|
639
|
+
r(c, {
|
|
640
640
|
icon: "content_copy",
|
|
641
641
|
variant: "tertiary",
|
|
642
|
-
onClick:
|
|
642
|
+
onClick: m[2] || (m[2] = (y) => e(st)(e(v)))
|
|
643
643
|
})
|
|
644
644
|
]),
|
|
645
645
|
_: 1
|
|
646
646
|
}, 8, ["model-value"]),
|
|
647
647
|
r(t, {
|
|
648
|
-
modelValue:
|
|
649
|
-
"onUpdate:modelValue":
|
|
648
|
+
modelValue: o.modelValue.webhookSecret,
|
|
649
|
+
"onUpdate:modelValue": m[3] || (m[3] = (y) => o.modelValue.webhookSecret = y),
|
|
650
650
|
label: "Webhook Secret",
|
|
651
651
|
"helper-text": `Copy the webhook signing secret from your Stripe account and paste
|
|
652
652
|
here.`
|
|
@@ -655,21 +655,21 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
655
655
|
]);
|
|
656
656
|
};
|
|
657
657
|
}
|
|
658
|
-
}),
|
|
658
|
+
}), Et = {
|
|
659
659
|
key: 0,
|
|
660
660
|
class: "space-y-16 pr-12"
|
|
661
|
-
},
|
|
661
|
+
}, jt = { class: "fm-typo-en-title-sm-800 !mb-[-12px]" }, Lt = {
|
|
662
662
|
key: 1,
|
|
663
663
|
class: "space-y-16"
|
|
664
|
-
},
|
|
664
|
+
}, Kt = { class: "fm-typo-en-title-sm-800 !mb-[-12px]" }, Ht = { class: "fm-typo-en-title-sm-800 !mb-[-12px]" }, qt = { class: "grid grid-cols-2 gap-x-16 gap-y-16" }, Wt = { class: "space-y-4" }, Yt = { class: "fm-typo-en-body-lg-400" }, zt = { class: "space-y-16" }, Jt = { class: "fm-typo-en-title-sm-800 !mb-[-12px]" }, Gt = { class: "flex items-center gap-8" }, Xt = /* @__PURE__ */ te({
|
|
665
665
|
__name: "StoreSettingSheet",
|
|
666
666
|
emits: ["update"],
|
|
667
|
-
setup(
|
|
668
|
-
const { t:
|
|
669
|
-
company:
|
|
667
|
+
setup(C, { expose: S, emit: o }) {
|
|
668
|
+
const { t: b } = xe(), s = o, v = N(!1), a = N(), m = N(!1), i = et.extend({
|
|
669
|
+
company: tt.extend({
|
|
670
670
|
name: ee.string().min(1, "Company name is required"),
|
|
671
671
|
regNo: ee.string().min(1, "Registration number is required"),
|
|
672
|
-
address:
|
|
672
|
+
address: nt.extend({
|
|
673
673
|
line1: ee.string().min(1, "Line 1 is required"),
|
|
674
674
|
line2: ee.string().optional(),
|
|
675
675
|
state: ee.string().min(1, "State is required"),
|
|
@@ -680,12 +680,12 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
680
680
|
phoneNo: ee.string().min(1, "Phone number is required"),
|
|
681
681
|
sstRegNo: ee.string().optional()
|
|
682
682
|
})
|
|
683
|
-
}), t = L(() => i.safeParse(
|
|
684
|
-
function
|
|
685
|
-
const T = i.safeParse(
|
|
683
|
+
}), t = L(() => i.safeParse(a.value).success);
|
|
684
|
+
function c() {
|
|
685
|
+
const T = i.safeParse(a.value);
|
|
686
686
|
T.success && s("update", T.data);
|
|
687
687
|
}
|
|
688
|
-
function
|
|
688
|
+
function y() {
|
|
689
689
|
return {
|
|
690
690
|
company: {
|
|
691
691
|
name: "",
|
|
@@ -704,31 +704,31 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
704
704
|
inclusiveTaxes: []
|
|
705
705
|
};
|
|
706
706
|
}
|
|
707
|
-
function
|
|
708
|
-
v.value = T, T && (
|
|
707
|
+
function u(T, l) {
|
|
708
|
+
v.value = T, T && (a.value = l != null && l.company ? ae.cloneDeep(l) : y());
|
|
709
709
|
}
|
|
710
710
|
return S({
|
|
711
|
-
showSheet:
|
|
712
|
-
data:
|
|
711
|
+
showSheet: u,
|
|
712
|
+
data: a
|
|
713
713
|
}), (T, l) => {
|
|
714
|
-
const w = _("FmIcon"),
|
|
715
|
-
return
|
|
714
|
+
const w = _("FmIcon"), U = _("FmMenuItem"), j = _("FmMenu"), ne = _("FmSelect"), Z = _("FmButton"), H = _("FmSideSheet");
|
|
715
|
+
return x(), O(H, {
|
|
716
716
|
"max-width": 560,
|
|
717
717
|
modelValue: e(v),
|
|
718
718
|
"onUpdate:modelValue": l[15] || (l[15] = (z) => re(v) ? v.value = z : null),
|
|
719
|
-
header: e(
|
|
719
|
+
header: e(b)("connect.store.setting.title")
|
|
720
720
|
}, {
|
|
721
721
|
"side-sheet-footer": B(() => [
|
|
722
|
-
V("div",
|
|
722
|
+
V("div", Gt, [
|
|
723
723
|
r(Z, {
|
|
724
|
-
label: e(
|
|
725
|
-
onClick:
|
|
726
|
-
disabled: !e(t) || e(
|
|
727
|
-
loading: e(
|
|
724
|
+
label: e(b)("connect.common.save"),
|
|
725
|
+
onClick: c,
|
|
726
|
+
disabled: !e(t) || e(_e)().isLoading,
|
|
727
|
+
loading: e(_e)().isLoading
|
|
728
728
|
}, null, 8, ["label", "disabled", "loading"]),
|
|
729
729
|
r(Z, {
|
|
730
|
-
label: e(
|
|
731
|
-
onClick: l[14] || (l[14] = (z) =>
|
|
730
|
+
label: e(b)("connect.common.cancel"),
|
|
731
|
+
onClick: l[14] || (l[14] = (z) => u(!1)),
|
|
732
732
|
variant: "tertiary"
|
|
733
733
|
}, null, 8, ["label"])
|
|
734
734
|
])
|
|
@@ -736,103 +736,103 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
736
736
|
default: B(() => {
|
|
737
737
|
var z, oe;
|
|
738
738
|
return [
|
|
739
|
-
r(ke, { json: e(
|
|
740
|
-
e(
|
|
741
|
-
V("div",
|
|
739
|
+
r(ke, { json: e(a) }, null, 8, ["json"]),
|
|
740
|
+
e(a) && e(a).company ? (x(), D("div", Et, [
|
|
741
|
+
V("div", jt, K(e(b)("connect.store.setting.company.legal_info")), 1),
|
|
742
742
|
r(le, {
|
|
743
|
-
modelValue: e(
|
|
744
|
-
"onUpdate:modelValue": l[0] || (l[0] = (F) => e(
|
|
745
|
-
label: e(
|
|
743
|
+
modelValue: e(a).company.name,
|
|
744
|
+
"onUpdate:modelValue": l[0] || (l[0] = (F) => e(a).company.name = F),
|
|
745
|
+
label: e(b)("connect.store.setting.company.name"),
|
|
746
746
|
schema: e(Q).typeAtPath(e(i), "company.name")
|
|
747
747
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
748
748
|
r(le, {
|
|
749
|
-
modelValue: e(
|
|
750
|
-
"onUpdate:modelValue": l[1] || (l[1] = (F) => e(
|
|
751
|
-
label: e(
|
|
749
|
+
modelValue: e(a).company.regNo,
|
|
750
|
+
"onUpdate:modelValue": l[1] || (l[1] = (F) => e(a).company.regNo = F),
|
|
751
|
+
label: e(b)("connect.store.setting.company.reg_no"),
|
|
752
752
|
schema: e(Q).typeAtPath(e(i), "company.regNo")
|
|
753
753
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
754
|
-
e(A.Config).getCountry().taxSystems.length ? (
|
|
754
|
+
e(A.Config).getCountry().taxSystems.length ? (x(), O(le, {
|
|
755
755
|
key: 0,
|
|
756
|
-
modelValue: e(
|
|
756
|
+
modelValue: e(a).company.sstRegNo,
|
|
757
757
|
"onUpdate:modelValue": [
|
|
758
|
-
l[2] || (l[2] = (F) => e(
|
|
759
|
-
l[3] || (l[3] = (F) => F ? null : e(
|
|
758
|
+
l[2] || (l[2] = (F) => e(a).company.sstRegNo = F),
|
|
759
|
+
l[3] || (l[3] = (F) => F ? null : e(a).inclusiveTaxes = [])
|
|
760
760
|
],
|
|
761
|
-
label: e(
|
|
761
|
+
label: e(b)("connect.store.setting.company.tax_reg_no"),
|
|
762
762
|
schema: e(Q).typeAtPath(e(i), "company.sstRegNo")
|
|
763
763
|
}, null, 8, ["modelValue", "label", "schema"])) : E("", !0),
|
|
764
|
-
(z = e(
|
|
765
|
-
V("div",
|
|
766
|
-
r(
|
|
767
|
-
modelValue: e(
|
|
768
|
-
"onUpdate:modelValue": l[4] || (l[4] = (F) => e(
|
|
764
|
+
(z = e(a).company) != null && z.sstRegNo && e(a).inclusiveTaxes ? (x(), D("div", Lt, [
|
|
765
|
+
V("div", Kt, K(e(b)("connect.store.setting.company.tax")), 1),
|
|
766
|
+
r(Nt, {
|
|
767
|
+
modelValue: e(a).inclusiveTaxes,
|
|
768
|
+
"onUpdate:modelValue": l[4] || (l[4] = (F) => e(a).inclusiveTaxes = F)
|
|
769
769
|
}, null, 8, ["modelValue"])
|
|
770
770
|
])) : E("", !0),
|
|
771
771
|
r(le, {
|
|
772
|
-
modelValue: e(
|
|
773
|
-
"onUpdate:modelValue": l[5] || (l[5] = (F) => e(
|
|
774
|
-
label: e(
|
|
772
|
+
modelValue: e(a).company.phoneNo,
|
|
773
|
+
"onUpdate:modelValue": l[5] || (l[5] = (F) => e(a).company.phoneNo = F),
|
|
774
|
+
label: e(b)("connect.store.setting.company.phone"),
|
|
775
775
|
schema: e(Q).typeAtPath(e(i), "company.phoneNo")
|
|
776
776
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
777
|
-
V("div",
|
|
777
|
+
V("div", Ht, K(e(b)("connect.store.setting.company.address.title")), 1),
|
|
778
778
|
r(le, {
|
|
779
|
-
modelValue: e(
|
|
780
|
-
"onUpdate:modelValue": l[6] || (l[6] = (F) => e(
|
|
781
|
-
label: e(
|
|
779
|
+
modelValue: e(a).company.address.line1,
|
|
780
|
+
"onUpdate:modelValue": l[6] || (l[6] = (F) => e(a).company.address.line1 = F),
|
|
781
|
+
label: e(b)("connect.store.setting.company.address.line1"),
|
|
782
782
|
schema: e(Q).typeAtPath(e(i), "company.address.line1")
|
|
783
783
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
784
784
|
r(le, {
|
|
785
|
-
modelValue: e(
|
|
786
|
-
"onUpdate:modelValue": l[7] || (l[7] = (F) => e(
|
|
787
|
-
label: e(
|
|
785
|
+
modelValue: e(a).company.address.line2,
|
|
786
|
+
"onUpdate:modelValue": l[7] || (l[7] = (F) => e(a).company.address.line2 = F),
|
|
787
|
+
label: e(b)("connect.store.setting.company.address.line2"),
|
|
788
788
|
schema: e(Q).typeAtPath(e(i), "company.address.line2")
|
|
789
789
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
790
|
-
V("div",
|
|
790
|
+
V("div", qt, [
|
|
791
791
|
r(le, {
|
|
792
|
-
modelValue: e(
|
|
793
|
-
"onUpdate:modelValue": l[8] || (l[8] = (F) => e(
|
|
794
|
-
label: e(
|
|
792
|
+
modelValue: e(a).company.address.city,
|
|
793
|
+
"onUpdate:modelValue": l[8] || (l[8] = (F) => e(a).company.address.city = F),
|
|
794
|
+
label: e(b)("connect.store.setting.company.address.city"),
|
|
795
795
|
schema: e(Q).typeAtPath(e(i), "company.address.city")
|
|
796
796
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
797
797
|
r(le, {
|
|
798
|
-
modelValue: e(
|
|
799
|
-
"onUpdate:modelValue": l[9] || (l[9] = (F) => e(
|
|
800
|
-
label: e(
|
|
798
|
+
modelValue: e(a).company.address.postcode,
|
|
799
|
+
"onUpdate:modelValue": l[9] || (l[9] = (F) => e(a).company.address.postcode = F),
|
|
800
|
+
label: e(b)("connect.store.setting.company.address.postcode"),
|
|
801
801
|
schema: e(Q).typeAtPath(e(i), "company.address.postcode")
|
|
802
802
|
}, null, 8, ["modelValue", "label", "schema"]),
|
|
803
|
-
V("div",
|
|
804
|
-
V("div",
|
|
803
|
+
V("div", Wt, [
|
|
804
|
+
V("div", Yt, K(e(b)("connect.store.setting.company.address.state")), 1),
|
|
805
805
|
r(j, {
|
|
806
806
|
placement: "top-end",
|
|
807
|
-
"model-value": e(
|
|
807
|
+
"model-value": e(m)
|
|
808
808
|
}, {
|
|
809
809
|
"menu-button": B(() => [
|
|
810
810
|
r(le, {
|
|
811
|
-
modelValue: e(
|
|
812
|
-
"onUpdate:modelValue": l[10] || (l[10] = (F) => e(
|
|
811
|
+
modelValue: e(a).company.address.state,
|
|
812
|
+
"onUpdate:modelValue": l[10] || (l[10] = (F) => e(a).company.address.state = F),
|
|
813
813
|
schema: e(Q).typeAtPath(e(i), "company.address.state"),
|
|
814
|
-
onFocusChanged: l[11] || (l[11] = (F) =>
|
|
814
|
+
onFocusChanged: l[11] || (l[11] = (F) => m.value = F)
|
|
815
815
|
}, {
|
|
816
816
|
append: B(() => [
|
|
817
817
|
r(w, {
|
|
818
|
-
name: e(
|
|
818
|
+
name: e(m) ? "keyboard_arrow_up" : "keyboard_arrow_down"
|
|
819
819
|
}, null, 8, ["name"])
|
|
820
820
|
]),
|
|
821
821
|
_: 1
|
|
822
822
|
}, 8, ["modelValue", "schema"])
|
|
823
823
|
]),
|
|
824
824
|
default: B(() => [
|
|
825
|
-
(
|
|
825
|
+
(x(!0), D(Y, null, ce(e(Bt)[e(A.Config).getCountry().code].stateItems.filter(
|
|
826
826
|
(F) => {
|
|
827
|
-
var ie,
|
|
828
|
-
return F.label.toLowerCase().includes(((
|
|
827
|
+
var ie, g;
|
|
828
|
+
return F.label.toLowerCase().includes(((g = (ie = e(a)) == null ? void 0 : ie.company) == null ? void 0 : g.address.state.toLowerCase()) ?? "");
|
|
829
829
|
}
|
|
830
|
-
) || [], (F) => (
|
|
830
|
+
) || [], (F) => (x(), O(U, {
|
|
831
831
|
key: F.value,
|
|
832
|
-
"model-value": e(
|
|
832
|
+
"model-value": e(a).company.address.state === F.value,
|
|
833
833
|
label: F.label,
|
|
834
834
|
onClick: () => {
|
|
835
|
-
e(
|
|
835
|
+
e(a).company.address.state = F.value, m.value = !1;
|
|
836
836
|
}
|
|
837
837
|
}, null, 8, ["model-value", "label", "onClick"]))), 128))
|
|
838
838
|
]),
|
|
@@ -840,9 +840,9 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
840
840
|
}, 8, ["model-value"])
|
|
841
841
|
]),
|
|
842
842
|
r(ne, {
|
|
843
|
-
label: e(
|
|
844
|
-
modelValue: e(
|
|
845
|
-
"onUpdate:modelValue": l[12] || (l[12] = (F) => e(
|
|
843
|
+
label: e(b)("connect.store.setting.company.address.country"),
|
|
844
|
+
modelValue: e(a).company.address.country,
|
|
845
|
+
"onUpdate:modelValue": l[12] || (l[12] = (F) => e(a).company.address.country = F),
|
|
846
846
|
items: [
|
|
847
847
|
{
|
|
848
848
|
label: e(A.Config).getCountry().name,
|
|
@@ -852,11 +852,11 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
852
852
|
rules: [e(Q).ruleAtPath(e(i), "company.address.country")]
|
|
853
853
|
}, null, 8, ["label", "modelValue", "items", "rules"])
|
|
854
854
|
]),
|
|
855
|
-
V("div",
|
|
856
|
-
V("div",
|
|
857
|
-
r(
|
|
858
|
-
"model-value": (oe = e(
|
|
859
|
-
"onUpdate:modelValue": l[13] || (l[13] = (F) => e(
|
|
855
|
+
V("div", zt, [
|
|
856
|
+
V("div", Jt, K(e(b)("connect.store.setting.stripe.title")), 1),
|
|
857
|
+
r(At, {
|
|
858
|
+
"model-value": (oe = e(a)) == null ? void 0 : oe.stripe,
|
|
859
|
+
"onUpdate:modelValue": l[13] || (l[13] = (F) => e(a).stripe = F)
|
|
860
860
|
}, null, 8, ["model-value"])
|
|
861
861
|
])
|
|
862
862
|
])) : E("", !0)
|
|
@@ -867,10 +867,10 @@ const Dt = { class: "space-y-8" }, Mt = {
|
|
|
867
867
|
};
|
|
868
868
|
}
|
|
869
869
|
});
|
|
870
|
-
function
|
|
871
|
-
return A.DineroFactory(
|
|
870
|
+
function Zt(C, S = !0) {
|
|
871
|
+
return A.DineroFactory(C).toFormat(S);
|
|
872
872
|
}
|
|
873
|
-
const
|
|
873
|
+
const Qt = /* @__PURE__ */ te({
|
|
874
874
|
__name: "TaxVariantSetting",
|
|
875
875
|
props: {
|
|
876
876
|
modelValue: {
|
|
@@ -880,15 +880,15 @@ const Zt = /* @__PURE__ */ te({
|
|
|
880
880
|
}
|
|
881
881
|
},
|
|
882
882
|
emits: ["update:modelValue"],
|
|
883
|
-
setup(
|
|
884
|
-
const
|
|
883
|
+
setup(C, { emit: S }) {
|
|
884
|
+
const o = C, b = S;
|
|
885
885
|
he(() => {
|
|
886
|
-
if (
|
|
887
|
-
const t = v.value.reduce((
|
|
888
|
-
const
|
|
889
|
-
if (!
|
|
890
|
-
const { systemCode: T, taxCode: l } =
|
|
891
|
-
return
|
|
886
|
+
if (a.value.length !== v.value.length) {
|
|
887
|
+
const t = v.value.reduce((c, y) => {
|
|
888
|
+
const u = W.systemDefaultCode(y.name);
|
|
889
|
+
if (!u) return c;
|
|
890
|
+
const { systemCode: T, taxCode: l } = u;
|
|
891
|
+
return y.value || c.push({ systemCode: T, taxCode: l }), c;
|
|
892
892
|
}, []);
|
|
893
893
|
i(t);
|
|
894
894
|
}
|
|
@@ -898,50 +898,50 @@ const Zt = /* @__PURE__ */ te({
|
|
|
898
898
|
}
|
|
899
899
|
const v = L(() => s().map((t) => ({
|
|
900
900
|
name: t.code,
|
|
901
|
-
value: (
|
|
902
|
-
(
|
|
901
|
+
value: (a.value || []).find(
|
|
902
|
+
(c) => t.options.some((y) => y.feedmeTaxCode === c)
|
|
903
903
|
),
|
|
904
|
-
options: t.options.map((
|
|
905
|
-
label: `${
|
|
906
|
-
value:
|
|
904
|
+
options: t.options.map((c) => ({
|
|
905
|
+
label: `${c.name} (${pt(c.rate)}%)`,
|
|
906
|
+
value: c.feedmeTaxCode
|
|
907
907
|
}))
|
|
908
|
-
}))),
|
|
909
|
-
function
|
|
910
|
-
const
|
|
908
|
+
}))), a = L(() => o.modelValue.map((t) => W.generateCode(t)));
|
|
909
|
+
function m(t) {
|
|
910
|
+
const c = s().find(
|
|
911
911
|
(l) => l.options.some((w) => w.feedmeTaxCode === t)
|
|
912
|
-
),
|
|
913
|
-
if (!
|
|
914
|
-
const { systemCode:
|
|
915
|
-
i([{ systemCode:
|
|
912
|
+
), y = c == null ? void 0 : c.options.find((l) => l.feedmeTaxCode === t);
|
|
913
|
+
if (!y) return;
|
|
914
|
+
const { systemCode: u, taxCode: T } = y;
|
|
915
|
+
i([{ systemCode: u, taxCode: T }]);
|
|
916
916
|
}
|
|
917
917
|
function i(t) {
|
|
918
|
-
const
|
|
919
|
-
t.forEach((
|
|
920
|
-
const
|
|
921
|
-
(w) => w.options.some((
|
|
922
|
-
), T = (
|
|
923
|
-
(w) => T.some((
|
|
918
|
+
const c = ae.clone(o.modelValue);
|
|
919
|
+
t.forEach((y) => {
|
|
920
|
+
const u = s().find(
|
|
921
|
+
(w) => w.options.some((U) => U.feedmeTaxCode === W.generateCode(y))
|
|
922
|
+
), T = (u == null ? void 0 : u.options) || [], l = c.findIndex(
|
|
923
|
+
(w) => T.some((U) => W.generateCode(U) === W.generateCode(w))
|
|
924
924
|
);
|
|
925
|
-
l >= 0 ?
|
|
926
|
-
}),
|
|
925
|
+
l >= 0 ? c.splice(l, 1, y) : c.push(y);
|
|
926
|
+
}), b("update:modelValue", c);
|
|
927
927
|
}
|
|
928
|
-
return (t,
|
|
929
|
-
const
|
|
930
|
-
return
|
|
928
|
+
return (t, c) => {
|
|
929
|
+
const y = _("FmRadio"), u = _("FmRadioGroup");
|
|
930
|
+
return x(!0), D(Y, null, ce(e(v), (T) => (x(), D("div", {
|
|
931
931
|
key: T.name,
|
|
932
932
|
class: "flex items-start"
|
|
933
933
|
}, [
|
|
934
|
-
r(
|
|
934
|
+
r(u, {
|
|
935
935
|
modelValue: T.value,
|
|
936
936
|
"onUpdate:modelValue": [
|
|
937
937
|
(l) => T.value = l,
|
|
938
|
-
|
|
939
|
-
|
|
938
|
+
c[0] || (c[0] = (l) => {
|
|
939
|
+
m(l);
|
|
940
940
|
})
|
|
941
941
|
]
|
|
942
942
|
}, {
|
|
943
943
|
default: B(() => [
|
|
944
|
-
(
|
|
944
|
+
(x(!0), D(Y, null, ce(T.options, (l, w) => (x(), O(y, {
|
|
945
945
|
key: w,
|
|
946
946
|
value: l.value,
|
|
947
947
|
label: l.label
|
|
@@ -974,53 +974,53 @@ const Zt = /* @__PURE__ */ te({
|
|
|
974
974
|
taxes: [],
|
|
975
975
|
taxTotals: [],
|
|
976
976
|
internal: !1,
|
|
977
|
-
priceWithTaxes:
|
|
978
|
-
},
|
|
977
|
+
priceWithTaxes: ct()
|
|
978
|
+
}, en = {
|
|
979
979
|
key: 0,
|
|
980
980
|
class: "space-y-24 pr-12"
|
|
981
|
-
},
|
|
981
|
+
}, tn = { class: "space-y-8" }, nn = { class: "fm-typo-en-title-sm-800 !mb-[-16px]" }, on = { class: "fm-typo-en-title-sm-800 !mb-[-16px]" }, an = { class: "fm-typo-en-title-sm-800 !mb-[-16px]" }, ln = { class: "fm-typo-en-title-sm-800 !mb-[-20px]" }, sn = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary !mb-[-16px]" }, rn = { class: "space-y-8" }, dn = { class: "flex items-center justify-between" }, un = { class: "fm-typo-en-title-sm-800 !mb-[-20px]" }, cn = { class: "space-y-8" }, mn = { class: "flex items-center gap-8" }, pn = /* @__PURE__ */ te({
|
|
982
982
|
__name: "EditBundleSheet",
|
|
983
983
|
emits: ["update"],
|
|
984
|
-
setup(
|
|
985
|
-
const
|
|
984
|
+
setup(C, { expose: S, emit: o }) {
|
|
985
|
+
const b = o, { t: s } = xe(), v = Te(), a = N(!1), m = N([]), i = N({
|
|
986
986
|
category: 0,
|
|
987
987
|
index: -1,
|
|
988
988
|
originalCategoryIndex: void 0
|
|
989
|
-
}), t = N(ae.cloneDeep(we)),
|
|
990
|
-
const
|
|
991
|
-
return
|
|
989
|
+
}), t = N(ae.cloneDeep(we)), c = N(), y = Ae, u = L(() => {
|
|
990
|
+
const d = y.safeParse(t.value);
|
|
991
|
+
return d.success ? [] : d.error.errors;
|
|
992
992
|
}), T = [
|
|
993
993
|
{
|
|
994
994
|
header: "Reward title",
|
|
995
|
-
accessorFn: (
|
|
995
|
+
accessorFn: (d) => d.collectible.name,
|
|
996
996
|
enableSorting: !0
|
|
997
997
|
},
|
|
998
998
|
{
|
|
999
999
|
id: "type",
|
|
1000
1000
|
header: "Reward type",
|
|
1001
|
-
accessorFn: (
|
|
1002
|
-
cell(
|
|
1003
|
-
return
|
|
1001
|
+
accessorFn: (d) => d.collectible.type,
|
|
1002
|
+
cell(d) {
|
|
1003
|
+
return ye[d.row.original.collectible.type].chip();
|
|
1004
1004
|
}
|
|
1005
1005
|
},
|
|
1006
1006
|
{
|
|
1007
1007
|
header: "Description",
|
|
1008
|
-
accessorFn: (
|
|
1009
|
-
cell(
|
|
1008
|
+
accessorFn: (d) => d.description,
|
|
1009
|
+
cell(d) {
|
|
1010
1010
|
var p;
|
|
1011
|
-
const n =
|
|
1012
|
-
return n.collectible.type == "VOUCHER" || n.selectedReward == null ? n.description :
|
|
1013
|
-
"onUpdate:modelValue": (
|
|
1011
|
+
const n = d.row.original;
|
|
1012
|
+
return n.collectible.type == "VOUCHER" || n.selectedReward == null ? n.description : Ge(Ze.FmStepperField, {
|
|
1013
|
+
"onUpdate:modelValue": (f) => {
|
|
1014
1014
|
t.value.titles = t.value.titles.map(
|
|
1015
|
-
(
|
|
1015
|
+
(I) => I.id == n.collectible._id ? { ...I, dayToExpire: f } : I
|
|
1016
1016
|
);
|
|
1017
1017
|
},
|
|
1018
1018
|
modelValue: ((p = n.selectedReward) == null ? void 0 : p.extra) ?? 0,
|
|
1019
1019
|
appendText: "day(s)",
|
|
1020
|
-
helperState: G(
|
|
1021
|
-
helperText: X(
|
|
1020
|
+
helperState: G(u.value, "titles"),
|
|
1021
|
+
helperText: X(u.value, "titles"),
|
|
1022
1022
|
max: 9999,
|
|
1023
|
-
rules: [(
|
|
1023
|
+
rules: [(f) => f <= 9999 || "Maximum 9999 days allowed"],
|
|
1024
1024
|
showSteppers: !1,
|
|
1025
1025
|
disabled: !!t.value.stripePriceId
|
|
1026
1026
|
});
|
|
@@ -1028,24 +1028,24 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1028
1028
|
}
|
|
1029
1029
|
], l = N([]), w = L(() => {
|
|
1030
1030
|
var n;
|
|
1031
|
-
const
|
|
1031
|
+
const d = (n = t.value) != null && n.isFeedvibe ? "STORE_BUNDLE:FEEDVIBE" : "STORE_BUNDLE:DEFAULT";
|
|
1032
1032
|
return v.bundleRewards.filter((p) => {
|
|
1033
|
-
var
|
|
1034
|
-
return (
|
|
1033
|
+
var f;
|
|
1034
|
+
return (f = t.value) != null && f.isFeedvibe && p.type !== "VOUCHER" ? !1 : ft(p.capabilities, d);
|
|
1035
1035
|
}).map((p) => {
|
|
1036
|
-
const
|
|
1036
|
+
const f = U.value.find((M) => M.id == p._id), I = p.type === "VOUCHER" ? `${p.options.maxUse} use(s), ${yt(
|
|
1037
1037
|
p.options.validityOption || {}
|
|
1038
1038
|
)}` : "No expiry";
|
|
1039
1039
|
return {
|
|
1040
1040
|
collectible: p,
|
|
1041
|
-
description:
|
|
1042
|
-
selectedReward:
|
|
1041
|
+
description: I,
|
|
1042
|
+
selectedReward: f
|
|
1043
1043
|
};
|
|
1044
1044
|
});
|
|
1045
|
-
}),
|
|
1046
|
-
var
|
|
1045
|
+
}), U = L(() => {
|
|
1046
|
+
var d, n;
|
|
1047
1047
|
return [
|
|
1048
|
-
...((
|
|
1048
|
+
...((d = t.value) == null ? void 0 : d.titles.map((p) => ({
|
|
1049
1049
|
id: p.id,
|
|
1050
1050
|
extra: p.dayToExpire
|
|
1051
1051
|
}))) ?? [],
|
|
@@ -1057,105 +1057,105 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1057
1057
|
}), j = L(
|
|
1058
1058
|
() => t.value.stripePriceId && t.value.subscriptionValidity ? t.value.subscriptionValidity : 0
|
|
1059
1059
|
);
|
|
1060
|
-
function ne(
|
|
1061
|
-
t.value.subscriptionValidity =
|
|
1060
|
+
function ne(d) {
|
|
1061
|
+
t.value.subscriptionValidity = d;
|
|
1062
1062
|
for (const n of t.value.titles)
|
|
1063
|
-
n.dayToExpire =
|
|
1064
|
-
t.value.credit.free && (t.value.credit.free.day =
|
|
1063
|
+
n.dayToExpire = d;
|
|
1064
|
+
t.value.credit.free && (t.value.credit.free.day = d);
|
|
1065
1065
|
}
|
|
1066
1066
|
function Z() {
|
|
1067
|
-
const
|
|
1068
|
-
if (!(!n || !
|
|
1069
|
-
for (let p = 0; p <
|
|
1070
|
-
const
|
|
1071
|
-
H.value[p] ?
|
|
1072
|
-
(
|
|
1067
|
+
const d = w.value, n = t.value;
|
|
1068
|
+
if (!(!n || !d))
|
|
1069
|
+
for (let p = 0; p < d.length; p++) {
|
|
1070
|
+
const f = d[p];
|
|
1071
|
+
H.value[p] ? f.collectible.type == "TITLE" ? n.titles.findIndex(
|
|
1072
|
+
(R) => R.id == f.collectible._id
|
|
1073
1073
|
) < 0 && n.titles.push({
|
|
1074
|
-
id:
|
|
1074
|
+
id: f.collectible._id,
|
|
1075
1075
|
dayToExpire: j.value
|
|
1076
1076
|
}) : n.vouchers.findIndex(
|
|
1077
|
-
(
|
|
1078
|
-
) < 0 && n.vouchers.push(
|
|
1079
|
-
(
|
|
1077
|
+
(R) => R == f.collectible._id
|
|
1078
|
+
) < 0 && n.vouchers.push(f.collectible._id) : (n.titles = n.titles.filter((M) => M.id != f.collectible._id), n.vouchers = n.vouchers.filter(
|
|
1079
|
+
(M) => M != f.collectible._id
|
|
1080
1080
|
));
|
|
1081
1081
|
}
|
|
1082
1082
|
}
|
|
1083
1083
|
const H = N({});
|
|
1084
1084
|
Pe(H, Z, { deep: !0 });
|
|
1085
1085
|
const z = L(() => {
|
|
1086
|
-
var
|
|
1087
|
-
return (n = (
|
|
1086
|
+
var d, n;
|
|
1087
|
+
return (n = (d = v.storeOption) == null ? void 0 : d.company) == null ? void 0 : n.sstRegNo;
|
|
1088
1088
|
}), oe = L(() => {
|
|
1089
|
-
var
|
|
1090
|
-
return (p = (n = (
|
|
1089
|
+
var d, n, p;
|
|
1090
|
+
return (p = (n = (d = v.storeOption) == null ? void 0 : d.inclusiveTaxes) == null ? void 0 : n[0]) != null && p.inclusive ? "Inclusive" : "Exclusive";
|
|
1091
1091
|
}), F = L(() => {
|
|
1092
|
-
var
|
|
1093
|
-
return
|
|
1092
|
+
var d, n, p;
|
|
1093
|
+
return qe(
|
|
1094
1094
|
W.fullTax,
|
|
1095
|
-
|
|
1095
|
+
Je(t.value.taxes),
|
|
1096
1096
|
t.value.price,
|
|
1097
1097
|
Number(t.value.credit.normal),
|
|
1098
|
-
((
|
|
1099
|
-
(p = (n = v.storeOption) == null ? void 0 : n.company) != null && p.sstRegNo ? W.taxSystem.map((
|
|
1098
|
+
((d = v.storeOption) == null ? void 0 : d.inclusiveTaxes) ?? [],
|
|
1099
|
+
(p = (n = v.storeOption) == null ? void 0 : n.company) != null && p.sstRegNo ? W.taxSystem.map((f) => f.code) : []
|
|
1100
1100
|
);
|
|
1101
1101
|
}), ie = L(() => F.value.reduce(
|
|
1102
1102
|
(n, p) => n.add(p.total),
|
|
1103
|
-
|
|
1104
|
-
).toFormat()),
|
|
1105
|
-
var
|
|
1106
|
-
const
|
|
1103
|
+
mt()
|
|
1104
|
+
).toFormat()), g = L(() => {
|
|
1105
|
+
var f;
|
|
1106
|
+
const d = We(
|
|
1107
1107
|
F.value,
|
|
1108
1108
|
t.value.price,
|
|
1109
|
-
((
|
|
1109
|
+
((f = v.storeOption) == null ? void 0 : f.inclusiveTaxes) ?? []
|
|
1110
1110
|
);
|
|
1111
|
-
t.value.priceWithTaxes =
|
|
1112
|
-
const n =
|
|
1111
|
+
t.value.priceWithTaxes = d;
|
|
1112
|
+
const n = Zt(d, !1), p = Number(n.replace(/[^\d.-]/g, ""));
|
|
1113
1113
|
return Number.isNaN(p) ? 0 : p;
|
|
1114
1114
|
});
|
|
1115
1115
|
function k() {
|
|
1116
|
-
t.value.taxTotals = F.value,
|
|
1116
|
+
t.value.taxTotals = F.value, b("update", Ae.parse(at(t.value)));
|
|
1117
1117
|
}
|
|
1118
|
-
function
|
|
1118
|
+
function h() {
|
|
1119
1119
|
return ae.cloneDeep(we);
|
|
1120
1120
|
}
|
|
1121
|
-
function
|
|
1122
|
-
|
|
1121
|
+
function $(d, n) {
|
|
1122
|
+
a.value = d, d && n && (c.value = void 0, m.value = n.categories, t.value = n.bundle || h(), i.value.category = n.category, i.value.index = n.index, i.value.originalCategoryIndex = n.category, H.value = w.value.reduce((p, f, I) => (p[I] = !!f.selectedReward, p), {}));
|
|
1123
1123
|
}
|
|
1124
1124
|
return S({
|
|
1125
|
-
showSheet:
|
|
1126
|
-
bundleImage:
|
|
1125
|
+
showSheet: $,
|
|
1126
|
+
bundleImage: c,
|
|
1127
1127
|
target: i,
|
|
1128
1128
|
data: t
|
|
1129
|
-
}), (
|
|
1130
|
-
const p = _("FmSwitch"),
|
|
1131
|
-
return
|
|
1129
|
+
}), (d, n) => {
|
|
1130
|
+
const p = _("FmSwitch"), f = _("FmHelperText"), I = _("FmTextField"), M = _("FmSelect"), R = _("FmStepperField"), q = _("FmMenuItem"), J = _("FmTable"), fe = _("FmButton"), Ce = _("FmSideSheet");
|
|
1131
|
+
return x(), O(Ce, {
|
|
1132
1132
|
"max-width": 768,
|
|
1133
|
-
modelValue: e(
|
|
1134
|
-
"onUpdate:modelValue": n[21] || (n[21] = (de) => re(
|
|
1133
|
+
modelValue: e(a),
|
|
1134
|
+
"onUpdate:modelValue": n[21] || (n[21] = (de) => re(a) ? a.value = de : null),
|
|
1135
1135
|
header: e(i).index != -1 ? e(s)("connect.store.bundle.edit.title") : e(s)("connect.store.bundle.edit.create")
|
|
1136
1136
|
}, {
|
|
1137
1137
|
"side-sheet-footer": B(() => [
|
|
1138
|
-
V("div",
|
|
1139
|
-
r(
|
|
1138
|
+
V("div", mn, [
|
|
1139
|
+
r(fe, {
|
|
1140
1140
|
label: e(i).index != -1 ? "Save" : "Add",
|
|
1141
1141
|
onClick: k,
|
|
1142
|
-
disabled: e(
|
|
1143
|
-
loading: e(
|
|
1142
|
+
disabled: e(u).length > 0,
|
|
1143
|
+
loading: e(_e)().isLoading
|
|
1144
1144
|
}, null, 8, ["label", "disabled", "loading"]),
|
|
1145
|
-
r(
|
|
1145
|
+
r(fe, {
|
|
1146
1146
|
label: "Cancel",
|
|
1147
|
-
onClick: n[20] || (n[20] = (de) =>
|
|
1147
|
+
onClick: n[20] || (n[20] = (de) => $(!1)),
|
|
1148
1148
|
variant: "tertiary"
|
|
1149
1149
|
})
|
|
1150
1150
|
])
|
|
1151
1151
|
]),
|
|
1152
1152
|
default: B(() => {
|
|
1153
|
-
var de, $e, Ue, Re, Ie, Be, Ne, De,
|
|
1153
|
+
var de, $e, Ue, Re, Ie, Be, Ne, De, Oe, Me;
|
|
1154
1154
|
return [
|
|
1155
1155
|
r(ke, { json: e(t) }, null, 8, ["json"]),
|
|
1156
|
-
e(t) ? (
|
|
1157
|
-
V("div",
|
|
1158
|
-
e(A.Config).getCountry().code == "MY" && ((de = e(v).payoutAccount) == null ? void 0 : de.status) == "APPROVED" && (($e = e(v).payoutAccount) != null && $e.enable) ? (
|
|
1156
|
+
e(t) ? (x(), D("div", en, [
|
|
1157
|
+
V("div", tn, [
|
|
1158
|
+
e(A.Config).getCountry().code == "MY" && ((de = e(v).payoutAccount) == null ? void 0 : de.status) == "APPROVED" && (($e = e(v).payoutAccount) != null && $e.enable) ? (x(), O(p, {
|
|
1159
1159
|
key: 0,
|
|
1160
1160
|
"onUpdate:modelValue": n[0] || (n[0] = (P) => {
|
|
1161
1161
|
e(t).isFeedvibe = P, e(t).isFeedvibe && (e(t).credit.normal = 0, e(t).coinPrice = 0, e(t).titles = [], H.value = {}, e(t).hideInPos = !0, e(t).internal = !0);
|
|
@@ -1165,39 +1165,39 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1165
1165
|
label: "Feedvibe Campaign",
|
|
1166
1166
|
sublabel: "Bundle will be appear for Feedvibe campaign use"
|
|
1167
1167
|
}, null, 8, ["model-value"])) : E("", !0),
|
|
1168
|
-
e(t).isFeedvibe ? (
|
|
1168
|
+
e(t).isFeedvibe ? (x(), O(f, {
|
|
1169
1169
|
key: 1,
|
|
1170
1170
|
text: "There will be a 15% charge for FeedVibe bundles sold in the FeedVibe app. FeedVibe bundles only show up in the FeedVibe app and cannot be sold in the POS and mini program. For more information, please contact support.",
|
|
1171
1171
|
state: "warning"
|
|
1172
1172
|
})) : E("", !0)
|
|
1173
1173
|
]),
|
|
1174
|
-
V("div",
|
|
1175
|
-
r(
|
|
1174
|
+
V("div", nn, K(e(s)("connect.store.bundle.edit.basicInformation")), 1),
|
|
1175
|
+
r(I, {
|
|
1176
1176
|
label: e(s)("connect.store.bundle.edit.bundleName"),
|
|
1177
1177
|
modelValue: e(t).name,
|
|
1178
1178
|
"onUpdate:modelValue": n[1] || (n[1] = (P) => e(t).name = P),
|
|
1179
|
-
"helper-state": e(G)(e(
|
|
1180
|
-
"helper-text": e(X)(e(
|
|
1179
|
+
"helper-state": e(G)(e(u), "name"),
|
|
1180
|
+
"helper-text": e(X)(e(u), "name")
|
|
1181
1181
|
}, null, 8, ["label", "modelValue", "helper-state", "helper-text"]),
|
|
1182
|
-
r(
|
|
1182
|
+
r(M, {
|
|
1183
1183
|
modelValue: e(i).category,
|
|
1184
1184
|
"onUpdate:modelValue": n[2] || (n[2] = (P) => e(i).category = P),
|
|
1185
1185
|
label: "Store Category",
|
|
1186
|
-
items: e(
|
|
1186
|
+
items: e(m).map((P, Ye) => ({ label: P, value: Ye }))
|
|
1187
1187
|
}, null, 8, ["modelValue", "items"]),
|
|
1188
|
-
r(
|
|
1188
|
+
r(dt, {
|
|
1189
1189
|
label: e(s)("connect.store.bundle.edit.bundleImage"),
|
|
1190
1190
|
class: "w-1/2 xs:w-2/3",
|
|
1191
1191
|
"aspect-ratio": "16/9",
|
|
1192
1192
|
thumbnail: e(t).image ?? void 0,
|
|
1193
|
-
file: e(
|
|
1193
|
+
file: e(c) ?? void 0,
|
|
1194
1194
|
"onUpdate:file": n[3] || (n[3] = (P) => {
|
|
1195
|
-
|
|
1195
|
+
c.value = P;
|
|
1196
1196
|
}),
|
|
1197
|
-
"helper-state": e(G)(e(
|
|
1198
|
-
"helper-text": e(X)(e(
|
|
1197
|
+
"helper-state": e(G)(e(u), "image"),
|
|
1198
|
+
"helper-text": e(X)(e(u), "image")
|
|
1199
1199
|
}, null, 8, ["label", "thumbnail", "file", "helper-state", "helper-text"]),
|
|
1200
|
-
r(
|
|
1200
|
+
r(R, {
|
|
1201
1201
|
"model-value": e(A.Dinero).fromFdoDinero(e(t).price).toUnit(),
|
|
1202
1202
|
label: e(s)("connect.store.bundle.edit.bundlePrice"),
|
|
1203
1203
|
min: 0,
|
|
@@ -1207,17 +1207,17 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1207
1207
|
}),
|
|
1208
1208
|
"is-currency": !0,
|
|
1209
1209
|
"show-steppers": !1,
|
|
1210
|
-
"helper-text": e(X)(e(
|
|
1210
|
+
"helper-text": e(X)(e(u), "price") || `${e(A.Dinero).fromNumber({ number: 1 }).toFormat(
|
|
1211
1211
|
!0
|
|
1212
1212
|
)} = ${e(A.Dinero).fromNumber({ number: 1 }).toUnit()} credit`,
|
|
1213
|
-
"helper-state": e(G)(e(
|
|
1213
|
+
"helper-state": e(G)(e(u), "price")
|
|
1214
1214
|
}, {
|
|
1215
1215
|
prepend: B(() => [
|
|
1216
1216
|
me(K(e(A.Dinero).defaultCurrency()), 1)
|
|
1217
1217
|
]),
|
|
1218
1218
|
_: 1
|
|
1219
1219
|
}, 8, ["model-value", "label", "helper-text", "helper-state"]),
|
|
1220
|
-
r(
|
|
1220
|
+
r(R, {
|
|
1221
1221
|
"model-value": e(A.Dinero).fromFdoDinero(e(t).originalPrice).toUnit(),
|
|
1222
1222
|
label: e(s)("connect.store.bundle.edit.bundleValue"),
|
|
1223
1223
|
min: 0,
|
|
@@ -1227,15 +1227,15 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1227
1227
|
}),
|
|
1228
1228
|
"is-currency": !0,
|
|
1229
1229
|
"show-steppers": !1,
|
|
1230
|
-
"helper-text": e(X)(e(
|
|
1231
|
-
"helper-state": e(G)(e(
|
|
1230
|
+
"helper-text": e(X)(e(u), "originalPrice") || e(s)("connect.store.bundle.edit.originalPriceHelper"),
|
|
1231
|
+
"helper-state": e(G)(e(u), "originalPrice")
|
|
1232
1232
|
}, {
|
|
1233
1233
|
prepend: B(() => [
|
|
1234
1234
|
me(K(e(A.Dinero).defaultCurrency()), 1)
|
|
1235
1235
|
]),
|
|
1236
1236
|
_: 1
|
|
1237
1237
|
}, 8, ["model-value", "label", "helper-text", "helper-state"]),
|
|
1238
|
-
e(t).isFeedvibe ? E("", !0) : (
|
|
1238
|
+
e(t).isFeedvibe ? E("", !0) : (x(), O(R, {
|
|
1239
1239
|
key: 0,
|
|
1240
1240
|
"model-value": e(t).coinPrice ?? null,
|
|
1241
1241
|
label: e(s)("connect.store.bundle.edit.pointNeeded"),
|
|
@@ -1244,50 +1244,50 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1244
1244
|
P > 0 && e(t).credit.normal > 0 && (e(t).credit.normal = 0), e(t).coinPrice = P;
|
|
1245
1245
|
}),
|
|
1246
1246
|
"show-steppers": !1,
|
|
1247
|
-
"helper-state": e(G)(e(
|
|
1248
|
-
"helper-text": e(X)(e(
|
|
1247
|
+
"helper-state": e(G)(e(u), "coinPrice"),
|
|
1248
|
+
"helper-text": e(X)(e(u), "coinPrice")
|
|
1249
1249
|
}, {
|
|
1250
1250
|
append: B(() => [...n[22] || (n[22] = [
|
|
1251
1251
|
me(" point(s) ", -1)
|
|
1252
1252
|
])]),
|
|
1253
1253
|
_: 1
|
|
1254
1254
|
}, 8, ["model-value", "label", "helper-state", "helper-text"])),
|
|
1255
|
-
(Ue = e(v).storeOption) != null && Ue.stripe && !e(t).isFeedvibe ? (
|
|
1256
|
-
V("div",
|
|
1257
|
-
r(
|
|
1255
|
+
(Ue = e(v).storeOption) != null && Ue.stripe && !e(t).isFeedvibe ? (x(), D(Y, { key: 1 }, [
|
|
1256
|
+
V("div", on, K(e(s)("connect.store.bundle.edit.subscriptionSettings")), 1),
|
|
1257
|
+
r(I, {
|
|
1258
1258
|
label: e(s)("connect.store.bundle.edit.stripePriceId"),
|
|
1259
1259
|
modelValue: e(t).stripePriceId,
|
|
1260
1260
|
"onUpdate:modelValue": n[7] || (n[7] = (P) => e(t).stripePriceId = P),
|
|
1261
|
-
"helper-state": e(G)(e(
|
|
1262
|
-
"helper-text": e(X)(e(
|
|
1261
|
+
"helper-state": e(G)(e(u), "stripePriceId"),
|
|
1262
|
+
"helper-text": e(X)(e(u), "stripePriceId")
|
|
1263
1263
|
}, null, 8, ["label", "modelValue", "helper-state", "helper-text"]),
|
|
1264
|
-
e(t).stripePriceId ? (
|
|
1264
|
+
e(t).stripePriceId ? (x(), O(R, {
|
|
1265
1265
|
key: 0,
|
|
1266
1266
|
"model-value": e(t).subscriptionValidity ?? null,
|
|
1267
1267
|
min: 1,
|
|
1268
1268
|
"onUpdate:modelValue": ne,
|
|
1269
1269
|
label: e(s)("connect.store.bundle.edit.subscriptionValidity"),
|
|
1270
1270
|
"show-steppers": !1,
|
|
1271
|
-
"helper-state": e(G)(e(
|
|
1272
|
-
"helper-text": e(X)(e(
|
|
1271
|
+
"helper-state": e(G)(e(u), "subscriptionValidity"),
|
|
1272
|
+
"helper-text": e(X)(e(u), "subscriptionValidity")
|
|
1273
1273
|
}, null, 8, ["model-value", "label", "helper-state", "helper-text"])) : E("", !0)
|
|
1274
1274
|
], 64)) : E("", !0),
|
|
1275
|
-
e(t).isFeedvibe ? E("", !0) : (
|
|
1276
|
-
V("div",
|
|
1277
|
-
r(
|
|
1275
|
+
e(t).isFeedvibe ? E("", !0) : (x(), D(Y, { key: 2 }, [
|
|
1276
|
+
V("div", an, K(e(s)("connect.store.bundle.edit.credit")), 1),
|
|
1277
|
+
r(R, {
|
|
1278
1278
|
modelValue: e(t).credit.normal,
|
|
1279
1279
|
"onUpdate:modelValue": n[8] || (n[8] = (P) => e(t).credit.normal = P),
|
|
1280
1280
|
label: e(s)("connect.store.bundle.edit.normalCredit"),
|
|
1281
1281
|
"show-steppers": !1,
|
|
1282
|
-
"helper-state": e(G)(e(
|
|
1283
|
-
"helper-text": e(X)(e(
|
|
1282
|
+
"helper-state": e(G)(e(u), "credit.normal"),
|
|
1283
|
+
"helper-text": e(X)(e(u), "credit.normal")
|
|
1284
1284
|
}, {
|
|
1285
1285
|
append: B(() => [...n[23] || (n[23] = [
|
|
1286
1286
|
me(" credit ", -1)
|
|
1287
1287
|
])]),
|
|
1288
1288
|
_: 1
|
|
1289
1289
|
}, 8, ["modelValue", "label", "helper-state", "helper-text"]),
|
|
1290
|
-
r(
|
|
1290
|
+
r(R, {
|
|
1291
1291
|
"model-value": ((Re = e(t).credit.free) == null ? void 0 : Re.amount) ?? null,
|
|
1292
1292
|
min: 0,
|
|
1293
1293
|
"onUpdate:modelValue": n[9] || (n[9] = (P) => {
|
|
@@ -1298,15 +1298,15 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1298
1298
|
}),
|
|
1299
1299
|
label: e(s)("connect.store.bundle.edit.freeCredit"),
|
|
1300
1300
|
"show-steppers": !1,
|
|
1301
|
-
"helper-state": e(G)(e(
|
|
1302
|
-
"helper-text": e(X)(e(
|
|
1301
|
+
"helper-state": e(G)(e(u), "credit.free.amount"),
|
|
1302
|
+
"helper-text": e(X)(e(u), "credit.free.amount")
|
|
1303
1303
|
}, {
|
|
1304
1304
|
append: B(() => [...n[24] || (n[24] = [
|
|
1305
1305
|
me(" credit ", -1)
|
|
1306
1306
|
])]),
|
|
1307
1307
|
_: 1
|
|
1308
1308
|
}, 8, ["model-value", "label", "helper-state", "helper-text"]),
|
|
1309
|
-
(Ie = e(t).credit.free) != null && Ie.amount ? (
|
|
1309
|
+
(Ie = e(t).credit.free) != null && Ie.amount ? (x(), O(R, {
|
|
1310
1310
|
key: 0,
|
|
1311
1311
|
disabled: !!e(t).stripePriceId,
|
|
1312
1312
|
"model-value": ((Be = e(t).credit.free) == null ? void 0 : Be.day) ?? null,
|
|
@@ -1319,8 +1319,8 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1319
1319
|
}),
|
|
1320
1320
|
label: "Free credit valid for",
|
|
1321
1321
|
"show-steppers": !1,
|
|
1322
|
-
"helper-state": e(G)(e(
|
|
1323
|
-
"helper-text": e(X)(e(
|
|
1322
|
+
"helper-state": e(G)(e(u), "credit.free.day"),
|
|
1323
|
+
"helper-text": e(X)(e(u), "credit.free.day")
|
|
1324
1324
|
}, {
|
|
1325
1325
|
append: B(() => [...n[25] || (n[25] = [
|
|
1326
1326
|
me(" day(s) ", -1)
|
|
@@ -1328,28 +1328,28 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1328
1328
|
_: 1
|
|
1329
1329
|
}, 8, ["disabled", "model-value", "helper-state", "helper-text"])) : E("", !0)
|
|
1330
1330
|
], 64)),
|
|
1331
|
-
e(z) ? (
|
|
1331
|
+
e(z) ? (x(), D(Y, { key: 3 }, [
|
|
1332
1332
|
n[26] || (n[26] = V("div", { class: "fm-typo-en-title-sm-800 !mb-[-16px]" }, "Taxes", -1)),
|
|
1333
|
-
r(
|
|
1333
|
+
r(Qt, {
|
|
1334
1334
|
modelValue: e(t).taxes,
|
|
1335
1335
|
"onUpdate:modelValue": n[11] || (n[11] = (P) => e(t).taxes = P)
|
|
1336
1336
|
}, null, 8, ["modelValue"]),
|
|
1337
|
-
r(
|
|
1337
|
+
r(I, {
|
|
1338
1338
|
label: `Tax Charged (${e(oe)})`,
|
|
1339
1339
|
"model-value": e(ie),
|
|
1340
1340
|
disabled: ""
|
|
1341
1341
|
}, null, 8, ["label", "model-value"])
|
|
1342
1342
|
], 64)) : E("", !0),
|
|
1343
|
-
r(
|
|
1343
|
+
r(R, {
|
|
1344
1344
|
label: "Total Price",
|
|
1345
|
-
"model-value": e(
|
|
1345
|
+
"model-value": e(g),
|
|
1346
1346
|
disabled: !0
|
|
1347
1347
|
}, null, 8, ["model-value"]),
|
|
1348
|
-
V("div",
|
|
1349
|
-
V("div",
|
|
1350
|
-
V("div",
|
|
1351
|
-
V("div",
|
|
1352
|
-
r(
|
|
1348
|
+
V("div", ln, K(e(s)("connect.store.bundle.edit.bundleReward.title")), 1),
|
|
1349
|
+
V("div", sn, K(e(s)("connect.store.bundle.edit.bundleReward.description")), 1),
|
|
1350
|
+
V("div", rn, [
|
|
1351
|
+
V("div", dn, [
|
|
1352
|
+
r(ut, {
|
|
1353
1353
|
label: `Reward type: ${e(l).length == 0 ? "All" : e(l)[0].name}`
|
|
1354
1354
|
}, {
|
|
1355
1355
|
default: B(() => [
|
|
@@ -1362,20 +1362,20 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1362
1362
|
{
|
|
1363
1363
|
id: "type",
|
|
1364
1364
|
value: "VOUCHER",
|
|
1365
|
-
name: e(
|
|
1365
|
+
name: e(ye).VOUCHER.name
|
|
1366
1366
|
}
|
|
1367
1367
|
]),
|
|
1368
|
-
label: e(
|
|
1368
|
+
label: e(ye).VOUCHER.name
|
|
1369
1369
|
}, null, 8, ["label"]),
|
|
1370
1370
|
r(q, {
|
|
1371
1371
|
onClick: n[14] || (n[14] = (P) => l.value = [
|
|
1372
1372
|
{
|
|
1373
1373
|
id: "type",
|
|
1374
1374
|
value: "TITLE",
|
|
1375
|
-
name: e(
|
|
1375
|
+
name: e(ye).TITLE.name
|
|
1376
1376
|
}
|
|
1377
1377
|
]),
|
|
1378
|
-
label: e(
|
|
1378
|
+
label: e(ye).TITLE.name
|
|
1379
1379
|
}, null, 8, ["label"])
|
|
1380
1380
|
]),
|
|
1381
1381
|
_: 1
|
|
@@ -1390,14 +1390,14 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1390
1390
|
"row-data": e(w),
|
|
1391
1391
|
"hide-footer": e(w).length <= 10
|
|
1392
1392
|
}, null, 8, ["modelValue", "column-filter", "row-data", "hide-footer"]),
|
|
1393
|
-
r(
|
|
1394
|
-
text: e(X)(e(
|
|
1395
|
-
state: e(G)(e(
|
|
1393
|
+
r(f, {
|
|
1394
|
+
text: e(X)(e(u), "titles"),
|
|
1395
|
+
state: e(G)(e(u), "titles")
|
|
1396
1396
|
}, null, 8, ["text", "state"])
|
|
1397
1397
|
]),
|
|
1398
|
-
V("div",
|
|
1399
|
-
V("div",
|
|
1400
|
-
e(t).isFeedvibe ? E("", !0) : (
|
|
1398
|
+
V("div", un, K(e(s)("connect.store.bundle.edit.advanceSetting")), 1),
|
|
1399
|
+
V("div", cn, [
|
|
1400
|
+
e(t).isFeedvibe ? E("", !0) : (x(), D(Y, { key: 0 }, [
|
|
1401
1401
|
r(p, {
|
|
1402
1402
|
"model-value": e(t).internal ?? !1,
|
|
1403
1403
|
"onUpdate:modelValue": n[16] || (n[16] = (P) => e(t).internal = P),
|
|
@@ -1413,15 +1413,15 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1413
1413
|
sublabel: e(s)("connect.store.bundle.edit.hideInPosDescription")
|
|
1414
1414
|
}, null, 8, ["model-value", "label", "sublabel"])
|
|
1415
1415
|
], 64)),
|
|
1416
|
-
r(
|
|
1416
|
+
r(R, {
|
|
1417
1417
|
"model-value": ((De = (Ne = e(t).config) == null ? void 0 : Ne.options) == null ? void 0 : De.maxPerUser) || null,
|
|
1418
1418
|
"onUpdate:modelValue": n[18] || (n[18] = (P) => e(ae).set(e(t), "config.options.maxPerUser", P)),
|
|
1419
1419
|
label: e(s)("connect.store.bundle.edit.maxPerUser"),
|
|
1420
1420
|
"show-steppers": !1,
|
|
1421
1421
|
placeholder: e(s)("connect.store.bundle.edit.unlimited")
|
|
1422
1422
|
}, null, 8, ["model-value", "label", "placeholder"]),
|
|
1423
|
-
r(
|
|
1424
|
-
"model-value": ((
|
|
1423
|
+
r(R, {
|
|
1424
|
+
"model-value": ((Me = (Oe = e(t).config) == null ? void 0 : Oe.options) == null ? void 0 : Me.maxReceive) || null,
|
|
1425
1425
|
"onUpdate:modelValue": n[19] || (n[19] = (P) => e(ae).set(e(t), "config.options.maxReceive", P)),
|
|
1426
1426
|
label: e(s)("connect.store.bundle.edit.maxReceive"),
|
|
1427
1427
|
"show-steppers": !1,
|
|
@@ -1435,51 +1435,51 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1435
1435
|
}, 8, ["modelValue", "header"]);
|
|
1436
1436
|
};
|
|
1437
1437
|
}
|
|
1438
|
-
}),
|
|
1438
|
+
}), fn = { class: "flex gap-8 items-center flex-wrap" }, yn = { class: "flex items-center gap-8" }, bn = /* @__PURE__ */ te({
|
|
1439
1439
|
__name: "SendBundleSheet",
|
|
1440
1440
|
emits: ["success"],
|
|
1441
|
-
setup(
|
|
1442
|
-
const { minor:
|
|
1441
|
+
setup(C, { expose: S, emit: o }) {
|
|
1442
|
+
const { minor: b } = Ke, s = N(), v = N(""), a = N(""), m = N([]), i = N(!1), t = N();
|
|
1443
1443
|
N(!0);
|
|
1444
|
-
function
|
|
1445
|
-
i.value = !0, v.value = null,
|
|
1444
|
+
function c(w) {
|
|
1445
|
+
i.value = !0, v.value = null, a.value = "", s.value = w.bundle;
|
|
1446
1446
|
}
|
|
1447
|
-
function
|
|
1447
|
+
function y() {
|
|
1448
1448
|
i.value = !1;
|
|
1449
1449
|
}
|
|
1450
|
-
async function
|
|
1451
|
-
const
|
|
1450
|
+
async function u(w) {
|
|
1451
|
+
const U = await bt.read({
|
|
1452
1452
|
limit: 25,
|
|
1453
1453
|
skip: 0,
|
|
1454
1454
|
sortBy: "_id",
|
|
1455
1455
|
search: w,
|
|
1456
1456
|
descending: !1
|
|
1457
1457
|
});
|
|
1458
|
-
|
|
1458
|
+
m.value = U.resources.map((j) => ({
|
|
1459
1459
|
label: `${j.name} (${j.phoneNumber})`,
|
|
1460
1460
|
value: j._id
|
|
1461
1461
|
})), await new Promise((j) => setTimeout(j, 100));
|
|
1462
1462
|
}
|
|
1463
1463
|
async function T() {
|
|
1464
1464
|
if (!s.value || !v.value) return;
|
|
1465
|
-
const w =
|
|
1465
|
+
const w = m.value.find(
|
|
1466
1466
|
(j) => j.value === v.value
|
|
1467
1467
|
);
|
|
1468
|
-
await
|
|
1468
|
+
await pe.confirm(
|
|
1469
1469
|
`Are you sure you want to send bundle ${s.value.name} to ${w == null ? void 0 : w.label}?`,
|
|
1470
1470
|
"Confirm",
|
|
1471
1471
|
"Confirm",
|
|
1472
1472
|
"Cancel"
|
|
1473
|
-
) && await
|
|
1473
|
+
) && await b(
|
|
1474
1474
|
async () => {
|
|
1475
1475
|
const j = {
|
|
1476
1476
|
bundle: s.value._id,
|
|
1477
1477
|
member: v.value,
|
|
1478
|
-
source:
|
|
1479
|
-
ref: `ADMIN:${(/* @__PURE__ */ new Date()).toISOString()}:${
|
|
1478
|
+
source: ot.enum.ADMIN,
|
|
1479
|
+
ref: `ADMIN:${(/* @__PURE__ */ new Date()).toISOString()}:${a.value}`,
|
|
1480
1480
|
withCoin: !1
|
|
1481
1481
|
};
|
|
1482
|
-
await
|
|
1482
|
+
await ge.sendBundle(j), y();
|
|
1483
1483
|
},
|
|
1484
1484
|
{
|
|
1485
1485
|
message: "Sending bundle",
|
|
@@ -1488,44 +1488,44 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1488
1488
|
);
|
|
1489
1489
|
}
|
|
1490
1490
|
const l = L(() => {
|
|
1491
|
-
var
|
|
1491
|
+
var U, j, ne;
|
|
1492
1492
|
const w = [];
|
|
1493
|
-
return ((
|
|
1494
|
-
`${A.Config.getCountry().currency.symbol}${
|
|
1493
|
+
return ((U = s.value) == null ? void 0 : U.price.amount) > 0 && w.push(
|
|
1494
|
+
`${A.Config.getCountry().currency.symbol}${He((j = s.value) == null ? void 0 : j.price)}`
|
|
1495
1495
|
), (ne = s.value) != null && ne.coinPrice && w.push(`${s.value.coinPrice} point(s)`), w.join(" or ");
|
|
1496
1496
|
});
|
|
1497
1497
|
return S({
|
|
1498
|
-
showSheet:
|
|
1499
|
-
hideSheet:
|
|
1498
|
+
showSheet: c,
|
|
1499
|
+
hideSheet: y
|
|
1500
1500
|
}), he(async () => {
|
|
1501
|
-
await
|
|
1502
|
-
}), (w,
|
|
1503
|
-
const j = _("FmCardMedia"), ne = _("FmCardHeader"), Z = _("FmChip"), H = _("FmCardSection"), z = _("FmCard"), oe = _("FmSelect"), F = _("FmTextField"), ie = _("FmForm"),
|
|
1504
|
-
return
|
|
1501
|
+
await u("");
|
|
1502
|
+
}), (w, U) => {
|
|
1503
|
+
const j = _("FmCardMedia"), ne = _("FmCardHeader"), Z = _("FmChip"), H = _("FmCardSection"), z = _("FmCard"), oe = _("FmSelect"), F = _("FmTextField"), ie = _("FmForm"), g = _("FmButton"), k = _("FmSideSheet");
|
|
1504
|
+
return x(), O(k, {
|
|
1505
1505
|
"max-width": 560,
|
|
1506
1506
|
"dismiss-away": !0,
|
|
1507
1507
|
header: "Send bundle to member",
|
|
1508
1508
|
modelValue: e(i),
|
|
1509
1509
|
"onUpdate:modelValue": [
|
|
1510
|
-
|
|
1511
|
-
|
|
1510
|
+
U[4] || (U[4] = (h) => re(i) ? i.value = h : null),
|
|
1511
|
+
U[5] || (U[5] = (h) => i.value = h)
|
|
1512
1512
|
]
|
|
1513
1513
|
}, {
|
|
1514
1514
|
"side-sheet-footer": B(() => [
|
|
1515
|
-
V("div",
|
|
1516
|
-
r(
|
|
1515
|
+
V("div", yn, [
|
|
1516
|
+
r(g, {
|
|
1517
1517
|
label: "Send",
|
|
1518
|
-
loading: e(
|
|
1519
|
-
onClick:
|
|
1520
|
-
var
|
|
1521
|
-
return (
|
|
1518
|
+
loading: e(_e)().isLoading,
|
|
1519
|
+
onClick: U[2] || (U[2] = async () => {
|
|
1520
|
+
var h;
|
|
1521
|
+
return (h = e(t)) == null ? void 0 : h.validateInputs();
|
|
1522
1522
|
})
|
|
1523
1523
|
}, null, 8, ["loading"]),
|
|
1524
|
-
r(
|
|
1524
|
+
r(g, {
|
|
1525
1525
|
label: "Cancel",
|
|
1526
1526
|
type: "button",
|
|
1527
1527
|
variant: "tertiary",
|
|
1528
|
-
onClick:
|
|
1528
|
+
onClick: U[3] || (U[3] = (h) => i.value = !1)
|
|
1529
1529
|
})
|
|
1530
1530
|
])
|
|
1531
1531
|
]),
|
|
@@ -1544,40 +1544,40 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1544
1544
|
variant: "outlined"
|
|
1545
1545
|
}, {
|
|
1546
1546
|
default: B(() => {
|
|
1547
|
-
var
|
|
1547
|
+
var h, $;
|
|
1548
1548
|
return [
|
|
1549
|
-
(
|
|
1549
|
+
(h = e(s)) != null && h.image ? (x(), O(j, {
|
|
1550
1550
|
key: 0,
|
|
1551
1551
|
width: "100",
|
|
1552
|
-
src: (
|
|
1552
|
+
src: ($ = e(s)) == null ? void 0 : $.image
|
|
1553
1553
|
}, null, 8, ["src"])) : E("", !0),
|
|
1554
1554
|
r(H, { class: "flex flex-col gap-16 justify-between" }, {
|
|
1555
1555
|
default: B(() => {
|
|
1556
|
-
var
|
|
1556
|
+
var d;
|
|
1557
1557
|
return [
|
|
1558
1558
|
r(ne, {
|
|
1559
1559
|
class: "p-0",
|
|
1560
|
-
title: (
|
|
1560
|
+
title: (d = e(s)) == null ? void 0 : d.name,
|
|
1561
1561
|
subtitle: e(l)
|
|
1562
1562
|
}, null, 8, ["title", "subtitle"]),
|
|
1563
1563
|
r(H, { class: "p-0" }, {
|
|
1564
1564
|
default: B(() => {
|
|
1565
|
-
var n, p,
|
|
1565
|
+
var n, p, f, I, M, R, q, J, fe, Ce, de;
|
|
1566
1566
|
return [
|
|
1567
|
-
V("div",
|
|
1568
|
-
(n = e(s)) != null && n.isFeedvibe ? (
|
|
1567
|
+
V("div", fn, [
|
|
1568
|
+
(n = e(s)) != null && n.isFeedvibe ? (x(), O(Z, {
|
|
1569
1569
|
key: 0,
|
|
1570
1570
|
label: "Feedvibe"
|
|
1571
1571
|
})) : E("", !0),
|
|
1572
|
-
(
|
|
1572
|
+
(f = (p = e(s)) == null ? void 0 : p.titles) != null && f.length ? (x(), O(Z, {
|
|
1573
1573
|
key: 1,
|
|
1574
1574
|
label: `${e(s).titles.length} title(s)`
|
|
1575
1575
|
}, null, 8, ["label"])) : E("", !0),
|
|
1576
|
-
(
|
|
1576
|
+
(M = (I = e(s)) == null ? void 0 : I.vouchers) != null && M.length ? (x(), O(Z, {
|
|
1577
1577
|
key: 2,
|
|
1578
1578
|
label: `${e(s).vouchers.length} voucher(s)`
|
|
1579
1579
|
}, null, 8, ["label"])) : E("", !0),
|
|
1580
|
-
(q = (
|
|
1580
|
+
(q = (R = e(s)) == null ? void 0 : R.credit) != null && q.normal || (Ce = (fe = (J = e(s)) == null ? void 0 : J.credit) == null ? void 0 : fe.free) != null && Ce.amount ? (x(), O(Z, {
|
|
1581
1581
|
key: 3,
|
|
1582
1582
|
label: `${(e(s).credit.normal || 0) + (((de = e(s).credit.free) == null ? void 0 : de.amount) || 0)} credit(s)`
|
|
1583
1583
|
}, null, 8, ["label"])) : E("", !0)
|
|
@@ -1596,20 +1596,20 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1596
1596
|
}),
|
|
1597
1597
|
r(oe, {
|
|
1598
1598
|
modelValue: e(v),
|
|
1599
|
-
"onUpdate:modelValue":
|
|
1599
|
+
"onUpdate:modelValue": U[0] || (U[0] = (h) => re(v) ? v.value = h : null),
|
|
1600
1600
|
label: "Select member",
|
|
1601
1601
|
searchable: "",
|
|
1602
|
-
items: e(
|
|
1603
|
-
onSearch:
|
|
1604
|
-
rules: [(
|
|
1602
|
+
items: e(m),
|
|
1603
|
+
onSearch: u,
|
|
1604
|
+
rules: [(h) => !!h > 0 || "Member is required"],
|
|
1605
1605
|
"helper-text": "Type to search member"
|
|
1606
1606
|
}, null, 8, ["modelValue", "items", "rules"]),
|
|
1607
1607
|
r(F, {
|
|
1608
|
-
modelValue: e(
|
|
1609
|
-
"onUpdate:modelValue":
|
|
1608
|
+
modelValue: e(a),
|
|
1609
|
+
"onUpdate:modelValue": U[1] || (U[1] = (h) => re(a) ? a.value = h : null),
|
|
1610
1610
|
label: "Reference (optional)",
|
|
1611
1611
|
rules: [
|
|
1612
|
-
(
|
|
1612
|
+
(h) => h.length < 50 || "Reference must be less than 50 characters"
|
|
1613
1613
|
]
|
|
1614
1614
|
}, null, 8, ["modelValue", "rules"])
|
|
1615
1615
|
]),
|
|
@@ -1621,231 +1621,258 @@ const Zt = /* @__PURE__ */ te({
|
|
|
1621
1621
|
};
|
|
1622
1622
|
}
|
|
1623
1623
|
});
|
|
1624
|
-
|
|
1625
|
-
|
|
1624
|
+
async function Ee({
|
|
1625
|
+
hasStoreCompany: C,
|
|
1626
|
+
confirm: S,
|
|
1627
|
+
showSettingSheet: o
|
|
1628
|
+
}) {
|
|
1629
|
+
return C ? !0 : (await S() && o(!0), !1);
|
|
1630
|
+
}
|
|
1631
|
+
var gn = { 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/" };
|
|
1632
|
+
const vn = { class: "px-24 flex flex-col gap-y-16" }, hn = { class: "flex gap-8 items-center" }, xn = { class: "fm-typo-en-body-lg-600" }, Cn = { class: "grid sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-24" }, Sn = { class: "flex flex-col gap-16 text-center" }, _n = { class: "fm-typo-en-title-sm-800" }, Fn = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Qn = /* @__PURE__ */ te({
|
|
1626
1633
|
__name: "Store",
|
|
1627
|
-
setup(
|
|
1634
|
+
setup(C) {
|
|
1628
1635
|
const S = {
|
|
1629
1636
|
label: "Setup payout account",
|
|
1630
1637
|
value: "payout",
|
|
1631
1638
|
isPrimary: !1
|
|
1632
|
-
}, { t:
|
|
1633
|
-
label:
|
|
1639
|
+
}, { t: o } = xe(), b = {
|
|
1640
|
+
label: o("connect.store.actions.setting"),
|
|
1634
1641
|
value: "setting",
|
|
1635
1642
|
isPrimary: !1
|
|
1636
1643
|
}, s = {
|
|
1637
|
-
label:
|
|
1644
|
+
label: o("connect.store.actions.manageReward"),
|
|
1638
1645
|
value: "create_reward"
|
|
1639
1646
|
}, v = {
|
|
1640
|
-
label:
|
|
1647
|
+
label: o("connect.store.actions.addCategory"),
|
|
1641
1648
|
value: "create_category",
|
|
1642
1649
|
isPrimary: !0,
|
|
1643
1650
|
prependIcon: "add"
|
|
1644
|
-
},
|
|
1645
|
-
async function
|
|
1651
|
+
}, a = N(), m = gt(), i = Te(), { global: t, minor: c } = Ke, y = je(), u = L(() => i.sortedStoreCategories), T = L(() => i.sortedStoreCategories.map((g) => g.name)), l = N(), w = N();
|
|
1652
|
+
async function U(g) {
|
|
1646
1653
|
var k;
|
|
1647
|
-
|
|
1654
|
+
g === "setting" ? (k = l.value) == null || k.showSheet(!0, i.storeOption) : g === "create_category" ? H(-1) : g === "create_reward" ? await m.push({ name: lt["$connect-STORE_REWARDS"] }) : g == "payout" && window.open(gn.paymentPortalUrl, "_blank");
|
|
1648
1655
|
}
|
|
1649
|
-
function j(
|
|
1656
|
+
function j(g, k) {
|
|
1650
1657
|
var p;
|
|
1651
|
-
const
|
|
1652
|
-
console.log(
|
|
1653
|
-
const
|
|
1654
|
-
return
|
|
1658
|
+
const h = !!((p = k.company) != null && p.sstRegNo), $ = k.inclusiveTaxes ?? [], d = W.taxSystem.map((f) => f.code), n = h ? $.flatMap((f) => {
|
|
1659
|
+
console.log(f, "inclusive tax");
|
|
1660
|
+
const I = W.systemDefaultCode(f.systemCode);
|
|
1661
|
+
return I ? [{ systemCode: f.systemCode, taxCode: I.taxCode }] : [];
|
|
1655
1662
|
}) : [];
|
|
1656
1663
|
return console.log([
|
|
1657
|
-
["hasSstRegNo",
|
|
1664
|
+
["hasSstRegNo", h],
|
|
1658
1665
|
["defaultTaxCodes", n],
|
|
1659
|
-
["inclusiveTaxes",
|
|
1660
|
-
["taxSystemCodes",
|
|
1661
|
-
]),
|
|
1662
|
-
...
|
|
1663
|
-
bundles:
|
|
1664
|
-
const { pf_vouchers:
|
|
1665
|
-
if (!
|
|
1666
|
+
["inclusiveTaxes", $],
|
|
1667
|
+
["taxSystemCodes", d]
|
|
1668
|
+
]), g.map((f) => ({
|
|
1669
|
+
...f,
|
|
1670
|
+
bundles: f.bundles.map((I) => {
|
|
1671
|
+
const { pf_vouchers: M, ...R } = I;
|
|
1672
|
+
if (!h)
|
|
1666
1673
|
return {
|
|
1667
|
-
...
|
|
1674
|
+
...R,
|
|
1668
1675
|
taxes: [],
|
|
1669
1676
|
taxTotals: [],
|
|
1670
|
-
priceWithTaxes: { ...
|
|
1677
|
+
priceWithTaxes: { ...R.price }
|
|
1671
1678
|
};
|
|
1672
|
-
const q = n, J =
|
|
1679
|
+
const q = n, J = qe(
|
|
1673
1680
|
W.fullTax,
|
|
1674
1681
|
q,
|
|
1675
|
-
|
|
1676
|
-
Number(
|
|
1677
|
-
|
|
1678
|
-
|
|
1682
|
+
R.price,
|
|
1683
|
+
Number(R.credit.normal),
|
|
1684
|
+
$,
|
|
1685
|
+
d
|
|
1679
1686
|
);
|
|
1680
1687
|
return {
|
|
1681
|
-
...
|
|
1688
|
+
...R,
|
|
1682
1689
|
taxes: q,
|
|
1683
1690
|
taxTotals: J,
|
|
1684
|
-
priceWithTaxes:
|
|
1691
|
+
priceWithTaxes: We(
|
|
1685
1692
|
J,
|
|
1686
|
-
|
|
1687
|
-
|
|
1693
|
+
R.price,
|
|
1694
|
+
$
|
|
1688
1695
|
)
|
|
1689
1696
|
};
|
|
1690
1697
|
})
|
|
1691
1698
|
}));
|
|
1692
1699
|
}
|
|
1693
|
-
async function ne(
|
|
1694
|
-
const
|
|
1700
|
+
async function ne(g, k, h) {
|
|
1701
|
+
const $ = !h && !!k, d = !!h && !k;
|
|
1695
1702
|
let n;
|
|
1696
|
-
if (
|
|
1697
|
-
const
|
|
1698
|
-
n =
|
|
1699
|
-
taxCode:
|
|
1703
|
+
if ($) {
|
|
1704
|
+
const f = W.taxSystem[0] ? W.systemDefaultCode(W.taxSystem[0].code) : void 0, I = f ? `${f.name} (${f.taxCode})` : o("connect.store.taxPropagation.defaultTax");
|
|
1705
|
+
n = o("connect.store.taxPropagation.addConfirm", {
|
|
1706
|
+
taxCode: I
|
|
1700
1707
|
});
|
|
1701
|
-
} else
|
|
1702
|
-
await
|
|
1708
|
+
} else d ? n = o("connect.store.taxPropagation.removeConfirm") : n = o("connect.store.taxPropagation.updateConfirm");
|
|
1709
|
+
await pe.confirm(
|
|
1703
1710
|
n,
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
) && await
|
|
1711
|
+
o("connect.store.taxPropagation.title"),
|
|
1712
|
+
o("connect.store.taxPropagation.confirm"),
|
|
1713
|
+
o("connect.common.cancel")
|
|
1714
|
+
) && await c(
|
|
1708
1715
|
async () => {
|
|
1709
|
-
const
|
|
1710
|
-
await
|
|
1716
|
+
const f = Fe(i.sortedStoreCategories), I = j(f, g);
|
|
1717
|
+
await ge.updateStoreBundle({ categories: I }), await i.readMemberStore(), await i.readMembership(), await i.readRewards();
|
|
1711
1718
|
},
|
|
1712
1719
|
{
|
|
1713
|
-
message:
|
|
1714
|
-
successMessage:
|
|
1720
|
+
message: o("connect.store.taxPropagation.updating"),
|
|
1721
|
+
successMessage: o("connect.store.taxPropagation.success")
|
|
1715
1722
|
}
|
|
1716
1723
|
);
|
|
1717
1724
|
}
|
|
1718
|
-
async function Z(
|
|
1719
|
-
var
|
|
1720
|
-
const k = ((
|
|
1721
|
-
((
|
|
1722
|
-
),
|
|
1723
|
-
await
|
|
1725
|
+
async function Z(g) {
|
|
1726
|
+
var I, M, R, q;
|
|
1727
|
+
const k = ((M = (I = i.storeOption) == null ? void 0 : I.company) == null ? void 0 : M.sstRegNo) ?? "", h = ae.cloneDeep(
|
|
1728
|
+
((R = i.storeOption) == null ? void 0 : R.inclusiveTaxes) ?? []
|
|
1729
|
+
), $ = ((q = g.company) == null ? void 0 : q.sstRegNo) ?? "";
|
|
1730
|
+
await c(
|
|
1724
1731
|
async () => {
|
|
1725
1732
|
var J;
|
|
1726
|
-
await
|
|
1733
|
+
await ge.updateStore(g), await i.readMemberStore(), (J = l.value) == null || J.showSheet(!1);
|
|
1727
1734
|
},
|
|
1728
1735
|
{
|
|
1729
|
-
message:
|
|
1730
|
-
successMessage:
|
|
1736
|
+
message: o("connect.store.setting.update.message"),
|
|
1737
|
+
successMessage: o("connect.store.setting.update.success")
|
|
1731
1738
|
}
|
|
1732
1739
|
);
|
|
1733
|
-
const
|
|
1734
|
-
|
|
1735
|
-
|
|
1740
|
+
const d = k !== $, n = !ae.isEqual(
|
|
1741
|
+
h,
|
|
1742
|
+
g.inclusiveTaxes ?? []
|
|
1736
1743
|
);
|
|
1737
|
-
!(
|
|
1744
|
+
!(d || n) || i.sortedStoreCategories.flatMap(
|
|
1738
1745
|
(J) => J.bundles
|
|
1739
|
-
).length === 0 || await ne(
|
|
1746
|
+
).length === 0 || await ne(g, $, k);
|
|
1740
1747
|
}
|
|
1741
|
-
async function H(
|
|
1742
|
-
var
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1748
|
+
async function H(g = -1) {
|
|
1749
|
+
var h, $;
|
|
1750
|
+
await Ee({
|
|
1751
|
+
hasStoreCompany: !!((h = i.storeOption) != null && h.company),
|
|
1752
|
+
confirm: () => pe.confirm(
|
|
1753
|
+
o("connect.store.category.setup.title"),
|
|
1754
|
+
o("connect.store.category.setup.button"),
|
|
1755
|
+
o("connect.store.category.setup.action"),
|
|
1756
|
+
o("connect.common.cancel")
|
|
1757
|
+
),
|
|
1758
|
+
showSettingSheet: (d) => {
|
|
1759
|
+
var n;
|
|
1760
|
+
return (n = l.value) == null ? void 0 : n.showSheet(d);
|
|
1761
|
+
}
|
|
1762
|
+
}) && y.open({
|
|
1763
|
+
title: g == -1 ? o("connect.store.category.add") : o("connect.store.category.edit"),
|
|
1764
|
+
contentComponent: $t,
|
|
1753
1765
|
contentComponentProps: {
|
|
1754
|
-
initialValue: ((
|
|
1755
|
-
action:
|
|
1766
|
+
initialValue: (($ = u.value[g]) == null ? void 0 : $.name) ?? "",
|
|
1767
|
+
action: g == -1 ? "add" : "edit"
|
|
1756
1768
|
}
|
|
1757
|
-
}).onPrimary(async (
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
) || await
|
|
1769
|
+
}).onPrimary(async (d) => {
|
|
1770
|
+
d === null && !await pe.remove(
|
|
1771
|
+
o("connect.store.category.remove.confirm"),
|
|
1772
|
+
o("connect.store.category.remove.title")
|
|
1773
|
+
) || await c(
|
|
1762
1774
|
async () => {
|
|
1763
|
-
const
|
|
1764
|
-
await
|
|
1765
|
-
categories:
|
|
1775
|
+
const n = g == -1 ? [...u.value, { name: d, bundles: [] }] : [...u.value].map((p, f) => f == g ? { ...p, name: d } : p).filter((p) => p.name !== null);
|
|
1776
|
+
await ge.updateStoreBundle({
|
|
1777
|
+
categories: n
|
|
1766
1778
|
}), await i.readMemberStore();
|
|
1767
1779
|
},
|
|
1768
1780
|
{
|
|
1769
|
-
message:
|
|
1770
|
-
successMessage:
|
|
1781
|
+
message: d === null ? o("connect.store.category.update.deleting") : g == -1 ? o("connect.store.category.update.creating") : o("connect.store.category.update.updating"),
|
|
1782
|
+
successMessage: d === null ? o("connect.store.category.update.success.deleted") : g == -1 ? o("connect.store.category.update.success.created") : o("connect.store.category.update.success.updated")
|
|
1771
1783
|
}
|
|
1772
1784
|
);
|
|
1773
1785
|
});
|
|
1774
1786
|
}
|
|
1775
|
-
async function z(
|
|
1776
|
-
var p,
|
|
1777
|
-
k ?? (k = (p = w.value) == null ? void 0 : p.target.category),
|
|
1778
|
-
const
|
|
1779
|
-
for (const
|
|
1780
|
-
for (const
|
|
1781
|
-
console.log(
|
|
1782
|
-
k !=
|
|
1783
|
-
const n =
|
|
1787
|
+
async function z(g, k, h, $) {
|
|
1788
|
+
var p, f, I;
|
|
1789
|
+
k ?? (k = (p = w.value) == null ? void 0 : p.target.category), h ?? (h = (f = w.value) == null ? void 0 : f.target.index), $ ?? ($ = (I = w.value) == null ? void 0 : I.target.originalCategoryIndex);
|
|
1790
|
+
const d = Fe(u.value);
|
|
1791
|
+
for (const M of d)
|
|
1792
|
+
for (const R of M.bundles)
|
|
1793
|
+
console.log(R, "bundle in payload"), "pf_vouchers" in R && delete R.pf_vouchers;
|
|
1794
|
+
k != $ && $ != null && (d[$].bundles.splice(h, 1), h = d[k].bundles.length);
|
|
1795
|
+
const n = d[k];
|
|
1784
1796
|
if (!n) {
|
|
1785
|
-
|
|
1797
|
+
rt.error("Unexpected error", 2e3);
|
|
1786
1798
|
return;
|
|
1787
1799
|
}
|
|
1788
|
-
if (
|
|
1789
|
-
if (await
|
|
1790
|
-
|
|
1791
|
-
|
|
1800
|
+
if (g == null) {
|
|
1801
|
+
if (await pe.remove(
|
|
1802
|
+
o("connect.store.bundle.delete.confirm"),
|
|
1803
|
+
o("connect.store.bundle.delete.title")
|
|
1792
1804
|
) == !1)
|
|
1793
1805
|
return;
|
|
1794
|
-
n.bundles.splice(
|
|
1806
|
+
n.bundles.splice(h, 1);
|
|
1795
1807
|
} else
|
|
1796
|
-
|
|
1797
|
-
await
|
|
1808
|
+
h == -1 ? n.bundles.push(g) : n.bundles[h] = g;
|
|
1809
|
+
await c(
|
|
1798
1810
|
async () => {
|
|
1799
|
-
var
|
|
1800
|
-
if (
|
|
1801
|
-
const q = (
|
|
1802
|
-
q === null &&
|
|
1811
|
+
var M, R;
|
|
1812
|
+
if (g != null) {
|
|
1813
|
+
const q = (M = w.value) == null ? void 0 : M.bundleImage;
|
|
1814
|
+
q === null && g.image ? (await Ve.delete(g.image), g.image = null) : q && (g.image = await Ve.update(
|
|
1803
1815
|
Ve.bundleImagePath(void 0, q),
|
|
1804
1816
|
q
|
|
1805
1817
|
));
|
|
1806
1818
|
}
|
|
1807
|
-
await
|
|
1808
|
-
categories:
|
|
1809
|
-
}), await i.readMemberStore(), await i.readMembership(), await i.readRewards(), (
|
|
1819
|
+
await ge.updateStoreBundle({
|
|
1820
|
+
categories: d
|
|
1821
|
+
}), await i.readMemberStore(), await i.readMembership(), await i.readRewards(), (R = w.value) == null || R.showSheet(!1);
|
|
1810
1822
|
},
|
|
1811
1823
|
{
|
|
1812
|
-
message: `${
|
|
1813
|
-
successMessage: `Bundle ${
|
|
1824
|
+
message: `${g == null ? "Deleting" : h == -1 ? "Creating" : "Updating"} bundle`,
|
|
1825
|
+
successMessage: `Bundle ${g == null ? "deleted" : h == -1 ? "created" : "updated"} successfully`
|
|
1814
1826
|
}
|
|
1815
1827
|
);
|
|
1816
1828
|
}
|
|
1817
|
-
function oe(
|
|
1829
|
+
function oe(g) {
|
|
1818
1830
|
var k;
|
|
1819
|
-
(
|
|
1820
|
-
|
|
1821
|
-
|
|
1831
|
+
Ee({
|
|
1832
|
+
hasStoreCompany: !!((k = i.storeOption) != null && k.company),
|
|
1833
|
+
confirm: () => pe.confirm(
|
|
1834
|
+
o("connect.store.category.setup.title"),
|
|
1835
|
+
o("connect.store.category.setup.button"),
|
|
1836
|
+
o("connect.store.category.setup.action"),
|
|
1837
|
+
o("connect.common.cancel")
|
|
1838
|
+
),
|
|
1839
|
+
showSettingSheet: (h) => {
|
|
1840
|
+
var $;
|
|
1841
|
+
return ($ = l.value) == null ? void 0 : $.showSheet(h);
|
|
1842
|
+
}
|
|
1843
|
+
}).then((h) => {
|
|
1844
|
+
var $;
|
|
1845
|
+
h && (($ = w.value) == null || $.showSheet(!0, {
|
|
1846
|
+
...g,
|
|
1847
|
+
bundle: g.bundle ? Fe(g.bundle) : void 0
|
|
1848
|
+
}));
|
|
1822
1849
|
});
|
|
1823
1850
|
}
|
|
1824
1851
|
const F = N([]);
|
|
1825
|
-
function ie(
|
|
1852
|
+
function ie(g) {
|
|
1826
1853
|
var k;
|
|
1827
|
-
(k =
|
|
1828
|
-
bundle:
|
|
1854
|
+
(k = a.value) == null || k.showSheet({
|
|
1855
|
+
bundle: g
|
|
1829
1856
|
});
|
|
1830
1857
|
}
|
|
1831
1858
|
return he(async () => {
|
|
1832
|
-
var k,
|
|
1859
|
+
var k, h;
|
|
1833
1860
|
await t(async () => {
|
|
1834
|
-
var
|
|
1835
|
-
if (await i.readMemberStore(), await i.readMembership(), await i.readRewards(), await i.readPayoutAccount(), (
|
|
1836
|
-
switch ((
|
|
1861
|
+
var $, d;
|
|
1862
|
+
if (await i.readMemberStore(), await i.readMembership(), await i.readRewards(), await i.readPayoutAccount(), ($ = m.currentRoute.value.query) != null && $.action) {
|
|
1863
|
+
switch ((d = m.currentRoute.value.query) == null ? void 0 : d.action) {
|
|
1837
1864
|
case "update_setting":
|
|
1838
|
-
|
|
1865
|
+
U("setting");
|
|
1839
1866
|
break;
|
|
1840
1867
|
case "create_category":
|
|
1841
1868
|
H(-1);
|
|
1842
1869
|
break;
|
|
1843
1870
|
case "create_feedvibe_bundle":
|
|
1844
|
-
|
|
1871
|
+
y.open({
|
|
1845
1872
|
title: "Select category",
|
|
1846
|
-
contentComponent:
|
|
1873
|
+
contentComponent: It
|
|
1847
1874
|
}).onPrimary((n) => {
|
|
1848
|
-
|
|
1875
|
+
y.close(), oe({
|
|
1849
1876
|
categories: T.value,
|
|
1850
1877
|
category: n,
|
|
1851
1878
|
index: -1,
|
|
@@ -1858,58 +1885,58 @@ const gn = { class: "px-24 flex flex-col gap-y-16" }, vn = { class: "flex gap-8
|
|
|
1858
1885
|
}).toObject()
|
|
1859
1886
|
}
|
|
1860
1887
|
});
|
|
1861
|
-
}).onTertiary(() =>
|
|
1888
|
+
}).onTertiary(() => y.close());
|
|
1862
1889
|
break;
|
|
1863
1890
|
}
|
|
1864
|
-
|
|
1891
|
+
m.replace({ query: {} });
|
|
1865
1892
|
}
|
|
1866
1893
|
});
|
|
1867
|
-
const
|
|
1894
|
+
const g = ((k = i.payoutAccount) == null ? void 0 : k.status) === "APPROVED" && ((h = i.payoutAccount) == null ? void 0 : h.enable) === !0;
|
|
1868
1895
|
F.value = [
|
|
1869
|
-
...
|
|
1870
|
-
|
|
1896
|
+
...g ? [] : [S],
|
|
1897
|
+
b,
|
|
1871
1898
|
s,
|
|
1872
1899
|
v
|
|
1873
1900
|
];
|
|
1874
|
-
}), (
|
|
1875
|
-
const
|
|
1876
|
-
return
|
|
1877
|
-
r(
|
|
1878
|
-
title: e(
|
|
1901
|
+
}), (g, k) => {
|
|
1902
|
+
const h = _("FmPageHead"), $ = _("FmButton"), d = _("FmCard");
|
|
1903
|
+
return x(), D(Y, null, [
|
|
1904
|
+
r(h, {
|
|
1905
|
+
title: e(o)("connect.store.title"),
|
|
1879
1906
|
actions: e(F),
|
|
1880
|
-
"onClick:action":
|
|
1907
|
+
"onClick:action": U
|
|
1881
1908
|
}, null, 8, ["title", "actions"]),
|
|
1882
|
-
V("div",
|
|
1883
|
-
e(
|
|
1884
|
-
(
|
|
1909
|
+
V("div", vn, [
|
|
1910
|
+
e(u) && e(u).length > 0 ? (x(), D(Y, { key: 0 }, [
|
|
1911
|
+
(x(!0), D(Y, null, ce(e(u), (n, p) => (x(), D("div", {
|
|
1885
1912
|
key: n.name,
|
|
1886
1913
|
class: "space-y-8 py-12"
|
|
1887
1914
|
}, [
|
|
1888
|
-
V("div",
|
|
1889
|
-
V("div",
|
|
1915
|
+
V("div", hn, [
|
|
1916
|
+
V("div", xn, K(n.name), 1),
|
|
1890
1917
|
r(ke, { json: n }, null, 8, ["json"]),
|
|
1891
|
-
r(
|
|
1918
|
+
r($, {
|
|
1892
1919
|
icon: "edit",
|
|
1893
1920
|
size: "md",
|
|
1894
1921
|
variant: "tertiary",
|
|
1895
|
-
onClick: (
|
|
1922
|
+
onClick: (f) => H(p)
|
|
1896
1923
|
}, null, 8, ["onClick"])
|
|
1897
1924
|
]),
|
|
1898
|
-
V("div",
|
|
1899
|
-
(
|
|
1900
|
-
bundle:
|
|
1901
|
-
key:
|
|
1902
|
-
onEdit: (
|
|
1903
|
-
bundle:
|
|
1925
|
+
V("div", Cn, [
|
|
1926
|
+
(x(!0), D(Y, null, ce(n.bundles, (f, I) => (x(), O(Vt, {
|
|
1927
|
+
bundle: f,
|
|
1928
|
+
key: f._id,
|
|
1929
|
+
onEdit: (M) => oe({
|
|
1930
|
+
bundle: f,
|
|
1904
1931
|
category: p,
|
|
1905
|
-
index:
|
|
1932
|
+
index: I,
|
|
1906
1933
|
categories: e(T)
|
|
1907
1934
|
}),
|
|
1908
|
-
onDelete: (
|
|
1935
|
+
onDelete: (M) => z(null, p, I),
|
|
1909
1936
|
onSend: ie
|
|
1910
1937
|
}, null, 8, ["bundle", "onEdit", "onDelete"]))), 128)),
|
|
1911
|
-
r(
|
|
1912
|
-
onCreate: (
|
|
1938
|
+
r(wt, {
|
|
1939
|
+
onCreate: (f) => oe({
|
|
1913
1940
|
category: p,
|
|
1914
1941
|
index: -1,
|
|
1915
1942
|
categories: e(T)
|
|
@@ -1917,42 +1944,42 @@ const gn = { class: "px-24 flex flex-col gap-y-16" }, vn = { class: "flex gap-8
|
|
|
1917
1944
|
}, null, 8, ["onCreate"])
|
|
1918
1945
|
])
|
|
1919
1946
|
]))), 128)),
|
|
1920
|
-
r(
|
|
1947
|
+
r(pn, {
|
|
1921
1948
|
ref_key: "bundleSheetRef",
|
|
1922
1949
|
ref: w,
|
|
1923
1950
|
onUpdate: z
|
|
1924
1951
|
}, null, 512)
|
|
1925
|
-
], 64)) : (
|
|
1952
|
+
], 64)) : (x(), O(d, {
|
|
1926
1953
|
key: 1,
|
|
1927
1954
|
variant: "outlined",
|
|
1928
1955
|
class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
|
|
1929
1956
|
}, {
|
|
1930
1957
|
default: B(() => [
|
|
1931
1958
|
k[1] || (k[1] = V("img", {
|
|
1932
|
-
src:
|
|
1959
|
+
src: Xe,
|
|
1933
1960
|
class: "aspect-square w-[150px]"
|
|
1934
1961
|
}, null, -1)),
|
|
1935
|
-
V("div",
|
|
1936
|
-
V("div", _n, K(e(
|
|
1937
|
-
V("div",
|
|
1962
|
+
V("div", Sn, [
|
|
1963
|
+
V("div", _n, K(e(o)("connect.store.bundle.title")), 1),
|
|
1964
|
+
V("div", Fn, K(e(o)("connect.store.bundle.description")), 1)
|
|
1938
1965
|
]),
|
|
1939
|
-
r(
|
|
1966
|
+
r($, {
|
|
1940
1967
|
variant: "primary",
|
|
1941
|
-
label: e(
|
|
1968
|
+
label: e(o)("connect.store.actions.addCategory"),
|
|
1942
1969
|
icon: "add",
|
|
1943
1970
|
onClick: k[0] || (k[0] = (n) => H(-1))
|
|
1944
1971
|
}, null, 8, ["label"])
|
|
1945
1972
|
]),
|
|
1946
1973
|
_: 1
|
|
1947
1974
|
})),
|
|
1948
|
-
r(
|
|
1975
|
+
r(Xt, {
|
|
1949
1976
|
ref_key: "settingSheetRef",
|
|
1950
1977
|
ref: l,
|
|
1951
1978
|
onUpdate: Z
|
|
1952
1979
|
}, null, 512),
|
|
1953
|
-
r(
|
|
1980
|
+
r(bn, {
|
|
1954
1981
|
ref_key: "sendBundleSheetRef",
|
|
1955
|
-
ref:
|
|
1982
|
+
ref: a
|
|
1956
1983
|
}, null, 512)
|
|
1957
1984
|
])
|
|
1958
1985
|
], 64);
|
|
@@ -1960,5 +1987,5 @@ const gn = { class: "px-24 flex flex-col gap-y-16" }, vn = { class: "flex gap-8
|
|
|
1960
1987
|
}
|
|
1961
1988
|
});
|
|
1962
1989
|
export {
|
|
1963
|
-
|
|
1990
|
+
Qn as default
|
|
1964
1991
|
};
|