@feedmepos/mf-report 5.22.12 → 5.22.13-beta.0

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.
Files changed (29) hide show
  1. package/dist/{App-DDzVhXL7.js → App-Ci4TNGo-.js} +40 -40
  2. package/dist/{BaseDialog.vue_vue_type_script_setup_true_lang-BZlvMBPW.js → BaseDialog.vue_vue_type_script_setup_true_lang-N4p0t07m.js} +3 -3
  3. package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-BM-li0d3.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-GTlzuFQB.js} +2 -2
  4. package/dist/{Default.vue_vue_type_script_setup_true_lang-BuFLfame.js → Default.vue_vue_type_script_setup_true_lang-COOzNYD3.js} +2 -2
  5. package/dist/{FilterSelector.vue_vue_type_script_setup_true_lang-BoX6fRDT.js → FilterSelector.vue_vue_type_script_setup_true_lang-lO1-P1LC.js} +6 -6
  6. package/dist/{InsightView-DBmUbSlP.js → InsightView-waXZnisb.js} +6 -6
  7. package/dist/{Integration-BDC13WLh.js → Integration-Dn9Ivqfx.js} +36 -35
  8. package/dist/{Integrations-C6gWnyhy.js → Integrations-B56QpwNs.js} +7 -6
  9. package/dist/{Layout-DbHEONpc.js → Layout-ydTDzEg9.js} +1 -1
  10. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-G9CiV2LK.js → MenuTab.vue_vue_type_script_setup_true_lang-Bqbrinds.js} +5 -5
  11. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-D9-002wn.js → NavigationTab.vue_vue_type_script_setup_true_lang-Cpa9H1ZR.js} +5 -5
  12. package/dist/{NoData.vue_vue_type_script_setup_true_lang-CdGpZdFx.js → NoData.vue_vue_type_script_setup_true_lang-C7GXgBKq.js} +1 -1
  13. package/dist/{OverviewView-B0dWJYNP.js → OverviewView-Y-KB6M-1.js} +5 -5
  14. package/dist/{Report-QeJVzX13.js → Report-DvSjPfbV.js} +202 -177
  15. package/dist/{ReportEditor-LupGO1_l.js → ReportEditor-Dj-pof8I.js} +6 -6
  16. package/dist/ReportView-DH8tcg-Q.js +265 -0
  17. package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-DMMP43KF.js → SelectComponent.vue_vue_type_script_setup_true_lang-DY50WPYu.js} +1 -1
  18. package/dist/{Setting-Dv-Eo5IX.js → Setting-Do5JShD8.js} +5 -5
  19. package/dist/{TileEditor-ZqOV5_Le.js → TileEditor-Do0x54jE.js} +8 -8
  20. package/dist/{TransitionFade-CsoI1XtQ.js → TransitionFade-lS2nSDyF.js} +6 -6
  21. package/dist/{useRestaurantPermission-8zTUt56b.js → access-Dw5cDt65-CQ5PE5GD.js} +386 -388
  22. package/dist/{app-Du0ALyx7.js → app-wKEwqUHq.js} +56 -36
  23. package/dist/app.js +1 -1
  24. package/dist/style.css +1 -1
  25. package/dist/useReportPermission-CRkYtDX0.js +60 -0
  26. package/dist/useRestaurantPermission-3Sf0GSc7.js +65 -0
  27. package/dist/{vue-i18n-kHBFKu4C.js → vue-i18n-wKxo3TA6.js} +7 -7
  28. package/package.json +2 -2
  29. package/dist/ReportView-BMgXES5v.js +0 -250
@@ -1,81 +1,84 @@
1
- import { defineComponent as ke, ref as U, watch as ce, computed as b, h as y, withModifiers as we, resolveComponent as w, createBlock as j, openBlock as A, withCtx as i, createVNode as s, createElementVNode as h, unref as e, normalizeStyle as xe, normalizeClass as x, withDirectives as G, createElementBlock as _e, Fragment as Ie, renderList as $e, toDisplayString as J, createTextVNode as Re, vShow as H } from "vue";
2
- import { storeToRefs as ie } from "pinia";
3
- import { a as De, u as Fe } from "./BaseDialog.vue_vue_type_script_setup_true_lang-BZlvMBPW.js";
4
- import { _ as Oe } from "./Default.vue_vue_type_script_setup_true_lang-BuFLfame.js";
5
- import { u as Le } from "./message-dialog-UoMWOnil.js";
6
- import { b as ue, e as Ne } from "./vue-i18n-kHBFKu4C.js";
7
- import { useSnackbar as Ve, useBreakpoints as Ae, components as Je, FmButtonColorThemeVariant as ze } from "@feedmepos/ui-library";
8
- import { _ as Pe } from "./NoData.vue_vue_type_script_setup_true_lang-CdGpZdFx.js";
9
- import { useRouter as Te, useRoute as Be, onBeforeRouteLeave as Ee } from "vue-router";
10
- import { useI18n as Ke } from "@feedmepos/mf-common";
11
- import { r as me } from "./i18n-CI_sQ5d_.js";
12
- const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye = { class: "w-[343px]" }, qe = { class: "fm-typo-en-body-md-600" }, nt = /* @__PURE__ */ ke({
1
+ import { defineComponent as _e, ref as j, watch as ue, computed as b, h as y, withModifiers as Ie, resolveComponent as x, createBlock as G, openBlock as V, withCtx as m, createVNode as l, createElementVNode as h, unref as e, normalizeStyle as $e, normalizeClass as _, withDirectives as H, createElementBlock as Re, Fragment as De, renderList as Fe, toDisplayString as A, createTextVNode as Oe, vShow as Q } from "vue";
2
+ import { storeToRefs as me } from "pinia";
3
+ import { a as Le, u as Ne } from "./BaseDialog.vue_vue_type_script_setup_true_lang-N4p0t07m.js";
4
+ import { _ as Pe } from "./Default.vue_vue_type_script_setup_true_lang-COOzNYD3.js";
5
+ import { u as Ve } from "./message-dialog-UoMWOnil.js";
6
+ import { b as de, e as Ae } from "./vue-i18n-wKxo3TA6.js";
7
+ import { useSnackbar as Je, useBreakpoints as ze, components as Be, FmButtonColorThemeVariant as Te } from "@feedmepos/ui-library";
8
+ import { _ as Ue } from "./NoData.vue_vue_type_script_setup_true_lang-C7GXgBKq.js";
9
+ import { useRouter as Ee, useRoute as Ke, onBeforeRouteLeave as Me } from "vue-router";
10
+ import { useI18n as Ye } from "@feedmepos/mf-common";
11
+ import { r as W } from "./i18n-CI_sQ5d_.js";
12
+ import { u as qe } from "./useReportPermission-CRkYtDX0.js";
13
+ const je = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ge = { class: "w-[343px]" }, He = { class: "fm-typo-en-body-md-600" }, ct = /* @__PURE__ */ _e({
13
14
  __name: "Report",
14
- setup(Ue) {
15
- const { t: a, te: Q } = Ke(), W = Te(), X = Be(), p = De(), de = Fe(), { business: pe } = ie(ue()), {
15
+ setup(Qe) {
16
+ const { t: a, te: J } = Ye(), X = Ee(), Z = Ke(), p = Le(), pe = Ne(), { business: fe } = me(de()), {
16
17
  reports: f,
17
18
  overviewReport: z,
18
- categories: I,
19
- pinReport: $,
20
- isOpenAddReportDialog: fe,
21
- scrollPositionY: Z,
22
- customReportQuota: R,
23
- canCreateCustomReport: ee
24
- } = ie(p), { promptMessage: te } = Le(), { promptLoader: P } = Ne(), d = Ve(), { breakpoints: c } = Ae(), S = U();
25
- Ee(() => {
26
- S.value && (Z.value = S.value.$el.children[0].scrollTop);
27
- }), ce(S, () => {
28
- S.value && setTimeout(() => {
29
- S.value.$el.children[0].scrollTop = Z.value;
19
+ categories: R,
20
+ pinReport: D,
21
+ isOpenAddReportDialog: ve,
22
+ scrollPositionY: ee,
23
+ customReportQuota: F,
24
+ canCreateCustomReport: te
25
+ } = me(p), { promptMessage: oe } = Ve(), { promptLoader: B } = Ae(), u = Je(), { breakpoints: i } = ze(), { canUpdate: ae, canDuplicate: ye, canCreateReport: ge } = qe(), C = j();
26
+ Me(() => {
27
+ C.value && (ee.value = C.value.$el.children[0].scrollTop);
28
+ }), ue(C, () => {
29
+ C.value && setTimeout(() => {
30
+ C.value.$el.children[0].scrollTop = ee.value;
30
31
  }, 200);
31
32
  });
32
- const T = b(() => $.value && f.value ? f.value.filter((o) => {
33
+ const T = b(() => D.value && f.value ? f.value.filter((o) => {
33
34
  var t;
34
- return (t = $.value) == null ? void 0 : t.includes(o.id);
35
+ return (t = D.value) == null ? void 0 : t.includes(o.id);
35
36
  }) : []);
36
- ce(
37
- [() => pe.value],
37
+ ue(
38
+ [() => fe.value],
38
39
  () => {
39
40
  p.refreshPinReport();
40
41
  },
41
42
  { immediate: !0 }
42
43
  );
43
- const oe = b(() => T.value.length > 0 ? f.value.filter(
44
+ const ne = b(() => T.value.length > 0 ? f.value.filter(
44
45
  (o) => T.value.findIndex((t) => t.id === o.id) === -1
45
- ) : f.value), { FmButton: ve, FmMenu: B, FmMenuItem: C, FmIcon: E, FmChip: K } = Je, ae = b(() => [
46
+ ) : f.value), { FmButton: be, FmMenu: U, FmMenuItem: S, FmIcon: E, FmChip: K } = Be, re = b(() => [
46
47
  { value: void 0, label: "All" },
47
- ...I.value.map((o) => ({
48
+ ...R.value.map((o) => ({
48
49
  value: o.id,
49
50
  label: o.name
50
51
  }))
51
- ]), D = U(ae.value[0]), M = U(""), k = b(() => oe.value.length === 0 || I.value.length === 0 ? [] : [
52
+ ]), O = j(re.value[0]), M = j(""), k = b(() => ne.value.length === 0 || R.value.length === 0 ? [] : [
52
53
  ...T.value.map((t) => {
53
- const n = I.value.find((l) => l.id === t.category);
54
+ const n = R.value.find((s) => s.id === t.category);
54
55
  return {
55
- name: me(a, Q, t.name, "other"),
56
+ name: W(a, J, t.name, "other"),
56
57
  categoryId: (n == null ? void 0 : n.id) ?? "",
57
58
  category: n != null && n.name ? a(`report.category.${n.name}`) : a("report.common.uncategorized"),
58
59
  reportId: t.id,
59
60
  editable: t.editable,
60
61
  description: t.description || "",
61
- pin: !0
62
+ pin: !0,
63
+ canUpdate: ae(t)
62
64
  };
63
65
  }),
64
- ...oe.value.map((t) => {
65
- const n = I.value.find((l) => l.id === t.category);
66
+ ...ne.value.map((t) => {
67
+ const n = R.value.find((s) => s.id === t.category);
66
68
  return {
67
- name: me(a, Q, t.name, "other"),
69
+ name: W(a, J, t.name, "other"),
68
70
  categoryId: (n == null ? void 0 : n.id) ?? "",
69
71
  category: n != null && n.name ? a(`report.category.${n.name}`) : a("report.common.uncategorized"),
70
72
  reportId: t.id,
71
73
  editable: t.editable,
72
74
  description: t.description || "",
73
- pin: !1
75
+ pin: !1,
76
+ canUpdate: ae(t)
74
77
  };
75
78
  })
76
- ].filter((t) => D.value.value && t.categoryId !== D.value.value ? !1 : `${(t == null ? void 0 : t.name) || ""}${(t == null ? void 0 : t.description) || ""}`.toLowerCase().indexOf(M.value.toLowerCase()) !== -1)), ye = b(
79
+ ].filter((t) => O.value.value && t.categoryId !== O.value.value ? !1 : `${(t == null ? void 0 : t.name) || ""}${(t == null ? void 0 : t.description) || ""}`.toLowerCase().indexOf(M.value.toLowerCase()) !== -1)), he = b(
77
80
  () => k.value.map((o) => `${o.name}${o.category}`).toString()
78
- ), ge = b(() => [
81
+ ), Ce = b(() => [
79
82
  {
80
83
  accessorKey: "name",
81
84
  header: a("report.common.name"),
@@ -112,20 +115,23 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
112
115
  width: "80px"
113
116
  },
114
117
  cell: (o) => {
115
- var N;
116
- const t = o.row.original, n = t.reportId, l = f.value.find((u) => u.id === n), Y = n === ((N = z.value) == null ? void 0 : N.id), q = [
118
+ var r;
119
+ const t = o.row.original, n = t.reportId, s = f.value.find((c) => c.id === n), Y = n === ((r = z.value) == null ? void 0 : r.id), w = !1, $ = s ? ye(s) : !1, q = [
117
120
  {
118
121
  label: a("report.common.duplicate"),
119
122
  onClick: () => {
120
- l && le(l);
123
+ s && $ ? ie(s) : $ || u.open({
124
+ message: a("report.messages.noPermissionDuplicateReport"),
125
+ type: "error"
126
+ });
121
127
  },
122
128
  variant: "",
123
- disabled: !1
129
+ disabled: !$
124
130
  },
125
131
  {
126
132
  label: a(Y ? "report.common.unsetAsOverview" : "report.common.setAsOverview"),
127
133
  onClick: async () => {
128
- l && ne(l);
134
+ s && se(s);
129
135
  },
130
136
  variant: "",
131
137
  disabled: !1
@@ -133,7 +139,7 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
133
139
  {
134
140
  label: a("report.common.remove"),
135
141
  onClick: () => {
136
- l && re(l);
142
+ s && le(s);
137
143
  },
138
144
  variant: "destructive",
139
145
  disabled: !t.editable
@@ -142,17 +148,21 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
142
148
  return y(
143
149
  "div",
144
150
  {
145
- class: `flex ${c.value.lg || c.value.md ? "justify-end" : ""} items-center`
151
+ class: `flex ${i.value.lg || i.value.md ? "justify-end" : ""} items-center`
146
152
  },
147
153
  {
148
154
  default: () => [
149
155
  y(
150
156
  "button",
151
157
  {
152
- onClick: we(() => {
153
- l && se(l);
158
+ disabled: w,
159
+ title: void 0,
160
+ onClick: Ie(() => {
161
+ s && ce(s);
154
162
  }, ["stop"]),
155
- class: `text-fm-color-neutral-gray-400 ${t.pin ? "" : "show-pin"} hover:bg-fm-color-opacity-sm rounded-lg flex items-center justify-center`
163
+ class: `text-fm-color-neutral-gray-400 ${t.pin ? "" : "show-pin"} hover:bg-fm-color-opacity-sm rounded-lg flex items-center justify-center`,
164
+ disabled: w,
165
+ title: void 0
156
166
  },
157
167
  {
158
168
  default: () => [
@@ -170,30 +180,37 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
170
180
  }
171
181
  ),
172
182
  y(
173
- B,
174
- { stopClickPropagation: !0, shift: !0 },
183
+ U,
184
+ {
185
+ stopClickPropagation: !0,
186
+ shift: !0,
187
+ disabled: w,
188
+ title: void 0
189
+ },
175
190
  {
176
191
  default: () => q.map(
177
- (u) => y(
178
- C,
192
+ (c) => y(
193
+ S,
179
194
  {
180
- onClick: u.disabled ? {} : u.onClick,
181
- label: u.label,
182
- class: u.disabled ? "text-fm-color-typo-disabled" : u.variant === "destructive" ? "text-fm-color-typo-error" : "",
183
- disabled: u.disabled
195
+ onClick: c.disabled ? {} : c.onClick,
196
+ label: c.label,
197
+ class: c.disabled ? "text-fm-color-typo-disabled" : c.variant === "destructive" ? "text-fm-color-typo-error" : "",
198
+ disabled: c.disabled
184
199
  },
185
200
  {
186
- label: () => y("p", u.label)
201
+ label: () => y("p", c.label)
187
202
  }
188
203
  )
189
204
  ),
190
205
  "menu-button": () => y(
191
- ve,
206
+ be,
192
207
  {
193
208
  variant: "tertiary",
194
209
  size: "md",
195
210
  icon: "more_vert",
196
- iconColor: ze.NeutralGray400
211
+ iconColor: Te.NeutralGray400,
212
+ disabled: w,
213
+ title: void 0
197
214
  },
198
215
  {}
199
216
  )
@@ -205,22 +222,22 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
205
222
  }
206
223
  }
207
224
  ]);
208
- async function ne(o) {
209
- await P(async () => {
225
+ async function se(o) {
226
+ await B(async () => {
210
227
  var t;
211
228
  try {
212
229
  const n = o.id === ((t = z.value) == null ? void 0 : t.id);
213
- await p.updateDefaultReport(n ? null : o.id), d.open({
230
+ await p.updateDefaultReport(n ? null : o.id), u.open({
214
231
  message: `Successfully ${n ? "unset" : "set"} ${o.name} as Overview`,
215
232
  type: "success"
216
233
  });
217
234
  } catch (n) {
218
- d.open({ message: JSON.stringify(n), type: "error" });
235
+ u.open({ message: JSON.stringify(n), type: "error" });
219
236
  }
220
237
  });
221
238
  }
222
- async function be(o) {
223
- if (await te({
239
+ async function Se(o) {
240
+ if (await oe({
224
241
  title: a("report.common.duplicate"),
225
242
  message: a("report.messages.confirmAction", {
226
243
  action: a("report.common.duplicate"),
@@ -228,73 +245,81 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
228
245
  })
229
246
  })) {
230
247
  const n = JSON.parse(JSON.stringify(o));
231
- n.editable = !0, n.id = "", n.name = `${n.name} ${a("report.common.duplicate")}`, P(async () => {
248
+ n.editable = !0, n.id = "", n.name = `${n.name} ${a("report.common.duplicate")}`, B(async () => {
232
249
  try {
233
- await p.createOrUpdateReport(n), d.open({
250
+ await p.createOrUpdateReport(n), u.open({
234
251
  message: `${a("report.messages.duplicateSuccess", { name: n.name })}`,
235
252
  type: "success"
236
253
  });
237
- } catch (l) {
238
- d.open({ message: JSON.stringify(l), type: "error" });
254
+ } catch (s) {
255
+ u.open({ message: JSON.stringify(s), type: "error" });
239
256
  }
240
257
  });
241
258
  }
242
259
  }
243
- async function re(o) {
244
- await te({
260
+ async function le(o) {
261
+ await oe({
245
262
  title: a("report.messages.deleteReport"),
246
263
  message: a("report.messages.confirmDelete", { name: o.name })
247
- }) && P(async () => {
264
+ }) && B(async () => {
248
265
  try {
249
- await p.removeReport(o), d.open({
266
+ await p.removeReport(o), u.open({
250
267
  message: a("report.messages.deleteSuccess", { name: o.name }),
251
268
  type: "success"
252
269
  });
253
270
  } catch (n) {
254
- d.open({ message: JSON.stringify(n), type: "error" });
271
+ u.open({ message: JSON.stringify(n), type: "error" });
255
272
  }
256
273
  });
257
274
  }
258
- async function le(o) {
259
- if (ee.value)
260
- await be(o);
275
+ async function ie(o) {
276
+ if (te.value)
277
+ await Se(o);
261
278
  else {
262
- let t = `Your current plan only support up to ${R.value} custom reports.`;
263
- R.value === 0 && (t = "Your current plan does not support custom report."), d.open({
279
+ let t = `Your current plan only support up to ${F.value} custom reports.`;
280
+ F.value === 0 && (t = "Your current plan does not support custom report."), u.open({
264
281
  message: t,
265
282
  type: "error"
266
283
  });
267
284
  }
268
285
  }
269
- function he() {
270
- if (ee.value)
271
- fe.value = !0;
286
+ function ke() {
287
+ if (!ge.value) {
288
+ u.open({
289
+ message: a("report.messages.noPermission"),
290
+ type: "error"
291
+ });
292
+ return;
293
+ }
294
+ if (te.value)
295
+ ve.value = !0;
272
296
  else {
273
- let o = `Your current plan only support up to ${R.value} custom reports.`;
274
- R.value === 0 && (o = "Your current plan does not support custom report."), d.open({
297
+ let o = `Your current plan only support up to ${F.value} custom reports.`;
298
+ F.value === 0 && (o = "Your current plan does not support custom report."), u.open({
275
299
  message: o,
276
300
  type: "error"
277
301
  });
278
302
  }
279
303
  }
280
- function se(o) {
281
- $.value && $.value.includes(o.id) ? (d.open({
282
- message: `${a("report.common.unpin")} ${o.name} ${a("report.common.successful")}`,
304
+ function ce(o) {
305
+ const t = W(a, J, o.name, "other") ?? "";
306
+ D.value && D.value.includes(o.id) ? (u.open({
307
+ message: `${a("report.common.unpin")} ${t} ${a("report.common.successful")}`,
283
308
  type: "success"
284
- }), p.clearPinReport(o.id)) : (d.open({
285
- message: `${a("report.common.pin")} ${o.name} ${a("report.common.successful")}`,
309
+ }), p.clearPinReport(o.id)) : (u.open({
310
+ message: `${a("report.common.pin")} ${t} ${a("report.common.successful")}`,
286
311
  type: "success"
287
312
  }), p.cachePinReport(o));
288
313
  }
289
- function Se(o) {
290
- D.value = o;
314
+ function we(o) {
315
+ O.value = o;
291
316
  }
292
- const { selectedLocationIds: _, dateRange: F, compareDateRange: O, timeRange: v, locations: Ce } = ue(), L = b(() => _.length === Ce.length);
317
+ const { selectedLocationIds: I, dateRange: L, compareDateRange: N, timeRange: v, locations: xe } = de(), P = b(() => I.length === xe.length);
293
318
  return (o, t) => {
294
- const n = w("FmPageHead"), l = w("FmSearch"), Y = w("FmForm"), q = w("FmListItem"), N = w("FmList"), u = w("FmTable");
295
- return A(), j(Oe, null, {
296
- default: i(() => [
297
- s(n, {
319
+ const n = x("FmPageHead"), s = x("FmSearch"), Y = x("FmForm"), w = x("FmListItem"), $ = x("FmList"), q = x("FmTable");
320
+ return V(), G(Pe, null, {
321
+ default: m(() => [
322
+ l(n, {
298
323
  title: e(a)("report.common.report", 1),
299
324
  class: "h-[68px]",
300
325
  actions: [
@@ -305,176 +330,176 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
305
330
  prependIcon: "add"
306
331
  }
307
332
  ],
308
- "onClick:action": t[0] || (t[0] = (r) => he())
333
+ "onClick:action": t[0] || (t[0] = (r) => ke())
309
334
  }, null, 8, ["title", "actions"]),
310
335
  h("div", {
311
- class: x(`overflow-y-hidden flex flex-col gap-8 ${e(c).sm || e(c).xs ? "mb-20" : ""}`),
312
- style: xe({ height: `calc(100% - ${e(c).lg || e(c).md ? 72 : 64}px)` })
336
+ class: _(`overflow-y-hidden flex flex-col gap-8 ${e(i).sm || e(i).xs ? "mb-20" : ""}`),
337
+ style: $e({ height: `calc(100% - ${e(i).lg || e(i).md ? 72 : 64}px)` })
313
338
  }, [
314
- s(Y, {
315
- class: x(`flex items-center gap-2 ${e(c).sm || e(c).xs ? "px-3" : "px-24"}`)
339
+ l(Y, {
340
+ class: _(`flex items-center gap-2 ${e(i).sm || e(i).xs ? "px-3" : "px-24"}`)
316
341
  }, {
317
- default: i(() => [
318
- s(e(B), null, {
319
- "menu-button": i(() => [
320
- s(e(K), { class: "fm-typo-en-body-md-600 text-fm-color-neutral-gray-400" }, {
321
- default: i(() => [
322
- h("p", null, J(e(a)(`report.category.${D.value.label}`)), 1),
323
- s(e(E), { name: "expand_more" })
342
+ default: m(() => [
343
+ l(e(U), null, {
344
+ "menu-button": m(() => [
345
+ l(e(K), { class: "fm-typo-en-body-md-600 text-fm-color-neutral-gray-400" }, {
346
+ default: m(() => [
347
+ h("p", null, A(e(a)(`report.category.${O.value.label}`)), 1),
348
+ l(e(E), { name: "expand_more" })
324
349
  ]),
325
350
  _: 1
326
351
  })
327
352
  ]),
328
- default: i(() => [
329
- (A(!0), _e(Ie, null, $e(ae.value, (r, V) => (A(), j(e(C), {
330
- key: V,
353
+ default: m(() => [
354
+ (V(!0), Re(De, null, Fe(re.value, (r, c) => (V(), G(e(S), {
355
+ key: c,
331
356
  label: e(a)(`report.category.${r.label}`),
332
- onClick: () => Se(r)
357
+ onClick: () => we(r)
333
358
  }, null, 8, ["label", "onClick"]))), 128))
334
359
  ]),
335
360
  _: 1
336
361
  }),
337
362
  h("div", {
338
- class: x(`flex ${e(c).sm || e(c).xs ? "justify-center items-center" : ""}`)
363
+ class: _(`flex ${e(i).sm || e(i).xs ? "justify-center items-center" : ""}`)
339
364
  }, [
340
- h("p", Me, J(e(a)("report.common.results", { count: k.value.length })), 1)
365
+ h("p", je, A(e(a)("report.common.results", { count: k.value.length })), 1)
341
366
  ], 2),
342
367
  t[3] || (t[3] = h("div", { class: "grow" }, null, -1)),
343
- h("div", Ye, [
344
- s(l, {
368
+ h("div", Ge, [
369
+ l(s, {
345
370
  modelValue: M.value,
346
371
  "onUpdate:modelValue": t[1] || (t[1] = (r) => M.value = r),
347
- class: x(`${e(c).lg || e(c).md ? "grow" : ""}`)
372
+ class: _(`${e(i).lg || e(i).md ? "grow" : ""}`)
348
373
  }, null, 8, ["modelValue", "class"])
349
374
  ])
350
375
  ]),
351
376
  _: 1
352
377
  }, 8, ["class"]),
353
- G((A(), j(u, {
354
- key: ye.value,
378
+ H((V(), G(q, {
379
+ key: he.value,
355
380
  ref_key: "table",
356
- ref: S,
357
- class: x([e(c).sm || e(c).xs ? "px-0" : "px-24", "report-table"]),
381
+ ref: C,
382
+ class: _([e(i).sm || e(i).xs ? "px-0" : "px-24", "report-table"]),
358
383
  style: { height: "calc(100% - 40px)" },
359
- "column-defs": ge.value,
384
+ "column-defs": Ce.value,
360
385
  "row-data": k.value,
361
386
  "page-size": k.value.length,
362
387
  "hide-footer": !0,
363
388
  "row-class-name": "row",
364
389
  onRowClick: t[2] || (t[2] = (r) => {
365
- e(de).suppressReportRouteSync = !0, e(p).updateCurrentReportId(r.original.reportId), e(W).push({
390
+ e(pe).suppressReportRouteSync = !0, e(p).updateCurrentReportId(r.original.reportId), e(X).push({
366
391
  name: "reportView",
367
392
  query: {
368
- ...e(X).query,
393
+ ...e(Z).query,
369
394
  reportId: r.original.reportId,
370
- startDate: e(F).startDate,
371
- endDate: e(F).endDate,
372
- compareStartDate: e(O).startDate,
373
- compareEndDate: e(O).endDate,
395
+ startDate: e(L).startDate,
396
+ endDate: e(L).endDate,
397
+ compareStartDate: e(N).startDate,
398
+ compareEndDate: e(N).endDate,
374
399
  timeStart: e(v).start ? JSON.stringify(e(v).start) : null,
375
400
  timeEnd: e(v).end ? JSON.stringify(e(v).end) : null,
376
- isAllLocation: L.value.toString(),
377
- locationIds: L.value ? void 0 : e(_) ? JSON.stringify(e(_)) : void 0
401
+ isAllLocation: P.value.toString(),
402
+ locationIds: P.value ? void 0 : e(I) ? JSON.stringify(e(I)) : void 0
378
403
  }
379
404
  });
380
405
  })
381
406
  }, {
382
- "list-row": i(({ original: r }) => [
383
- s(N, {
407
+ "list-row": m(({ original: r }) => [
408
+ l($, {
384
409
  onClick: () => {
385
- r.reportId && (e(p).updateCurrentReportId(r.reportId), e(W).push({
410
+ r.reportId && (e(p).updateCurrentReportId(r.reportId), e(X).push({
386
411
  name: "reportView",
387
412
  query: {
388
- ...e(X).query,
413
+ ...e(Z).query,
389
414
  reportId: r.reportId,
390
- startDate: e(F).startDate,
391
- endDate: e(F).endDate,
392
- compareStartDate: e(O).startDate,
393
- compareEndDate: e(O).endDate,
415
+ startDate: e(L).startDate,
416
+ endDate: e(L).endDate,
417
+ compareStartDate: e(N).startDate,
418
+ compareEndDate: e(N).endDate,
394
419
  timeStart: e(v).start ? JSON.stringify(e(v).start) : null,
395
420
  timeEnd: e(v).end ? JSON.stringify(e(v).end) : null,
396
- isAllLocation: L.value.toString(),
397
- locationIds: L.value ? void 0 : e(_) ? JSON.stringify(e(_)) : void 0
421
+ isAllLocation: P.value.toString(),
422
+ locationIds: P.value ? void 0 : e(I) ? JSON.stringify(e(I)) : void 0
398
423
  }
399
424
  }));
400
425
  }
401
426
  }, {
402
- default: i(() => [
403
- s(q, {
427
+ default: m(() => [
428
+ l(w, {
404
429
  tag: "label",
405
430
  label: r.name,
406
431
  clickable: ""
407
432
  }, {
408
- append: i(() => [
409
- s(e(K), {
410
- class: x(
433
+ append: m(() => [
434
+ l(e(K), {
435
+ class: _(
411
436
  r.category !== "Uncategorized" ? "bg-fm-color-system-info-100 text-fm-color-typo-info" : "text-fm-color-typo-secondary"
412
437
  ),
413
438
  compact: !0
414
439
  }, {
415
- default: i(() => [
416
- h("p", qe, J(r.category), 1)
440
+ default: m(() => [
441
+ h("p", He, A(r.category), 1)
417
442
  ]),
418
443
  _: 2
419
444
  }, 1032, ["class"]),
420
- s(e(B), {
445
+ l(e(U), {
421
446
  placement: "left",
422
447
  "stop-click-propagation": !0
423
448
  }, {
424
- "menu-button": i(() => [
425
- s(e(E), {
449
+ "menu-button": m(() => [
450
+ l(e(E), {
426
451
  name: "more_vert",
427
452
  class: "btn-color"
428
453
  })
429
454
  ]),
430
- default: i(() => {
431
- var V;
455
+ default: m(() => {
456
+ var c;
432
457
  return [
433
- s(e(C), {
458
+ l(e(S), {
434
459
  label: r.pin ? "Unpin" : "Pin",
435
460
  onClick: () => {
436
- const m = e(f).find(
461
+ const d = e(f).find(
437
462
  (g) => g.id === r.reportId
438
463
  );
439
- m && se(m);
464
+ d && ce(d);
440
465
  }
441
466
  }, null, 8, ["label", "onClick"]),
442
- s(e(C), {
467
+ l(e(S), {
443
468
  label: e(a)("report.common.duplicate"),
444
469
  onClick: () => {
445
- const m = e(f).find(
470
+ const d = e(f).find(
446
471
  (g) => g.id === r.reportId
447
472
  );
448
- m && le(m);
473
+ d && ie(d);
449
474
  }
450
475
  }, null, 8, ["label", "onClick"]),
451
- s(e(C), {
476
+ l(e(S), {
452
477
  label: e(a)(
453
- r.reportId === ((V = e(z)) == null ? void 0 : V.id) ? "report.common.unsetAsOverview" : "report.common.setAsOverview"
478
+ r.reportId === ((c = e(z)) == null ? void 0 : c.id) ? "report.common.unsetAsOverview" : "report.common.setAsOverview"
454
479
  ),
455
480
  onClick: () => {
456
- const m = e(f).find(
481
+ const d = e(f).find(
457
482
  (g) => g.id === r.reportId
458
483
  );
459
- m && ne(m);
484
+ d && se(d);
460
485
  }
461
486
  }, null, 8, ["label", "onClick"]),
462
- G(s(e(C), {
487
+ H(l(e(S), {
463
488
  label: e(a)("report.common.delete"),
464
489
  class: "text-fm-color-typo-error",
465
490
  onClick: () => {
466
- const m = e(f).find(
491
+ const d = e(f).find(
467
492
  (g) => g.id === r.reportId
468
493
  );
469
- m && re(m);
494
+ d && le(d);
470
495
  }
471
496
  }, {
472
- label: i(() => [
473
- Re(J(e(a)("report.common.delete")), 1)
497
+ label: m(() => [
498
+ Oe(A(e(a)("report.common.delete")), 1)
474
499
  ]),
475
500
  _: 2
476
501
  }, 1032, ["label", "onClick"]), [
477
- [H, r.editable]
502
+ [Q, r.editable]
478
503
  ])
479
504
  ];
480
505
  }),
@@ -489,10 +514,10 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
489
514
  ]),
490
515
  _: 1
491
516
  }, 8, ["class", "column-defs", "row-data", "page-size"])), [
492
- [H, k.value.length > 0]
517
+ [Q, k.value.length > 0]
493
518
  ]),
494
- G(s(Pe, null, null, 512), [
495
- [H, k.value.length === 0]
519
+ H(l(Ue, null, null, 512), [
520
+ [Q, k.value.length === 0]
496
521
  ])
497
522
  ], 6)
498
523
  ]),
@@ -502,5 +527,5 @@ const Me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ye
502
527
  }
503
528
  });
504
529
  export {
505
- nt as default
530
+ ct as default
506
531
  };