@feedmepos/mf-connect 0.1.37-prod → 0.1.38-beta.2
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-BjSfI2Ff.js +761 -0
- package/dist/{App-Bpo0XZSs.js → App-D11A2JY1.js} +364 -352
- package/dist/AuditLogs-DWCFYoRg.js +1887 -0
- package/dist/{Bin-ohZ2CZZR.js → Bin-9wV4Ah3M.js} +8 -8
- package/dist/{Broadcast-D5x0_-zC.js → Broadcast-I3BtSk8V.js} +40 -40
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CYb38NXA.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-XJqTXbKr.js} +18 -18
- package/dist/{Card-BM-Lrm5y.js → Card-CqALG5RM.js} +159 -159
- package/dist/{Collections-Cr4aoJer.js → Collections-rg3SzoUb.js} +103 -91
- package/dist/{Credit-DzDVFv4H.js → Credit-BNn1sYZv.js} +74 -74
- package/dist/DateRangeChip.vue_vue_type_script_setup_true_lang-BUzUIIUW.js +58 -0
- package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-Bs8o9n1V.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-PJ8q72XH.js} +491 -488
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-koqrPPqM.js → EffectSheet.vue_vue_type_style_index_0_lang-Sww7KNle.js} +91 -89
- package/dist/{Experience-CjaDdbvZ.js → Experience-D_Qm8SUj.js} +41 -41
- package/dist/{FilterChip.vue_vue_type_script_setup_true_lang-BrPLkFX8.js → FilterChip.vue_vue_type_script_setup_true_lang-d8rh38tD.js} +2 -6
- package/dist/{Game-BuiTygow.js → Game-CKXgXm6Q.js} +31 -31
- package/dist/ImageInput.vue_vue_type_script_setup_true_lang-rWUkV9gn.js +144 -0
- package/dist/{Index-CQGzUU-w.js → Index-D4DGfUHd.js} +10 -10
- package/dist/Marketing-Dn9A1vgH.js +20073 -0
- package/dist/Member-B55vWHDd.js +279 -0
- package/dist/MemberList-BWTG9Ohy.js +1606 -0
- package/dist/MemberOverview-wL_ailso.js +58 -0
- package/dist/{MemberTransactions-DzG1fY0c.js → MemberTransactions-CP5EI-W0.js} +1 -1
- package/dist/MessageInput.vue_vue_type_script_setup_true_lang-D--_An-f.js +60279 -0
- package/dist/{Mission-BtypT2uF.js → Mission-CFvhROuB.js} +21 -21
- package/dist/{Overview-Be7bUtRO.js → Overview-4273yNwL.js} +335 -335
- package/dist/{Point-Bw4lnLqp.js → Point-B_-_C919.js} +41 -41
- package/dist/Promotion-D2S3COxk.js +289 -0
- package/dist/{Queue-CpPEVgn8.js → Queue-BmS1Oi-C.js} +52 -52
- package/dist/{Record-DQq4P69i.js → Record-DRBl0M8g.js} +9 -9
- package/dist/{Reward-DJH0eM8u.js → Reward-8056NmfK.js} +173 -173
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-_kw_PR0h.js → RewardGroup.vue_vue_type_script_setup_true_lang-CJ_WC2gV.js} +11 -11
- package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-CRGep1RK.js → RuleGroup.vue_vue_type_script_setup_true_lang-DqNQl_nz.js} +635 -548
- package/dist/Segment-Bzq-pyhc.js +882 -0
- package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-Dx6Ew9Z_.js → SelectItems.vue_vue_type_script_setup_true_lang-4nNkkklE.js} +2 -2
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-B60_8Toi.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-Dnf2oxOG.js} +11 -11
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-BCaJ3xKT.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-BLYP-5U9.js} +3 -3
- package/dist/{Setting-GRIUo7vg.js → Setting-BrJfYoru.js} +432 -432
- package/dist/{Store-H0UDQpln.js → Store-Bpl_4yZW.js} +211 -211
- package/dist/StoreRewards-Cu7n7Pjz.js +423 -0
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-T3Wo2maC.js +1029 -0
- package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-D-jL1oGS.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-QucRaI08.js} +1 -1
- package/dist/{Tier-CJufQcIz.js → Tier-_LnXg3n6.js} +106 -106
- package/dist/{Title-BBMgGUld.js → Title-B7AGStvx.js} +133 -131
- package/dist/{Transaction-DsucPnfp.js → Transaction-Chxv6V7u.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-CwOcZEQX.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-CzXNmobp.js} +6 -6
- package/dist/{Voucher-BPvxKO_w.js → Voucher-C5z2kOq9.js} +153 -123
- package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-DdGMrk2C.js +419 -0
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-DMs4XKXM.js → ZodTextField.vue_vue_type_script_setup_true_lang-BlXzEWA6.js} +1 -1
- package/dist/{app-D3MT1deX.js → app-7cvPyHJ7.js} +164 -125
- package/dist/{app-Bo0JpadQ.js → app-BVojNX0w.js} +1 -1
- package/dist/app.js +4 -3
- package/dist/business-CmxV69wT.js +79 -0
- package/dist/{campaign-Z3l7BoMg.js → campaign-CT_cNJEL.js} +9 -9
- package/dist/{campaign-j1c3ou7l.js → campaign-Dq5C_no-.js} +5 -3
- package/dist/{campaign.enum-CVXPc5Pd.js → campaign.enum-dp7yHKzF.js} +1 -1
- package/dist/campaign.fn-BYZgKDN7.js +758 -0
- package/dist/{collectible.enum-CDSikBAy.js → collectible.enum-DxbB4DxT.js} +1 -1
- package/dist/{collection.fn-Bz38mGMa.js → collection.fn-CNZRdUgy.js} +2 -2
- package/dist/{dto-D648NN4s.js → dto-CT9zZbv9.js} +4 -4
- package/dist/{effect-DbMAmVSR.js → effect-FIlOEC4H.js} +1 -1
- package/dist/{email-addresses-KOVDrRiK.js → email-addresses-Ba7xImfX.js} +1 -1
- package/dist/{export-cTZf8Avd.js → export-uzjZFNF9.js} +3 -3
- package/dist/{helper-BYyfcLqw.js → helper-D4sAZde0.js} +1 -1
- package/dist/{index-BIaCtk8e.js → index-B9pl4zRZ.js} +192 -79
- package/dist/{index-B4MqsaBz.js → index-BI3m1Ehv.js} +3 -3
- package/dist/{index-E-0tTd0_.js → index-BXz54M1s.js} +1 -1
- package/dist/{index-BMl2KZts.js → index-BjU8LVUC.js} +11447 -10969
- package/dist/index-CH3z92VV.js +31 -0
- package/dist/{index-BTb8I_eB.js → index-CNJLP3D5.js} +1 -1
- package/dist/{index-BrKXRxe_.js → index-CONvJfKv.js} +1 -1
- package/dist/index-CS3Jmojj.js +32260 -0
- package/dist/{index-CTPMbFf5.js → index-CUfS9Kp1.js} +10 -9
- package/dist/index-CsaQJMAR.js +66 -0
- package/dist/{index-nF9iYTlh.js → index-CvBcve-r.js} +1 -1
- package/dist/index-CwsMG2cV.js +56 -0
- package/dist/{index-B3p0hmIV.js → index-D5rvMvzx.js} +1 -1
- package/dist/{index-CvoShC5J.js → index-DNxa8Rqx.js} +536 -461
- package/dist/{index-DPBHiqsJ.js → index-l2F5MnLF.js} +1 -1
- package/dist/{index.esm2017-DFYwde30.js → index.esm2017-ATcsD5N4.js} +127 -127
- package/dist/{loading-vUArhX_O.js → loading-BWGQSrCB.js} +1 -1
- package/dist/{membership-BHKv29yt.js → membership-Cc4OZ8-U.js} +3 -3
- package/dist/{money-Bl3_QRkE.js → money-D7p8nfun.js} +1 -1
- package/dist/{number-hh_S9w7k.js → number-CMJjC4qz.js} +1 -1
- package/dist/objectid-D5T27iny.js +145 -0
- package/dist/{plugins-CVes2wzE.js → plugins-eQis66QR.js} +2 -2
- package/dist/remy-vue-client-Cpppk9h-.js +1693 -0
- package/dist/{reward-ANZOdWzf.js → reward-DrnzbG20.js} +1 -1
- package/dist/{rule-BvFk5bQg.js → rule-CtRxkYXB.js} +3 -3
- package/dist/{rule-builder-BSN777PN.js → rule-builder-Di9RIYHF.js} +17 -17
- package/dist/style.css +1 -1
- package/dist/{template-Dh9lDLs_.js → template-C3UfY0v5.js} +64 -64
- package/dist/{trigger-C7THbt7R.js → trigger-C9U7Zgad.js} +7 -7
- package/dist/{usePagination-JoYaROkV.js → usePagination-BeF5K3M7.js} +85 -85
- package/dist/{user-DtNR9JY2.js → user-D7n9yYmO.js} +1 -1
- package/dist/{vue-i18n-BWyHnm4m.js → vue-i18n-Bz45zC04.js} +387 -387
- package/dist/{xlsx-7u9SB0oa.js → xlsx-D4S4qbcZ.js} +226 -226
- package/package.json +9 -3
- package/dist/Analytic-CavR2bzs.js +0 -427
- package/dist/ImageInput.vue_vue_type_script_setup_true_lang-ByhTB9Ie.js +0 -144
- package/dist/Marketing-BSspYuhg.js +0 -319
- package/dist/Member-B4S0UNGq.js +0 -287
- package/dist/MemberList-CfnUJ3mh.js +0 -1606
- package/dist/MemberOverview-C2n9oJZh.js +0 -58
- package/dist/MessageInput.vue_vue_type_script_setup_true_lang-hZUWLTWj.js +0 -455
- package/dist/Promotion-Bg6x0rAh.js +0 -255
- package/dist/Segment-BLB4VWNJ.js +0 -882
- package/dist/StoreRewards--TNIFaCo.js +0 -423
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-CfB8tA5l.js +0 -995
- package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-Bg-9YqLP.js +0 -419
- package/dist/business-DMALI7ZO.js +0 -78
- package/dist/campaign.fn-rsRhHYZP.js +0 -758
- package/dist/index-BsCGyJMY.js +0 -29566
- package/dist/index-CuvNtC_M.js +0 -61
- package/dist/index-DFKmjCG1.js +0 -44
- package/dist/index-Dbd4WA4r.js +0 -61
- package/dist/objectid-CEyMlMge.js +0 -145
|
@@ -1,27 +1,26 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var O = (f, i, d) =>
|
|
4
|
-
import { defineComponent as
|
|
1
|
+
var ae = Object.defineProperty;
|
|
2
|
+
var le = (f, i, d) => i in f ? ae(f, i, { enumerable: !0, configurable: !0, writable: !0, value: d }) : f[i] = d;
|
|
3
|
+
var O = (f, i, d) => le(f, typeof i != "symbol" ? i + "" : i, d);
|
|
4
|
+
import { defineComponent as J, ref as p, computed as Q, watch as K, resolveComponent as u, openBlock as x, createBlock as z, unref as o, isRef as j, withCtx as I, createElementVNode as v, createVNode as r, createElementBlock as N, Fragment as P, renderList as ne, createCommentVNode as R, onMounted as se, h as S } from "vue";
|
|
5
5
|
import { h as G } from "./moment-BWErdI6_.js";
|
|
6
|
-
import { components as
|
|
7
|
-
import "./index-
|
|
6
|
+
import { components as H } from "@feedmepos/ui-library";
|
|
7
|
+
import "./index-CS3Jmojj.js";
|
|
8
8
|
import { J as re } from "./JsonViewer-v8_C7l5N.js";
|
|
9
|
-
import { u as
|
|
9
|
+
import { u as W } from "./loading-BWGQSrCB.js";
|
|
10
10
|
import { u as ie } from "./app-wDQR6dpb.js";
|
|
11
|
-
import { useRoute as
|
|
12
|
-
import { c as
|
|
11
|
+
import { useRoute as X, useRouter as ue } from "vue-router";
|
|
12
|
+
import { c as q } from "./index-D5rvMvzx.js";
|
|
13
13
|
import { e as m } from "./index-vh86FiIQ.js";
|
|
14
|
-
import { u as Y, w as de } from "./xlsx-
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
|
|
20
|
-
const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code type", -1), he = { class: "space-y-16" }, ve = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Settings", -1), ye = { class: "gap-16 grid grid-cols-2" }, xe = { class: "flex items-center gap-8" }, Ve = /* @__PURE__ */ H({
|
|
14
|
+
import { u as Y, w as de } from "./xlsx-D4S4qbcZ.js";
|
|
15
|
+
import { u as ce, _ as me } from "./usePagination-BeF5K3M7.js";
|
|
16
|
+
import { a as pe } from "./plugins-eQis66QR.js";
|
|
17
|
+
import { m as fe } from "./index-l2F5MnLF.js";
|
|
18
|
+
import { o as ge } from "./objectId-dwaoBfJX.js";
|
|
19
|
+
const be = { class: "space-y-16" }, Ce = { class: "gap-16 grid grid-cols-2" }, ve = { class: "flex items-center gap-8" }, he = /* @__PURE__ */ J({
|
|
21
20
|
__name: "CreateCollectionSheet",
|
|
22
21
|
emits: ["success"],
|
|
23
22
|
setup(f, { expose: i, emit: d }) {
|
|
24
|
-
const { minor:
|
|
23
|
+
const { minor: w } = W, F = X(), k = p(), _ = p(!1), A = d, g = p(!1);
|
|
25
24
|
function D(s) {
|
|
26
25
|
g.value = s, s && (a.value = {
|
|
27
26
|
quantity: 1,
|
|
@@ -56,7 +55,7 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
56
55
|
value: "single",
|
|
57
56
|
sublabel: "Enter your own custom codes"
|
|
58
57
|
}
|
|
59
|
-
],
|
|
58
|
+
], U = [
|
|
60
59
|
{
|
|
61
60
|
label: "Alphanumeric",
|
|
62
61
|
value: "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
|
@@ -69,12 +68,12 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
69
68
|
{ label: "Alphabetic Uppercase", value: "ABCDEFGHIJKLMNOPQRSTUVWXYZ" },
|
|
70
69
|
{ label: "Numbers", value: "0123456789" },
|
|
71
70
|
{ label: "Custom", value: "" }
|
|
72
|
-
],
|
|
71
|
+
], h = p(U[0].value), c = p("bulk"), y = p(!1), M = Q(() => F.params.id);
|
|
73
72
|
async function n(s) {
|
|
74
73
|
var e;
|
|
75
|
-
await ((e =
|
|
74
|
+
await ((e = k.value) == null ? void 0 : e.validateInputs()), _.value && await w(
|
|
76
75
|
async () => {
|
|
77
|
-
await
|
|
76
|
+
await q.createCollectionByCampaignId(M.value, s), await A("success");
|
|
78
77
|
},
|
|
79
78
|
{
|
|
80
79
|
message: "Creating claim(s)",
|
|
@@ -105,8 +104,8 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
105
104
|
s != e && (a.value.codeConfig.pattern = "#".repeat(Math.min(16, Number(s))));
|
|
106
105
|
}
|
|
107
106
|
), (s, e) => {
|
|
108
|
-
const C = u("FmRadio"),
|
|
109
|
-
return
|
|
107
|
+
const C = u("FmRadio"), L = u("FmRadioGroup"), V = u("FmSwitch"), T = u("FmStepperField"), Z = u("FmSelect"), B = u("FmTextField"), ee = u("FmTextarea"), oe = u("FmForm"), $ = u("FmButton"), te = u("FmSideSheet");
|
|
108
|
+
return x(), z(te, {
|
|
110
109
|
"max-width": 560,
|
|
111
110
|
"dismiss-away": !0,
|
|
112
111
|
header: "Create collection",
|
|
@@ -117,7 +116,7 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
117
116
|
]
|
|
118
117
|
}, {
|
|
119
118
|
"side-sheet-footer": I(() => [
|
|
120
|
-
|
|
119
|
+
v("div", ve, [
|
|
121
120
|
r($, {
|
|
122
121
|
label: "Save",
|
|
123
122
|
onClick: e[12] || (e[12] = (t) => n(o(a))),
|
|
@@ -133,23 +132,23 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
133
132
|
]),
|
|
134
133
|
default: I(() => [
|
|
135
134
|
r(re, { json: o(a) }, null, 8, ["json"]),
|
|
136
|
-
r(
|
|
135
|
+
r(oe, {
|
|
137
136
|
ref_key: "form",
|
|
138
|
-
ref:
|
|
137
|
+
ref: k,
|
|
139
138
|
class: "space-y-40",
|
|
140
|
-
onValidationSuccess: e[10] || (e[10] = (t) =>
|
|
141
|
-
onValidationFailed: e[11] || (e[11] = (t) =>
|
|
139
|
+
onValidationSuccess: e[10] || (e[10] = (t) => _.value = !0),
|
|
140
|
+
onValidationFailed: e[11] || (e[11] = (t) => _.value = !1)
|
|
142
141
|
}, {
|
|
143
142
|
default: I(() => [
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
r(
|
|
143
|
+
v("div", null, [
|
|
144
|
+
e[16] || (e[16] = v("div", { class: "fm-typo-en-body-lg-600" }, "Code type", -1)),
|
|
145
|
+
r(L, {
|
|
147
146
|
modelValue: o(c),
|
|
148
147
|
"onUpdate:modelValue": e[0] || (e[0] = (t) => j(c) ? c.value = t : null),
|
|
149
148
|
inline: !1
|
|
150
149
|
}, {
|
|
151
150
|
default: I(() => [
|
|
152
|
-
(
|
|
151
|
+
(x(), N(P, null, ne(E, (t) => r(C, {
|
|
153
152
|
key: t.value,
|
|
154
153
|
value: t.value,
|
|
155
154
|
label: t.label,
|
|
@@ -159,19 +158,19 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
159
158
|
_: 1
|
|
160
159
|
}, 8, ["modelValue"])
|
|
161
160
|
]),
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
o(c) === "bulk" ? (
|
|
161
|
+
v("div", be, [
|
|
162
|
+
e[17] || (e[17] = v("div", { class: "fm-typo-en-body-lg-600" }, "Settings", -1)),
|
|
163
|
+
o(c) === "bulk" ? (x(), N(P, { key: 0 }, [
|
|
165
164
|
r(V, {
|
|
166
|
-
"model-value": o(
|
|
165
|
+
"model-value": o(y),
|
|
167
166
|
"label-placement": "right",
|
|
168
167
|
value: "true",
|
|
169
168
|
label: "Advance code setting",
|
|
170
169
|
required: !0,
|
|
171
|
-
"onUpdate:modelValue": e[1] || (e[1] = () =>
|
|
170
|
+
"onUpdate:modelValue": e[1] || (e[1] = () => y.value = !o(y))
|
|
172
171
|
}, null, 8, ["model-value"]),
|
|
173
|
-
o(
|
|
174
|
-
r(
|
|
172
|
+
o(y) ? (x(), N(P, { key: 0 }, [
|
|
173
|
+
r(T, {
|
|
175
174
|
modelValue: o(a).codeConfig.length,
|
|
176
175
|
"onUpdate:modelValue": e[2] || (e[2] = (t) => o(a).codeConfig.length = t),
|
|
177
176
|
label: "Code length",
|
|
@@ -183,42 +182,42 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
183
182
|
],
|
|
184
183
|
required: !0
|
|
185
184
|
}, null, 8, ["modelValue", "rules"]),
|
|
186
|
-
r(
|
|
185
|
+
r(Z, {
|
|
187
186
|
label: "Charset",
|
|
188
|
-
"model-value": o(
|
|
189
|
-
items:
|
|
187
|
+
"model-value": o(h),
|
|
188
|
+
items: U,
|
|
190
189
|
"helper-text": o(a).codeConfig.charset.length > 62 ? `${o(a).codeConfig.charset.substring(0, 62)}...` : o(a).codeConfig.charset,
|
|
191
190
|
"onUpdate:modelValue": e[3] || (e[3] = (t) => {
|
|
192
|
-
|
|
191
|
+
h.value = t, o(a).codeConfig.charset = t;
|
|
193
192
|
})
|
|
194
193
|
}, null, 8, ["model-value", "helper-text"]),
|
|
195
|
-
o(
|
|
194
|
+
o(h) === "" ? (x(), z(B, {
|
|
196
195
|
key: 0,
|
|
197
196
|
modelValue: o(a).codeConfig.charset,
|
|
198
197
|
"onUpdate:modelValue": e[4] || (e[4] = (t) => o(a).codeConfig.charset = t),
|
|
199
198
|
label: "Custom Charset",
|
|
200
199
|
required: ""
|
|
201
|
-
}, null, 8, ["modelValue"])) :
|
|
202
|
-
|
|
203
|
-
r(
|
|
200
|
+
}, null, 8, ["modelValue"])) : R("", !0),
|
|
201
|
+
v("div", Ce, [
|
|
202
|
+
r(B, {
|
|
204
203
|
modelValue: o(a).codeConfig.prefix,
|
|
205
204
|
"onUpdate:modelValue": e[5] || (e[5] = (t) => o(a).codeConfig.prefix = t),
|
|
206
205
|
label: "Prefix (Optional)"
|
|
207
206
|
}, null, 8, ["modelValue"]),
|
|
208
|
-
r(
|
|
207
|
+
r(B, {
|
|
209
208
|
modelValue: o(a).codeConfig.suffix,
|
|
210
209
|
"onUpdate:modelValue": e[6] || (e[6] = (t) => o(a).codeConfig.suffix = t),
|
|
211
210
|
label: "Suffix (Optional)"
|
|
212
211
|
}, null, 8, ["modelValue"])
|
|
213
212
|
]),
|
|
214
|
-
r(
|
|
213
|
+
r(B, {
|
|
215
214
|
modelValue: o(a).codeConfig.pattern,
|
|
216
215
|
"onUpdate:modelValue": e[7] || (e[7] = (t) => o(a).codeConfig.pattern = t),
|
|
217
216
|
label: "Pattern",
|
|
218
217
|
required: !0
|
|
219
218
|
}, null, 8, ["modelValue"])
|
|
220
|
-
], 64)) :
|
|
221
|
-
r(
|
|
219
|
+
], 64)) : R("", !0),
|
|
220
|
+
r(B, {
|
|
222
221
|
modelValue: o(a).quantity,
|
|
223
222
|
"onUpdate:modelValue": e[8] || (e[8] = (t) => o(a).quantity = t),
|
|
224
223
|
label: "Number of code",
|
|
@@ -229,8 +228,8 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
229
228
|
required: !0,
|
|
230
229
|
"helper-text": `${o(a).quantity} claim will be created`
|
|
231
230
|
}, null, 8, ["modelValue", "rules", "helper-text"])
|
|
232
|
-
], 64)) :
|
|
233
|
-
o(c) !== "bulk" ? (
|
|
231
|
+
], 64)) : R("", !0),
|
|
232
|
+
o(c) !== "bulk" ? (x(), z(ee, {
|
|
234
233
|
key: 1,
|
|
235
234
|
modelValue: o(a).code,
|
|
236
235
|
"onUpdate:modelValue": e[9] || (e[9] = (t) => o(a).code = t),
|
|
@@ -241,7 +240,7 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
241
240
|
(t) => !b(t) || "Custom code must not contain space"
|
|
242
241
|
],
|
|
243
242
|
placeholder: "(For multiple codes, please enter in the new row.)"
|
|
244
|
-
}, null, 8, ["modelValue", "rules"])) :
|
|
243
|
+
}, null, 8, ["modelValue", "rules"])) : R("", !0)
|
|
245
244
|
])
|
|
246
245
|
]),
|
|
247
246
|
_: 1
|
|
@@ -252,7 +251,7 @@ const Ce = /* @__PURE__ */ h("div", { class: "fm-typo-en-body-lg-600" }, "Code t
|
|
|
252
251
|
};
|
|
253
252
|
}
|
|
254
253
|
});
|
|
255
|
-
class
|
|
254
|
+
class xe {
|
|
256
255
|
constructor() {
|
|
257
256
|
O(this, "data", []);
|
|
258
257
|
}
|
|
@@ -264,27 +263,27 @@ class Se {
|
|
|
264
263
|
return Y.book_append_sheet(i, d, "Collection"), i;
|
|
265
264
|
}
|
|
266
265
|
}
|
|
267
|
-
const
|
|
266
|
+
const ye = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Ve = { class: "flex items-center justify-end py-4 xs:hidden" }, Le = /* @__PURE__ */ J({
|
|
268
267
|
__name: "Collections",
|
|
269
268
|
setup(f) {
|
|
270
|
-
const i = ue(), d =
|
|
269
|
+
const i = ue(), d = X(), w = p(), F = Q(() => d.params.id), k = p(!1), { custom: _ } = W, A = [
|
|
271
270
|
{
|
|
272
271
|
header: "ID/Code",
|
|
273
272
|
accessorKey: "_id",
|
|
274
273
|
cell(n) {
|
|
275
|
-
return
|
|
276
|
-
|
|
274
|
+
return S("div", { class: "flex items-center" }, [
|
|
275
|
+
S(H.FmIcon, {
|
|
277
276
|
name: "content_copy",
|
|
278
277
|
outline: !0,
|
|
279
278
|
size: "sm",
|
|
280
279
|
class: "cursor-pointer mr-4",
|
|
281
280
|
onClick: (l) => {
|
|
282
|
-
l.preventDefault(), l.stopPropagation(),
|
|
281
|
+
l.preventDefault(), l.stopPropagation(), pe(
|
|
283
282
|
n.row.original.code || n.row.original._id.toString()
|
|
284
283
|
);
|
|
285
284
|
}
|
|
286
285
|
}),
|
|
287
|
-
|
|
286
|
+
S(
|
|
288
287
|
"div",
|
|
289
288
|
{ class: "pr-2 text-ellipsis overflow-hidden" },
|
|
290
289
|
n.row.original.code || n.row.original._id.toString()
|
|
@@ -298,7 +297,20 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
298
297
|
enableSorting: !1,
|
|
299
298
|
cell(n) {
|
|
300
299
|
const l = n.row.original.pf_user;
|
|
301
|
-
return
|
|
300
|
+
return S(
|
|
301
|
+
"div",
|
|
302
|
+
{
|
|
303
|
+
class: "flex items-center gap-x-8"
|
|
304
|
+
},
|
|
305
|
+
[
|
|
306
|
+
S(H.FmAvatar, {
|
|
307
|
+
name: l != null && l.photoUrl || l == null ? void 0 : l.name,
|
|
308
|
+
src: (l == null ? void 0 : l.photoUrl) ?? void 0,
|
|
309
|
+
size: "sm"
|
|
310
|
+
}),
|
|
311
|
+
S("span", l == null ? void 0 : l.name)
|
|
312
|
+
]
|
|
313
|
+
);
|
|
302
314
|
}
|
|
303
315
|
},
|
|
304
316
|
{
|
|
@@ -316,7 +328,7 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
316
328
|
{
|
|
317
329
|
header: "Created at",
|
|
318
330
|
accessorKey: "_id",
|
|
319
|
-
accessorFn: (n) => G(
|
|
331
|
+
accessorFn: (n) => G(ge(n._id.toString())).format("DD MMM YYYY")
|
|
320
332
|
},
|
|
321
333
|
{
|
|
322
334
|
header: "Nearest expired at",
|
|
@@ -327,21 +339,21 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
327
339
|
}
|
|
328
340
|
}
|
|
329
341
|
], g = {
|
|
330
|
-
"$connect-STORE_REWARD_COLLECTIONS":
|
|
331
|
-
"$connect-CAMPAIGN_VOUCHER_COLLECTIONS":
|
|
342
|
+
"$connect-STORE_REWARD_COLLECTIONS": fe.readCollectionsByRewardId,
|
|
343
|
+
"$connect-CAMPAIGN_VOUCHER_COLLECTIONS": q.readCollectionsByCampaignId
|
|
332
344
|
}, D = (n) => {
|
|
333
345
|
const l = g[d.name];
|
|
334
346
|
return (b) => l(n, b);
|
|
335
|
-
}, { tableMeta: a, rowData: E, onSort:
|
|
336
|
-
async function
|
|
347
|
+
}, { tableMeta: a, rowData: E, onSort: U, debouncedFetchData: h, onSearch: c } = ce(D(F.value));
|
|
348
|
+
async function y() {
|
|
337
349
|
var n;
|
|
338
|
-
await
|
|
350
|
+
await h(), (n = w.value) == null || n.showSheet(!1);
|
|
339
351
|
}
|
|
340
|
-
async function
|
|
341
|
-
|
|
352
|
+
async function M() {
|
|
353
|
+
k.value || _(
|
|
342
354
|
async () => {
|
|
343
355
|
var s;
|
|
344
|
-
const n = new
|
|
356
|
+
const n = new xe(), l = (await q.readCollectionsByCampaignId(F.value, {
|
|
345
357
|
limit: 1,
|
|
346
358
|
skip: 0,
|
|
347
359
|
sortBy: m.sortBy,
|
|
@@ -354,15 +366,15 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
354
366
|
skip: m.page - 1,
|
|
355
367
|
sortBy: m.sortBy,
|
|
356
368
|
descending: m.descending
|
|
357
|
-
},
|
|
358
|
-
|
|
369
|
+
}, L = await q.readCollectionsByCampaignId(
|
|
370
|
+
F.value,
|
|
359
371
|
C
|
|
360
372
|
);
|
|
361
|
-
for await (const V of
|
|
362
|
-
const
|
|
373
|
+
for await (const V of L.resources) {
|
|
374
|
+
const T = {
|
|
363
375
|
Id: (V == null ? void 0 : V.code) || ((s = V._id) == null ? void 0 : s.toString()) || ""
|
|
364
376
|
};
|
|
365
|
-
n.addRecord(
|
|
377
|
+
n.addRecord(T);
|
|
366
378
|
}
|
|
367
379
|
m.page++;
|
|
368
380
|
}
|
|
@@ -377,15 +389,15 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
377
389
|
), m.page = 1;
|
|
378
390
|
},
|
|
379
391
|
{
|
|
380
|
-
isLoading:
|
|
392
|
+
isLoading: k
|
|
381
393
|
}
|
|
382
394
|
);
|
|
383
395
|
}
|
|
384
|
-
return
|
|
385
|
-
await
|
|
396
|
+
return se(async () => {
|
|
397
|
+
await h();
|
|
386
398
|
}), (n, l) => {
|
|
387
399
|
const b = u("FmPageHead"), s = u("FmSearch");
|
|
388
|
-
return
|
|
400
|
+
return x(), N(P, null, [
|
|
389
401
|
r(b, {
|
|
390
402
|
title: "Collections",
|
|
391
403
|
"back-button": !0,
|
|
@@ -400,10 +412,10 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
400
412
|
"onClick:back": l[0] || (l[0] = (e) => o(i).back()),
|
|
401
413
|
"onClick:action": l[1] || (l[1] = (e) => {
|
|
402
414
|
var C;
|
|
403
|
-
e === "create" && ((C = o(
|
|
415
|
+
e === "create" && ((C = o(w)) == null || C.showSheet(!0)), e === "export" && M();
|
|
404
416
|
})
|
|
405
417
|
}),
|
|
406
|
-
|
|
418
|
+
v("div", ye, [
|
|
407
419
|
r(s, {
|
|
408
420
|
class: "hidden xs:flex border-b border-fm-color-neutral-gray-100",
|
|
409
421
|
modelValue: o(a).searchValue,
|
|
@@ -414,7 +426,7 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
414
426
|
placeholder: "Search",
|
|
415
427
|
collapsible: ""
|
|
416
428
|
}, null, 8, ["modelValue", "onUpdate:modelValue"]),
|
|
417
|
-
|
|
429
|
+
v("div", Ve, [
|
|
418
430
|
r(s, {
|
|
419
431
|
modelValue: o(a).searchValue,
|
|
420
432
|
"onUpdate:modelValue": [
|
|
@@ -425,22 +437,22 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
425
437
|
collapsible: ""
|
|
426
438
|
}, null, 8, ["modelValue", "onUpdate:modelValue"])
|
|
427
439
|
]),
|
|
428
|
-
r(
|
|
440
|
+
r(me, {
|
|
429
441
|
loading: o(a).isLoading,
|
|
430
442
|
"row-data": o(E),
|
|
431
|
-
"column-defs":
|
|
443
|
+
"column-defs": A,
|
|
432
444
|
"row-count": o(a).totalRows,
|
|
433
445
|
"page-count": o(a).pageCount,
|
|
434
446
|
"page-index": o(a).pageIndex,
|
|
435
447
|
"page-size": o(a).pageSize,
|
|
436
448
|
"shrink-at": !1,
|
|
437
|
-
onSortChange: o(
|
|
438
|
-
onPageChange: l[4] || (l[4] = (e) => o(
|
|
449
|
+
onSortChange: o(U),
|
|
450
|
+
onPageChange: l[4] || (l[4] = (e) => o(h)({ pageSize: e.pageSize, pageIndex: e.pageIndex }))
|
|
439
451
|
}, null, 8, ["loading", "row-data", "row-count", "page-count", "page-index", "page-size", "onSortChange"]),
|
|
440
|
-
r(
|
|
452
|
+
r(he, {
|
|
441
453
|
ref_key: "sheetRef",
|
|
442
|
-
ref:
|
|
443
|
-
onSuccess:
|
|
454
|
+
ref: w,
|
|
455
|
+
onSuccess: y
|
|
444
456
|
}, null, 512)
|
|
445
457
|
])
|
|
446
458
|
], 64);
|
|
@@ -448,5 +460,5 @@ const we = { class: "px-24 flex flex-col gap-y-32 pb-24" }, Fe = { class: "flex
|
|
|
448
460
|
}
|
|
449
461
|
});
|
|
450
462
|
export {
|
|
451
|
-
|
|
463
|
+
Le as default
|
|
452
464
|
};
|