@feedmepos/mf-menu 0.31.76-beta.1 → 0.31.76-prod

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 (62) hide show
  1. package/dist/{App-IKWFQ0LG.js → App-i4MsTBGL.js} +6 -6
  2. package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-DaoRKuTE.js → ApplyProduct.vue_vue_type_script_setup_true_lang-C7nAccDq.js} +3 -3
  3. package/dist/{Catalog-CddVBuCt.js → Catalog-CLbwCvQa.js} +6 -6
  4. package/dist/{Category-BtJifGpV.js → Category-BeneUsA7.js} +6 -6
  5. package/dist/{Category-UjN1MvRx.js → Category-CE1gEYJ7.js} +4 -4
  6. package/dist/{CookingGuide-C60PKbdw.js → CookingGuide-C9qhqN9A.js} +4 -4
  7. package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-Bh5I274Z.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-Bn5hx--m.js} +1 -1
  8. package/dist/{Group-uP_N7XV9.js → Group-BK7S4pGn.js} +1 -1
  9. package/dist/{Group-CL9-nZIy.js → Group-zdNfbd9c.js} +3 -3
  10. package/dist/{Group.vue_vue_type_script_setup_true_lang-TCtCEYei.js → Group.vue_vue_type_script_setup_true_lang-Bg0cdKM2.js} +7 -7
  11. package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-BonCgo1E.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-CL-60lpj.js} +5 -5
  12. package/dist/{ImportProductDialog.vue_vue_type_script_setup_true_lang-CD668o_s.js → ImportProductDialog.vue_vue_type_script_setup_true_lang-DXRTOqPv.js} +207 -207
  13. package/dist/{Ingredient-0SKOh0qp.js → Ingredient-D8L1AuNz.js} +3 -3
  14. package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-DBRsVhnw.js → InventoryBinding.vue_vue_type_script_setup_true_lang-Dmu6jkcU.js} +2 -2
  15. package/dist/{LinkProductSideSheet-tkbRMtn3.js → LinkProductSideSheet-BjumT4OD.js} +3 -3
  16. package/dist/{MenuSetting-CDk6v_Bl.js → MenuSetting-Cz1tgcRJ.js} +5 -5
  17. package/dist/{PrintRoute-B_K6oU3B.js → PrintRoute-DIK12jhb.js} +4 -4
  18. package/dist/{Product-DtG6SZ5h.js → Product-CHNP6WP5.js} +1 -1
  19. package/dist/{Product.vue_vue_type_script_setup_true_lang-DiwfWCUi.js → Product.vue_vue_type_script_setup_true_lang-D59An66a.js} +13 -13
  20. package/dist/{ProductInternalTools-CN3mNU8n.js → ProductInternalTools-DOqdy0rD.js} +6 -6
  21. package/dist/{Products-d4dxegLd.js → Products-DHEIHR8V.js} +11 -11
  22. package/dist/{Publish-BQP6-JEG.js → Publish-Uj40COh0.js} +3 -3
  23. package/dist/{Recipe-B4aaH1yA.js → Recipe-CO-CfI0H.js} +4 -4
  24. package/dist/{Scheduler-C0rs1p3e.js → Scheduler-CUWeGO0g.js} +3 -3
  25. package/dist/{ServingSequence-D_IZqTcd.js → ServingSequence-0zjBiqM0.js} +3 -3
  26. package/dist/{Setting-6VEKLlEu.js → Setting-Br7EYS-s.js} +5 -5
  27. package/dist/{Subcategory-CIGrf6Q0.js → Subcategory-iRAC5CuK.js} +4 -4
  28. package/dist/{Takeaway-ChawjNAU.js → Takeaway-B4ekEPct.js} +1 -1
  29. package/dist/{Takeaway-umxANsBm.js → Takeaway-CaCigz-m.js} +4 -4
  30. package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-BCn-pG8S.js → Takeaway.vue_vue_type_script_setup_true_lang-CrgbohwL.js} +5 -5
  31. package/dist/{Thumbnail.vue_vue_type_script_setup_true_lang-BN6BZEuV.js → Thumbnail.vue_vue_type_script_setup_true_lang-DikGODMn.js} +4 -4
  32. package/dist/{TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CyzU15F0.js → TreeEditorOpenner.vue_vue_type_script_setup_true_lang-BxcI4COW.js} +15 -15
  33. package/dist/{Unit-4PJdNn2q.js → Unit-COKx4pYS.js} +2 -2
  34. package/dist/{Variant-CR7Pvv5N.js → Variant-C9FVr37F.js} +3 -3
  35. package/dist/{_id_-Zf6gAKQ9.js → _id_-C_zW17uS.js} +10 -10
  36. package/dist/{app-Z9dYyosz.js → app-BgBl7Ty6.js} +26 -26
  37. package/dist/{app-CSDqAFMU.js → app-CCzqLBqE.js} +1 -1
  38. package/dist/app.js +1 -1
  39. package/dist/assets/{linked-status-BKYTLe7I.js → linked-status-De-I7zeD.js} +5 -5
  40. package/dist/assets/{override-menu-BKP0NheT.js → override-menu-Bxb06cQ6.js} +5 -5
  41. package/dist/assets/{validate-menu-CsLxjjPJ.js → validate-menu-C7rkEYIs.js} +2 -2
  42. package/dist/{catalog-D-iWj3Ig.js → catalog-C4ICMK5E.js} +1 -1
  43. package/dist/{catalogSetting-DfsQaE2k.js → catalogSetting-CptKtJtm.js} +1 -1
  44. package/dist/{category-DWipTwJC.js → category-DhTeQutn.js} +1 -1
  45. package/dist/{currency-BPyUd-Uq.js → currency-Dnu_P_5E.js} +1 -1
  46. package/dist/{customAttributes-DEfSmlRQ.js → customAttributes-DRG3HAvt.js} +1 -1
  47. package/dist/{index-BrzM9d53.js → index-Cbo9djfs.js} +1 -1
  48. package/dist/{index-DGQzCriF.js → index-CqdjOAtu.js} +4 -4
  49. package/dist/{index-CMsdZGYU.js → index-Cyp9RR7l.js} +3 -3
  50. package/dist/{index-CX1AIm7T.js → index-DBxnLcHs.js} +1 -1
  51. package/dist/{item-C5BGEJfL.js → item-Cjjz_jVU.js} +15 -15
  52. package/dist/{iteration-DT--Uo_f.js → iteration-DsJuo_ft.js} +1 -1
  53. package/dist/{jszip.min-Zgr9h0eY.js → jszip.min-DnBGkPKz.js} +245 -245
  54. package/dist/{menu-qc8oftWK.js → menu-CnXHE9uW.js} +1 -1
  55. package/dist/{menu-CiZ9jI7P.js → menu-DXzZVB-B.js} +6 -6
  56. package/dist/{menuV2-BndWMdLg.js → menuV2-CZB1IGtm.js} +85 -85
  57. package/dist/{priceTier-DMBJPgo9.js → priceTier-CaL6oR7J.js} +1 -1
  58. package/dist/{scheduler-CnK4QvgL.js → scheduler-C_Hjzu_M.js} +4 -4
  59. package/dist/{subcategory-Cg-gyF3g.js → subcategory-EW4oO3C7.js} +2 -2
  60. package/dist/{toExcel-whneqAkf.js → toExcel-C132BwLx.js} +2 -2
  61. package/dist/{unit-Cy-snkRq.js → unit-C1DDNHxM.js} +2 -2
  62. package/package.json +1 -1
@@ -1,12 +1,12 @@
1
1
  var Ue = Object.defineProperty;
2
2
  var We = (e, t, n) => t in e ? Ue(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var ne = (e, t, n) => We(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { an as ue, H as I, B as D, z as ae, ao as re, J as q, I as ie, ab as x, c as L, X as V, al as oe, ap as Le, aq as ze, A as Be, ad as qe, ar as Ge, as as He, aa as Je } from "./menu-CiZ9jI7P.js";
4
+ import { an as ue, H as I, B as T, z as ae, ao as re, J as B, I as ie, ab as x, c as z, X as V, al as oe, ap as ze, aq as Le, A as qe, ad as Be, ar as Ge, as as He, aa as Je } from "./menu-DXzZVB-B.js";
5
5
  import { defineStore as Ye } from "pinia";
6
- import { shallowRef as N, ref as G, computed as S, shallowReactive as Xe, effectScope as Qe, watch as Ze } from "vue";
6
+ import { shallowRef as j, ref as G, computed as S, shallowReactive as Qe, effectScope as Xe, watch as Ze } from "vue";
7
7
  import { useCoreStore as se } from "@feedmepos/mf-common";
8
8
  import { useSnackbar as et } from "@feedmepos/ui-library";
9
- const tt = "/assets/linked-status-BKYTLe7I.js", nt = "/assets/override-menu-BKP0NheT.js";
9
+ const tt = "/assets/linked-status-De-I7zeD.js", nt = "/assets/override-menu-Bxb06cQ6.js";
10
10
  function rt(e) {
11
11
  var o;
12
12
  const t = I(e), n = (o = t.variant) == null ? void 0 : o.variantCombinations;
@@ -88,7 +88,7 @@ function st(e, t) {
88
88
  if (i)
89
89
  return $(i, t, 1);
90
90
  const f = {
91
- ...D.generator.initMenuV4ItemOverrider(),
91
+ ...T.generator.initMenuV4ItemOverrider(),
92
92
  _id: c._id,
93
93
  combinationKey: c.combinationKey
94
94
  };
@@ -96,7 +96,7 @@ function st(e, t) {
96
96
  });
97
97
  return { ...a, items: u };
98
98
  }), o = e.variant ? e.variant.variantCombinations.map((a) => $(a, t, 1)) : [], r = {
99
- ...D.generator.initMenuV4ItemOverrider(),
99
+ ...T.generator.initMenuV4ItemOverrider(),
100
100
  _id: e._id,
101
101
  name: e.name,
102
102
  code: e.code,
@@ -156,7 +156,7 @@ async function Ot(e, t, n, o, r, a = !0) {
156
156
  const l = I(n), u = a ? ot(t, l, o, r) : l, c = t.reduce((h, m) => (h[m._id] = u.modules.item.find((v) => v._id === m._id), h), {}), i = t.reduce((h, m) => {
157
157
  const v = m._id;
158
158
  return h[v] = st(c[v], e), h;
159
- }, {}), f = D.getFallbackPrices({
159
+ }, {}), f = T.getFallbackPrices({
160
160
  rawMenu: u,
161
161
  items: i,
162
162
  catalogId: o || void 0,
@@ -170,7 +170,7 @@ async function Ot(e, t, n, o, r, a = !0) {
170
170
  };
171
171
  });
172
172
  }
173
- function Tt(e, t) {
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((r, a) => {
@@ -183,11 +183,11 @@ function Tt(e, t) {
183
183
  return r;
184
184
  }, [])) || []).join(" / ");
185
185
  }
186
- const z = /* @__PURE__ */ new Map();
186
+ const L = /* @__PURE__ */ new Map();
187
187
  async function Vt(e, t) {
188
188
  const n = `${e._id}-${e.updatedAt}-${t}`;
189
- if (z.has(n))
190
- return z.get(n);
189
+ if (L.has(n))
190
+ return L.get(n);
191
191
  const o = await ue(
192
192
  tt,
193
193
  JSON.stringify({
@@ -195,7 +195,7 @@ async function Vt(e, t) {
195
195
  itemId: t
196
196
  })
197
197
  );
198
- return z.set(n, o), o;
198
+ return L.set(n, o), o;
199
199
  }
200
200
  async function ce(e, t, n) {
201
201
  return await ue(nt, {
@@ -204,7 +204,7 @@ async function ce(e, t, n) {
204
204
  schedulerId: n
205
205
  });
206
206
  }
207
- function Dt(e, t, n) {
207
+ function Tt(e, t, n) {
208
208
  const o = /* @__PURE__ */ new Set();
209
209
  function r(a, l) {
210
210
  if (!e || !a || !l || o.has(l)) return !1;
@@ -219,7 +219,7 @@ function Dt(e, t, n) {
219
219
  }
220
220
  return r(t, n);
221
221
  }
222
- function Kt(e, t, n) {
222
+ function Ft(e, t, n) {
223
223
  const o = /* @__PURE__ */ new Set();
224
224
  function r(a, l) {
225
225
  if (!e || !a || !l || o.has(a)) return !1;
@@ -234,15 +234,15 @@ function Kt(e, t, n) {
234
234
  }
235
235
  return r(t, n);
236
236
  }
237
- const B = /* @__PURE__ */ new Map();
237
+ const q = /* @__PURE__ */ new Map();
238
238
  async function at(e, t, n) {
239
239
  const o = `${e._id}-${e.updatedAt}-${t || "null"}-${n || "null"}`;
240
- if (B.has(o))
241
- return B.get(o);
240
+ if (q.has(o))
241
+ return q.get(o);
242
242
  const r = await ce(e, t, n);
243
- return B.set(o, r), r;
243
+ return q.set(o, r), r;
244
244
  }
245
- async function Pt(e, t, n) {
245
+ async function Kt(e, t, n) {
246
246
  var l, u;
247
247
  const o = await at(e, t, null), r = [], a = (c, i) => {
248
248
  const f = I(c);
@@ -268,7 +268,7 @@ async function Pt(e, t, n) {
268
268
  }
269
269
  return r;
270
270
  }
271
- const M = 0, K = 3;
271
+ const M = 0, F = 3;
272
272
  function it(e) {
273
273
  const t = /^\/(.*)\/([gimyu]*)$/.exec(e.toString());
274
274
  if (!t)
@@ -291,13 +291,13 @@ function O(e) {
291
291
  Object.prototype.hasOwnProperty.call(e, n) && (t[n] = O(e[n]));
292
292
  return t;
293
293
  }
294
- function F(e) {
294
+ function P(e) {
295
295
  return e instanceof RegExp ? e.toString() : e;
296
296
  }
297
297
  function k(e) {
298
298
  return typeof e == "object" && e !== null && !Array.isArray(e) && !(e instanceof Date) && !(e instanceof RegExp);
299
299
  }
300
- function P(e, t) {
300
+ function K(e, t) {
301
301
  if (e === t) return !0;
302
302
  if (typeof e != typeof t) return !1;
303
303
  if (e instanceof Date && t instanceof Date)
@@ -307,14 +307,14 @@ function P(e, t) {
307
307
  if (Array.isArray(e) && Array.isArray(t)) {
308
308
  if (e.length !== t.length) return !1;
309
309
  for (let n = 0; n < e.length; n++)
310
- if (!P(e[n], t[n])) return !1;
310
+ if (!K(e[n], t[n])) return !1;
311
311
  return !0;
312
312
  }
313
313
  if (k(e) && k(t)) {
314
314
  const n = Object.keys(e), o = Object.keys(t);
315
315
  if (n.length !== o.length) return !1;
316
316
  for (const r of n)
317
- if (!Object.prototype.hasOwnProperty.call(t, r) || !P(e[r], t[r])) return !1;
317
+ if (!Object.prototype.hasOwnProperty.call(t, r) || !K(e[r], t[r])) return !1;
318
318
  return !0;
319
319
  }
320
320
  return !1;
@@ -330,7 +330,7 @@ function ct(e, t, n) {
330
330
  const i = e[c], f = n ? n(i) : JSON.stringify(i), h = a.get(f);
331
331
  if (h) {
332
332
  for (const m of h)
333
- if (!u.has(m) && P(i, t[m])) {
333
+ if (!u.has(m) && K(i, t[m])) {
334
334
  l.push({ leftIndex: c, rightIndex: m }), u.add(m);
335
335
  break;
336
336
  }
@@ -340,7 +340,7 @@ function ct(e, t, n) {
340
340
  }
341
341
  function lt(e, t, n) {
342
342
  var m, v;
343
- if (P(e, t)) return;
343
+ if (K(e, t)) return;
344
344
  const o = { _t: "a" }, r = ((m = n == null ? void 0 : n.arrays) == null ? void 0 : m.detectMove) !== !1, a = ((v = n == null ? void 0 : n.arrays) == null ? void 0 : v.includeValueOnMove) === !0, l = n == null ? void 0 : n.objectHash;
345
345
  let u = r ? ct(e, t, l) : [];
346
346
  if (!l && e.length === t.length && e.length > 0 && u.length < e.length) {
@@ -360,7 +360,7 @@ function lt(e, t, n) {
360
360
  if (b !== void 0) {
361
361
  const w = J(e[p], t[b], n);
362
362
  if (w !== void 0 && (o[b] = w), r && b !== p) {
363
- const C = `_${p}`, R = a ? [e[p], b, K] : ["", b, K];
363
+ const C = `_${p}`, R = a ? [e[p], b, F] : ["", b, F];
364
364
  o[C] = R;
365
365
  }
366
366
  } else {
@@ -375,7 +375,7 @@ function lt(e, t, n) {
375
375
  return o;
376
376
  }
377
377
  function dt(e, t, n) {
378
- if (P(e, t)) return;
378
+ if (K(e, t)) return;
379
379
  const o = {}, r = Object.keys(e), a = Object.keys(t), l = /* @__PURE__ */ new Set([...r, ...a]);
380
380
  for (const u of l) {
381
381
  if (n != null && n.propertyFilter && !n.propertyFilter(u, { left: e, right: t }))
@@ -392,21 +392,21 @@ function dt(e, t, n) {
392
392
  return Object.keys(o).length > 0 ? o : void 0;
393
393
  }
394
394
  function J(e, t, n) {
395
- if (P(e, t)) return;
395
+ if (K(e, t)) return;
396
396
  if (e === void 0 && t !== void 0) {
397
397
  const u = n != null && n.cloneDiffValues ? O(t) : t;
398
- return [F(u)];
398
+ return [P(u)];
399
399
  }
400
400
  if (typeof e !== typeof t || e instanceof Date != t instanceof Date || e instanceof RegExp != t instanceof RegExp || Array.isArray(e) !== Array.isArray(t)) {
401
401
  const u = n != null && n.cloneDiffValues ? O(e) : e, c = n != null && n.cloneDiffValues ? O(t) : t;
402
- return [F(u), F(c)];
402
+ return [P(u), P(c)];
403
403
  }
404
404
  if (Array.isArray(e) && Array.isArray(t))
405
405
  return lt(e, t, n);
406
406
  if (k(e) && k(t))
407
407
  return dt(e, t, n);
408
408
  const a = n != null && n.cloneDiffValues ? O(e) : e, l = n != null && n.cloneDiffValues ? O(t) : t;
409
- return [F(a), F(l)];
409
+ return [P(a), P(l)];
410
410
  }
411
411
  function ft(e, t, n) {
412
412
  return J(e, t, n);
@@ -416,7 +416,7 @@ function mt(e, t, n) {
416
416
  for (const u in t) {
417
417
  if (u === "_t" || !u.startsWith("_")) continue;
418
418
  const c = parseInt(u.slice(1)), i = t[u];
419
- Array.isArray(i) && (i.length === 3 && i[2] === M ? o.add(c) : i.length === 3 && i[2] === K && r.set(c, i[1]));
419
+ Array.isArray(i) && (i.length === 3 && i[2] === M ? o.add(c) : i.length === 3 && i[2] === F && r.set(c, i[1]));
420
420
  }
421
421
  const a = [];
422
422
  let l = 0;
@@ -481,9 +481,9 @@ function yt(e) {
481
481
  if (Array.isArray(r)) {
482
482
  if (r.length === 3 && r[2] === M)
483
483
  t[o] = [r[0]];
484
- else if (r.length === 3 && r[2] === K) {
484
+ else if (r.length === 3 && r[2] === F) {
485
485
  const a = r[1];
486
- t[`_${a}`] = [r[0], o, K];
486
+ t[`_${a}`] = [r[0], o, F];
487
487
  }
488
488
  }
489
489
  } else {
@@ -491,7 +491,7 @@ function yt(e) {
491
491
  if (Array.isArray(r) && r.length === 1)
492
492
  t[`_${o}`] = [r[0], M, M];
493
493
  else {
494
- const a = X(r);
494
+ const a = Q(r);
495
495
  a !== void 0 && (t[n] = a);
496
496
  }
497
497
  }
@@ -504,13 +504,13 @@ function ht(e) {
504
504
  if (Array.isArray(o))
505
505
  o.length === 1 ? t[n] = [o[0], M, M] : o.length === 3 && o[2] === M ? t[n] = [o[0]] : o.length === 2 && (t[n] = [o[1], o[0]]);
506
506
  else {
507
- const r = X(o);
507
+ const r = Q(o);
508
508
  r !== void 0 && (t[n] = r);
509
509
  }
510
510
  }
511
511
  return t;
512
512
  }
513
- function X(e) {
513
+ function Q(e) {
514
514
  if (e !== void 0) {
515
515
  if (Array.isArray(e)) {
516
516
  if (e.length === 1)
@@ -519,14 +519,14 @@ function X(e) {
519
519
  return [e[1], e[0]];
520
520
  if (e.length === 3 && e[2] === M)
521
521
  return [e[0]];
522
- if (e.length === 3 && e[2] === K)
522
+ if (e.length === 3 && e[2] === F)
523
523
  return e;
524
524
  }
525
525
  return k(e) && e._t === "a" ? yt(e) : k(e) ? ht(e) : e;
526
526
  }
527
527
  }
528
528
  function de(e) {
529
- return X(e);
529
+ return Q(e);
530
530
  }
531
531
  function pt(e, t, n) {
532
532
  const o = de(t);
@@ -566,7 +566,7 @@ function St({
566
566
  includeValueOnMove: !1
567
567
  },
568
568
  cloneDiffValues: !1
569
- }), n = N(null), o = N([]), r = G(-1), a = N(null), l = S(() => r.value > 0), u = S(() => r.value < o.value.length - 1);
569
+ }), n = j(null), o = j([]), r = G(-1), a = j(null), l = S(() => r.value > 0), u = S(() => r.value < o.value.length - 1);
570
570
  function c(v) {
571
571
  if (n.value === null) {
572
572
  n.value = I(v), a.value = I(v), o.value = [{ delta: null }], r.value = 0;
@@ -616,7 +616,7 @@ function St({
616
616
  }
617
617
  const bt = {
618
618
  async updateMenuModule(e, t) {
619
- const n = q.RequestRunner.operation(t, e.modules);
619
+ const n = B.RequestRunner.operation(t, e.modules);
620
620
  if (n.validateError.length > 0)
621
621
  throw new Error(n.validateError.join(`
622
622
  `));
@@ -664,15 +664,15 @@ function wt() {
664
664
  }
665
665
  };
666
666
  }
667
- const Ft = Ye(
667
+ const Pt = Ye(
668
668
  "mf-menu-store-v2",
669
669
  () => {
670
- const e = Xe(wt()), t = se(), n = et(), o = S(() => e.menu.modules.serveSequence ? x(e.menu.modules.serveSequence, {
670
+ const e = Qe(wt()), t = se(), n = et(), o = S(() => e.menu.modules.serveSequence ? x(e.menu.modules.serveSequence, {
671
671
  selector: "position"
672
672
  }) : []), r = S(() => {
673
673
  var s;
674
- return ((s = t.currentBusiness.value) == null ? void 0 : s.menuVersion) || L.F_MENU_VERSION.v3;
675
- }), a = S(() => r.value === L.F_MENU_VERSION.v4), l = S(() => {
674
+ return ((s = t.currentBusiness.value) == null ? void 0 : s.menuVersion) || z.F_MENU_VERSION.v3;
675
+ }), a = S(() => r.value === z.F_MENU_VERSION.v4), l = S(() => {
676
676
  const s = e.menu.modules.catalog;
677
677
  return x(s, { selector: "name" });
678
678
  }), u = S(() => {
@@ -680,7 +680,7 @@ const Ft = Ye(
680
680
  let s = e.menu.modules.catalog.find(
681
681
  (y) => y._id === e.currentCatalogId
682
682
  );
683
- return s && ((d = s.linkItemRules) != null && d.length) && (s = D.populateCatalog({
683
+ return s && ((d = s.linkItemRules) != null && d.length) && (s = T.populateCatalog({
684
684
  catalog: s,
685
685
  ruleGroupSettings: e.menu.ruleGroupSettings,
686
686
  items: e.menu.modules.item,
@@ -690,15 +690,15 @@ const Ft = Ye(
690
690
  (s) => s._id === e.currentSchedulerId
691
691
  ));
692
692
  function f(s, d = !0) {
693
- e.menu = { ...s, _rev: e.menu._rev }, d && T.push(e.menu);
693
+ e.menu = { ...s, _rev: e.menu._rev }, d && D.push(e.menu);
694
694
  }
695
- const h = N(fe()), m = G(!1), v = G(1);
695
+ const h = j(fe()), m = G(!1), v = G(1);
696
696
  async function p() {
697
697
  var y;
698
698
  m.value = !0;
699
699
  let s = e.menu.modules.catalog;
700
700
  if (u.value && ((y = u.value.linkItemRules) != null && y.length)) {
701
- const g = D.populateCatalog({
701
+ const g = T.populateCatalog({
702
702
  catalog: u.value,
703
703
  ruleGroupSettings: e.menu.ruleGroupSettings,
704
704
  items: e.menu.modules.item,
@@ -729,15 +729,15 @@ const Ft = Ye(
729
729
  }
730
730
  const w = ie.debounce(p, 200);
731
731
  let C = null, R = null;
732
- function Q() {
733
- R && (R(), R = null), C && C.stop(), C = Qe(!0), R = C.run(() => Ze(
732
+ function X() {
733
+ R && (R(), R = null), C && C.stop(), C = Xe(!0), R = C.run(() => Ze(
734
734
  () => [e.menu, e.currentCatalogId, e.currentSchedulerId],
735
735
  () => {
736
736
  m.value || w();
737
737
  }
738
738
  )) || null;
739
739
  }
740
- Q();
740
+ X();
741
741
  const me = S(() => [
742
742
  {
743
743
  label: "Main",
@@ -785,7 +785,7 @@ const Ft = Ye(
785
785
  y,
786
786
  (g) => g.code || g.name
787
787
  ).reduce((g, _, A) => (g[_._id] = A + d[_.category || ""], g), {});
788
- }), he = S(() => oe(j.value, Z.value, ee.value)), pe = S(() => {
788
+ }), he = S(() => oe(N.value, Z.value, ee.value)), pe = S(() => {
789
789
  const s = U.value.item.addon ? [
790
790
  {
791
791
  _id: e.currentCatalogId ? "" : null,
@@ -799,23 +799,23 @@ const Ft = Ye(
799
799
  s,
800
800
  e.menu.modules.item
801
801
  );
802
- }), j = S(() => {
802
+ }), N = S(() => {
803
803
  const s = h.value.modules.variant;
804
804
  return x(s, { selector: "name" });
805
805
  });
806
806
  function ge(s = []) {
807
- const d = s.map((g) => j.value.find((_) => _._id === g)).filter((g) => !!g);
808
- return D.fullVariantCombination(d).reduce((g, _) => (g[_.combinationKey] = _.selectionName.join(" / "), g), {});
807
+ const d = s.map((g) => N.value.find((_) => _._id === g)).filter((g) => !!g);
808
+ return T.fullVariantCombination(d).reduce((g, _) => (g[_.combinationKey] = _.selectionName.join(" / "), g), {});
809
809
  }
810
810
  const _e = S(() => V(h.value.modules.group, (s) => s.name)), Se = S(() => x(h.value.modules.takeaway, { selector: "name" })), be = S(() => x(e.menu.modules.printDepartment || [], {
811
811
  selector: "name"
812
- })), we = S(() => x(e.menu.modules.unit, { selector: "name" })), Me = S(() => x(Le(e.menu.modules.recipe, e.menu.modules.sku), {
812
+ })), we = S(() => x(e.menu.modules.unit, { selector: "name" })), Me = S(() => x(ze(e.menu.modules.recipe, e.menu.modules.sku), {
813
813
  selector: "name"
814
814
  })), Ae = S(() => e.menu.modules.cookingGuide), Ie = S(() => {
815
- const s = ze(e.menu.modules.sku);
815
+ const s = Le(e.menu.modules.sku);
816
816
  return x(s, { selector: "code" });
817
817
  }), U = S(() => {
818
- const s = !e.currentCatalogId, d = r.value === L.F_MENU_VERSION.v4, y = !e.currentSchedulerId, g = {
818
+ const s = !e.currentCatalogId, d = r.value === z.F_MENU_VERSION.v4, y = !e.currentSchedulerId, g = {
819
819
  create: s && y,
820
820
  edit: s && y,
821
821
  delete: s && y
@@ -895,10 +895,10 @@ const Ft = Ye(
895
895
  }
896
896
  const ke = S(() => {
897
897
  var g;
898
- const s = ["SV5", "SV10"], d = Be.Country.getCountryFlattenTaxes(
898
+ const s = ["SV5", "SV10"], d = qe.Country.getCountryFlattenTaxes(
899
899
  se().currentCountry.value
900
900
  ), y = d.filter((_) => a.value || !s.includes(_.taxCode)).map((_) => ({
901
- label: `${_.name} (${qe(_.rate)}%)`,
901
+ label: `${_.name} (${Be(_.rate)}%)`,
902
902
  value: W(_),
903
903
  meta: {
904
904
  rate: _.rate
@@ -922,11 +922,11 @@ const Ft = Ye(
922
922
  e.currentCatalogId = s;
923
923
  }, Oe = (s) => {
924
924
  e.currentSchedulerId = s;
925
- }, Te = (s) => {
925
+ }, De = (s) => {
926
926
  e.currentCategoryIds = s;
927
927
  }, Ve = (s) => {
928
928
  e.currentRestaurantAttrParams = s;
929
- }, De = async (s, d) => {
929
+ }, Te = async (s, d) => {
930
930
  const y = Array.isArray(s) ? s : [s];
931
931
  if (!y.length) return;
932
932
  const g = y.map((_) => ({
@@ -936,7 +936,7 @@ const Ft = Ye(
936
936
  }));
937
937
  try {
938
938
  if (d || g.some(
939
- (A) => [q.F_OPERATION_TYPE.delete, q.F_OPERATION_TYPE.deleteMany].includes(A.operation)
939
+ (A) => [B.F_OPERATION_TYPE.delete, B.F_OPERATION_TYPE.deleteMany].includes(A.operation)
940
940
  )) {
941
941
  const A = await Ge(g, e.menu.modules);
942
942
  if (A !== !0) throw new Error(A);
@@ -950,7 +950,7 @@ const Ft = Ye(
950
950
  message: _
951
951
  });
952
952
  }
953
- }, Ke = async (s) => {
953
+ }, Fe = async (s) => {
954
954
  const d = {
955
955
  ...e.menu,
956
956
  masterCatalogSetting: s.masterCatalogSetting,
@@ -958,14 +958,14 @@ const Ft = Ye(
958
958
  priceTierSettings: s.priceTierSettings
959
959
  };
960
960
  return f(d), d;
961
- }, T = St({ maxHistorySize: 50 }), Pe = S(() => T.canUndo.value), Fe = S(() => T.canRedo.value), $e = () => {
962
- const s = T.undo();
963
- s && f(s, !1);
964
- }, Ne = () => {
965
- const s = T.redo();
961
+ }, D = St({ maxHistorySize: 50 }), Ke = S(() => D.canUndo.value), Pe = S(() => D.canRedo.value), $e = () => {
962
+ const s = D.undo();
966
963
  s && f(s, !1);
967
964
  }, je = () => {
968
- T.clear();
965
+ const s = D.redo();
966
+ s && f(s, !1);
967
+ }, Ne = () => {
968
+ D.clear();
969
969
  };
970
970
  return {
971
971
  state: e,
@@ -989,7 +989,7 @@ const Ft = Ye(
989
989
  sortedItems: ye,
990
990
  categorizedItems: he,
991
991
  categorizedRawMenuItems: pe,
992
- variants: j,
992
+ variants: N,
993
993
  groups: _e,
994
994
  takeaways: Se,
995
995
  printDepartments: be,
@@ -1005,10 +1005,10 @@ const Ft = Ye(
1005
1005
  readRestaurants: xe,
1006
1006
  selectCatalog: te,
1007
1007
  selectScheduler: Oe,
1008
- selectCategory: Te,
1008
+ selectCategory: De,
1009
1009
  setRestaurantAttrParams: Ve,
1010
- updateMenu: De,
1011
- updateMenuSetting: Ke,
1010
+ updateMenu: Te,
1011
+ updateMenuSetting: Fe,
1012
1012
  computeMergedMenu: p,
1013
1013
  // helper
1014
1014
  encodeTax: W,
@@ -1016,27 +1016,27 @@ const Ft = Ye(
1016
1016
  getSelectedTax: Re,
1017
1017
  mapVariant: ge,
1018
1018
  // history
1019
- canUndoHistory: Pe,
1020
- canRedoHistory: Fe,
1019
+ canUndoHistory: Ke,
1020
+ canRedoHistory: Pe,
1021
1021
  undoHistory: $e,
1022
- redoHistory: Ne,
1022
+ redoHistory: je,
1023
1023
  // cleanup
1024
1024
  $dispose: () => {
1025
- w.cancel(), R && (R(), R = null), C && (C.stop(), C = null), je();
1025
+ w.cancel(), R && (R(), R = null), C && (C.stop(), C = null), Ne();
1026
1026
  },
1027
1027
  $reinitialize: () => {
1028
- Q();
1028
+ X();
1029
1029
  }
1030
1030
  };
1031
1031
  }
1032
1032
  );
1033
1033
  export {
1034
1034
  Vt as a,
1035
- Dt as b,
1036
- Kt as c,
1037
- Pt as f,
1038
- Tt as g,
1035
+ Tt as b,
1036
+ Ft as c,
1037
+ Kt as f,
1038
+ Dt as g,
1039
1039
  Ot as m,
1040
1040
  at as o,
1041
- Ft as u
1041
+ Pt as u
1042
1042
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as d, ref as g, watch as _, resolveComponent as S, createBlock as T, openBlock as f, unref as y, computed as h } from "vue";
2
2
  import { useI18n as m } from "@feedmepos/mf-common";
3
3
  import { useDialogChild as w, useDialog as x, useSnackbar as C } from "@feedmepos/ui-library";
4
- import { u as k, D as M } from "./menu-CiZ9jI7P.js";
4
+ import { u as k, D as M } from "./menu-DXzZVB-B.js";
5
5
  const v = /* @__PURE__ */ d({
6
6
  __name: "AddPriceGroupDialog",
7
7
  setup(s) {
@@ -1,11 +1,11 @@
1
1
  import { defineComponent as ie, computed as Y, resolveComponent as _, createElementBlock as d, openBlock as u, createVNode as t, createCommentVNode as F, unref as n, toDisplayString as A, createElementVNode as h, withCtx as v, Fragment as N, renderList as M, createBlock as I, ref as H, Transition as se, createTextVNode as me } from "vue";
2
- import { H as S, z as r, u as pe, I as ve, J as ue } from "./menu-CiZ9jI7P.js";
2
+ import { H as S, z as r, u as pe, I as ve, J as ue } from "./menu-DXzZVB-B.js";
3
3
  import { useI18n as de } from "@feedmepos/mf-common";
4
4
  import { components as _e } from "@feedmepos/ui-library";
5
- import { _ as ne, a as fe } from "./customAttributes-DEfSmlRQ.js";
5
+ import { _ as ne, a as fe } from "./customAttributes-DRG3HAvt.js";
6
6
  import { u as ye } from "./discardConfirm-BHni0LNu.js";
7
- import { u as he } from "./menu-qc8oftWK.js";
8
- import { L as ge } from "./LinkProductSideSheet-tkbRMtn3.js";
7
+ import { u as he } from "./menu-CnXHE9uW.js";
8
+ import { L as ge } from "./LinkProductSideSheet-BjumT4OD.js";
9
9
  const Ve = { class: "space-y-8" }, Fe = {
10
10
  key: 0,
11
11
  class: "space-y-16"
@@ -1,8 +1,8 @@
1
1
  import { defineComponent as M, watch as _, ref as E, resolveComponent as f, createBlock as x, openBlock as C, unref as c, withCtx as V, createVNode as A } from "vue";
2
- import { J as l, z as d, u as F } from "./menu-CiZ9jI7P.js";
2
+ import { J as l, z as d, u as F } from "./menu-DXzZVB-B.js";
3
3
  import { useI18n as b } from "@feedmepos/mf-common";
4
4
  import { useDialogChild as P } from "@feedmepos/ui-library";
5
- import { u as v } from "./menuV2-BndWMdLg.js";
5
+ import { u as v } from "./menuV2-CZB1IGtm.js";
6
6
  const y = /* @__PURE__ */ M({
7
7
  __name: "AddSubcategoryDialogContentComponent",
8
8
  props: {
@@ -1,5 +1,5 @@
1
- import { u as C } from "./ImportProductDialog.vue_vue_type_script_setup_true_lang-CD668o_s.js";
2
- import "./menu-CiZ9jI7P.js";
1
+ import { u as C } from "./ImportProductDialog.vue_vue_type_script_setup_true_lang-DXRTOqPv.js";
2
+ import "./menu-DXzZVB-B.js";
3
3
  var Z = {
4
4
  defaultAmount: 0,
5
5
  defaultCurrency: "USD",
@@ -1,13 +1,13 @@
1
1
  import { defineStore as J } from "pinia";
2
2
  import { defineComponent as O, computed as w, ref as h, watch as T, resolveComponent as _, createBlock as W, openBlock as F, withCtx as x, createVNode as d, createElementVNode as b, normalizeClass as Q, createElementBlock as A, toDisplayString as M, unref as l, Fragment as q, renderSlot as X, renderList as Z, getCurrentInstance as ee } from "vue";
3
- import { a5 as B, a6 as te, a3 as P, H as k, O as $, D as I, B as E, a4 as ne, J as C, z as D, I as ae, u as oe } from "./menu-CiZ9jI7P.js";
3
+ import { a5 as B, a6 as te, a3 as P, H as k, O as $, D as I, B as E, a4 as ne, J as C, z as D, I as ae, u as oe } from "./menu-DXzZVB-B.js";
4
4
  import { useI18n as L } from "@feedmepos/mf-common";
5
5
  import { useSnackbar as j, components as le, useDialog as ue, FmButtonVariant as ie } from "@feedmepos/ui-library";
6
6
  import { u as se } from "./discardConfirm-BHni0LNu.js";
7
7
  import { c as me } from "./check-C9mY6LiX.js";
8
8
  import "./vuedraggable-DnBIRDMr.js";
9
9
  import "./app-CzXxFrl1.js";
10
- import "./menuV2-BndWMdLg.js";
10
+ import "./menuV2-CZB1IGtm.js";
11
11
  /* empty css */
12
12
  import { c as re } from "./createComponentProgrammatically-Bt2rn1IQ.js";
13
13
  const de = ["value", "disabled"], ce = /* @__PURE__ */ O({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@feedmepos/mf-menu",
3
- "version": "0.31.76-beta.1",
3
+ "version": "0.31.76-prod",
4
4
  "files": [
5
5
  "dist"
6
6
  ],