@feedmepos/mf-report 5.22.23 → 5.22.24
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-Zn-puM1b.js → App-vJDVOth7.js} +5 -5
- package/dist/{BaseDialog.vue_vue_type_script_setup_true_lang-CpoV8rC8.js → BaseDialog.vue_vue_type_script_setup_true_lang-CuDpyny4.js} +636 -623
- package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-B5vOl_Qi.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-DFIMIp0w.js} +2 -2
- package/dist/{Default.vue_vue_type_script_setup_true_lang-B4qeIU-5.js → Default.vue_vue_type_script_setup_true_lang-yPwz9xco.js} +2 -2
- package/dist/{FilterSelector.vue_vue_type_script_setup_true_lang-pbAzVGA4.js → FilterSelector.vue_vue_type_script_setup_true_lang-BcODTyl7.js} +6 -6
- package/dist/InsightView-DNa3QEKr.js +670 -0
- package/dist/{Integration-DSpComdb.js → Integration-B8bI4Prk.js} +4 -4
- package/dist/{Integrations-DWsnA_ad.js → Integrations-BlVASP74.js} +4 -4
- package/dist/Layout-DW47sZuO.js +29 -0
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-Dg6agPDE.js → MenuTab.vue_vue_type_script_setup_true_lang-rtidppHZ.js} +5 -5
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-CJXAXP9k.js → NavigationTab.vue_vue_type_script_setup_true_lang-Bzc3bo-E.js} +5 -5
- package/dist/{NoData.vue_vue_type_script_setup_true_lang-BeANsyve.js → NoData.vue_vue_type_script_setup_true_lang-DaoGO26M.js} +1 -1
- package/dist/NoPermission.vue_vue_type_script_setup_true_lang-G3Os8ZFD.js +25 -0
- package/dist/OverviewView-qupMQGx3.js +67 -0
- package/dist/{Report-C3KsOYeU.js → Report-BZXMhOBE.js} +4 -4
- package/dist/{ReportEditor-CtgWwf3_.js → ReportEditor-gtLvhWsX.js} +6 -6
- package/dist/{ReportView-DfU2sOC5.js → ReportView-OKevCUGl.js} +8 -8
- package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang--GXm-kRc.js → SelectComponent.vue_vue_type_script_setup_true_lang-CPVvQ97s.js} +1 -1
- package/dist/Setting-CwZBJq6_.js +328 -0
- package/dist/{TileEditor-RhXE0gx2.js → TileEditor-DC0MmQ9i.js} +8 -8
- package/dist/{TransitionFade-rhvb0xo6.js → TransitionFade-Wch1EA34.js} +6 -6
- package/dist/{app-Bk5L2zfK.js → app--_wgvJ4h.js} +15 -11
- package/dist/app.js +1 -1
- package/dist/{useRestaurantPermission-CUzN375q.js → useRestaurantPermission-owy2OAuf.js} +1 -1
- package/dist/{vue-i18n-BGJaPUEy.js → vue-i18n-CsqQ6wm5.js} +1010 -1009
- package/package.json +2 -2
- package/dist/InsightView-CmNgn19R.js +0 -662
- package/dist/Layout-DnvPqfQI.js +0 -19
- package/dist/OverviewView-B_x6fZFf.js +0 -62
- package/dist/Setting-B2oXF461.js +0 -324
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import { defineComponent as k, computed as w, resolveComponent as $, createBlock as n, openBlock as t, withCtx as y, createVNode as d, createElementVNode as h, unref as e, normalizeStyle as C, normalizeClass as u, createElementBlock as _, Fragment as b, renderList as B } from "vue";
|
|
2
|
-
import { _ as F } from "./FilterSelector.vue_vue_type_script_setup_true_lang-pbAzVGA4.js";
|
|
3
|
-
import { _ as L } from "./Default.vue_vue_type_script_setup_true_lang-B4qeIU-5.js";
|
|
4
|
-
import { a as P } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CpoV8rC8.js";
|
|
5
|
-
import { storeToRefs as R } from "pinia";
|
|
6
|
-
import { _ as S } from "./NoData.vue_vue_type_script_setup_true_lang-BeANsyve.js";
|
|
7
|
-
import { useBreakpoints as V } from "@feedmepos/ui-library";
|
|
8
|
-
import { _ as z } from "./MenuTab.vue_vue_type_script_setup_true_lang-Dg6agPDE.js";
|
|
9
|
-
import { useI18n as D } from "@feedmepos/mf-common";
|
|
10
|
-
import { r as E } from "./i18n-CI_sQ5d_.js";
|
|
11
|
-
const M = /* @__PURE__ */ k({
|
|
12
|
-
__name: "OverviewView",
|
|
13
|
-
setup(H) {
|
|
14
|
-
const { t: l, te: f } = D(), v = P(), { breakpoints: o } = V(), { isOpenDownloadDialog: x, overviewReport: r } = R(v), s = w(() => {
|
|
15
|
-
var a;
|
|
16
|
-
return ((a = r.value) == null ? void 0 : a.tiles) || [];
|
|
17
|
-
});
|
|
18
|
-
return (a, m) => {
|
|
19
|
-
const g = $("FmPageHead");
|
|
20
|
-
return t(), n(L, null, {
|
|
21
|
-
default: y(() => {
|
|
22
|
-
var i;
|
|
23
|
-
return [
|
|
24
|
-
d(g, {
|
|
25
|
-
title: e(E)(e(l), e(f), (i = e(r)) == null ? void 0 : i.name, "other"),
|
|
26
|
-
class: "h-[68px]",
|
|
27
|
-
actions: [
|
|
28
|
-
{
|
|
29
|
-
label: e(l)("report.common.download"),
|
|
30
|
-
value: "download",
|
|
31
|
-
isPrimary: !0,
|
|
32
|
-
prependIcon: "download"
|
|
33
|
-
}
|
|
34
|
-
],
|
|
35
|
-
"onClick:action": m[0] || (m[0] = (p) => x.value = !0)
|
|
36
|
-
}, null, 8, ["title", "actions"]),
|
|
37
|
-
h("div", {
|
|
38
|
-
class: u(`flex flex-col gap-2 ${e(o).sm || e(o).xs ? "mb-20" : ""}`),
|
|
39
|
-
style: C({ height: `calc(100% - ${e(o).lg || e(o).md ? 72 : 64}px)` })
|
|
40
|
-
}, [
|
|
41
|
-
d(z),
|
|
42
|
-
s.value.length > 0 && e(r) ? (t(), _("div", {
|
|
43
|
-
key: 0,
|
|
44
|
-
class: u(["grid grid-cols-12", e(o).sm || e(o).xs ? "px-3 gap-[16px]" : "px-24 gap-[24px]"])
|
|
45
|
-
}, [
|
|
46
|
-
(t(!0), _(b, null, B(s.value, (p, c) => (t(), n(F, {
|
|
47
|
-
key: `widget_${e(r).id}_${c}`,
|
|
48
|
-
"model-value": p,
|
|
49
|
-
index: c
|
|
50
|
-
}, null, 8, ["model-value", "index"]))), 128))
|
|
51
|
-
], 2)) : (t(), n(S, { key: 1 }))
|
|
52
|
-
], 6)
|
|
53
|
-
];
|
|
54
|
-
}),
|
|
55
|
-
_: 1
|
|
56
|
-
});
|
|
57
|
-
};
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
export {
|
|
61
|
-
M as default
|
|
62
|
-
};
|
package/dist/Setting-B2oXF461.js
DELETED
|
@@ -1,324 +0,0 @@
|
|
|
1
|
-
import { defineComponent as B, ref as H, useModel as J, resolveComponent as h, createElementBlock as k, openBlock as x, createBlock as P, createElementVNode as t, resolveDynamicComponent as ne, unref as e, withCtx as y, createVNode as a, normalizeClass as O, toDisplayString as s, Fragment as K, renderList as Q, withDirectives as M, createTextVNode as ie, vShow as j, watch as me, normalizeStyle as ue } from "vue";
|
|
2
|
-
import { _ as de } from "./Default.vue_vue_type_script_setup_true_lang-B4qeIU-5.js";
|
|
3
|
-
import { d as z } from "./app-Bk5L2zfK.js";
|
|
4
|
-
import { components as I, useSnackbar as W, useBreakpoints as X, FmButtonColorThemeVariant as A } from "@feedmepos/ui-library";
|
|
5
|
-
import { t as N, l as pe } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CpoV8rC8.js";
|
|
6
|
-
import { u as ce } from "./message-dialog-UoMWOnil.js";
|
|
7
|
-
import { u as U, C as G, D as fe, b as ve } from "./vue-i18n-BGJaPUEy.js";
|
|
8
|
-
import { detectLocale as F } from "@feedmepos/mf-common";
|
|
9
|
-
import { a as Y } from "./SelectComponent.vue_vue_type_script_setup_true_lang--GXm-kRc.js";
|
|
10
|
-
import { storeToRefs as _e } from "pinia";
|
|
11
|
-
const ge = { class: "px-5 py-2" }, ye = { class: "flex" }, he = { class: "flex px-5 gap-2" }, xe = { class: "flex flex-col gap-2" }, be = { class: "fm-typo-en-title-sm-600" }, Ce = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ve = { class: "w-full gap-[24px] flex flex-col pt-2" }, Te = { class: "flex items-center w-full gap-3" }, De = { class: "text-fm-color-typo-primary" }, $e = { class: "text-fm-color-typo-secondary" }, Se = { class: "flex items-center gap-2" }, ke = /* @__PURE__ */ B({
|
|
12
|
-
__name: "ReportHour",
|
|
13
|
-
props: {
|
|
14
|
-
modelValue: {
|
|
15
|
-
required: !0,
|
|
16
|
-
default: () => []
|
|
17
|
-
},
|
|
18
|
-
modelModifiers: {}
|
|
19
|
-
},
|
|
20
|
-
emits: ["update:modelValue"],
|
|
21
|
-
setup(T) {
|
|
22
|
-
const o = H(!1), p = H(), l = {
|
|
23
|
-
name: "",
|
|
24
|
-
isDefault: !1,
|
|
25
|
-
startTime: { hour: 0, minute: 0 },
|
|
26
|
-
endTime: { hour: 0, minute: 0 }
|
|
27
|
-
}, { FmForm: c } = I, n = H(), { promptMessage: D } = ce(), b = W(), r = H(JSON.parse(JSON.stringify(l))), i = J(T, "modelValue"), { t: m } = U(), d = () => {
|
|
28
|
-
o.value = !1, r.value && p.value === void 0 ? i.value.push(r.value) : i.value[p.value] = r.value;
|
|
29
|
-
}, R = () => {
|
|
30
|
-
var v;
|
|
31
|
-
(v = n.value) == null || v.validateInputs();
|
|
32
|
-
}, L = () => {
|
|
33
|
-
o.value = !1, r.value = l;
|
|
34
|
-
}, Z = (v) => {
|
|
35
|
-
p.value = v, r.value = JSON.parse(JSON.stringify(i.value[p.value])), o.value = !0;
|
|
36
|
-
}, ee = () => {
|
|
37
|
-
r.value = l, o.value = !0;
|
|
38
|
-
}, te = async (v) => {
|
|
39
|
-
const u = i.value.find((C, f) => f === v);
|
|
40
|
-
if (!u) {
|
|
41
|
-
b.open({ message: `index ${v} cannot be found`, type: "error" });
|
|
42
|
-
return;
|
|
43
|
-
}
|
|
44
|
-
await D({
|
|
45
|
-
title: m("report.setting.reportHour.deleteTitle"),
|
|
46
|
-
message: m("report.setting.reportHour.deleteConfirm", { name: u.name })
|
|
47
|
-
}) && (i.value = i.value.filter((f, E) => E !== v), i.value.find((f) => f.isDefault) || (i.value[0].isDefault = !0), r.value = l);
|
|
48
|
-
}, oe = (v, u) => {
|
|
49
|
-
v ? i.value = i.value.map(($, C) => ({
|
|
50
|
-
...$,
|
|
51
|
-
isDefault: u === C
|
|
52
|
-
})) : i.value = i.value.map(($, C) => ({
|
|
53
|
-
...$,
|
|
54
|
-
isDefault: C === 0
|
|
55
|
-
}));
|
|
56
|
-
}, { breakpoints: w } = X(), { FmSideSheet: le, FmTopSheet: ae } = I;
|
|
57
|
-
return (v, u) => {
|
|
58
|
-
const $ = h("FmTextField"), C = h("FmTimePicker"), f = h("FmButton"), E = h("FmSwitch"), se = h("FmChip"), re = h("FmCard");
|
|
59
|
-
return x(), k("div", null, [
|
|
60
|
-
(x(), P(ne(e(w).lg || e(w).md ? e(le) : e(ae)), {
|
|
61
|
-
modelValue: o.value,
|
|
62
|
-
"onUpdate:modelValue": u[3] || (u[3] = (g) => o.value = g),
|
|
63
|
-
"fullscreen-size": "sm",
|
|
64
|
-
"dismiss-away": !0
|
|
65
|
-
}, {
|
|
66
|
-
"side-sheet-header": y(() => [
|
|
67
|
-
t("p", null, s(e(m)("report.setting.reportHour.addTitle")), 1)
|
|
68
|
-
]),
|
|
69
|
-
"top-sheet-header": y(() => [
|
|
70
|
-
t("div", ge, [
|
|
71
|
-
t("p", null, s(e(m)("report.setting.reportHour.addTitle")), 1)
|
|
72
|
-
])
|
|
73
|
-
]),
|
|
74
|
-
"side-sheet-footer": y(() => [
|
|
75
|
-
t("div", ye, [
|
|
76
|
-
a(f, {
|
|
77
|
-
label: "Save",
|
|
78
|
-
variant: "primary",
|
|
79
|
-
onClick: R
|
|
80
|
-
}),
|
|
81
|
-
a(f, {
|
|
82
|
-
label: "Cancel",
|
|
83
|
-
variant: "tertiary",
|
|
84
|
-
onClick: L
|
|
85
|
-
})
|
|
86
|
-
])
|
|
87
|
-
]),
|
|
88
|
-
"top-sheet-footer": y(() => [
|
|
89
|
-
t("div", he, [
|
|
90
|
-
a(f, {
|
|
91
|
-
label: "Save",
|
|
92
|
-
variant: "primary",
|
|
93
|
-
onClick: R
|
|
94
|
-
}),
|
|
95
|
-
a(f, {
|
|
96
|
-
label: "Cancel",
|
|
97
|
-
variant: "tertiary",
|
|
98
|
-
onClick: L
|
|
99
|
-
})
|
|
100
|
-
])
|
|
101
|
-
]),
|
|
102
|
-
default: y(() => [
|
|
103
|
-
a(e(c), {
|
|
104
|
-
ref_key: "form",
|
|
105
|
-
ref: n,
|
|
106
|
-
class: O(["flex flex-col gap-2", `${e(w).sm || e(w).xs ? "px-24" : ""}`]),
|
|
107
|
-
onValidationSuccess: d
|
|
108
|
-
}, {
|
|
109
|
-
default: y(() => {
|
|
110
|
-
var g, V, S, q;
|
|
111
|
-
return [
|
|
112
|
-
a($, {
|
|
113
|
-
modelValue: r.value.name,
|
|
114
|
-
"onUpdate:modelValue": u[0] || (u[0] = (_) => r.value.name = _),
|
|
115
|
-
label: e(m)("report.setting.reportHour.hourSetName"),
|
|
116
|
-
placeholder: e(m)("report.setting.reportHour.namePlaceholder"),
|
|
117
|
-
rules: [(_) => _ !== "" || e(m)("report.setting.reportHour.cannotBeEmpty")]
|
|
118
|
-
}, null, 8, ["modelValue", "label", "placeholder", "rules"]),
|
|
119
|
-
a(C, {
|
|
120
|
-
"model-value": e(z)().hour(((g = r.value.startTime) == null ? void 0 : g.hour) ?? 0).minute(((V = r.value.startTime) == null ? void 0 : V.minute) ?? 0).locale(e(F)()).format("HH:mm"),
|
|
121
|
-
class: "grow",
|
|
122
|
-
label: e(m)("report.setting.reportHour.startTime"),
|
|
123
|
-
"onUpdate:modelValue": u[1] || (u[1] = (_) => {
|
|
124
|
-
_ && (r.value.startTime.hour = Number(_.split(":")[0]), r.value.startTime.minute = Number(_.split(":")[1]));
|
|
125
|
-
})
|
|
126
|
-
}, null, 8, ["model-value", "label"]),
|
|
127
|
-
a(C, {
|
|
128
|
-
"model-value": e(z)().hour(((S = r.value.endTime) == null ? void 0 : S.hour) ?? 0).minute(((q = r.value.endTime) == null ? void 0 : q.minute) ?? 0).format("HH:mm"),
|
|
129
|
-
class: "grow",
|
|
130
|
-
label: e(m)("report.setting.reportHour.closeTime"),
|
|
131
|
-
"onUpdate:modelValue": u[2] || (u[2] = (_) => {
|
|
132
|
-
_ && (r.value.endTime.hour = Number(_.split(":")[0]), r.value.endTime.minute = Number(_.split(":")[1]));
|
|
133
|
-
})
|
|
134
|
-
}, null, 8, ["model-value", "label"])
|
|
135
|
-
];
|
|
136
|
-
}),
|
|
137
|
-
_: 1
|
|
138
|
-
}, 8, ["class"])
|
|
139
|
-
]),
|
|
140
|
-
_: 1
|
|
141
|
-
}, 8, ["modelValue"])),
|
|
142
|
-
t("div", xe, [
|
|
143
|
-
t("p", be, s(e(m)("report.setting.reportHour.title")), 1),
|
|
144
|
-
t("p", Ce, s(e(m)("report.setting.reportHour.description")), 1)
|
|
145
|
-
]),
|
|
146
|
-
t("div", Ve, [
|
|
147
|
-
(x(!0), k(K, null, Q(i.value, (g, V) => (x(), P(re, {
|
|
148
|
-
key: `report_${V}`,
|
|
149
|
-
class: "flex p-4",
|
|
150
|
-
variant: "outlined"
|
|
151
|
-
}, {
|
|
152
|
-
default: y(() => [
|
|
153
|
-
t("div", Te, [
|
|
154
|
-
a(E, {
|
|
155
|
-
"model-value": g.isDefault,
|
|
156
|
-
"onUpdate:modelValue": (S) => oe(S, V)
|
|
157
|
-
}, null, 8, ["model-value", "onUpdate:modelValue"]),
|
|
158
|
-
t("div", null, [
|
|
159
|
-
t("p", De, [
|
|
160
|
-
ie(s(g.name) + " ", 1),
|
|
161
|
-
M(a(se, {
|
|
162
|
-
label: e(m)("report.common.default"),
|
|
163
|
-
class: "bg-fm-color-system-info-100 border-fm-color-typo-info text-fm-color-typo-info",
|
|
164
|
-
compact: ""
|
|
165
|
-
}, null, 8, ["label"]), [
|
|
166
|
-
[j, g.isDefault]
|
|
167
|
-
])
|
|
168
|
-
]),
|
|
169
|
-
t("p", $e, s(e(N)(g.startTime, e(F)())) + " - " + s(e(N)(g.endTime, e(F)())), 1)
|
|
170
|
-
]),
|
|
171
|
-
u[4] || (u[4] = t("div", { class: "grow" }, null, -1)),
|
|
172
|
-
M(t("div", Se, [
|
|
173
|
-
a(f, {
|
|
174
|
-
icon: "edit",
|
|
175
|
-
variant: "tertiary",
|
|
176
|
-
onClick: (S) => Z(V)
|
|
177
|
-
}, null, 8, ["onClick"]),
|
|
178
|
-
a(f, {
|
|
179
|
-
icon: "delete",
|
|
180
|
-
variant: "tertiary",
|
|
181
|
-
onClick: (S) => te(V)
|
|
182
|
-
}, null, 8, ["onClick"])
|
|
183
|
-
], 512), [
|
|
184
|
-
[j, V !== 0]
|
|
185
|
-
])
|
|
186
|
-
])
|
|
187
|
-
]),
|
|
188
|
-
_: 2
|
|
189
|
-
}, 1024))), 128)),
|
|
190
|
-
t("div", null, [
|
|
191
|
-
a(f, {
|
|
192
|
-
label: e(m)("report.setting.reportHour.add"),
|
|
193
|
-
variant: "secondary",
|
|
194
|
-
icon: "add",
|
|
195
|
-
"icon-position": "prepend",
|
|
196
|
-
"border-color": e(A).ColorPrimary,
|
|
197
|
-
"text-color": e(A).ColorPrimary,
|
|
198
|
-
onClick: ee
|
|
199
|
-
}, null, 8, ["label", "border-color", "text-color"])
|
|
200
|
-
])
|
|
201
|
-
])
|
|
202
|
-
]);
|
|
203
|
-
};
|
|
204
|
-
}
|
|
205
|
-
}), Fe = { class: "py-2 w-full gap-2 flex flex-col" }, Re = { class: "fm-typo-en-title-sm-600" }, we = /* @__PURE__ */ B({
|
|
206
|
-
__name: "CompareRangeSetting",
|
|
207
|
-
props: {
|
|
208
|
-
modelValue: {
|
|
209
|
-
required: !0,
|
|
210
|
-
default: G.PRECEDING_PERIOD
|
|
211
|
-
},
|
|
212
|
-
modelModifiers: {}
|
|
213
|
-
},
|
|
214
|
-
emits: ["update:modelValue"],
|
|
215
|
-
setup(T) {
|
|
216
|
-
const { t: o } = U(), p = J(T, "modelValue"), l = Object.values(G).map((c) => ({
|
|
217
|
-
label: o(`report.compare.${c}`),
|
|
218
|
-
value: c
|
|
219
|
-
})).slice(0, -1);
|
|
220
|
-
return (c, n) => (x(), k("div", Fe, [
|
|
221
|
-
t("p", Re, s(e(o)("report.setting.summary.comparisonDateRange")), 1),
|
|
222
|
-
a(Y, {
|
|
223
|
-
modelValue: p.value,
|
|
224
|
-
"onUpdate:modelValue": n[0] || (n[0] = (D) => p.value = D),
|
|
225
|
-
label: e(o)("report.setting.summary.comparisonDateRange"),
|
|
226
|
-
items: e(l),
|
|
227
|
-
"disable-search": !0
|
|
228
|
-
}, null, 8, ["modelValue", "label", "items"])
|
|
229
|
-
]));
|
|
230
|
-
}
|
|
231
|
-
}), He = { class: "py-2 w-full gap-2 flex flex-col" }, Oe = { class: "fm-typo-en-title-sm-600" }, Ne = /* @__PURE__ */ B({
|
|
232
|
-
__name: "DateRangeSetting",
|
|
233
|
-
props: {
|
|
234
|
-
modelValue: { required: !0 },
|
|
235
|
-
modelModifiers: {}
|
|
236
|
-
},
|
|
237
|
-
emits: ["update:modelValue"],
|
|
238
|
-
setup(T) {
|
|
239
|
-
const { t: o } = U(), p = J(T, "modelValue"), l = Object.values(fe).filter((c) => !["This month", "Last month"].includes(c)).map((c) => ({
|
|
240
|
-
label: o(`report.date.${c}`),
|
|
241
|
-
value: c
|
|
242
|
-
}));
|
|
243
|
-
return (c, n) => (x(), k("div", He, [
|
|
244
|
-
t("p", Oe, s(e(o)("report.setting.summary.defaultDateRange")), 1),
|
|
245
|
-
a(Y, {
|
|
246
|
-
modelValue: p.value,
|
|
247
|
-
"onUpdate:modelValue": n[0] || (n[0] = (D) => p.value = D),
|
|
248
|
-
label: e(o)("report.setting.summary.defaultDateRange"),
|
|
249
|
-
items: e(l),
|
|
250
|
-
"disable-search": !0
|
|
251
|
-
}, null, 8, ["modelValue", "label", "items"])
|
|
252
|
-
]));
|
|
253
|
-
}
|
|
254
|
-
}), Be = { class: "w-2/4" }, Ue = { class: "fm-typo-en-title-sm-600" }, Ee = { class: "text-fm-color-typo-secondary" }, Pe = { class: "fm-typo-en-body-lg-600" }, Me = { class: "text-fm-color-typo-secondary" }, je = { class: "fm-typo-en-body-lg-600" }, Je = { class: "text-fm-color-typo-secondary" }, Le = { class: "fm-typo-en-body-lg-600" }, Ze = /* @__PURE__ */ B({
|
|
255
|
-
__name: "Setting",
|
|
256
|
-
setup(T) {
|
|
257
|
-
const { breakpoints: o } = X(), p = ve(), { defaultDateSetting: l } = _e(p), c = W(), { t: n } = U();
|
|
258
|
-
return me(
|
|
259
|
-
[
|
|
260
|
-
() => l.value.defaultCompareType,
|
|
261
|
-
() => l.value.defaultDateRange,
|
|
262
|
-
() => l.value.timeOptions
|
|
263
|
-
],
|
|
264
|
-
() => {
|
|
265
|
-
l.value.timeOptions.length === 0 ? c.open({ message: n("report.setting.reportHour.cannotBeEmptyError"), type: "error" }) : p.createOrUpdateBusinessSetting(l.value);
|
|
266
|
-
},
|
|
267
|
-
{ deep: !0 }
|
|
268
|
-
), (D, b) => {
|
|
269
|
-
const r = h("FmPageHead"), i = h("FmMenuDivider"), m = h("FmCard");
|
|
270
|
-
return x(), P(de, null, {
|
|
271
|
-
default: y(() => [
|
|
272
|
-
a(r, { title: "Settings" }),
|
|
273
|
-
t("div", {
|
|
274
|
-
class: O(`${e(o).sm || e(o).xs ? "pb-20" : ""} overflow-y-auto flex`),
|
|
275
|
-
style: ue({ height: `calc(100% - ${e(o).sm || e(o).xs ? 60 : 72}px)` })
|
|
276
|
-
}, [
|
|
277
|
-
t("div", {
|
|
278
|
-
class: O(`${e(o).lg || e(o).md ? "px-24" : "px-3"} w-full flex flex-col gap-[40px]`)
|
|
279
|
-
}, [
|
|
280
|
-
a(ke, {
|
|
281
|
-
modelValue: e(l).timeOptions,
|
|
282
|
-
"onUpdate:modelValue": b[0] || (b[0] = (d) => e(l).timeOptions = d)
|
|
283
|
-
}, null, 8, ["modelValue"]),
|
|
284
|
-
a(Ne, {
|
|
285
|
-
modelValue: e(l).defaultDateRange,
|
|
286
|
-
"onUpdate:modelValue": b[1] || (b[1] = (d) => e(l).defaultDateRange = d)
|
|
287
|
-
}, null, 8, ["modelValue"]),
|
|
288
|
-
a(we, {
|
|
289
|
-
modelValue: e(l).defaultCompareType,
|
|
290
|
-
"onUpdate:modelValue": b[2] || (b[2] = (d) => e(l).defaultCompareType = d)
|
|
291
|
-
}, null, 8, ["modelValue"])
|
|
292
|
-
], 2),
|
|
293
|
-
M(t("div", Be, [
|
|
294
|
-
a(m, {
|
|
295
|
-
variant: "outlined",
|
|
296
|
-
class: O(["flex flex-col gap-3", `${e(o).lg || e(o).md ? "mr-5 p-6" : ""}`])
|
|
297
|
-
}, {
|
|
298
|
-
default: y(() => [
|
|
299
|
-
t("p", Ue, s(e(n)("report.setting.summary.title")), 1),
|
|
300
|
-
a(i),
|
|
301
|
-
t("p", Ee, s(e(n)("report.setting.summary.reportHour")), 1),
|
|
302
|
-
(x(!0), k(K, null, Q(e(l).timeOptions, (d, R) => (x(), k("div", { key: R }, [
|
|
303
|
-
t("p", Pe, s(d.name) + s(d.isDefault ? `(${e(n)("report.setting.reportHour.default")})` : "") + " " + s(e(N)(d.startTime, e(F)())) + " " + s(e(N)(d.endTime, e(F)())) + " " + s(e(pe)(d.startTime, d.endTime)), 1)
|
|
304
|
-
]))), 128)),
|
|
305
|
-
t("p", Me, s(e(n)("report.setting.summary.defaultDateRange")), 1),
|
|
306
|
-
t("p", je, s(e(n)(`report.date.${e(l).defaultDateRange}`)), 1),
|
|
307
|
-
t("p", Je, s(e(n)("report.setting.summary.comparisonDateRange")), 1),
|
|
308
|
-
t("p", Le, s(e(n)(`report.compare.${e(l).defaultCompareType}`)), 1)
|
|
309
|
-
]),
|
|
310
|
-
_: 1
|
|
311
|
-
}, 8, ["class"])
|
|
312
|
-
], 512), [
|
|
313
|
-
[j, e(o).lg || e(o).md]
|
|
314
|
-
])
|
|
315
|
-
], 6)
|
|
316
|
-
]),
|
|
317
|
-
_: 1
|
|
318
|
-
});
|
|
319
|
-
};
|
|
320
|
-
}
|
|
321
|
-
});
|
|
322
|
-
export {
|
|
323
|
-
Ze as default
|
|
324
|
-
};
|