@feedmepos/mf-menu 0.20.2 → 0.20.3

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 (58) hide show
  1. package/dist/App-DGK08eRV.js +18860 -0
  2. package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-Ds2qfY_X.js → ApplyProduct.vue_vue_type_script_setup_true_lang-DY5ZAvXD.js} +10 -10
  3. package/dist/{ApplyProducts.vue_vue_type_script_setup_true_lang-BRepaPR3.js → ApplyProducts.vue_vue_type_script_setup_true_lang-CTQXFXig.js} +2 -2
  4. package/dist/{Catalog-S5KDEWzG.js → Catalog-DDLkwHEl.js} +3 -3
  5. package/dist/{Category-DLaNEtA5.js → Category-Dvijo086.js} +6 -6
  6. package/dist/{CookingGuide-DSGZapxz.js → CookingGuide-CsE9_yha.js} +4 -4
  7. package/dist/{Group-CBMSkmwQ.js → Group-BIQU7w0g.js} +1 -1
  8. package/dist/{Group-B0VQ-64x.js → Group-CMMIHqaG.js} +6 -6
  9. package/dist/{Group.vue_vue_type_script_setup_true_lang-DKzrhXtM.js → Group.vue_vue_type_script_setup_true_lang-BTL9j3_B.js} +70 -70
  10. package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-BV-FC8tM.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-pogjGaYM.js} +23 -23
  11. package/dist/{Ingredient-CnPQ0kiR.js → Ingredient-m0hSAC1U.js} +16 -16
  12. package/dist/{LinkProductSideSheet-A26Otbdm.js → LinkProductSideSheet-DfZrxiHw.js} +30 -29
  13. package/dist/{PrintRoute-BlJMdPP0.js → PrintRoute-iSOdrR8L.js} +27 -27
  14. package/dist/{Product-BvD813LL.js → Product-LV9usgIQ.js} +1 -1
  15. package/dist/{Product.vue_vue_type_script_setup_true_lang-D_oKtXbh.js → Product.vue_vue_type_script_setup_true_lang-D2840VfX.js} +67 -67
  16. package/dist/{Products-B8Ok-bkN.js → Products-C3u76O52.js} +37 -37
  17. package/dist/{Publish-qBiJUQ4X.js → Publish-_OkfKSnM.js} +69 -69
  18. package/dist/{Recipe-CJxJJAUV.js → Recipe-CB_uktjY.js} +34 -34
  19. package/dist/{Scheduler-DfAMwXCu.js → Scheduler-DWIGrzZY.js} +2 -2
  20. package/dist/{SchedulerSelector.vue_vue_type_script_setup_true_lang-CArE_Hua.js → SchedulerSelector.vue_vue_type_script_setup_true_lang-BcruguLb.js} +1 -1
  21. package/dist/ServingSequence-Cq1ZZlrm.js +4 -0
  22. package/dist/{Setting-BbgJcWsN.js → Setting-N_eRQUsY.js} +1 -1
  23. package/dist/{Setting.vue_vue_type_script_setup_true_lang-BbVEzNve.js → Setting.vue_vue_type_script_setup_true_lang-WQ6hWgnm.js} +13 -13
  24. package/dist/{Takeaway-CMDFYeUw.js → Takeaway-DiOnksOz.js} +1 -1
  25. package/dist/{Takeaway-wAXsZQN2.js → Takeaway-NrqUpXFx.js} +9 -9
  26. package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-DSphRs_i.js → Takeaway.vue_vue_type_script_setup_true_lang-CHAbaRBT.js} +9 -9
  27. package/dist/{TaxSetting-C1XOTv-9.js → TaxSetting-V0dnzYo3.js} +6 -6
  28. package/dist/{Unit-BW3iqgp8.js → Unit-DOsZE2qJ.js} +15 -15
  29. package/dist/{Variant-BJIxp9PJ.js → Variant-CYP1P6ns.js} +40 -40
  30. package/dist/{_id_-B25OxuPV.js → _id_-B6Hne1hp.js} +34 -34
  31. package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
  32. package/dist/app-D2FqvCaC.js +127479 -0
  33. package/dist/app.js +4 -4
  34. package/dist/assets/linked-status-B-90MiJw.js +24 -0
  35. package/dist/assets/validate-menu-C1LwcZzw.js +24 -0
  36. package/dist/{catalog-B-Z6lEFK.js → catalog-Bq6JWNgk.js} +1 -1
  37. package/dist/{catalog-Do7RfIKm.js → catalog-C8CFP-ny.js} +22549 -22547
  38. package/dist/{category-DEWEor3m.js → category-DJo3MbY6.js} +14 -14
  39. package/dist/{currency-33gUke3q.js → currency-Ccc8KrCJ.js} +1 -1
  40. package/dist/index-BS64cx1H.js +7392 -0
  41. package/dist/{index-BEdHzZvu.js → index-PJVryAUX.js} +14 -14
  42. package/dist/{item-BooojPpg.js → item-Dj35T3VU.js} +940 -938
  43. package/dist/{lodash-247YxYiQ.js → lodash-MHSu1pkA.js} +439 -439
  44. package/dist/{menu-DCnWrgH7.js → menu-CUXJ9cXY.js} +1 -1
  45. package/dist/{object-B2cP_UeG.js → object-BN9wCbKv.js} +19 -19
  46. package/dist/remy-BWBsUWuo.js +36 -0
  47. package/dist/{scheduler-0cChIv2I.js → scheduler-DZwOVztH.js} +4 -4
  48. package/dist/style.css +1 -1
  49. package/dist/{takeaway-mwqVQ1ij.js → takeaway-PjB5BC80.js} +17 -17
  50. package/dist/{toExcel-Dha8Vf3u.js → toExcel-D9nGg3_g.js} +237 -237
  51. package/dist/{unit-BgfdgXAu.js → unit-97ZKmnbi.js} +12 -12
  52. package/dist/{vuedraggable-BEszc36M.js → vuedraggable-WU01qJgi.js} +110 -110
  53. package/package.json +1 -1
  54. package/dist/ServingSequence-DxDMeto7.js +0 -4
  55. package/dist/app-BFJlAowN.js +0 -135983
  56. package/dist/assets/linked-status-4i88AmvK.js +0 -24
  57. package/dist/assets/validate-menu-CTKwgXfw.js +0 -24
  58. package/dist/index-BXl09ebx.js +0 -21908
@@ -1,21 +1,21 @@
1
- import { ref as D, computed as g, defineComponent as ce, resolveComponent as q, openBlock as b, createBlock as G, withCtx as M, createVNode as i, createElementVNode as f, toDisplayString as Q, unref as l, createElementBlock as z, Fragment as xe, renderList as De, createTextVNode as Ze, mergeModels as Je, useModel as Qe, onMounted as Xe, renderSlot as he, watch as pe, h as A, withModifiers as Ve, createCommentVNode as ue, resolveDynamicComponent as et, normalizeStyle as tt, normalizeClass as se, nextTick as lt, watchEffect as at } from "vue";
2
- import { u as ye, a as Ne, c as ve, x as fe, F as ot, y as nt, k as ie, g as rt, z as Fe, i as je } from "./app-BFJlAowN.js";
3
- import { _ as $e } from "./SchedulerSelector.vue_vue_type_script_setup_true_lang-CArE_Hua.js";
4
- import { useI18n as Ce, useCoreStore as Ue } from "@feedmepos/mf-common";
5
- import { useSnackbar as Be, useDialog as Ae, components as re, FmButtonVariant as H, FmButtonColorThemeVariant as R, useBreakpoints as Ee } from "@feedmepos/ui-library";
1
+ import { ref as D, computed as g, defineComponent as ce, resolveComponent as q, openBlock as b, createBlock as G, withCtx as M, createVNode as i, createElementVNode as f, toDisplayString as Q, unref as l, createElementBlock as z, Fragment as xe, renderList as De, createTextVNode as Ze, mergeModels as Je, useModel as Qe, onMounted as Xe, renderSlot as he, watch as pe, h as E, withModifiers as Ve, createCommentVNode as ue, resolveDynamicComponent as et, normalizeStyle as tt, normalizeClass as se, nextTick as lt, watchEffect as at } from "vue";
2
+ import { u as ye, b as Ne, d as ve, B as fe, F as ot, C as nt, o as ie, j as rt, E as Fe, l as je } from "./app-D2FqvCaC.js";
3
+ import { _ as $e } from "./SchedulerSelector.vue_vue_type_script_setup_true_lang-BcruguLb.js";
4
+ import { useI18n as Ce, useCoreStore as Be } from "@feedmepos/mf-common";
5
+ import { useSnackbar as Ue, useDialog as Ee, components as re, FmButtonVariant as H, FmButtonColorThemeVariant as R, useBreakpoints as Ae } from "@feedmepos/ui-library";
6
6
  import "vue-router";
7
- import { u as ge } from "./menu-DCnWrgH7.js";
8
- import { u as Ke } from "./category-DEWEor3m.js";
9
- import "./vuedraggable-BEszc36M.js";
10
- import { s as st, _ as ut, c as Te, a as it, u as ct } from "./catalog-Do7RfIKm.js";
11
- import { _ as dt } from "./takeaway-mwqVQ1ij.js";
12
- import { f as mt } from "./currency-33gUke3q.js";
13
- import { l as be } from "./lodash-247YxYiQ.js";
14
- import { u as Le, m as pt } from "./item-BooojPpg.js";
7
+ import { u as ge } from "./menu-CUXJ9cXY.js";
8
+ import { u as Ke } from "./category-DJo3MbY6.js";
9
+ import "./vuedraggable-WU01qJgi.js";
10
+ import { s as st, _ as ut, c as Te, a as it, u as ct } from "./catalog-C8CFP-ny.js";
11
+ import { _ as dt } from "./takeaway-PjB5BC80.js";
12
+ import { f as mt } from "./currency-Ccc8KrCJ.js";
13
+ import { l as be } from "./lodash-MHSu1pkA.js";
14
+ import { u as Le, m as pt } from "./item-Dj35T3VU.js";
15
15
  import { w as vt } from "./InfoBasic.vue_vue_type_script_setup_true_lang-DxQBDu16.js";
16
- import { F as ft } from "./object-B2cP_UeG.js";
16
+ import { F as ft } from "./object-BN9wCbKv.js";
17
17
  import { _ as Ie } from "./TextChip.vue_vue_type_script_setup_true_lang-CNp85hoQ.js";
18
- import { L as Me } from "./LinkProductSideSheet-A26Otbdm.js";
18
+ import { L as Me } from "./LinkProductSideSheet-DfZrxiHw.js";
19
19
  function bt(O, d) {
20
20
  const m = D(!0), r = g(() => {
21
21
  var p, y;
@@ -47,7 +47,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
47
47
  set: (k) => {
48
48
  d.selectCategory(k);
49
49
  }
50
- }), { allCleared: Y, allSelected: T, toggleAll: Z, toggleOption: J, indeterminate: E } = bt(n, _);
50
+ }), { allCleared: Y, allSelected: T, toggleAll: Z, toggleOption: J, indeterminate: A } = bt(n, _);
51
51
  return (k, c) => {
52
52
  const N = q("FmIcon"), K = q("FmChip"), L = q("FmSearch"), ae = q("FmMenuItem"), X = q("FmMenu");
53
53
  return b(), G(X, {
@@ -80,7 +80,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
80
80
  label: "All",
81
81
  "has-checkbox": "",
82
82
  "model-value": l(T),
83
- indeterminate: l(E),
83
+ indeterminate: l(A),
84
84
  onClick: l(Z)
85
85
  }, null, 8, ["model-value", "indeterminate", "onClick"]),
86
86
  (b(!0), z(xe, null, De(W.value, (j) => {
@@ -90,7 +90,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
90
90
  label: j.label,
91
91
  "has-checkbox": "",
92
92
  "model-value": l(T) || ((w = _.value) == null ? void 0 : w.includes(j.value)),
93
- onClick: (U) => l(J)(j.value)
93
+ onClick: (B) => l(J)(j.value)
94
94
  }, null, 8, ["label", "model-value", "onClick"]);
95
95
  }), 128))
96
96
  ])
@@ -132,7 +132,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
132
132
  function m() {
133
133
  d.value = !d.value;
134
134
  }
135
- const r = Ue();
135
+ const r = Be();
136
136
  return Xe(() => {
137
137
  const S = r.currentCountry.value;
138
138
  S && st(S);
@@ -183,14 +183,14 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
183
183
  class: "flex-1 min-w-0"
184
184
  }, jt = {
185
185
  class: "flex justify-between items-center gap-8 pb-4"
186
- }, Ut = {
187
- class: "flex-1 min-w-0 fm-typo-en-body-lg-600 line-clamp-2"
188
186
  }, Bt = {
189
- class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
190
- }, At = {
187
+ class: "flex-1 min-w-0 fm-typo-en-body-lg-600 line-clamp-2"
188
+ }, Ut = {
191
189
  class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
192
190
  }, Et = {
193
191
  class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
192
+ }, At = {
193
+ class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
194
194
  }, Kt = {
195
195
  key: 1
196
196
  }, Lt = {
@@ -210,7 +210,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
210
210
  }) {
211
211
  const m = O, {
212
212
  t: r
213
- } = Ce(), S = Ue(), n = ye(), W = Be(), p = Ae(), y = Ne(W), $ = je(y);
213
+ } = Ce(), S = Be(), n = ye(), W = Ue(), p = Ee(), y = Ne(W), $ = je(y);
214
214
  Ke({
215
215
  dialog: p,
216
216
  menuLoader: $
@@ -221,13 +221,13 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
221
221
  g(() => J.value.length === 1 && J.value[0].id === null);
222
222
  const {
223
223
  selectedCategories: J
224
- } = ge(), E = g(() => be.flatten(J.value.map((e) => e.items))), k = d, c = D(!1);
224
+ } = ge(), A = g(() => be.flatten(J.value.map((e) => e.items))), k = d, c = D(!1);
225
225
  pe(() => c.value, (e) => {
226
226
  k("update:editing", e);
227
227
  });
228
228
  const N = (e) => {
229
229
  rt.isBoolean(e) ? c.value = e : c.value = !c.value;
230
- }, K = D(""), L = g(() => E.value.filter((e) => {
230
+ }, K = D(""), L = g(() => A.value.filter((e) => {
231
231
  var o;
232
232
  return !K.value || !K.value.trim() ? !0 : `${e.code} ${e.name} ${ke(e)} ${X(e.category || null)} ${(o = fe()[e.orderFrom]) == null ? void 0 : o.label}`.toLowerCase().includes(K.value.toLowerCase());
233
233
  })), {
@@ -242,9 +242,9 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
242
242
  ...u,
243
243
  [t]: o
244
244
  }, k("update:model-value", a));
245
- }, w = be.debounce(j, 300), U = (e) => (t) => !!t || r("menu.product.table.validation.name_required", {
245
+ }, w = be.debounce(j, 300), B = (e) => (t) => !!t || r("menu.product.table.validation.name_required", {
246
246
  field: e
247
- }), V = (e) => e >= 0 || r("menu.product.table.validation.price_min"), F = [U("Name")], x = () => [(e) => V(typeof e == "number" ? e : Number(e) ?? 0)], P = fe(), B = D([{
247
+ }), V = (e) => e >= 0 || r("menu.product.table.validation.price_min"), F = [B("Name")], x = () => [(e) => V(typeof e == "number" ? e : Number(e) ?? 0)], P = fe(), U = D([{
248
248
  accessorKey: "thumbnail",
249
249
  header: "",
250
250
  size: 64,
@@ -254,7 +254,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
254
254
  },
255
255
  cell: (e) => {
256
256
  var t, o;
257
- return A(Te, {
257
+ return E(Te, {
258
258
  src: e.getValue(),
259
259
  alt: (o = (t = e == null ? void 0 : e.row) == null ? void 0 : t.original) == null ? void 0 : o.name,
260
260
  className: "my-8 mx-12",
@@ -271,7 +271,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
271
271
  const t = e.row.original, o = e.getValue() || "--";
272
272
  if (!c.value) return o;
273
273
  const a = _e(t._id);
274
- return A(re.FmTextField, {
274
+ return E(re.FmTextField, {
275
275
  disabled: !Z.value.code,
276
276
  modelValue: a == null ? void 0 : a.code,
277
277
  placeholder: m.modelValue[t._id].fallbackCode,
@@ -287,7 +287,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
287
287
  size: 240,
288
288
  cell: (e) => {
289
289
  const t = e.row.original, o = e.getValue();
290
- return c.value ? A(re.FmTextField, {
290
+ return c.value ? E(re.FmTextField, {
291
291
  disabled: !Z.value.name,
292
292
  modelValue: t.name,
293
293
  "onUpdate:modelValue": (a) => {
@@ -315,7 +315,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
315
315
  const t = e.getValue();
316
316
  if (!c.value) return ve.Dinero.fromFdoDinero(t).toFormat();
317
317
  const o = m.modelValue[e.row.original._id], a = o.fallbackPrice;
318
- return A(dt, {
318
+ return E(dt, {
319
319
  min: 0,
320
320
  disabled: !o.editPrice,
321
321
  // @ts-ignore
@@ -341,7 +341,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
341
341
  if (!c.value)
342
342
  return `${h != null && h.meta.rate ? ot(h.meta.rate) : 0}%`;
343
343
  const s = n.getSelectedTax(t, o.fallbackTaxes, n.taxSetting.countryTaxOptions);
344
- return A(re.FmSelect, {
344
+ return E(re.FmSelect, {
345
345
  disabled: !Z.value.tax,
346
346
  items: n.taxSetting.countryTaxOptions,
347
347
  modelValue: s,
@@ -358,7 +358,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
358
358
  size: 140,
359
359
  cell: (e) => {
360
360
  const t = e.row.original;
361
- return c.value ? A(_t, {
361
+ return c.value ? E(_t, {
362
362
  "model-value": m.modelValue[t._id].category,
363
363
  disabled: !!(n.state.currentCatalogId || n.state.currentSchedulerId),
364
364
  "onUpdate:modelValue": async (o) => {
@@ -378,14 +378,14 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
378
378
  cell: (e) => {
379
379
  var u, h;
380
380
  const t = e.getValue(), o = e.row.original, a = fe();
381
- return c.value ? A(re.FmSelect, {
381
+ return c.value ? E(re.FmSelect, {
382
382
  disabled: !Z.value.orderFrom,
383
383
  items: Object.values(fe()),
384
384
  modelValue: t,
385
385
  "onUpdate:modelValue": async (s) => {
386
386
  j(o._id, "orderFrom", s);
387
387
  }
388
- }) : A(Ie, {
388
+ }) : E(Ie, {
389
389
  label: (u = a[t]) == null ? void 0 : u.label,
390
390
  variant: (h = a[t]) == null ? void 0 : h.variant
391
391
  });
@@ -398,9 +398,9 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
398
398
  headerClass: "py-4",
399
399
  textAlign: "right"
400
400
  },
401
- header: () => A("div", {
401
+ header: () => E("div", {
402
402
  class: "w-full px-4 flex justify-end"
403
- }, [vt(A(re.FmButton, {
403
+ }, [vt(E(re.FmButton, {
404
404
  variant: H.Tertiary,
405
405
  textColor: R.NeutralGray400,
406
406
  prependIcon: "edit",
@@ -410,9 +410,9 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
410
410
  }), "Bulk edit")]),
411
411
  cell: (e) => {
412
412
  const t = e.row.original;
413
- return A("div", {
413
+ return E("div", {
414
414
  class: "px-4 flex justify-end"
415
- }, [A(re.FmButton, {
415
+ }, [E(re.FmButton, {
416
416
  icon: "delete",
417
417
  variant: "tertiary",
418
418
  textColor: R.NeutralGray400,
@@ -426,7 +426,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
426
426
  })]);
427
427
  }
428
428
  }]);
429
- n.taxSetting.systemCode || B.value.splice(4, 1);
429
+ n.taxSetting.systemCode || U.value.splice(4, 1);
430
430
  const C = D({}), v = D([]);
431
431
  pe([() => C.value, () => L.value], (e) => {
432
432
  let t = [];
@@ -434,7 +434,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
434
434
  const a = e[0][o], u = L.value[parseInt(o)];
435
435
  u && (a ? t.push(u) : v.value = t.filter((h) => h !== u));
436
436
  }), v.value = t;
437
- }), pe(() => E.value, () => {
437
+ }), pe(() => A.value, () => {
438
438
  C.value = {}, v.value = [];
439
439
  }), pe(() => c.value, () => {
440
440
  C.value = {}, v.value = [];
@@ -516,9 +516,9 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
516
516
  _id: o
517
517
  };
518
518
  return ((a = u == null ? void 0 : u.items) == null ? void 0 : a.filter((s) => s._id === e))[0];
519
- } else return t ? t.override.items[e][0] : o ? n.schedulers.find((s) => s._id === o).items.filter((s) => s._id === e)[0] : E.value.find((u) => u._id === e);
519
+ } else return t ? t.override.items[e][0] : o ? n.schedulers.find((s) => s._id === o).items.filter((s) => s._id === e)[0] : A.value.find((u) => u._id === e);
520
520
  }
521
- const qe = Ee(), We = g(() => qe.breakpoints.value.xs), Se = D(null), Ye = nt(Se), He = g(() => {
521
+ const qe = Ae(), We = g(() => qe.breakpoints.value.xs), Se = D(null), Ye = nt(Se), He = g(() => {
522
522
  var t;
523
523
  return {
524
524
  height: `calc(100vh - ${((t = Ye.value) == null ? void 0 : t.top) + 24}px)`
@@ -533,7 +533,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
533
533
  placeholder: l(r)("menu.product.table.search.placeholder")
534
534
  }, null, 8, ["model-value", "placeholder"])]), t[6] || (t[6] = f("div", {
535
535
  class: "w-full h-[1px] bg-fm-color-neutral-gray-100"
536
- }, null, -1)), f("div", Ot, [he(e.$slots, "filter")])]), E.value.length ? (b(), z("div", Pt, [(b(!0), z(xe, null, De(L.value, (s) => {
536
+ }, null, -1)), f("div", Ot, [he(e.$slots, "filter")])]), A.value.length ? (b(), z("div", Pt, [(b(!0), z(xe, null, De(L.value, (s) => {
537
537
  var le, me, we;
538
538
  return b(), z("div", {
539
539
  key: s._id,
@@ -543,10 +543,10 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
543
543
  alt: s.name,
544
544
  size: 72,
545
545
  src: s.thumbnail
546
- }, null, 8, ["alt", "src"]), f("div", Nt, [f("div", jt, [f("p", Ut, Q(s.name), 1), i(Ie, {
546
+ }, null, 8, ["alt", "src"]), f("div", Nt, [f("div", jt, [f("p", Bt, Q(s.name), 1), i(Ie, {
547
547
  label: (le = l(P)[s.orderFrom || ""]) == null ? void 0 : le.label,
548
548
  variant: (me = l(P)[s.orderFrom || ""]) == null ? void 0 : me.variant
549
- }, null, 8, ["label", "variant"])]), f("p", Bt, Q(ke(s)), 1), f("p", At, Q(l(r)("menu.product.table.columns.code")) + ": " + Q(((we = _e(s._id)) == null ? void 0 : we.code) || "--"), 1), f("p", Et, Q(l(r)("menu.product.table.columns.category")) + ": " + Q(X(s.category || null)), 1)])]), i(a, {
549
+ }, null, 8, ["label", "variant"])]), f("p", Ut, Q(ke(s)), 1), f("p", Et, Q(l(r)("menu.product.table.columns.code")) + ": " + Q(((we = _e(s._id)) == null ? void 0 : we.code) || "--"), 1), f("p", At, Q(l(r)("menu.product.table.columns.category")) + ": " + Q(X(s.category || null)), 1)])]), i(a, {
550
550
  "text-color": l(R).NeutralGray400,
551
551
  variant: l(H).Tertiary,
552
552
  "prepend-icon": "delete",
@@ -590,7 +590,7 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
590
590
  "onUpdate:modelValue": t[0] || (t[0] = (s) => K.value = s),
591
591
  autofocus: "",
592
592
  placeholder: l(r)("menu.product.table.search.placeholder")
593
- }, null, 8, ["model-value", "placeholder"])])]), E.value.length ? (b(), z("div", kt, [v.value.length && !c.value ? (b(), z("div", St, [f("p", wt, Q(l(r)("menu.product.table.selection.count", {
593
+ }, null, 8, ["model-value", "placeholder"])])]), A.value.length ? (b(), z("div", kt, [v.value.length && !c.value ? (b(), z("div", St, [f("p", wt, Q(l(r)("menu.product.table.selection.count", {
594
594
  count: v.value.length
595
595
  })), 1), i(a, {
596
596
  label: l(r)("menu.product.table.selection.actions.deselect_all"),
@@ -646,10 +646,10 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
646
646
  }),
647
647
  modelValue: C.value,
648
648
  "onUpdate:modelValue": t[1] || (t[1] = (s) => C.value = s),
649
- "column-defs": B.value,
649
+ "column-defs": U.value,
650
650
  "column-visibility": de.value,
651
651
  loading: e.isCalculating,
652
- "page-size": E.value.length,
652
+ "page-size": A.value.length,
653
653
  "row-data": L.value,
654
654
  selection: c.value ? void 0 : "multiple",
655
655
  "shrink-at": !1,
@@ -697,49 +697,49 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
697
697
  }, Ht = { class: "flex items-center gap-8 px-16" }, vl = /* @__PURE__ */ ce({
698
698
  __name: "Product",
699
699
  setup(O) {
700
- const d = Ae(), m = Be(), r = Ne(m), S = je(r);
700
+ const d = Ee(), m = Ue(), r = Ne(m), S = je(r);
701
701
  Ke({
702
702
  dialog: d,
703
703
  menuLoader: S
704
704
  });
705
- const n = ye(), W = g(() => n.rules.item), p = it(), y = Le(), $ = ct(), _ = g(() => !n.state.currentCatalogId), Y = g(() => n.rules.item), T = g(() => !n.state.currentSchedulerId), Z = D(!1), J = D(!1), E = g(() => {
705
+ const n = ye(), W = g(() => n.rules.item), p = it(), y = Le(), $ = ct(), _ = g(() => !n.state.currentCatalogId), Y = g(() => n.rules.item), T = g(() => !n.state.currentSchedulerId), Z = D(!1), J = D(!1), A = g(() => {
706
706
  var V, F, x, P;
707
707
  if (_.value && T.value) return;
708
708
  if (T.value) {
709
- const B = (V = n.currentCatalog) == null ? void 0 : V.override.items;
710
- return B ? Object.entries(B).reduce((C, [v, ee]) => {
709
+ const U = (V = n.currentCatalog) == null ? void 0 : V.override.items;
710
+ return U ? Object.entries(U).reduce((C, [v, ee]) => {
711
711
  const I = ee.find((oe) => !oe.combinationKey);
712
712
  return I && (C[v] = I), C;
713
713
  }, {}) : {};
714
714
  }
715
- return ((_.value ? (F = n.currentScheduler) == null ? void 0 : F.items : (P = (x = n.currentCatalog) == null ? void 0 : x.override.scheduler[n.state.currentSchedulerId]) == null ? void 0 : P.items) ?? []).reduce((B, C) => (C.combinationKey || (B[C._id] = C), B), {});
715
+ return ((_.value ? (F = n.currentScheduler) == null ? void 0 : F.items : (P = (x = n.currentCatalog) == null ? void 0 : x.override.scheduler[n.state.currentSchedulerId]) == null ? void 0 : P.items) ?? []).reduce((U, C) => (C.combinationKey || (U[C._id] = C), U), {});
716
716
  }), k = D({}), c = D({}), N = async () => {
717
- var P, B;
717
+ var P, U;
718
718
  J.value = !0;
719
- const U = !!E.value, V = be.flatten(L.value.map((C) => C.items)), F = U && Z.value ? await pt(
719
+ const B = !!A.value, V = be.flatten(L.value.map((C) => C.items)), F = B && Z.value ? await pt(
720
720
  n.mergedMenu,
721
721
  V,
722
722
  n.state.menu,
723
723
  (P = n.currentCatalog) == null ? void 0 : P._id,
724
- (B = n.currentScheduler) == null ? void 0 : B._id,
724
+ (U = n.currentScheduler) == null ? void 0 : U._id,
725
725
  !1
726
726
  ) : void 0, x = V.reduce((C, v, ee) => {
727
727
  var oe, te, ne, de;
728
- const I = (oe = E.value) == null ? void 0 : oe[v._id];
728
+ const I = (oe = A.value) == null ? void 0 : oe[v._id];
729
729
  return C[v._id] = {
730
730
  _id: v._id,
731
731
  name: v.name,
732
- code: U ? I == null ? void 0 : I.code : v == null ? void 0 : v.code,
732
+ code: B ? I == null ? void 0 : I.code : v == null ? void 0 : v.code,
733
733
  category: v.category,
734
- price: U && Y.value.editPrice ? I == null ? void 0 : I.price : v.price,
735
- orderFrom: U ? I == null ? void 0 : I.orderFrom : v.orderFrom,
736
- taxes: U ? null : v.taxes,
734
+ price: B && Y.value.editPrice ? I == null ? void 0 : I.price : v.price,
735
+ orderFrom: B ? I == null ? void 0 : I.orderFrom : v.orderFrom,
736
+ taxes: B ? null : v.taxes,
737
737
  thumbnail: v.thumbnail,
738
738
  fallbackPrice: (te = F == null ? void 0 : F[ee]) == null ? void 0 : te.price,
739
- fallbackName: U ? v.name : void 0,
739
+ fallbackName: B ? v.name : void 0,
740
740
  fallbackCode: (ne = F == null ? void 0 : F[ee]) == null ? void 0 : ne.code,
741
741
  fallbackOrder: (de = F == null ? void 0 : F[ee]) == null ? void 0 : de.orderFrom,
742
- fallbackTaxes: U ? v.taxes : null
742
+ fallbackTaxes: B ? v.taxes : null
743
743
  }, C;
744
744
  }, {});
745
745
  k.value = x, c.value = { ...x }, J.value = !1;
@@ -752,10 +752,10 @@ const gt = { class: "p-4" }, yt = { class: "flex-1 overflow-y-auto min-h-0" }, O
752
752
  }
753
753
  const X = () => {
754
754
  L.value && N();
755
- }, j = Ee();
755
+ }, j = Ae();
756
756
  g(() => j.breakpoints.value.xs);
757
757
  const { t: w } = Ce();
758
- return (U, V) => {
758
+ return (B, V) => {
759
759
  const F = q("fm-button");
760
760
  return l(K).length ? (b(), z("div", Gt, [
761
761
  f("div", qt, [
@@ -1,15 +1,15 @@
1
- import { defineComponent as F, computed as f, ref as h, resolveComponent as S, openBlock as u, createBlock as g, unref as e, withCtx as p, createElementVNode as i, toDisplayString as U, createVNode as o, createCommentVNode as A, createElementBlock as T, Fragment as E } from "vue";
2
- import { u as L, a as j, c as I, e as P, b as H, m as G, d as J, _ as K, f as V, D as Q } from "./app-BFJlAowN.js";
1
+ import { defineComponent as F, computed as f, ref as M, resolveComponent as S, openBlock as u, createBlock as g, unref as e, withCtx as p, createElementVNode as l, toDisplayString as U, createVNode as o, createCommentVNode as A, createElementBlock as T, Fragment as E } from "vue";
2
+ import { u as L, b as j, d as I, e as P, f as H, m as G, h as J, _ as K, i as V, D as Q } from "./app-D2FqvCaC.js";
3
3
  import { useCoreStore as W, useI18n as X } from "@feedmepos/mf-common";
4
- import { useDialog as q, useDialogChild as Z, useSnackbar as z, useBreakpoints as ee, FmButtonColorThemeVariant as M, FmButtonVariant as D } from "@feedmepos/ui-library";
4
+ import { useDialog as q, useDialogChild as Z, useSnackbar as z, useBreakpoints as ee, FmButtonColorThemeVariant as x, FmButtonVariant as D } from "@feedmepos/ui-library";
5
5
  import "vue-router";
6
- import { L as N } from "./LinkProductSideSheet-A26Otbdm.js";
7
- import { _ as te, a as B } from "./Product.vue_vue_type_script_setup_true_lang-D_oKtXbh.js";
8
- import { u as oe, a as ne } from "./menu-DCnWrgH7.js";
9
- import { u as ae } from "./item-BooojPpg.js";
10
- import { u as re, a as se, w as le } from "./catalog-Do7RfIKm.js";
11
- import { m as ie } from "./toExcel-Dha8Vf3u.js";
12
- import { l as ue } from "./lodash-247YxYiQ.js";
6
+ import { L as N } from "./LinkProductSideSheet-DfZrxiHw.js";
7
+ import { _ as te, a as B } from "./Product.vue_vue_type_script_setup_true_lang-D2840VfX.js";
8
+ import { u as oe, a as ne } from "./menu-CUXJ9cXY.js";
9
+ import { u as ae } from "./item-Dj35T3VU.js";
10
+ import { u as re, a as se, w as ie } from "./catalog-C8CFP-ny.js";
11
+ import { m as le } from "./toExcel-D9nGg3_g.js";
12
+ import { l as ue } from "./lodash-MHSu1pkA.js";
13
13
  import { _ as ce, a as R } from "./BottomSheetMenuItem.vue_vue_type_script_setup_true_lang-DPis3HVx.js";
14
14
  const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "flex justify-end gap-8" }, fe = /* @__PURE__ */ F({
15
15
  __name: "ConfirmActionDialog",
@@ -19,7 +19,7 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
19
19
  message: { default: "To confirm your action, type <b>[[value]]</b> in the text field." }
20
20
  },
21
21
  setup(C) {
22
- const t = C, y = f(() => t.message.replace("[[value]]", t.value)), n = h(""), k = q(), { emitAction: b } = Z();
22
+ const t = C, y = f(() => t.message.replace("[[value]]", t.value)), n = M(""), k = q(), { emitAction: b } = Z();
23
23
  return (c, a) => {
24
24
  const s = S("FmTextField"), m = S("FmButton"), _ = S("FmForm");
25
25
  return u(), g(_, {
@@ -27,26 +27,26 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
27
27
  "blame-form-child-on-validation-failed": ""
28
28
  }, {
29
29
  default: p(() => [
30
- i("div", me, [
31
- i("div", null, U(c.description), 1),
32
- i("div", { innerHTML: y.value }, null, 8, de),
33
- i("div", null, [
30
+ l("div", me, [
31
+ l("div", null, U(c.description), 1),
32
+ l("div", { innerHTML: y.value }, null, 8, de),
33
+ l("div", null, [
34
34
  o(s, {
35
35
  modelValue: n.value,
36
36
  "onUpdate:modelValue": [
37
- a[0] || (a[0] = (l) => n.value = l),
37
+ a[0] || (a[0] = (i) => n.value = i),
38
38
  a[1] || (a[1] = () => {
39
39
  })
40
40
  ],
41
41
  placeholder: c.value,
42
- rules: [(l) => l === c.value || "Value does not match"]
42
+ rules: [(i) => i === c.value || "Value does not match"]
43
43
  }, null, 8, ["modelValue", "placeholder", "rules"])
44
44
  ]),
45
- i("div", pe, [
45
+ l("div", pe, [
46
46
  o(m, {
47
47
  label: "Cancel",
48
48
  variant: "secondary",
49
- onClick: a[2] || (a[2] = (l) => e(k).close())
49
+ onClick: a[2] || (a[2] = (i) => e(k).close())
50
50
  }),
51
51
  o(m, {
52
52
  label: "Confirm",
@@ -62,7 +62,7 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
62
62
  }), _e = /* @__PURE__ */ F({
63
63
  __name: "Migrate",
64
64
  setup(C) {
65
- const t = L(), y = W(), n = z(), { minor: k } = j(n), b = h(!1), c = q();
65
+ const t = L(), y = W(), n = z(), { minor: k } = j(n), b = M(!1), c = q();
66
66
  async function a() {
67
67
  s.value || b.value || c.open({
68
68
  title: "Migrate to new version",
@@ -94,8 +94,8 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
94
94
  return _.length ? `Upgrade POS to V${I.Pos.minVersionToUse(P.F_FEATURE.enum.menuV4)} to use new menu: ${_.map((v) => v.profile.name).join(", ")}` : null;
95
95
  });
96
96
  return f(() => s.value ? s.value : "Migrate your menu to new version to enjoy more features. Content of new menu will remain the same as current."), (m, _) => {
97
- const l = S("FmSnackbar");
98
- return !s.value && e(t).version !== e(H.F_MENU_VERSION).enum.v4 ? (u(), g(l, {
97
+ const i = S("FmSnackbar");
98
+ return !s.value && e(t).version !== e(H.F_MENU_VERSION).enum.v4 ? (u(), g(i, {
99
99
  key: 0,
100
100
  class: "!max-w-full",
101
101
  title: "New version of menu is out now!",
@@ -114,13 +114,13 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
114
114
  ...G.menuV4ToV3(J(n.state.menu)),
115
115
  _id: n.state.menu._id,
116
116
  _rev: n.state.menu._rev
117
- })), l = f(() => ue.flatten(m.value.map((x) => x.items)).length);
117
+ })), i = f(() => ue.flatten(m.value.map((h) => h.items)).length);
118
118
  async function v() {
119
119
  await y.minor(
120
120
  async () => {
121
121
  await n.readMenu();
122
- const x = await ie(_.value), d = `menu_${Q().format("DD-MM-YYYY_HH-mm")}`;
123
- await le(x, `${d}.xlsx`, {
122
+ const h = await le(_.value), d = `menu_${Q().format("DD-MM-YYYY_HH-mm")}`;
123
+ await ie(h, `${d}.xlsx`, {
124
124
  bookType: "xlsx",
125
125
  bookSST: !1,
126
126
  type: "array"
@@ -129,9 +129,9 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
129
129
  { successMessage: "Menu exported", customId: n.state.menu._id }
130
130
  );
131
131
  }
132
- h(!1), h(!1);
132
+ M(!1), M(!1);
133
133
  const O = ee(), Y = f(() => O.breakpoints.value.xs);
134
- return ne().resetOnMount(), (x, d) => {
134
+ return ne().resetOnMount(), (h, d) => {
135
135
  const $ = S("fm-button");
136
136
  return u(), g(K, {
137
137
  heading: e(t)("menu.products.title")
@@ -141,13 +141,13 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
141
141
  o(te)
142
142
  ]),
143
143
  "append-heading": p(() => [
144
- i("div", ve, [
145
- i("div", ge, [
146
- i("div", be, [
147
- i("p", ye, U(l.value), 1)
144
+ l("div", ve, [
145
+ l("div", ge, [
146
+ l("div", be, [
147
+ l("p", ye, U(i.value), 1)
148
148
  ])
149
149
  ]),
150
- i("div", ke, [
150
+ l("div", ke, [
151
151
  Y.value ? (u(), g(B, { key: 1 }, {
152
152
  default: p(({ trigger: r }) => [
153
153
  o(ce, null, {
@@ -167,8 +167,8 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
167
167
  _: 1
168
168
  })) : (u(), T(E, { key: 0 }, [
169
169
  o($, {
170
- "bg-color": e(M).NeutralGray100,
171
- "text-color": e(M).TypoSecondary,
170
+ "bg-color": e(x).NeutralGray100,
171
+ "text-color": e(x).TypoSecondary,
172
172
  variant: e(D).Primary,
173
173
  label: e(t)("menu.products.actions.export"),
174
174
  onClick: v
@@ -176,8 +176,8 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
176
176
  o(B, null, {
177
177
  default: p(({ trigger: r }) => [
178
178
  o($, {
179
- "bg-color": e(M).NeutralGray100,
180
- "text-color": e(M).TypoSecondary,
179
+ "bg-color": e(x).NeutralGray100,
180
+ "text-color": e(x).TypoSecondary,
181
181
  variant: e(D).Primary,
182
182
  label: e(t)("menu.products.actions.import"),
183
183
  onClick: r
@@ -186,7 +186,7 @@ const me = { class: "space-y-24 mb-24" }, de = ["innerHTML"], pe = { class: "fle
186
186
  _: 1
187
187
  })
188
188
  ], 64)),
189
- l.value > 0 ? (u(), T(E, { key: 2 }, [
189
+ i.value > 0 ? (u(), T(E, { key: 2 }, [
190
190
  k.value.create ? (u(), g(V, {
191
191
  key: 0,
192
192
  label: e(t)("menu.products.actions.add"),