@feedmepos/mf-common 1.27.4 → 1.27.6
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/{CustomAttributesForm-1d9add0d.js → CustomAttributesForm-05d5b316.js} +1 -1
- package/dist/ItemSelector-b13afc4e.js +49466 -0
- package/dist/RestaurantSelector-571a07f4.js +242 -0
- package/dist/{app-bab0f0ed.js → app-f8b2e389.js} +188 -42
- package/dist/app.js +26 -25
- package/dist/components/RestaurantSelector.vue.d.ts.map +1 -1
- package/dist/composables/filterSelector.d.ts +1 -1
- package/dist/composables/filterSelector.d.ts.map +1 -1
- package/dist/permission/permission.d.ts +7 -1
- package/dist/permission/permission.d.ts.map +1 -1
- package/dist/permissions.d.ts +1 -1
- package/dist/permissions.d.ts.map +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/ItemSelector-7af4226f.js +0 -25170
- package/dist/RestaurantSelector-c9dc3511.js +0 -231
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
import { ref as S, computed as s, defineComponent as le, mergeModels as te, useModel as ae, watch as U, resolveComponent as C, openBlock as d, createElementBlock as y, createElementVNode as k, createVNode as g, withCtx as z, normalizeClass as ne, toDisplayString as ue, createCommentVNode as $, withModifiers as j, unref as h, isRef as re, Fragment as I, renderList as K, createBlock as P, renderSlot as oe, nextTick as se } from "vue";
|
|
2
|
+
import { t as ie, u as ce, a as ve, O as N, b as de } from "./app-f8b2e389.js";
|
|
3
|
+
import "@feedmepos/ui-library";
|
|
4
|
+
import "pinia";
|
|
5
|
+
import "vue-router";
|
|
6
|
+
function fe(f, e, i = f) {
|
|
7
|
+
const a = S(!0), m = s(() => {
|
|
8
|
+
if (!a.value && !e.value)
|
|
9
|
+
return !0;
|
|
10
|
+
if (e.value && e.value.length > 0) {
|
|
11
|
+
const u = new Set(i.value.map((n) => n.value));
|
|
12
|
+
return e.value.length === i.value.length && e.value.every((n) => u.has(n));
|
|
13
|
+
}
|
|
14
|
+
return !1;
|
|
15
|
+
}), w = s(() => {
|
|
16
|
+
var u, n, p, b;
|
|
17
|
+
return !!((u = e.value) != null && u.length && ((n = e.value) == null ? void 0 : n.length) > 0 && ((p = e.value) == null ? void 0 : p.length) < ((b = f.value) == null ? void 0 : b.length));
|
|
18
|
+
});
|
|
19
|
+
return { allCleared: a, allSelected: m, indeterminate: w, toggleAll: () => {
|
|
20
|
+
if (m.value) {
|
|
21
|
+
e.value = void 0, a.value = !0;
|
|
22
|
+
return;
|
|
23
|
+
}
|
|
24
|
+
const u = i.value.map((n) => n.value);
|
|
25
|
+
u.length === f.value.length ? (e.value = void 0, a.value = !1) : (e.value = u, a.value = !1);
|
|
26
|
+
}, toggleOption: (u) => {
|
|
27
|
+
var p, b, x;
|
|
28
|
+
let n;
|
|
29
|
+
e.value === void 0 && a.value ? n = [u] : e.value === void 0 && !a.value ? n = (p = f.value.map((c) => c.value)) == null ? void 0 : p.filter((c) => c !== u) : (b = e.value) != null && b.includes(u) ? n = (x = e.value) == null ? void 0 : x.filter((c) => c !== u) : n = [...e.value || [], u], n.length === 0 ? (e.value = void 0, a.value = !0) : n.length === f.value.length ? (e.value = void 0, a.value = !1) : e.value = n;
|
|
30
|
+
} };
|
|
31
|
+
}
|
|
32
|
+
const me = { class: "w-full flex flex-col gap-8" }, pe = { class: "flex items-center gap-8" }, ge = { class: "inline-flex items-center" }, he = { class: "flex flex-col w-[360px] min-h-0 gap-8" }, be = { class: "flex gap-4 px-[6px]" }, ye = { class: "flex-1" }, _e = { class: "flex-1 overflow-y-auto min-h-0" }, ke = { key: 0 }, Oe = /* @__PURE__ */ le({
|
|
33
|
+
__name: "RestaurantSelector",
|
|
34
|
+
props: /* @__PURE__ */ te({
|
|
35
|
+
multiple: { type: Boolean, default: !1 },
|
|
36
|
+
excludeRestaurants: {},
|
|
37
|
+
managableOnly: { type: Boolean, default: !0 },
|
|
38
|
+
disabled: { type: Boolean, default: !1 },
|
|
39
|
+
variant: { default: "default" },
|
|
40
|
+
autoSelectFirst: { type: Boolean, default: !1 }
|
|
41
|
+
}, {
|
|
42
|
+
modelValue: {},
|
|
43
|
+
modelModifiers: {}
|
|
44
|
+
}),
|
|
45
|
+
emits: ["update:modelValue"],
|
|
46
|
+
setup(f) {
|
|
47
|
+
const e = f, { t: i } = ie(), a = ae(f, "modelValue"), { restaurants: m, restaurantAttributeSettings: w } = ce();
|
|
48
|
+
function Q(l) {
|
|
49
|
+
const t = m.value.map((_) => {
|
|
50
|
+
var A;
|
|
51
|
+
return (A = _.customAttributes) == null ? void 0 : A[l];
|
|
52
|
+
}).filter((_) => typeof _ == "string" && !!_);
|
|
53
|
+
return [...new Set(t)];
|
|
54
|
+
}
|
|
55
|
+
const E = s(() => w.value.map((l) => {
|
|
56
|
+
const t = Q(l.key);
|
|
57
|
+
return {
|
|
58
|
+
...l,
|
|
59
|
+
values: t
|
|
60
|
+
};
|
|
61
|
+
})), { searchKey: u, filter: n } = ve(), p = S(null);
|
|
62
|
+
function b(l) {
|
|
63
|
+
var t;
|
|
64
|
+
if (e.multiple)
|
|
65
|
+
throw new Error("Single selection is not supported for multiple selection");
|
|
66
|
+
a.value = l, (t = p.value) == null || t.toggleMenu(!1);
|
|
67
|
+
}
|
|
68
|
+
const x = (l) => {
|
|
69
|
+
const { name: t, code: r } = l.profile;
|
|
70
|
+
return {
|
|
71
|
+
label: `${t} (${r ?? "--"})`,
|
|
72
|
+
value: l._id
|
|
73
|
+
};
|
|
74
|
+
}, c = s(() => m.value.map(x)), F = s(
|
|
75
|
+
() => m.value.filter((l) => e.managableOnly ? l.managable : !0).filter((l) => e.multiple ? !0 : N(l.customAttributes || {}, v.value)).map(x).filter(({ label: l }) => n([l])).filter((l) => {
|
|
76
|
+
var t;
|
|
77
|
+
return !((t = e.excludeRestaurants) != null && t.includes(l.value));
|
|
78
|
+
})
|
|
79
|
+
), T = s(() => {
|
|
80
|
+
var l;
|
|
81
|
+
return a.value ? a.value.length === 1 ? (l = c.value.find((t) => {
|
|
82
|
+
var r;
|
|
83
|
+
return t.value === ((r = a.value) == null ? void 0 : r[0]);
|
|
84
|
+
})) == null ? void 0 : l.label : i("portalshell.components.restaurantSelector.restaurantCount", {
|
|
85
|
+
count: a.value.length
|
|
86
|
+
}) : i("portalshell.components.restaurantSelector.allRestaurants");
|
|
87
|
+
}), W = s(() => {
|
|
88
|
+
var l;
|
|
89
|
+
return a.value ? ((l = c.value.find((t) => t.value === a.value)) == null ? void 0 : l.label) || i("portalshell.components.restaurantSelector.unknownRestaurant") : i("portalshell.components.restaurantSelector.selectRestaurant");
|
|
90
|
+
}), L = s(() => e.multiple ? T.value : W.value), O = s(() => e.disabled ? "neutral-gray-200" : e.variant === "dark" ? "neutral-black" : "neutral-gray-400"), q = s(() => e.disabled ? "text-fm-color-neutral-gray-200" : e.variant === "dark" ? "text-fm-color-neutral-black" : "text-fm-color-neutral-gray-400"), { allSelected: D, toggleAll: G, toggleOption: H, indeterminate: J } = fe(
|
|
91
|
+
c,
|
|
92
|
+
a,
|
|
93
|
+
F
|
|
94
|
+
), V = S(!1), X = s(() => w.value.length > 0), R = S(null);
|
|
95
|
+
async function Y() {
|
|
96
|
+
e.disabled || (V.value ? V.value = !1 : (V.value = !0, await se(), R.value && R.value.toggleProperty(!0)));
|
|
97
|
+
}
|
|
98
|
+
const v = S((() => ({
|
|
99
|
+
logic: "AND",
|
|
100
|
+
rules: []
|
|
101
|
+
}))()), Z = s(() => {
|
|
102
|
+
var l, t;
|
|
103
|
+
return ((t = (l = v.value) == null ? void 0 : l.rules) == null ? void 0 : t.length) || 0;
|
|
104
|
+
});
|
|
105
|
+
return U(
|
|
106
|
+
v,
|
|
107
|
+
() => {
|
|
108
|
+
var l;
|
|
109
|
+
if (e.multiple) {
|
|
110
|
+
if (!v.value || v.value.rules.length === 0) {
|
|
111
|
+
a.value = null;
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
const t = m.value.filter((r) => N(r.customAttributes || {}, v.value));
|
|
115
|
+
a.value = t.map((r) => r._id);
|
|
116
|
+
} else {
|
|
117
|
+
const t = m.value.filter((r) => N(r.customAttributes || {}, v.value));
|
|
118
|
+
t.length === 0 ? a.value = null : a.value = (l = t[0]) == null ? void 0 : l._id;
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
deep: !0
|
|
123
|
+
}
|
|
124
|
+
), U(
|
|
125
|
+
[() => e.autoSelectFirst, F],
|
|
126
|
+
([l, t]) => {
|
|
127
|
+
l && t.length > 0 && !a.value && (a.value = t[0].value);
|
|
128
|
+
},
|
|
129
|
+
{ immediate: !0 }
|
|
130
|
+
), (l, t) => {
|
|
131
|
+
const r = C("FmIcon"), _ = C("FmChip"), A = C("FmSearch"), M = C("FmMenuItem"), ee = C("FmMenu");
|
|
132
|
+
return d(), y("div", me, [
|
|
133
|
+
k("div", pe, [
|
|
134
|
+
g(ee, {
|
|
135
|
+
"close-on-click": !1,
|
|
136
|
+
disabled: e.disabled,
|
|
137
|
+
ref_key: "menuRef",
|
|
138
|
+
ref: p,
|
|
139
|
+
"z-index": 50,
|
|
140
|
+
"selector-for-dismiss-away-event-exclusion": ".fm-dialog, .fm-select__menu__wrapper"
|
|
141
|
+
}, {
|
|
142
|
+
"menu-button": z(() => [
|
|
143
|
+
k("div", ge, [
|
|
144
|
+
g(_, {
|
|
145
|
+
disabled: e.disabled
|
|
146
|
+
}, {
|
|
147
|
+
default: z(() => [
|
|
148
|
+
g(r, {
|
|
149
|
+
color: O.value,
|
|
150
|
+
name: "storefront",
|
|
151
|
+
outline: "",
|
|
152
|
+
size: "sm"
|
|
153
|
+
}, null, 8, ["color"]),
|
|
154
|
+
L.value ? (d(), y("div", {
|
|
155
|
+
key: 0,
|
|
156
|
+
class: ne([
|
|
157
|
+
"fm-typo-en-body-md-600 select-none text-ellipsis overflow-hidden whitespace-nowrap",
|
|
158
|
+
q.value
|
|
159
|
+
])
|
|
160
|
+
}, ue(L.value), 3)) : $("", !0),
|
|
161
|
+
g(r, {
|
|
162
|
+
color: O.value,
|
|
163
|
+
name: "keyboard_arrow_down",
|
|
164
|
+
size: "sm"
|
|
165
|
+
}, null, 8, ["color"]),
|
|
166
|
+
X.value ? (d(), y("div", {
|
|
167
|
+
key: 1,
|
|
168
|
+
class: "pl-8 flex items-center justify-center border-l border-fm-color-neutral-gray-200",
|
|
169
|
+
onClick: j(Y, ["stop"])
|
|
170
|
+
}, [
|
|
171
|
+
g(r, {
|
|
172
|
+
name: "filter_alt",
|
|
173
|
+
size: "sm",
|
|
174
|
+
outline: Z.value === 0,
|
|
175
|
+
color: O.value,
|
|
176
|
+
onClick: t[0] || (t[0] = j(() => {
|
|
177
|
+
}, ["prevent"]))
|
|
178
|
+
}, null, 8, ["outline", "color"])
|
|
179
|
+
])) : $("", !0)
|
|
180
|
+
]),
|
|
181
|
+
_: 1
|
|
182
|
+
}, 8, ["disabled"])
|
|
183
|
+
])
|
|
184
|
+
]),
|
|
185
|
+
default: z(() => [
|
|
186
|
+
k("div", he, [
|
|
187
|
+
k("div", be, [
|
|
188
|
+
k("div", ye, [
|
|
189
|
+
g(A, {
|
|
190
|
+
modelValue: h(u),
|
|
191
|
+
"onUpdate:modelValue": t[1] || (t[1] = (o) => re(u) ? u.value = o : null),
|
|
192
|
+
placeholder: h(i)("common.search")
|
|
193
|
+
}, null, 8, ["modelValue", "placeholder"])
|
|
194
|
+
])
|
|
195
|
+
]),
|
|
196
|
+
k("div", _e, [
|
|
197
|
+
l.multiple ? (d(), y(I, { key: 0 }, [
|
|
198
|
+
g(M, {
|
|
199
|
+
label: "All",
|
|
200
|
+
"has-checkbox": "",
|
|
201
|
+
"model-value": h(D),
|
|
202
|
+
indeterminate: h(J),
|
|
203
|
+
onClick: h(G)
|
|
204
|
+
}, null, 8, ["model-value", "indeterminate", "onClick"]),
|
|
205
|
+
(d(!0), y(I, null, K(F.value, (o) => {
|
|
206
|
+
var B;
|
|
207
|
+
return d(), P(M, {
|
|
208
|
+
key: o.value,
|
|
209
|
+
label: o.label,
|
|
210
|
+
"has-checkbox": "",
|
|
211
|
+
"model-value": h(D) || ((B = a.value) == null ? void 0 : B.includes(o.value)),
|
|
212
|
+
onClick: (Ce) => h(H)(o.value)
|
|
213
|
+
}, null, 8, ["label", "model-value", "onClick"]);
|
|
214
|
+
}), 128))
|
|
215
|
+
], 64)) : (d(!0), y(I, { key: 1 }, K(F.value, (o) => (d(), P(M, {
|
|
216
|
+
key: o.value,
|
|
217
|
+
label: o.label,
|
|
218
|
+
onClick: (B) => b(o.value)
|
|
219
|
+
}, null, 8, ["label", "onClick"]))), 128))
|
|
220
|
+
])
|
|
221
|
+
])
|
|
222
|
+
]),
|
|
223
|
+
_: 1
|
|
224
|
+
}, 8, ["disabled"]),
|
|
225
|
+
oe(l.$slots, "append-right")
|
|
226
|
+
]),
|
|
227
|
+
V.value ? (d(), y("div", ke, [
|
|
228
|
+
g(h(de), {
|
|
229
|
+
ref_key: "filterRef",
|
|
230
|
+
ref: R,
|
|
231
|
+
attributes: E.value,
|
|
232
|
+
modelValue: v.value,
|
|
233
|
+
"onUpdate:modelValue": t[2] || (t[2] = (o) => v.value = o)
|
|
234
|
+
}, null, 8, ["attributes", "modelValue"])
|
|
235
|
+
])) : $("", !0)
|
|
236
|
+
]);
|
|
237
|
+
};
|
|
238
|
+
}
|
|
239
|
+
});
|
|
240
|
+
export {
|
|
241
|
+
Oe as default
|
|
242
|
+
};
|
|
@@ -47006,12 +47006,158 @@ var yu;
|
|
|
47006
47006
|
})(o.Feedme || (o.Feedme = {})), ((i) => {
|
|
47007
47007
|
i.quota = "quota", i.owner = "owner";
|
|
47008
47008
|
})(o.FeedmeBusinessField || (o.FeedmeBusinessField = {})), ((i) => {
|
|
47009
|
-
i.profile = "business::profile", i.restaurant = "business::restaurant", i.menu = "business::menu", i.promotion = "business::promotion", i.voucher = "business::voucher", i.membership = "business::membership", i.stock = "business::stock", i.permission = "business::permission", i.role = "business::role", i.wastageTemplate = "business::wastageTemplate", i.closingTemplate = "business::closingTemplate", i.orderTemplate = "business::orderTemplate", i.ingredient = "business::ingredient";
|
|
47009
|
+
i.profile = "business::profile", i.restaurant = "business::restaurant", i.menu = "business::menu", i.promotion = "business::promotion", i.voucher = "business::voucher", i.membership = "business::membership", i.stock = "business::stock", i.permission = "business::permission", i.role = "business::role", i.wastageTemplate = "business::wastageTemplate", i.closingTemplate = "business::closingTemplate", i.orderTemplate = "business::orderTemplate", i.ingredient = "business::ingredient", i.recipe = "business::recipe", i.unit = "business::unit", i.supplier = "business::supplier", i.warehouse = "business::warehouse", i.publish = "business::publish", i.integration = "business::integration";
|
|
47010
47010
|
})(o.Business || (o.Business = {})), ((i) => {
|
|
47011
47011
|
i.restaurant = "restaurant";
|
|
47012
47012
|
})(o.Restaurant || (o.Restaurant = {}));
|
|
47013
47013
|
})(l.Subject || (l.Subject = {}));
|
|
47014
47014
|
})(yu || (yu = {}));
|
|
47015
|
+
const fx = {
|
|
47016
|
+
menu: {
|
|
47017
|
+
label: "Menu Management",
|
|
47018
|
+
subject: "business::menu",
|
|
47019
|
+
actions: [
|
|
47020
|
+
"manage"
|
|
47021
|
+
/* manage */
|
|
47022
|
+
]
|
|
47023
|
+
},
|
|
47024
|
+
stock: {
|
|
47025
|
+
label: "Stock Management",
|
|
47026
|
+
subject: "business::stock",
|
|
47027
|
+
actions: [
|
|
47028
|
+
"manage"
|
|
47029
|
+
/* manage */
|
|
47030
|
+
]
|
|
47031
|
+
},
|
|
47032
|
+
promotion: {
|
|
47033
|
+
label: "Promotion Management",
|
|
47034
|
+
subject: "business::promotion",
|
|
47035
|
+
actions: [
|
|
47036
|
+
"manage"
|
|
47037
|
+
/* manage */
|
|
47038
|
+
]
|
|
47039
|
+
},
|
|
47040
|
+
voucher: {
|
|
47041
|
+
label: "Voucher Management",
|
|
47042
|
+
subject: "business::voucher",
|
|
47043
|
+
actions: [
|
|
47044
|
+
"manage"
|
|
47045
|
+
/* manage */
|
|
47046
|
+
]
|
|
47047
|
+
},
|
|
47048
|
+
membership: {
|
|
47049
|
+
label: "Membership Management",
|
|
47050
|
+
subject: "business::membership",
|
|
47051
|
+
actions: [
|
|
47052
|
+
"manage"
|
|
47053
|
+
/* manage */
|
|
47054
|
+
]
|
|
47055
|
+
},
|
|
47056
|
+
permission: {
|
|
47057
|
+
label: "Team Management",
|
|
47058
|
+
subject: "business::permission",
|
|
47059
|
+
actions: [
|
|
47060
|
+
"manage"
|
|
47061
|
+
/* manage */
|
|
47062
|
+
]
|
|
47063
|
+
},
|
|
47064
|
+
restaurant: {
|
|
47065
|
+
label: "Restaurant Owner",
|
|
47066
|
+
subject: "business::restaurant",
|
|
47067
|
+
actions: [
|
|
47068
|
+
"manage"
|
|
47069
|
+
/* manage */
|
|
47070
|
+
]
|
|
47071
|
+
},
|
|
47072
|
+
role: {
|
|
47073
|
+
label: "Role Management",
|
|
47074
|
+
subject: "business::role",
|
|
47075
|
+
actions: [
|
|
47076
|
+
"manage"
|
|
47077
|
+
/* manage */
|
|
47078
|
+
]
|
|
47079
|
+
},
|
|
47080
|
+
wastageTemplate: {
|
|
47081
|
+
label: "Wastage Template Management",
|
|
47082
|
+
subject: "business::wastageTemplate",
|
|
47083
|
+
actions: [
|
|
47084
|
+
"manage"
|
|
47085
|
+
/* manage */
|
|
47086
|
+
]
|
|
47087
|
+
},
|
|
47088
|
+
closingTemplate: {
|
|
47089
|
+
label: "Closing Template Management",
|
|
47090
|
+
subject: "business::closingTemplate",
|
|
47091
|
+
actions: [
|
|
47092
|
+
"manage"
|
|
47093
|
+
/* manage */
|
|
47094
|
+
]
|
|
47095
|
+
},
|
|
47096
|
+
orderTemplate: {
|
|
47097
|
+
label: "Order Template Management",
|
|
47098
|
+
subject: "business::orderTemplate",
|
|
47099
|
+
actions: [
|
|
47100
|
+
"manage"
|
|
47101
|
+
/* manage */
|
|
47102
|
+
]
|
|
47103
|
+
},
|
|
47104
|
+
ingredient: {
|
|
47105
|
+
label: "Ingredient Management",
|
|
47106
|
+
subject: "business::ingredient",
|
|
47107
|
+
actions: [
|
|
47108
|
+
"manage"
|
|
47109
|
+
/* manage */
|
|
47110
|
+
]
|
|
47111
|
+
},
|
|
47112
|
+
recipe: {
|
|
47113
|
+
label: "Recipe Management",
|
|
47114
|
+
subject: "business::recipe",
|
|
47115
|
+
actions: [
|
|
47116
|
+
"manage"
|
|
47117
|
+
/* manage */
|
|
47118
|
+
]
|
|
47119
|
+
},
|
|
47120
|
+
unit: {
|
|
47121
|
+
label: "Unit Management",
|
|
47122
|
+
subject: "business::unit",
|
|
47123
|
+
actions: [
|
|
47124
|
+
"manage"
|
|
47125
|
+
/* manage */
|
|
47126
|
+
]
|
|
47127
|
+
},
|
|
47128
|
+
supplier: {
|
|
47129
|
+
label: "Supplier Management",
|
|
47130
|
+
subject: "business::supplier",
|
|
47131
|
+
actions: [
|
|
47132
|
+
"manage"
|
|
47133
|
+
/* manage */
|
|
47134
|
+
]
|
|
47135
|
+
},
|
|
47136
|
+
warehouse: {
|
|
47137
|
+
label: "Warehouse Management",
|
|
47138
|
+
subject: "business::warehouse",
|
|
47139
|
+
actions: [
|
|
47140
|
+
"manage"
|
|
47141
|
+
/* manage */
|
|
47142
|
+
]
|
|
47143
|
+
},
|
|
47144
|
+
publish: {
|
|
47145
|
+
label: "Publish Management",
|
|
47146
|
+
subject: "business::publish",
|
|
47147
|
+
actions: [
|
|
47148
|
+
"manage"
|
|
47149
|
+
/* manage */
|
|
47150
|
+
]
|
|
47151
|
+
},
|
|
47152
|
+
integration: {
|
|
47153
|
+
label: "Integration Management",
|
|
47154
|
+
subject: "business::integration",
|
|
47155
|
+
actions: [
|
|
47156
|
+
"manage"
|
|
47157
|
+
/* manage */
|
|
47158
|
+
]
|
|
47159
|
+
}
|
|
47160
|
+
};
|
|
47015
47161
|
async function $B(l) {
|
|
47016
47162
|
const { sessionUser: o, validationManifest: i } = l, { requiredRoles: u, requiredCaslPermissions: R, customValidationFunction: m } = i;
|
|
47017
47163
|
if (!o)
|
|
@@ -47057,9 +47203,9 @@ async function _B(l) {
|
|
|
47057
47203
|
canAccess: !0
|
|
47058
47204
|
};
|
|
47059
47205
|
}
|
|
47060
|
-
function fx(l) {
|
|
47061
|
-
}
|
|
47062
47206
|
function yx(l) {
|
|
47207
|
+
}
|
|
47208
|
+
function zx(l) {
|
|
47063
47209
|
return {
|
|
47064
47210
|
render: () => du(KB, {}, { default: () => du(l) })
|
|
47065
47211
|
};
|
|
@@ -49418,7 +49564,7 @@ const kO = /* @__PURE__ */ Ad(SO, [["__scopeId", "data-v-318fbbc5"]]), fO = { cl
|
|
|
49418
49564
|
])
|
|
49419
49565
|
], 64));
|
|
49420
49566
|
}
|
|
49421
|
-
}),
|
|
49567
|
+
}), Qx = /* @__PURE__ */ Pt({
|
|
49422
49568
|
__name: "App",
|
|
49423
49569
|
props: {
|
|
49424
49570
|
hideAppDrawer: { type: Boolean }
|
|
@@ -49484,11 +49630,11 @@ const kO = /* @__PURE__ */ Ad(SO, [["__scopeId", "data-v-318fbbc5"]]), fO = { cl
|
|
|
49484
49630
|
_: 3
|
|
49485
49631
|
}, 8, ["dropdown-opened", "apps", "businesses", "countries", "current-app", "current-business", "current-country", "user", "embedded", "hide-app-drawer"]));
|
|
49486
49632
|
}
|
|
49487
|
-
}),
|
|
49488
|
-
() => import("./CustomAttributesForm-
|
|
49489
|
-
),
|
|
49490
|
-
() => import("./RestaurantSelector-
|
|
49491
|
-
),
|
|
49633
|
+
}), gx = JN(
|
|
49634
|
+
() => import("./CustomAttributesForm-05d5b316.js")
|
|
49635
|
+
), vx = JN(
|
|
49636
|
+
() => import("./RestaurantSelector-571a07f4.js")
|
|
49637
|
+
), Yx = JN(() => import("./ItemSelector-b13afc4e.js")), zO = {
|
|
49492
49638
|
yes: "Yes",
|
|
49493
49639
|
no: "No",
|
|
49494
49640
|
ok: "OK",
|
|
@@ -50354,7 +50500,7 @@ const kO = /* @__PURE__ */ Ad(SO, [["__scopeId", "data-v-318fbbc5"]]), fO = { cl
|
|
|
50354
50500
|
"th-TH": { ...XO, ...vO },
|
|
50355
50501
|
"zh-Hant": { ...PO, ...jO }
|
|
50356
50502
|
};
|
|
50357
|
-
function
|
|
50503
|
+
function Jx(l) {
|
|
50358
50504
|
if (l.messages)
|
|
50359
50505
|
for (const o of KO) {
|
|
50360
50506
|
const i = l.messages[o] || {};
|
|
@@ -50365,7 +50511,7 @@ function Yx(l) {
|
|
|
50365
50511
|
}
|
|
50366
50512
|
return _g(l);
|
|
50367
50513
|
}
|
|
50368
|
-
function
|
|
50514
|
+
function Gx(l, o, i) {
|
|
50369
50515
|
l && o && i && /^GTM-[0-9A-Z]+$/.test(i.id) ? l.use(
|
|
50370
50516
|
sv({
|
|
50371
50517
|
id: i.id,
|
|
@@ -50378,7 +50524,7 @@ function Jx(l, o, i) {
|
|
|
50378
50524
|
})
|
|
50379
50525
|
) : console.log("skipped init vue client monitoring");
|
|
50380
50526
|
}
|
|
50381
|
-
function
|
|
50527
|
+
function jx(l) {
|
|
50382
50528
|
l.beforeEach((o, i) => {
|
|
50383
50529
|
const u = i.query.country || o.query.country || ua.getCountry(), R = i.query.businessId || o.query.businessId || ua.getBusinessId(), m = i.query.restaurantId || o.query.restaurantId || ua.getRestaurantId();
|
|
50384
50530
|
if (R || u) {
|
|
@@ -50399,7 +50545,7 @@ function Gx(l) {
|
|
|
50399
50545
|
});
|
|
50400
50546
|
}
|
|
50401
50547
|
const QT = "fm-post-message-request", zN = "fm-post-message-response";
|
|
50402
|
-
function
|
|
50548
|
+
function Bx({
|
|
50403
50549
|
targetWindow: l,
|
|
50404
50550
|
methodName: o,
|
|
50405
50551
|
params: i = [],
|
|
@@ -50452,59 +50598,59 @@ async function vT(l) {
|
|
|
50452
50598
|
});
|
|
50453
50599
|
}
|
|
50454
50600
|
}
|
|
50455
|
-
function
|
|
50601
|
+
function Dx(l, o) {
|
|
50456
50602
|
gT[l] = o;
|
|
50457
50603
|
}
|
|
50458
50604
|
let QN = !1;
|
|
50459
|
-
function
|
|
50605
|
+
function wx() {
|
|
50460
50606
|
QN || (window.addEventListener("message", vT), QN = !0);
|
|
50461
50607
|
}
|
|
50462
|
-
function
|
|
50608
|
+
function Ox() {
|
|
50463
50609
|
window.removeEventListener("message", vT), QN = !1;
|
|
50464
50610
|
}
|
|
50465
50611
|
export {
|
|
50466
50612
|
$O as A,
|
|
50467
|
-
|
|
50468
|
-
|
|
50613
|
+
Jx as B,
|
|
50614
|
+
gx as C,
|
|
50469
50615
|
eD as D,
|
|
50470
50616
|
WB as E,
|
|
50471
50617
|
Tn as F,
|
|
50472
50618
|
IV as G,
|
|
50473
50619
|
QT as H,
|
|
50474
|
-
|
|
50620
|
+
Yx as I,
|
|
50475
50621
|
zN as J,
|
|
50476
|
-
|
|
50477
|
-
|
|
50478
|
-
|
|
50479
|
-
|
|
50622
|
+
Bx as K,
|
|
50623
|
+
Dx as L,
|
|
50624
|
+
wx as M,
|
|
50625
|
+
Ox as N,
|
|
50480
50626
|
bx as O,
|
|
50481
50627
|
yu as P,
|
|
50482
|
-
|
|
50628
|
+
vx as R,
|
|
50483
50629
|
KB as _,
|
|
50484
50630
|
B9 as a,
|
|
50485
50631
|
Ex as b,
|
|
50486
50632
|
a0 as c,
|
|
50487
|
-
|
|
50488
|
-
|
|
50489
|
-
|
|
50490
|
-
|
|
50491
|
-
|
|
50492
|
-
|
|
50493
|
-
|
|
50494
|
-
|
|
50633
|
+
_e as d,
|
|
50634
|
+
Qt as e,
|
|
50635
|
+
_n as f,
|
|
50636
|
+
hr as g,
|
|
50637
|
+
VG as h,
|
|
50638
|
+
Tx as i,
|
|
50639
|
+
sT as j,
|
|
50640
|
+
Gx as k,
|
|
50495
50641
|
pe as l,
|
|
50496
|
-
|
|
50497
|
-
|
|
50642
|
+
UG as m,
|
|
50643
|
+
jx as n,
|
|
50498
50644
|
Wx as o,
|
|
50499
|
-
|
|
50500
|
-
|
|
50501
|
-
|
|
50502
|
-
|
|
50645
|
+
Q0 as p,
|
|
50646
|
+
Mx as q,
|
|
50647
|
+
WT as r,
|
|
50648
|
+
Sx as s,
|
|
50503
50649
|
gn as t,
|
|
50504
50650
|
Sn as u,
|
|
50505
|
-
|
|
50506
|
-
|
|
50651
|
+
kx as v,
|
|
50652
|
+
yx as w,
|
|
50507
50653
|
fx as x,
|
|
50508
|
-
|
|
50509
|
-
|
|
50654
|
+
zx as y,
|
|
50655
|
+
Qx as z
|
|
50510
50656
|
};
|
package/dist/app.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { C as u, E as
|
|
1
|
+
import { p as s } from "./app-f8b2e389.js";
|
|
2
|
+
import { C as u, E as m, r as M, H as E, J as P, F as S, z as p, h as c, I as d, P as g, _ as C, R as _, g as h, K as F, B as R, m as A, x as y, A as O, k as I, i as L, n as T, M as b, w as G, s as N, v as Q, o as U, L as f, D as w, N as x, u as B, j as D, q as Y, t as v, G as z, y as V } from "./app-f8b2e389.js";
|
|
3
3
|
import "pinia";
|
|
4
4
|
import "vue";
|
|
5
5
|
import "vue-router";
|
|
@@ -8,37 +8,38 @@ const r = s.Dinero;
|
|
|
8
8
|
export {
|
|
9
9
|
u as CustomAttributesForm,
|
|
10
10
|
r as Dinero,
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
m as EMPTY_MONGO_QUERY,
|
|
12
|
+
M as EMPTY_RULE,
|
|
13
13
|
E as FM_POST_MESSAGE_REQUEST,
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
P as FM_POST_MESSAGE_RESPONSE,
|
|
15
|
+
S as FeedMeAuth,
|
|
16
|
+
p as FmNavBar,
|
|
17
|
+
c as FmpUser,
|
|
18
|
+
d as ItemSelector,
|
|
19
|
+
g as Permission,
|
|
20
|
+
C as PermissionWrapper,
|
|
21
|
+
_ as RestaurantSelector,
|
|
22
22
|
h as baseClientInstance,
|
|
23
23
|
F as callMethodOnWindow,
|
|
24
24
|
R as createFeedMeI18n,
|
|
25
25
|
A as detectLocale,
|
|
26
|
-
y as
|
|
27
|
-
O as
|
|
28
|
-
I as
|
|
29
|
-
L as
|
|
30
|
-
T as
|
|
31
|
-
b as
|
|
32
|
-
G as
|
|
33
|
-
N as
|
|
34
|
-
Q as
|
|
35
|
-
U as
|
|
26
|
+
y as fullPermission,
|
|
27
|
+
O as i18nMessages,
|
|
28
|
+
I as initVueClientMonitoring,
|
|
29
|
+
L as initialize,
|
|
30
|
+
T as installBusinessQueryStatePlugin,
|
|
31
|
+
b as installPostMessageMethodCall,
|
|
32
|
+
G as installRouteValidation,
|
|
33
|
+
N as isEmptyMongoQuery,
|
|
34
|
+
Q as isEmptyRule,
|
|
35
|
+
U as onAuthStateChanged,
|
|
36
|
+
f as registerPostMessageMethod,
|
|
36
37
|
w as setEnabledLocales,
|
|
37
38
|
x as uninstallPostMessageMethodCall,
|
|
38
39
|
B as useCoreStore,
|
|
39
40
|
D as useCountry,
|
|
40
41
|
Y as useCustomAttributes,
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
v as useI18n,
|
|
43
|
+
z as useLocale,
|
|
44
|
+
V as withPermission
|
|
44
45
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RestaurantSelector.vue.d.ts","sourceRoot":"","sources":["../../../src/components/RestaurantSelector.vue.ts"],"names":[],"mappings":"AAkBA,MAAM,WAAW,KAAK;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"RestaurantSelector.vue.d.ts","sourceRoot":"","sources":["../../../src/components/RestaurantSelector.vue.ts"],"names":[],"mappings":"AAkBA,MAAM,WAAW,KAAK;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyjBD,wBAAwG;AAUxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
|
|
@@ -2,7 +2,7 @@ import { type Ref } from "vue";
|
|
|
2
2
|
interface Option<T> {
|
|
3
3
|
value: T;
|
|
4
4
|
}
|
|
5
|
-
export declare function useFilterSelector<T>(options: Ref<Option<T>[]>, model: Ref<T[] | undefined | null>): {
|
|
5
|
+
export declare function useFilterSelector<T>(options: Ref<Option<T>[]>, model: Ref<T[] | undefined | null>, filteredOptions?: Ref<Option<T>[]>): {
|
|
6
6
|
allCleared: Ref<boolean, boolean>;
|
|
7
7
|
allSelected: import("vue").ComputedRef<boolean>;
|
|
8
8
|
indeterminate: import("vue").ComputedRef<boolean>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filterSelector.d.ts","sourceRoot":"","sources":["../../../src/composables/filterSelector.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAE7C,UAAU,MAAM,CAAC,CAAC;IAChB,KAAK,EAAE,CAAC,CAAA;CACT;AAED,wBAAgB,iBAAiB,CAAC,CAAC,
|
|
1
|
+
{"version":3,"file":"filterSelector.d.ts","sourceRoot":"","sources":["../../../src/composables/filterSelector.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAE7C,UAAU,MAAM,CAAC,CAAC;IAChB,KAAK,EAAE,CAAC,CAAA;CACT;AAED,wBAAgB,iBAAiB,CAAC,CAAC,EACjC,OAAO,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,EACzB,KAAK,EAAE,GAAG,CAAC,CAAC,EAAE,GAAG,SAAS,GAAG,IAAI,CAAC,EAClC,eAAe,GAAE,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAW;;;;;0BA8Cd,CAAC;EAwB/B"}
|
|
@@ -41,7 +41,13 @@ export declare namespace Permission.Subject {
|
|
|
41
41
|
wastageTemplate = "business::wastageTemplate",
|
|
42
42
|
closingTemplate = "business::closingTemplate",
|
|
43
43
|
orderTemplate = "business::orderTemplate",
|
|
44
|
-
ingredient = "business::ingredient"
|
|
44
|
+
ingredient = "business::ingredient",
|
|
45
|
+
recipe = "business::recipe",
|
|
46
|
+
unit = "business::unit",
|
|
47
|
+
supplier = "business::supplier",
|
|
48
|
+
warehouse = "business::warehouse",
|
|
49
|
+
publish = "business::publish",
|
|
50
|
+
integration = "business::integration"
|
|
45
51
|
}
|
|
46
52
|
enum Restaurant {
|
|
47
53
|
restaurant = "restaurant"
|