@feedmepos/mf-report 5.22.14-beta.2 → 5.22.15-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 (30) hide show
  1. package/dist/{App-Cwppqefm.js → App-BQhR0gXI.js} +5 -5
  2. package/dist/{BaseDialog.vue_vue_type_script_setup_true_lang-CcKWqqNP.js → BaseDialog.vue_vue_type_script_setup_true_lang-CoJrINGt.js} +1890 -1838
  3. package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-CryPHoYr.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-HVO_Z_aB.js} +7 -7
  4. package/dist/{Default.vue_vue_type_script_setup_true_lang-DU3zkEF1.js → Default.vue_vue_type_script_setup_true_lang-B0td3xNS.js} +2 -2
  5. package/dist/{FilterSelector.vue_vue_type_script_setup_true_lang-CyW-5xr4.js → FilterSelector.vue_vue_type_script_setup_true_lang-DB7d9t3_.js} +6 -6
  6. package/dist/{InsightView-DAnaBH3D.js → InsightView-CitbD8mF.js} +6 -6
  7. package/dist/{Integration-DiNs52W5.js → Integration-DjnNmveS.js} +6 -7
  8. package/dist/{Integrations-BvgLRF5N.js → Integrations-BKYeENnK.js} +6 -7
  9. package/dist/{Layout-BAYV4nCo.js → Layout-5TdGrp8j.js} +1 -1
  10. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-BZphMQGv.js → MenuTab.vue_vue_type_script_setup_true_lang-DkiUvM56.js} +5 -5
  11. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-DSTG-gQ3.js → NavigationTab.vue_vue_type_script_setup_true_lang-CifNNsqR.js} +3120 -3095
  12. package/dist/{NoData.vue_vue_type_script_setup_true_lang-zS79GrjC.js → NoData.vue_vue_type_script_setup_true_lang-Uei_Jstp.js} +1 -1
  13. package/dist/{OverviewView-CvRMdLbB.js → OverviewView-DZoL2KUz.js} +5 -5
  14. package/dist/{Report-C6445626.js → Report-D_9Db2Pa.js} +216 -187
  15. package/dist/{ReportEditor-Cy8f2WFu.js → ReportEditor-VGOkYidh.js} +65 -65
  16. package/dist/{ReportView-D-T3b10U.js → ReportView-B9PQlaFs.js} +22 -22
  17. package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-CYDZzbCU.js → SelectComponent.vue_vue_type_script_setup_true_lang-UhEjUKRz.js} +1 -1
  18. package/dist/{Setting-DBzyuCx-.js → Setting-BpStivU1.js} +5 -5
  19. package/dist/{TileEditor-CWYE5X71.js → TileEditor-CYwZNqhl.js} +110 -110
  20. package/dist/{TransitionFade-DwQjFIYA.js → TransitionFade-Cmxee7D0.js} +6 -6
  21. package/dist/{app-BRv3iLF1.js → app-BXEgzj0c.js} +11 -11
  22. package/dist/app.js +1 -1
  23. package/dist/style.css +1 -1
  24. package/dist/useReportPermission-B_CqU5GP.js +63 -0
  25. package/dist/useRestaurantPermission-DIlTzfKA.js +64 -0
  26. package/dist/{vue-i18n-ComGWqEb.js → vue-i18n-mTXrqqL9.js} +4477 -3241
  27. package/package.json +2 -2
  28. package/dist/access-Dw5cDt65-C2c0R9q4.js +0 -1238
  29. package/dist/useReportPermission-CDWkdi6R.js +0 -60
  30. package/dist/useRestaurantPermission-CjG_t7dK.js +0 -65
@@ -1,15 +1,15 @@
1
- import { defineComponent as Q, mergeModels as K, useModel as A, ref as B, computed as O, resolveComponent as p, createBlock as F, openBlock as u, withCtx as m, createElementVNode as h, createVNode as n, unref as t, normalizeClass as de, createTextVNode as xe, toDisplayString as P, createElementBlock as T, Fragment as H, renderSlot as Me, createCommentVNode as G, watch as fe, renderList as ee, resolveDynamicComponent as Pe, isRef as Ue, normalizeStyle as ke, onMounted as ze } from "vue";
2
- import { W as Je, g as Le, _ as He, i as Ge, S as Se, d as $e, T as je, a as Ke } from "./TransitionFade-DwQjFIYA.js";
3
- import { D as L, c as ve, C as he, a as De, b as Ae, v as ue } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CcKWqqNP.js";
1
+ import { defineComponent as Q, mergeModels as K, useModel as A, ref as B, computed as O, resolveComponent as p, createBlock as x, openBlock as u, withCtx as m, createElementVNode as h, createVNode as n, unref as t, normalizeClass as de, createTextVNode as xe, toDisplayString as P, createElementBlock as T, Fragment as H, renderSlot as Me, createCommentVNode as j, watch as fe, renderList as ee, resolveDynamicComponent as Pe, isRef as Ue, normalizeStyle as ke, onMounted as ze } from "vue";
2
+ import { W as Je, g as Le, _ as He, i as je, S as Se, d as $e, T as Ge, a as Ke } from "./TransitionFade-Cmxee7D0.js";
3
+ import { D as L, c as ve, C as he, a as De, b as Ae, v as ue } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CoJrINGt.js";
4
4
  import { storeToRefs as ge } from "pinia";
5
5
  import { useRouter as Be, useRoute as Ie } from "vue-router";
6
6
  import { useBreakpoints as be, useSnackbar as Re, FmButtonColorThemeVariant as re } from "@feedmepos/ui-library";
7
7
  import { u as We } from "./message-dialog-UoMWOnil.js";
8
- import { u as ce, b as Qe, i as we, e as Xe } from "./vue-i18n-ComGWqEb.js";
8
+ import { u as ce, b as Qe, j as we, e as Xe } from "./vue-i18n-mTXrqqL9.js";
9
9
  import { r as me } from "./i18n-CI_sQ5d_.js";
10
- import { a as Te, _ as _e } from "./FilterSelector.vue_vue_type_script_setup_true_lang-CyW-5xr4.js";
11
- import { _ as Fe } from "./NoData.vue_vue_type_script_setup_true_lang-zS79GrjC.js";
12
- import { a as Oe } from "./SelectComponent.vue_vue_type_script_setup_true_lang-CYDZzbCU.js";
10
+ import { a as Te, _ as _e } from "./FilterSelector.vue_vue_type_script_setup_true_lang-DB7d9t3_.js";
11
+ import { _ as Fe } from "./NoData.vue_vue_type_script_setup_true_lang-Uei_Jstp.js";
12
+ import { a as Oe } from "./SelectComponent.vue_vue_type_script_setup_true_lang-UhEjUKRz.js";
13
13
  const Ye = /* @__PURE__ */ Q({
14
14
  __name: "WidgetDialog",
15
15
  props: /* @__PURE__ */ K({
@@ -30,7 +30,7 @@ const Ye = /* @__PURE__ */ Q({
30
30
  const d = B(), I = O(() => !d.value);
31
31
  return (q, S) => {
32
32
  const U = p("FmButton"), v = p("FmDialog");
33
- return u(), F(v, {
33
+ return u(), x(v, {
34
34
  "model-value": c.isOpen
35
35
  }, {
36
36
  "dialog-header": m(() => [
@@ -118,7 +118,7 @@ const Ye = /* @__PURE__ */ Q({
118
118
  const s = A(k, "modelValue");
119
119
  return (r, i) => {
120
120
  const w = p("FmTopSheet"), c = p("FmCard");
121
- return u(), F(c, { class: "fixed bottom-0 w-full" }, {
121
+ return u(), x(c, { class: "fixed bottom-0 w-full" }, {
122
122
  default: m(() => [
123
123
  n(Ve, {
124
124
  modelValue: s.value,
@@ -136,7 +136,7 @@ const Ye = /* @__PURE__ */ Q({
136
136
  "onUpdate:modelValue": i[1] || (i[1] = (_) => s.value = _),
137
137
  icon: "keyboard_double_arrow_down"
138
138
  }, null, 8, ["modelValue"]),
139
- s.value ? Me(r.$slots, "default", { key: 0 }) : G("", !0)
139
+ s.value ? Me(r.$slots, "default", { key: 0 }) : j("", !0)
140
140
  ]),
141
141
  _: 3
142
142
  }, 8, ["modelValue"])
@@ -171,18 +171,18 @@ const Ye = /* @__PURE__ */ Q({
171
171
  setup(k) {
172
172
  const { t: s, te: r } = ce(), i = A(k, "globalFilter"), w = A(k, "isOpen"), c = Re(), _ = k, M = B(), g = B(), d = B(), I = B(), q = B([]), S = B([]), U = B(""), v = B(!1);
173
173
  fe(w, (o) => {
174
- var e, x, R, W, a, l, $;
174
+ var e, F, R, W, a, l, $;
175
175
  o && (M.value = ((e = i.value) == null ? void 0 : e.label) || "", g.value = _.schemas.find(
176
176
  (V) => {
177
177
  var f;
178
178
  return V.name === ((f = i.value) == null ? void 0 : f.schemaName);
179
179
  }
180
- ), d.value = (x = le.value.find(
180
+ ), d.value = (F = le.value.find(
181
181
  (V) => {
182
182
  var f;
183
183
  return V.value.name === ((f = i.value) == null ? void 0 : f.name);
184
184
  }
185
- )) == null ? void 0 : x.value, I.value = (R = i.value) == null ? void 0 : R.option, q.value = ((W = i.value) == null ? void 0 : W.tileIds) || [], S.value = ((a = i.value) == null ? void 0 : a.filters) || [], v.value = !!((l = i.value) != null && l.dataFormula), U.value = (($ = i.value) == null ? void 0 : $.dataFormula) || "");
185
+ )) == null ? void 0 : F.value, I.value = (R = i.value) == null ? void 0 : R.option, q.value = ((W = i.value) == null ? void 0 : W.tileIds) || [], S.value = ((a = i.value) == null ? void 0 : a.filters) || [], v.value = !!((l = i.value) != null && l.dataFormula), U.value = (($ = i.value) == null ? void 0 : $.dataFormula) || "");
186
186
  });
187
187
  const N = O(
188
188
  () => _.schemas.map((o) => ({
@@ -198,13 +198,13 @@ const Ye = /* @__PURE__ */ Q({
198
198
  }), te = O(() => {
199
199
  var o;
200
200
  return ((o = d.value) == null ? void 0 : o.type) !== L.Timestamp ? [] : Le(s);
201
- }), z = O(() => _.tiles.reduce((o, e, x) => {
201
+ }), z = O(() => _.tiles.reduce((o, e, F) => {
202
202
  var a, l;
203
203
  const R = e.widget.config.schemaNames ?? [], W = (e.widget.config.joinDatasources ?? []).flatMap(
204
204
  ($) => $.schemaNames ?? []
205
205
  );
206
206
  return [...R, ...W].includes(((a = g.value) == null ? void 0 : a.name) || "") && o.push({
207
- label: (l = e == null ? void 0 : e.widget.title) != null && l.trim() ? e.widget.title : `Widget ${x + 1}`,
207
+ label: (l = e == null ? void 0 : e.widget.title) != null && l.trim() ? e.widget.title : `Widget ${F + 1}`,
208
208
  value: e.id
209
209
  }), o;
210
210
  }, [])), D = O(
@@ -225,7 +225,7 @@ const Ye = /* @__PURE__ */ Q({
225
225
  function J(o) {
226
226
  d.value = o, I.value = o.type === L.Timestamp ? ve.DateTime : void 0;
227
227
  }
228
- function j(o, e) {
228
+ function G(o, e) {
229
229
  switch (o) {
230
230
  case L.Timestamp:
231
231
  return e === ve.DateTime || e === ve.TimeOfDay ? he.Between : he.Equal;
@@ -260,7 +260,7 @@ const Ye = /* @__PURE__ */ Q({
260
260
  schemaName: g.value.name,
261
261
  name: d.value.name,
262
262
  label: M.value,
263
- operator: j(
263
+ operator: G(
264
264
  d.value.type,
265
265
  d.value.type === L.Timestamp ? I.value ?? ve.DateTime : null
266
266
  ),
@@ -283,14 +283,14 @@ const Ye = /* @__PURE__ */ Q({
283
283
  });
284
284
  function ie(o) {
285
285
  var a, l, $, V;
286
- const e = _.tiles.find((f) => f.id === o.value), x = ((l = (a = e == null ? void 0 : e.widget) == null ? void 0 : a.config) == null ? void 0 : l.schemaNames) ?? [], R = (((V = ($ = e == null ? void 0 : e.widget) == null ? void 0 : $.config) == null ? void 0 : V.joinDatasources) ?? []).flatMap(
286
+ const e = _.tiles.find((f) => f.id === o.value), F = ((l = (a = e == null ? void 0 : e.widget) == null ? void 0 : a.config) == null ? void 0 : l.schemaNames) ?? [], R = (((V = ($ = e == null ? void 0 : e.widget) == null ? void 0 : $.config) == null ? void 0 : V.joinDatasources) ?? []).flatMap(
287
287
  (f) => f.schemaNames ?? []
288
- ), W = [...x, ...R];
288
+ ), W = [...F, ...R];
289
289
  return ae.value.filter((f) => !!f).some((f) => !W.includes(f));
290
290
  }
291
291
  return (o, e) => {
292
- const x = p("FmTextField"), R = p("FmSelect"), W = p("FmCheckbox"), a = p("FmTextarea"), l = p("FmLabel"), $ = p("FmIcon"), V = p("FmTooltip"), f = p("FmForm"), E = p("FmButton"), ne = p("FmDialog");
293
- return u(), F(ne, {
292
+ const F = p("FmTextField"), R = p("FmSelect"), W = p("FmCheckbox"), a = p("FmTextarea"), l = p("FmLabel"), $ = p("FmIcon"), V = p("FmTooltip"), f = p("FmForm"), E = p("FmButton"), ne = p("FmDialog");
293
+ return u(), x(ne, {
294
294
  modelValue: w.value,
295
295
  "onUpdate:modelValue": e[8] || (e[8] = (Y) => w.value = Y),
296
296
  overlay: !0,
@@ -307,7 +307,7 @@ const Ye = /* @__PURE__ */ Q({
307
307
  default: m(() => {
308
308
  var Y;
309
309
  return [
310
- n(x, {
310
+ n(F, {
311
311
  modelValue: M.value,
312
312
  "onUpdate:modelValue": e[0] || (e[0] = (C) => M.value = C),
313
313
  placeholder: t(s)("report.section.filter.displayName"),
@@ -328,26 +328,26 @@ const Ye = /* @__PURE__ */ Q({
328
328
  label: t(s)("report.section.dimension.title"),
329
329
  "onUpdate:modelValue": e[2] || (e[2] = (C) => J(C))
330
330
  }, null, 8, ["model-value", "items", "placeholder", "label"]),
331
- ((Y = d.value) == null ? void 0 : Y.type) === t(L).Timestamp ? (u(), F(R, {
331
+ ((Y = d.value) == null ? void 0 : Y.type) === t(L).Timestamp ? (u(), x(R, {
332
332
  key: 0,
333
333
  modelValue: I.value,
334
334
  "onUpdate:modelValue": e[3] || (e[3] = (C) => I.value = C),
335
335
  items: te.value,
336
336
  placeholder: t(s)("report.section.filter.timeFormatter"),
337
337
  label: t(s)("report.section.filter.timeFormatter")
338
- }, null, 8, ["modelValue", "items", "placeholder", "label"])) : G("", !0),
338
+ }, null, 8, ["modelValue", "items", "placeholder", "label"])) : j("", !0),
339
339
  n(W, {
340
340
  modelValue: v.value,
341
341
  "onUpdate:modelValue": e[4] || (e[4] = (C) => v.value = C),
342
342
  label: t(s)("report.section.filter.advance"),
343
343
  value: !0
344
344
  }, null, 8, ["modelValue", "label"]),
345
- v.value ? (u(), F(a, {
345
+ v.value ? (u(), x(a, {
346
346
  key: 1,
347
347
  modelValue: U.value,
348
348
  "onUpdate:modelValue": e[5] || (e[5] = (C) => U.value = C),
349
349
  placeholder: t(s)("report.section.filter.dataFormula")
350
- }, null, 8, ["modelValue", "placeholder"])) : G("", !0),
350
+ }, null, 8, ["modelValue", "placeholder"])) : j("", !0),
351
351
  n(He, {
352
352
  modelValue: S.value,
353
353
  "onUpdate:modelValue": e[6] || (e[6] = (C) => S.value = C),
@@ -370,7 +370,7 @@ const Ye = /* @__PURE__ */ Q({
370
370
  label: C.label,
371
371
  value: C.value
372
372
  }, null, 8, ["modelValue", "label", "value"]),
373
- ie(C) ? (u(), F(V, {
373
+ ie(C) ? (u(), x(V, {
374
374
  key: 0,
375
375
  content: t(s)("report.section.filter.missingFilterSchema"),
376
376
  "z-index": 99,
@@ -383,9 +383,9 @@ const Ye = /* @__PURE__ */ Q({
383
383
  })
384
384
  ]),
385
385
  _: 1
386
- }, 8, ["content"])) : G("", !0)
386
+ }, 8, ["content"])) : j("", !0)
387
387
  ]))), 128))
388
- ])) : (u(), F(l, {
388
+ ])) : (u(), x(l, {
389
389
  key: 3,
390
390
  class: "fm-typo-en-body-lg-400",
391
391
  label: t(s)("report.section.filter.noWidget")
@@ -431,7 +431,7 @@ const Ye = /* @__PURE__ */ Q({
431
431
  editingTileIndex: S,
432
432
  editingGlobalFilter: U,
433
433
  editingGlobalFilterIndex: v
434
- } = ge(De()), { schemas: N } = ge(Ae()), { globalFilters: le } = ge(Qe()), { promptMessage: te } = We(), z = B(!1), D = B(!1), { t: b, te: J, locale: j } = ce(), X = B(void 0), oe = O(() => {
434
+ } = ge(De()), { schemas: N } = ge(Ae()), { globalFilters: le } = ge(Qe()), { promptMessage: te } = We(), z = B(!1), D = B(!1), { t: b, te: J, locale: G } = ce(), X = B(void 0), oe = O(() => {
435
435
  const a = r.value.tiles.flatMap((l) => {
436
436
  var f;
437
437
  const $ = l.widget.config.schemaNames ?? [], V = ((f = l.widget.config.joinDatasources) == null ? void 0 : f.flatMap((E) => E.schemaNames ?? [])) ?? [];
@@ -450,7 +450,7 @@ const Ye = /* @__PURE__ */ Q({
450
450
  fe(
451
451
  () => d.value,
452
452
  () => {
453
- d.value !== void 0 && (X.value = Ge(d.value), q.value = X.value, S.value = -1, _.push({
453
+ d.value !== void 0 && (X.value = je(d.value), q.value = X.value, S.value = -1, _.push({
454
454
  name: "tileEditor",
455
455
  query: M.query
456
456
  }));
@@ -537,7 +537,7 @@ const Ye = /* @__PURE__ */ Q({
537
537
  ], e = O(() => I.value.map((a) => ({
538
538
  label: b(`report.category.${a.name}`),
539
539
  value: a.id
540
- }))), x = O({
540
+ }))), F = O({
541
541
  get: () => me(b, J, r.value.name, "other"),
542
542
  set: (a) => {
543
543
  r.value.name = a;
@@ -558,7 +558,7 @@ const Ye = /* @__PURE__ */ Q({
558
558
  { deep: !0, immediate: !0 }
559
559
  ), (a, l) => {
560
560
  const $ = p("FmTextField"), V = p("FmSelect"), f = p("FmButton"), E = p("FmIcon"), ne = p("FmTooltip"), Y = p("FmMenuItem"), C = p("FmMenu"), pe = p("FmListItem"), Ce = p("FmList"), qe = p("FmForm");
561
- return u(), F(Pe(t(i).lg || t(i).md ? el : ll), {
561
+ return u(), x(Pe(t(i).lg || t(i).md ? el : ll), {
562
562
  "model-value": w.hideConfiguration,
563
563
  "onUpdate:modelValue": l[9] || (l[9] = (y) => c("hideConfiguration", y))
564
564
  }, {
@@ -593,17 +593,17 @@ const Ye = /* @__PURE__ */ Q({
593
593
  content: m(() => [
594
594
  h("div", al, [
595
595
  n($, {
596
- modelValue: x.value,
597
- "onUpdate:modelValue": l[4] || (l[4] = (y) => x.value = y),
596
+ modelValue: F.value,
597
+ "onUpdate:modelValue": l[4] || (l[4] = (y) => F.value = y),
598
598
  label: t(b)("report.common.name"),
599
599
  placeholder: t(b)("report.common.name")
600
600
  }, null, 8, ["modelValue", "label", "placeholder"]),
601
- (u(), F(V, {
601
+ (u(), x(V, {
602
602
  modelValue: r.value.category,
603
603
  "onUpdate:modelValue": l[5] || (l[5] = (y) => r.value.category = y),
604
604
  label: t(b)("report.common.category"),
605
605
  items: e.value,
606
- key: `category-${t(j)}`
606
+ key: `category-${t(G)}`
607
607
  }, null, 8, ["modelValue", "label", "items"])),
608
608
  n($, {
609
609
  modelValue: r.value.description,
@@ -662,7 +662,7 @@ const Ye = /* @__PURE__ */ Q({
662
662
  ]),
663
663
  _: 2
664
664
  }, 1032, ["content"]),
665
- W(y) ? (u(), F(ne, {
665
+ W(y) ? (u(), x(ne, {
666
666
  key: 0,
667
667
  content: t(b)("report.section.filter.missingSchema"),
668
668
  "z-index": 99
@@ -674,7 +674,7 @@ const Ye = /* @__PURE__ */ Q({
674
674
  })
675
675
  ]),
676
676
  _: 1
677
- }, 8, ["content"])) : R(y) ? (u(), F(ne, {
677
+ }, 8, ["content"])) : R(y) ? (u(), x(ne, {
678
678
  key: 1,
679
679
  content: t(b)("report.section.filter.missingTileIds"),
680
680
  "z-index": 99
@@ -686,7 +686,7 @@ const Ye = /* @__PURE__ */ Q({
686
686
  })
687
687
  ]),
688
688
  _: 1
689
- }, 8, ["content"])) : G("", !0)
689
+ }, 8, ["content"])) : j("", !0)
690
690
  ]),
691
691
  l[12] || (l[12] = h("div", { class: "grow" }, null, -1)),
692
692
  n(C, {
@@ -846,19 +846,19 @@ const Ye = /* @__PURE__ */ Q({
846
846
  const I = p("FmCircularProgress"), q = p("FmButton"), S = p("FmMenuDivider"), U = p("FmCard");
847
847
  return u(), T("div", dl, [
848
848
  i.value ? (u(), T(H, { key: 1 }, [
849
- c.value ? G("", !0) : (u(), F(je, {
849
+ c.value ? j("", !0) : (u(), x(Ge, {
850
850
  key: 0,
851
851
  "model-value": !w.hideConfiguration
852
852
  }, {
853
853
  right: m(() => [
854
854
  h("div", ml, [
855
- i.value ? (u(), F(Ne, {
855
+ i.value ? (u(), x(Ne, {
856
856
  key: 0,
857
857
  modelValue: i.value,
858
858
  "onUpdate:modelValue": d[0] || (d[0] = (v) => i.value = v),
859
859
  "hide-configuration": w.hideConfiguration,
860
860
  onHideConfiguration: d[1] || (d[1] = (v) => M("hideConfiguration", v))
861
- }, null, 8, ["modelValue", "hide-configuration"])) : G("", !0)
861
+ }, null, 8, ["modelValue", "hide-configuration"])) : j("", !0)
862
862
  ])
863
863
  ]),
864
864
  left: m(() => [
@@ -885,13 +885,13 @@ const Ye = /* @__PURE__ */ Q({
885
885
  h("div", fl, [
886
886
  n(Te)
887
887
  ]),
888
- (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), F(_e, {
888
+ (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), x(_e, {
889
889
  key: `${t(ue)()}_${N}`,
890
890
  "model-value": v,
891
891
  index: N,
892
892
  "hide-export": !0
893
893
  }, null, 8, ["model-value", "index"]))), 128))
894
- ])) : (u(), F(Fe, { key: 1 }))
894
+ ])) : (u(), x(Fe, { key: 1 }))
895
895
  ])) : _.value && !c.value ? (u(), T("div", gl, [
896
896
  n(U, { class: "px-5 pb-28" }, {
897
897
  default: m(() => [
@@ -899,17 +899,17 @@ const Ye = /* @__PURE__ */ Q({
899
899
  h("div", yl, [
900
900
  n(Te)
901
901
  ]),
902
- (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), F(_e, {
902
+ (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), x(_e, {
903
903
  key: `${t(ue)()}_${N}`,
904
904
  "model-value": v,
905
905
  index: N,
906
906
  "hide-export": !0
907
907
  }, null, 8, ["model-value", "index"]))), 128))
908
- ])) : (u(), F(Fe, { key: 1 }))
908
+ ])) : (u(), x(Fe, { key: 1 }))
909
909
  ]),
910
910
  _: 1
911
911
  }),
912
- i.value ? (u(), F(Ne, {
912
+ i.value ? (u(), x(Ne, {
913
913
  key: 0,
914
914
  modelValue: i.value,
915
915
  "onUpdate:modelValue": d[3] || (d[3] = (v) => i.value = v),
@@ -917,7 +917,7 @@ const Ye = /* @__PURE__ */ Q({
917
917
  onHideConfiguration: d[4] || (d[4] = (v) => {
918
918
  M("hideConfiguration", v);
919
919
  })
920
- }, null, 8, ["modelValue", "hide-configuration"])) : G("", !0)
920
+ }, null, 8, ["modelValue", "hide-configuration"])) : j("", !0)
921
921
  ])) : (u(), T("div", hl, [
922
922
  h("div", {
923
923
  style: ke({
@@ -933,18 +933,18 @@ const Ye = /* @__PURE__ */ Q({
933
933
  })
934
934
  }, [
935
935
  i.value.tiles.length > 0 ? (u(), T("div", wl, [
936
- (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), F(_e, {
936
+ (u(!0), T(H, null, ee(i.value.tiles, (v, N) => (u(), x(_e, {
937
937
  key: `${t(ue)()}_${N}`,
938
938
  "model-value": v,
939
939
  index: N,
940
940
  "hide-export": !0,
941
941
  "custom-screen-width": w.previewWidth
942
942
  }, null, 8, ["model-value", "index", "custom-screen-width"]))), 128))
943
- ])) : (u(), F(Fe, { key: 1 }))
943
+ ])) : (u(), x(Fe, { key: 1 }))
944
944
  ], 4)
945
945
  ], 4)
946
946
  ]))
947
- ], 64)) : (u(), F(I, { key: 0 }))
947
+ ], 64)) : (u(), x(I, { key: 0 }))
948
948
  ]);
949
949
  };
950
950
  }
@@ -971,8 +971,8 @@ const Ye = /* @__PURE__ */ Q({
971
971
  try {
972
972
  await w(async () => {
973
973
  if (I.value) {
974
- const x = JSON.parse(JSON.stringify(g.value));
975
- x.editable = !0, x.id = "", x.name = `${x.name} ${c("report.common.duplicate")}`, await i.createOrUpdateReport(x);
974
+ const F = JSON.parse(JSON.stringify(g.value));
975
+ F.editable = !0, F.id = "", F.name = `${F.name} ${c("report.common.duplicate")}`, F.isDefault = !1, await i.createOrUpdateReport(F);
976
976
  } else
977
977
  g.value && await i.createOrUpdateReport(g.value);
978
978
  s.push({
@@ -980,8 +980,8 @@ const Ye = /* @__PURE__ */ Q({
980
980
  query: r.query
981
981
  });
982
982
  });
983
- } catch (x) {
984
- console.log(x), U.open({
983
+ } catch (F) {
984
+ console.log(F), U.open({
985
985
  message: c("report.messages.failedToAction", { action: o }),
986
986
  type: "error"
987
987
  });
@@ -1019,10 +1019,10 @@ const Ye = /* @__PURE__ */ Q({
1019
1019
  width: 390,
1020
1020
  height: 859
1021
1021
  }
1022
- ], D = B(z[0]), b = B(!1), J = O(() => b.value ? Math.max(D.value.width || 0, D.value.height || 0) : Math.min(D.value.width || 0, D.value.height || 0)), j = O(() => b.value ? Math.min(D.value.width || 0, D.value.height || 0) : Math.max(D.value.width || 0, D.value.height || 0)), X = O(() => window.innerHeight - 72 - 56), oe = O(() => {
1022
+ ], D = B(z[0]), b = B(!1), J = O(() => b.value ? Math.max(D.value.width || 0, D.value.height || 0) : Math.min(D.value.width || 0, D.value.height || 0)), G = O(() => b.value ? Math.min(D.value.width || 0, D.value.height || 0) : Math.max(D.value.width || 0, D.value.height || 0)), X = O(() => window.innerHeight - 72 - 56), oe = O(() => {
1023
1023
  if (!J.value) return 1;
1024
- let o = (X.value - 48) / J.value, e = j.value * o;
1025
- return e > window.innerWidth && (o = window.innerWidth / j.value, e = j.value * o), o > 1 ? 1 : o;
1024
+ let o = (X.value - 48) / J.value, e = G.value * o;
1025
+ return e > window.innerWidth && (o = window.innerWidth / G.value, e = G.value * o), o > 1 ? 1 : o;
1026
1026
  });
1027
1027
  function ae(o) {
1028
1028
  D.value = o;
@@ -1031,8 +1031,8 @@ const Ye = /* @__PURE__ */ Q({
1031
1031
  b.value = !b.value;
1032
1032
  }
1033
1033
  return (o, e) => {
1034
- const x = p("FmTooltip"), R = p("FmButton"), W = p("FmPageHead");
1035
- return u(), F(Ke, null, {
1034
+ const F = p("FmTooltip"), R = p("FmButton"), W = p("FmPageHead");
1035
+ return u(), x(Ke, null, {
1036
1036
  default: m(() => [
1037
1037
  n(W, {
1038
1038
  actions: [
@@ -1045,7 +1045,7 @@ const Ye = /* @__PURE__ */ Q({
1045
1045
  }, {
1046
1046
  title: m(() => [
1047
1047
  h("div", Fl, [
1048
- n(x, {
1048
+ n(F, {
1049
1049
  content: S.value,
1050
1050
  placement: "bottom"
1051
1051
  }, {
@@ -1081,18 +1081,18 @@ const Ye = /* @__PURE__ */ Q({
1081
1081
  ]),
1082
1082
  _: 1
1083
1083
  }, 8, ["actions"]),
1084
- t(g) ? (u(), F(_l, {
1084
+ t(g) ? (u(), x(_l, {
1085
1085
  key: 0,
1086
1086
  modelValue: t(g),
1087
1087
  "onUpdate:modelValue": e[1] || (e[1] = (a) => Ue(g) ? g.value = a : null),
1088
1088
  style: ke({ height: X.value + "px" }),
1089
1089
  class: de(t(d).lg || t(d).md ? "flex" : ""),
1090
1090
  "hide-configuration": N.value,
1091
- "preview-width": j.value,
1091
+ "preview-width": G.value,
1092
1092
  "preview-height": J.value,
1093
1093
  "preview-scale": oe.value,
1094
1094
  onHideConfiguration: e[2] || (e[2] = (a) => N.value = a)
1095
- }, null, 8, ["modelValue", "style", "class", "hide-configuration", "preview-width", "preview-height", "preview-scale"])) : G("", !0)
1095
+ }, null, 8, ["modelValue", "style", "class", "hide-configuration", "preview-width", "preview-height", "preview-scale"])) : j("", !0)
1096
1096
  ]),
1097
1097
  _: 1
1098
1098
  });
@@ -1,22 +1,22 @@
1
- import { defineComponent as ne, ref as y, computed as m, watch as J, onMounted as se, onUnmounted as le, resolveComponent as ie, createBlock as k, openBlock as v, withCtx as ue, createVNode as N, createElementVNode as T, unref as a, normalizeStyle as ce, normalizeClass as q, createElementBlock as L, Fragment as pe, renderList as me } from "vue";
2
- import { _ as de } from "./MenuTab.vue_vue_type_script_setup_true_lang-BZphMQGv.js";
3
- import { _ as ve } from "./FilterSelector.vue_vue_type_script_setup_true_lang-CyW-5xr4.js";
4
- import { useRouter as fe, useRoute as ge } from "vue-router";
5
- import { _ as ye } from "./Default.vue_vue_type_script_setup_true_lang-DU3zkEF1.js";
6
- import { a as be, s as _e } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CcKWqqNP.js";
1
+ import { defineComponent as ne, ref as y, computed as m, watch as J, onMounted as se, onUnmounted as le, resolveComponent as ie, createBlock as k, openBlock as f, withCtx as ue, createVNode as N, createElementVNode as T, unref as a, normalizeStyle as ce, normalizeClass as q, createElementBlock as L, Fragment as pe, renderList as me } from "vue";
2
+ import { _ as de } from "./MenuTab.vue_vue_type_script_setup_true_lang-DkiUvM56.js";
3
+ import { _ as fe } from "./FilterSelector.vue_vue_type_script_setup_true_lang-DB7d9t3_.js";
4
+ import { useRouter as ve, useRoute as ge } from "vue-router";
5
+ import { _ as ye } from "./Default.vue_vue_type_script_setup_true_lang-B0td3xNS.js";
6
+ import { a as be, s as _e } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CoJrINGt.js";
7
7
  import { storeToRefs as b } from "pinia";
8
- import { b as we, c as Se, u as ke, g as he } from "./NavigationTab.vue_vue_type_script_setup_true_lang-DSTG-gQ3.js";
9
- import { _ as Re } from "./NoData.vue_vue_type_script_setup_true_lang-zS79GrjC.js";
8
+ import { b as we, c as Se, u as ke, g as he } from "./NavigationTab.vue_vue_type_script_setup_true_lang-CifNNsqR.js";
9
+ import { _ as Re } from "./NoData.vue_vue_type_script_setup_true_lang-Uei_Jstp.js";
10
10
  import { useSnackbar as Ce, useBreakpoints as xe } from "@feedmepos/ui-library";
11
- import { u as Pe, e as De, d as Oe } from "./vue-i18n-ComGWqEb.js";
11
+ import { u as Pe, e as De, d as Oe } from "./vue-i18n-mTXrqqL9.js";
12
12
  import { u as Ie } from "./message-dialog-UoMWOnil.js";
13
13
  import { r as $e } from "./i18n-CI_sQ5d_.js";
14
- import { u as Ee } from "./useReportPermission-CDWkdi6R.js";
15
- import { _ as Ae } from "./SelectComponent.vue_vue_type_script_setup_true_lang-CYDZzbCU.js";
14
+ import { u as Ee } from "./useReportPermission-B_CqU5GP.js";
15
+ import { _ as Ae } from "./SelectComponent.vue_vue_type_script_setup_true_lang-UhEjUKRz.js";
16
16
  const Be = /* @__PURE__ */ ne({
17
17
  __name: "ReportView",
18
18
  setup(Je) {
19
- const { t: e, te: V } = Pe(), _ = fe(), f = ge(), i = Ce(), { promptMessage: j } = Ie(), d = be(), h = we(), { promptLoader: w } = De(), { breakpoints: s } = xe(), { isOpenAccountingDialog: F } = b(Se()), { isOpenScheduleDialog: R } = b(ke()), { disabled: C } = b(Oe()), g = y(null), H = y(0), x = y(0);
19
+ const { t: e, te: V } = Pe(), _ = ve(), v = ge(), i = Ce(), { promptMessage: j } = Ie(), d = be(), h = we(), { promptLoader: w } = De(), { breakpoints: s } = xe(), { isOpenAccountingDialog: F } = b(Se()), { isOpenScheduleDialog: R } = b(ke()), { disabled: C } = b(Oe()), g = y(null), H = y(0), x = y(0);
20
20
  let u = null;
21
21
  const P = y(null), D = m(() => {
22
22
  var r;
@@ -116,7 +116,7 @@ const Be = /* @__PURE__ */ ne({
116
116
  }
117
117
  G.value = JSON.parse(JSON.stringify(t.value)), _.push({
118
118
  name: "reportEditor",
119
- query: f.query
119
+ query: v.query
120
120
  });
121
121
  }
122
122
  async function oe() {
@@ -147,14 +147,14 @@ const Be = /* @__PURE__ */ ne({
147
147
  })
148
148
  }) && t.value) {
149
149
  const o = JSON.parse(JSON.stringify(t.value));
150
- o.editable = !0, o.id = "", o.name = `${o.name} duplicate`;
150
+ o.editable = !0, o.id = "", o.name = `${o.name} duplicate`, o.isDefault = !1;
151
151
  try {
152
152
  await w(async () => {
153
153
  const l = await d.createOrUpdateReport(o);
154
154
  d.updateCurrentReportId(l.id), _.push({
155
155
  name: "reportView",
156
- params: f.params,
157
- query: f.query
156
+ params: v.params,
157
+ query: v.query
158
158
  });
159
159
  });
160
160
  } catch (l) {
@@ -214,7 +214,7 @@ const Be = /* @__PURE__ */ ne({
214
214
  });
215
215
  return (r, o) => {
216
216
  const l = ie("FmPageHead");
217
- return v(), k(ye, null, {
217
+ return f(), k(ye, null, {
218
218
  default: ue(() => {
219
219
  var p, A;
220
220
  return [
@@ -222,7 +222,7 @@ const Be = /* @__PURE__ */ ne({
222
222
  title: a($e)(a(e), a(V), (p = a(t)) == null ? void 0 : p.name, "other"),
223
223
  "back-button": !0,
224
224
  actions: ae.value,
225
- "onClick:back": o[0] || (o[0] = (n) => a(_).push({ name: "reports", query: a(f).query })),
225
+ "onClick:back": o[0] || (o[0] = (n) => a(_).push({ name: "reports", query: a(v).query })),
226
226
  "onClick:action": o[1] || (o[1] = (n) => {
227
227
  n === "show_in_pos" && re(), n === "duplicate" && oe(), n === "download" && (Y.value = !0), n === "email" && (z.value = !0), n === "edit" && ee(), n === "schedule_email" && (R.value = !0), n === "content_copy" && te(), n === "export" && $(), n === "report_jobs" && I();
228
228
  }),
@@ -241,17 +241,17 @@ const Be = /* @__PURE__ */ ne({
241
241
  "model-value": a(s).lg || a(s).md ? Z.value : []
242
242
  }, null, 8, ["model-value"])
243
243
  ], 512),
244
- a(t) && ((A = E.value) == null ? void 0 : A.length) > 0 ? (v(), L("div", {
244
+ a(t) && ((A = E.value) == null ? void 0 : A.length) > 0 ? (f(), L("div", {
245
245
  key: 0,
246
246
  class: q(["grid grid-cols-12", a(s).sm || a(s).xs ? "px-3 gap-[16px]" : "px-24 gap-[24px]"])
247
247
  }, [
248
- (v(!0), L(pe, null, me(E.value, (n, B) => (v(), k(ve, {
248
+ (f(!0), L(pe, null, me(E.value, (n, B) => (f(), k(fe, {
249
249
  key: `widget_${a(c)}_${B}`,
250
250
  "model-value": n,
251
251
  index: B,
252
252
  "sticky-header-offset": X.value
253
253
  }, null, 8, ["model-value", "index", "sticky-header-offset"]))), 128))
254
- ], 2)) : (v(), k(Re, { key: 1 }))
254
+ ], 2)) : (f(), k(Re, { key: 1 }))
255
255
  ], 6)
256
256
  ];
257
257
  }),
@@ -259,7 +259,7 @@ const Be = /* @__PURE__ */ ne({
259
259
  });
260
260
  };
261
261
  }
262
- }), Ke = /* @__PURE__ */ Ae(Be, [["__scopeId", "data-v-6ddab9e2"]]);
262
+ }), Ke = /* @__PURE__ */ Ae(Be, [["__scopeId", "data-v-c7321b3d"]]);
263
263
  export {
264
264
  Ke as default
265
265
  };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as B, mergeModels as D, useModel as z, ref as b, computed as f, resolveComponent as n, createBlock as y, openBlock as _, withCtx as m, createElementVNode as c, normalizeStyle as L, withDirectives as U, createElementBlock as $, createVNode as d, unref as E, vShow as H, Fragment as N, renderList as O, toDisplayString as g, normalizeClass as q } from "vue";
2
- import { u as A } from "./vue-i18n-ComGWqEb.js";
2
+ import { u as A } from "./vue-i18n-mTXrqqL9.js";
3
3
  const K = (s, u) => {
4
4
  const t = s.__vccOpts || s;
5
5
  for (const [o, i] of u)
@@ -1,12 +1,12 @@
1
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-DU3zkEF1.js";
3
- import { d as z } from "./app-BRv3iLF1.js";
2
+ import { _ as de } from "./Default.vue_vue_type_script_setup_true_lang-B0td3xNS.js";
3
+ import { d as z } from "./app-BXEgzj0c.js";
4
4
  import { components as I, useSnackbar as W, useBreakpoints as X, FmButtonColorThemeVariant as A } from "@feedmepos/ui-library";
5
- import { t as N, k as pe } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CcKWqqNP.js";
5
+ import { t as N, k as pe } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CoJrINGt.js";
6
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-ComGWqEb.js";
7
+ import { u as U, C as G, D as fe, b as ve } from "./vue-i18n-mTXrqqL9.js";
8
8
  import { detectLocale as F } from "@feedmepos/mf-common";
9
- import { a as Y } from "./SelectComponent.vue_vue_type_script_setup_true_lang-CYDZzbCU.js";
9
+ import { a as Y } from "./SelectComponent.vue_vue_type_script_setup_true_lang-UhEjUKRz.js";
10
10
  import { storeToRefs as _e } from "pinia";
11
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
12
  __name: "ReportHour",