@feedmepos/mf-menu 0.32.13 → 0.32.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{App-D70-FH5L.js → App-BFUyUrdi.js} +16 -9
- package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-BJdja2N0.js → ApplyProduct.vue_vue_type_script_setup_true_lang-BbjRIN7Z.js} +20 -20
- package/dist/{Catalog-WMpN3a0p.js → Catalog-B6VFmr6e.js} +20 -20
- package/dist/{Category-C_VsQIHU.js → Category-B-bTjNFI.js} +24 -24
- package/dist/{Category-BwHhFTZ-.js → Category-C8uGxpST.js} +84 -84
- package/dist/{CookingGuide-D9RNkYDL.js → CookingGuide-BL3uetlO.js} +65 -65
- package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-DtmrxDZm.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-8yIVwc8E.js} +1 -1
- package/dist/{Group-DexONgr2.js → Group-BvO-gQZe.js} +1 -1
- package/dist/{Group-qRZlg5ST.js → Group-DT9UkkOx.js} +3 -3
- package/dist/{Group.vue_vue_type_script_setup_true_lang-DtPY9uUt.js → Group.vue_vue_type_script_setup_true_lang-DZhM1Tpb.js} +56 -56
- package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-B5Qpmj2f.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-D48u_DHq.js} +5 -5
- package/dist/ImportProductDialog.vue_vue_type_script_setup_true_lang-C_X-lTnN.js +72979 -0
- package/dist/{Ingredient-BuOS_Wvm.js → Ingredient-7qWDD9e6.js} +26 -26
- package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-DFvXklj9.js → InventoryBinding.vue_vue_type_script_setup_true_lang-CwjW0wfz.js} +2 -2
- package/dist/{LinkProductSideSheet-DJj8Nn4X.js → LinkProductSideSheet-BXW6eNgZ.js} +3 -3
- package/dist/{MenuSetting-D6B0gCGV.js → MenuSetting-BSF7O2NL.js} +5 -5
- package/dist/{PrintRoute-B7G8f1iC.js → PrintRoute-b1ii5Uz9.js} +20 -20
- package/dist/{Product-DpS5EepJ.js → Product-Ce0GJb3c.js} +1 -1
- package/dist/{Product.vue_vue_type_script_setup_true_lang-CdIukLqA.js → Product.vue_vue_type_script_setup_true_lang-BZVvTAOX.js} +49 -49
- package/dist/{ProductInternalTools-CBCyWHOS.js → ProductInternalTools-igbOLRap.js} +20 -20
- package/dist/Products-GAyUdhnN.js +292 -0
- package/dist/Publish-g60odzhM.js +1300 -0
- package/dist/{Recipe-D14rkATU.js → Recipe-B6aye_iC.js} +9 -9
- package/dist/{RuleView.vue_vue_type_script_setup_true_lang-CdH2ius3.js → RuleView.vue_vue_type_script_setup_true_lang-By8kwuMB.js} +134 -134
- package/dist/{Scheduler-DWZqa-jf.js → Scheduler-CyaG6Y5v.js} +7 -7
- package/dist/{ServingSequence-Mx7ovvJ1.js → ServingSequence-BXeypgrN.js} +27 -27
- package/dist/{Setting-DmHuVXVn.js → Setting-D7GcaNTk.js} +17 -17
- package/dist/{Subcategory-DixZPdnT.js → Subcategory-DNUp9ojI.js} +37 -37
- package/dist/{Takeaway-BVIymFV_.js → Takeaway-Baqvq5nP.js} +9 -9
- package/dist/{Takeaway-DDKeDEbV.js → Takeaway-BjXPeYRv.js} +1 -1
- package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-CTaCQgRv.js → Takeaway.vue_vue_type_script_setup_true_lang-CgXT2UVL.js} +54 -54
- package/dist/{Thumbnail.vue_vue_type_script_setup_true_lang-DveI9xvU.js → Thumbnail.vue_vue_type_script_setup_true_lang-CX8cSbDe.js} +12 -12
- package/dist/{TreeEditorOpenner.vue_vue_type_script_setup_true_lang-2nBbq_Yk.js → TreeEditorOpenner.vue_vue_type_script_setup_true_lang-DcjGVQEO.js} +756 -763
- package/dist/{Unit-utuaNZBw.js → Unit-mI7lLzCf.js} +2 -2
- package/dist/{Variant-CzuJNwen.js → Variant-CVwnODRz.js} +14 -14
- package/dist/{_id_-DMDhPQCr.js → _id_-fpn0nBru.js} +14 -14
- package/dist/{app-BQUkvrAS.js → app-CCKI85Te.js} +26 -26
- package/dist/{app-Bqj3cAPJ.js → app-U5MEN4U1.js} +1 -1
- package/dist/app.js +1 -1
- package/dist/apps/mf-menu/src/Entry.vue.d.ts +1 -0
- package/dist/apps/mf-menu/src/components/feature/Fields/ImageDropField.vue.d.ts +0 -2
- package/dist/apps/mf-menu/src/composable/useClientEvent.d.ts +14 -0
- package/dist/apps/mf-menu/src/helper/import-export-utils.d.ts +22 -22
- package/dist/apps/mf-menu/src/helper/menuExport.d.ts +59 -33
- package/dist/apps/mf-menu/tsconfig.app.tsbuildinfo +1 -1
- package/dist/assets/{linked-status-ILQVL8r9.js → linked-status-6Jt70XBp.js} +2 -2
- package/dist/assets/menu-export-CR0a98CA.js +107 -0
- package/dist/assets/{override-menu-DVkGhbA9.js → override-menu-Chsc0CSI.js} +2 -2
- package/dist/assets/{validate-menu-y_NQUL02.js → validate-menu-pb0aN4gj.js} +2 -2
- package/dist/{catalog-BYzITAmC.js → catalog-BgQmytEA.js} +1 -1
- package/dist/{catalogSetting-DAo5tN3P.js → catalogSetting-BS5IaQKq.js} +1 -1
- package/dist/{category-D4x8r_lY.js → category-DJMVbmzx.js} +1 -1
- package/dist/{currency-CvoBdMM2.js → currency-FHrLDvzy.js} +1 -1
- package/dist/dayjs.min-DJGdQr-B.js +6 -0
- package/dist/{index-LuH6PJzW.js → index-BywPDIFW.js} +4 -4
- package/dist/{index-BLUIaanj.js → index-DYxLHjeC.js} +1 -1
- package/dist/{index-6lju0f3r.js → index-XVWDnyu-.js} +17 -17
- package/dist/{index.vue_vue_type_script_setup_true_lang-DxF14kn9.js → index.vue_vue_type_script_setup_true_lang-kj6HkxwD.js} +2306 -2306
- package/dist/{item-lXMLaKOb.js → item-cmnP2N-a.js} +1089 -1091
- package/dist/{jszip.min-CdZ-wY5m.js → jszip.min-psVCZNVl.js} +545 -545
- package/dist/{menu-PJc2dQHQ.js → menu-CgQPOu3W.js} +1 -1
- package/dist/{menuV2-DinFmdTL.js → menuV2-DHO9OmzU.js} +159 -159
- package/dist/mf-menu.css +1 -1
- package/dist/{priceTier-CzKIo11g.js → priceTier-CLm9vzaK.js} +1 -1
- package/dist/{scheduler-DQjxnoCk.js → scheduler-BMdZdtpj.js} +4 -4
- package/dist/{subcategory-CLkDImEU.js → subcategory-Dj_DOvFt.js} +2 -2
- package/dist/{toExcel-DPh8DaM0.js → toExcel-XwFFiTiA.js} +2 -2
- package/dist/{unit-QYkVoC6_.js → unit-CsuAQsy7.js} +12 -12
- package/package.json +3 -3
- package/dist/ImportProductDialog.vue_vue_type_script_setup_true_lang-BqhNkaw_.js +0 -96043
- package/dist/Products-CcyGNlUl.js +0 -794
- package/dist/Publish-rZLHFaJ5.js +0 -1264
- package/dist/dayjs.min-C6xioui7.js +0 -6
|
@@ -2,23 +2,23 @@ import { defineComponent as le, ref as w, computed as V, resolveComponent as x,
|
|
|
2
2
|
import { useI18n as se } from "@feedmepos/mf-common";
|
|
3
3
|
import { components as ue, useSnackbar as be, useDialog as ye } from "@feedmepos/ui-library";
|
|
4
4
|
import { _ as ke } from "./ResponsiveFabButton.vue_vue_type_script_setup_true_lang-Cn-3MRBO.js";
|
|
5
|
-
import { _ as he } from "./app-
|
|
6
|
-
import { I as ee, J as me,
|
|
5
|
+
import { _ as he } from "./app-CCKI85Te.js";
|
|
6
|
+
import { I as ee, J as me, M as re, A as oe, u as xe, Q as Ce, G as we, a4 as Fe } from "./index.vue_vue_type_script_setup_true_lang-kj6HkxwD.js";
|
|
7
7
|
import { d as Ve } from "./vuedraggable-CK8z7qA8.js";
|
|
8
|
-
import { _ as Z } from "./RuleView.vue_vue_type_script_setup_true_lang-
|
|
8
|
+
import { _ as Z } from "./RuleView.vue_vue_type_script_setup_true_lang-By8kwuMB.js";
|
|
9
9
|
import { u as pe } from "./discardConfirm-BHni0LNu.js";
|
|
10
|
-
import { L as Se } from "./LinkProductSideSheet-
|
|
10
|
+
import { L as Se } from "./LinkProductSideSheet-BXW6eNgZ.js";
|
|
11
11
|
import { _ as Ie } from "./PageLayout.vue_vue_type_script_setup_true_lang-2f0QfweQ.js";
|
|
12
|
-
const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = { class: "space-y-32" }, Ke = { class: "flex bg-fm-color-neutral-gray-100 border-b border-b-fm-color-neutral-gray-200" }, Le = { class: "px-16 py-8 w-[40%]" }, Ne = { class: "px-16 py-8 grow" }, De = { class: "px-16 py-8 w-[40%]" }, Ge = { class: "px-16 py-8 grow" }, Ue = { class: "space-y-16" },
|
|
12
|
+
const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = { class: "space-y-32" }, Ke = { class: "flex bg-fm-color-neutral-gray-100 border-b border-b-fm-color-neutral-gray-200" }, Le = { class: "px-16 py-8 w-[40%]" }, Ne = { class: "px-16 py-8 grow" }, De = { class: "px-16 py-8 w-[40%]" }, Ge = { class: "px-16 py-8 grow" }, Ue = { class: "space-y-16" }, Me = { class: "flex flex-wrap gap-8 overflow-hidden mb-8" }, Te = { class: "flex gap-8 items-center justify-start" }, Be = /* @__PURE__ */ le({
|
|
13
13
|
__name: "CookingGuideStepDialog",
|
|
14
14
|
emits: ["onComplete"],
|
|
15
|
-
setup(N, { expose: g, emit:
|
|
15
|
+
setup(N, { expose: g, emit: Q }) {
|
|
16
16
|
const { t: u } = se();
|
|
17
17
|
g({
|
|
18
18
|
show: d,
|
|
19
19
|
hide: $
|
|
20
20
|
});
|
|
21
|
-
const D =
|
|
21
|
+
const D = Q;
|
|
22
22
|
function L() {
|
|
23
23
|
return {
|
|
24
24
|
id: "",
|
|
@@ -36,7 +36,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
36
36
|
C.value = !1;
|
|
37
37
|
}
|
|
38
38
|
const m = w(L()), F = w([]);
|
|
39
|
-
function
|
|
39
|
+
function X() {
|
|
40
40
|
F.value.push({ key: "", value: "" });
|
|
41
41
|
}
|
|
42
42
|
function R(v) {
|
|
@@ -79,7 +79,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
79
79
|
C.value = !1;
|
|
80
80
|
}
|
|
81
81
|
);
|
|
82
|
-
function
|
|
82
|
+
function M() {
|
|
83
83
|
$(), D("onComplete", {
|
|
84
84
|
...m.value,
|
|
85
85
|
variables: F.value.reduce((v, { key: t, value: f }) => ({ ...v, [t]: f }), {})
|
|
@@ -89,13 +89,13 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
89
89
|
const f = x("FmButton"), _ = x("FmTextField"), P = x("FmChip"), W = x("FmTextarea"), q = x("FmSideSheet");
|
|
90
90
|
return k(), Y(q, {
|
|
91
91
|
modelValue: C.value,
|
|
92
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
92
|
+
"onUpdate:modelValue": t[1] || (t[1] = (T) => C.value = T),
|
|
93
93
|
closeButton: !1,
|
|
94
94
|
header: n.value,
|
|
95
95
|
"max-width": 560,
|
|
96
96
|
"is-container": i(ue).FmForm,
|
|
97
97
|
"is-container-props": {
|
|
98
|
-
onValidationSuccess:
|
|
98
|
+
onValidationSuccess: M,
|
|
99
99
|
blameFormChildOnValidationFailed: !0,
|
|
100
100
|
class: "flex flex-col h-full"
|
|
101
101
|
},
|
|
@@ -113,7 +113,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
113
113
|
])
|
|
114
114
|
]),
|
|
115
115
|
"side-sheet-footer": p(() => [
|
|
116
|
-
l("div",
|
|
116
|
+
l("div", Te, [
|
|
117
117
|
a(f, {
|
|
118
118
|
label: s.value,
|
|
119
119
|
size: "lg",
|
|
@@ -140,7 +140,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
140
140
|
variant: "secondary",
|
|
141
141
|
"text-color": "primary",
|
|
142
142
|
"border-color": "primary",
|
|
143
|
-
onClick:
|
|
143
|
+
onClick: X
|
|
144
144
|
}, null, 8, ["label"])
|
|
145
145
|
]),
|
|
146
146
|
default: p(() => [
|
|
@@ -149,26 +149,26 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
149
149
|
l("div", Le, S(i(u)("menu.cooking_guide.step_dialog.sections.variables.columns.key")), 1),
|
|
150
150
|
l("div", Ne, S(i(u)("menu.cooking_guide.step_dialog.sections.variables.columns.value")), 1)
|
|
151
151
|
]),
|
|
152
|
-
(k(!0), I(z, null, J(F.value, (
|
|
153
|
-
key:
|
|
152
|
+
(k(!0), I(z, null, J(F.value, (T, B) => (k(), I("div", {
|
|
153
|
+
key: B,
|
|
154
154
|
class: "flex items-center border-b border-b-fm-color-neutral-gray-100"
|
|
155
155
|
}, [
|
|
156
156
|
l("div", De, [
|
|
157
157
|
a(_, {
|
|
158
|
-
modelValue: F.value[
|
|
159
|
-
"onUpdate:modelValue": (O) => F.value[
|
|
158
|
+
modelValue: F.value[B].key,
|
|
159
|
+
"onUpdate:modelValue": (O) => F.value[B].key = O,
|
|
160
160
|
rules: [
|
|
161
161
|
(O) => !!O || i(u)("menu.cooking_guide.step_dialog.sections.variables.validation.required"),
|
|
162
162
|
(O) => !O || /^[a-z]+$/.test(O) || i(u)("menu.cooking_guide.step_dialog.sections.variables.validation.lowercase"),
|
|
163
|
-
(O) => !O || F.value.findIndex((de) => de.key === O) ===
|
|
163
|
+
(O) => !O || F.value.findIndex((de) => de.key === O) === B || i(u)("menu.cooking_guide.step_dialog.sections.variables.validation.duplicate")
|
|
164
164
|
],
|
|
165
165
|
placeholder: i(u)("menu.cooking_guide.step_dialog.sections.variables.placeholders.key")
|
|
166
166
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "rules", "placeholder"])
|
|
167
167
|
]),
|
|
168
168
|
l("div", Ge, [
|
|
169
169
|
a(_, {
|
|
170
|
-
modelValue: F.value[
|
|
171
|
-
"onUpdate:modelValue": (O) => F.value[
|
|
170
|
+
modelValue: F.value[B].value,
|
|
171
|
+
"onUpdate:modelValue": (O) => F.value[B].value = O,
|
|
172
172
|
rules: [
|
|
173
173
|
(O) => !!O || i(u)("menu.cooking_guide.step_dialog.sections.variables.validation.required")
|
|
174
174
|
],
|
|
@@ -179,7 +179,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
179
179
|
icon: "delete",
|
|
180
180
|
variant: "tertiary",
|
|
181
181
|
"text-color": "neutral-gray-400",
|
|
182
|
-
onClick: () => R(
|
|
182
|
+
onClick: () => R(B)
|
|
183
183
|
}, null, 8, ["onClick"])
|
|
184
184
|
]))), 128))
|
|
185
185
|
])
|
|
@@ -191,17 +191,17 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
191
191
|
}, {
|
|
192
192
|
default: p(() => [
|
|
193
193
|
l("div", Ue, [
|
|
194
|
-
l("div",
|
|
195
|
-
(k(!0), I(z, null, J(h.value, (
|
|
196
|
-
key:
|
|
197
|
-
label:
|
|
194
|
+
l("div", Me, [
|
|
195
|
+
(k(!0), I(z, null, J(h.value, (T) => (k(), Y(P, {
|
|
196
|
+
key: T.label,
|
|
197
|
+
label: T.label,
|
|
198
198
|
class: "text-fm-color-primary bg-fm-color-system-warning-100",
|
|
199
|
-
onMousedown: ae(() => G(
|
|
199
|
+
onMousedown: ae(() => G(T.label), ["prevent"])
|
|
200
200
|
}, null, 8, ["label", "onMousedown"]))), 128))
|
|
201
201
|
]),
|
|
202
202
|
a(W, {
|
|
203
203
|
modelValue: m.value.instruction,
|
|
204
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
204
|
+
"onUpdate:modelValue": t[0] || (t[0] = (T) => m.value.instruction = T),
|
|
205
205
|
ref: "textareaRef"
|
|
206
206
|
}, null, 8, ["modelValue"])
|
|
207
207
|
])
|
|
@@ -214,16 +214,16 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
214
214
|
}, 8, ["modelValue", "header", "is-container", "is-container-props", "onOn:clickedAway"]);
|
|
215
215
|
};
|
|
216
216
|
}
|
|
217
|
-
}), ze = { class: "w-[700px]" }, Ae = { class: "flex bg-fm-color-neutral-gray-100" }, Re = { class: "px-16 py-8 grow" }, Pe = { class: "px-16 py-8 w-[200px]" }, qe = { class: "px-16 py-8 w-[200px]" }, je = { class: "px-16 py-8 grow" }, Ye = { class: "px-16 py-8 w-[200px] flex flex-col gap-8" }, Je = { class: "px-16 py-8 w-[200px] flex flex-col gap-8" },
|
|
217
|
+
}), ze = { class: "w-[700px]" }, Ae = { class: "flex bg-fm-color-neutral-gray-100" }, Re = { class: "px-16 py-8 grow" }, Pe = { class: "px-16 py-8 w-[200px]" }, qe = { class: "px-16 py-8 w-[200px]" }, je = { class: "px-16 py-8 grow" }, Ye = { class: "px-16 py-8 w-[200px] flex flex-col gap-8" }, Je = { class: "px-16 py-8 w-[200px] flex flex-col gap-8" }, Qe = /* @__PURE__ */ le({
|
|
218
218
|
__name: "CookingGuideStepOverrideDialog",
|
|
219
219
|
emits: ["onComplete"],
|
|
220
|
-
setup(N, { expose: g, emit:
|
|
220
|
+
setup(N, { expose: g, emit: Q }) {
|
|
221
221
|
const { t: u } = se();
|
|
222
222
|
g({
|
|
223
223
|
show: d,
|
|
224
224
|
hide: $
|
|
225
225
|
});
|
|
226
|
-
const D =
|
|
226
|
+
const D = Q;
|
|
227
227
|
function L() {
|
|
228
228
|
return {
|
|
229
229
|
productId: "",
|
|
@@ -238,12 +238,12 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
238
238
|
C.value = !1;
|
|
239
239
|
}
|
|
240
240
|
const m = w(L()), F = V(() => m.value.overrides.reduce((h, n) => (h[n.id] = n, h), {}));
|
|
241
|
-
function
|
|
241
|
+
function X(h, n) {
|
|
242
242
|
var s;
|
|
243
243
|
return ((s = F.value[h]) == null ? void 0 : s.variables[n]) ?? "";
|
|
244
244
|
}
|
|
245
245
|
function R(h, n, s) {
|
|
246
|
-
const K = m.value.overrides.findIndex((
|
|
246
|
+
const K = m.value.overrides.findIndex((M) => M.id === h);
|
|
247
247
|
s ? K < 0 ? m.value.overrides.push({
|
|
248
248
|
id: h,
|
|
249
249
|
variables: { [n]: s }
|
|
@@ -253,7 +253,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
253
253
|
$(), D("onComplete", m.value);
|
|
254
254
|
}
|
|
255
255
|
return (h, n) => {
|
|
256
|
-
const s = x("FmTextField"), K = x("FmSpacer"),
|
|
256
|
+
const s = x("FmTextField"), K = x("FmSpacer"), M = x("FmButton"), v = x("FmDialog");
|
|
257
257
|
return k(), Y(v, {
|
|
258
258
|
modelValue: C.value,
|
|
259
259
|
"onUpdate:modelValue": n[0] || (n[0] = (t) => C.value = t),
|
|
@@ -266,14 +266,14 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
266
266
|
]),
|
|
267
267
|
"dialog-footer": p(() => [
|
|
268
268
|
a(K),
|
|
269
|
-
a(
|
|
269
|
+
a(M, {
|
|
270
270
|
class: "sm:w-full xs:w-full",
|
|
271
271
|
label: i(u)("menu.cooking_guide.step_override_dialog.actions.cancel"),
|
|
272
272
|
size: "md",
|
|
273
273
|
variant: "tertiary",
|
|
274
274
|
onClick: $
|
|
275
275
|
}, null, 8, ["label"]),
|
|
276
|
-
a(
|
|
276
|
+
a(M, {
|
|
277
277
|
class: "sm:w-full xs:w-full",
|
|
278
278
|
label: i(u)("menu.cooking_guide.step_override_dialog.actions.save"),
|
|
279
279
|
size: "md",
|
|
@@ -302,7 +302,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
302
302
|
l("div", Je, [
|
|
303
303
|
(k(!0), I(z, null, J(t.variables, (f, _) => (k(), I("div", { key: _ }, [
|
|
304
304
|
a(s, {
|
|
305
|
-
"model-value":
|
|
305
|
+
"model-value": X(t.id, _.toString()),
|
|
306
306
|
placeholder: f,
|
|
307
307
|
"onUpdate:modelValue": (P) => R(t.id, _.toString(), P)
|
|
308
308
|
}, null, 8, ["model-value", "placeholder", "onUpdate:modelValue"])
|
|
@@ -315,7 +315,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
315
315
|
}, 8, ["modelValue"]);
|
|
316
316
|
};
|
|
317
317
|
}
|
|
318
|
-
}),
|
|
318
|
+
}), Xe = { class: "fm-typo-en-title-md-600" }, He = { class: "space-y-24" }, We = { class: "flex items-center" }, Ze = { class: "flex-1" }, eo = { class: "flex items-center gap-8" }, oo = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, to = { class: "flex-1" }, no = { class: "bg-fm-color-neutral-gray-100 px-16 py-8" }, io = { class: "px-16 py-8 flex-1 flex gap-4 overflow-auto min-w-0" }, ao = { class: "fm-typo-en-body-md-500" }, lo = { class: "px-16 py-8 flex gap-8" }, so = { class: "flex gap-8 items-center justify-start" }, uo = /* @__PURE__ */ le({
|
|
319
319
|
__name: "CookingGuideDialog",
|
|
320
320
|
props: {
|
|
321
321
|
categorizedItems: {
|
|
@@ -328,7 +328,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
328
328
|
}
|
|
329
329
|
},
|
|
330
330
|
emits: ["onSave"],
|
|
331
|
-
setup(N, { expose: g, emit:
|
|
331
|
+
setup(N, { expose: g, emit: Q }) {
|
|
332
332
|
const u = N;
|
|
333
333
|
g({
|
|
334
334
|
showModal: U,
|
|
@@ -358,7 +358,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
358
358
|
var o;
|
|
359
359
|
(o = $.value) == null || o.show(e);
|
|
360
360
|
}
|
|
361
|
-
function
|
|
361
|
+
function X(e) {
|
|
362
362
|
d.value.steps.splice(e, 1);
|
|
363
363
|
}
|
|
364
364
|
function R(e) {
|
|
@@ -382,11 +382,11 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
382
382
|
}
|
|
383
383
|
function n({ items: e }) {
|
|
384
384
|
const o = e.reduce((r, c) => (r[c._id] = r[c._id] ?? [], c.combinationKey && (r[c._id] = [...r[c._id], c.combinationKey]), r), {}), b = Object.entries(o).reduce(
|
|
385
|
-
(r, [c,
|
|
385
|
+
(r, [c, H]) => {
|
|
386
386
|
var te;
|
|
387
|
-
return r =
|
|
387
|
+
return r = H.length > 0 ? [
|
|
388
388
|
...r,
|
|
389
|
-
...
|
|
389
|
+
...H.map((ne) => {
|
|
390
390
|
var ie;
|
|
391
391
|
return {
|
|
392
392
|
productId: c,
|
|
@@ -415,7 +415,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
415
415
|
bindings: h(e.itemId, e.combinationKey)
|
|
416
416
|
});
|
|
417
417
|
}
|
|
418
|
-
function
|
|
418
|
+
function M({ productId: e, combinationKey: o, overrides: b }) {
|
|
419
419
|
const r = d.value.bindings.map((c) => ({
|
|
420
420
|
...c,
|
|
421
421
|
overrides: c.productId === e && c.combinationKey == o ? b : c.overrides
|
|
@@ -433,18 +433,18 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
433
433
|
const b = e[o.productId] ?? [];
|
|
434
434
|
return o.combinationKey ? e[o.productId] = [...b, o.combinationKey] : e[o.productId] = [], e;
|
|
435
435
|
}, {})
|
|
436
|
-
), q = w(""),
|
|
436
|
+
), q = w(""), T = V(() => u.categorizedItems.reduce((e, o) => {
|
|
437
437
|
var b, r;
|
|
438
438
|
for (const c of o.items)
|
|
439
439
|
(b = c.variant) != null && b.variantGroupIds.length && ((r = c.variant) == null ? void 0 : r.variantGroupIds.length) > 0 ? e = [
|
|
440
440
|
...e,
|
|
441
|
-
...c.variant.variantCombinations.map((
|
|
441
|
+
...c.variant.variantCombinations.map((H) => ({
|
|
442
442
|
categoryId: o.id,
|
|
443
443
|
categoryName: o.name,
|
|
444
444
|
itemId: c._id,
|
|
445
445
|
itemCode: c.code,
|
|
446
|
-
itemName: `${c.name} - ${
|
|
447
|
-
combinationKey:
|
|
446
|
+
itemName: `${c.name} - ${H.codeName}`,
|
|
447
|
+
combinationKey: H.combinationKey
|
|
448
448
|
}))
|
|
449
449
|
] : e.push({
|
|
450
450
|
categoryId: o.id,
|
|
@@ -454,17 +454,17 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
454
454
|
itemName: c.name
|
|
455
455
|
});
|
|
456
456
|
return e;
|
|
457
|
-
}, [])),
|
|
457
|
+
}, [])), B = V(() => T.value.filter((e) => {
|
|
458
458
|
const o = W.value[e.itemId];
|
|
459
459
|
return !!o && (!e.combinationKey || o.includes(e.combinationKey));
|
|
460
460
|
})), O = V(() => {
|
|
461
461
|
const e = q.value.toLowerCase();
|
|
462
|
-
return e ?
|
|
462
|
+
return e ? B.value.filter(
|
|
463
463
|
(o) => {
|
|
464
464
|
var b;
|
|
465
465
|
return ((b = o.itemCode) == null ? void 0 : b.toLowerCase().includes(e)) || o.itemName.toLowerCase().includes(e) || o.categoryName.toLowerCase().includes(e);
|
|
466
466
|
}
|
|
467
|
-
) :
|
|
467
|
+
) : B.value;
|
|
468
468
|
}), de = V(() => O.value.reduce(
|
|
469
469
|
(e, o) => {
|
|
470
470
|
const b = e.findIndex((r) => r.id === o.categoryId);
|
|
@@ -478,7 +478,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
478
478
|
}, e;
|
|
479
479
|
},
|
|
480
480
|
[]
|
|
481
|
-
)), ge =
|
|
481
|
+
)), ge = Q;
|
|
482
482
|
w();
|
|
483
483
|
const _e = pe(
|
|
484
484
|
() => !me.isEqual(C.value, d.value),
|
|
@@ -490,7 +490,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
490
490
|
E(), ge("onSave", d.value);
|
|
491
491
|
}
|
|
492
492
|
return (e, o) => {
|
|
493
|
-
const b = x("FmTextField"), r = x("FmButton"), c = x("FmCardSection"),
|
|
493
|
+
const b = x("FmTextField"), r = x("FmButton"), c = x("FmCardSection"), H = x("FmCard"), te = x("FmSpacer"), ne = x("FmSearch"), ie = x("FmSideSheet");
|
|
494
494
|
return k(), I(z, null, [
|
|
495
495
|
a(ie, {
|
|
496
496
|
modelValue: L.value,
|
|
@@ -506,7 +506,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
506
506
|
"onOn:clickedAway": i(_e)
|
|
507
507
|
}, {
|
|
508
508
|
"side-sheet-header": p(() => [
|
|
509
|
-
l("span",
|
|
509
|
+
l("span", Xe, S(f.value), 1)
|
|
510
510
|
]),
|
|
511
511
|
"side-sheet-footer": p(() => [
|
|
512
512
|
l("div", so, [
|
|
@@ -525,7 +525,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
525
525
|
])
|
|
526
526
|
]),
|
|
527
527
|
default: p(() => [
|
|
528
|
-
l("div",
|
|
528
|
+
l("div", He, [
|
|
529
529
|
a(Z, {
|
|
530
530
|
title: i(t)("menu.cooking_guide.dialog.sections.guide_detail.title")
|
|
531
531
|
}, {
|
|
@@ -564,7 +564,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
564
564
|
"item-key": "id"
|
|
565
565
|
}, {
|
|
566
566
|
item: p(({ element: y, index: j }) => [
|
|
567
|
-
a(
|
|
567
|
+
a(H, {
|
|
568
568
|
variant: "outlined",
|
|
569
569
|
class: "rounded-md mb-16 items-center",
|
|
570
570
|
horizontal: "",
|
|
@@ -588,7 +588,7 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
588
588
|
a(r, {
|
|
589
589
|
icon: "delete",
|
|
590
590
|
variant: "tertiary",
|
|
591
|
-
onClick: ae(() =>
|
|
591
|
+
onClick: ae(() => X(j), ["stop"])
|
|
592
592
|
}, null, 8, ["onClick"])
|
|
593
593
|
]),
|
|
594
594
|
_: 2
|
|
@@ -674,15 +674,15 @@ const $e = { class: "flex items-center gap-8" }, Oe = { class: "grow" }, Ee = {
|
|
|
674
674
|
]),
|
|
675
675
|
_: 1
|
|
676
676
|
}, 8, ["modelValue", "header", "is-container", "is-container-props", "onOn:clickedAway"]),
|
|
677
|
-
a(
|
|
677
|
+
a(Be, {
|
|
678
678
|
ref_key: "cookingGuideStepDialogRef",
|
|
679
679
|
ref: $,
|
|
680
680
|
onOnComplete: R
|
|
681
681
|
}, null, 512),
|
|
682
|
-
a(
|
|
682
|
+
a(Qe, {
|
|
683
683
|
ref_key: "cookingGuideStepOverrideDialogRef",
|
|
684
684
|
ref: s,
|
|
685
|
-
onOnComplete:
|
|
685
|
+
onOnComplete: M
|
|
686
686
|
}, null, 512)
|
|
687
687
|
], 64);
|
|
688
688
|
};
|
|
@@ -726,7 +726,7 @@ const po = {
|
|
|
726
726
|
setup(N) {
|
|
727
727
|
const {
|
|
728
728
|
t: g
|
|
729
|
-
} = se(),
|
|
729
|
+
} = se(), Q = V(() => [{
|
|
730
730
|
accessorKey: "name",
|
|
731
731
|
header: () => g("menu.cooking_guide.table.columns.name"),
|
|
732
732
|
cell: (n) => n.getValue(),
|
|
@@ -783,14 +783,14 @@ const po = {
|
|
|
783
783
|
const s = n._id ? co(n) : ro(n);
|
|
784
784
|
await E.updateMenu(s, n.name);
|
|
785
785
|
}
|
|
786
|
-
const
|
|
786
|
+
const X = ye();
|
|
787
787
|
async function R(n) {
|
|
788
788
|
let s = [A("span", g("menu.cooking_guide.dialogs.remove.message.prefix")), A("span", {
|
|
789
789
|
class: "fm-typo-en-body-lg-600"
|
|
790
790
|
}, n.name), A("span", "?")];
|
|
791
791
|
n.bindings.length && (s = [A("span", g("menu.cooking_guide.dialogs.remove.message.products_using")), A("span", {
|
|
792
792
|
class: "fm-typo-en-body-lg-600"
|
|
793
|
-
}, n.bindings.length), A("span", g("menu.cooking_guide.dialogs.remove.message.products_count")), ...s]),
|
|
793
|
+
}, n.bindings.length), A("span", g("menu.cooking_guide.dialogs.remove.message.products_count")), ...s]), X.open({
|
|
794
794
|
title: g("menu.cooking_guide.dialogs.remove.title"),
|
|
795
795
|
contentComponent: A("div", s),
|
|
796
796
|
primaryActions: {
|
|
@@ -811,7 +811,7 @@ const po = {
|
|
|
811
811
|
return n ? C.value.filter((s) => s.name.toLowerCase().includes(n)) : C.value;
|
|
812
812
|
});
|
|
813
813
|
return (n, s) => {
|
|
814
|
-
const K = x("FmSearch"),
|
|
814
|
+
const K = x("FmSearch"), M = x("FmTable"), v = x("FmButton"), t = x("FmListItem"), f = x("FmList");
|
|
815
815
|
return k(), Y(Ie, {
|
|
816
816
|
heading: i(g)("menu.cooking_guide.title")
|
|
817
817
|
}, {
|
|
@@ -834,8 +834,8 @@ const po = {
|
|
|
834
834
|
}, null, 8, ["modelValue", "placeholder"])]), a(he, {
|
|
835
835
|
class: "xs:hidden block"
|
|
836
836
|
}, {
|
|
837
|
-
default: p(() => [a(
|
|
838
|
-
"column-defs":
|
|
837
|
+
default: p(() => [a(M, {
|
|
838
|
+
"column-defs": Q.value,
|
|
839
839
|
loading: D.value,
|
|
840
840
|
"page-size": C.value.length,
|
|
841
841
|
"row-data": C.value,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as S, computed as o, createBlock as v, openBlock as t, unref as c, withCtx as g, renderSlot as B, ref as A, resolveComponent as I, createElementBlock as a, createElementVNode as m, createCommentVNode as b, Fragment as f, renderList as C, toDisplayString as d, withModifiers as F } from "vue";
|
|
2
2
|
import { useI18n as V } from "@feedmepos/mf-common";
|
|
3
3
|
import { _ as M } from "./MenuSelector.vue_vue_type_script_setup_true_lang-K6Z0QJBl.js";
|
|
4
|
-
import { u as D } from "./index.vue_vue_type_script_setup_true_lang-
|
|
4
|
+
import { u as D } from "./index.vue_vue_type_script_setup_true_lang-kj6HkxwD.js";
|
|
5
5
|
import { useBreakpoints as E } from "@feedmepos/ui-library";
|
|
6
6
|
import { _ as y } from "./TextChip.vue_vue_type_script_setup_true_lang-8frWuZFL.js";
|
|
7
7
|
const X = /* @__PURE__ */ S({
|
|
@@ -2,9 +2,9 @@ import { defineComponent as m, ref as p, createBlock as i, openBlock as d, unref
|
|
|
2
2
|
import { useI18n as _ } from "@feedmepos/mf-common";
|
|
3
3
|
import { _ as f } from "./ResponsiveFabButton.vue_vue_type_script_setup_true_lang-Cn-3MRBO.js";
|
|
4
4
|
import { _ as g } from "./PageLayout.vue_vue_type_script_setup_true_lang-2f0QfweQ.js";
|
|
5
|
-
import { _ as y } from "./Group.vue_vue_type_script_setup_true_lang-
|
|
6
|
-
import { A as b } from "./item-
|
|
7
|
-
import { a as h } from "./menu-
|
|
5
|
+
import { _ as y } from "./Group.vue_vue_type_script_setup_true_lang-DZhM1Tpb.js";
|
|
6
|
+
import { A as b } from "./item-cmnP2N-a.js";
|
|
7
|
+
import { a as h } from "./menu-CgQPOu3W.js";
|
|
8
8
|
const v = { class: "flex-1 flex justify-between gap-8 pl-8" }, x = { class: "flex items-center" }, k = { class: "bg-fm-color-neutral-gray-100 rounded-md px-8 py-4" }, C = { class: "fm-typo-en-body-md-600 font-semibold" }, j = /* @__PURE__ */ m({
|
|
9
9
|
__name: "Group",
|
|
10
10
|
setup(N) {
|