@feedmepos/mf-menu 1.0.1-dev.2 → 1.0.1-dev.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.
- package/dist/{App-CdIN4s5n.js → App-DEoljb3M.js} +546 -533
- package/dist/{BindingTable.vue_vue_type_script_setup_true_lang-CoHlJwpz.js → BindingTable.vue_vue_type_script_setup_true_lang-DACfW6SY.js} +1 -1
- package/dist/{Catalog-DjAubC9s.js → Catalog-B6mXH-Ez.js} +4 -4
- package/dist/{CatalogBinding-5JNRTbyZ.js → CatalogBinding-CZbbxQCa.js} +3 -3
- package/dist/{CatalogEditTabs.vue_vue_type_script_setup_true_lang-BorOjk1k.js → CatalogEditTabs.vue_vue_type_script_setup_true_lang-CFjBkgkl.js} +3 -3
- package/dist/{CatalogEditor.vue_vue_type_script_setup_true_lang-CkF7O_V-.js → CatalogEditor.vue_vue_type_script_setup_true_lang-owNQUf8y.js} +6 -6
- package/dist/{CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-3fL43MuR.js → CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-DJLjbLGK.js} +3 -3
- package/dist/{Category-COug7fz8.js → Category-B37n9Row.js} +2 -2
- package/dist/{Category-BbiN4hd7.js → Category-DHGrowud.js} +5 -5
- package/dist/{CategoryList.vue_vue_type_script_setup_true_lang-B_9aPMIN.js → CategoryList.vue_vue_type_script_setup_true_lang-_Ux8uXwn.js} +92 -91
- package/dist/{CookingGuide-Dg7kuF6l.js → CookingGuide-4i1KsBxo.js} +262 -256
- package/dist/{Group-BRpmTqyT.js → Group-DVB_G6lM.js} +5 -5
- package/dist/{Group-C-hwlkgJ.js → Group-N5_9GK2v.js} +2 -2
- package/dist/{GroupList.vue_vue_type_script_setup_true_lang-DowoJ3WM.js → GroupList.vue_vue_type_script_setup_true_lang-BDWyiP8J.js} +5 -5
- package/dist/{Ingredient-BQYnARdC.js → Ingredient-C-puVgJK.js} +3 -3
- package/dist/{LinkProductSideSheet.vue_vue_type_script_setup_true_lang-CgTDkHle.js → LinkProductSideSheet.vue_vue_type_script_setup_true_lang-ChDd6vJd.js} +1 -1
- package/dist/{MenuSetting-DsdM2_OW.js → MenuSetting-QhU37DTL.js} +3 -3
- package/dist/{OrderPacing-5x2YH-_l.js → OrderPacing-COY_HJ8I.js} +96 -93
- package/dist/{OrderPacingFields.vue_vue_type_script_setup_true_lang-DVGJjpiM.js → OrderPacingFields.vue_vue_type_script_setup_true_lang-BAbojJnz.js} +1 -1
- package/dist/{Preview-AdgGTYlQ.js → Preview-DrbsRznu.js} +1 -1
- package/dist/{PriceTierNotice.vue_vue_type_script_setup_true_lang-vmxVZ2ya.js → PriceTierNotice.vue_vue_type_script_setup_true_lang-BTJwvrlT.js} +1 -1
- package/dist/{PrintRoute-COkCv4gf.js → PrintRoute-DVJAvYq-.js} +158 -152
- package/dist/{Product-BJFb_J4h.js → Product-ClT1oFVA.js} +4 -4
- package/dist/{ProductEditorHost.vue_vue_type_script_setup_true_lang-Tpp8MBYS.js → ProductEditorHost.vue_vue_type_script_setup_true_lang-B4qpB-yA.js} +2 -2
- package/dist/{ProductGroupCreateSheet.vue_vue_type_script_setup_true_lang-C25Pwqme.js → ProductGroupCreateSheet.vue_vue_type_script_setup_true_lang-BWZwFal7.js} +3 -3
- package/dist/{ProductImageEditorDialog.vue_vue_type_script_setup_true_lang-BMAtAK9D.js → ProductImageEditorDialog.vue_vue_type_script_setup_true_lang-yZSYrcYe.js} +1 -1
- package/dist/{ProductInlineCreateHost.vue_vue_type_script_setup_true_lang-Dl4Zr5tx.js → ProductInlineCreateHost.vue_vue_type_script_setup_true_lang-3SaYTgCI.js} +1181 -1174
- package/dist/ProductInternalTools-DRcfn5DE.js +2147 -0
- package/dist/{ProductInventoryDialog-C3ruRWU5.js → ProductInventoryDialog-i48yqlp_.js} +1 -1
- package/dist/{ProductInventoryDialog.vue_vue_type_script_setup_true_lang-MpdIixqI.js → ProductInventoryDialog.vue_vue_type_script_setup_true_lang-C7z4BHKp.js} +1 -1
- package/dist/{ProductList.vue_vue_type_script_setup_true_lang-9_ohgfqE.js → ProductList.vue_vue_type_script_setup_true_lang-DkIwQeby.js} +1990 -1967
- package/dist/{ProductVariantTranslationSheet.vue_vue_type_script_setup_true_lang-Ctbz-8cd.js → ProductVariantTranslationSheet.vue_vue_type_script_setup_true_lang-Dr0r1hYM.js} +1 -1
- package/dist/{Products-DMrjQFfu.js → Products-B4yaF9Y5.js} +3 -3
- package/dist/{Publish-f6g0dIao.js → Publish-D8pKpnju.js} +3 -3
- package/dist/{Recipe-p-wxadSN.js → Recipe-Cz4s5W4k.js} +3 -3
- package/dist/{Scheduler-CtebRafn.js → Scheduler-xE_rjFjJ.js} +3 -3
- package/dist/{ServingSequence-CEd4ywOQ.js → ServingSequence-BjD1Xn6Q.js} +103 -97
- package/dist/{Setting-bPKadRu-.js → Setting-BrD0NB_a.js} +6 -6
- package/dist/{Subcategory-DBCnIP0b.js → Subcategory-wbHw1iCU.js} +141 -129
- package/dist/{Takeaway-VBkdW1DM.js → Takeaway-CIqSThUQ.js} +5 -5
- package/dist/{Takeaway-GNRHR5kN.js → Takeaway-DM7weBPk.js} +2 -2
- package/dist/{TakeawayList.vue_vue_type_script_setup_true_lang-DvX3k0Jg.js → TakeawayList.vue_vue_type_script_setup_true_lang-HZP5jmAy.js} +117 -111
- package/dist/{TreeEditorOpenner.vue_vue_type_script_setup_true_lang-D1qaEVUu.js → TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CLeJxNfG.js} +6 -6
- package/dist/{Unit-DbGKIprZ.js → Unit-RHuHWCCg.js} +2 -2
- package/dist/{Variant-_edSAKif.js → Variant-MA-mdYxx.js} +114 -108
- package/dist/{_id_-BNVtBV3q.js → _id_-CO1c1eIn.js} +3 -3
- package/dist/{app-BlTv5xag.js → app-DnIyFwTs.js} +420 -406
- package/dist/app.js +1 -1
- package/dist/apps/mf-menu/src/router/shared.d.ts +33 -0
- package/dist/apps/mf-menu/src/sdk/import-export.d.ts +8 -2
- package/dist/apps/mf-menu/tsconfig.app.tsbuildinfo +1 -1
- package/dist/assets/{menu-compute-BzchkTYh.js → menu-compute-BYzYhsd6.js} +2 -2
- package/dist/assets/{validate-menu-CTV_cJNG.js → validate-menu-oaYEuMiz.js} +2 -2
- package/dist/mf-menu.css +1 -1
- package/dist/{provide-dbE6Qt1z.js → provide-UZbVvMqZ.js} +56729 -55678
- package/dist/{useActionFeedback-CdY_C_HX.js → useActionFeedback-CfPMryOm.js} +1 -1
- package/package.json +1 -1
- package/dist/ProductInternalTools-thlSvqbA.js +0 -2906
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
import { defineComponent as se, computed as
|
|
1
|
+
import { defineComponent as se, computed as C, ref as O, shallowRef as te, h as le, withModifiers as ye, onUnmounted as fe, resolveComponent as f, openBlock as r, createBlock as k, unref as e, withCtx as c, createElementBlock as g, toDisplayString as h, createVNode as d, Fragment as $, createElementVNode as p, createCommentVNode as F, renderList as oe } from "vue";
|
|
2
2
|
import { useI18n as _e } from "@feedmepos/mf-common";
|
|
3
3
|
import { useDialog as he, components as R, FmButtonVariant as ke } from "@feedmepos/ui-library";
|
|
4
4
|
import { _ as ne } from "./index.vue_vue_type_script_setup_true_lang-CGPDazqs.js";
|
|
5
5
|
import { _ as xe } from "./ListCountTag.vue_vue_type_script_setup_true_lang-0bjk8Aly.js";
|
|
6
6
|
import { _ as we } from "./PageLayout.vue_vue_type_script_setup_true_lang-B3szUH39.js";
|
|
7
|
-
import { _ as
|
|
8
|
-
import { u as
|
|
9
|
-
import { b as Se, u as Ve, a as Le } from "./provide-
|
|
7
|
+
import { _ as Ce } from "./TranslationSideSheet.vue_vue_type_script_setup_true_lang-B0j2PNih.js";
|
|
8
|
+
import { u as Fe } from "./useActionFeedback-CfPMryOm.js";
|
|
9
|
+
import { b as Se, u as Ve, a as Le } from "./provide-UZbVvMqZ.js";
|
|
10
10
|
import { _ as Ue } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
11
|
-
const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "flex items-center" },
|
|
11
|
+
const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "flex items-center" }, Ne = {
|
|
12
12
|
key: 0,
|
|
13
13
|
class: "text-fm-color-typo-secondary",
|
|
14
14
|
role: "alert"
|
|
15
|
-
},
|
|
15
|
+
}, ze = {
|
|
16
16
|
key: 1,
|
|
17
17
|
"data-menu-state": "unavailable"
|
|
18
|
-
},
|
|
18
|
+
}, Ee = { class: "flex justify-end items-center" }, Ie = { class: "w-[320px]" }, je = { class: "fm-typo-en-title-md-600" }, Be = { class: "flex flex-col gap-32 h-full min-h-0 py-16" }, Me = { "data-testid": "subcategory-translation-button" }, Oe = { class: "py-12 px-16 space-y-4" }, $e = { key: 0 }, Re = { class: "flex gap-8 items-center justify-start" }, Ae = { class: "fm-typo-en-title-sm-600" }, Pe = { class: "py-12 px-16 space-y-4" }, qe = { key: 0 }, Ke = { class: "flex w-full gap-8 items-center justify-end px-0 pb-0" }, Qe = /* @__PURE__ */ se({
|
|
19
19
|
__name: "SubcategoryList",
|
|
20
20
|
props: {
|
|
21
21
|
sdk: {}
|
|
22
22
|
},
|
|
23
23
|
setup(A) {
|
|
24
|
-
const
|
|
25
|
-
() =>
|
|
26
|
-
),
|
|
24
|
+
const b = A, { t: a, n: P } = _e(), S = Se(), ue = he(), { run: B } = Fe(), x = Ve(b.sdk.subCategory.list), s = C(
|
|
25
|
+
() => x.value.status === "ready" ? x.value.value : null
|
|
26
|
+
), V = O(!1), L = O(!1), N = O(!1), q = C(() => {
|
|
27
27
|
var t;
|
|
28
28
|
return ((t = s.value) == null ? void 0 : t.query) ?? "";
|
|
29
|
-
}),
|
|
30
|
-
|
|
31
|
-
),
|
|
32
|
-
|
|
29
|
+
}), u = te(
|
|
30
|
+
b.sdk.subCategory.editor()
|
|
31
|
+
), U = te(
|
|
32
|
+
u.value.get()
|
|
33
33
|
);
|
|
34
|
-
let M =
|
|
35
|
-
(t) =>
|
|
34
|
+
let M = u.value.subscribe(
|
|
35
|
+
(t) => U.value = t
|
|
36
36
|
);
|
|
37
|
-
const l =
|
|
38
|
-
() =>
|
|
37
|
+
const l = C(
|
|
38
|
+
() => U.value.status === "ready" ? U.value.value : null
|
|
39
39
|
);
|
|
40
40
|
function K(t) {
|
|
41
|
-
var o,
|
|
42
|
-
return ((
|
|
43
|
-
(
|
|
44
|
-
)) == null ? void 0 :
|
|
41
|
+
var o, v;
|
|
42
|
+
return ((v = (o = l.value) == null ? void 0 : o.supportedLocales.find(
|
|
43
|
+
(w) => w.code === t
|
|
44
|
+
)) == null ? void 0 : v.name) ?? t;
|
|
45
45
|
}
|
|
46
46
|
function Q(t) {
|
|
47
|
-
M(),
|
|
48
|
-
(o) =>
|
|
47
|
+
M(), u.value.dispose(), u.value = b.sdk.subCategory.editor(t), U.value = u.value.get(), M = u.value.subscribe(
|
|
48
|
+
(o) => U.value = o
|
|
49
49
|
);
|
|
50
50
|
}
|
|
51
51
|
function G() {
|
|
52
|
-
!s.value || s.value.create.state !== "allowed" || (Q(),
|
|
52
|
+
!s.value || s.value.create.state !== "allowed" || (Q(), N.value = !0);
|
|
53
53
|
}
|
|
54
54
|
function re(t) {
|
|
55
|
-
Q(t.id),
|
|
55
|
+
Q(t.id), V.value = !0;
|
|
56
56
|
}
|
|
57
|
-
function
|
|
58
|
-
|
|
57
|
+
function z() {
|
|
58
|
+
V.value = !1, N.value = !1, L.value = !1;
|
|
59
59
|
}
|
|
60
60
|
function H() {
|
|
61
61
|
var t;
|
|
62
|
-
((t = l.value) == null ? void 0 : t.translation.state) === "allowed" && (
|
|
62
|
+
((t = l.value) == null ? void 0 : t.translation.state) === "allowed" && (u.value.beginTranslationEdit(), L.value = !0);
|
|
63
63
|
}
|
|
64
64
|
function ie() {
|
|
65
|
-
|
|
65
|
+
u.value.saveTranslationEdit(), L.value = !1;
|
|
66
66
|
}
|
|
67
67
|
function J() {
|
|
68
|
-
|
|
68
|
+
u.value.discardTranslationEdit(), L.value = !1;
|
|
69
69
|
}
|
|
70
70
|
async function W() {
|
|
71
|
-
var
|
|
72
|
-
const t = (
|
|
73
|
-
t === "update" &&
|
|
71
|
+
var w, E, I;
|
|
72
|
+
const t = (w = l.value) == null ? void 0 : w.mode, o = ((I = (E = l.value) == null ? void 0 : E.name) == null ? void 0 : I.trim()) ?? "";
|
|
73
|
+
t === "update" && z(), (await B(() => u.value.submit(), {
|
|
74
74
|
successMessage: t === "update" ? a("menu.subcategory.manager.dialog.update.success", { name: o }) : a("menu.subcategory.manager.dialog.add.success", { name: o })
|
|
75
|
-
})).kind === "success" ?
|
|
75
|
+
})).kind === "success" ? z() : t === "update" && (V.value = !0);
|
|
76
76
|
}
|
|
77
77
|
function de(t) {
|
|
78
78
|
t.remove.state === "allowed" && ue.open({
|
|
@@ -90,26 +90,26 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
90
90
|
close: !0
|
|
91
91
|
}
|
|
92
92
|
}).onPrimary(async () => {
|
|
93
|
-
await B(() =>
|
|
93
|
+
await B(() => b.sdk.subCategory.remove(t.id), {
|
|
94
94
|
successMessage: a("menu.subcategory.dialog.remove.success", {
|
|
95
95
|
name: t.name
|
|
96
96
|
})
|
|
97
97
|
});
|
|
98
98
|
});
|
|
99
99
|
}
|
|
100
|
-
const ce =
|
|
100
|
+
const ce = C(() => {
|
|
101
101
|
var t;
|
|
102
102
|
return [...((t = s.value) == null ? void 0 : t.rows) ?? []];
|
|
103
|
-
}), me =
|
|
103
|
+
}), me = C(() => !s.value || s.value.reorder.state !== "allowed" ? !1 : () => !0);
|
|
104
104
|
function pe(t) {
|
|
105
105
|
!s.value || s.value.reorder.state !== "allowed" || B(
|
|
106
|
-
() =>
|
|
106
|
+
() => b.sdk.subCategory.reorder(t.map((o) => o.id)),
|
|
107
107
|
{
|
|
108
108
|
successMessage: a("menu.subcategory.rearrange.success")
|
|
109
109
|
}
|
|
110
110
|
);
|
|
111
111
|
}
|
|
112
|
-
const ve =
|
|
112
|
+
const ve = C(() => [
|
|
113
113
|
{
|
|
114
114
|
accessorKey: "name",
|
|
115
115
|
header: () => a("menu.subcategory.columns.title"),
|
|
@@ -140,22 +140,22 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
140
140
|
}
|
|
141
141
|
]);
|
|
142
142
|
return fe(() => {
|
|
143
|
-
M(),
|
|
143
|
+
b.sdk.subCategory.search(""), M(), u.value.dispose();
|
|
144
144
|
}), (t, o) => {
|
|
145
|
-
const
|
|
146
|
-
return
|
|
145
|
+
const v = f("FmButton"), w = f("FmCircularProgress"), E = f("FmSearch"), I = f("FmTable"), X = f("FmTooltip"), Y = f("FmTextField"), be = f("FmSideSheet"), ge = f("FmDialog");
|
|
146
|
+
return r(), k(we, {
|
|
147
147
|
heading: e(a)("menu.subcategory.title")
|
|
148
148
|
}, {
|
|
149
|
-
"append-heading":
|
|
150
|
-
var
|
|
149
|
+
"append-heading": c(() => {
|
|
150
|
+
var D;
|
|
151
151
|
return [
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
value: e(P)(((
|
|
152
|
+
p("div", De, [
|
|
153
|
+
p("div", Te, [
|
|
154
|
+
d(xe, {
|
|
155
|
+
value: e(P)(((D = s.value) == null ? void 0 : D.totalCount) ?? 0)
|
|
156
156
|
}, null, 8, ["value"])
|
|
157
157
|
]),
|
|
158
|
-
s.value && s.value.totalCount > 0 ? (
|
|
158
|
+
s.value && s.value.totalCount > 0 ? (r(), k(v, {
|
|
159
159
|
key: 0,
|
|
160
160
|
disabled: s.value.create.state !== "allowed",
|
|
161
161
|
label: e(a)("menu.subcategory.add"),
|
|
@@ -165,34 +165,34 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
165
165
|
])
|
|
166
166
|
];
|
|
167
167
|
}),
|
|
168
|
-
default:
|
|
169
|
-
var
|
|
168
|
+
default: c(() => {
|
|
169
|
+
var D, Z, ee;
|
|
170
170
|
return [
|
|
171
|
-
e(
|
|
172
|
-
|
|
171
|
+
e(x).status === "error" ? (r(), g("p", Ne, h(e(S)(e(x).error.message)), 1)) : e(x).status === "unavailable" ? (r(), g("div", ze, [
|
|
172
|
+
d(e(ne), {
|
|
173
173
|
title: e(a)("menu.subcategory.empty.title"),
|
|
174
174
|
subtitle: e(a)("menu.subcategory.empty.subtitle")
|
|
175
175
|
}, null, 8, ["title", "subtitle"])
|
|
176
|
-
])) : e(
|
|
176
|
+
])) : e(x).status === "loading" ? (r(), k(w, { key: 2 })) : s.value && s.value.rows.length === 0 && !q.value ? (r(), k(e(ne), {
|
|
177
177
|
key: 3,
|
|
178
178
|
action: s.value.create.state === "allowed" ? { text: e(a)("menu.subcategory.add"), callback: G } : void 0,
|
|
179
179
|
subtitle: e(a)("menu.subcategory.empty.subtitle"),
|
|
180
180
|
title: e(a)("menu.subcategory.empty.title")
|
|
181
|
-
}, null, 8, ["action", "subtitle", "title"])) : s.value ? (
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
181
|
+
}, null, 8, ["action", "subtitle", "title"])) : s.value ? (r(), g($, { key: 4 }, [
|
|
182
|
+
p("div", Ee, [
|
|
183
|
+
p("div", Ie, [
|
|
184
|
+
d(E, {
|
|
185
185
|
autofocus: "",
|
|
186
186
|
class: "mb-8",
|
|
187
187
|
"model-value": q.value,
|
|
188
188
|
placeholder: e(a)("menu.common.labels.search_placeholder", {
|
|
189
189
|
type: e(a)("menu.subcategory.title")
|
|
190
190
|
}),
|
|
191
|
-
"onUpdate:modelValue":
|
|
191
|
+
"onUpdate:modelValue": b.sdk.subCategory.search
|
|
192
192
|
}, null, 8, ["model-value", "placeholder", "onUpdate:modelValue"])
|
|
193
193
|
])
|
|
194
194
|
]),
|
|
195
|
-
|
|
195
|
+
d(I, {
|
|
196
196
|
class: "subcategory-table",
|
|
197
197
|
"column-defs": ve.value,
|
|
198
198
|
draggable: me.value,
|
|
@@ -205,80 +205,86 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
205
205
|
onRowClick: o[0] || (o[0] = (n) => re(n.original))
|
|
206
206
|
}, null, 8, ["column-defs", "draggable", "page-size", "row-data"])
|
|
207
207
|
], 64)) : F("", !0),
|
|
208
|
-
((
|
|
208
|
+
((D = l.value) == null ? void 0 : D.mode) === "update" ? (r(), k(be, {
|
|
209
209
|
key: 5,
|
|
210
|
-
modelValue:
|
|
211
|
-
"onUpdate:modelValue": o[2] || (o[2] = (n) =>
|
|
210
|
+
modelValue: V.value,
|
|
211
|
+
"onUpdate:modelValue": o[2] || (o[2] = (n) => V.value = n),
|
|
212
212
|
"is-container": e(R).FmForm,
|
|
213
213
|
"is-container-props": { onValidationSuccess: W },
|
|
214
214
|
"max-width": 560,
|
|
215
215
|
"z-index": 100
|
|
216
216
|
}, {
|
|
217
|
-
"side-sheet-header":
|
|
217
|
+
"side-sheet-header": c(() => {
|
|
218
218
|
var n;
|
|
219
219
|
return [
|
|
220
|
-
|
|
220
|
+
p("p", je, h(((n = l.value) == null ? void 0 : n.mode) === "update" ? e(a)("menu.subcategory.title") : e(a)("menu.subcategory.manager.dialog.add.title")), 1)
|
|
221
221
|
];
|
|
222
222
|
}),
|
|
223
|
-
"side-sheet-footer":
|
|
223
|
+
"side-sheet-footer": c(() => {
|
|
224
224
|
var n, y;
|
|
225
225
|
return [
|
|
226
|
-
|
|
227
|
-
|
|
226
|
+
p("div", Re, [
|
|
227
|
+
d(v, {
|
|
228
228
|
disabled: ((n = l.value) == null ? void 0 : n.submit.state) !== "allowed",
|
|
229
229
|
label: ((y = l.value) == null ? void 0 : y.mode) === "update" ? e(a)("menu.subcategory.manager.dialog.update.action") : e(a)("menu.subcategory.manager.dialog.add.action"),
|
|
230
230
|
size: "lg",
|
|
231
231
|
type: "submit",
|
|
232
232
|
variant: "primary"
|
|
233
233
|
}, null, 8, ["disabled", "label"]),
|
|
234
|
-
|
|
234
|
+
d(v, {
|
|
235
235
|
label: e(a)("menu.common.actions.cancel"),
|
|
236
236
|
size: "lg",
|
|
237
237
|
variant: "tertiary",
|
|
238
|
-
onClick:
|
|
238
|
+
onClick: z
|
|
239
239
|
}, null, 8, ["label"])
|
|
240
240
|
])
|
|
241
241
|
];
|
|
242
242
|
}),
|
|
243
|
-
default:
|
|
244
|
-
var n, y,
|
|
243
|
+
default: c(() => {
|
|
244
|
+
var n, y, T;
|
|
245
245
|
return [
|
|
246
|
-
|
|
247
|
-
|
|
246
|
+
p("div", Be, [
|
|
247
|
+
d(Y, {
|
|
248
|
+
rules: [
|
|
249
|
+
(m) => {
|
|
250
|
+
const i = u.value.validateName(String(m ?? ""));
|
|
251
|
+
return i ? e(S)(i) : !0;
|
|
252
|
+
}
|
|
253
|
+
],
|
|
248
254
|
"helper-state": (n = l.value) != null && n.nameIssue ? "error" : "none",
|
|
249
|
-
"helper-text": (y = l.value) != null && y.nameIssue ? e(
|
|
255
|
+
"helper-text": (y = l.value) != null && y.nameIssue ? e(S)(l.value.nameIssue) : "",
|
|
250
256
|
label: e(a)("menu.subcategory.name"),
|
|
251
|
-
"model-value": ((
|
|
257
|
+
"model-value": ((T = l.value) == null ? void 0 : T.name) ?? "",
|
|
252
258
|
placeholder: e(a)("menu.subcategory.dialog.add.name.placeholder"),
|
|
253
|
-
"onUpdate:modelValue": o[1] || (o[1] = (
|
|
259
|
+
"onUpdate:modelValue": o[1] || (o[1] = (m) => u.value.setName(m))
|
|
254
260
|
}, {
|
|
255
|
-
append:
|
|
256
|
-
|
|
257
|
-
|
|
261
|
+
append: c(() => [
|
|
262
|
+
p("div", Me, [
|
|
263
|
+
d(X, {
|
|
258
264
|
variant: "plain",
|
|
259
265
|
placement: "top",
|
|
260
266
|
"z-index": 999
|
|
261
267
|
}, {
|
|
262
|
-
content:
|
|
263
|
-
var
|
|
268
|
+
content: c(() => {
|
|
269
|
+
var m, i;
|
|
264
270
|
return [
|
|
265
|
-
|
|
266
|
-
Object.keys(((
|
|
267
|
-
(
|
|
268
|
-
value:
|
|
269
|
-
locale: K(
|
|
271
|
+
p("div", Oe, [
|
|
272
|
+
Object.keys(((m = l.value) == null ? void 0 : m.nameLocale) ?? {}).length === 0 ? (r(), g("div", $e, h(e(a)("menu.common.translation.translation_label")), 1)) : F("", !0),
|
|
273
|
+
(r(!0), g($, null, oe((i = l.value) == null ? void 0 : i.nameLocale, (_, j) => (r(), g("div", { key: j }, h(e(a)("menu.subcategory.translation.tooltip_value", {
|
|
274
|
+
value: _,
|
|
275
|
+
locale: K(j)
|
|
270
276
|
})), 1))), 128))
|
|
271
277
|
])
|
|
272
278
|
];
|
|
273
279
|
}),
|
|
274
|
-
default:
|
|
275
|
-
var
|
|
280
|
+
default: c(() => {
|
|
281
|
+
var m;
|
|
276
282
|
return [
|
|
277
|
-
|
|
283
|
+
d(v, {
|
|
278
284
|
icon: "g_translate",
|
|
279
285
|
"aria-label": e(a)("menu.common.translation.translation_label"),
|
|
280
286
|
variant: "tertiary",
|
|
281
|
-
disabled: ((
|
|
287
|
+
disabled: ((m = l.value) == null ? void 0 : m.translation.state) !== "allowed",
|
|
282
288
|
onClick: H
|
|
283
289
|
}, null, 8, ["aria-label", "disabled"])
|
|
284
290
|
];
|
|
@@ -288,46 +294,46 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
288
294
|
])
|
|
289
295
|
]),
|
|
290
296
|
_: 1
|
|
291
|
-
}, 8, ["helper-state", "helper-text", "label", "model-value", "placeholder"])
|
|
297
|
+
}, 8, ["rules", "helper-state", "helper-text", "label", "model-value", "placeholder"])
|
|
292
298
|
])
|
|
293
299
|
];
|
|
294
300
|
}),
|
|
295
301
|
_: 1
|
|
296
302
|
}, 8, ["modelValue", "is-container", "is-container-props"])) : F("", !0),
|
|
297
|
-
((Z = l.value) == null ? void 0 : Z.mode) === "update" || ((ee = l.value) == null ? void 0 : ee.mode) === "create" ? (
|
|
303
|
+
((Z = l.value) == null ? void 0 : Z.mode) === "update" || ((ee = l.value) == null ? void 0 : ee.mode) === "create" ? (r(), k(Ce, {
|
|
298
304
|
key: 6,
|
|
299
|
-
"model-value":
|
|
305
|
+
"model-value": L.value,
|
|
300
306
|
"onUpdate:modelValue": o[3] || (o[3] = (n) => n || J()),
|
|
301
307
|
name: l.value.name,
|
|
302
308
|
"name-locale": l.value.nameLocale,
|
|
303
309
|
"supported-locales": l.value.supportedLocales,
|
|
304
310
|
dirty: l.value.translationDirty,
|
|
305
311
|
"z-index": 200,
|
|
306
|
-
"onUpdate:name":
|
|
307
|
-
"onUpdate:nameLocale":
|
|
312
|
+
"onUpdate:name": u.value.setName,
|
|
313
|
+
"onUpdate:nameLocale": u.value.setNameLocale,
|
|
308
314
|
onSave: ie,
|
|
309
315
|
onDiscard: J
|
|
310
316
|
}, null, 8, ["model-value", "name", "name-locale", "supported-locales", "dirty", "onUpdate:name", "onUpdate:nameLocale"])) : F("", !0),
|
|
311
|
-
|
|
312
|
-
modelValue:
|
|
313
|
-
"onUpdate:modelValue": o[5] || (o[5] = (n) =>
|
|
317
|
+
d(ge, {
|
|
318
|
+
modelValue: N.value,
|
|
319
|
+
"onUpdate:modelValue": o[5] || (o[5] = (n) => N.value = n),
|
|
314
320
|
"is-component": e(R).FmForm,
|
|
315
321
|
"is-component-props": { onValidationSuccess: W },
|
|
316
322
|
"max-width": 560
|
|
317
323
|
}, {
|
|
318
|
-
"dialog-header":
|
|
319
|
-
|
|
324
|
+
"dialog-header": c(() => [
|
|
325
|
+
p("p", Ae, h(e(a)("menu.subcategory.manager.dialog.add.title")), 1)
|
|
320
326
|
]),
|
|
321
|
-
"dialog-footer":
|
|
327
|
+
"dialog-footer": c(() => {
|
|
322
328
|
var n;
|
|
323
329
|
return [
|
|
324
|
-
|
|
325
|
-
|
|
330
|
+
p("div", Ke, [
|
|
331
|
+
d(v, {
|
|
326
332
|
label: e(a)("menu.common.actions.cancel"),
|
|
327
333
|
variant: "tertiary",
|
|
328
|
-
onClick:
|
|
334
|
+
onClick: z
|
|
329
335
|
}, null, 8, ["label"]),
|
|
330
|
-
|
|
336
|
+
d(v, {
|
|
331
337
|
disabled: ((n = l.value) == null ? void 0 : n.submit.state) !== "allowed",
|
|
332
338
|
label: e(a)("menu.subcategory.manager.dialog.add.action"),
|
|
333
339
|
type: "submit",
|
|
@@ -336,45 +342,51 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
336
342
|
])
|
|
337
343
|
];
|
|
338
344
|
}),
|
|
339
|
-
default:
|
|
340
|
-
var n, y,
|
|
345
|
+
default: c(() => {
|
|
346
|
+
var n, y, T, m;
|
|
341
347
|
return [
|
|
342
|
-
|
|
348
|
+
d(Y, {
|
|
343
349
|
autofocus: "",
|
|
344
350
|
invalid: !!((n = l.value) != null && n.nameIssue),
|
|
351
|
+
rules: [
|
|
352
|
+
(i) => {
|
|
353
|
+
const _ = u.value.validateName(String(i ?? ""));
|
|
354
|
+
return _ ? e(S)(_) : !0;
|
|
355
|
+
}
|
|
356
|
+
],
|
|
345
357
|
"helper-state": (y = l.value) != null && y.nameIssue ? "error" : "none",
|
|
346
|
-
"helper-text": (
|
|
358
|
+
"helper-text": (T = l.value) != null && T.nameIssue ? e(S)(l.value.nameIssue) : "",
|
|
347
359
|
label: e(a)("menu.subcategory.name"),
|
|
348
|
-
"model-value": ((
|
|
360
|
+
"model-value": ((m = l.value) == null ? void 0 : m.name) ?? "",
|
|
349
361
|
placeholder: e(a)("menu.subcategory.dialog.add.name.placeholder"),
|
|
350
|
-
"onUpdate:modelValue": o[4] || (o[4] = (
|
|
362
|
+
"onUpdate:modelValue": o[4] || (o[4] = (i) => u.value.setName(i))
|
|
351
363
|
}, {
|
|
352
|
-
append:
|
|
353
|
-
|
|
364
|
+
append: c(() => [
|
|
365
|
+
d(X, {
|
|
354
366
|
variant: "plain",
|
|
355
367
|
placement: "top",
|
|
356
368
|
"z-index": 999
|
|
357
369
|
}, {
|
|
358
|
-
content:
|
|
359
|
-
var
|
|
370
|
+
content: c(() => {
|
|
371
|
+
var i, _;
|
|
360
372
|
return [
|
|
361
|
-
|
|
362
|
-
Object.keys(((
|
|
363
|
-
(
|
|
364
|
-
value:
|
|
373
|
+
p("div", Pe, [
|
|
374
|
+
Object.keys(((i = l.value) == null ? void 0 : i.nameLocale) ?? {}).length === 0 ? (r(), g("div", qe, h(e(a)("menu.common.translation.translation_label")), 1)) : F("", !0),
|
|
375
|
+
(r(!0), g($, null, oe((_ = l.value) == null ? void 0 : _.nameLocale, (j, ae) => (r(), g("div", { key: ae }, h(e(a)("menu.subcategory.translation.tooltip_value", {
|
|
376
|
+
value: j,
|
|
365
377
|
locale: K(ae)
|
|
366
378
|
})), 1))), 128))
|
|
367
379
|
])
|
|
368
380
|
];
|
|
369
381
|
}),
|
|
370
|
-
default:
|
|
371
|
-
var
|
|
382
|
+
default: c(() => {
|
|
383
|
+
var i;
|
|
372
384
|
return [
|
|
373
|
-
|
|
385
|
+
d(v, {
|
|
374
386
|
icon: "g_translate",
|
|
375
387
|
"aria-label": e(a)("menu.common.translation.translation_label"),
|
|
376
388
|
variant: "tertiary",
|
|
377
|
-
disabled: ((
|
|
389
|
+
disabled: ((i = l.value) == null ? void 0 : i.translation.state) !== "allowed",
|
|
378
390
|
onClick: H
|
|
379
391
|
}, null, 8, ["aria-label", "disabled"])
|
|
380
392
|
];
|
|
@@ -383,7 +395,7 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
383
395
|
})
|
|
384
396
|
]),
|
|
385
397
|
_: 1
|
|
386
|
-
}, 8, ["invalid", "helper-state", "helper-text", "label", "model-value", "placeholder"])
|
|
398
|
+
}, 8, ["invalid", "rules", "helper-state", "helper-text", "label", "model-value", "placeholder"])
|
|
387
399
|
];
|
|
388
400
|
}),
|
|
389
401
|
_: 1
|
|
@@ -394,11 +406,11 @@ const De = { class: "flex-1 flex justify-between gap-8 pl-8" }, Te = { class: "f
|
|
|
394
406
|
}, 8, ["heading"]);
|
|
395
407
|
};
|
|
396
408
|
}
|
|
397
|
-
}), Ge = /* @__PURE__ */ Ue(Qe, [["__scopeId", "data-v-
|
|
409
|
+
}), Ge = /* @__PURE__ */ Ue(Qe, [["__scopeId", "data-v-f7188357"]]), oa = /* @__PURE__ */ se({
|
|
398
410
|
__name: "Subcategory",
|
|
399
411
|
setup(A) {
|
|
400
|
-
const
|
|
401
|
-
return (a, P) => (
|
|
412
|
+
const b = Le();
|
|
413
|
+
return (a, P) => (r(), k(Ge, { sdk: e(b) }, null, 8, ["sdk"]));
|
|
402
414
|
}
|
|
403
415
|
});
|
|
404
416
|
export {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defineComponent as m, resolveComponent as i, openBlock as s, createBlock as c, unref as a, withCtx as t, createVNode as e } from "vue";
|
|
2
2
|
import { RouterLink as p } from "vue-router";
|
|
3
3
|
import { useI18n as _ } from "@feedmepos/mf-common";
|
|
4
|
-
import { _ as l } from "./TakeawayList.vue_vue_type_script_setup_true_lang-
|
|
5
|
-
import { _ as d } from "./CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-
|
|
6
|
-
import { R as u } from "./app-
|
|
7
|
-
import { a as f } from "./provide-
|
|
8
|
-
import { _ as k } from "./CatalogEditTabs.vue_vue_type_script_setup_true_lang-
|
|
4
|
+
import { _ as l } from "./TakeawayList.vue_vue_type_script_setup_true_lang-HZP5jmAy.js";
|
|
5
|
+
import { _ as d } from "./CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-DJLjbLGK.js";
|
|
6
|
+
import { R as u } from "./app-DnIyFwTs.js";
|
|
7
|
+
import { a as f } from "./provide-UZbVvMqZ.js";
|
|
8
|
+
import { _ as k } from "./CatalogEditTabs.vue_vue_type_script_setup_true_lang-CFjBkgkl.js";
|
|
9
9
|
const A = /* @__PURE__ */ m({
|
|
10
10
|
__name: "Takeaway",
|
|
11
11
|
setup(g) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as o, openBlock as n, createBlock as r, unref as a } from "vue";
|
|
2
|
-
import { _ as s } from "./TakeawayList.vue_vue_type_script_setup_true_lang-
|
|
3
|
-
import { a as t } from "./provide-
|
|
2
|
+
import { _ as s } from "./TakeawayList.vue_vue_type_script_setup_true_lang-HZP5jmAy.js";
|
|
3
|
+
import { a as t } from "./provide-UZbVvMqZ.js";
|
|
4
4
|
const k = /* @__PURE__ */ o({
|
|
5
5
|
__name: "Takeaway",
|
|
6
6
|
setup(_) {
|