@feedmepos/mf-menu 0.32.17 → 0.32.18-dev.1
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-Cfl37TTw.js +152661 -0
- package/dist/{Catalog-ChlP8Cid.js → Catalog-Yxsb-D33.js} +47 -52
- package/dist/{Category-CHs96ibF.js → Category-0vJH8Ct0.js} +86 -92
- package/dist/{Category-B1tAJpNd.js → Category-qp0wI14I.js} +25 -26
- package/dist/{CookingGuide-mEvca-0v.js → CookingGuide-EpAr5F5U.js} +139 -143
- package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-Bk26jQI7.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-CkyD0sdI.js} +14 -16
- package/dist/{Group-Ye2IIY52.js → Group-B3W9iSbO.js} +5 -5
- package/dist/{Group-Co2Vf4Lw.js → Group-DLCh0fDU.js} +1 -1
- package/dist/{Group.vue_vue_type_script_setup_true_lang-BcxSbvJS.js → Group.vue_vue_type_script_setup_true_lang-Bzy_hXDv.js} +176 -186
- package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-D1f8VG-n.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-BFaAXp7r.js} +81 -88
- package/dist/{ImportProductDialog.vue_vue_type_script_setup_true_lang-Jv6iJlg9.js → ImportProductDialog.vue_vue_type_script_setup_true_lang-CxP8lDD0.js} +2502 -2508
- package/dist/{Ingredient-BgnW8sWo.js → Ingredient-CVLMr_YB.js} +102 -105
- package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-8ziHcUiK.js → InventoryBinding.vue_vue_type_script_setup_true_lang-CdTC5ykI.js} +1058 -1059
- package/dist/{MenuSetting-GEngjeC8.js → MenuSetting-Blpi1vSd.js} +58 -61
- package/dist/{PrintRoute-BSlUQT7g.js → PrintRoute-BS7PPPkE.js} +49 -52
- package/dist/{Product-DNg_BUuV.js → Product-DDeNKQ7u.js} +1 -1
- package/dist/{Product.vue_vue_type_script_setup_true_lang-Cehy2oy-.js → Product.vue_vue_type_script_setup_true_lang-rmv8m4_D.js} +286 -298
- package/dist/{ProductInternalTools-B5A67yxH.js → ProductInternalTools-CVuothk9.js} +45 -46
- package/dist/{Products-DCsxmTPB.js → Products-BIvsHKEt.js} +111 -116
- package/dist/{Publish-Cst0Ll6T.js → Publish-CDADU3Pp.js} +154 -159
- package/dist/{Recipe-DupS3SQT.js → Recipe-CMhW7e_z.js} +40 -43
- package/dist/{Scheduler-BcThU1M6.js → Scheduler-BpxunKBV.js} +7 -7
- package/dist/{ServingSequence-CT3THBH6.js → ServingSequence-BQVuYyAB.js} +54 -58
- package/dist/{Setting-Dxh8E3no.js → Setting-Dj0yyP37.js} +63 -66
- package/dist/{Subcategory-DhJEzofz.js → Subcategory-BH4DDZM4.js} +72 -76
- package/dist/{Takeaway-DSC7U4Jk.js → Takeaway-CGJBZ_sJ.js} +1 -1
- package/dist/{Takeaway-B8BSSKNj.js → Takeaway-DifOudVE.js} +20 -21
- package/dist/{Takeaway.vue_vue_type_script_setup_true_lang-BLpiJlk2.js → Takeaway.vue_vue_type_script_setup_true_lang-D-R5_S5G.js} +59 -64
- package/dist/{Unit-joU7vZZu.js → Unit-DXDox2Ut.js} +8 -8
- package/dist/{Variant-D8YjRJ6N.js → Variant-DbJVwgm5.js} +75 -78
- package/dist/{_id_-Bd9uo1WW.js → _id_-RFYwWjbM.js} +34 -38
- package/dist/{app-BNrAos5Z.js → app-Z0KWH9-d.js} +74 -335
- package/dist/app.js +4 -5
- package/dist/apps/mf-menu/src/app.d.ts +1 -2
- package/dist/apps/mf-menu/src/helper/import-export-utils.d.ts +1 -0
- package/dist/apps/mf-menu/tsconfig.app.tsbuildinfo +1 -1
- package/dist/assets/{linked-status-DbjzbFTw.js → linked-status-CkmoJAm-.js} +2 -2
- package/dist/assets/{menu-export-D_oNY_wi.js → menu-export-DcINiK28.js} +3 -3
- package/dist/assets/{override-menu-CIU7U1_4.js → override-menu-PUKiu-df.js} +2 -2
- package/dist/assets/{validate-menu-kuOxuwG9.js → validate-menu-CcqiRhNT.js} +2 -2
- package/dist/{catalogSetting-BHgsBDTl.js → catalogSetting-Bf66H-j7.js} +1 -1
- package/dist/dayjs.min-DNPTnUFp.js +6 -0
- package/dist/{jszip.min-7SsHzD5O.js → jszip.min-CO2_Gf69.js} +545 -545
- package/dist/{menu-Cd4NbFVq.js → menu-Brxar171.js} +1 -1
- package/dist/mf-menu.css +1 -1
- package/dist/{scheduler-B6OokVIA.js → scheduler-CqdIiE8G.js} +56 -60
- package/dist/{toExcel-BZkbXlHv.js → toExcel-CRJIU0NC.js} +2 -2
- package/dist/{unit-D6QOkMoM.js → unit-wYPYkm33.js} +98 -105
- package/package.json +1 -1
- package/dist/App-BiSEuDkd.js +0 -13484
- package/dist/ApplyProduct.vue_vue_type_script_setup_true_lang-C_SjdLpO.js +0 -161
- package/dist/FormItem.vue_vue_type_script_setup_true_lang-BmPAVphe.js +0 -26
- package/dist/LinkProductSideSheet-DFDYEUBh.js +0 -687
- package/dist/MenuSelector.vue_vue_type_script_setup_true_lang-K6Z0QJBl.js +0 -69
- package/dist/RuleView.vue_vue_type_script_setup_true_lang-BeesK2ym.js +0 -3285
- package/dist/TextChip.vue_vue_type_script_setup_true_lang-8frWuZFL.js +0 -20
- package/dist/Thumbnail.vue_vue_type_script_setup_true_lang-C3qXnZlz.js +0 -399
- package/dist/TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CMe76XvZ.js +0 -6011
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
- package/dist/app-5fxKLAzS.js +0 -8163
- package/dist/app-nTzkERJW.js +0 -68
- package/dist/catalog-BO2nXwe5.js +0 -199
- package/dist/category-CuG3DsGL.js +0 -156
- package/dist/check-C9mY6LiX.js +0 -9
- package/dist/createComponentProgrammatically-Bt2rn1IQ.js +0 -11
- package/dist/currency-DxC5zyZB.js +0 -7
- package/dist/dayjs.min-BvFUSPWD.js +0 -6
- package/dist/discardConfirm-BHni0LNu.js +0 -28
- package/dist/index-B0nhvuxR.js +0 -273
- package/dist/index-C2zPvt64.js +0 -239
- package/dist/index-C36JQix-.js +0 -246
- package/dist/index-CisutoS9.js +0 -156
- package/dist/index.vue_vue_type_script_setup_true_lang-DCBYExNb.js +0 -109064
- package/dist/item-K01xd1Z0.js +0 -6868
- package/dist/menuV2-DKE-xanq.js +0 -1052
- package/dist/object-DVUNCr7w.js +0 -16
- package/dist/priceTier-Beavb91W.js +0 -87
- package/dist/search-BAPEUu1R.js +0 -15
- package/dist/string-DpfFixWH.js +0 -4
- package/dist/subcategory-DnslmmRD.js +0 -148
- package/dist/tooltip-B5BiPMx9.js +0 -32
- package/dist/vuedraggable-CK8z7qA8.js +0 -1728
|
@@ -1,26 +1,14 @@
|
|
|
1
|
-
import { ref as F, computed as h, defineComponent as
|
|
2
|
-
import { u as Fe,
|
|
3
|
-
import { useI18n as Ie, useCoreStore as ze, useCustomAttributes as
|
|
4
|
-
import { u as Se } from "./menu-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { _ as
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
import { useBreakpoints as rt, components as te, useDialog as Tt, FmButtonColorThemeVariant as q, FmButtonVariant as ee } from "@feedmepos/ui-library";
|
|
13
|
-
import { F as Pt } from "./index-CisutoS9.js";
|
|
14
|
-
import { _ as De, a as At } from "./app-BNrAos5Z.js";
|
|
15
|
-
import { _ as ke } from "./TextChip.vue_vue_type_script_setup_true_lang-8frWuZFL.js";
|
|
16
|
-
import { _ as Rt } from "./index-B0nhvuxR.js";
|
|
17
|
-
import { r as Mt, _ as Ut } from "./ImportProductDialog.vue_vue_type_script_setup_true_lang-Jv6iJlg9.js";
|
|
18
|
-
import { c as zt } from "./check-C9mY6LiX.js";
|
|
19
|
-
import { f as Dt } from "./currency-DxC5zyZB.js";
|
|
20
|
-
import { w as Ot } from "./tooltip-B5BiPMx9.js";
|
|
21
|
-
function Bt(C, e, i = C) {
|
|
22
|
-
const n = F(!0), t = h(() => {
|
|
23
|
-
if (!n.value && !e.value)
|
|
1
|
+
import { ref as F, computed as h, defineComponent as j, resolveComponent as O, createBlock as I, openBlock as m, withCtx as T, createElementVNode as g, createVNode as d, unref as a, createElementBlock as k, Fragment as pe, renderList as we, createCommentVNode as M, normalizeClass as ve, toDisplayString as N, withModifiers as fe, mergeModels as Je, useModel as Xe, renderSlot as _e, watch as de, createTextVNode as et, watchEffect as tt, nextTick as Ae, resolveDynamicComponent as lt, onMounted as at, h as q, isRef as Be, normalizeStyle as ft } from "vue";
|
|
2
|
+
import { u as Fe, a0 as Ce, ac as ke, i as me, ad as gt, c as Re, ae as bt, af as _t, ag as Me, k as ot, n as ge, ah as yt, ai as ht, aj as xt, ak as Ct, al as kt, am as wt, an as Pe, ao as St, ap as Vt, aq as Ft, a1 as It, $ as Ee, ar as $t, _ as be, b as Tt, as as Pt, at as Ge, o as At, au as Le, L as qe, av as Rt } from "./App-Cfl37TTw.js";
|
|
3
|
+
import { useI18n as Ie, useCoreStore as ze, useCustomAttributes as Mt } from "@feedmepos/mf-common";
|
|
4
|
+
import { u as Se } from "./menu-Brxar171.js";
|
|
5
|
+
import { _ as Ue, a as We } from "./CustomAttributeChip.vue_vue_type_script_setup_true_lang-CkyD0sdI.js";
|
|
6
|
+
import { useBreakpoints as nt, components as te, useDialog as Ut, FmButtonColorThemeVariant as W, FmButtonVariant as ee } from "@feedmepos/ui-library";
|
|
7
|
+
import { _ as De, u as zt } from "./app-Z0KWH9-d.js";
|
|
8
|
+
import { r as Dt, _ as Ot } from "./ImportProductDialog.vue_vue_type_script_setup_true_lang-CxP8lDD0.js";
|
|
9
|
+
function Kt(C, e, i = C) {
|
|
10
|
+
const r = F(!0), t = h(() => {
|
|
11
|
+
if (!r.value && !e.value)
|
|
24
12
|
return !0;
|
|
25
13
|
if (e.value && e.value.length > 0) {
|
|
26
14
|
const f = i.value.map((s) => s.value);
|
|
@@ -31,66 +19,66 @@ function Bt(C, e, i = C) {
|
|
|
31
19
|
var f, s, b, y;
|
|
32
20
|
return !!((f = e.value) != null && f.length && ((s = e.value) == null ? void 0 : s.length) > 0 && ((b = e.value) == null ? void 0 : b.length) < ((y = C.value) == null ? void 0 : y.length));
|
|
33
21
|
});
|
|
34
|
-
return { allCleared:
|
|
22
|
+
return { allCleared: r, allSelected: t, indeterminate: u, toggleAll: () => {
|
|
35
23
|
if (t.value) {
|
|
36
|
-
e.value = void 0,
|
|
24
|
+
e.value = void 0, r.value = !0;
|
|
37
25
|
return;
|
|
38
26
|
}
|
|
39
27
|
const f = i.value.map((s) => s.value);
|
|
40
|
-
f.length === C.value.length ? (e.value = void 0,
|
|
28
|
+
f.length === C.value.length ? (e.value = void 0, r.value = !1) : (e.value = f, r.value = !1);
|
|
41
29
|
}, toggleOption: (f) => {
|
|
42
30
|
var b, y, w;
|
|
43
31
|
let s;
|
|
44
|
-
e.value === void 0 &&
|
|
32
|
+
e.value === void 0 && r.value ? s = [f] : e.value === void 0 && !r.value ? s = (b = C.value.map((z) => z.value)) == null ? void 0 : b.filter((z) => z !== f) : (y = e.value) != null && y.includes(f) ? s = (w = e.value) == null ? void 0 : w.filter((z) => z !== f) : s = [...e.value || [], f], s.length === 0 ? (e.value = void 0, r.value = !0) : s.length === C.value.length ? (e.value = void 0, r.value = !1) : e.value = s;
|
|
45
33
|
} };
|
|
46
34
|
}
|
|
47
|
-
const
|
|
35
|
+
const Nt = { class: "inline-flex items-center" }, jt = {
|
|
48
36
|
key: 0,
|
|
49
37
|
class: /* @__PURE__ */ ve([
|
|
50
38
|
"fm-typo-en-body-md-600 select-none text-ellipsis overflow-hidden whitespace-nowrap",
|
|
51
39
|
"text-fm-color-neutral-gray-400"
|
|
52
40
|
])
|
|
53
|
-
},
|
|
41
|
+
}, Bt = { class: "p-4" }, Et = { class: "flex-1 overflow-y-auto min-h-0" }, He = /* @__PURE__ */ j({
|
|
54
42
|
__name: "CategorySelector",
|
|
55
43
|
emits: ["toggleAttributeFilter"],
|
|
56
44
|
setup(C, { emit: e }) {
|
|
57
|
-
const i = e,
|
|
58
|
-
() => t.value.map((
|
|
45
|
+
const i = e, r = Fe(), { categories: t, selectedCategories: u } = Se(), l = h(() => r.state.currentCategoryIds), v = h(
|
|
46
|
+
() => t.value.map((K) => ({ label: K.name, value: K.id }))
|
|
59
47
|
), f = h(() => v.value.filter(
|
|
60
|
-
(
|
|
48
|
+
(K) => K.label.toLowerCase().includes(y.value.toLowerCase())
|
|
61
49
|
)), { t: s } = Ie(), b = h(() => {
|
|
62
|
-
var
|
|
63
|
-
return t.value.length === ((
|
|
50
|
+
var K, D, H;
|
|
51
|
+
return t.value.length === ((K = u.value) == null ? void 0 : K.length) ? s("menu.category.selector.all") : ((D = u.value) == null ? void 0 : D.length) === 1 ? u.value[0].name : `${(H = u.value) == null ? void 0 : H.length}`;
|
|
64
52
|
}), y = F(""), w = h({
|
|
65
53
|
get: () => l.value,
|
|
66
|
-
set: (
|
|
67
|
-
|
|
54
|
+
set: (K) => {
|
|
55
|
+
r.selectCategory(K);
|
|
68
56
|
}
|
|
69
|
-
}), { allSelected: z, toggleAll: Y, toggleOption: S, indeterminate: oe } =
|
|
57
|
+
}), { allSelected: z, toggleAll: Y, toggleOption: S, indeterminate: oe } = Kt(
|
|
70
58
|
v,
|
|
71
59
|
w,
|
|
72
60
|
f
|
|
73
|
-
),
|
|
61
|
+
), Z = ze(), ne = h(() => Z.itemAttributeSettings.value.length > 0);
|
|
74
62
|
function G() {
|
|
75
63
|
i("toggleAttributeFilter");
|
|
76
64
|
}
|
|
77
|
-
return (
|
|
78
|
-
const H = O("FmIcon"),
|
|
65
|
+
return (K, D) => {
|
|
66
|
+
const H = O("FmIcon"), J = O("FmChip"), re = O("FmSearch"), Q = O("FmMenuItem"), se = O("FmMenu");
|
|
79
67
|
return m(), I(se, {
|
|
80
68
|
"close-on-click": !1,
|
|
81
69
|
width: 220
|
|
82
70
|
}, {
|
|
83
71
|
"menu-button": T(() => [
|
|
84
|
-
g("div",
|
|
85
|
-
d(
|
|
72
|
+
g("div", Nt, [
|
|
73
|
+
d(J, null, {
|
|
86
74
|
default: T(() => [
|
|
87
|
-
b.value ? (m(), k("div",
|
|
75
|
+
b.value ? (m(), k("div", jt, N(a(s)("menu.category.selector.title", { label: b.value })), 1)) : M("", !0),
|
|
88
76
|
d(H, {
|
|
89
77
|
color: "neutral-gray-400",
|
|
90
78
|
name: "expand_more",
|
|
91
79
|
size: "sm"
|
|
92
80
|
}),
|
|
93
|
-
|
|
81
|
+
ne.value ? (m(), k("div", {
|
|
94
82
|
key: 1,
|
|
95
83
|
class: "pl-8 flex items-center justify-center border-l border-fm-color-neutral-gray-200",
|
|
96
84
|
onClick: fe(G, ["stop"])
|
|
@@ -110,8 +98,8 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
110
98
|
])
|
|
111
99
|
]),
|
|
112
100
|
default: T(() => [
|
|
113
|
-
g("div",
|
|
114
|
-
d(
|
|
101
|
+
g("div", Bt, [
|
|
102
|
+
d(re, {
|
|
115
103
|
autofocus: "",
|
|
116
104
|
modelValue: y.value,
|
|
117
105
|
"onUpdate:modelValue": D[1] || (D[1] = (R) => y.value = R),
|
|
@@ -142,20 +130,20 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
142
130
|
});
|
|
143
131
|
};
|
|
144
132
|
}
|
|
145
|
-
}), Gt = { class: "flex flex-wrap gap-8" }, Lt = { class: "py-12 px-16 space-y-12" },
|
|
133
|
+
}), Gt = { class: "flex flex-wrap gap-8" }, Lt = { class: "py-12 px-16 space-y-12" }, qt = { class: "fm-typo-en-body-md-600 text-fm-color-neutral-gray-600" }, Wt = { class: "flex flex-wrap gap-8" }, Ht = {
|
|
146
134
|
key: 0,
|
|
147
135
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
148
136
|
}, Qt = { key: 0 }, Yt = {
|
|
149
137
|
key: 1,
|
|
150
138
|
class: "inline-block w-8"
|
|
151
|
-
},
|
|
139
|
+
}, Zt = { key: 0 }, Jt = { key: 1 }, Qe = /* @__PURE__ */ j({
|
|
152
140
|
__name: "CategoriesChip",
|
|
153
141
|
props: {
|
|
154
142
|
categories: { default: () => [] },
|
|
155
143
|
ellipsis: { type: Boolean, default: !0 }
|
|
156
144
|
},
|
|
157
145
|
setup(C) {
|
|
158
|
-
const e = C, { t: i } = Ie(),
|
|
146
|
+
const e = C, { t: i } = Ie(), r = nt(), t = h(() => r.breakpoints.value.xs), u = h(() => e.ellipsis ? t.value ? 1 : 2 : 1 / 0), l = h(() => e.categories.length <= u.value ? e.categories : e.categories.slice(0, u.value)), v = F(!0), f = h(() => {
|
|
159
147
|
if (v.value) {
|
|
160
148
|
const b = l.value.join(", ");
|
|
161
149
|
return b.length > 20 ? b.slice(0, 20) + "..." : b;
|
|
@@ -166,15 +154,15 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
166
154
|
const y = O("FmTooltip");
|
|
167
155
|
return t.value ? (m(), k(pe, { key: 1 }, [
|
|
168
156
|
s.categories.length > 0 ? (m(), k("p", Ht, [
|
|
169
|
-
g("span", null,
|
|
170
|
-
g("span", null,
|
|
157
|
+
g("span", null, N(a(i)("menu.product.table.columns.category")) + ": ", 1),
|
|
158
|
+
g("span", null, N(f.value), 1),
|
|
171
159
|
v.value ? (m(), k("span", Yt)) : (m(), k("br", Qt)),
|
|
172
160
|
s.categories.length > u.value ? (m(), k("span", {
|
|
173
161
|
key: 2,
|
|
174
162
|
class: "fm-typo-en-body-md-400 text-fm-color-primary cursor-pointer",
|
|
175
163
|
onClick: b[0] || (b[0] = fe((w) => v.value = !v.value, ["stop", "prevent"]))
|
|
176
164
|
}, [
|
|
177
|
-
v.value ? (m(), k("span",
|
|
165
|
+
v.value ? (m(), k("span", Zt, N(a(i)("menu.product.table.category.expand", { count: s.categories.length - u.value })), 1)) : (m(), k("span", Jt, N(a(i)("menu.product.table.category.collapse")), 1))
|
|
178
166
|
])) : M("", !0)
|
|
179
167
|
])) : M("", !0)
|
|
180
168
|
], 64)) : (m(), I(y, {
|
|
@@ -186,9 +174,9 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
186
174
|
}, {
|
|
187
175
|
content: T(() => [
|
|
188
176
|
g("div", Lt, [
|
|
189
|
-
g("p",
|
|
190
|
-
g("div",
|
|
191
|
-
(m(!0), k(pe, null, we(e.categories, (w) => (m(), I(
|
|
177
|
+
g("p", qt, N(a(i)("menu.product.table.category.all")), 1),
|
|
178
|
+
g("div", Wt, [
|
|
179
|
+
(m(!0), k(pe, null, we(e.categories, (w) => (m(), I(Ce, {
|
|
192
180
|
key: w,
|
|
193
181
|
label: w,
|
|
194
182
|
variant: "neutral"
|
|
@@ -198,12 +186,12 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
198
186
|
]),
|
|
199
187
|
default: T(() => [
|
|
200
188
|
g("div", Gt, [
|
|
201
|
-
(m(!0), k(pe, null, we(l.value, (w) => (m(), I(
|
|
189
|
+
(m(!0), k(pe, null, we(l.value, (w) => (m(), I(Ce, {
|
|
202
190
|
key: w,
|
|
203
191
|
label: w,
|
|
204
192
|
variant: "neutral"
|
|
205
193
|
}, null, 8, ["label"]))), 128)),
|
|
206
|
-
s.categories.length > u.value ? (m(), I(
|
|
194
|
+
s.categories.length > u.value ? (m(), I(Ce, {
|
|
207
195
|
key: 0,
|
|
208
196
|
label: "...",
|
|
209
197
|
variant: "neutral"
|
|
@@ -214,9 +202,9 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
214
202
|
}));
|
|
215
203
|
};
|
|
216
204
|
}
|
|
217
|
-
}), Xt = /* @__PURE__ */
|
|
205
|
+
}), Xt = /* @__PURE__ */ j({
|
|
218
206
|
__name: "ProductSearcher",
|
|
219
|
-
props: /* @__PURE__ */
|
|
207
|
+
props: /* @__PURE__ */ Je({
|
|
220
208
|
label: {},
|
|
221
209
|
helperText: {},
|
|
222
210
|
menu: {}
|
|
@@ -226,7 +214,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
226
214
|
}),
|
|
227
215
|
emits: ["update:modelValue"],
|
|
228
216
|
setup(C) {
|
|
229
|
-
const e = C, i = Xe(C, "modelValue"),
|
|
217
|
+
const e = C, i = Xe(C, "modelValue"), r = h(() => e.menu.modules.item.map((t) => ({
|
|
230
218
|
label: t.code ? `${t.code} ${t.name}` : t.name,
|
|
231
219
|
value: t._id
|
|
232
220
|
})));
|
|
@@ -235,7 +223,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
235
223
|
return m(), I(l, {
|
|
236
224
|
modelValue: i.value,
|
|
237
225
|
"onUpdate:modelValue": u[0] || (u[0] = (v) => i.value = v),
|
|
238
|
-
items:
|
|
226
|
+
items: r.value,
|
|
239
227
|
searchable: !0,
|
|
240
228
|
"search-target": "label",
|
|
241
229
|
placeholder: "Search by product name or code",
|
|
@@ -247,9 +235,9 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
247
235
|
}), el = { class: "flex" }, tl = { class: "w-[260px] space-y-16 h-full" }, ll = { class: "flex items-center gap-4 px-8" }, al = { class: "fm-typo-en-title-sm-600" }, ol = {
|
|
248
236
|
key: 0,
|
|
249
237
|
class: "bg-fm-color-neutral-gray-100 rounded-md px-8 py-4"
|
|
250
|
-
},
|
|
238
|
+
}, nl = { class: "fm-typo-en-body-md-600" }, rl = { class: "flex-1" }, rt = /* @__PURE__ */ j({
|
|
251
239
|
__name: "ViewLayout",
|
|
252
|
-
props: /* @__PURE__ */
|
|
240
|
+
props: /* @__PURE__ */ Je({
|
|
253
241
|
title: {},
|
|
254
242
|
titleBadge: {},
|
|
255
243
|
items: {}
|
|
@@ -260,50 +248,50 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
260
248
|
emits: ["update:modelValue"],
|
|
261
249
|
setup(C) {
|
|
262
250
|
const e = Xe(C, "modelValue");
|
|
263
|
-
return (i,
|
|
251
|
+
return (i, r) => {
|
|
264
252
|
const t = O("FmCollapsibleTabs");
|
|
265
253
|
return m(), k("div", el, [
|
|
266
254
|
g("div", tl, [
|
|
267
255
|
g("div", ll, [
|
|
268
|
-
g("p", al,
|
|
256
|
+
g("p", al, N(i.title), 1),
|
|
269
257
|
i.titleBadge !== void 0 ? (m(), k("div", ol, [
|
|
270
|
-
g("p",
|
|
258
|
+
g("p", nl, N(i.titleBadge), 1)
|
|
271
259
|
])) : M("", !0)
|
|
272
260
|
]),
|
|
273
261
|
d(De, null, {
|
|
274
262
|
default: T(() => [
|
|
275
263
|
d(t, {
|
|
276
264
|
modelValue: e.value,
|
|
277
|
-
"onUpdate:modelValue":
|
|
265
|
+
"onUpdate:modelValue": r[0] || (r[0] = (u) => e.value = u),
|
|
278
266
|
items: i.items
|
|
279
267
|
}, null, 8, ["modelValue", "items"])
|
|
280
268
|
]),
|
|
281
269
|
_: 1
|
|
282
270
|
})
|
|
283
271
|
]),
|
|
284
|
-
|
|
285
|
-
g("div",
|
|
272
|
+
r[1] || (r[1] = g("div", { class: "w-[1px] min-h-full ml-4 mr-12 bg-fm-color-neutral-gray-100 self-stretch" }, null, -1)),
|
|
273
|
+
g("div", rl, [
|
|
286
274
|
_e(i.$slots, "default")
|
|
287
275
|
])
|
|
288
276
|
]);
|
|
289
277
|
};
|
|
290
278
|
}
|
|
291
|
-
}), Ve = /* @__PURE__ */
|
|
279
|
+
}), Ve = /* @__PURE__ */ j({
|
|
292
280
|
__name: "OrderFromChip",
|
|
293
281
|
props: {
|
|
294
282
|
orderFrom: {}
|
|
295
283
|
},
|
|
296
284
|
setup(C) {
|
|
297
|
-
const e = C, i =
|
|
298
|
-
return (
|
|
285
|
+
const e = C, i = ke();
|
|
286
|
+
return (r, t) => {
|
|
299
287
|
var u, l;
|
|
300
|
-
return m(), I(
|
|
288
|
+
return m(), I(Ce, {
|
|
301
289
|
label: ((u = a(i)[e.orderFrom]) == null ? void 0 : u.label) || e.orderFrom,
|
|
302
290
|
variant: (l = a(i)[e.orderFrom]) == null ? void 0 : l.variant
|
|
303
291
|
}, null, 8, ["label", "variant"]);
|
|
304
292
|
};
|
|
305
293
|
}
|
|
306
|
-
}), sl = /* @__PURE__ */
|
|
294
|
+
}), sl = /* @__PURE__ */ j({
|
|
307
295
|
__name: "GroupViewTable",
|
|
308
296
|
props: {
|
|
309
297
|
data: {}
|
|
@@ -363,9 +351,9 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
363
351
|
meta: {
|
|
364
352
|
colspan: (l) => l.original.subRows ? 0 : 1
|
|
365
353
|
}
|
|
366
|
-
}],
|
|
354
|
+
}], r = F({}), t = (l) => l.subRows;
|
|
367
355
|
function u() {
|
|
368
|
-
|
|
356
|
+
r.value = Object.fromEntries(e.data.map((l, v) => [v, !0]));
|
|
369
357
|
}
|
|
370
358
|
return de(() => e.data, () => {
|
|
371
359
|
u();
|
|
@@ -378,22 +366,22 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
378
366
|
"hide-footer": !0,
|
|
379
367
|
"page-size": 1e6,
|
|
380
368
|
"get-sub-row": t,
|
|
381
|
-
"expanded-state":
|
|
369
|
+
"expanded-state": r.value,
|
|
382
370
|
"shrink-at": !1,
|
|
383
|
-
"onUpdate:expandedState": v[0] || (v[0] = (s) =>
|
|
371
|
+
"onUpdate:expandedState": v[0] || (v[0] = (s) => r.value = s)
|
|
384
372
|
}, null, 8, ["row-data", "expanded-state"])]),
|
|
385
373
|
_: 1
|
|
386
374
|
});
|
|
387
375
|
};
|
|
388
376
|
}
|
|
389
|
-
}), ul = /* @__PURE__ */
|
|
377
|
+
}), ul = /* @__PURE__ */ j({
|
|
390
378
|
__name: "GroupView",
|
|
391
379
|
props: {
|
|
392
380
|
itemId: {},
|
|
393
381
|
menu: {}
|
|
394
382
|
},
|
|
395
383
|
setup(C) {
|
|
396
|
-
const e = C, i = F(""),
|
|
384
|
+
const e = C, i = F(""), r = h(() => t.value.reduce((s, b) => s + (typeof b.badge == "number" ? b.badge ?? 1 : 0), 0)), t = F([]), u = h(() => {
|
|
397
385
|
const s = t.value.find((y) => y.value === i.value);
|
|
398
386
|
return ((s == null ? void 0 : s.itemInGroup) || []).map((y) => ({
|
|
399
387
|
groupName: y.group.name,
|
|
@@ -433,7 +421,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
433
421
|
b.badge = () => d(te.FmCircularProgress, {
|
|
434
422
|
size: "md"
|
|
435
423
|
}, null);
|
|
436
|
-
const y = await
|
|
424
|
+
const y = await gt(Re(e.menu), s, e.itemId);
|
|
437
425
|
b.badge = y.length, b.disabled = y.length <= 0, b.itemInGroup = y;
|
|
438
426
|
}
|
|
439
427
|
}
|
|
@@ -446,12 +434,12 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
446
434
|
e.menu && e.itemId && f();
|
|
447
435
|
}, {
|
|
448
436
|
immediate: !0
|
|
449
|
-
}), (s, b) => (m(), I(
|
|
437
|
+
}), (s, b) => (m(), I(rt, {
|
|
450
438
|
modelValue: i.value,
|
|
451
439
|
"onUpdate:modelValue": b[0] || (b[0] = (y) => i.value = y),
|
|
452
440
|
items: t.value,
|
|
453
441
|
title: "Catalog",
|
|
454
|
-
"title-badge":
|
|
442
|
+
"title-badge": r.value
|
|
455
443
|
}, {
|
|
456
444
|
default: T(() => [d(sl, {
|
|
457
445
|
data: u.value
|
|
@@ -461,7 +449,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
461
449
|
}
|
|
462
450
|
}), il = {
|
|
463
451
|
class: "scroll-x-auto"
|
|
464
|
-
}, cl = /* @__PURE__ */
|
|
452
|
+
}, cl = /* @__PURE__ */ j({
|
|
465
453
|
__name: "ProductViewTable",
|
|
466
454
|
props: {
|
|
467
455
|
itemId: {},
|
|
@@ -504,7 +492,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
504
492
|
}, null);
|
|
505
493
|
},
|
|
506
494
|
enableSorting: !1
|
|
507
|
-
}],
|
|
495
|
+
}], r = F([]);
|
|
508
496
|
function t(u, l) {
|
|
509
497
|
return {
|
|
510
498
|
loading: !0,
|
|
@@ -517,14 +505,14 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
517
505
|
};
|
|
518
506
|
}
|
|
519
507
|
return de([() => e.menu, () => e.catalogId, () => e.schedulerIds], async () => {
|
|
520
|
-
|
|
508
|
+
r.value = [t(null, "All day"), ...e.schedulerIds.map((u) => {
|
|
521
509
|
var l;
|
|
522
510
|
return t(u, ((l = e.menu.modules.scheduler.find((v) => v._id === u)) == null ? void 0 : l.name) || "Unknown");
|
|
523
|
-
})],
|
|
524
|
-
const v = (await
|
|
511
|
+
})], r.value.forEach(async (u) => {
|
|
512
|
+
const v = (await bt(Re(e.menu), e.catalogId, u.schedulerId)).modules.item.find((s) => s._id === e.itemId), f = r.value.findIndex((s) => s.schedulerId === u.schedulerId);
|
|
525
513
|
if (v) {
|
|
526
|
-
const s = Re(
|
|
527
|
-
s[f].loading = !1, s[f].code = v.code || "--", s[f].productName = v.name || "--", s[f].price = me.Dinero.fromFdoDinero(v.price).toFormat(), s[f].orderFrom = v.orderFrom || "--",
|
|
514
|
+
const s = Re(r.value);
|
|
515
|
+
s[f].loading = !1, s[f].code = v.code || "--", s[f].productName = v.name || "--", s[f].price = me.Dinero.fromFdoDinero(v.price).toFormat(), s[f].orderFrom = v.orderFrom || "--", r.value = s;
|
|
528
516
|
}
|
|
529
517
|
});
|
|
530
518
|
}), (u, l) => {
|
|
@@ -533,16 +521,16 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
533
521
|
default: T(() => [g("div", il, [d(v, {
|
|
534
522
|
class: "min-w-[800px]",
|
|
535
523
|
"column-defs": i,
|
|
536
|
-
"row-data":
|
|
524
|
+
"row-data": r.value,
|
|
537
525
|
"hide-footer": !0,
|
|
538
|
-
"page-size":
|
|
526
|
+
"page-size": r.value.length,
|
|
539
527
|
"shrink-at": !1
|
|
540
528
|
}, null, 8, ["row-data", "page-size"])])]),
|
|
541
529
|
_: 1
|
|
542
530
|
});
|
|
543
531
|
};
|
|
544
532
|
}
|
|
545
|
-
}), dl = /* @__PURE__ */
|
|
533
|
+
}), dl = /* @__PURE__ */ j({
|
|
546
534
|
__name: "ProductView",
|
|
547
535
|
props: {
|
|
548
536
|
itemId: {},
|
|
@@ -551,9 +539,9 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
551
539
|
setup(C) {
|
|
552
540
|
const e = C, i = F(null);
|
|
553
541
|
tt(async () => {
|
|
554
|
-
i.value = await
|
|
542
|
+
i.value = await _t(e.menu, e.itemId), await Ae(), r.value = t.value[0].value;
|
|
555
543
|
});
|
|
556
|
-
const
|
|
544
|
+
const r = F(""), t = h(() => {
|
|
557
545
|
var f, s;
|
|
558
546
|
const l = {
|
|
559
547
|
label: "Master product",
|
|
@@ -576,10 +564,10 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
576
564
|
};
|
|
577
565
|
});
|
|
578
566
|
return [l, ...v];
|
|
579
|
-
}), u = h(() => t.value.find((l) => l.value ===
|
|
580
|
-
return (l, v) => (m(), I(
|
|
581
|
-
modelValue:
|
|
582
|
-
"onUpdate:modelValue": v[0] || (v[0] = (f) =>
|
|
567
|
+
}), u = h(() => t.value.find((l) => l.value === r.value));
|
|
568
|
+
return (l, v) => (m(), I(rt, {
|
|
569
|
+
modelValue: r.value,
|
|
570
|
+
"onUpdate:modelValue": v[0] || (v[0] = (f) => r.value = f),
|
|
583
571
|
items: t.value,
|
|
584
572
|
title: "Catalog",
|
|
585
573
|
"title-badge": t.value.filter((f) => !f.disabled).length
|
|
@@ -601,21 +589,21 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
601
589
|
}), ml = { class: "flex items-center gap-8" }, pl = { class: "space-y-4" }, vl = { class: "fm-typo-en-title-md-600" }, fl = { key: 0 }, gl = { class: "text-fm-color-typo-secondary" }, bl = {
|
|
602
590
|
key: 0,
|
|
603
591
|
class: "text-fm-color-typo-secondary"
|
|
604
|
-
}, _l = { class: "flex items-center gap-4" }, yl = /* @__PURE__ */
|
|
592
|
+
}, _l = { class: "flex items-center gap-4" }, yl = /* @__PURE__ */ j({
|
|
605
593
|
__name: "ProductBaseInfo",
|
|
606
594
|
props: {
|
|
607
595
|
itemId: {},
|
|
608
596
|
menu: {}
|
|
609
597
|
},
|
|
610
598
|
setup(C) {
|
|
611
|
-
const e = C, i = h(() => e.menu.modules.item.find((t) => t._id === e.itemId)),
|
|
599
|
+
const e = C, i = h(() => e.menu.modules.item.find((t) => t._id === e.itemId)), r = h(() => {
|
|
612
600
|
var t;
|
|
613
601
|
return me.Dinero.fromFdoDinero((t = i.value) == null ? void 0 : t.price).toFormat(!0);
|
|
614
602
|
});
|
|
615
603
|
return (t, u) => {
|
|
616
604
|
var l, v, f, s, b, y, w;
|
|
617
605
|
return m(), k("div", ml, [
|
|
618
|
-
d(
|
|
606
|
+
d(Me, {
|
|
619
607
|
alt: ((l = i.value) == null ? void 0 : l.name) ?? null,
|
|
620
608
|
size: 72,
|
|
621
609
|
src: (v = i.value) == null ? void 0 : v.thumbnail,
|
|
@@ -623,14 +611,14 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
623
611
|
}, null, 8, ["alt", "src"]),
|
|
624
612
|
g("div", pl, [
|
|
625
613
|
g("p", vl, [
|
|
626
|
-
(f = i.value) != null && f.code ? (m(), k("span", fl,
|
|
627
|
-
g("span", null,
|
|
614
|
+
(f = i.value) != null && f.code ? (m(), k("span", fl, N((s = i.value) == null ? void 0 : s.code) + ", ", 1)) : M("", !0),
|
|
615
|
+
g("span", null, N((b = i.value) == null ? void 0 : b.name), 1)
|
|
628
616
|
]),
|
|
629
|
-
g("p", gl, "Base price: " +
|
|
617
|
+
g("p", gl, "Base price: " + N(r.value), 1),
|
|
630
618
|
(y = i.value) != null && y.customAttributes ? (m(), k("div", bl, [
|
|
631
619
|
g("div", _l, [
|
|
632
620
|
u[0] || (u[0] = g("span", null, "Tagging:", -1)),
|
|
633
|
-
d(
|
|
621
|
+
d(Ue, {
|
|
634
622
|
ellipsis: !1,
|
|
635
623
|
"custom-attributes": (w = i.value) == null ? void 0 : w.customAttributes
|
|
636
624
|
}, null, 8, ["custom-attributes"])
|
|
@@ -640,7 +628,7 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
640
628
|
]);
|
|
641
629
|
};
|
|
642
630
|
}
|
|
643
|
-
}), hl = { class: "space-y-16" }, xl = /* @__PURE__ */
|
|
631
|
+
}), hl = { class: "space-y-16" }, xl = /* @__PURE__ */ j({
|
|
644
632
|
__name: "ProductViewer",
|
|
645
633
|
props: {
|
|
646
634
|
itemId: {},
|
|
@@ -659,13 +647,13 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
659
647
|
component: ul
|
|
660
648
|
}
|
|
661
649
|
]);
|
|
662
|
-
return (
|
|
650
|
+
return (r, t) => {
|
|
663
651
|
var l;
|
|
664
652
|
const u = O("FmTabs");
|
|
665
653
|
return m(), k("div", hl, [
|
|
666
654
|
d(yl, {
|
|
667
|
-
"item-id":
|
|
668
|
-
menu:
|
|
655
|
+
"item-id": r.itemId,
|
|
656
|
+
menu: r.menu
|
|
669
657
|
}, null, 8, ["item-id", "menu"]),
|
|
670
658
|
g("div", null, [
|
|
671
659
|
d(u, {
|
|
@@ -676,28 +664,28 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
676
664
|
]),
|
|
677
665
|
g("div", null, [
|
|
678
666
|
(m(), I(lt((l = i.value.find((v) => v.value === e.value)) == null ? void 0 : l.component), {
|
|
679
|
-
"item-id":
|
|
680
|
-
menu:
|
|
667
|
+
"item-id": r.itemId,
|
|
668
|
+
menu: r.menu
|
|
681
669
|
}, null, 8, ["item-id", "menu"]))
|
|
682
670
|
])
|
|
683
671
|
]);
|
|
684
672
|
};
|
|
685
673
|
}
|
|
686
|
-
}), Cl = { class: "space-y-24" }, kl = { key: 0 }, wl = /* @__PURE__ */
|
|
674
|
+
}), Cl = { class: "space-y-24" }, kl = { key: 0 }, wl = /* @__PURE__ */ j({
|
|
687
675
|
__name: "ProductOverview",
|
|
688
676
|
props: {
|
|
689
677
|
itemId: {},
|
|
690
678
|
showSearch: { type: Boolean, default: !1 }
|
|
691
679
|
},
|
|
692
680
|
setup(C) {
|
|
693
|
-
const e = C, i = Fe(),
|
|
681
|
+
const e = C, i = Fe(), r = F(null);
|
|
694
682
|
return at(() => {
|
|
695
|
-
|
|
683
|
+
r.value = e.itemId;
|
|
696
684
|
}), (t, u) => (m(), k("div", Cl, [
|
|
697
685
|
t.showSearch ? (m(), k("div", kl, [
|
|
698
686
|
d(Xt, {
|
|
699
|
-
modelValue:
|
|
700
|
-
"onUpdate:modelValue": u[0] || (u[0] = (l) =>
|
|
687
|
+
modelValue: r.value,
|
|
688
|
+
"onUpdate:modelValue": u[0] || (u[0] = (l) => r.value = l),
|
|
701
689
|
class: "w-1/2",
|
|
702
690
|
label: "Search and compare prices",
|
|
703
691
|
"helper-text": "Quickly find products and view their prices across different catalogs and schedules.",
|
|
@@ -705,25 +693,25 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
705
693
|
}, null, 8, ["modelValue", "menu"])
|
|
706
694
|
])) : M("", !0),
|
|
707
695
|
g("div", null, [
|
|
708
|
-
|
|
696
|
+
r.value ? (m(), I(xl, {
|
|
709
697
|
key: 0,
|
|
710
|
-
"item-id":
|
|
698
|
+
"item-id": r.value,
|
|
711
699
|
menu: a(i).state.menu
|
|
712
700
|
}, null, 8, ["item-id", "menu"])) : M("", !0)
|
|
713
701
|
])
|
|
714
702
|
]));
|
|
715
703
|
}
|
|
716
|
-
}), Sl = /* @__PURE__ */
|
|
704
|
+
}), Sl = /* @__PURE__ */ j({
|
|
717
705
|
__name: "OverviewSheet",
|
|
718
706
|
setup(C) {
|
|
719
707
|
const e = F(null), i = F(!1);
|
|
720
|
-
function
|
|
708
|
+
function r(t) {
|
|
721
709
|
i.value = !i.value, t && (e.value = t);
|
|
722
710
|
}
|
|
723
711
|
return (t, u) => {
|
|
724
712
|
const l = O("FmSideSheet");
|
|
725
713
|
return m(), k(pe, null, [
|
|
726
|
-
_e(t.$slots, "default", { trigger:
|
|
714
|
+
_e(t.$slots, "default", { trigger: r }),
|
|
727
715
|
d(l, {
|
|
728
716
|
id: "product-overview",
|
|
729
717
|
modelValue: i.value,
|
|
@@ -748,17 +736,17 @@ const Kt = { class: "inline-flex items-center" }, Nt = {
|
|
|
748
736
|
};
|
|
749
737
|
}
|
|
750
738
|
});
|
|
751
|
-
var Vl =
|
|
752
|
-
const Ye = /* @__PURE__ */
|
|
739
|
+
var Vl = Dt();
|
|
740
|
+
const Ye = /* @__PURE__ */ j({
|
|
753
741
|
__name: "ImportButton",
|
|
754
742
|
setup(C) {
|
|
755
743
|
const e = F(!1);
|
|
756
744
|
function i() {
|
|
757
745
|
e.value = !e.value;
|
|
758
746
|
}
|
|
759
|
-
const
|
|
747
|
+
const r = ze();
|
|
760
748
|
return at(() => {
|
|
761
|
-
const t =
|
|
749
|
+
const t = r.currentCountry.value;
|
|
762
750
|
if (t)
|
|
763
751
|
try {
|
|
764
752
|
Vl.setCountryConfig(t);
|
|
@@ -766,14 +754,14 @@ const Ye = /* @__PURE__ */ N({
|
|
|
766
754
|
console.log("Unable to set country config", u);
|
|
767
755
|
}
|
|
768
756
|
}), (t, u) => (m(), k(pe, null, [
|
|
769
|
-
d(
|
|
757
|
+
d(Ot, {
|
|
770
758
|
modelValue: e.value,
|
|
771
759
|
"onUpdate:modelValue": u[0] || (u[0] = (l) => e.value = l)
|
|
772
760
|
}, null, 8, ["modelValue"]),
|
|
773
761
|
_e(t.$slots, "default", { trigger: i })
|
|
774
762
|
], 64));
|
|
775
763
|
}
|
|
776
|
-
}),
|
|
764
|
+
}), Ze = (C) => d("div", {
|
|
777
765
|
class: "flex flex-1 justify-end"
|
|
778
766
|
}, [d("span", null, [C, et(" ")])]), Fl = {
|
|
779
767
|
class: "flex justify-between items-center space-x-8"
|
|
@@ -803,23 +791,23 @@ const Ye = /* @__PURE__ */ N({
|
|
|
803
791
|
class: "pt-8 flex flex-col flex-1 overflow-hidden"
|
|
804
792
|
}, Ol = {
|
|
805
793
|
class: "space-y-8 pb-8"
|
|
806
|
-
}, Bl = {
|
|
807
|
-
class: "w-full px-8"
|
|
808
794
|
}, Kl = {
|
|
809
|
-
class: "
|
|
795
|
+
class: "w-full px-8"
|
|
810
796
|
}, Nl = {
|
|
797
|
+
class: "flex space-x-8 px-8"
|
|
798
|
+
}, jl = {
|
|
811
799
|
key: 0,
|
|
812
800
|
class: "px-8"
|
|
813
|
-
},
|
|
801
|
+
}, Bl = {
|
|
814
802
|
key: 0,
|
|
815
803
|
class: /* @__PURE__ */ ve(["flex flex-col flex-1", "overflow-scroll", "divide-y divide-fm-color-neutral-gray-100", "pb-64"])
|
|
816
804
|
}, El = ["onClick"], Gl = {
|
|
817
805
|
class: "min-w-0 flex flex-1 items-center justify-start space-x-16"
|
|
818
806
|
}, Ll = {
|
|
819
807
|
class: "flex-1 min-w-0"
|
|
820
|
-
}, Wl = {
|
|
821
|
-
class: "flex justify-between items-center gap-8 pb-4"
|
|
822
808
|
}, ql = {
|
|
809
|
+
class: "flex justify-between items-center gap-8 pb-4"
|
|
810
|
+
}, Wl = {
|
|
823
811
|
class: "flex-1 min-w-0 fm-typo-en-body-lg-600 line-clamp-2"
|
|
824
812
|
}, Hl = {
|
|
825
813
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
@@ -827,11 +815,11 @@ const Ye = /* @__PURE__ */ N({
|
|
|
827
815
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
828
816
|
}, Yl = {
|
|
829
817
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
830
|
-
}, Jl = {
|
|
831
|
-
key: 1
|
|
832
818
|
}, Zl = {
|
|
819
|
+
key: 1
|
|
820
|
+
}, Jl = {
|
|
833
821
|
class: "flex space-x-8"
|
|
834
|
-
}, Xl = /* @__PURE__ */
|
|
822
|
+
}, Xl = /* @__PURE__ */ j({
|
|
835
823
|
__name: "ProductTable",
|
|
836
824
|
props: {
|
|
837
825
|
modelValue: {},
|
|
@@ -845,59 +833,59 @@ const Ye = /* @__PURE__ */ N({
|
|
|
845
833
|
expose: e,
|
|
846
834
|
emit: i
|
|
847
835
|
}) {
|
|
848
|
-
const
|
|
836
|
+
const r = C, {
|
|
849
837
|
t
|
|
850
|
-
} = Ie(), u = ze(), l = Fe(), v =
|
|
838
|
+
} = Ie(), u = ze(), l = Fe(), v = Ut(), f = ot(), s = u.currentCountry, b = h(() => s.value ? me.Country.getCountry(s.value) : null), y = h(() => l.rules.item), {
|
|
851
839
|
selectedCategories: w
|
|
852
840
|
} = Se(), z = h(() => {
|
|
853
|
-
const o = ge.flatten(w.value.map((
|
|
854
|
-
return ge.uniqBy(o, (
|
|
841
|
+
const o = ge.flatten(w.value.map((n) => n.items));
|
|
842
|
+
return ge.uniqBy(o, (n) => n._id);
|
|
855
843
|
}), Y = i, S = F(!1);
|
|
856
844
|
de(() => S.value, (o) => {
|
|
857
845
|
Y("update:editing", o);
|
|
858
846
|
});
|
|
859
847
|
const oe = (o) => {
|
|
860
|
-
|
|
861
|
-
},
|
|
848
|
+
Tt.isBoolean(o) ? S.value = o : S.value = !S.value;
|
|
849
|
+
}, Z = F(!1), ne = F(null);
|
|
862
850
|
async function G() {
|
|
863
|
-
|
|
851
|
+
Z.value = !Z.value, Z.value && (await Ae(), ne.value && ne.value.toggleProperty(!0));
|
|
864
852
|
}
|
|
865
853
|
e({
|
|
866
854
|
toggleAttributeFilter: G
|
|
867
855
|
});
|
|
868
856
|
const {
|
|
869
|
-
attributes:
|
|
857
|
+
attributes: K,
|
|
870
858
|
filterRule: D,
|
|
871
859
|
mongoQuery: H
|
|
872
|
-
} =
|
|
860
|
+
} = Mt({
|
|
873
861
|
valueSource: z,
|
|
874
862
|
entity: "item"
|
|
875
|
-
}),
|
|
863
|
+
}), J = F(""), re = yt(J, 300), Q = h(() => {
|
|
876
864
|
const o = (c) => {
|
|
877
865
|
var x;
|
|
878
|
-
return !
|
|
879
|
-
},
|
|
880
|
-
return z.value.filter((c) => o(c) &&
|
|
866
|
+
return !re.value || !re.value.trim() ? !0 : [c.code, c.name, Ke(c), ...Pe(se.value, c), (x = ke()[c.orderFrom]) == null ? void 0 : x.label, Object.values(c.customAttributes ?? {}).join(" ")].join(" ").toLowerCase().includes(re.value.toLowerCase());
|
|
867
|
+
}, n = (c) => H.value ? Pt(c.customAttributes, H.value) : !0;
|
|
868
|
+
return z.value.filter((c) => o(c) && n(c));
|
|
881
869
|
}), {
|
|
882
870
|
categories: se
|
|
883
871
|
} = Se(), R = h(() => l.categories.map((o) => ({
|
|
884
872
|
label: o.name,
|
|
885
873
|
value: o._id || null
|
|
886
|
-
}))), $ = (o,
|
|
887
|
-
let p = ge.clone(
|
|
874
|
+
}))), $ = (o, n, c) => {
|
|
875
|
+
let p = ge.clone(r.modelValue);
|
|
888
876
|
const x = p[o];
|
|
889
|
-
x && (typeof
|
|
877
|
+
x && (typeof n == "object" && n !== null ? p[o] = {
|
|
890
878
|
...x,
|
|
891
|
-
...
|
|
879
|
+
...n
|
|
892
880
|
} : p[o] = {
|
|
893
881
|
...x,
|
|
894
|
-
[
|
|
882
|
+
[n]: c
|
|
895
883
|
}, Y("update:model-value", p));
|
|
896
|
-
}, P =
|
|
884
|
+
}, P = xt(() => r.originalValue, () => r.modelValue), A = ge.debounce($, 300), ue = (o) => (n) => !!n || t("menu.product.table.validation.name_required", {
|
|
897
885
|
field: o
|
|
898
|
-
}), L = (o) => o >= 0 || t("menu.product.table.validation.price_min"),
|
|
886
|
+
}), L = (o) => o >= 0 || t("menu.product.table.validation.price_min"), B = [ue("Name")], U = () => [(o) => L(typeof o == "number" ? o : Number(o) ?? 0)], ie = ke(), E = h(() => {
|
|
899
887
|
const o = l.isV4;
|
|
900
|
-
return
|
|
888
|
+
return ht.setCoreStore(u).taxSetting(o);
|
|
901
889
|
}), ce = h(() => [{
|
|
902
890
|
accessorKey: "thumbnail",
|
|
903
891
|
header: "",
|
|
@@ -907,10 +895,10 @@ const Ye = /* @__PURE__ */ N({
|
|
|
907
895
|
headerContentClass: "px-0"
|
|
908
896
|
},
|
|
909
897
|
cell: (o) => {
|
|
910
|
-
var
|
|
911
|
-
return
|
|
898
|
+
var n, c;
|
|
899
|
+
return q(Me, {
|
|
912
900
|
src: o.getValue(),
|
|
913
|
-
alt: (c = (
|
|
901
|
+
alt: (c = (n = o == null ? void 0 : o.row) == null ? void 0 : n.original) == null ? void 0 : c.name,
|
|
914
902
|
className: "my-8 mx-12",
|
|
915
903
|
size: 72,
|
|
916
904
|
crossorigin: !1
|
|
@@ -923,17 +911,17 @@ const Ye = /* @__PURE__ */ N({
|
|
|
923
911
|
enableSorting: !1,
|
|
924
912
|
size: 100,
|
|
925
913
|
cell: (o) => {
|
|
926
|
-
const
|
|
914
|
+
const n = o.row.original, c = o.getValue() || "--";
|
|
927
915
|
if (!S.value) return d("span", {
|
|
928
916
|
class: "break-all"
|
|
929
917
|
}, [c]);
|
|
930
|
-
const p = Te(
|
|
931
|
-
return
|
|
918
|
+
const p = Te(n._id);
|
|
919
|
+
return q(te.FmTextField, {
|
|
932
920
|
disabled: !y.value.code,
|
|
933
|
-
modelValue: P(
|
|
934
|
-
placeholder:
|
|
921
|
+
modelValue: P(n._id, "code") ?? (p == null ? void 0 : p.code),
|
|
922
|
+
placeholder: r.modelValue[n._id].fallbackCode,
|
|
935
923
|
"onUpdate:modelValue": (x) => {
|
|
936
|
-
A(
|
|
924
|
+
A(n._id, "code", x);
|
|
937
925
|
}
|
|
938
926
|
});
|
|
939
927
|
}
|
|
@@ -943,22 +931,22 @@ const Ye = /* @__PURE__ */ N({
|
|
|
943
931
|
enableSorting: !1,
|
|
944
932
|
size: 200,
|
|
945
933
|
cell: (o) => {
|
|
946
|
-
const
|
|
947
|
-
return S.value ?
|
|
934
|
+
const n = o.row.original, c = o.getValue();
|
|
935
|
+
return S.value ? q(te.FmTextField, {
|
|
948
936
|
disabled: !y.value.name,
|
|
949
|
-
modelValue: P(
|
|
937
|
+
modelValue: P(n._id, "name") ?? n.name,
|
|
950
938
|
"onUpdate:modelValue": (p) => {
|
|
951
|
-
A(
|
|
939
|
+
A(n._id, "name", p);
|
|
952
940
|
},
|
|
953
|
-
rules:
|
|
954
|
-
placeholder:
|
|
941
|
+
rules: B,
|
|
942
|
+
placeholder: n.fallbackName
|
|
955
943
|
}) : c;
|
|
956
944
|
}
|
|
957
945
|
}, {
|
|
958
946
|
accessorKey: "price",
|
|
959
947
|
header: () => {
|
|
960
948
|
var o;
|
|
961
|
-
return
|
|
949
|
+
return Ze(t("menu.product.table.columns.price", {
|
|
962
950
|
currency: (o = b.value) == null ? void 0 : o.currency.symbol
|
|
963
951
|
}));
|
|
964
952
|
},
|
|
@@ -969,14 +957,14 @@ const Ye = /* @__PURE__ */ N({
|
|
|
969
957
|
},
|
|
970
958
|
cell: (o) => {
|
|
971
959
|
var x;
|
|
972
|
-
const
|
|
973
|
-
if (!S.value) return me.Dinero.fromFdoDinero(
|
|
974
|
-
const c =
|
|
975
|
-
return
|
|
960
|
+
const n = o.getValue();
|
|
961
|
+
if (!S.value) return me.Dinero.fromFdoDinero(n).toFormat();
|
|
962
|
+
const c = r.modelValue[o.row.original._id], p = c.fallbackPrice;
|
|
963
|
+
return q(Ct, {
|
|
976
964
|
min: 0,
|
|
977
965
|
disabled: !c.editPrice,
|
|
978
966
|
// @ts-ignore
|
|
979
|
-
placeholder: p ?
|
|
967
|
+
placeholder: p ? kt(p, !1) : void 0,
|
|
980
968
|
modelValue: P(c._id, "price") ?? ((x = Te(c._id)) == null ? void 0 : x.price),
|
|
981
969
|
// @ts-ignore
|
|
982
970
|
"onUpdate:modelValue": (V) => {
|
|
@@ -987,18 +975,18 @@ const Ye = /* @__PURE__ */ N({
|
|
|
987
975
|
}
|
|
988
976
|
}, {
|
|
989
977
|
accessorKey: "taxes",
|
|
990
|
-
header: () =>
|
|
978
|
+
header: () => Ze(E.value.systemCode),
|
|
991
979
|
size: S.value ? 120 : 80,
|
|
992
980
|
enableSorting: !1,
|
|
993
981
|
meta: {
|
|
994
982
|
textAlign: "right"
|
|
995
983
|
},
|
|
996
984
|
cell: (o) => {
|
|
997
|
-
const
|
|
985
|
+
const n = o.getValue(), c = o.row.original, p = l.taxSetting.countryTaxOptions, x = l.getSelectedTax(n, c.fallbackTaxes, l.taxSetting.countryTaxOptions), V = p.find((ae) => ae.value === x);
|
|
998
986
|
if (!S.value)
|
|
999
|
-
return `${V != null && V.meta.rate ?
|
|
1000
|
-
const _ = l.getSelectedTax(P(c._id, "taxes") ??
|
|
1001
|
-
return
|
|
987
|
+
return `${V != null && V.meta.rate ? wt(V.meta.rate) : 0}%`;
|
|
988
|
+
const _ = l.getSelectedTax(P(c._id, "taxes") ?? n, c.fallbackTaxes, l.taxSetting.countryTaxOptions);
|
|
989
|
+
return q(te.FmSelect, {
|
|
1002
990
|
disabled: !y.value.tax,
|
|
1003
991
|
items: l.taxSetting.countryTaxOptions,
|
|
1004
992
|
modelValue: _,
|
|
@@ -1014,13 +1002,13 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1014
1002
|
enableSorting: !1,
|
|
1015
1003
|
size: 140,
|
|
1016
1004
|
cell: (o) => {
|
|
1017
|
-
const
|
|
1005
|
+
const n = o.row.original;
|
|
1018
1006
|
if (!S.value)
|
|
1019
|
-
return
|
|
1020
|
-
categories: Pe(se.value,
|
|
1007
|
+
return q(Qe, {
|
|
1008
|
+
categories: Pe(se.value, n)
|
|
1021
1009
|
});
|
|
1022
|
-
const c =
|
|
1023
|
-
return
|
|
1010
|
+
const c = St(r.originalValue, r.modelValue, n._id) ?? Vt(n), p = (c == null ? void 0 : c.map((V) => V._id)) ?? [], x = c == null ? void 0 : c.reduce((V, _) => (V[_._id] = _, V), {});
|
|
1011
|
+
return q(Ft, {
|
|
1024
1012
|
shouldShowChips: !1,
|
|
1025
1013
|
shouldShowSelectedItemsWithinPlaceholder: !0,
|
|
1026
1014
|
modelValue: p.length > 0 ? p : [null],
|
|
@@ -1028,11 +1016,11 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1028
1016
|
disabled: !!(l.state.currentCatalogId || l.state.currentSchedulerId),
|
|
1029
1017
|
"onUpdate:modelValue": async (V) => {
|
|
1030
1018
|
const [_, ...ae] = V;
|
|
1031
|
-
A(
|
|
1019
|
+
A(n._id, {
|
|
1032
1020
|
category: _,
|
|
1033
1021
|
additionalCategories: ae.map((xe) => {
|
|
1034
|
-
const
|
|
1035
|
-
return
|
|
1022
|
+
const je = x == null ? void 0 : x[xe];
|
|
1023
|
+
return je || {
|
|
1036
1024
|
_id: xe,
|
|
1037
1025
|
position: null
|
|
1038
1026
|
};
|
|
@@ -1048,31 +1036,31 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1048
1036
|
enableSorting: !1,
|
|
1049
1037
|
size: 140,
|
|
1050
1038
|
cell: (o) => {
|
|
1051
|
-
const
|
|
1052
|
-
return
|
|
1053
|
-
customAttributes:
|
|
1039
|
+
const n = o.row.original;
|
|
1040
|
+
return q(Ue, {
|
|
1041
|
+
customAttributes: n.customAttributes
|
|
1054
1042
|
});
|
|
1055
1043
|
}
|
|
1056
1044
|
}, {
|
|
1057
1045
|
accessorKey: "orderFrom",
|
|
1058
1046
|
header: () => t("menu.product.table.columns.order_from"),
|
|
1059
1047
|
enableSorting: !0,
|
|
1060
|
-
sortingFn: (o,
|
|
1061
|
-
const [c, p] = [o,
|
|
1048
|
+
sortingFn: (o, n) => {
|
|
1049
|
+
const [c, p] = [o, n].map((x) => ie[x.original.orderFrom].sortingIndex);
|
|
1062
1050
|
return c - p;
|
|
1063
1051
|
},
|
|
1064
1052
|
size: 140,
|
|
1065
1053
|
cell: (o) => {
|
|
1066
|
-
const
|
|
1067
|
-
return S.value ?
|
|
1054
|
+
const n = o.getValue(), c = o.row.original;
|
|
1055
|
+
return S.value ? q(te.FmSelect, {
|
|
1068
1056
|
disabled: !y.value.orderFrom,
|
|
1069
|
-
items: Object.values(
|
|
1070
|
-
modelValue: P(c._id, "orderFrom") ??
|
|
1057
|
+
items: Object.values(ke()),
|
|
1058
|
+
modelValue: P(c._id, "orderFrom") ?? n,
|
|
1071
1059
|
"onUpdate:modelValue": async (p) => {
|
|
1072
1060
|
$(c._id, "orderFrom", p);
|
|
1073
1061
|
}
|
|
1074
|
-
}) :
|
|
1075
|
-
orderFrom:
|
|
1062
|
+
}) : q(Ve, {
|
|
1063
|
+
orderFrom: n
|
|
1076
1064
|
});
|
|
1077
1065
|
}
|
|
1078
1066
|
}, {
|
|
@@ -1083,18 +1071,18 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1083
1071
|
headerClass: "py-4",
|
|
1084
1072
|
textAlign: "right"
|
|
1085
1073
|
},
|
|
1086
|
-
header: () =>
|
|
1074
|
+
header: () => q("div", {
|
|
1087
1075
|
class: "w-full px-4 flex justify-end"
|
|
1088
|
-
}, [
|
|
1076
|
+
}, [It(q(te.FmButton, {
|
|
1089
1077
|
variant: ee.Tertiary,
|
|
1090
|
-
textColor:
|
|
1078
|
+
textColor: W.NeutralGray400,
|
|
1091
1079
|
prependIcon: "edit",
|
|
1092
1080
|
class: "flex justify-end",
|
|
1093
1081
|
onClick: oe,
|
|
1094
1082
|
type: "button"
|
|
1095
1083
|
}), "Bulk edit")]),
|
|
1096
1084
|
cell: (o) => {
|
|
1097
|
-
const
|
|
1085
|
+
const n = o.row.original;
|
|
1098
1086
|
return d("div", {
|
|
1099
1087
|
class: "px-4 flex justify-end"
|
|
1100
1088
|
}, [d(Sl, null, {
|
|
@@ -1103,20 +1091,20 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1103
1091
|
}) => d(te.FmButton, {
|
|
1104
1092
|
icon: "overview",
|
|
1105
1093
|
variant: "tertiary",
|
|
1106
|
-
textColor:
|
|
1094
|
+
textColor: W.NeutralGray400,
|
|
1107
1095
|
onClick: fe(() => {
|
|
1108
|
-
c(
|
|
1096
|
+
c(n._id);
|
|
1109
1097
|
}, ["stop", "prevent"])
|
|
1110
1098
|
}, null)
|
|
1111
1099
|
}), d(te.FmButton, {
|
|
1112
1100
|
icon: "delete",
|
|
1113
1101
|
variant: "tertiary",
|
|
1114
|
-
textColor:
|
|
1102
|
+
textColor: W.NeutralGray400,
|
|
1115
1103
|
onClick: fe(async () => {
|
|
1116
1104
|
await f.deleteItem([{
|
|
1117
|
-
_id:
|
|
1118
|
-
name:
|
|
1119
|
-
thumbnail:
|
|
1105
|
+
_id: n._id,
|
|
1106
|
+
name: n.name,
|
|
1107
|
+
thumbnail: n.thumbnail
|
|
1120
1108
|
}]);
|
|
1121
1109
|
}, ["stop", "prevent"])
|
|
1122
1110
|
}, null)]);
|
|
@@ -1125,11 +1113,11 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1125
1113
|
l.taxSetting.systemCode || ce.value.splice(4, 1);
|
|
1126
1114
|
const le = F({}), X = F([]);
|
|
1127
1115
|
de([() => le.value, () => Q.value], (o) => {
|
|
1128
|
-
let
|
|
1116
|
+
let n = [];
|
|
1129
1117
|
Object.keys(o[0]).forEach((c) => {
|
|
1130
1118
|
const p = o[0][c], x = Q.value[parseInt(c)];
|
|
1131
|
-
x && (p ?
|
|
1132
|
-
}), X.value =
|
|
1119
|
+
x && (p ? n.push(x) : X.value = n.filter((V) => V !== x));
|
|
1120
|
+
}), X.value = n;
|
|
1133
1121
|
}), de(() => z.value, () => {
|
|
1134
1122
|
le.value = {}, X.value = [];
|
|
1135
1123
|
}), de(() => S.value, () => {
|
|
@@ -1140,9 +1128,9 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1140
1128
|
};
|
|
1141
1129
|
async function Oe() {
|
|
1142
1130
|
await Ae();
|
|
1143
|
-
const o = () => !!l.currentCatalog || !!l.state.currentSchedulerId,
|
|
1144
|
-
const x = Object.values(
|
|
1145
|
-
return
|
|
1131
|
+
const o = () => !!l.currentCatalog || !!l.state.currentSchedulerId, n = (p) => p === "" || p === null ? o() ? "" : null : p, c = Object.values(r.modelValue).filter((p) => {
|
|
1132
|
+
const x = Object.values(r.originalValue).find((V) => V._id === p._id);
|
|
1133
|
+
return Ge(x, p);
|
|
1146
1134
|
}).map((p) => ({
|
|
1147
1135
|
_id: p._id,
|
|
1148
1136
|
name: p.name,
|
|
@@ -1150,7 +1138,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1150
1138
|
price: p.price,
|
|
1151
1139
|
orderFrom: p.orderFrom ?? null,
|
|
1152
1140
|
taxes: p.taxes,
|
|
1153
|
-
category:
|
|
1141
|
+
category: n(p.category || null),
|
|
1154
1142
|
additionalCategories: p.additionalCategories
|
|
1155
1143
|
}));
|
|
1156
1144
|
await f.updateMany(c), oe(!1);
|
|
@@ -1164,7 +1152,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1164
1152
|
}, he = () => {
|
|
1165
1153
|
Y("reset:model-value");
|
|
1166
1154
|
}, $e = () => {
|
|
1167
|
-
Object.entries(
|
|
1155
|
+
Object.entries(r.modelValue).some(([n, c]) => Ge(c, r.originalValue[n])) ? v.open({
|
|
1168
1156
|
title: "You have unsaved changes!",
|
|
1169
1157
|
message: "Are you sure you want to discard? You will lose all the changes if discard edit.",
|
|
1170
1158
|
primaryActions: {
|
|
@@ -1180,11 +1168,11 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1180
1168
|
he(), oe(!1);
|
|
1181
1169
|
}) : (oe(!1), he());
|
|
1182
1170
|
}, ut = h(() => {
|
|
1183
|
-
var o,
|
|
1171
|
+
var o, n;
|
|
1184
1172
|
return {
|
|
1185
1173
|
thumbnail: !S.value,
|
|
1186
1174
|
actions: !S.value,
|
|
1187
|
-
tagging: !S.value && ((
|
|
1175
|
+
tagging: !S.value && ((n = (o = u.itemAttributeSettings) == null ? void 0 : o.value) == null ? void 0 : n.length) > 0
|
|
1188
1176
|
};
|
|
1189
1177
|
}), it = (o) => {
|
|
1190
1178
|
f.update(o._id);
|
|
@@ -1192,13 +1180,13 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1192
1180
|
async function ct(o) {
|
|
1193
1181
|
await f.update(o.original._id);
|
|
1194
1182
|
}
|
|
1195
|
-
function
|
|
1183
|
+
function Ke(o) {
|
|
1196
1184
|
var _;
|
|
1197
|
-
const
|
|
1185
|
+
const n = o.price ?? // TODO: fix type error
|
|
1198
1186
|
// @ts-ignore
|
|
1199
1187
|
o.fallbackPrice ?? me.Dinero.fromNumber({
|
|
1200
1188
|
number: 0
|
|
1201
|
-
}).toObject(), c = o.taxes, p = l.taxSetting.countryTaxOptions, x = me.Dinero.fromFdoDinero(
|
|
1189
|
+
}).toObject(), c = o.taxes, p = l.taxSetting.countryTaxOptions, x = me.Dinero.fromFdoDinero(n).toFormat(), V = (_ = b.value) == null ? void 0 : _.currency.symbol;
|
|
1202
1190
|
return l.getSelectedTax(
|
|
1203
1191
|
c,
|
|
1204
1192
|
// TODO: fix type error
|
|
@@ -1209,51 +1197,51 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1209
1197
|
}
|
|
1210
1198
|
function Te(o) {
|
|
1211
1199
|
var p;
|
|
1212
|
-
const
|
|
1213
|
-
if (
|
|
1214
|
-
const x =
|
|
1200
|
+
const n = l.currentCatalog, c = l.state.currentSchedulerId;
|
|
1201
|
+
if (n && c) {
|
|
1202
|
+
const x = n.override.scheduler[c] ?? {}, V = (p = x == null ? void 0 : x.items) == null ? void 0 : p.filter((_) => _._id === o);
|
|
1215
1203
|
return V == null ? void 0 : V[0];
|
|
1216
|
-
} else return
|
|
1204
|
+
} else return n ? n.override.items[o][0] : c ? l.schedulers.find((_) => _._id === c).items.filter((_) => _._id === o)[0] : z.value.find((x) => x._id === o);
|
|
1217
1205
|
}
|
|
1218
|
-
const dt =
|
|
1219
|
-
var
|
|
1206
|
+
const dt = nt(), mt = h(() => dt.breakpoints.value.xs), Ne = F(null), pt = zt(Ne, Z), vt = h(() => {
|
|
1207
|
+
var n;
|
|
1220
1208
|
return {
|
|
1221
|
-
height: `calc(100vh - ${((
|
|
1209
|
+
height: `calc(100vh - ${((n = pt.value) == null ? void 0 : n.top) + 24}px)`
|
|
1222
1210
|
};
|
|
1223
1211
|
});
|
|
1224
|
-
return (o,
|
|
1212
|
+
return (o, n) => {
|
|
1225
1213
|
const c = O("fm-search"), p = O("fm-button"), x = O("fm-table"), V = O("fm-form");
|
|
1226
|
-
return mt.value ? (m(), k("div", Dl, [g("div", Ol, [g("div",
|
|
1227
|
-
"model-value":
|
|
1228
|
-
"onUpdate:modelValue":
|
|
1214
|
+
return mt.value ? (m(), k("div", Dl, [g("div", Ol, [g("div", Kl, [d(c, {
|
|
1215
|
+
"model-value": J.value,
|
|
1216
|
+
"onUpdate:modelValue": n[5] || (n[5] = (_) => J.value = _),
|
|
1229
1217
|
autofocus: "",
|
|
1230
1218
|
placeholder: a(t)("menu.product.table.search.placeholder")
|
|
1231
|
-
}, null, 8, ["model-value", "placeholder"])]),
|
|
1219
|
+
}, null, 8, ["model-value", "placeholder"])]), n[8] || (n[8] = g("div", {
|
|
1232
1220
|
class: "w-full h-[1px] bg-fm-color-neutral-gray-100"
|
|
1233
|
-
}, null, -1)), g("div",
|
|
1221
|
+
}, null, -1)), g("div", Nl, [_e(o.$slots, "filter")]), Z.value ? (m(), k("div", jl, [d(a(Ee), {
|
|
1234
1222
|
ref_key: "attributeFilterRef",
|
|
1235
|
-
ref:
|
|
1236
|
-
attributes: a(
|
|
1223
|
+
ref: ne,
|
|
1224
|
+
attributes: a(K),
|
|
1237
1225
|
modelValue: a(D),
|
|
1238
|
-
"onUpdate:modelValue":
|
|
1239
|
-
}, null, 8, ["attributes", "modelValue"])])) : M("", !0)]), z.value.length ? (m(), k("div",
|
|
1226
|
+
"onUpdate:modelValue": n[6] || (n[6] = (_) => Be(D) ? D.value = _ : null)
|
|
1227
|
+
}, null, 8, ["attributes", "modelValue"])])) : M("", !0)]), z.value.length ? (m(), k("div", Bl, [(m(!0), k(pe, null, we(Q.value, (_) => {
|
|
1240
1228
|
var ae;
|
|
1241
1229
|
return m(), k("div", {
|
|
1242
1230
|
key: _._id,
|
|
1243
1231
|
class: "max-w-full py-12 px-16 space-x-16 flex items-center",
|
|
1244
1232
|
onClick: () => it(_)
|
|
1245
|
-
}, [g("div", Gl, [d(
|
|
1233
|
+
}, [g("div", Gl, [d(Me, {
|
|
1246
1234
|
alt: _.name,
|
|
1247
1235
|
size: 72,
|
|
1248
1236
|
src: _.thumbnail
|
|
1249
|
-
}, null, 8, ["alt", "src"]), g("div", Ll, [g("div",
|
|
1237
|
+
}, null, 8, ["alt", "src"]), g("div", Ll, [g("div", ql, [g("p", Wl, N(_.name), 1), d(Ve, {
|
|
1250
1238
|
"order-from": _.orderFrom
|
|
1251
|
-
}, null, 8, ["order-from"])]), g("p", Hl,
|
|
1239
|
+
}, null, 8, ["order-from"])]), g("p", Hl, N(Ke(_)), 1), g("p", Ql, N(a(t)("menu.product.table.columns.code")) + ": " + N(((ae = Te(_._id)) == null ? void 0 : ae.code) || "--"), 1), g("p", Yl, [d(Qe, {
|
|
1252
1240
|
categories: a(Pe)(a(se), _)
|
|
1253
|
-
}, null, 8, ["categories"])]), d(
|
|
1241
|
+
}, null, 8, ["categories"])]), d(Ue, {
|
|
1254
1242
|
"custom-attributes": _.customAttributes
|
|
1255
1243
|
}, null, 8, ["custom-attributes"])])]), d(p, {
|
|
1256
|
-
"text-color": a(
|
|
1244
|
+
"text-color": a(W).NeutralGray400,
|
|
1257
1245
|
variant: a(ee).Tertiary,
|
|
1258
1246
|
"prepend-icon": "delete",
|
|
1259
1247
|
onClick: fe(() => a(f).deleteItem([{
|
|
@@ -1262,21 +1250,21 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1262
1250
|
thumbnail: _.thumbnail
|
|
1263
1251
|
}]), ["stop"])
|
|
1264
1252
|
}, null, 8, ["text-color", "variant", "onClick"])], 8, El);
|
|
1265
|
-
}), 128))])) : (m(), k("div",
|
|
1253
|
+
}), 128))])) : (m(), k("div", Zl, [d(be, {
|
|
1266
1254
|
subtitle: a(t)("menu.product.table.empty.subtitle"),
|
|
1267
1255
|
title: a(t)("menu.product.table.empty.title")
|
|
1268
1256
|
}, {
|
|
1269
|
-
action: T(() => [g("div",
|
|
1257
|
+
action: T(() => [g("div", Jl, [d(p, {
|
|
1270
1258
|
variant: a(ee).Primary,
|
|
1271
1259
|
label: a(t)("menu.product.table.empty.actions.add"),
|
|
1272
1260
|
"prepend-icon": "add",
|
|
1273
|
-
onClick:
|
|
1261
|
+
onClick: n[7] || (n[7] = (_) => a(f).create(null))
|
|
1274
1262
|
}, null, 8, ["variant", "label"]), d(Ye, null, {
|
|
1275
1263
|
default: T(({
|
|
1276
1264
|
trigger: _
|
|
1277
1265
|
}) => [d(p, {
|
|
1278
|
-
"bg-color": a(
|
|
1279
|
-
"text-color": a(
|
|
1266
|
+
"bg-color": a(W).NeutralGray100,
|
|
1267
|
+
"text-color": a(W).NeutralGray400,
|
|
1280
1268
|
variant: a(ee).Primary,
|
|
1281
1269
|
label: a(t)("menu.product.table.empty.actions.import"),
|
|
1282
1270
|
"prepend-icon": "download",
|
|
@@ -1292,17 +1280,17 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1292
1280
|
onValidationSuccess: Oe
|
|
1293
1281
|
}, {
|
|
1294
1282
|
default: T(() => [g("div", Fl, [g("div", Il, [_e(o.$slots, "filter")]), g("div", $l, [d(c, {
|
|
1295
|
-
"model-value":
|
|
1296
|
-
"onUpdate:modelValue":
|
|
1283
|
+
"model-value": J.value,
|
|
1284
|
+
"onUpdate:modelValue": n[0] || (n[0] = (_) => J.value = _),
|
|
1297
1285
|
autofocus: "",
|
|
1298
1286
|
placeholder: a(t)("menu.product.table.search.placeholder")
|
|
1299
|
-
}, null, 8, ["model-value", "placeholder"])])]),
|
|
1287
|
+
}, null, 8, ["model-value", "placeholder"])])]), Z.value ? (m(), k("div", Tl, [d(a(Ee), {
|
|
1300
1288
|
ref_key: "attributeFilterRef",
|
|
1301
|
-
ref:
|
|
1302
|
-
attributes: a(
|
|
1289
|
+
ref: ne,
|
|
1290
|
+
attributes: a(K),
|
|
1303
1291
|
modelValue: a(D),
|
|
1304
|
-
"onUpdate:modelValue":
|
|
1305
|
-
}, null, 8, ["attributes", "modelValue"])])) : M("", !0), z.value.length ? (m(), k("div", Pl, [X.value.length && !S.value ? (m(), k("div", Al, [g("p", Rl,
|
|
1292
|
+
"onUpdate:modelValue": n[1] || (n[1] = (_) => Be(D) ? D.value = _ : null)
|
|
1293
|
+
}, null, 8, ["attributes", "modelValue"])])) : M("", !0), z.value.length ? (m(), k("div", Pl, [X.value.length && !S.value ? (m(), k("div", Al, [g("p", Rl, N(a(t)("menu.product.table.selection.count", {
|
|
1306
1294
|
count: X.value.length
|
|
1307
1295
|
})), 1), d(p, {
|
|
1308
1296
|
label: a(t)("menu.product.table.selection.actions.deselect_all"),
|
|
@@ -1310,8 +1298,8 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1310
1298
|
variant: "plain",
|
|
1311
1299
|
onClick: ye
|
|
1312
1300
|
}, null, 8, ["label"]), d(p, {
|
|
1313
|
-
"border-color": a(
|
|
1314
|
-
"text-color": a(
|
|
1301
|
+
"border-color": a(W).SystemError300,
|
|
1302
|
+
"text-color": a(W).SystemError300,
|
|
1315
1303
|
class: "ml-auto",
|
|
1316
1304
|
label: a(t)("menu.product.table.selection.actions.remove"),
|
|
1317
1305
|
"prepend-icon": "delete",
|
|
@@ -1326,15 +1314,15 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1326
1314
|
label: a(t)("menu.common.actions.cancel"),
|
|
1327
1315
|
onClick: $e
|
|
1328
1316
|
}, null, 8, ["variant", "label"]), d(p, {
|
|
1329
|
-
borderColor: a(
|
|
1330
|
-
textColor: a(
|
|
1317
|
+
borderColor: a(W).ColorPrimary,
|
|
1318
|
+
textColor: a(W).ColorPrimary,
|
|
1331
1319
|
variant: a(ee).Secondary,
|
|
1332
1320
|
label: a(t)("menu.product.table.bulk_edit.actions.save"),
|
|
1333
1321
|
type: "submit"
|
|
1334
1322
|
}, null, 8, ["borderColor", "textColor", "variant", "label"])])) : M("", !0), g("div", {
|
|
1335
1323
|
ref_key: "tableWrapper",
|
|
1336
|
-
ref:
|
|
1337
|
-
}, [(m(), I(lt(S.value ?
|
|
1324
|
+
ref: Ne
|
|
1325
|
+
}, [(m(), I(lt(S.value ? $t : "div"), {
|
|
1338
1326
|
ref: "fullWrapper",
|
|
1339
1327
|
title: S.value ? a(t)("menu.product.table.bulk_edit.title") : "",
|
|
1340
1328
|
show: S.value,
|
|
@@ -1359,7 +1347,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1359
1347
|
"mt-24": S.value
|
|
1360
1348
|
}),
|
|
1361
1349
|
modelValue: le.value,
|
|
1362
|
-
"onUpdate:modelValue":
|
|
1350
|
+
"onUpdate:modelValue": n[2] || (n[2] = (_) => le.value = _),
|
|
1363
1351
|
"column-defs": ce.value,
|
|
1364
1352
|
"column-visibility": ut.value,
|
|
1365
1353
|
loading: o.isCalculating,
|
|
@@ -1371,7 +1359,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1371
1359
|
"virtual-row-height": S.value ? 48 : 91,
|
|
1372
1360
|
"hide-footer": "",
|
|
1373
1361
|
"pin-header-row": "",
|
|
1374
|
-
onRowClick:
|
|
1362
|
+
onRowClick: n[3] || (n[3] = (_) => S.value ? void 0 : ct(_))
|
|
1375
1363
|
}, null, 8, ["class", "modelValue", "column-defs", "column-visibility", "loading", "page-size", "row-data", "selection", "virtual-row-height"])]),
|
|
1376
1364
|
_: 1
|
|
1377
1365
|
}, 40, ["title", "show", "primary-action", "secondary-actions", "style"]))], 512)])) : (m(), k("div", Ul, [d(be, {
|
|
@@ -1382,13 +1370,13 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1382
1370
|
variant: a(ee).Primary,
|
|
1383
1371
|
label: a(t)("menu.product.table.empty.actions.add"),
|
|
1384
1372
|
"prepend-icon": "add",
|
|
1385
|
-
onClick:
|
|
1373
|
+
onClick: n[4] || (n[4] = (_) => a(f).create(null))
|
|
1386
1374
|
}, null, 8, ["variant", "label"]), d(Ye, null, {
|
|
1387
1375
|
default: T(({
|
|
1388
1376
|
trigger: _
|
|
1389
1377
|
}) => [d(p, {
|
|
1390
|
-
"bg-color": a(
|
|
1391
|
-
"text-color": a(
|
|
1378
|
+
"bg-color": a(W).NeutralGray100,
|
|
1379
|
+
"text-color": a(W).NeutralGray400,
|
|
1392
1380
|
variant: a(ee).Primary,
|
|
1393
1381
|
label: a(t)("menu.product.table.empty.actions.import"),
|
|
1394
1382
|
"prepend-icon": "download",
|
|
@@ -1410,34 +1398,34 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1410
1398
|
}, la = { class: "flex flex-col flex-1 overflow-hidden" }, aa = {
|
|
1411
1399
|
key: 1,
|
|
1412
1400
|
class: "pt-16 xs:pt-8 space-y-24"
|
|
1413
|
-
}, oa = { class: "flex items-center gap-8 px-16" },
|
|
1401
|
+
}, oa = { class: "flex items-center gap-8 px-16" }, pa = /* @__PURE__ */ j({
|
|
1414
1402
|
__name: "Product",
|
|
1415
1403
|
setup(C) {
|
|
1416
|
-
const e = Fe(), i = h(() => e.rules.item),
|
|
1404
|
+
const e = Fe(), i = h(() => e.rules.item), r = ot(), t = h(() => !e.state.currentCatalogId), u = h(() => e.rules.item), l = h(() => !e.state.currentSchedulerId), v = F(!1), f = F(!1), s = h(() => {
|
|
1417
1405
|
var $, P, A, ue;
|
|
1418
1406
|
if (t.value && l.value) return;
|
|
1419
1407
|
if (l.value) {
|
|
1420
1408
|
const L = ($ = e.currentCatalog) == null ? void 0 : $.override.items;
|
|
1421
|
-
return L ? Object.entries(L).reduce((
|
|
1409
|
+
return L ? Object.entries(L).reduce((B, [U, ie]) => {
|
|
1422
1410
|
const E = ie.find((ce) => !ce.combinationKey);
|
|
1423
|
-
return E && (
|
|
1411
|
+
return E && (B[U] = E), B;
|
|
1424
1412
|
}, {}) : {};
|
|
1425
1413
|
}
|
|
1426
|
-
return ((t.value ? (P = e.currentScheduler) == null ? void 0 : P.items : (ue = (A = e.currentCatalog) == null ? void 0 : A.override.scheduler[e.state.currentSchedulerId]) == null ? void 0 : ue.items) ?? []).reduce((L,
|
|
1414
|
+
return ((t.value ? (P = e.currentScheduler) == null ? void 0 : P.items : (ue = (A = e.currentCatalog) == null ? void 0 : A.override.scheduler[e.state.currentSchedulerId]) == null ? void 0 : ue.items) ?? []).reduce((L, B) => (B.combinationKey || (L[B._id] = B), L), {});
|
|
1427
1415
|
}), b = F({}), y = F({}), w = async () => {
|
|
1428
1416
|
var ue, L;
|
|
1429
1417
|
f.value = !0;
|
|
1430
|
-
const R = !!s.value, $ = ge.flatten(Y.value.map((
|
|
1418
|
+
const R = !!s.value, $ = ge.flatten(Y.value.map((B) => B.items)), P = R && v.value ? await Rt(
|
|
1431
1419
|
e.mergedMenu,
|
|
1432
1420
|
$,
|
|
1433
1421
|
e.state.menu,
|
|
1434
1422
|
(ue = e.currentCatalog) == null ? void 0 : ue._id,
|
|
1435
1423
|
(L = e.currentScheduler) == null ? void 0 : L._id,
|
|
1436
1424
|
!1
|
|
1437
|
-
) : void 0, A = $.reduce((
|
|
1425
|
+
) : void 0, A = $.reduce((B, U, ie) => {
|
|
1438
1426
|
var ce, le, X, ye;
|
|
1439
1427
|
const E = (ce = s.value) == null ? void 0 : ce[U._id];
|
|
1440
|
-
return
|
|
1428
|
+
return B[U._id] = {
|
|
1441
1429
|
_id: U._id,
|
|
1442
1430
|
name: U.name,
|
|
1443
1431
|
code: R ? E == null ? void 0 : E.code : U == null ? void 0 : U.code,
|
|
@@ -1452,7 +1440,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1452
1440
|
fallbackCode: (X = P == null ? void 0 : P[ie]) == null ? void 0 : X.code,
|
|
1453
1441
|
fallbackOrder: (ye = P == null ? void 0 : P[ie]) == null ? void 0 : ye.orderFrom,
|
|
1454
1442
|
fallbackTaxes: R ? U.taxes : null
|
|
1455
|
-
},
|
|
1443
|
+
}, B;
|
|
1456
1444
|
}, {});
|
|
1457
1445
|
b.value = A, y.value = { ...A }, f.value = !1;
|
|
1458
1446
|
}, { categories: z, selectedCategories: Y } = Se(), S = F(null);
|
|
@@ -1462,22 +1450,22 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1462
1450
|
tt(async () => {
|
|
1463
1451
|
Y.value && await w();
|
|
1464
1452
|
});
|
|
1465
|
-
function
|
|
1466
|
-
|
|
1453
|
+
function Z() {
|
|
1454
|
+
r.create(null);
|
|
1467
1455
|
}
|
|
1468
|
-
const
|
|
1456
|
+
const ne = () => {
|
|
1469
1457
|
Y.value && w();
|
|
1470
|
-
}, { t: G } = Ie(),
|
|
1458
|
+
}, { t: G } = Ie(), K = h(() => {
|
|
1471
1459
|
var R, $;
|
|
1472
1460
|
return ($ = (R = e.currentCatalog) == null ? void 0 : R.linkItemRules) == null ? void 0 : $.length;
|
|
1473
1461
|
}), {
|
|
1474
1462
|
menuItems: D,
|
|
1475
1463
|
categories: H,
|
|
1476
|
-
linkItemRules:
|
|
1477
|
-
handleSubmit:
|
|
1464
|
+
linkItemRules: J,
|
|
1465
|
+
handleSubmit: re,
|
|
1478
1466
|
catalogManager: Q,
|
|
1479
1467
|
schedulerManager: se
|
|
1480
|
-
} =
|
|
1468
|
+
} = At(!1);
|
|
1481
1469
|
return (R, $) => {
|
|
1482
1470
|
const P = O("fm-button");
|
|
1483
1471
|
return a(z).length ? (m(), k("div", ea, [
|
|
@@ -1491,13 +1479,13 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1491
1479
|
"model-value": b.value,
|
|
1492
1480
|
"original-value": y.value,
|
|
1493
1481
|
"onUpdate:modelValue": $[1] || ($[1] = (A) => b.value = A),
|
|
1494
|
-
"onReset:modelValue":
|
|
1482
|
+
"onReset:modelValue": ne,
|
|
1495
1483
|
"onUpdate:editing": $[2] || ($[2] = (A) => v.value = A)
|
|
1496
1484
|
}, {
|
|
1497
1485
|
filter: T(() => [
|
|
1498
1486
|
d(He, { onToggleAttributeFilter: oe }),
|
|
1499
1487
|
u.value.multiScheduler ? (m(), I(We, { key: 0 })) : M("", !0),
|
|
1500
|
-
|
|
1488
|
+
K.value ? (m(), I(Le, {
|
|
1501
1489
|
key: 1,
|
|
1502
1490
|
"current-restaurant-attr-params": a(e).state.currentRestaurantAttrParams,
|
|
1503
1491
|
onConfirm: $[0] || ($[0] = (A) => a(e).setRestaurantAttrParams(A))
|
|
@@ -1511,7 +1499,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1511
1499
|
g("div", oa, [
|
|
1512
1500
|
d(He),
|
|
1513
1501
|
u.value.multiScheduler ? (m(), I(We, { key: 0 })) : M("", !0),
|
|
1514
|
-
|
|
1502
|
+
K.value ? (m(), I(Le, {
|
|
1515
1503
|
key: 1,
|
|
1516
1504
|
"current-restaurant-attr-params": a(e).state.currentRestaurantAttrParams,
|
|
1517
1505
|
onConfirm: $[3] || ($[3] = (A) => a(e).setRestaurantAttrParams(A))
|
|
@@ -1521,7 +1509,7 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1521
1509
|
key: 0,
|
|
1522
1510
|
action: {
|
|
1523
1511
|
text: a(G)("menu.product.empty.with_create.action"),
|
|
1524
|
-
callback:
|
|
1512
|
+
callback: Z
|
|
1525
1513
|
},
|
|
1526
1514
|
subtitle: a(G)("menu.product.empty.with_create.subtitle"),
|
|
1527
1515
|
title: a(G)("menu.product.empty.with_create.title")
|
|
@@ -1531,16 +1519,16 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1531
1519
|
title: a(G)("menu.product.empty.no_scheduler.title")
|
|
1532
1520
|
}, {
|
|
1533
1521
|
action: T(() => [
|
|
1534
|
-
d(
|
|
1522
|
+
d(qe, {
|
|
1535
1523
|
"categorized-items": a(Q).linkableItems.value,
|
|
1536
1524
|
"initial-value": a(Q).currentItems.value,
|
|
1537
1525
|
"show-variant": !1,
|
|
1538
1526
|
"menu-items": a(D),
|
|
1539
1527
|
categories: a(H),
|
|
1540
|
-
"link-item-rules": a(
|
|
1528
|
+
"link-item-rules": a(J),
|
|
1541
1529
|
"no-scheduler": l.value,
|
|
1542
1530
|
"is-local-only": !0,
|
|
1543
|
-
onSubmit: a(
|
|
1531
|
+
onSubmit: a(re)
|
|
1544
1532
|
}, {
|
|
1545
1533
|
default: T(({ trigger: A }) => [
|
|
1546
1534
|
d(P, {
|
|
@@ -1559,16 +1547,16 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1559
1547
|
title: a(G)("menu.product.empty.with_scheduler.title")
|
|
1560
1548
|
}, {
|
|
1561
1549
|
action: T(() => [
|
|
1562
|
-
d(
|
|
1550
|
+
d(qe, {
|
|
1563
1551
|
"categorized-items": a(se).linkableItems.value,
|
|
1564
1552
|
"initial-value": a(se).currentItems.value,
|
|
1565
1553
|
"show-variant": !1,
|
|
1566
1554
|
"menu-items": a(D),
|
|
1567
1555
|
categories: a(H),
|
|
1568
|
-
"link-item-rules": a(
|
|
1556
|
+
"link-item-rules": a(J),
|
|
1569
1557
|
"no-scheduler": l.value,
|
|
1570
1558
|
"is-local-only": !0,
|
|
1571
|
-
onSubmit: a(
|
|
1559
|
+
onSubmit: a(re)
|
|
1572
1560
|
}, {
|
|
1573
1561
|
default: T(({ trigger: A }) => [
|
|
1574
1562
|
d(P, {
|
|
@@ -1587,5 +1575,5 @@ const Ye = /* @__PURE__ */ N({
|
|
|
1587
1575
|
});
|
|
1588
1576
|
export {
|
|
1589
1577
|
Ye as _,
|
|
1590
|
-
|
|
1578
|
+
pa as a
|
|
1591
1579
|
};
|