@feedmepos/mf-connect 0.1.0-beta.2 → 0.1.0-beta.21

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.
Files changed (97) hide show
  1. package/dist/Analytic-CZ8gfj2V.js +424 -0
  2. package/dist/{App-D8a5eW51.js → App-Da9h7lhI.js} +397 -384
  3. package/dist/{Broadcast-C8jgMe6g.js → Broadcast-m6ehTw7F.js} +32 -32
  4. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-pG8WvV4I.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BTKA2Ygl.js} +8 -8
  5. package/dist/Card-DqZveZ44.js +685 -0
  6. package/dist/{Collections-lMrdPUuM.js → Collections-XIY6SLgQ.js} +4 -4
  7. package/dist/{Credit-CJfU5tP4.js → Credit-B6Yg3_al.js} +14 -14
  8. package/dist/CustomSelect.vue_vue_type_script_setup_true_lang-DLnvDVgf.js +108 -0
  9. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-D1gub9ZP.js +2198 -0
  10. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-CzEtOmp0.js → EffectSheet.vue_vue_type_style_index_0_lang-tRUwA8zh.js} +8 -8
  11. package/dist/{Experience-Bp2ki8gU.js → Experience-CsoneWLZ.js} +8 -8
  12. package/dist/{Game-BpTf6ebE.js → Game-B029f9yE.js} +15 -15
  13. package/dist/Index-B2LvLfrR.js +226 -0
  14. package/dist/Marketing-DUTyDRXu.js +20070 -0
  15. package/dist/{Member-BSWyy32a.js → Member-CATybMaC.js} +4 -4
  16. package/dist/MemberList-DxvQ7DnC.js +1045 -0
  17. package/dist/{MemberTransactions-BzHiXCnp.js → MemberTransactions-fEZyBY9P.js} +1 -1
  18. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-e-zWg08J.js → MessageInput.vue_vue_type_script_setup_true_lang-BCCEsJZj.js} +2 -2
  19. package/dist/{Mission-8IGT3T2C.js → Mission-Cl3O0ULj.js} +16 -16
  20. package/dist/Overview-BVI2xGvT.js +1014 -0
  21. package/dist/{Point-CbbJ6ohd.js → Point-DSVn47pK.js} +23 -23
  22. package/dist/{Promotion-BYXCJa_S.js → Promotion-C4HyMpPg.js} +53 -47
  23. package/dist/Record-BSKXwUu2.js +187 -0
  24. package/dist/Reward-Cus20Wq5.js +399 -0
  25. package/dist/RewardGroup.vue_vue_type_script_setup_true_lang-Dm6Vgx8-.js +151 -0
  26. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-CqMCdTsv.js +1597 -0
  27. package/dist/Segment-DAHJ2FYV.js +567 -0
  28. package/dist/SelectItems.vue_vue_type_script_setup_true_lang-DpkIgpqy.js +181 -0
  29. package/dist/{Setting-CLpvvZTv.js → Setting-D7dKlTiZ.js} +8 -8
  30. package/dist/Store-DQdWn1Dw.js +1745 -0
  31. package/dist/{StoreRewards-CUM2irXK.js → StoreRewards-Cut9mJGn.js} +12 -12
  32. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-BQscw_Di.js +957 -0
  33. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-DEb4OBcX.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BVzz2Zkl.js} +1 -1
  34. package/dist/{Tier-DZTDxWBo.js → Tier-DGpNybHO.js} +15 -15
  35. package/dist/{Title-C2Dr5ceK.js → Title-D5y8GEwE.js} +15 -15
  36. package/dist/{Transaction-BL4mS29d.js → Transaction-CCnZouEv.js} +2 -2
  37. package/dist/UserRuleGroup.vue_vue_type_script_setup_true_lang-Cr9DV7hr.js +130 -0
  38. package/dist/{Voucher-Cx0r2-df.js → Voucher-BJ6RC4SS.js} +31 -31
  39. package/dist/VoucherEditor.vue_vue_type_script_setup_true_lang-6751WdaT.js +419 -0
  40. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-DWuAODUF.js → ZodTextField.vue_vue_type_script_setup_true_lang-aq-9V3Gc.js} +1 -1
  41. package/dist/{app-wE5HTF_Y.js → app-D3chCumI.js} +1279 -1282
  42. package/dist/{app-B_xuZ5HB.js → app-PfWyqx7U.js} +1 -1
  43. package/dist/app.js +1 -1
  44. package/dist/{business-DSv8zM8C.js → business-trsrJyHK.js} +1 -1
  45. package/dist/{campaign-7y5qquHZ.js → campaign-B1rgdv77.js} +2 -2
  46. package/dist/collectible.enum-ZoD0ya1M.js +19 -0
  47. package/dist/{collection.fn-BxVZQAx0.js → collection.fn-CnQjdokW.js} +2 -2
  48. package/dist/{dto-Ew1QwLci.js → dto-DuJumvC2.js} +12 -20
  49. package/dist/{effect-BzPh8fRI.js → effect-CFYktLyZ.js} +9 -9
  50. package/dist/email-addresses-BocLAqLt.js +705 -0
  51. package/dist/{export-C9tDplkA.js → export-BDxbvd3c.js} +3 -3
  52. package/dist/{helper-Sz7oQ0F4.js → helper-Bx6u7f_W.js} +1 -1
  53. package/dist/{index-DH_1nOJ_.js → index-7QsBQpBM.js} +39 -35
  54. package/dist/{index-z0IfdrZk.js → index-AcoIUTDS.js} +203 -195
  55. package/dist/{index-C3_4GUiI.js → index-BAUe6Mqp.js} +7 -1
  56. package/dist/{index-C0lpADCo.js → index-C20tnKDo.js} +1 -1
  57. package/dist/{index-C-SOz7jt.js → index-CDgSJNKm.js} +1 -1
  58. package/dist/{index-DBMaUGYI.js → index-CTnZ9dt0.js} +30 -26
  59. package/dist/index-CUMB0mpB.js +28997 -0
  60. package/dist/index-CsF6BSZU.js +1067 -0
  61. package/dist/index-CsaQJMAR.js +66 -0
  62. package/dist/{index-tv4t0Pnh.js → index-DwXHEi0X.js} +1 -1
  63. package/dist/{index-_3qBsogG.js → index-ZXWgygOr.js} +1500 -1479
  64. package/dist/index-_v_LQTuR.js +53 -0
  65. package/dist/index-kLMiwwB-.js +38 -0
  66. package/dist/{index-gIRszcHf.js → index-pRpTA8Kd.js} +1 -1
  67. package/dist/{index.esm2017-BnKJDxUo.js → index.esm2017-DuOZ7nuk.js} +33 -33
  68. package/dist/{loading-Ds-yFYhc.js → loading-BTEwnG5-.js} +591 -597
  69. package/dist/{membership-DaiVw9qF.js → membership-DkH7qw6W.js} +51 -43
  70. package/dist/money-BfCdj0Ts.js +15 -0
  71. package/dist/number-BKHcstZb.js +12 -0
  72. package/dist/objectid-CumRza_j.js +145 -0
  73. package/dist/remy-vue-client-Cpppk9h-.js +1693 -0
  74. package/dist/reward-DpR3xoxT.js +36 -0
  75. package/dist/{rule-Cd2M6Ri2.js → rule-Hb9_sJvP.js} +180 -177
  76. package/dist/{rule-builder-B6og27Q1.js → rule-builder-BhwlX4fv.js} +1 -1
  77. package/dist/style.css +1 -1
  78. package/dist/{template-DouRWBpv.js → template-PkDFDppy.js} +5 -5
  79. package/dist/trigger-vLHrldAH.js +114 -0
  80. package/dist/{vue-i18n-BTlOChXs.js → vue-i18n-ComnFt3O.js} +2 -2
  81. package/dist/{xlsx-SahfXQ70.js → xlsx-CsUJ1mq4.js} +1 -1
  82. package/package.json +8 -7
  83. package/dist/Analytic-DSD9TsKr.js +0 -622
  84. package/dist/Card-C1K7ULPo.js +0 -825
  85. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-BYoaa_-x.js +0 -2809
  86. package/dist/Marketing-BiKE2gxA.js +0 -316
  87. package/dist/MemberList-CHlGREyR.js +0 -1733
  88. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-Bruh-umZ.js +0 -1753
  89. package/dist/Segment-DXDNM0yd.js +0 -437
  90. package/dist/Store-C6-P6bwc.js +0 -1511
  91. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-JaRdmqif.js +0 -890
  92. package/dist/index-BQm0C3Jm.js +0 -298
  93. package/dist/index-CuvNtC_M.js +0 -61
  94. package/dist/index-D-2nFLsg.js +0 -762
  95. package/dist/index-Dy4pmQpt.js +0 -29193
  96. package/dist/money-BHtBdZoz.js +0 -15
  97. package/dist/number-CZhcB8ef.js +0 -12
@@ -0,0 +1,181 @@
1
+ import { defineComponent as N, computed as f, ref as V, onMounted as H, resolveComponent as _, openBlock as c, createElementBlock as u, createVNode as i, withCtx as S, createElementVNode as p, toDisplayString as q, normalizeClass as A, Fragment as b, renderList as j, createCommentVNode as B } from "vue";
2
+ import { e as D } from "./app-PfWyqx7U.js";
3
+ import "./loading-BTEwnG5-.js";
4
+ import { c as E } from "./object-qECH92oz.js";
5
+ const M = { class: "flex flex-col flex-nowrap" }, T = { class: "flex gap-16 items-center w-full" }, $ = { class: "flex grow items-center" }, z = { class: "grow text-fm-color-typo-secondary" }, K = { key: 0 }, J = { class: "px-16" }, X = /* @__PURE__ */ N({
6
+ __name: "SelectItems",
7
+ props: {
8
+ initialValue: {
9
+ type: Array,
10
+ default: () => []
11
+ },
12
+ filterItems: {
13
+ type: Function,
14
+ default: void 0
15
+ },
16
+ onComplete: {
17
+ type: Function,
18
+ required: !0
19
+ },
20
+ maxHeight: {
21
+ type: [String, Number],
22
+ default: 380
23
+ }
24
+ },
25
+ setup(F, { expose: O }) {
26
+ const m = F, x = D(), w = f(() => x.menu.value || {
27
+ _id: "",
28
+ modules: {
29
+ catalog: [],
30
+ category: [],
31
+ item: [],
32
+ variant: [],
33
+ group: [],
34
+ takeaway: [],
35
+ scheduler: [],
36
+ printDepartment: [],
37
+ recipe: [],
38
+ sku: [],
39
+ unit: [],
40
+ cookingGuide: [],
41
+ serveSequence: []
42
+ }
43
+ }), k = f(() => {
44
+ const n = m.filterItems ?? ((t) => !!t.category);
45
+ return w.value.modules.item.filter(n).reduce((t, l) => {
46
+ const a = {
47
+ id: l._id,
48
+ category: l.category,
49
+ name: (l.name2 || l.name).trim()
50
+ };
51
+ return t = [...t, a], t;
52
+ }, []);
53
+ }), C = f(() => {
54
+ const n = w.value.modules.category.reduce((e, t) => (e[t._id] = {
55
+ id: t._id,
56
+ name: t.name,
57
+ items: {}
58
+ }, e), {});
59
+ return k.value.reduce(
60
+ (e, t) => {
61
+ const l = t.category ?? "";
62
+ return e[l].items = {
63
+ ...e[l].items,
64
+ [t.id]: t
65
+ }, e;
66
+ },
67
+ {
68
+ ...n,
69
+ "": {
70
+ id: "",
71
+ name: "Addons",
72
+ items: {}
73
+ }
74
+ }
75
+ );
76
+ }), v = f(() => {
77
+ const n = y.value.toLowerCase();
78
+ return n ? Object.entries(C.value).reduce((e, [t, l]) => {
79
+ if (l.name.toLowerCase().includes(n))
80
+ return e[t] = l, e;
81
+ const a = Object.entries(l.items).reduce((d, [h, o]) => (o.name.toLowerCase().includes(n) && (d[h] = o), d), {});
82
+ return Object.keys(a).length > 0 && (e[t] = { ...l, items: a }), e;
83
+ }, {}) : C.value;
84
+ }), s = V({}), y = V(""), G = f(() => Object.values(s.value).filter((n) => !!n).length);
85
+ function I(n) {
86
+ s.value = k.value.reduce((e, t) => (e[t.id] = n.includes(t.id), e), {});
87
+ }
88
+ H(async () => {
89
+ await x.getMenu(), I(m.initialValue);
90
+ });
91
+ function g(n) {
92
+ const e = Object.keys(v.value[n].items), t = e.filter((l) => s.value[l]);
93
+ return t.length ? t.length === e.length ? !0 : null : !1;
94
+ }
95
+ function U(n) {
96
+ const e = Object.keys(v.value[n].items), t = g(n), l = E(s.value);
97
+ for (const a of e)
98
+ l[a] = t !== !0;
99
+ s.value = l;
100
+ }
101
+ function L(n) {
102
+ s.value[n] = !s.value[n];
103
+ }
104
+ return O({
105
+ onConfirm: () => {
106
+ const n = Object.entries(s.value).filter(([, e]) => !!e).map(([e]) => e);
107
+ m.onComplete(n);
108
+ }
109
+ }), (n, e) => {
110
+ const t = _("fm-button"), l = _("FmTextField"), a = _("fm-list-item"), d = _("fm-checkbox"), h = _("fm-list");
111
+ return c(), u("div", M, [
112
+ i(a, {
113
+ tag: "div",
114
+ clickable: !1
115
+ }, {
116
+ default: S(() => [
117
+ p("div", T, [
118
+ p("div", $, [
119
+ i(t, {
120
+ icon: "sync",
121
+ variant: "tertiary",
122
+ onClick: e[0] || (e[0] = () => I([]))
123
+ }),
124
+ p("span", z, q(G.value) + " product(s) selected ", 1)
125
+ ]),
126
+ i(l, {
127
+ modelValue: y.value,
128
+ "onUpdate:modelValue": e[1] || (e[1] = (o) => y.value = o),
129
+ placeholder: "Search",
130
+ "leading-icon": { name: "search", color: "" },
131
+ style: { width: "200px", "min-width": "200px" }
132
+ }, null, 8, ["modelValue"])
133
+ ])
134
+ ]),
135
+ _: 1
136
+ }),
137
+ i(h, {
138
+ class: A(["grow overflow-y-auto", `max-h-${m.maxHeight ? `[${m.maxHeight}px]` : "full"}`])
139
+ }, {
140
+ default: S(() => [
141
+ (c(!0), u(b, null, j(v.value, (o) => (c(), u(b, {
142
+ key: o.id
143
+ }, [
144
+ Object.keys(o.items).length > 0 ? (c(), u("div", K, [
145
+ p("div", J, [
146
+ i(d, {
147
+ "model-value": g(o.id) ?? !1,
148
+ indeterminate: g(o.id) === null,
149
+ label: o.name,
150
+ value: "",
151
+ name: "",
152
+ sublabel: "",
153
+ class: "w-full",
154
+ "onUpdate:modelValue": () => U(o.id)
155
+ }, null, 8, ["model-value", "indeterminate", "label", "onUpdate:modelValue"])
156
+ ]),
157
+ (c(!0), u(b, null, j(o.items, (r) => (c(), u("div", {
158
+ key: r.id,
159
+ class: "pl-48"
160
+ }, [
161
+ i(d, {
162
+ "model-value": s.value[r.id],
163
+ label: r.name,
164
+ value: r.id,
165
+ name: r.name,
166
+ class: "w-full",
167
+ "onUpdate:modelValue": () => L(r.id)
168
+ }, null, 8, ["model-value", "label", "value", "name", "onUpdate:modelValue"])
169
+ ]))), 128))
170
+ ])) : B("", !0)
171
+ ], 64))), 128))
172
+ ]),
173
+ _: 1
174
+ }, 8, ["class"])
175
+ ]);
176
+ };
177
+ }
178
+ });
179
+ export {
180
+ X as _
181
+ };
@@ -2,16 +2,16 @@ import { defineComponent as He, ref as H, computed as se, onMounted as Ke, resol
2
2
  import { h as dt } from "./moment-BWErdI6_.js";
3
3
  import { Z as ke } from "./zod-Bg2FbC-D.js";
4
4
  import { useDialog as Ye } from "@feedmepos/ui-library";
5
- import { a as je, u as ft, p as mt, f as K } from "./loading-Ds-yFYhc.js";
5
+ import { a as je, u as ft, p as mt, f as K } from "./loading-BTEwnG5-.js";
6
6
  import { u as gt } from "./app-wDQR6dpb.js";
7
- import { u as ve, l as Je } from "./business-DSv8zM8C.js";
8
- import { u as qe } from "./membership-DaiVw9qF.js";
9
- import { m as ht, l as pt } from "./index-D-2nFLsg.js";
7
+ import { u as ve, l as Je } from "./business-trsrJyHK.js";
8
+ import { u as qe } from "./membership-DkH7qw6W.js";
9
+ import { t as ht, k as pt } from "./index-CsF6BSZU.js";
10
10
  import { _ as Ve } from "./ImageInput.vue_vue_type_script_setup_true_lang-rWUkV9gn.js";
11
- import { _ as yt } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-DEb4OBcX.js";
12
- import { _ as wt } from "./MessageInput.vue_vue_type_script_setup_true_lang-e-zWg08J.js";
13
- import { u as bt } from "./vue-i18n-BTlOChXs.js";
14
- import { m as vt } from "./index-C3_4GUiI.js";
11
+ import { _ as yt } from "./TargetLocationInput.vue_vue_type_script_setup_true_lang-BVzz2Zkl.js";
12
+ import { _ as wt } from "./MessageInput.vue_vue_type_script_setup_true_lang-BCCEsJZj.js";
13
+ import { u as bt } from "./vue-i18n-ComnFt3O.js";
14
+ import { m as vt } from "./index-BAUe6Mqp.js";
15
15
  import { o as Ct } from "./objectId-dwaoBfJX.js";
16
16
  import { a as Et } from "./object-qECH92oz.js";
17
17
  var ee = {}, Bt = function() {