@feedmepos/mf-menu 0.32.61-dev.3 → 0.32.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{App-TgWTfhbY.js → App-CE4fZP2_.js} +7 -7
- package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-BeW-aCRL.js → ApplyProduct.vue_vue_type_script_setup_true_lang-PpYjjdOP.js} +3 -3
- package/dist/{ApplyProductDialog.vue_vue_type_script_setup_true_lang-C8il14gy.js → ApplyProductDialog.vue_vue_type_script_setup_true_lang-C_JKiJRD.js} +2 -2
- package/dist/{Catalog-hnhpn9Of.js → Catalog-C2MyXkps.js} +6 -6
- package/dist/{Category-DIubPG8Y.js → Category-B7Uxbyug.js} +4 -4
- package/dist/{Category-wXfspM5v.js → Category-BoV0MYQp.js} +4 -4
- package/dist/{CookingGuide-CR1cBZ3S.js → CookingGuide-Bdyj8XMv.js} +4 -4
- package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-DlpZfbx-.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-EDbgLHTU.js} +1 -1
- package/dist/{Group-DbG3cLfp.js → Group-BuFbi0Z-.js} +3 -3
- package/dist/{Group-DTzbprcr.js → Group-DYpxc5ui.js} +1 -1
- package/dist/{Group.vue_vue_type_script_setup_true_lang-CMEdW613.js → Group.vue_vue_type_script_setup_true_lang-B5Uw2Rzm.js} +6 -6
- package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-aLcNgJLb.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-COYg8e7h.js} +5 -5
- package/dist/{ImportProductDialog.vue_vue_type_script_setup_true_lang-CnChdePY.js → ImportProductDialog.vue_vue_type_script_setup_true_lang-YY25YW4B.js} +7 -7
- package/dist/{Ingredient-BBGzGfS2.js → Ingredient-Ddw06I0B.js} +3 -3
- package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-B9CfZ7oA.js → InventoryBinding.vue_vue_type_script_setup_true_lang-CsWdL5Lz.js} +2 -2
- package/dist/{LinkProductSideSheet-CLd4LEy4.js → LinkProductSideSheet-COAMZqOM.js} +3 -3
- package/dist/{MenuSetting-BuS9_e0y.js → MenuSetting--G1_lGoV.js} +6 -6
- package/dist/{OrderPacing-2QPouAql.js → OrderPacing-DnvLJh5M.js} +5 -5
- package/dist/{PrintRoute-D-SiyoaP.js → PrintRoute-CP-3JGP3.js} +4 -4
- package/dist/{Product-nmlc3rrr.js → Product-D-q15-Qw.js} +1 -1
- package/dist/{Product.vue_vue_type_script_setup_true_lang-DYn_bqcn.js → Product.vue_vue_type_script_setup_true_lang-BaOg60Q6.js} +12 -12
- package/dist/{ProductInternalTools-BgDSe1XP.js → ProductInternalTools-wYn0bzml.js} +6 -6
- package/dist/{Products-BPa6wC-o.js → Products-CxEsB-7l.js} +35 -35
- package/dist/{Publish-DbI1wemN.js → Publish-BCljLztW.js} +3 -3
- package/dist/{Recipe-CAgscHCL.js → Recipe-DgfobgnQ.js} +4 -4
- package/dist/{RestaurantAttributesSelector.vue_vue_type_script_setup_true_lang-DNG5WX4W.js → RestaurantAttributesSelector.vue_vue_type_script_setup_true_lang-BgDVFKRI.js} +1 -1
- package/dist/{RuleView.vue_vue_type_script_setup_true_lang-DNk48PUl.js → RuleView.vue_vue_type_script_setup_true_lang-DCbrAMxd.js} +503 -503
- package/dist/{Scheduler-C8TXHcb2.js → Scheduler-C-LJs7Gl.js} +3 -3
- package/dist/{ServingSequence-CQzQWvUA.js → ServingSequence-BoaDRfsc.js} +3 -3
- package/dist/{Setting-gun4ZUQ4.js → Setting-BfFqBD9u.js} +5 -5
- package/dist/{Subcategory-CqcWpp94.js → Subcategory-BsnC9ZSS.js} +5 -5
- package/dist/{Takeaway-DV_ND3Ts.js → Takeaway-PilRifJP.js} +1 -1
- package/dist/{Takeaway-DsRU9wBO.js → Takeaway-dSEAc70g.js} +4 -4
- package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-GMA7-Hrb.js → Takeaway.vue_vue_type_script_setup_true_lang-CgioM0sV.js} +5 -5
- package/dist/{Thumbnail.vue_vue_type_script_setup_true_lang-C5hn1NYM.js → Thumbnail.vue_vue_type_script_setup_true_lang-DGqao47l.js} +4 -4
- package/dist/{TranslationFieldSection.vue_vue_type_script_setup_true_lang-DAwsbPs4.js → TranslationFieldSection.vue_vue_type_script_setup_true_lang-CHf3g1ia.js} +1 -1
- package/dist/{TranslationSideSheet.vue_vue_type_script_setup_true_lang-DYVBVDBy.js → TranslationSideSheet.vue_vue_type_script_setup_true_lang-A43XxqyC.js} +2 -2
- package/dist/{TreeEditorOpenner.vue_vue_type_script_setup_true_lang-BFUOqfDO.js → TreeEditorOpenner.vue_vue_type_script_setup_true_lang-DY1umres.js} +14 -14
- package/dist/{Unit-BcPn6opY.js → Unit-DW1dFJas.js} +2 -2
- package/dist/{Variant-Wkd9mHWk.js → Variant-CzLzrt2N.js} +3 -3
- package/dist/{_id_-CuOgqnZ3.js → _id_-qfASfKMD.js} +9 -9
- package/dist/{app-BsNMWUZ9.js → app-BB33yKM6.js} +32 -32
- package/dist/{app-kS8tUq_w.js → app-CJnEQz-U.js} +1 -1
- package/dist/app.js +1 -1
- package/dist/assets/{override-menu-cifFGmrk.js → linked-status-VaVE9Pyh.js} +4 -4
- package/dist/assets/{menu-export-Bd2A9o3e.js → menu-export-DD9Zt6XH.js} +3 -3
- package/dist/assets/{linked-status-CHvHJGH9.js → override-menu-DZCgrhuF.js} +4 -4
- package/dist/assets/{validate-menu-B8cp1kCt.js → validate-menu-BFsQlikL.js} +3 -3
- package/dist/{catalog-BxfmkFrE.js → catalog-Cvn1ZMGp.js} +1 -1
- package/dist/{catalogSetting-ebS4mr1i.js → catalogSetting-D2bOCGW7.js} +1 -1
- package/dist/{currency-BM5m7MDE.js → currency-DQDsuXB5.js} +1 -1
- package/dist/{dayjs.min-X4vHGjJn.js → dayjs.min-CzUkrXIR.js} +2 -2
- package/dist/{index-CUrfs4iN.js → index-B2fxLO4K.js} +4 -4
- package/dist/{index-BxvnAb0l.js → index-CizrxT_e.js} +5 -5
- package/dist/{index.vue_vue_type_script_setup_true_lang-C3c2B-qJ.js → index.vue_vue_type_script_setup_true_lang-gaRM4vfS.js} +652 -652
- package/dist/{item-26-Gw7Ug.js → item-DOHVD6CN.js} +18 -18
- package/dist/{jszip.min-DccvCJln.js → jszip.min-BXLegUsz.js} +167 -167
- package/dist/{memberPricing-FatZi_6k.js → memberPricing-CizI1rUM.js} +1 -1
- package/dist/{menu-DcPMF0nf.js → menu-BCed1YCE.js} +1 -1
- package/dist/{menuV2-CVo-19H-.js → menuV2-Bo9AHrdr.js} +149 -149
- package/dist/{order_pacing-CWDYwJcW.js → order_pacing-BkfQeNeC.js} +5 -5
- package/dist/{priceTier-C58Ixr5m.js → priceTier-rjuK-b6U.js} +1 -1
- package/dist/{rules-DwomOoC9.js → rules-DHX_hK6G.js} +3 -3
- package/dist/{scheduler-CJcxPgeF.js → scheduler-BsfPbtM2.js} +4 -4
- package/dist/{toExcel-DjWt9SEm.js → toExcel-DJHljg_L.js} +2 -2
- package/dist/{unit-KhTILQfe.js → unit-BxTWR1dZ.js} +2 -2
- package/package.json +1 -1
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
var We = Object.defineProperty;
|
|
2
|
-
var
|
|
3
|
-
var ne = (e, t, n) =>
|
|
4
|
-
import { I as ae, G as C, A as T, U as ue, az as re, J as
|
|
5
|
-
import { defineStore as
|
|
6
|
-
import { shallowRef as j, ref as
|
|
2
|
+
var Le = (e, t, n) => t in e ? We(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var ne = (e, t, n) => Le(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { I as ae, G as C, A as T, U as ue, az as re, J as H, H as ie, aj as x, c as L, a0 as D, au as oe, aA as ze, aB as qe, z as He, am as Be, aC as Ge, aD as Je, ah as Ye } from "./index.vue_vue_type_script_setup_true_lang-gaRM4vfS.js";
|
|
5
|
+
import { defineStore as Ze } from "pinia";
|
|
6
|
+
import { shallowRef as j, ref as B, computed as S, shallowReactive as Qe, effectScope as Xe, watch as et } from "vue";
|
|
7
7
|
import { useCoreStore as se } from "@feedmepos/mf-common";
|
|
8
8
|
import { useSnackbar as tt } from "@feedmepos/ui-library";
|
|
9
|
-
const nt = "/assets/linked-status-
|
|
9
|
+
const nt = "/assets/linked-status-VaVE9Pyh.js", rt = "/assets/override-menu-DZCgrhuF.js";
|
|
10
10
|
function ot(e) {
|
|
11
11
|
var s;
|
|
12
12
|
const t = C(e), n = (s = t.variant) == null ? void 0 : s.variantCombinations;
|
|
13
13
|
return delete t.variant, delete t.thumbnail, [t, ...n || []];
|
|
14
14
|
}
|
|
15
15
|
function st(e, t, n, s) {
|
|
16
|
-
const o = C(t), u = n ? o.modules.catalog.find((f) => f._id === n) : null, l = s ? o.modules.scheduler.find((f) => f._id === s) : null, a = u ? C(u) : void 0, d = n ? o.modules.catalog.filter((f) => f._id !== n) : [], c = l ? C(l) : void 0,
|
|
16
|
+
const o = C(t), u = n ? o.modules.catalog.find((f) => f._id === n) : null, l = s ? o.modules.scheduler.find((f) => f._id === s) : null, a = u ? C(u) : void 0, d = n ? o.modules.catalog.filter((f) => f._id !== n) : [], c = l ? C(l) : void 0, h = e.reduce((f, v) => (f[v._id] = ot(v), f), {});
|
|
17
17
|
function y(f = []) {
|
|
18
|
-
const v = e.map((
|
|
18
|
+
const v = e.map((g) => g._id);
|
|
19
19
|
return [
|
|
20
|
-
...f.filter((
|
|
21
|
-
...Object.values(
|
|
20
|
+
...f.filter((g) => !v.includes(g._id)),
|
|
21
|
+
...Object.values(h).flatMap((g) => g)
|
|
22
22
|
];
|
|
23
23
|
}
|
|
24
24
|
return a && s ? (a.override.scheduler = {
|
|
@@ -33,7 +33,7 @@ function st(e, t, n, s) {
|
|
|
33
33
|
}
|
|
34
34
|
}, o.modules.catalog = [...d, a], o) : a ? (a.override.items = {
|
|
35
35
|
...a.override.items,
|
|
36
|
-
...
|
|
36
|
+
...h
|
|
37
37
|
}, o.modules.catalog = [...d, a], o) : c ? (c.items = y(c.items), o.modules.scheduler = [
|
|
38
38
|
...o.modules.scheduler.filter((f) => f._id !== s),
|
|
39
39
|
c
|
|
@@ -56,12 +56,12 @@ function F(e, t, n) {
|
|
|
56
56
|
if (!s)
|
|
57
57
|
throw new Error(`_insertItemOverriders - Item not found - ${e._id}`);
|
|
58
58
|
const o = (u = s.groups) == null ? void 0 : u.map((l) => {
|
|
59
|
-
var c,
|
|
59
|
+
var c, h, y;
|
|
60
60
|
const a = (c = e == null ? void 0 : e.groups) == null ? void 0 : c.find((f) => f._id === l._id);
|
|
61
61
|
let d;
|
|
62
|
-
return a ? d = ((
|
|
63
|
-
var
|
|
64
|
-
const v = (
|
|
62
|
+
return a ? d = ((h = l.items) == null ? void 0 : h.map((f) => {
|
|
63
|
+
var g;
|
|
64
|
+
const v = (g = a.items) == null ? void 0 : g.find(
|
|
65
65
|
(b) => b._id === f._id && b.combinationKey === f.combinationKey
|
|
66
66
|
);
|
|
67
67
|
return F(v || f, t, n + 1);
|
|
@@ -87,12 +87,12 @@ function at(e, t) {
|
|
|
87
87
|
);
|
|
88
88
|
if (c)
|
|
89
89
|
return F(c, t, 1);
|
|
90
|
-
const
|
|
90
|
+
const h = {
|
|
91
91
|
...T.generator.initMenuV4ItemOverrider(),
|
|
92
92
|
_id: d._id,
|
|
93
93
|
combinationKey: d.combinationKey
|
|
94
94
|
};
|
|
95
|
-
return F(
|
|
95
|
+
return F(h, t, 1);
|
|
96
96
|
});
|
|
97
97
|
return { ...u, items: a };
|
|
98
98
|
}), s = e.variant ? e.variant.variantCombinations.map((u) => F(u, t, 1)) : [], o = {
|
|
@@ -104,7 +104,7 @@ function at(e, t) {
|
|
|
104
104
|
};
|
|
105
105
|
return [...s, o];
|
|
106
106
|
}
|
|
107
|
-
function
|
|
107
|
+
function G(e, t) {
|
|
108
108
|
var s;
|
|
109
109
|
if (!t)
|
|
110
110
|
return e;
|
|
@@ -113,11 +113,11 @@ function B(e, t) {
|
|
|
113
113
|
var l, a;
|
|
114
114
|
const u = (l = t.groups) == null ? void 0 : l.find((d) => d._id === o._id);
|
|
115
115
|
return o.items = (a = o.items) == null ? void 0 : a.map((d) => {
|
|
116
|
-
var
|
|
117
|
-
const c = (
|
|
116
|
+
var h;
|
|
117
|
+
const c = (h = u == null ? void 0 : u.items) == null ? void 0 : h.find(
|
|
118
118
|
(y) => y._id === d._id && y.combinationKey === d.combinationKey
|
|
119
119
|
);
|
|
120
|
-
return
|
|
120
|
+
return G(d, c);
|
|
121
121
|
}), o;
|
|
122
122
|
}), n;
|
|
123
123
|
}
|
|
@@ -131,7 +131,7 @@ function ut(e, t) {
|
|
|
131
131
|
);
|
|
132
132
|
if (!u)
|
|
133
133
|
throw new Error(`Item overrider not found - ${o._id} - ${o.combinationKey}`);
|
|
134
|
-
return
|
|
134
|
+
return G(u, o);
|
|
135
135
|
})
|
|
136
136
|
});
|
|
137
137
|
const s = n.find((o) => !o.combinationKey);
|
|
@@ -143,20 +143,20 @@ function ut(e, t) {
|
|
|
143
143
|
return o.items = (l = o.items) == null ? void 0 : l.map((a) => {
|
|
144
144
|
var c;
|
|
145
145
|
const d = (c = u == null ? void 0 : u.items) == null ? void 0 : c.find(
|
|
146
|
-
(
|
|
146
|
+
(h) => h._id === a._id && h.combinationKey === a.combinationKey
|
|
147
147
|
);
|
|
148
|
-
return
|
|
148
|
+
return G(a, d);
|
|
149
149
|
}), o;
|
|
150
150
|
}), {
|
|
151
151
|
...t,
|
|
152
152
|
price: (s == null ? void 0 : s.price) || t.price
|
|
153
153
|
};
|
|
154
154
|
}
|
|
155
|
-
async function
|
|
155
|
+
async function Vt(e, t, n, s, o, u = !0) {
|
|
156
156
|
const l = C(n), a = u ? st(t, l, s, o) : l, d = t.reduce((y, f) => (y[f._id] = a.modules.item.find((v) => v._id === f._id), y), {}), c = t.reduce((y, f) => {
|
|
157
157
|
const v = f._id;
|
|
158
158
|
return y[v] = at(d[v], e), y;
|
|
159
|
-
}, {}),
|
|
159
|
+
}, {}), h = T.getFallbackPrices({
|
|
160
160
|
rawMenu: a,
|
|
161
161
|
items: c,
|
|
162
162
|
catalogId: s || void 0,
|
|
@@ -165,29 +165,29 @@ async function Dt(e, t, n, s, o, u = !0) {
|
|
|
165
165
|
return t.map((y) => {
|
|
166
166
|
const f = y._id, v = d[f];
|
|
167
167
|
return {
|
|
168
|
-
...ut(
|
|
168
|
+
...ut(h, v),
|
|
169
169
|
category: s || o ? v == null ? void 0 : v.category : null
|
|
170
170
|
};
|
|
171
171
|
});
|
|
172
172
|
}
|
|
173
|
-
function
|
|
173
|
+
function Dt(e, t) {
|
|
174
174
|
if (e.length === 0) return "";
|
|
175
175
|
const n = e == null ? void 0 : e.split("variant");
|
|
176
176
|
return ((n == null ? void 0 : n.reduce((o, u) => {
|
|
177
177
|
if (u && u.length > 0) {
|
|
178
178
|
const l = `variant${u.split("/")[0]}`, a = u.split("/")[1], c = t.find(
|
|
179
|
-
({ _id:
|
|
180
|
-
).options.find(({ _id:
|
|
179
|
+
({ _id: h }) => h === l
|
|
180
|
+
).options.find(({ _id: h }) => h === a);
|
|
181
181
|
o.push(((c == null ? void 0 : c.name) || "").trim());
|
|
182
182
|
}
|
|
183
183
|
return o;
|
|
184
184
|
}, [])) || []).join(" / ");
|
|
185
185
|
}
|
|
186
|
-
const
|
|
186
|
+
const z = /* @__PURE__ */ new Map();
|
|
187
187
|
async function Tt(e, t) {
|
|
188
188
|
const n = `${e._id}-${e.updatedAt}-${t}`;
|
|
189
|
-
if (
|
|
190
|
-
return
|
|
189
|
+
if (z.has(n))
|
|
190
|
+
return z.get(n);
|
|
191
191
|
const s = await ae(
|
|
192
192
|
nt,
|
|
193
193
|
JSON.stringify({
|
|
@@ -195,7 +195,7 @@ async function Tt(e, t) {
|
|
|
195
195
|
itemId: t
|
|
196
196
|
})
|
|
197
197
|
);
|
|
198
|
-
return
|
|
198
|
+
return z.set(n, s), s;
|
|
199
199
|
}
|
|
200
200
|
async function ce(e, t, n) {
|
|
201
201
|
return await ae(rt, {
|
|
@@ -204,30 +204,30 @@ async function ce(e, t, n) {
|
|
|
204
204
|
schedulerId: n
|
|
205
205
|
});
|
|
206
206
|
}
|
|
207
|
-
const
|
|
207
|
+
const q = /* @__PURE__ */ new Map();
|
|
208
208
|
async function it(e, t, n) {
|
|
209
209
|
const s = `${e._id}-${e.updatedAt}-${t || "null"}-${n || "null"}`;
|
|
210
|
-
if (
|
|
211
|
-
return
|
|
210
|
+
if (q.has(s))
|
|
211
|
+
return q.get(s);
|
|
212
212
|
const o = await ce(e, t, n);
|
|
213
|
-
return
|
|
213
|
+
return q.set(s, o), o;
|
|
214
214
|
}
|
|
215
|
-
async function
|
|
215
|
+
async function Pt(e, t, n) {
|
|
216
216
|
var l, a;
|
|
217
217
|
const s = await it(e, t, null), o = [], u = (d, c) => {
|
|
218
|
-
const
|
|
218
|
+
const h = C(d);
|
|
219
219
|
for (const y in c)
|
|
220
|
-
c[y] && (
|
|
221
|
-
return
|
|
220
|
+
c[y] && (h[y] = c[y]);
|
|
221
|
+
return h;
|
|
222
222
|
};
|
|
223
223
|
for (const d of s.modules.group) {
|
|
224
|
-
const c = (l = d.items) == null ? void 0 : l.find((y) => y._id === n && !y.combinationKey),
|
|
224
|
+
const c = (l = d.items) == null ? void 0 : l.find((y) => y._id === n && !y.combinationKey), h = e.modules.item.find((y) => y._id === n);
|
|
225
225
|
if (c) {
|
|
226
226
|
const y = (a = d.items) == null ? void 0 : a.filter((v) => v._id === n && v.combinationKey), f = [c, ...y].map((v) => {
|
|
227
227
|
var M, I;
|
|
228
|
-
const
|
|
228
|
+
const g = v.combinationKey ? (I = (M = h == null ? void 0 : h.variant) == null ? void 0 : M.variantCombinations) == null ? void 0 : I.find(
|
|
229
229
|
(E) => E.combinationKey === v.combinationKey
|
|
230
|
-
) :
|
|
230
|
+
) : h, b = g && h ? u(h, g) : v;
|
|
231
231
|
return u(b, v);
|
|
232
232
|
});
|
|
233
233
|
o.push({
|
|
@@ -238,7 +238,7 @@ async function Kt(e, t, n) {
|
|
|
238
238
|
}
|
|
239
239
|
return o;
|
|
240
240
|
}
|
|
241
|
-
const w = 0,
|
|
241
|
+
const w = 0, P = 3;
|
|
242
242
|
function ct(e) {
|
|
243
243
|
const t = /^\/(.*)\/([gimyu]*)$/.exec(e.toString());
|
|
244
244
|
if (!t)
|
|
@@ -267,7 +267,7 @@ function $(e) {
|
|
|
267
267
|
function k(e) {
|
|
268
268
|
return typeof e == "object" && e !== null && !Array.isArray(e) && !(e instanceof Date) && !(e instanceof RegExp);
|
|
269
269
|
}
|
|
270
|
-
function
|
|
270
|
+
function K(e, t) {
|
|
271
271
|
if (e === t) return !0;
|
|
272
272
|
if (typeof e != typeof t) return !1;
|
|
273
273
|
if (e instanceof Date && t instanceof Date)
|
|
@@ -277,14 +277,14 @@ function P(e, t) {
|
|
|
277
277
|
if (Array.isArray(e) && Array.isArray(t)) {
|
|
278
278
|
if (e.length !== t.length) return !1;
|
|
279
279
|
for (let n = 0; n < e.length; n++)
|
|
280
|
-
if (!
|
|
280
|
+
if (!K(e[n], t[n])) return !1;
|
|
281
281
|
return !0;
|
|
282
282
|
}
|
|
283
283
|
if (k(e) && k(t)) {
|
|
284
284
|
const n = Object.keys(e), s = Object.keys(t);
|
|
285
285
|
if (n.length !== s.length) return !1;
|
|
286
286
|
for (const o of n)
|
|
287
|
-
if (!Object.prototype.hasOwnProperty.call(t, o) || !
|
|
287
|
+
if (!Object.prototype.hasOwnProperty.call(t, o) || !K(e[o], t[o])) return !1;
|
|
288
288
|
return !0;
|
|
289
289
|
}
|
|
290
290
|
return !1;
|
|
@@ -297,10 +297,10 @@ function lt(e, t, n) {
|
|
|
297
297
|
}
|
|
298
298
|
const l = [], a = /* @__PURE__ */ new Set();
|
|
299
299
|
for (let d = 0; d < s; d++) {
|
|
300
|
-
const c = e[d],
|
|
300
|
+
const c = e[d], h = n ? n(c) : JSON.stringify(c), y = u.get(h);
|
|
301
301
|
if (y) {
|
|
302
302
|
for (const f of y)
|
|
303
|
-
if (!a.has(f) &&
|
|
303
|
+
if (!a.has(f) && K(c, t[f])) {
|
|
304
304
|
l.push({ leftIndex: d, rightIndex: f }), a.add(f);
|
|
305
305
|
break;
|
|
306
306
|
}
|
|
@@ -310,59 +310,59 @@ function lt(e, t, n) {
|
|
|
310
310
|
}
|
|
311
311
|
function dt(e, t, n) {
|
|
312
312
|
var f, v;
|
|
313
|
-
if (
|
|
313
|
+
if (K(e, t)) return;
|
|
314
314
|
const s = { _t: "a" }, o = ((f = n == null ? void 0 : n.arrays) == null ? void 0 : f.detectMove) !== !1, u = ((v = n == null ? void 0 : n.arrays) == null ? void 0 : v.includeValueOnMove) === !0, l = n == null ? void 0 : n.objectHash;
|
|
315
315
|
let a = o ? lt(e, t, l) : [];
|
|
316
316
|
if (!l && e.length === t.length && e.length > 0 && a.length < e.length) {
|
|
317
|
-
const
|
|
318
|
-
if (
|
|
317
|
+
const g = k(e[0]) || Array.isArray(e[0]), b = a.length > 0;
|
|
318
|
+
if (g || b) {
|
|
319
319
|
a = [];
|
|
320
320
|
for (let M = 0; M < e.length; M++)
|
|
321
321
|
a.push({ leftIndex: M, rightIndex: M });
|
|
322
322
|
}
|
|
323
323
|
}
|
|
324
|
-
new Set(a.map((
|
|
325
|
-
const d = new Set(a.map((
|
|
326
|
-
for (const
|
|
327
|
-
c.set(
|
|
328
|
-
for (let
|
|
329
|
-
const b = c.get(
|
|
324
|
+
new Set(a.map((g) => g.leftIndex));
|
|
325
|
+
const d = new Set(a.map((g) => g.rightIndex)), c = /* @__PURE__ */ new Map(), h = /* @__PURE__ */ new Map();
|
|
326
|
+
for (const g of a)
|
|
327
|
+
c.set(g.leftIndex, g.rightIndex), h.set(g.rightIndex, g.leftIndex);
|
|
328
|
+
for (let g = 0; g < e.length; g++) {
|
|
329
|
+
const b = c.get(g);
|
|
330
330
|
if (b !== void 0) {
|
|
331
|
-
const M = J(e[
|
|
332
|
-
if (M !== void 0 && (s[b] = M), o && b !==
|
|
333
|
-
const I = `_${
|
|
331
|
+
const M = J(e[g], t[b], n);
|
|
332
|
+
if (M !== void 0 && (s[b] = M), o && b !== g) {
|
|
333
|
+
const I = `_${g}`, E = u ? [e[g], b, P] : ["", b, P];
|
|
334
334
|
s[I] = E;
|
|
335
335
|
}
|
|
336
336
|
} else {
|
|
337
|
-
const M = `_${
|
|
338
|
-
s[M] = [e[
|
|
337
|
+
const M = `_${g}`;
|
|
338
|
+
s[M] = [e[g], w, w];
|
|
339
339
|
}
|
|
340
340
|
}
|
|
341
|
-
for (let
|
|
342
|
-
d.has(
|
|
341
|
+
for (let g = 0; g < t.length; g++)
|
|
342
|
+
d.has(g) || (s[g] = [t[g]]);
|
|
343
343
|
const y = Object.keys(s);
|
|
344
344
|
if (!(y.length === 1 && y[0] === "_t"))
|
|
345
345
|
return s;
|
|
346
346
|
}
|
|
347
347
|
function mt(e, t, n) {
|
|
348
|
-
if (
|
|
348
|
+
if (K(e, t)) return;
|
|
349
349
|
const s = {}, o = Object.keys(e), u = Object.keys(t), l = /* @__PURE__ */ new Set([...o, ...u]);
|
|
350
350
|
for (const a of l) {
|
|
351
351
|
if (n != null && n.propertyFilter && !n.propertyFilter(a, { left: e, right: t }))
|
|
352
352
|
continue;
|
|
353
353
|
const d = Object.prototype.hasOwnProperty.call(e, a), c = Object.prototype.hasOwnProperty.call(t, a);
|
|
354
354
|
if (d && c) {
|
|
355
|
-
const
|
|
356
|
-
|
|
355
|
+
const h = J(e[a], t[a], n);
|
|
356
|
+
h !== void 0 && (s[a] = h);
|
|
357
357
|
} else if (d && !c) {
|
|
358
|
-
const
|
|
359
|
-
s[a] = [
|
|
358
|
+
const h = n != null && n.omitRemovedValues ? 0 : e[a];
|
|
359
|
+
s[a] = [h, w, w];
|
|
360
360
|
} else !d && c && (s[a] = [t[a]]);
|
|
361
361
|
}
|
|
362
362
|
return Object.keys(s).length > 0 ? s : void 0;
|
|
363
363
|
}
|
|
364
364
|
function J(e, t, n) {
|
|
365
|
-
if (
|
|
365
|
+
if (K(e, t)) return;
|
|
366
366
|
if (e === void 0 && t !== void 0) {
|
|
367
367
|
const a = n != null && n.cloneDiffValues ? O(t) : t;
|
|
368
368
|
return [$(a)];
|
|
@@ -386,7 +386,7 @@ function vt(e, t, n) {
|
|
|
386
386
|
for (const a in t) {
|
|
387
387
|
if (a === "_t" || !a.startsWith("_")) continue;
|
|
388
388
|
const d = parseInt(a.slice(1)), c = t[a];
|
|
389
|
-
Array.isArray(c) && (c.length === 3 && c[2] === w ? s.add(d) : c.length === 3 && c[2] ===
|
|
389
|
+
Array.isArray(c) && (c.length === 3 && c[2] === w ? s.add(d) : c.length === 3 && c[2] === P && o.set(d, c[1]));
|
|
390
390
|
}
|
|
391
391
|
const u = [];
|
|
392
392
|
let l = 0;
|
|
@@ -401,13 +401,13 @@ function vt(e, t, n) {
|
|
|
401
401
|
l < e.length && (u.push(Y(e[l], c)), l++);
|
|
402
402
|
}
|
|
403
403
|
else {
|
|
404
|
-
let
|
|
404
|
+
let h = !1;
|
|
405
405
|
for (const [y, f] of o.entries())
|
|
406
406
|
if (f === a) {
|
|
407
|
-
u.push(e[y]),
|
|
407
|
+
u.push(e[y]), h = !0;
|
|
408
408
|
break;
|
|
409
409
|
}
|
|
410
|
-
if (!
|
|
410
|
+
if (!h) {
|
|
411
411
|
for (; l < e.length && (s.has(l) || o.has(l)); )
|
|
412
412
|
l++;
|
|
413
413
|
if (l < e.length)
|
|
@@ -442,7 +442,7 @@ function Y(e, t, n) {
|
|
|
442
442
|
function le(e, t, n) {
|
|
443
443
|
return Y(e, t);
|
|
444
444
|
}
|
|
445
|
-
function
|
|
445
|
+
function ht(e) {
|
|
446
446
|
const t = { _t: "a" };
|
|
447
447
|
for (const n in e)
|
|
448
448
|
if (n !== "_t")
|
|
@@ -451,9 +451,9 @@ function gt(e) {
|
|
|
451
451
|
if (Array.isArray(o)) {
|
|
452
452
|
if (o.length === 3 && o[2] === w)
|
|
453
453
|
t[s] = [o[0]];
|
|
454
|
-
else if (o.length === 3 && o[2] ===
|
|
454
|
+
else if (o.length === 3 && o[2] === P) {
|
|
455
455
|
const u = o[1];
|
|
456
|
-
t[`_${u}`] = [o[0], s,
|
|
456
|
+
t[`_${u}`] = [o[0], s, P];
|
|
457
457
|
}
|
|
458
458
|
}
|
|
459
459
|
} else {
|
|
@@ -461,26 +461,26 @@ function gt(e) {
|
|
|
461
461
|
if (Array.isArray(o) && o.length === 1)
|
|
462
462
|
t[`_${s}`] = [o[0], w, w];
|
|
463
463
|
else {
|
|
464
|
-
const u =
|
|
464
|
+
const u = Z(o);
|
|
465
465
|
u !== void 0 && (t[n] = u);
|
|
466
466
|
}
|
|
467
467
|
}
|
|
468
468
|
return t;
|
|
469
469
|
}
|
|
470
|
-
function
|
|
470
|
+
function gt(e) {
|
|
471
471
|
const t = {};
|
|
472
472
|
for (const n in e) {
|
|
473
473
|
const s = e[n];
|
|
474
474
|
if (Array.isArray(s))
|
|
475
475
|
s.length === 1 ? t[n] = [s[0], w, w] : s.length === 3 && s[2] === w ? t[n] = [s[0]] : s.length === 2 && (t[n] = [s[1], s[0]]);
|
|
476
476
|
else {
|
|
477
|
-
const o =
|
|
477
|
+
const o = Z(s);
|
|
478
478
|
o !== void 0 && (t[n] = o);
|
|
479
479
|
}
|
|
480
480
|
}
|
|
481
481
|
return t;
|
|
482
482
|
}
|
|
483
|
-
function
|
|
483
|
+
function Z(e) {
|
|
484
484
|
if (e !== void 0) {
|
|
485
485
|
if (Array.isArray(e)) {
|
|
486
486
|
if (e.length === 1)
|
|
@@ -489,14 +489,14 @@ function Q(e) {
|
|
|
489
489
|
return [e[1], e[0]];
|
|
490
490
|
if (e.length === 3 && e[2] === w)
|
|
491
491
|
return [e[0]];
|
|
492
|
-
if (e.length === 3 && e[2] ===
|
|
492
|
+
if (e.length === 3 && e[2] === P)
|
|
493
493
|
return e;
|
|
494
494
|
}
|
|
495
|
-
return k(e) && e._t === "a" ?
|
|
495
|
+
return k(e) && e._t === "a" ? ht(e) : k(e) ? gt(e) : e;
|
|
496
496
|
}
|
|
497
497
|
}
|
|
498
498
|
function de(e) {
|
|
499
|
-
return
|
|
499
|
+
return Z(e);
|
|
500
500
|
}
|
|
501
501
|
function pt(e, t, n) {
|
|
502
502
|
const s = de(t);
|
|
@@ -536,14 +536,14 @@ function bt({
|
|
|
536
536
|
includeValueOnMove: !1
|
|
537
537
|
},
|
|
538
538
|
cloneDiffValues: !1
|
|
539
|
-
}), n = j(null), s = j([]), o =
|
|
539
|
+
}), n = j(null), s = j([]), o = B(-1), u = j(null), l = S(() => o.value > 0), a = S(() => o.value < s.value.length - 1);
|
|
540
540
|
function d(v) {
|
|
541
541
|
if (n.value === null) {
|
|
542
542
|
n.value = C(v), u.value = C(v), s.value = [{ delta: null }], o.value = 0;
|
|
543
543
|
return;
|
|
544
544
|
}
|
|
545
|
-
const
|
|
546
|
-
if (o.value < s.value.length - 1 && (s.value = s.value.slice(0, o.value + 1)), s.value.push({ delta:
|
|
545
|
+
const g = t.diff(u.value, v);
|
|
546
|
+
if (o.value < s.value.length - 1 && (s.value = s.value.slice(0, o.value + 1)), s.value.push({ delta: g }), o.value++, u.value = C(v), s.value.length > e) {
|
|
547
547
|
const b = s.value[1].delta;
|
|
548
548
|
b && n.value && (n.value = t.patch(C(n.value), b)), s.value.shift(), o.value--;
|
|
549
549
|
}
|
|
@@ -551,14 +551,14 @@ function bt({
|
|
|
551
551
|
function c(v) {
|
|
552
552
|
if (!n.value || v < 0 || v >= s.value.length)
|
|
553
553
|
return;
|
|
554
|
-
let
|
|
554
|
+
let g = C(n.value);
|
|
555
555
|
for (let b = 1; b <= v; b++) {
|
|
556
556
|
const M = s.value[b];
|
|
557
|
-
M.delta && (
|
|
557
|
+
M.delta && (g = t.patch(g, M.delta));
|
|
558
558
|
}
|
|
559
|
-
return
|
|
559
|
+
return g;
|
|
560
560
|
}
|
|
561
|
-
function
|
|
561
|
+
function h() {
|
|
562
562
|
if (l.value) {
|
|
563
563
|
o.value--;
|
|
564
564
|
const v = c(o.value);
|
|
@@ -579,14 +579,14 @@ function bt({
|
|
|
579
579
|
push: d,
|
|
580
580
|
canUndo: l,
|
|
581
581
|
canRedo: a,
|
|
582
|
-
undo:
|
|
582
|
+
undo: h,
|
|
583
583
|
redo: y,
|
|
584
584
|
clear: f
|
|
585
585
|
};
|
|
586
586
|
}
|
|
587
587
|
const Mt = {
|
|
588
588
|
async updateMenuModule(e, t) {
|
|
589
|
-
const n =
|
|
589
|
+
const n = H.RequestRunner.operation(t, e.modules);
|
|
590
590
|
if (n.validateError.length > 0)
|
|
591
591
|
throw new Error(n.validateError.join(`
|
|
592
592
|
`));
|
|
@@ -634,15 +634,15 @@ function wt() {
|
|
|
634
634
|
}
|
|
635
635
|
};
|
|
636
636
|
}
|
|
637
|
-
const
|
|
637
|
+
const Kt = Ze(
|
|
638
638
|
"mf-menu-store-v2",
|
|
639
639
|
() => {
|
|
640
|
-
const e =
|
|
640
|
+
const e = Qe(wt()), t = se(), n = tt(), s = S(() => e.menu.modules.serveSequence ? x(e.menu.modules.serveSequence, {
|
|
641
641
|
selector: "position"
|
|
642
642
|
}) : []), o = S(() => {
|
|
643
643
|
var r;
|
|
644
|
-
return ((r = t.currentBusiness.value) == null ? void 0 : r.menuVersion) ||
|
|
645
|
-
}), u = S(() => o.value ===
|
|
644
|
+
return ((r = t.currentBusiness.value) == null ? void 0 : r.menuVersion) || L.F_MENU_VERSION.v3;
|
|
645
|
+
}), u = S(() => o.value === L.F_MENU_VERSION.v4), l = S(() => {
|
|
646
646
|
const r = e.menu.modules.catalog;
|
|
647
647
|
return x(r, { selector: "name" });
|
|
648
648
|
}), a = S(() => {
|
|
@@ -659,11 +659,11 @@ const Pt = Qe(
|
|
|
659
659
|
}), d = S(() => x(y.value.modules.scheduler, { selector: "name" })), c = S(() => e.menu.modules.scheduler.find(
|
|
660
660
|
(r) => r._id === e.currentSchedulerId
|
|
661
661
|
));
|
|
662
|
-
function
|
|
663
|
-
e.menu = { ...r, _rev: e.menu._rev }, i &&
|
|
662
|
+
function h(r, i = !0) {
|
|
663
|
+
e.menu = { ...r, _rev: e.menu._rev }, i && V.push(e.menu);
|
|
664
664
|
}
|
|
665
|
-
const y = j(me()), f =
|
|
666
|
-
async function
|
|
665
|
+
const y = j(me()), f = B(!1), v = B(1);
|
|
666
|
+
async function g() {
|
|
667
667
|
var m;
|
|
668
668
|
f.value = !0;
|
|
669
669
|
let r = e.menu.modules.catalog;
|
|
@@ -697,17 +697,17 @@ const Pt = Qe(
|
|
|
697
697
|
}
|
|
698
698
|
return y.value = i, f.value = !1, v.value = v.value + 1, i;
|
|
699
699
|
}
|
|
700
|
-
const M = ie.debounce(
|
|
700
|
+
const M = ie.debounce(g, 200);
|
|
701
701
|
let I = null, E = null;
|
|
702
|
-
function
|
|
703
|
-
E && (E(), E = null), I && I.stop(), I =
|
|
702
|
+
function Q() {
|
|
703
|
+
E && (E(), E = null), I && I.stop(), I = Xe(!0), E = I.run(() => et(
|
|
704
704
|
() => [e.menu, e.currentCatalogId, e.currentSchedulerId],
|
|
705
705
|
() => {
|
|
706
706
|
f.value || M();
|
|
707
707
|
}
|
|
708
708
|
)) || null;
|
|
709
709
|
}
|
|
710
|
-
|
|
710
|
+
Q();
|
|
711
711
|
const fe = S(() => [
|
|
712
712
|
{
|
|
713
713
|
label: "Main",
|
|
@@ -717,7 +717,7 @@ const Pt = Qe(
|
|
|
717
717
|
label: r.name,
|
|
718
718
|
value: r._id
|
|
719
719
|
}))
|
|
720
|
-
]),
|
|
720
|
+
]), X = S(() => {
|
|
721
721
|
const r = y.value.modules.category;
|
|
722
722
|
return [
|
|
723
723
|
...U.value.item.addon ? [
|
|
@@ -727,11 +727,11 @@ const Pt = Qe(
|
|
|
727
727
|
position: 0
|
|
728
728
|
}
|
|
729
729
|
] : [],
|
|
730
|
-
...
|
|
730
|
+
...D(r, (i) => i.name)
|
|
731
731
|
];
|
|
732
732
|
}), ve = S(() => {
|
|
733
733
|
const r = y.value.modules.subCategory || [];
|
|
734
|
-
return
|
|
734
|
+
return D(r, (i) => i.name);
|
|
735
735
|
}), ee = S(() => {
|
|
736
736
|
var i;
|
|
737
737
|
let r = y.value.modules.item;
|
|
@@ -745,17 +745,17 @@ const Pt = Qe(
|
|
|
745
745
|
return (_ == null ? void 0 : _.orderFrom) !== ue.enum.NONE;
|
|
746
746
|
});
|
|
747
747
|
}
|
|
748
|
-
return
|
|
748
|
+
return D(r, (m) => m.code || m.name);
|
|
749
749
|
}), ye = S(() => {
|
|
750
|
-
const r = e.menu.modules.category, i =
|
|
750
|
+
const r = e.menu.modules.category, i = D(r, (p) => p.name).reduce(
|
|
751
751
|
(p, _, A) => (p[_._id] = A, p),
|
|
752
752
|
{ "": 0 }
|
|
753
753
|
), m = e.menu.modules.item;
|
|
754
|
-
return
|
|
754
|
+
return D(
|
|
755
755
|
m,
|
|
756
756
|
(p) => p.code || p.name
|
|
757
757
|
).reduce((p, _, A) => (p[_._id] = A + i[_.category || ""], p), {});
|
|
758
|
-
}),
|
|
758
|
+
}), he = S(() => oe(N.value, X.value, ee.value)), ge = S(() => {
|
|
759
759
|
const r = U.value.item.addon ? [
|
|
760
760
|
{
|
|
761
761
|
_id: e.currentCatalogId ? "" : null,
|
|
@@ -777,12 +777,12 @@ const Pt = Qe(
|
|
|
777
777
|
const i = r.map((p) => N.value.find((_) => _._id === p)).filter((p) => !!p);
|
|
778
778
|
return T.fullVariantCombination(i).reduce((p, _) => (p[_.combinationKey] = _.selectionName.join(" / "), p), {});
|
|
779
779
|
}
|
|
780
|
-
const _e = S(() =>
|
|
780
|
+
const _e = S(() => D(y.value.modules.group, (r) => r.name)), Se = S(() => x(y.value.modules.takeaway, { selector: "name" })), be = S(() => x(e.menu.modules.printDepartment || [], {
|
|
781
781
|
selector: "name"
|
|
782
|
-
})), Me = S(() => x(e.menu.modules.unit, { selector: "name" })), we = S(() => x(
|
|
782
|
+
})), Me = S(() => x(e.menu.modules.unit, { selector: "name" })), we = S(() => x(ze(e.menu.modules.recipe, e.menu.modules.sku), {
|
|
783
783
|
selector: "name"
|
|
784
784
|
})), Ae = S(() => e.menu.modules.cookingGuide), Ce = S(() => {
|
|
785
|
-
const r =
|
|
785
|
+
const r = qe(e.menu.modules.sku);
|
|
786
786
|
return x(r, { selector: "code" });
|
|
787
787
|
}), Ie = S(() => {
|
|
788
788
|
const r = /* @__PURE__ */ new Map();
|
|
@@ -793,7 +793,7 @@ const Pt = Qe(
|
|
|
793
793
|
});
|
|
794
794
|
}), r;
|
|
795
795
|
}), U = S(() => {
|
|
796
|
-
const r = !e.currentCatalogId, i = o.value ===
|
|
796
|
+
const r = !e.currentCatalogId, i = o.value === L.F_MENU_VERSION.v4, m = !e.currentSchedulerId, p = {
|
|
797
797
|
create: r && m,
|
|
798
798
|
edit: r && m,
|
|
799
799
|
delete: r && m
|
|
@@ -877,10 +877,10 @@ const Pt = Qe(
|
|
|
877
877
|
}
|
|
878
878
|
const Re = S(() => {
|
|
879
879
|
var p;
|
|
880
|
-
const r = ["SV5", "SV10"], i =
|
|
880
|
+
const r = ["SV5", "SV10"], i = He.Country.getCountryFlattenTaxes(
|
|
881
881
|
se().currentCountry.value
|
|
882
882
|
), m = i.filter((_) => u.value || !r.includes(_.taxCode)).map((_) => ({
|
|
883
|
-
label: `${_.name} (${
|
|
883
|
+
label: `${_.name} (${Be(_.rate)}%)`,
|
|
884
884
|
value: W(_),
|
|
885
885
|
meta: {
|
|
886
886
|
rate: _.rate
|
|
@@ -906,13 +906,13 @@ const Pt = Qe(
|
|
|
906
906
|
});
|
|
907
907
|
}, te = (r) => {
|
|
908
908
|
e.currentCatalogId = r;
|
|
909
|
-
}, De = (r) => {
|
|
910
|
-
e.currentSchedulerId = r;
|
|
911
909
|
}, Ve = (r) => {
|
|
910
|
+
e.currentSchedulerId = r;
|
|
911
|
+
}, De = (r) => {
|
|
912
912
|
e.currentCategoryIds = r;
|
|
913
913
|
}, Te = (r) => {
|
|
914
914
|
e.currentRestaurantAttrParams = r;
|
|
915
|
-
},
|
|
915
|
+
}, Pe = async (r, i) => {
|
|
916
916
|
const m = Array.isArray(r) ? r : [r];
|
|
917
917
|
if (!m.length) return;
|
|
918
918
|
const p = m.map((_) => ({
|
|
@@ -922,13 +922,13 @@ const Pt = Qe(
|
|
|
922
922
|
}));
|
|
923
923
|
try {
|
|
924
924
|
if (i || p.some(
|
|
925
|
-
(A) => [
|
|
925
|
+
(A) => [H.F_OPERATION_TYPE.delete, H.F_OPERATION_TYPE.deleteMany].includes(A.operation)
|
|
926
926
|
)) {
|
|
927
|
-
const A = await
|
|
927
|
+
const A = await Ge(p, e.menu.modules);
|
|
928
928
|
if (A !== !0) throw new Error(A);
|
|
929
929
|
}
|
|
930
930
|
const _ = await Mt.updateMenuModule(e.menu, p);
|
|
931
|
-
return
|
|
931
|
+
return h(_.menu), _;
|
|
932
932
|
} catch (_) {
|
|
933
933
|
n.open({
|
|
934
934
|
type: "error",
|
|
@@ -936,22 +936,22 @@ const Pt = Qe(
|
|
|
936
936
|
message: _
|
|
937
937
|
});
|
|
938
938
|
}
|
|
939
|
-
},
|
|
939
|
+
}, Ke = async (r) => {
|
|
940
940
|
const i = {
|
|
941
941
|
...e.menu,
|
|
942
942
|
masterCatalogSetting: r.masterCatalogSetting,
|
|
943
943
|
lowStockThreshold: r.lowStockThreshold,
|
|
944
944
|
priceTierSettings: r.priceTierSettings
|
|
945
945
|
};
|
|
946
|
-
return
|
|
947
|
-
},
|
|
948
|
-
const r =
|
|
949
|
-
r &&
|
|
946
|
+
return h(i), i;
|
|
947
|
+
}, V = bt({ maxHistorySize: 50 }), $e = S(() => V.canUndo.value), Fe = S(() => V.canRedo.value), je = () => {
|
|
948
|
+
const r = V.undo();
|
|
949
|
+
r && h(r, !1);
|
|
950
950
|
}, Ne = () => {
|
|
951
|
-
const r =
|
|
952
|
-
r &&
|
|
951
|
+
const r = V.redo();
|
|
952
|
+
r && h(r, !1);
|
|
953
953
|
}, Ue = () => {
|
|
954
|
-
|
|
954
|
+
V.clear();
|
|
955
955
|
};
|
|
956
956
|
return {
|
|
957
957
|
state: e,
|
|
@@ -969,13 +969,13 @@ const Pt = Qe(
|
|
|
969
969
|
schedulers: d,
|
|
970
970
|
currentScheduler: c,
|
|
971
971
|
catalogOptions: fe,
|
|
972
|
-
categories:
|
|
972
|
+
categories: X,
|
|
973
973
|
subcategories: ve,
|
|
974
974
|
items: ee,
|
|
975
975
|
sortedItems: ye,
|
|
976
976
|
itemCodeMap: Ie,
|
|
977
|
-
categorizedItems:
|
|
978
|
-
categorizedRawMenuItems:
|
|
977
|
+
categorizedItems: he,
|
|
978
|
+
categorizedRawMenuItems: ge,
|
|
979
979
|
variants: N,
|
|
980
980
|
groups: _e,
|
|
981
981
|
takeaways: Se,
|
|
@@ -987,16 +987,16 @@ const Pt = Qe(
|
|
|
987
987
|
rules: U,
|
|
988
988
|
taxSetting: Re,
|
|
989
989
|
// Action
|
|
990
|
-
setMenu:
|
|
990
|
+
setMenu: h,
|
|
991
991
|
readMenu: xe,
|
|
992
992
|
readRestaurants: Oe,
|
|
993
993
|
selectCatalog: te,
|
|
994
|
-
selectScheduler:
|
|
995
|
-
selectCategory:
|
|
994
|
+
selectScheduler: Ve,
|
|
995
|
+
selectCategory: De,
|
|
996
996
|
setRestaurantAttrParams: Te,
|
|
997
|
-
updateMenu:
|
|
998
|
-
updateMenuSetting:
|
|
999
|
-
computeMergedMenu:
|
|
997
|
+
updateMenu: Pe,
|
|
998
|
+
updateMenuSetting: Ke,
|
|
999
|
+
computeMergedMenu: g,
|
|
1000
1000
|
// helper
|
|
1001
1001
|
encodeTax: W,
|
|
1002
1002
|
decodeTax: Ee,
|
|
@@ -1012,16 +1012,16 @@ const Pt = Qe(
|
|
|
1012
1012
|
M.cancel(), E && (E(), E = null), I && (I.stop(), I = null), Ue();
|
|
1013
1013
|
},
|
|
1014
1014
|
$reinitialize: () => {
|
|
1015
|
-
|
|
1015
|
+
Q();
|
|
1016
1016
|
}
|
|
1017
1017
|
};
|
|
1018
1018
|
}
|
|
1019
1019
|
);
|
|
1020
1020
|
export {
|
|
1021
1021
|
Tt as a,
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1022
|
+
Pt as f,
|
|
1023
|
+
Dt as g,
|
|
1024
|
+
Vt as m,
|
|
1025
1025
|
it as o,
|
|
1026
|
-
|
|
1026
|
+
Kt as u
|
|
1027
1027
|
};
|