@feedmepos/mf-menu 0.32.52-dev → 0.32.53-dev

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 (67) hide show
  1. package/dist/{App-COGal-TD.js → App-PbFbM-b9.js} +5 -5
  2. package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-DzisSpvQ.js → ApplyProduct.vue_vue_type_script_setup_true_lang-DRl0F9ex.js} +3 -3
  3. package/dist/{ApplyProductDialog.vue_vue_type_script_setup_true_lang-eqJDqaPZ.js → ApplyProductDialog.vue_vue_type_script_setup_true_lang-Dxaiz_KJ.js} +2 -2
  4. package/dist/{Catalog-BJ8-NdAC.js → Catalog-BV1mgE-z.js} +6 -6
  5. package/dist/{Category-CFaPOouQ.js → Category-C2ymwzxI.js} +4 -4
  6. package/dist/{Category-BkU2y10v.js → Category-C5RNTUST.js} +4 -4
  7. package/dist/{CookingGuide-BDDCmfeL.js → CookingGuide-Byn0p1cx.js} +4 -4
  8. package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-BcJYQo_p.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-CftleIRB.js} +1 -1
  9. package/dist/{Group-DBrJ4Rin.js → Group-B-Z1yY_a.js} +1 -1
  10. package/dist/{Group-Sk7Qd6G3.js → Group-CAOu7mTu.js} +3 -3
  11. package/dist/{Group.vue_vue_type_script_setup_true_lang-BWpIG76a.js → Group.vue_vue_type_script_setup_true_lang-CMfGMwA5.js} +128 -128
  12. package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-DzeAE7Oj.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-DEzXdEtH.js} +5 -5
  13. package/dist/{ImportProductDialog.vue_vue_type_script_setup_true_lang-DWScWkMg.js → ImportProductDialog.vue_vue_type_script_setup_true_lang-BtZtkQHn.js} +7 -7
  14. package/dist/{Ingredient-CA0qoRc1.js → Ingredient-_-Z-auCy.js} +3 -3
  15. package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-BzLcfi4f.js → InventoryBinding.vue_vue_type_script_setup_true_lang-rBo5MgKk.js} +2 -2
  16. package/dist/{LinkProductSideSheet-TTj7qiWm.js → LinkProductSideSheet-Cpr-OzhV.js} +3 -3
  17. package/dist/{MenuSetting-DwfE7v0B.js → MenuSetting-BHAYHNoL.js} +6 -6
  18. package/dist/{OrderPacing-cT1Vs3OD.js → OrderPacing-0xP2FLqE.js} +5 -5
  19. package/dist/{PrintRoute-D8pc6M31.js → PrintRoute-BXqPWXr-.js} +4 -4
  20. package/dist/{Product-CW1oQzS-.js → Product-CCwCq0oF.js} +1 -1
  21. package/dist/{Product.vue_vue_type_script_setup_true_lang-lqXctN9S.js → Product.vue_vue_type_script_setup_true_lang-BHjCwlbX.js} +12 -12
  22. package/dist/{ProductInternalTools-DAIu8IhO.js → ProductInternalTools-BsUazT7k.js} +5 -5
  23. package/dist/{Products-nVL6Qsuw.js → Products-Y2h_hLvm.js} +45 -45
  24. package/dist/{Publish-DHEzIG_J.js → Publish-10DtltRY.js} +3 -3
  25. package/dist/{Recipe-BLcLaekI.js → Recipe-BKCEiBY4.js} +4 -4
  26. package/dist/{RestaurantAttributesSelector.vue_vue_type_script_setup_true_lang-BCHurASV.js → RestaurantAttributesSelector.vue_vue_type_script_setup_true_lang-Y2Ei1h4p.js} +1 -1
  27. package/dist/{RuleView.vue_vue_type_script_setup_true_lang-Dwi3pOl9.js → RuleView.vue_vue_type_script_setup_true_lang-Bc-WFsaf.js} +2 -2
  28. package/dist/{Scheduler-C4e5hO7Z.js → Scheduler-D1WnpvQd.js} +3 -3
  29. package/dist/{ServingSequence-C12Ny_nR.js → ServingSequence-DZ4MchF3.js} +3 -3
  30. package/dist/{Setting-BscTehhJ.js → Setting-BgO-a6VG.js} +5 -5
  31. package/dist/{Subcategory-C5FGoPot.js → Subcategory-mLhMiNx9.js} +5 -5
  32. package/dist/{Takeaway-CDSKNUhc.js → Takeaway-B9fVwXW3.js} +1 -1
  33. package/dist/{Takeaway-Dr6WQVE1.js → Takeaway-BN8itU_F.js} +4 -4
  34. package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-C6eREsQp.js → Takeaway.vue_vue_type_script_setup_true_lang-CNNtpfY0.js} +5 -5
  35. package/dist/{Thumbnail.vue_vue_type_script_setup_true_lang-CkETUziX.js → Thumbnail.vue_vue_type_script_setup_true_lang-IEPm4c9G.js} +4 -4
  36. package/dist/{TranslationFieldSection.vue_vue_type_script_setup_true_lang-CcD-TGhd.js → TranslationFieldSection.vue_vue_type_script_setup_true_lang-BWq9E3Pr.js} +1 -1
  37. package/dist/{TranslationSideSheet.vue_vue_type_script_setup_true_lang-DccUYmCx.js → TranslationSideSheet.vue_vue_type_script_setup_true_lang-D2Mdr76E.js} +2 -2
  38. package/dist/{TreeEditorOpenner.vue_vue_type_script_setup_true_lang-D1ov0odP.js → TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CgEcWKsF.js} +14 -14
  39. package/dist/{Unit-U3pz6pPm.js → Unit-CJTyfSaA.js} +2 -2
  40. package/dist/{Variant-D-nC4Dy6.js → Variant-CSR0PyJt.js} +3 -3
  41. package/dist/{_id_-DHI7NeZ5.js → _id_-B-uZfPBS.js} +9 -9
  42. package/dist/{app-dIGG83GF.js → app-nRTse_K5.js} +32 -32
  43. package/dist/{app-Brq8nN4D.js → app-vpEeMZuq.js} +1 -1
  44. package/dist/app.js +1 -1
  45. package/dist/assets/{linked-status-C-sgTOx9.js → linked-status-kcewbkLn.js} +2 -2
  46. package/dist/assets/{menu-export-Nt98HUsd.js → menu-export-LL-Hfzyk.js} +2 -2
  47. package/dist/assets/{override-menu-Ako9Ghu_.js → override-menu-kO9kvtlN.js} +2 -2
  48. package/dist/assets/{validate-menu-CVJ4sdGa.js → validate-menu-Bv0NTZv1.js} +2 -2
  49. package/dist/{catalog-BDfp-HKs.js → catalog-CVMKoUf8.js} +1 -1
  50. package/dist/{catalogSetting-BjZWlJux.js → catalogSetting-CJofGu7O.js} +1 -1
  51. package/dist/{currency-BMM0v_C-.js → currency-DeBYT9j_.js} +1 -1
  52. package/dist/{dayjs.min-qRo56ggi.js → dayjs.min-Ws3b1WxF.js} +2 -2
  53. package/dist/{index-Dnr_KMtS.js → index-OUJmHOAU.js} +5 -5
  54. package/dist/{index-DwsAtSPy.js → index-v56nMLPD.js} +4 -4
  55. package/dist/{index.vue_vue_type_script_setup_true_lang-BLHrxcy_.js → index.vue_vue_type_script_setup_true_lang-DPaHA1bp.js} +279 -279
  56. package/dist/{item-hYgXuH-R.js → item-D5rytEqk.js} +18 -18
  57. package/dist/{jszip.min-BqsNpcIL.js → jszip.min-C6uUCcnL.js} +3 -3
  58. package/dist/{memberPricing-CXI5GqbJ.js → memberPricing-CBzr9qLU.js} +1 -1
  59. package/dist/{menu-Okh_Q4gK.js → menu-BhxWRy0N.js} +1 -1
  60. package/dist/{menuV2-DbTc7yw0.js → menuV2-Ds1f3a8P.js} +49 -49
  61. package/dist/{order_pacing-CBkQIrp3.js → order_pacing-CYuEj5Sb.js} +5 -5
  62. package/dist/{priceTier-BxWXhfDh.js → priceTier-KEgRA3RV.js} +1 -1
  63. package/dist/{rules-CsoPQCO5.js → rules-C1xA7rwc.js} +3 -3
  64. package/dist/{scheduler-BfvHQAuo.js → scheduler-C5YdAro0.js} +4 -4
  65. package/dist/{toExcel-DZMykkCy.js → toExcel-Dv-vcMzg.js} +2 -2
  66. package/dist/{unit-ro6UkV3c.js → unit-WEAw3qgL.js} +2 -2
  67. package/package.json +1 -1
@@ -1,49 +1,49 @@
1
- import { defineComponent as oe, computed as v, resolveComponent as F, createBlock as R, openBlock as m, withCtx as x, createElementBlock as y, Fragment as E, renderList as ne, createElementVNode as d, normalizeClass as q, toDisplayString as A, createVNode as c, createCommentVNode as O, unref as u, ref as T, watch as $e, h as Y, mergeProps as De, createSlots as Pe, withModifiers as Te, isRef as J, nextTick as de } from "vue";
2
- import { u as ye, P as Ee, B as Le, y as ee, R as w, A as Ue, a5 as Ke, H as te, z as ze, K as ve, J as Be } from "./index.vue_vue_type_script_setup_true_lang-BLHrxcy_.js";
1
+ import { defineComponent as oe, computed as f, resolveComponent as V, createBlock as R, openBlock as m, withCtx as x, createElementBlock as y, Fragment as E, renderList as ne, createElementVNode as p, normalizeClass as q, toDisplayString as A, createVNode as i, createCommentVNode as O, unref as u, ref as T, watch as $e, h as Y, mergeProps as De, createSlots as Pe, withModifiers as Te, isRef as J, nextTick as pe } from "vue";
2
+ import { u as ye, P as Ee, B as Le, y as ee, R as w, A as Ue, a5 as Ke, H as te, z as ze, K as fe, J as Be } from "./index.vue_vue_type_script_setup_true_lang-DPaHA1bp.js";
3
3
  import { d as je } from "./vuedraggable-CK8z7qA8.js";
4
- import { b as fe, H as Ye } from "./app-5fxKLAzS.js";
4
+ import { b as ve, H as Ye } from "./app-5fxKLAzS.js";
5
5
  import { useI18n as _e, useCoreStore as He, useCustomAttributes as Je } from "@feedmepos/mf-common";
6
6
  import { useBreakpoints as be, useSnackbar as qe, useDialog as Qe, components as We, FmButtonVariant as Xe } from "@feedmepos/ui-library";
7
- import { _ as Ze, a as et } from "./CustomAttributeChip.vue_vue_type_script_setup_true_lang-BcJYQo_p.js";
8
- import { _ as tt } from "./app-dIGG83GF.js";
7
+ import { _ as Ze, a as et } from "./CustomAttributeChip.vue_vue_type_script_setup_true_lang-CftleIRB.js";
8
+ import { _ as tt } from "./app-nRTse_K5.js";
9
9
  import { _ as nt, a as ot } from "./BottomSheetMenuItem.vue_vue_type_script_setup_true_lang-DhrXKy3b.js";
10
10
  import { c as lt } from "./object-DVUNCr7w.js";
11
- import { _ as rt } from "./ApplyProductDialog.vue_vue_type_script_setup_true_lang-eqJDqaPZ.js";
12
- import { M as ge, K as at, L as ut, J as st, m as it, r as ct, s as mt } from "./item-hYgXuH-R.js";
13
- import { _ as pt } from "./TranslationViewChip.vue_vue_type_script_setup_true_lang-DiK3fi9J.js";
14
- import { u as dt } from "./search-BAPEUu1R.js";
15
- import { C as vt } from "./catalog-BDfp-HKs.js";
16
- import { c as ft } from "./menuV2-DbTc7yw0.js";
11
+ import { _ as rt } from "./ApplyProductDialog.vue_vue_type_script_setup_true_lang-Dxaiz_KJ.js";
12
+ import { M as ge, K as at, L as ut, J as st, m as it, r as ct, s as mt } from "./item-D5rytEqk.js";
13
+ import { _ as dt } from "./TranslationViewChip.vue_vue_type_script_setup_true_lang-DiK3fi9J.js";
14
+ import { u as pt } from "./search-BAPEUu1R.js";
15
+ import { C as ft } from "./catalog-CVMKoUf8.js";
16
+ import { c as vt } from "./menuV2-Ds1f3a8P.js";
17
17
  const gt = /* @__PURE__ */ oe({
18
18
  __name: "ResponsiveContextMenu",
19
19
  props: {
20
20
  items: {}
21
21
  },
22
22
  setup(Q) {
23
- const L = be(), a = v(() => L.breakpoints.value.xs);
23
+ const L = be(), a = f(() => L.breakpoints.value.xs);
24
24
  return (I, N) => {
25
- const b = F("FmButton"), k = F("FmMenuItem"), f = F("FmMenu");
25
+ const b = V("FmButton"), k = V("FmMenuItem"), v = V("FmMenu");
26
26
  return a.value ? (m(), R(nt, { key: 0 }, {
27
27
  default: x(() => [
28
- (m(!0), y(E, null, ne(I.items, ({ icon: S, label: G, disabled: h, itemClass: U, onClick: V }) => (m(), R(ot, {
28
+ (m(!0), y(E, null, ne(I.items, ({ icon: F, label: G, disabled: h, itemClass: U, onClick: S }) => (m(), R(ot, {
29
29
  key: G,
30
- icon: S,
30
+ icon: F,
31
31
  label: G,
32
32
  disabled: h,
33
33
  itemClass: U,
34
34
  onClick: () => {
35
- !h && (V == null || V());
35
+ !h && (S == null || S());
36
36
  }
37
37
  }, null, 8, ["icon", "label", "disabled", "itemClass", "onClick"]))), 128))
38
38
  ]),
39
39
  _: 1
40
- })) : (m(), R(f, {
40
+ })) : (m(), R(v, {
41
41
  key: 1,
42
42
  "stop-click-propagation": "",
43
43
  shift: !0
44
44
  }, {
45
45
  "menu-button": x(() => [
46
- c(b, {
46
+ i(b, {
47
47
  type: "button",
48
48
  variant: "tertiary",
49
49
  icon: "more_vert",
@@ -52,16 +52,16 @@ const gt = /* @__PURE__ */ oe({
52
52
  })
53
53
  ]),
54
54
  default: x(() => [
55
- (m(!0), y(E, null, ne(I.items, ({ icon: S, label: G, disabled: h, itemClass: U, onClick: V }) => (m(), R(k, {
55
+ (m(!0), y(E, null, ne(I.items, ({ icon: F, label: G, disabled: h, itemClass: U, onClick: S }) => (m(), R(k, {
56
56
  key: G,
57
57
  disabled: h,
58
58
  onClick: () => {
59
- !h && (V == null || V());
59
+ !h && (S == null || S());
60
60
  },
61
61
  label: G
62
62
  }, {
63
63
  label: x(() => [
64
- d("span", {
64
+ p("span", {
65
65
  class: q(h ? "text-fm-color-typo-disabled" : U)
66
66
  }, A(G), 3)
67
67
  ]),
@@ -81,19 +81,19 @@ const gt = /* @__PURE__ */ oe({
81
81
  group: {}
82
82
  },
83
83
  setup(Q) {
84
- const L = Q, { t: a } = _e(), I = ye(), N = v(() => L.group.itemsLinked.map((b) => {
85
- const k = I.state.menu.modules.item.find((f) => f._id === b);
84
+ const L = Q, { t: a } = _e(), I = ye(), N = f(() => L.group.itemsLinked.map((b) => {
85
+ const k = I.state.menu.modules.item.find((v) => v._id === b);
86
86
  return (k == null ? void 0 : k.name) || b;
87
87
  }).filter(Boolean));
88
88
  return (b, k) => (m(), y("div", null, [
89
- d("div", null, A(u(a)("menu.group.dialogs.delete.message", { name: b.group.name })), 1),
89
+ p("div", null, A(u(a)("menu.group.dialogs.delete.message", { name: b.group.name })), 1),
90
90
  N.value.length > 0 ? (m(), y("div", yt, [
91
- d("div", _t, A(u(a)("menu.group.dialogs.delete.unlink_warning", { count: N.value.length })), 1),
92
- d("ul", bt, [
93
- (m(!0), y(E, null, ne(N.value, (f) => (m(), y("li", {
94
- key: f,
91
+ p("div", _t, A(u(a)("menu.group.dialogs.delete.unlink_warning", { count: N.value.length })), 1),
92
+ p("ul", bt, [
93
+ (m(!0), y(E, null, ne(N.value, (v) => (m(), y("li", {
94
+ key: v,
95
95
  class: "text-sm"
96
- }, A(f), 1))), 128))
96
+ }, A(v), 1))), 128))
97
97
  ])
98
98
  ])) : O("", !0)
99
99
  ]));
@@ -114,12 +114,12 @@ const gt = /* @__PURE__ */ oe({
114
114
  class: "px-16 py-8"
115
115
  }, Gt = {
116
116
  class: "py-8 px-16"
117
- }, Vt = {
117
+ }, St = {
118
118
  key: 0,
119
119
  class: "px-16 py-8"
120
- }, Ft = {
120
+ }, Vt = {
121
121
  class: "flex items-center flex-1"
122
- }, St = {
122
+ }, Ft = {
123
123
  class: "flex-1 space-y-4"
124
124
  }, It = {
125
125
  class: "fm-typo-en-body-lg-600"
@@ -134,17 +134,17 @@ const gt = /* @__PURE__ */ oe({
134
134
  setup(Q, {
135
135
  emit: L
136
136
  }) {
137
- const a = ye(), I = He(), N = qe(), b = Ee(Le(N)), k = Qe(), f = v(() => a.rules.group), S = v(() => new ge(a, b.updateMenu, k)), G = v(() => S.value.mapGroups(a.groups, !1)), {
137
+ const a = ye(), I = He(), N = qe(), b = Ee(Le(N)), k = Qe(), v = f(() => a.rules.group), F = f(() => new ge(a, b.updateMenu, k)), G = f(() => F.value.mapGroups(a.groups, !1)), {
138
138
  searchKey: h,
139
139
  filter: U
140
- } = dt(), V = T(!1), _ = T(null), {
140
+ } = pt(), S = T(!1), _ = T(null), {
141
141
  attributes: le,
142
142
  filterRule: $,
143
143
  mongoQuery: re
144
144
  } = Je({
145
145
  valueSource: G,
146
146
  entity: "group"
147
- }), K = v(() => {
147
+ }), K = f(() => {
148
148
  const t = (r) => U([r.name, ...Object.values(r.items).flatMap((o) => `${o.code} ${o.name ?? o.fallbackName} ${ze.Dinero.fromFdoDinero(o.price).toFormat()}`), r.type]), e = (r) => !r.customAttributes && !re.value ? !0 : Ye(r.customAttributes ?? {}, re.value);
149
149
  return G.value.filter((r) => t(r) && e(r)).filter((r) => !_.value || r.type === _.value);
150
150
  }), ke = L;
@@ -153,58 +153,58 @@ const gt = /* @__PURE__ */ oe({
153
153
  }, {
154
154
  immediate: !0
155
155
  });
156
- const i = v(() => !!a.state.currentCatalogId || !!a.state.currentSchedulerId);
156
+ const c = f(() => !!a.state.currentCatalogId || !!a.state.currentSchedulerId);
157
157
  function ae(t) {
158
158
  var P, n;
159
- const e = !a.state.currentCatalogId, r = !a.state.currentSchedulerId, o = ((P = a.currentCatalog) == null ? void 0 : P.priceTierRules) ?? ((n = a.currentCatalog) == null ? void 0 : n.usePriceTiers), s = a.rules.item.bindToVariant, C = a.rules.group.type, p = a.version === ee.enum.v3, M = a.rules.item.orderFromActiveOnly;
159
+ const e = !a.state.currentCatalogId, r = !a.state.currentSchedulerId, o = ((P = a.currentCatalog) == null ? void 0 : P.priceTierRules) ?? ((n = a.currentCatalog) == null ? void 0 : n.usePriceTiers), s = a.rules.item.bindToVariant, C = a.rules.group.type, d = a.version === ee.enum.v3, M = a.rules.item.orderFromActiveOnly;
160
160
  return {
161
- link: (g) => !i.value && (!g || s),
162
- name: (g) => !i.value && !g,
163
- isDefault: (g) => !i.value,
164
- type: C && !t._id && !i.value,
165
- price: !p || t.type !== w.enum.DYNAMIC,
166
- priceEdit: !(o && o.length > 0 && !p && r),
167
- priceTier: !p && r && e,
168
- inventory: r ? p ? !i.value && t.type === w.enum.NORMAL : !i.value : !1,
169
- orderFrom: (g) => r ? p ? t.type === w.enum.DYNAMIC ? i.value : !!i.value == !g : i.value : !1,
161
+ link: (g) => !c.value && (!g || s),
162
+ name: (g) => !c.value && !g,
163
+ isDefault: (g) => !c.value,
164
+ type: C && !t._id && !c.value,
165
+ price: !d || t.type !== w.enum.DYNAMIC,
166
+ priceEdit: !(o && o.length > 0 && !d && r),
167
+ priceTier: !d && r && e,
168
+ inventory: r ? d ? !c.value && t.type === w.enum.NORMAL : !c.value : !1,
169
+ orderFrom: (g) => r ? d ? t.type === w.enum.DYNAMIC ? !a.state.currentSchedulerId : !a.state.currentSchedulerId == !g : !a.state.currentSchedulerId : !1,
170
170
  orderFromActiveOnly: M,
171
- showOrderFrom: r ? p ? i.value ? !0 : t.type === w.enum.PRODUCT : !0 : !1,
171
+ showOrderFrom: r ? d ? c.value ? !0 : t.type === w.enum.PRODUCT : !0 : !1,
172
172
  bindToVariant: s,
173
- isOverride: i.value,
173
+ isOverride: c.value,
174
174
  isItemGroup: !1,
175
- isV4: !p
175
+ isV4: !d
176
176
  };
177
177
  }
178
- const he = v(() => {
178
+ const he = f(() => {
179
179
  const t = !a.state.currentSchedulerId, e = a.rules.group.type, r = a.version === ee.enum.v3, o = a.rules.item.orderFromActiveOnly, s = a.rules.item.bindToVariant;
180
- return function(p) {
180
+ return function(d) {
181
181
  return {
182
- link: (M) => !i.value && (!M || s),
183
- name: (M) => !i.value && !M,
184
- isDefault: (M) => !i.value,
185
- type: e && !p._id && !i.value,
186
- price: p.type !== w.enum.DYNAMIC,
182
+ link: (M) => !c.value && (!M || s),
183
+ name: (M) => !c.value && !M,
184
+ isDefault: (M) => !c.value,
185
+ type: e && !d._id && !c.value,
186
+ price: d.type !== w.enum.DYNAMIC,
187
187
  priceEdit: !0,
188
188
  priceTier: a.isV4,
189
- inventory: t ? r ? !i.value && p.type === w.enum.NORMAL : !i.value : !1,
190
- orderFrom: (M) => t ? r ? p.type === w.enum.DYNAMIC ? i.value : !!i.value == !M : i.value : !1,
189
+ inventory: t ? r ? !c.value && d.type === w.enum.NORMAL : !c.value : !1,
190
+ orderFrom: (M) => t ? r ? d.type === w.enum.DYNAMIC ? c.value : !!c.value == !M : c.value : !1,
191
191
  orderFromActiveOnly: o,
192
- showOrderFrom: t ? r ? i.value ? !0 : p.type === w.enum.PRODUCT : i.value : !1,
192
+ showOrderFrom: t ? r ? c.value ? !0 : d.type === w.enum.PRODUCT : c.value : !1,
193
193
  bindToVariant: s,
194
- isOverride: i.value,
194
+ isOverride: c.value,
195
195
  isItemGroup: !1,
196
196
  isV4: !r
197
197
  };
198
198
  };
199
- }), we = v(() => ({
199
+ }), we = f(() => ({
200
200
  ...Ue.generator.initMenuV4Group(),
201
201
  type: a.version === ee.enum.v4 ? w.enum.PRODUCT : w.enum.NORMAL,
202
202
  items: {},
203
203
  position: a.groups.length - 1,
204
204
  itemsLinked: []
205
- })), W = v(() => he.value(we.value).type);
205
+ })), W = f(() => he.value(we.value).type);
206
206
  function ue(t) {
207
- S.value.sortGroups(t);
207
+ F.value.sortGroups(t);
208
208
  }
209
209
  function Ce(t) {
210
210
  k.open({
@@ -220,14 +220,14 @@ const gt = /* @__PURE__ */ oe({
220
220
  text: l("menu.common.actions.cancel"),
221
221
  close: !0
222
222
  }
223
- }).onPrimary(() => S.value.duplicateGroup(t));
223
+ }).onPrimary(() => F.value.duplicateGroup(t));
224
224
  }
225
- const X = v(() => a.currentCatalog), z = v(() => a.currentScheduler), B = v(() => new vt(X.value, a, b.updateMenu, k)), Z = v(() => new at(z.value, a, b.updateMenu, k)), xe = (t) => {
225
+ const X = f(() => a.currentCatalog), z = f(() => a.currentScheduler), B = f(() => new ft(X.value, a, b.updateMenu, k)), Z = f(() => new at(z.value, a, b.updateMenu, k)), xe = (t) => {
226
226
  let e = t;
227
227
  function r(o) {
228
- const C = a.state.menu.modules.group.find((n) => n._id === o._id), p = (o.items ?? []).reduce((n, g) => (n[g._id] = [...n[g._id] || [], g.combinationKey || ""], n), {}), P = (C.items ?? []).filter((n) => {
228
+ const C = a.state.menu.modules.group.find((n) => n._id === o._id), d = (o.items ?? []).reduce((n, g) => (n[g._id] = [...n[g._id] || [], g.combinationKey || ""], n), {}), P = (C.items ?? []).filter((n) => {
229
229
  var g;
230
- return !((g = p[n._id]) != null && g.includes(n.combinationKey || ""));
230
+ return !((g = d[n._id]) != null && g.includes(n.combinationKey || ""));
231
231
  }).map((n) => ({
232
232
  _id: n._id,
233
233
  combinationKey: n.combinationKey,
@@ -239,7 +239,7 @@ const gt = /* @__PURE__ */ oe({
239
239
  items: [...o.items ?? [], ...P]
240
240
  };
241
241
  }
242
- if (i.value) {
242
+ if (c.value) {
243
243
  let o;
244
244
  X.value ? z.value ? o = B.value.getCatalogSchedulerGroup(t._id, z.value._id) : o = B.value.getCatalogGroup(t._id) : o = Z.value.getSchedulerGroup(t._id);
245
245
  const s = r(o);
@@ -268,7 +268,7 @@ const gt = /* @__PURE__ */ oe({
268
268
  close: !0
269
269
  }
270
270
  }).onPrimary(async () => {
271
- await S.value.deleteGroup(t);
271
+ await F.value.deleteGroup(t);
272
272
  });
273
273
  }
274
274
  function se(t, e) {
@@ -276,12 +276,12 @@ const gt = /* @__PURE__ */ oe({
276
276
  key: t._id,
277
277
  initialValue: t.itemsLinked,
278
278
  group: it(t),
279
- editable: f.value.applyProduct,
279
+ editable: v.value.applyProduct,
280
280
  "onApply:product": async (r) => {
281
281
  var o;
282
282
  for (const s of r)
283
- if (ft(a.state.menu, t._id, s._id)) {
284
- const C = (o = a.state.menu.modules.item.find((p) => p._id === s._id)) == null ? void 0 : o.name;
283
+ if (vt(a.state.menu, t._id, s._id)) {
284
+ const C = (o = a.state.menu.modules.item.find((d) => d._id === s._id)) == null ? void 0 : o.name;
285
285
  N.open({
286
286
  type: "error",
287
287
  message: l("menu.product.form.group.circularError", {
@@ -291,7 +291,7 @@ const gt = /* @__PURE__ */ oe({
291
291
  });
292
292
  return;
293
293
  }
294
- await S.value.applyItems(t, r.map((s) => s._id));
294
+ await F.value.applyItems(t, r.map((s) => s._id));
295
295
  }
296
296
  }, {
297
297
  default: e
@@ -307,24 +307,24 @@ const gt = /* @__PURE__ */ oe({
307
307
  onClick: () => me(e)
308
308
  }, {
309
309
  label: l("menu.group.actions.apply_product"),
310
- disable: !f.value.applyProduct,
310
+ disable: !v.value.applyProduct,
311
311
  onClick: o
312
312
  }, {
313
313
  label: l("menu.group.actions.duplicate_action"),
314
- disabled: !f.value.create,
314
+ disabled: !v.value.create,
315
315
  onClick: () => Ce(e)
316
316
  }, {
317
317
  label: l("menu.common.actions.delete"),
318
318
  itemClass: "text-fm-color-typo-error",
319
- disabled: !f.value.delete,
319
+ disabled: !v.value.delete,
320
320
  onClick: () => Me(e)
321
321
  }];
322
- return c(gt, {
322
+ return i(gt, {
323
323
  class: t.className,
324
324
  items: s
325
325
  }, null);
326
326
  });
327
- }, Ae = v(() => [{
327
+ }, Ae = f(() => [{
328
328
  accessorKey: "name",
329
329
  header: () => l("menu.group.list.columns.name"),
330
330
  enableSorting: !1,
@@ -334,7 +334,7 @@ const gt = /* @__PURE__ */ oe({
334
334
  class: "flex items-center gap-8"
335
335
  }, [Y("span", {
336
336
  class: "break-all"
337
- }, r), e.name_locale ? Y(pt, {
337
+ }, r), e.name_locale ? Y(dt, {
338
338
  nameLocale: e.name_locale ?? {}
339
339
  }) : null]);
340
340
  }
@@ -393,7 +393,7 @@ const gt = /* @__PURE__ */ oe({
393
393
  });
394
394
  return se(t.row.original, ({
395
395
  trigger: o
396
- }) => c("div", {
396
+ }) => i("div", {
397
397
  class: "w-fit cursor-pointer border-b border-dashed border-fm-color-neutral-gray-300 hover:border-fm-color-neutral-gray-400",
398
398
  onClick: (s) => {
399
399
  s.stopPropagation(), o(s);
@@ -413,53 +413,53 @@ const gt = /* @__PURE__ */ oe({
413
413
  className: "flex justify-end w-full"
414
414
  });
415
415
  }
416
- }]), Ge = v(() => {
416
+ }]), Ge = f(() => {
417
417
  var t;
418
418
  return {
419
- itemsLinked: f.value.showAppliedProduct,
420
- type: f.value.type,
419
+ itemsLinked: v.value.showAppliedProduct,
420
+ type: v.value.type,
421
421
  tagging: ((t = I.groupAttributeSettings) == null ? void 0 : t.value.length) > 0
422
422
  };
423
- }), Ve = async (t) => {
423
+ }), Se = async (t) => {
424
424
  const e = ct(t), r = e.group, o = mt(r, ae(t));
425
- if (i.value)
425
+ if (c.value)
426
426
  X.value ? (z.value ? B.value.overrideCatalogSchedulerGroups([o], z.value._id) : B.value.overrideCatalogGroups([o]), await B.value.update()) : (Z.value.overrideSchedulerGroups([o]), await Z.value.update());
427
427
  else {
428
428
  const s = {
429
- module: ve.enum.group,
429
+ module: fe.enum.group,
430
430
  operation: Be.F_OPERATION_TYPE.update,
431
431
  data: o,
432
432
  link: [{
433
- module: ve.enum.item,
433
+ module: fe.enum.item,
434
434
  id: "",
435
435
  data: e.linkItems
436
436
  }]
437
437
  };
438
438
  await b.updateMenu(s, o.name);
439
439
  }
440
- }, D = T(null), Fe = v(() => xe(D.value)), ce = T(null), me = async (t) => {
440
+ }, D = T(null), Ve = f(() => xe(D.value)), ce = T(null), me = async (t) => {
441
441
  var e;
442
- D.value = lt(t), await de(), (e = ce.value) == null || e.trigger(!0);
442
+ D.value = lt(t), await pe(), (e = ce.value) == null || e.trigger(!0);
443
443
  };
444
- function Se(t) {
444
+ function Fe(t) {
445
445
  me(t.original);
446
446
  }
447
- const Ie = be(), Ne = v(() => Ie.breakpoints.value.xs), {
447
+ const Ie = be(), Ne = f(() => Ie.breakpoints.value.xs), {
448
448
  t: l
449
- } = _e(), Oe = v(() => {
449
+ } = _e(), Oe = f(() => {
450
450
  var t;
451
451
  return ((t = I.groupAttributeSettings) == null ? void 0 : t.value.length) > 0;
452
452
  }), j = T(!1), H = T(null);
453
453
  async function Re() {
454
- j.value = !j.value, j.value && (await de(), H.value && H.value.toggleProperty(!0));
454
+ j.value = !j.value, j.value && (await pe(), H.value && H.value.toggleProperty(!0));
455
455
  }
456
- const pe = () => f.value.multiScheduler ? c(et, null, {
457
- append: () => Oe.value ? c("div", {
456
+ const de = () => v.value.multiScheduler ? i(et, null, {
457
+ append: () => Oe.value ? i("div", {
458
458
  class: "pl-8 flex items-center justify-center border-l border-fm-color-neutral-gray-200",
459
459
  onClick: (t) => {
460
460
  t.stopPropagation(), Re();
461
461
  }
462
- }, [c(We.FmIcon, {
462
+ }, [i(We.FmIcon, {
463
463
  name: "filter_alt",
464
464
  outline: !0,
465
465
  color: "neutral-gray-400",
@@ -467,28 +467,28 @@ const gt = /* @__PURE__ */ oe({
467
467
  }, null)]) : null
468
468
  }) : null;
469
469
  return (t, e) => {
470
- const r = F("fm-button"), o = F("fm-chip"), s = F("fm-menu-item"), C = F("fm-menu"), p = F("fm-search"), M = F("fm-table"), P = F("fm-bottom-sheet");
470
+ const r = V("fm-button"), o = V("fm-chip"), s = V("fm-menu-item"), C = V("fm-menu"), d = V("fm-search"), M = V("fm-table"), P = V("fm-bottom-sheet");
471
471
  return m(), y(E, null, [D.value ? (m(), R(ut, De({
472
472
  ref_key: "groupManagerFormRef",
473
473
  ref: ce,
474
474
  key: D.value._id
475
- }, Fe.value, {
475
+ }, Ve.value, {
476
476
  action: "update",
477
477
  title: u(l)("menu.group.dialogs.update.title"),
478
478
  group: D.value,
479
479
  "onUpdate:group": e[0] || (e[0] = (n) => D.value = n),
480
- "onSubmit:group": e[1] || (e[1] = (n) => Ve(n))
481
- }), null, 16, ["title", "group"])) : O("", !0), G.value.length === 0 ? (m(), y("div", ht, [c(Ke, {
480
+ "onSubmit:group": e[1] || (e[1] = (n) => Se(n))
481
+ }), null, 16, ["title", "group"])) : O("", !0), G.value.length === 0 ? (m(), y("div", ht, [i(Ke, {
482
482
  subtitle: u(l)("menu.group.empty.subtitle"),
483
483
  title: u(l)("menu.group.empty.title")
484
484
  }, Pe({
485
485
  _: 2
486
- }, [f.value.create ? {
486
+ }, [v.value.create ? {
487
487
  name: "action",
488
- fn: x(() => [c(u(st), null, {
488
+ fn: x(() => [i(u(st), null, {
489
489
  default: x(({
490
490
  trigger: n
491
- }) => [c(r, {
491
+ }) => [i(r, {
492
492
  "prepend-icon": "add",
493
493
  label: u(l)("menu.group.actions.add"),
494
494
  onClick: Te(n, ["stop"])
@@ -500,46 +500,46 @@ const gt = /* @__PURE__ */ oe({
500
500
  key: 2
501
501
  }, [Ne.value ? (m(), y(E, {
502
502
  key: 1
503
- }, [d("div", At, [c(p, {
503
+ }, [p("div", At, [i(d, {
504
504
  autofocus: "",
505
505
  modelValue: u(h),
506
506
  "onUpdate:modelValue": e[9] || (e[9] = (n) => J(h) ? h.value = n : null),
507
507
  placeholder: u(l)("menu.group.search.placeholder")
508
- }, null, 8, ["modelValue", "placeholder"])]), e[17] || (e[17] = d("div", {
508
+ }, null, 8, ["modelValue", "placeholder"])]), e[17] || (e[17] = p("div", {
509
509
  class: "bg-fm-color-neutral-gray-100 w-full h-px rounded-md"
510
- }, null, -1)), d("div", Gt, [c(pe), W.value ? (m(), R(P, {
510
+ }, null, -1)), p("div", Gt, [i(de), W.value ? (m(), R(P, {
511
511
  key: 0,
512
- modelValue: V.value,
513
- "onUpdate:modelValue": e[14] || (e[14] = (n) => V.value = n)
512
+ modelValue: S.value,
513
+ "onUpdate:modelValue": e[14] || (e[14] = (n) => S.value = n)
514
514
  }, {
515
- "bottom-sheet-button": x(() => [c(o, {
515
+ "bottom-sheet-button": x(() => [i(o, {
516
516
  label: u(l)("menu.group.type.title", {
517
517
  type: _.value ? u(te.capitalize)(_.value) : u(l)("menu.common.labels.all")
518
518
  }),
519
519
  class: "text-fm-color-typo-secondary",
520
520
  "right-icon": "keyboard_arrow_down"
521
521
  }, null, 8, ["label"])]),
522
- default: x(() => [d("div", null, [d("div", {
522
+ default: x(() => [p("div", null, [p("div", {
523
523
  class: "px-16 py-8",
524
524
  onClick: e[10] || (e[10] = (n) => _.value = null)
525
- }, A(u(l)("menu.group.type.all")), 1), d("div", {
525
+ }, A(u(l)("menu.group.type.all")), 1), p("div", {
526
526
  class: "px-16 py-8",
527
527
  onClick: e[11] || (e[11] = (n) => _.value = "NORMAL")
528
- }, A(u(l)("menu.group.type.normal")), 1), d("div", {
528
+ }, A(u(l)("menu.group.type.normal")), 1), p("div", {
529
529
  class: "px-16 py-8",
530
530
  onClick: e[12] || (e[12] = (n) => _.value = "PRODUCT")
531
- }, A(u(l)("menu.group.type.product")), 1), d("div", {
531
+ }, A(u(l)("menu.group.type.product")), 1), p("div", {
532
532
  class: "px-16 py-8",
533
533
  onClick: e[13] || (e[13] = (n) => _.value = "DYNAMIC")
534
534
  }, A(u(l)("menu.group.type.dynamic")), 1)])]),
535
535
  _: 1
536
- }, 8, ["modelValue"])) : O("", !0)]), j.value ? (m(), y("div", Vt, [c(u(fe), {
536
+ }, 8, ["modelValue"])) : O("", !0)]), j.value ? (m(), y("div", St, [i(u(ve), {
537
537
  ref_key: "attributeFilterRef",
538
538
  ref: H,
539
539
  attributes: u(le),
540
540
  modelValue: u($),
541
541
  "onUpdate:modelValue": e[15] || (e[15] = (n) => J($) ? $.value = n : null)
542
- }, null, 8, ["attributes", "modelValue"])])) : O("", !0), c(u(je), {
542
+ }, null, 8, ["attributes", "modelValue"])])) : O("", !0), i(u(je), {
543
543
  class: q(["flex-1", "overflow-scroll", "divide-y divide-fm-color-neutral-gray-100", "pb-64"]),
544
544
  "model-value": K.value,
545
545
  group: "categories",
@@ -552,53 +552,53 @@ const gt = /* @__PURE__ */ oe({
552
552
  }) => [(m(), y("div", {
553
553
  key: n._id,
554
554
  class: q(["py-12 px-16", "flex space-x-16", "items-center"])
555
- }, [d("div", Ft, [d("div", St, [d("p", It, A(n.name), 1), d("div", null, [W.value ? (m(), y("p", Nt, A(u(te.capitalize)(n.type)) + " type ", 1)) : O("", !0), d("p", Ot, A(u(l)("menu.group.list.products_linked", {
555
+ }, [p("div", Vt, [p("div", Ft, [p("p", It, A(n.name), 1), p("div", null, [W.value ? (m(), y("p", Nt, A(u(te.capitalize)(n.type)) + " type ", 1)) : O("", !0), p("p", Ot, A(u(l)("menu.group.list.products_linked", {
556
556
  count: n.itemsLinked.length
557
- })), 1)])]), c(ie, {
557
+ })), 1)])]), i(ie, {
558
558
  group: n
559
559
  }, null, 8, ["group"])])]))]),
560
560
  _: 1
561
- }, 8, ["model-value"])], 64)) : (m(), y("div", wt, [d("div", Ct, [c(pe), W.value ? (m(), R(C, {
561
+ }, 8, ["model-value"])], 64)) : (m(), y("div", wt, [p("div", Ct, [i(de), W.value ? (m(), R(C, {
562
562
  key: 0
563
563
  }, {
564
- "menu-button": x(() => [c(o, {
564
+ "menu-button": x(() => [i(o, {
565
565
  label: u(l)("menu.group.type.title", {
566
566
  type: _.value ? u(te.capitalize)(_.value) : u(l)("menu.common.labels.all")
567
567
  }),
568
568
  class: "text-fm-color-typo-secondary",
569
569
  "right-icon": "keyboard_arrow_down"
570
570
  }, null, 8, ["label"])]),
571
- default: x(() => [d("div", null, [c(s, {
571
+ default: x(() => [p("div", null, [i(s, {
572
572
  class: "px-16 py-8",
573
573
  label: u(l)("menu.group.type.all"),
574
574
  onClick: e[2] || (e[2] = (n) => _.value = null)
575
- }, null, 8, ["label"]), c(s, {
575
+ }, null, 8, ["label"]), i(s, {
576
576
  class: "px-16 py-8",
577
577
  label: u(l)("menu.group.type.normal"),
578
578
  onClick: e[3] || (e[3] = (n) => _.value = "NORMAL")
579
- }, null, 8, ["label"]), c(s, {
579
+ }, null, 8, ["label"]), i(s, {
580
580
  class: "px-16 py-8",
581
581
  label: u(l)("menu.group.type.product"),
582
582
  onClick: e[4] || (e[4] = (n) => _.value = "PRODUCT")
583
- }, null, 8, ["label"]), c(s, {
583
+ }, null, 8, ["label"]), i(s, {
584
584
  class: "px-16 py-8",
585
585
  label: u(l)("menu.group.type.dynamic"),
586
586
  onClick: e[5] || (e[5] = (n) => _.value = "DYNAMIC")
587
587
  }, null, 8, ["label"])])]),
588
588
  _: 1
589
- })) : O("", !0), d("div", xt, [c(p, {
589
+ })) : O("", !0), p("div", xt, [i(d, {
590
590
  autofocus: "",
591
591
  modelValue: u(h),
592
592
  "onUpdate:modelValue": e[6] || (e[6] = (n) => J(h) ? h.value = n : null),
593
593
  placeholder: u(l)("menu.group.search.placeholder")
594
- }, null, 8, ["modelValue", "placeholder"])])]), j.value ? (m(), y("div", Mt, [c(u(fe), {
594
+ }, null, 8, ["modelValue", "placeholder"])])]), j.value ? (m(), y("div", Mt, [i(u(ve), {
595
595
  ref_key: "attributeFilterRef",
596
596
  ref: H,
597
597
  attributes: u(le),
598
598
  modelValue: u($),
599
599
  "onUpdate:modelValue": e[7] || (e[7] = (n) => J($) ? $.value = n : null)
600
- }, null, 8, ["attributes", "modelValue"])])) : O("", !0), c(tt, null, {
601
- default: x(() => [c(M, {
600
+ }, null, 8, ["attributes", "modelValue"])])) : O("", !0), i(tt, null, {
601
+ default: x(() => [i(M, {
602
602
  "column-defs": Ae.value,
603
603
  "column-visibility": Ge.value,
604
604
  loading: u(b).checkMenuIsLoading(),
@@ -609,7 +609,7 @@ const gt = /* @__PURE__ */ oe({
609
609
  draggable: "",
610
610
  "hide-footer": "",
611
611
  "pin-header-row": "",
612
- onRowClick: Se,
612
+ onRowClick: Fe,
613
613
  onDndChanged: e[8] || (e[8] = (n) => ue(n))
614
614
  }, null, 8, ["column-defs", "column-visibility", "loading", "page-size", "row-data"])]),
615
615
  _: 1
@@ -1,14 +1,14 @@
1
1
  import { defineComponent as N, useModel as K, computed as B, resolveComponent as d, createBlock as I, openBlock as b, ref as L, watch as W, withCtx as f, createElementBlock as F, createElementVNode as U, Fragment as q, renderList as X, createVNode as u, unref as e, createCommentVNode as $, withModifiers as Q, onMounted as te, renderSlot as le, toDisplayString as h, createTextVNode as ae } from "vue";
2
2
  import { useI18n as z, useCustomAttributes as ue, useCoreStore as re, isEmptyRule as oe, EMPTY_RULE as w } from "@feedmepos/mf-common";
3
3
  import { _ as x } from "./FormItem.vue_vue_type_script_setup_true_lang-BmPAVphe.js";
4
- import { u as D } from "./priceTier-BxWXhfDh.js";
4
+ import { u as D } from "./priceTier-KEgRA3RV.js";
5
5
  import { b as G } from "./app-5fxKLAzS.js";
6
6
  import { FmButtonVariant as Z, useDialog as ne, components as ie, FmButtonColorThemeVariant as O } from "@feedmepos/ui-library";
7
- import { m as j, f as Y, e as se, _ as me } from "./RuleView.vue_vue_type_script_setup_true_lang-Dwi3pOl9.js";
8
- import { L as R } from "./catalogSetting-BjZWlJux.js";
9
- import { L as de } from "./LinkProductSideSheet-TTj7qiWm.js";
7
+ import { m as j, f as Y, e as se, _ as me } from "./RuleView.vue_vue_type_script_setup_true_lang-Bc-WFsaf.js";
8
+ import { L as R } from "./catalogSetting-CJofGu7O.js";
9
+ import { L as de } from "./LinkProductSideSheet-Cpr-OzhV.js";
10
10
  import { c as H } from "./check-C9mY6LiX.js";
11
- import { u as pe, G as J, au as ce } from "./index.vue_vue_type_script_setup_true_lang-BLHrxcy_.js";
11
+ import { u as pe, G as J, au as ce } from "./index.vue_vue_type_script_setup_true_lang-DPaHA1bp.js";
12
12
  import { c as ve } from "./string-DpfFixWH.js";
13
13
  const _e = /* @__PURE__ */ N({
14
14
  __name: "LinkPriceTier",