@feedmepos/mf-report 5.7.6 → 5.8.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/dist/App-DJp01-Og.js +150 -0
  2. package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-Bi_BES93.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-g6ESEkM9.js} +2 -2
  3. package/dist/{Default.vue_vue_type_script_setup_true_lang-RIJC16Ui.js → Default.vue_vue_type_script_setup_true_lang-CRvS7Ex3.js} +10 -10
  4. package/dist/DynamicWidget.vue_vue_type_script_setup_true_lang-BVc7b2H4.js +1417 -0
  5. package/dist/{InsightView-DIhPKYKe.js → InsightView-Ba_em7GM.js} +6 -6
  6. package/dist/{Integration-D61lmDoO.js → Integration-7h1cJFLg.js} +3 -3
  7. package/dist/{Integrations-BiJVCGrp.js → Integrations-Dm7n-0iv.js} +3 -3
  8. package/dist/{Layout-DH7q-7AG.js → Layout-_u9uU4T9.js} +1 -1
  9. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-nPHvtT2O.js → MenuTab.vue_vue_type_script_setup_true_lang-Bn3KCbjG.js} +3 -3
  10. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-CPTKq_OA.js → NavigationTab.vue_vue_type_script_setup_true_lang-DuOqx76g.js} +7074 -7041
  11. package/dist/{NoData.vue_vue_type_script_setup_true_lang-CdFXBqlX.js → NoData.vue_vue_type_script_setup_true_lang-CAbykN6l.js} +1 -1
  12. package/dist/{OverviewView-Cp0quKsj.js → OverviewView-B_RWwK33.js} +5 -5
  13. package/dist/{Report-DSO3L0cw.js → Report-D6UGn8fH.js} +4 -4
  14. package/dist/ReportEditor-HDMGjShp.js +621 -0
  15. package/dist/{ReportView-CRKPSw3H.js → ReportView-CzhcGBn8.js} +7 -7
  16. package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-N2Lg1Vpt.js → SelectComponent.vue_vue_type_script_setup_true_lang-BEkJzB27.js} +1 -1
  17. package/dist/{Setting-Dd1O-wia.js → Setting-Bvzzqokm.js} +4 -4
  18. package/dist/{TileEditor-BLsGvreq.js → TileEditor-BNx2KgYJ.js} +8 -8
  19. package/dist/{TransitionFade-C7yNEw8X.js → TransitionFade-BR2i09Vy.js} +4 -4
  20. package/dist/app.js +29 -14
  21. package/dist/{global-loader-CbmVhJAK.js → global-loader-DKYDQRZx.js} +1175 -1204
  22. package/dist/{index-BWqDfeY6.js → index--mBthMxH.js} +1 -1
  23. package/dist/{report-schema-BnzKoFjx.js → report-schema-DDo0Dgd1.js} +1 -1
  24. package/dist/{v4-Cbq0RSpY.js → v4-CfR4tJai.js} +287 -281
  25. package/package.json +1 -1
  26. package/dist/App-BrW5SiDe.js +0 -152
  27. package/dist/DynamicWidget.vue_vue_type_script_setup_true_lang-DokEr03U.js +0 -1390
  28. package/dist/ReportEditor-DPWD6PV0.js +0 -527
@@ -1,6 +1,6 @@
1
- import { j as xe, a as te, F as re, h as K, b as Ie, c as Ne, n as je, d as pe, e as ze, k as Ke } from "./global-loader-CbmVhJAK.js";
1
+ import { j as xe, a as te, F as re, h as K, b as Ie, c as Ne, n as je, d as fe, e as ze, k as Ke } from "./global-loader-DKYDQRZx.js";
2
2
  import { storeToRefs as W, defineStore as ke } from "pinia";
3
- import { ref as X, computed as Ae, h as Xe, watch as Ze } from "vue";
3
+ import { ref as Z, computed as Te, h as Xe, watch as Ze } from "vue";
4
4
  import { useSnackbar as et, components as tt } from "@feedmepos/ui-library";
5
5
  import { useRouter as rt } from "vue-router";
6
6
  function He(F) {
@@ -9,53 +9,53 @@ function He(F) {
9
9
  var Me = {};
10
10
  (function(F) {
11
11
  var w = typeof xe < "u" ? xe : window, J = Object.create(w);
12
- J.scheduleImmediate = typeof setImmediate < "u" ? function(Q) {
13
- setImmediate(Q);
14
- } : function(Q) {
15
- setTimeout(Q, 0);
12
+ J.scheduleImmediate = typeof setImmediate < "u" ? function(V) {
13
+ setImmediate(V);
14
+ } : function(V) {
15
+ setTimeout(V, 0);
16
16
  }, J.exports = F, typeof process < "u" && (J.process = process), typeof __dirname < "u" && (J.__dirname = __dirname), typeof __filename < "u" && (J.__filename = __filename), typeof Buffer < "u" && (J.Buffer = Buffer);
17
- var U = !w.window;
17
+ var H = !w.window;
18
18
  try {
19
- typeof WorkerGlobalScope < "u" && w instanceof WorkerGlobalScope && (U = !1), typeof process < "u" && process.versions && process.versions.hasOwnProperty("electron") && process.versions.hasOwnProperty("node") && (U = !0);
19
+ typeof WorkerGlobalScope < "u" && w instanceof WorkerGlobalScope && (H = !1), typeof process < "u" && process.versions && process.versions.hasOwnProperty("electron") && process.versions.hasOwnProperty("node") && (H = !0);
20
20
  } catch {
21
21
  }
22
- if (U) {
23
- var N = (typeof __webpack_require__ < "u" ? __non_webpack_require__ : He)("url");
22
+ if (H) {
23
+ var P = (typeof __webpack_require__ < "u" ? __non_webpack_require__ : He)("url");
24
24
  Object.defineProperty(J, "location", {
25
25
  value: {
26
26
  get href() {
27
- return N.pathToFileURL ? N.pathToFileURL(process.cwd()).href + "/" : "file://" + function() {
28
- var Q = process.cwd();
29
- return process.platform != "win32" ? Q : "/" + Q.replace(/\\/g, "/");
27
+ return P.pathToFileURL ? P.pathToFileURL(process.cwd()).href + "/" : "file://" + function() {
28
+ var V = process.cwd();
29
+ return process.platform != "win32" ? V : "/" + V.replace(/\\/g, "/");
30
30
  }() + "/";
31
31
  }
32
32
  }
33
33
  }), function() {
34
- function Q() {
34
+ function V() {
35
35
  try {
36
36
  throw new Error();
37
37
  } catch (G) {
38
- var P = G.stack, H = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), q = null;
38
+ var N = G.stack, B = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), U = null;
39
39
  do {
40
- var V = H.exec(P);
41
- V != null && (q = V);
42
- } while (V != null);
43
- return q[1];
40
+ var Q = B.exec(N);
41
+ Q != null && (U = Q);
42
+ } while (Q != null);
43
+ return U[1];
44
44
  }
45
45
  }
46
46
  var k = null;
47
47
  Object.defineProperty(J, "document", {
48
48
  value: {
49
49
  get currentScript() {
50
- return k == null && (k = { src: Q() }), k;
50
+ return k == null && (k = { src: V() }), k;
51
51
  }
52
52
  }
53
53
  });
54
- }(), J.dartDeferredLibraryLoader = function(Q, k, P) {
54
+ }(), J.dartDeferredLibraryLoader = function(V, k, N) {
55
55
  try {
56
- load(Q), k();
57
- } catch (H) {
58
- P(H);
56
+ load(V), k();
57
+ } catch (B) {
58
+ N(B);
59
59
  }
60
60
  };
61
61
  }
@@ -66,16 +66,16 @@ var Me = {};
66
66
  e[a] = r[a];
67
67
  }
68
68
  }
69
- function P(r, e) {
69
+ function N(r, e) {
70
70
  for (var i = Object.keys(r), n = 0; n < i.length; n++) {
71
71
  var a = i[n];
72
72
  e.hasOwnProperty(a) || (e[a] = r[a]);
73
73
  }
74
74
  }
75
- function H(r, e) {
75
+ function B(r, e) {
76
76
  Object.assign(e, r);
77
77
  }
78
- var q = function() {
78
+ var U = function() {
79
79
  var r = function() {
80
80
  };
81
81
  r.prototype = { p: {} };
@@ -94,9 +94,9 @@ var Me = {};
94
94
  }
95
95
  return !1;
96
96
  }();
97
- function V(r, e) {
97
+ function Q(r, e) {
98
98
  if (r.prototype.constructor = r, r.prototype["$is" + r.name] = r, e != null) {
99
- if (q) {
99
+ if (U) {
100
100
  r.prototype.__proto__ = e.prototype;
101
101
  return;
102
102
  }
@@ -106,13 +106,13 @@ var Me = {};
106
106
  }
107
107
  function G(r, e) {
108
108
  for (var i = 0; i < e.length; i++)
109
- V(e[i], r);
109
+ Q(e[i], r);
110
110
  }
111
111
  function Y(r, e) {
112
- H(e.prototype, r.prototype), r.prototype.constructor = r;
112
+ B(e.prototype, r.prototype), r.prototype.constructor = r;
113
113
  }
114
- function ae(r, e) {
115
- P(e.prototype, r.prototype), r.prototype.constructor = r;
114
+ function ie(r, e) {
115
+ N(e.prototype, r.prototype), r.prototype.constructor = r;
116
116
  }
117
117
  function oe(r, e, i, n) {
118
118
  var a = r;
@@ -131,7 +131,7 @@ var Me = {};
131
131
  return s;
132
132
  };
133
133
  }
134
- function Z(r, e, i, n) {
134
+ function ee(r, e, i, n) {
135
135
  var a = r;
136
136
  r[e] = a, r[i] = function() {
137
137
  return r[e] === a && (r[e] = n()), r[i] = function() {
@@ -139,7 +139,7 @@ var Me = {};
139
139
  }, r[e];
140
140
  };
141
141
  }
142
- function fe(r, e, i, n) {
142
+ function ye(r, e, i, n) {
143
143
  var a = r;
144
144
  r[e] = a, r[i] = function() {
145
145
  if (r[e] === a) {
@@ -155,14 +155,14 @@ var Me = {};
155
155
  function se(r) {
156
156
  return r.immutable$list = Array, r.fixed$length = Array, r;
157
157
  }
158
- function ye(r) {
158
+ function $e(r) {
159
159
  return r;
160
160
  }
161
- function ie(r) {
161
+ function de(r) {
162
162
  for (var e = 0; e < r.length; ++e)
163
163
  r[e];
164
164
  }
165
- function ee(r, e) {
165
+ function ne(r, e) {
166
166
  var i = null;
167
167
  return r ? function(n) {
168
168
  return i === null && (i = t.closureFromTearOff(e)), new i(n, this);
@@ -170,26 +170,26 @@ var Me = {};
170
170
  return i === null && (i = t.closureFromTearOff(e)), new i(this, null);
171
171
  };
172
172
  }
173
- function le(r) {
173
+ function X(r) {
174
174
  var e = null;
175
175
  return function() {
176
176
  return e === null && (e = t.closureFromTearOff(r).prototype), e;
177
177
  };
178
178
  }
179
- var ue = 0;
180
- function _e(r, e, i, n, a, s, l, _, d, c) {
181
- return typeof _ == "number" && (_ += ue), { co: r, iS: e, iI: i, rC: n, dV: a, cs: s, fs: l, fT: _, aI: d || 0, nDA: c };
179
+ var _e = 0;
180
+ function le(r, e, i, n, a, s, l, _, d, c) {
181
+ return typeof _ == "number" && (_ += _e), { co: r, iS: e, iI: i, rC: n, dV: a, cs: s, fs: l, fT: _, aI: d || 0, nDA: c };
182
182
  }
183
- function ne(r, e, i, n, a, s, l, _) {
184
- var d = _e(r, !0, !1, i, n, a, s, l, _, !1), c = le(d);
183
+ function ae(r, e, i, n, a, s, l, _) {
184
+ var d = le(r, !0, !1, i, n, a, s, l, _, !1), c = X(d);
185
185
  r[e] = c;
186
186
  }
187
- function de(r, e, i, n, a, s, l, _, d, c) {
187
+ function ce(r, e, i, n, a, s, l, _, d, c) {
188
188
  i = !!i;
189
- var f = _e(r, !1, i, n, a, s, l, _, d, !!c), $ = ee(i, f);
189
+ var f = le(r, !1, i, n, a, s, l, _, d, !!c), $ = ne(i, f);
190
190
  r[e] = $;
191
191
  }
192
- function he(r) {
192
+ function ge(r) {
193
193
  var e = T.interceptorsByTag;
194
194
  if (!e) {
195
195
  T.interceptorsByTag = r;
@@ -197,7 +197,7 @@ var Me = {};
197
197
  }
198
198
  k(r, e);
199
199
  }
200
- function Te(r) {
200
+ function me(r) {
201
201
  var e = T.leafTags;
202
202
  if (!e) {
203
203
  T.leafTags = r;
@@ -205,24 +205,24 @@ var Me = {};
205
205
  }
206
206
  k(r, e);
207
207
  }
208
- function $e(r) {
208
+ function ue(r) {
209
209
  var e = T.types, i = e.length;
210
210
  return e.push.apply(e, r), i;
211
211
  }
212
- function ge(r, e) {
212
+ function Se(r, e) {
213
213
  return k(e, r), r;
214
214
  }
215
215
  var j = function() {
216
216
  var r = function(i, n, a, s, l) {
217
217
  return function(_, d, c, f) {
218
- return de(_, d, i, n, a, s, [c], f, l, !1);
218
+ return ce(_, d, i, n, a, s, [c], f, l, !1);
219
219
  };
220
220
  }, e = function(i, n, a, s) {
221
221
  return function(l, _, d, c) {
222
- return ne(l, _, i, n, a, [d], c, s);
222
+ return ae(l, _, i, n, a, [d], c, s);
223
223
  };
224
224
  };
225
- return { inherit: V, inheritMany: G, mixin: Y, mixinHard: ae, installStaticTearOff: ne, installInstanceTearOff: de, _instance_0u: r(0, 0, null, ["call$0"], 0), _instance_1u: r(0, 1, null, ["call$1"], 0), _instance_2u: r(0, 2, null, ["call$2"], 0), _instance_0i: r(1, 0, null, ["call$0"], 0), _instance_1i: r(1, 1, null, ["call$1"], 0), _instance_2i: r(1, 2, null, ["call$2"], 0), _static_0: e(0, null, ["call$0"], 0), _static_1: e(1, null, ["call$1"], 0), _static_2: e(2, null, ["call$2"], 0), makeConstList: se, lazy: Z, lazyFinal: fe, lazyOld: oe, updateHolder: ge, convertToFastObject: ye, updateTypes: $e, setOrUpdateInterceptorsByTag: he, setOrUpdateLeafTags: Te };
225
+ return { inherit: Q, inheritMany: G, mixin: Y, mixinHard: ie, installStaticTearOff: ae, installInstanceTearOff: ce, _instance_0u: r(0, 0, null, ["call$0"], 0), _instance_1u: r(0, 1, null, ["call$1"], 0), _instance_2u: r(0, 2, null, ["call$2"], 0), _instance_0i: r(1, 0, null, ["call$0"], 0), _instance_1i: r(1, 1, null, ["call$1"], 0), _instance_2i: r(1, 2, null, ["call$2"], 0), _static_0: e(0, null, ["call$0"], 0), _static_1: e(1, null, ["call$1"], 0), _static_2: e(2, null, ["call$2"], 0), makeConstList: se, lazy: ee, lazyFinal: ye, lazyOld: oe, updateHolder: Se, convertToFastObject: $e, updateTypes: ue, setOrUpdateInterceptorsByTag: ge, setOrUpdateLeafTags: me };
226
226
  }(), t = {
227
227
  JS_CONST: function() {
228
228
  },
@@ -1757,7 +1757,7 @@ var Me = {};
1757
1757
  return d === 12 ? e === y.JavaScriptFunction ? !0 : s ? !1 : t._isFunctionSubtype(r, e, i, n, a) : l === 9 ? d !== 9 ? !1 : t._isInterfaceSubtype(r, e, i, n, a) : (s = l === 11, s && n === y.Record ? !0 : s && d === 11 ? t._isRecordSubtype(r, e, i, n, a) : !1);
1758
1758
  },
1759
1759
  _isFunctionSubtype(r, e, i, n, a) {
1760
- var s, l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L, v, x, B;
1760
+ var s, l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L, v, x, q;
1761
1761
  if (!t._isSubtype(r, e._primary, i, n._primary, a) || (s = e._rest, l = n._rest, _ = s._requiredPositional, d = l._requiredPositional, c = _.length, f = d.length, c > f) || ($ = f - c, g = s._optionalPositional, m = l._optionalPositional, h = g.length, A = m.length, c + h < f + A))
1762
1762
  return !1;
1763
1763
  for (E = 0; E < c; ++E)
@@ -1773,12 +1773,12 @@ var Me = {};
1773
1773
  for (v = R[L]; ; ) {
1774
1774
  if (D >= C || (x = b[D], D += 3, v < x))
1775
1775
  return !1;
1776
- if (B = b[D - 2], x < v) {
1777
- if (B)
1776
+ if (q = b[D - 2], x < v) {
1777
+ if (q)
1778
1778
  return !1;
1779
1779
  continue;
1780
1780
  }
1781
- if (M = R[L + 1], B && !M || (M = b[D - 1], !t._isSubtype(r, R[L + 2], a, M, i)))
1781
+ if (M = R[L + 1], q && !M || (M = b[D - 1], !t._isSubtype(r, R[L + 2], a, M, i)))
1782
1782
  return !1;
1783
1783
  break;
1784
1784
  }
@@ -8345,10 +8345,10 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
8345
8345
  $signature: 1
8346
8346
  }, t.flattenItemSchema_closure.prototype = {
8347
8347
  call$1(r) {
8348
- var e = null, i = "itemCreatedAt", n = "billCompletedAt", a = "perXUnit", s = "takeawayId", l = "takeawayName", _ = "productId", d = "isRefund", c = "servedAt", f = "isTakeaway", $ = "quantity", g = "unitQuantity", m = "billAdjustmentTotal", h = "itemAdjustmentTotal", A = "grossTotal", E = "takeawayPrice", M = "nettTotal", b = "layerNettTotal", R = "layerBillAdjustmentTotal", C = "layerItemAdjustmentTotal", O = "layerGrossTotal", D = "layerTakeawayPrice", L = "layerTaxTotal", v = "layerScTotal", x = "layerOtherChargeTotal", B = "customAttributes", ce = "layerZeroParentId";
8348
+ var e = null, i = "itemCreatedAt", n = "billCompletedAt", a = "perXUnit", s = "takeawayId", l = "takeawayName", _ = "productId", d = "isRefund", c = "servedAt", f = "isTakeaway", $ = "quantity", g = "unitQuantity", m = "billAdjustmentTotal", h = "itemAdjustmentTotal", A = "grossTotal", E = "takeawayPrice", M = "nettTotal", b = "layerNettTotal", R = "layerBillAdjustmentTotal", C = "layerItemAdjustmentTotal", O = "layerGrossTotal", D = "layerTakeawayPrice", L = "layerTaxTotal", v = "layerScTotal", x = "layerOtherChargeTotal", q = "customAttributes", pe = "layerZeroParentId";
8349
8349
  return t._setArrayType([t.Field_Field$string(e, !1, "ID", "id", "_id", e, r), t.Field_Field$string(e, !0, e, "docId", "_docId", e, r), t.Field_Field$string(e, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, r), t.Field_Field$timestamp(e, !1, "Time", "createdAt", "_createdAt", e, r), t.Field_Field$timestamp(e, !0, e, "publishedAt", "_publishedAt", e, r), t.Field_Field$timestamp(e, !1, "Item time", i, i, e, r), t.Field_Field$timestamp(e, !1, "Bill close time", n, n, e, r), t.Field_Field$string(e, !1, "Bill ID", "billId", "billId", e, r), t.Field_Field$string(e, !1, "Status", "status", "status", e, r), t.Field_Field$string(e, !1, "Name", "name", "name", e, r), t.Field_Field$numeric(e, !1, "Per unit", a, a, e, r), t.Field_Field$string(e, !1, "Unit", "unit", "unit", e, r), t.Field_Field$string(`IF(@categoryName IS NULL OR @productId IS NULL OR REGEXP_CONTAINS(@productId, r'^\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+([+-][0-2]\\d:[0-5]\\d|Z)$'), 'Other', @categoryName)
8350
8350
  `, !1, "Category", "categoryName", "category", `CASE WHEN @category_name IS NULL OR @product_id IS NULL OR @product_id ~ '^\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+([+-][0-2]\\d:[0-5]\\d|Z)$' THEN 'Other' ELSE @category_name END
8351
- `, r), t.Field_Field$string(e, !1, "Takeaway ID", s, s, e, r), t.Field_Field$string(e, !1, "Takeaway name", l, l, e, r), t.Field_Field$string(e, !1, "Code", "code", "code", e, r), t.Field_Field$string(e, !1, "Remark", "remark", "remark", e, r), t.Field_Field$string(e, !1, "Product ID", _, _, e, r), t.Field_Field$string(e, !1, "Variant ID", "variantId", "variant.id", e, r), t.Field_Field$string(e, !1, "Variant", "variantName", "variant.name", e, r), t.Field_Field$bool(e, !1, "Refund", d, d, e, r), t.Field_Field$string(e, !1, "User id", "createdById", "createdBy.id", e, r), t.Field_Field$string(e, !1, "User", "createdByName", "createdBy.name", e, r), t.Field_Field$timestamp(e, !1, "Sent time", "sentAt", "sentAt", e, r), t.Field_Field$timestamp(e, !1, "Served time", c, c, e, r), t.Field_Field$timestamp(e, !1, "Printed time", "printedAt", "printBy.printAt", e, r), t.Field_Field$timestamp(e, !1, "Void time", "voidAt", "void.voidAt", e, r), t.Field_Field$string(e, !1, "Void reason", "voidReason", "void.reason", e, r), t.Field_Field$string(e, !0, e, "voidedById", "void.by.id", e, r), t.Field_Field$string(e, !1, "Void user", "voidedByName", "void.by.name", e, r), t.Field_Field$string(e, !0, e, "voidApprovedById", "void.approvedBy.id", e, r), t.Field_Field$string(e, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, r), t.Field_Field$bool(e, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, r), t.Field_Field$bool(e, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, r), t.Field_Field$bool(e, !1, "Takeaway", f, f, e, r), t.Field_Field$numeric("@quantity*IF(@isRefund, -1, 1)", !1, "Qty", $, $, I.x40quant, r), t.Field_Field$numeric("@unitQuantity*IF(@isRefund, -1, 1)", !1, "Unit qty", g, g, I.x40unit_, r), t.Field_Field$numeric("@sstTotal*IF(@isRefund, -1, 1)", !1, "SST", "sstTotal", "sst.total", I.x40sst_t, r), t.Field_Field$numeric(e, !0, "SST %", "sstPercentage", "sst.percentage", e, r), t.Field_Field$numeric(e, !0, "SC %", "serviceChargePercentage", "sc.percentage", e, r), t.Field_Field$numeric("@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, "SC", "serviceChargeTotal", "sc.total", I.x40servi, r), t.Field_Field$numeric("@otherChargeTotal*IF(@isRefund, -1, 1)", !1, "Other charge", "otherChargeTotal", "otherCharge.total", I.x40other, r), t.Field_Field$numeric(I.x40billA, !1, "Bill discount", m, m, I.x40bill_, r), t.Field_Field$numeric(I.x40itemA, !1, "Item discount", h, h, I.x40item_, r), t.Field_Field$numeric("@grossTotal*IF(@isRefund, -1, 1)", !1, "Gross", A, A, I.x40gross, r), t.Field_Field$numeric(I.x28_grosT, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, I.x28_gros_, r), t.Field_Field$numeric("@takeawayPrice*IF(@isRefund, -1, 1)", !1, "Takeaway price", E, E, I.x40takea, r), t.Field_Field$numeric("@nettTotal*IF(@isRefund, -1, 1)", !1, "Nett", M, M, I.x40nett_, r), t.Field_Field$string(e, !1, "Parent ID", "parentId", "parent.id", e, r), t.Field_Field$string(e, !1, "Parent name", "parentName", "parent.name", e, r), t.Field_Field$string(e, !1, "Addon type", "addonType", "addon.type", e, r), t.Field_Field$string(e, !1, "Addon ID", "addonId", "addon.selectionId", e, r), t.Field_Field$string("SPLIT(@addonId, '/')[OFFSET(0)]", !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", r), t.Field_Field$numeric(e, !1, "Layer", "layer", "layer", e, r), t.Field_Field$numeric("@addonPrice*IF(@isRefund, -1, 1)", !1, "Addon price", "addonPrice", "addon.price", I.x40addon, r), t.Field_Field$numeric("@taxTotal*IF(@isRefund, -1, 1)", !1, "Tax", "taxTotal", "tax.total", "@tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(I.x28IFNULb, !1, "Discount", "discountTotal", e, I.x28COALEb, r), t.Field_Field$numeric(I.x28IFNULgx2b, !1, "Gross before charges", "grossBeforeCharges", e, I.x28COALEgx2b, r), t.Field_Field$numeric(I.TIMEST, !1, "Preparation seconds", "preparationSeconds", e, I.EXTRAC, r), t.Field_Field$string(I.CONCAT_, !1, "Summary", "summary", e, I.CONCATA, r), t.Field_Field$numeric("@layerNettTotal*IF(@isRefund, -1, 1)", !1, "Layer nett", b, b, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, "Layer bill discount", R, R, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, "Layer item discount", C, C, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerGrossTotal*IF(@isRefund, -1, 1)", !1, "Layer gross total", O, O, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, "Layer takeaway price", D, D, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerTaxTotal*IF(@isRefund, -1, 1)", !1, "Layer tax total", L, L, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerScTotal*IF(@isRefund, -1, 1)", !1, "Layer sc", v, v, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, "Layer other charge", x, x, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, "Layer gross before charges", "layerGrossBeforeCharges", e, "(COALESCE(@layer_gross_total,0)+COALESCE(@layer_bill_adjustment_total,0)+COALESCE(@layer_item_adjustment_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, !1, "Custom attributes", B, B, e, r), t.Field_Field$string(e, !1, "Layer 0 parent ID", ce, ce, e, r), t.Field_Field$string(e, !1, "Charge variant", "chargeVariant", e, "(select variant from charges where charges.parent_id=@layer_zero_parent_id and charges.restaurant_id=@restaurant_id and charges.bill_id=@bill_id and charges.code in ('SST','GST'))", r)], y.JSArray_Field);
8351
+ `, r), t.Field_Field$string(e, !1, "Takeaway ID", s, s, e, r), t.Field_Field$string(e, !1, "Takeaway name", l, l, e, r), t.Field_Field$string(e, !1, "Code", "code", "code", e, r), t.Field_Field$string(e, !1, "Remark", "remark", "remark", e, r), t.Field_Field$string(e, !1, "Product ID", _, _, e, r), t.Field_Field$string(e, !1, "Variant ID", "variantId", "variant.id", e, r), t.Field_Field$string(e, !1, "Variant", "variantName", "variant.name", e, r), t.Field_Field$bool(e, !1, "Refund", d, d, e, r), t.Field_Field$string(e, !1, "User id", "createdById", "createdBy.id", e, r), t.Field_Field$string(e, !1, "User", "createdByName", "createdBy.name", e, r), t.Field_Field$timestamp(e, !1, "Sent time", "sentAt", "sentAt", e, r), t.Field_Field$timestamp(e, !1, "Served time", c, c, e, r), t.Field_Field$timestamp(e, !1, "Printed time", "printedAt", "printBy.printAt", e, r), t.Field_Field$timestamp(e, !1, "Void time", "voidAt", "void.voidAt", e, r), t.Field_Field$string(e, !1, "Void reason", "voidReason", "void.reason", e, r), t.Field_Field$string(e, !0, e, "voidedById", "void.by.id", e, r), t.Field_Field$string(e, !1, "Void user", "voidedByName", "void.by.name", e, r), t.Field_Field$string(e, !0, e, "voidApprovedById", "void.approvedBy.id", e, r), t.Field_Field$string(e, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, r), t.Field_Field$bool(e, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, r), t.Field_Field$bool(e, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, r), t.Field_Field$bool(e, !1, "Takeaway", f, f, e, r), t.Field_Field$numeric("@quantity*IF(@isRefund, -1, 1)", !1, "Qty", $, $, I.x40quant, r), t.Field_Field$numeric("@unitQuantity*IF(@isRefund, -1, 1)", !1, "Unit qty", g, g, I.x40unit_, r), t.Field_Field$numeric("@sstTotal*IF(@isRefund, -1, 1)", !1, "SST", "sstTotal", "sst.total", I.x40sst_t, r), t.Field_Field$numeric(e, !0, "SST %", "sstPercentage", "sst.percentage", e, r), t.Field_Field$numeric(e, !0, "SC %", "serviceChargePercentage", "sc.percentage", e, r), t.Field_Field$numeric("@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, "SC", "serviceChargeTotal", "sc.total", I.x40servi, r), t.Field_Field$numeric("@otherChargeTotal*IF(@isRefund, -1, 1)", !1, "Other charge", "otherChargeTotal", "otherCharge.total", I.x40other, r), t.Field_Field$numeric(I.x40billA, !1, "Bill discount", m, m, I.x40bill_, r), t.Field_Field$numeric(I.x40itemA, !1, "Item discount", h, h, I.x40item_, r), t.Field_Field$numeric("@grossTotal*IF(@isRefund, -1, 1)", !1, "Gross", A, A, I.x40gross, r), t.Field_Field$numeric(I.x28_grosT, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, I.x28_gros_, r), t.Field_Field$numeric("@takeawayPrice*IF(@isRefund, -1, 1)", !1, "Takeaway price", E, E, I.x40takea, r), t.Field_Field$numeric("@nettTotal*IF(@isRefund, -1, 1)", !1, "Nett", M, M, I.x40nett_, r), t.Field_Field$string(e, !1, "Parent ID", "parentId", "parent.id", e, r), t.Field_Field$string(e, !1, "Parent name", "parentName", "parent.name", e, r), t.Field_Field$string(e, !1, "Addon type", "addonType", "addon.type", e, r), t.Field_Field$string(e, !1, "Addon ID", "addonId", "addon.selectionId", e, r), t.Field_Field$string("SPLIT(@addonId, '/')[OFFSET(0)]", !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", r), t.Field_Field$numeric(e, !1, "Layer", "layer", "layer", e, r), t.Field_Field$numeric("@addonPrice*IF(@isRefund, -1, 1)", !1, "Addon price", "addonPrice", "addon.price", I.x40addon, r), t.Field_Field$numeric("@taxTotal*IF(@isRefund, -1, 1)", !1, "Tax", "taxTotal", "tax.total", "@tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric(I.x28IFNULb, !1, "Discount", "discountTotal", e, I.x28COALEb, r), t.Field_Field$numeric(I.x28IFNULgx2b, !1, "Gross before charges", "grossBeforeCharges", e, I.x28COALEgx2b, r), t.Field_Field$numeric(I.TIMEST, !1, "Preparation seconds", "preparationSeconds", e, I.EXTRAC, r), t.Field_Field$string(I.CONCAT_, !1, "Summary", "summary", e, I.CONCATA, r), t.Field_Field$numeric("@layerNettTotal*IF(@isRefund, -1, 1)", !1, "Layer nett", b, b, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, "Layer bill discount", R, R, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, "Layer item discount", C, C, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerGrossTotal*IF(@isRefund, -1, 1)", !1, "Layer gross total", O, O, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, "Layer takeaway price", D, D, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerTaxTotal*IF(@isRefund, -1, 1)", !1, "Layer tax total", L, L, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerScTotal*IF(@isRefund, -1, 1)", !1, "Layer sc", v, v, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, "Layer other charge", x, x, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$numeric("(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, "Layer gross before charges", "layerGrossBeforeCharges", e, "(COALESCE(@layer_gross_total,0)+COALESCE(@layer_bill_adjustment_total,0)+COALESCE(@layer_item_adjustment_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", r), t.Field_Field$string(e, !1, "Custom attributes", q, q, e, r), t.Field_Field$string(e, !1, "Layer 0 parent ID", pe, pe, e, r), t.Field_Field$string(e, !1, "Charge variant", "chargeVariant", e, "(select variant from charges where charges.parent_id=@layer_zero_parent_id and charges.restaurant_id=@restaurant_id and charges.bill_id=@bill_id and charges.code in ('SST','GST'))", r)], y.JSArray_Field);
8352
8352
  },
8353
8353
  $signature: 0
8354
8354
  }, t.flattenItemSchema_closure0.prototype = {
@@ -9825,8 +9825,8 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
9825
9825
  return n.message;
9826
9826
  }
9827
9827
  }())), e(S, "DateTime__parseFormat", "$get$DateTime__parseFormat", () => t.RegExp_RegExp("^([+-]?\\d{4,6})-?(\\d\\d)-?(\\d\\d)(?:[ T](\\d\\d)(?::?(\\d\\d)(?::?(\\d\\d)(?:[.,](\\d+))?)?)?( ?[zZ]| ?([-+])(\\d\\d)(?::?(\\d\\d))?)?)?$")), e(S, "_hashSeed", "$get$_hashSeed", () => t.objectHashCode(u.Type_Object_xQ6)), e(S, "Endian_host", "$get$Endian_host", () => t.NativeByteData_NativeByteData$view(t.NativeUint16List__create1(t._ensureNativeList(t._setArrayType([1], y.JSArray_int))).buffer, 0, null).getInt8(0) === 1 ? u.C_Endian0 : u.C_Endian), e(S, "_clockKey", "$get$_clockKey", () => new t.Object()), e(S, "en_USSymbols", "$get$en_USSymbols", () => new t.DateSymbols("en_US", u.List_BC_AD, u.List_6xs, u.List_qpm, u.List_qpm, u.List_cIc, u.List_cIc, u.List_h8w, u.List_h8w, u.List_wMy, u.List_wMy, u.List_gc6, u.List_gc6, u.List_3US, u.List_AM_PM)), i(S, "_dateTimeSymbols", "$get$_dateTimeSymbols", () => t.UninitializedLocaleData$("initializeDateFormatting(<locale>)", S.$get$en_USSymbols())), i(S, "dateTimePatterns", "$get$dateTimePatterns", () => t.UninitializedLocaleData$("initializeDateFormatting(<locale>)", u.Map_EQ6TW)), e(S, "asciiZeroCodeUnit", "$get$asciiZeroCodeUnit", () => 48), e(S, "DateFormat__matchers", "$get$DateFormat__matchers", () => t._setArrayType([t.RegExp_RegExp("^'(?:[^']|'')*'"), t.RegExp_RegExp("^(?:G+|y+|M+|k+|S+|E+|a+|h+|K+|H+|c+|L+|Q+|d+|D+|m+|s+|v+|z+|Z+)"), t.RegExp_RegExp("^[^'GyMkSEahKHcLQdDmsvzZ]+")], t.findType("JSArray<RegExp>"))), e(S, "_DateFormatQuotedField__twoEscapedQuotes", "$get$_DateFormatQuotedField__twoEscapedQuotes", () => t.RegExp_RegExp("''")), e(S, "asciiDigitMatcher", "$get$asciiDigitMatcher", () => t.RegExp_RegExp("^\\d+")), i(S, "_availableLocales", "$get$_availableLocales", () => {
9828
- var n, a, s = t.EnLocale$(u.StartOfWeek_1), l = t.EnLocale$(u.StartOfWeek_1), _ = t.EnLocale$(u.StartOfWeek_1), d = t.EnLocale$(u.StartOfWeek_1), c = t.EnLocale$(u.StartOfWeek_1), f = t.EnLocale$(u.StartOfWeek_2), $ = t.EnLocale$(u.StartOfWeek_2), g = t.EnLocale$(u.StartOfWeek_1), m = t.EnLocale$(u.StartOfWeek_1), h = t.EsLocale$(u.StartOfWeek_2), A = t.EsLocale$(u.StartOfWeek_2), E = t.EsLocale$(u.StartOfWeek_1), M = t.FrLocale$(u.StartOfWeek_2), b = t.FrLocale$(u.StartOfWeek_2), R = t.FrLocale$(u.StartOfWeek_1), C = t.ZhCnLocale$(u.StartOfWeek_1), O = t.ZhCnLocale$(u.StartOfWeek_1), D = t.ZhLocale$(u.StartOfWeek_1), L = t.ZhLocale$(u.StartOfWeek_1), v = t.DeLocale$(u.StartOfWeek_2), x = t.DeLocale$(u.StartOfWeek_2), B = t.DeLocale$(u.StartOfWeek_2), ce = t.DeLocale$(u.StartOfWeek_2), Ce = t.ItLocale$(u.StartOfWeek_2), be = t.ItLocale$(u.StartOfWeek_2), Re = t.ArLyLocale$(!0, u.StartOfWeek_0), Fe = t.ArLyLocale$(!1, u.StartOfWeek_0), Oe = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), Le = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), we = t.ArSaMaDzKwTnLocale$(!0, u.StartOfWeek_1), ve = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0), De = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0);
9829
- return t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), n = t.PtLocale$(u.StartOfWeek_2), a = t.PtLocale$(u.StartOfWeek_1), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.LinkedHashMap_LinkedHashMap$_literal(["en", s, "en_us", l, "en_sg", _, "en_au", d, "en_ca", c, "en_gb", f, "en_ie", $, "en_il", g, "en_nz", m, "es", h, "es_do", A, "es_us", E, "fr", M, "fr_ch", b, "fr_ca", R, "zh", C, "zh_cn", O, "zh_hk", D, "zh_tw", L, "de", v, "de_de", x, "de_at", B, "de_ch", ce, "it", Ce, "it_ch", be, "ar", Re, "ar_ly", Fe, "ar_dz", Oe, "ar_kw", Le, "ar_sa", we, "ar_ma", ve, "ar_tn", De, "az", new t.AzLocale(u.StartOfWeek_2), "id", new t.IdLocale(u.StartOfWeek_1), "ja", new t.JaLocale(u.StartOfWeek_1), "ko", new t.KoLocale(u.StartOfWeek_1), "ru", new t.RuLocale(u.StartOfWeek_2), "uk", new t.UkLocale(u.StartOfWeek_2), "hi", new t.HiLocale(u.StartOfWeek_1), "pt", n, "pt_br", a, "pl", new t.PlLocale(u.StartOfWeek_2), "tr", new t.TrLocale(u.StartOfWeek_2), "sv", new t.SvLocale(u.StartOfWeek_2), "nb", new t.NbLocale(u.StartOfWeek_2), "fa", new t.FaLocale(u.StartOfWeek_0), "bn", new t.BnLocale(u.StartOfWeek_1), "nl", new t.NlLocale(u.StartOfWeek_2), "th", new t.ThLocale(u.StartOfWeek_1)], y.String, t.findType("Locale"));
9828
+ var n, a, s = t.EnLocale$(u.StartOfWeek_1), l = t.EnLocale$(u.StartOfWeek_1), _ = t.EnLocale$(u.StartOfWeek_1), d = t.EnLocale$(u.StartOfWeek_1), c = t.EnLocale$(u.StartOfWeek_1), f = t.EnLocale$(u.StartOfWeek_2), $ = t.EnLocale$(u.StartOfWeek_2), g = t.EnLocale$(u.StartOfWeek_1), m = t.EnLocale$(u.StartOfWeek_1), h = t.EsLocale$(u.StartOfWeek_2), A = t.EsLocale$(u.StartOfWeek_2), E = t.EsLocale$(u.StartOfWeek_1), M = t.FrLocale$(u.StartOfWeek_2), b = t.FrLocale$(u.StartOfWeek_2), R = t.FrLocale$(u.StartOfWeek_1), C = t.ZhCnLocale$(u.StartOfWeek_1), O = t.ZhCnLocale$(u.StartOfWeek_1), D = t.ZhLocale$(u.StartOfWeek_1), L = t.ZhLocale$(u.StartOfWeek_1), v = t.DeLocale$(u.StartOfWeek_2), x = t.DeLocale$(u.StartOfWeek_2), q = t.DeLocale$(u.StartOfWeek_2), pe = t.DeLocale$(u.StartOfWeek_2), Ce = t.ItLocale$(u.StartOfWeek_2), be = t.ItLocale$(u.StartOfWeek_2), Re = t.ArLyLocale$(!0, u.StartOfWeek_0), Fe = t.ArLyLocale$(!1, u.StartOfWeek_0), Oe = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), Le = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), we = t.ArSaMaDzKwTnLocale$(!0, u.StartOfWeek_1), ve = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0), De = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0);
9829
+ return t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), n = t.PtLocale$(u.StartOfWeek_2), a = t.PtLocale$(u.StartOfWeek_1), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.LinkedHashMap_LinkedHashMap$_literal(["en", s, "en_us", l, "en_sg", _, "en_au", d, "en_ca", c, "en_gb", f, "en_ie", $, "en_il", g, "en_nz", m, "es", h, "es_do", A, "es_us", E, "fr", M, "fr_ch", b, "fr_ca", R, "zh", C, "zh_cn", O, "zh_hk", D, "zh_tw", L, "de", v, "de_de", x, "de_at", q, "de_ch", pe, "it", Ce, "it_ch", be, "ar", Re, "ar_ly", Fe, "ar_dz", Oe, "ar_kw", Le, "ar_sa", we, "ar_ma", ve, "ar_tn", De, "az", new t.AzLocale(u.StartOfWeek_2), "id", new t.IdLocale(u.StartOfWeek_1), "ja", new t.JaLocale(u.StartOfWeek_1), "ko", new t.KoLocale(u.StartOfWeek_1), "ru", new t.RuLocale(u.StartOfWeek_2), "uk", new t.UkLocale(u.StartOfWeek_2), "hi", new t.HiLocale(u.StartOfWeek_1), "pt", n, "pt_br", a, "pl", new t.PlLocale(u.StartOfWeek_2), "tr", new t.TrLocale(u.StartOfWeek_2), "sv", new t.SvLocale(u.StartOfWeek_2), "nb", new t.NbLocale(u.StartOfWeek_2), "fa", new t.FaLocale(u.StartOfWeek_0), "bn", new t.BnLocale(u.StartOfWeek_1), "nl", new t.NlLocale(u.StartOfWeek_2), "th", new t.ThLocale(u.StartOfWeek_1)], y.String, t.findType("Locale"));
9830
9830
  }), e(S, "addonFlattenItemSchema", "$get$addonFlattenItemSchema", () => {
9831
9831
  var n = "createdAt", a = t.Source_Source$couchdb("", ""), s = t.TopLevelFilters$(t._setArrayType([t.Permission_Permission$restaurant("restaurantId")], y.JSArray_Permission), n);
9832
9832
  return t.Schema_Schema$build(t._setArrayType(["restaurantId"], y.JSArray_String), null, new t.addonFlattenItemSchema_closure(), u.List_empty, null, null, !1, !1, !0, !1, new t.addonFlattenItemSchema_closure0(), "Addon", "flatten_items", "flatten_item", u.SCHEMA_NAME_6, n, "", a, s);
@@ -10077,7 +10077,7 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
10077
10077
  return this(r, e, i);
10078
10078
  }, Function.prototype.call$8 = function(r, e, i, n, a, s, l, _) {
10079
10079
  return this(r, e, i, n, a, s, l, _);
10080
- }, ie(p), function(r) {
10080
+ }, de(p), function(r) {
10081
10081
  if (typeof document > "u") {
10082
10082
  r(null);
10083
10083
  return;
@@ -10104,17 +10104,17 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
10104
10104
  var Ue = {};
10105
10105
  (function(F) {
10106
10106
  F.load = function(w, J) {
10107
- var U = typeof process < "u" && (process.versions || {}).hasOwnProperty("node"), N = U ? Object.create(globalThis) : globalThis;
10108
- if (N.scheduleImmediate = typeof setImmediate < "u" ? function(k) {
10107
+ var H = typeof process < "u" && (process.versions || {}).hasOwnProperty("node"), P = H ? Object.create(globalThis) : globalThis;
10108
+ if (P.scheduleImmediate = typeof setImmediate < "u" ? function(k) {
10109
10109
  setImmediate(k);
10110
10110
  } : function(k) {
10111
10111
  setTimeout(k, 0);
10112
- }, N.exports = J || F, typeof process < "u" && (N.process = process), typeof __dirname < "u" && (N.__dirname = __dirname), typeof __filename < "u" && (N.__filename = __filename), typeof Buffer < "u" && (N.Buffer = Buffer), U) {
10113
- var Q = (typeof __webpack_require__ < "u" ? __non_webpack_require__ : He)("url");
10114
- Object.defineProperty(N, "location", {
10112
+ }, P.exports = J || F, typeof process < "u" && (P.process = process), typeof __dirname < "u" && (P.__dirname = __dirname), typeof __filename < "u" && (P.__filename = __filename), typeof Buffer < "u" && (P.Buffer = Buffer), H) {
10113
+ var V = (typeof __webpack_require__ < "u" ? __non_webpack_require__ : He)("url");
10114
+ Object.defineProperty(P, "location", {
10115
10115
  value: {
10116
10116
  get href() {
10117
- return Q.pathToFileURL ? Q.pathToFileURL(process.cwd()).href + "/" : "file://" + function() {
10117
+ return V.pathToFileURL ? V.pathToFileURL(process.cwd()).href + "/" : "file://" + function() {
10118
10118
  var k = process.cwd();
10119
10119
  return process.platform != "win32" ? k : "/" + k.replace(/\\/g, "/");
10120
10120
  }() + "/";
@@ -10125,47 +10125,47 @@ var Ue = {};
10125
10125
  try {
10126
10126
  throw new Error();
10127
10127
  } catch (Y) {
10128
- var H = Y.stack, q = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), V = null;
10128
+ var B = Y.stack, U = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), Q = null;
10129
10129
  do {
10130
- var G = q.exec(H);
10131
- G != null && (V = G);
10130
+ var G = U.exec(B);
10131
+ G != null && (Q = G);
10132
10132
  } while (G != null);
10133
- return V[1];
10133
+ return Q[1];
10134
10134
  }
10135
10135
  }
10136
- var P = null;
10137
- Object.defineProperty(N, "document", {
10136
+ var N = null;
10137
+ Object.defineProperty(P, "document", {
10138
10138
  value: {
10139
10139
  get currentScript() {
10140
- return P == null && (P = { src: k() }), P;
10140
+ return N == null && (N = { src: k() }), N;
10141
10141
  }
10142
10142
  }
10143
10143
  });
10144
- }(), N.dartDeferredLibraryLoader = function(k, P, H) {
10144
+ }(), P.dartDeferredLibraryLoader = function(k, N, B) {
10145
10145
  try {
10146
- load(k), P();
10147
- } catch (q) {
10148
- H(q);
10146
+ load(k), N();
10147
+ } catch (U) {
10148
+ B(U);
10149
10149
  }
10150
10150
  };
10151
10151
  }
10152
10152
  (function() {
10153
- function P(e, i) {
10153
+ function N(e, i) {
10154
10154
  for (var n = Object.keys(e), a = 0; a < n.length; a++) {
10155
10155
  var s = n[a];
10156
10156
  i[s] = e[s];
10157
10157
  }
10158
10158
  }
10159
- function H(e, i) {
10159
+ function B(e, i) {
10160
10160
  for (var n = Object.keys(e), a = 0; a < n.length; a++) {
10161
10161
  var s = n[a];
10162
10162
  i.hasOwnProperty(s) || (i[s] = e[s]);
10163
10163
  }
10164
10164
  }
10165
- function q(e, i) {
10165
+ function U(e, i) {
10166
10166
  Object.assign(i, e);
10167
10167
  }
10168
- var V = function() {
10168
+ var Q = function() {
10169
10169
  var e = function() {
10170
10170
  };
10171
10171
  e.prototype = { p: {} };
@@ -10186,25 +10186,25 @@ var Ue = {};
10186
10186
  }();
10187
10187
  function G(e, i) {
10188
10188
  if (e.prototype.constructor = e, e.prototype["$is" + e.name] = e, i != null) {
10189
- if (V) {
10189
+ if (Q) {
10190
10190
  e.prototype.__proto__ = i.prototype;
10191
10191
  return;
10192
10192
  }
10193
10193
  var n = Object.create(i.prototype);
10194
- P(e.prototype, n), e.prototype = n;
10194
+ N(e.prototype, n), e.prototype = n;
10195
10195
  }
10196
10196
  }
10197
10197
  function Y(e, i) {
10198
10198
  for (var n = 0; n < i.length; n++)
10199
10199
  G(i[n], e);
10200
10200
  }
10201
- function ae(e, i) {
10202
- q(i.prototype, e.prototype), e.prototype.constructor = e;
10201
+ function ie(e, i) {
10202
+ U(i.prototype, e.prototype), e.prototype.constructor = e;
10203
10203
  }
10204
10204
  function oe(e, i) {
10205
- H(i.prototype, e.prototype), e.prototype.constructor = e;
10205
+ B(i.prototype, e.prototype), e.prototype.constructor = e;
10206
10206
  }
10207
- function Z(e, i, n, a) {
10207
+ function ee(e, i, n, a) {
10208
10208
  var s = e;
10209
10209
  e[i] = s, e[n] = function() {
10210
10210
  e[n] = function() {
@@ -10221,7 +10221,7 @@ var Ue = {};
10221
10221
  return l;
10222
10222
  };
10223
10223
  }
10224
- function fe(e, i, n, a) {
10224
+ function ye(e, i, n, a) {
10225
10225
  var s = e;
10226
10226
  e[i] = s, e[n] = function() {
10227
10227
  return e[i] === s && (e[i] = a()), e[n] = function() {
@@ -10242,17 +10242,17 @@ var Ue = {};
10242
10242
  }, _;
10243
10243
  };
10244
10244
  }
10245
- function ye(e) {
10245
+ function $e(e) {
10246
10246
  return e.immutable$list = Array, e.fixed$length = Array, e;
10247
10247
  }
10248
- function ie(e) {
10248
+ function de(e) {
10249
10249
  return e;
10250
10250
  }
10251
- function ee(e) {
10251
+ function ne(e) {
10252
10252
  for (var i = 0; i < e.length; ++i)
10253
10253
  e[i];
10254
10254
  }
10255
- function le(e, i) {
10255
+ function X(e, i) {
10256
10256
  var n = null;
10257
10257
  return e ? function(a) {
10258
10258
  return n === null && (n = o.closureFromTearOff(i)), new n(a, this);
@@ -10260,59 +10260,59 @@ var Ue = {};
10260
10260
  return n === null && (n = o.closureFromTearOff(i)), new n(this, null);
10261
10261
  };
10262
10262
  }
10263
- function ue(e) {
10263
+ function _e(e) {
10264
10264
  var i = null;
10265
10265
  return function() {
10266
10266
  return i === null && (i = o.closureFromTearOff(e).prototype), i;
10267
10267
  };
10268
10268
  }
10269
- var _e = 0;
10270
- function ne(e, i, n, a, s, l, _, d, c, f) {
10271
- return typeof d == "number" && (d += _e), { co: e, iS: i, iI: n, rC: a, dV: s, cs: l, fs: _, fT: d, aI: c || 0, nDA: f };
10269
+ var le = 0;
10270
+ function ae(e, i, n, a, s, l, _, d, c, f) {
10271
+ return typeof d == "number" && (d += le), { co: e, iS: i, iI: n, rC: a, dV: s, cs: l, fs: _, fT: d, aI: c || 0, nDA: f };
10272
10272
  }
10273
- function de(e, i, n, a, s, l, _, d) {
10274
- var c = ne(e, !0, !1, n, a, s, l, _, d, !1), f = ue(c);
10273
+ function ce(e, i, n, a, s, l, _, d) {
10274
+ var c = ae(e, !0, !1, n, a, s, l, _, d, !1), f = _e(c);
10275
10275
  e[i] = f;
10276
10276
  }
10277
- function he(e, i, n, a, s, l, _, d, c, f) {
10277
+ function ge(e, i, n, a, s, l, _, d, c, f) {
10278
10278
  n = !!n;
10279
- var $ = ne(e, !1, n, a, s, l, _, d, c, !!f), g = le(n, $);
10279
+ var $ = ae(e, !1, n, a, s, l, _, d, c, !!f), g = X(n, $);
10280
10280
  e[i] = g;
10281
10281
  }
10282
- function Te(e) {
10282
+ function me(e) {
10283
10283
  var i = I.interceptorsByTag;
10284
10284
  if (!i) {
10285
10285
  I.interceptorsByTag = e;
10286
10286
  return;
10287
10287
  }
10288
- P(e, i);
10288
+ N(e, i);
10289
10289
  }
10290
- function $e(e) {
10290
+ function ue(e) {
10291
10291
  var i = I.leafTags;
10292
10292
  if (!i) {
10293
10293
  I.leafTags = e;
10294
10294
  return;
10295
10295
  }
10296
- P(e, i);
10296
+ N(e, i);
10297
10297
  }
10298
- function ge(e) {
10298
+ function Se(e) {
10299
10299
  var i = I.types, n = i.length;
10300
10300
  return i.push.apply(i, e), n;
10301
10301
  }
10302
10302
  function j(e, i) {
10303
- return P(i, e), e;
10303
+ return N(i, e), e;
10304
10304
  }
10305
10305
  var t = function() {
10306
10306
  var e = function(n, a, s, l, _) {
10307
10307
  return function(d, c, f, $) {
10308
- return he(d, c, n, a, s, l, [f], $, _, !1);
10308
+ return ge(d, c, n, a, s, l, [f], $, _, !1);
10309
10309
  };
10310
10310
  }, i = function(n, a, s, l) {
10311
10311
  return function(_, d, c, f) {
10312
- return de(_, d, n, a, s, [c], f, l);
10312
+ return ce(_, d, n, a, s, [c], f, l);
10313
10313
  };
10314
10314
  };
10315
- return { inherit: G, inheritMany: Y, mixin: ae, mixinHard: oe, installStaticTearOff: de, installInstanceTearOff: he, _instance_0u: e(0, 0, null, ["call$0"], 0), _instance_1u: e(0, 1, null, ["call$1"], 0), _instance_2u: e(0, 2, null, ["call$2"], 0), _instance_0i: e(1, 0, null, ["call$0"], 0), _instance_1i: e(1, 1, null, ["call$1"], 0), _instance_2i: e(1, 2, null, ["call$2"], 0), _static_0: i(0, null, ["call$0"], 0), _static_1: i(1, null, ["call$1"], 0), _static_2: i(2, null, ["call$2"], 0), makeConstList: ye, lazy: fe, lazyFinal: se, lazyOld: Z, updateHolder: j, convertToFastObject: ie, updateTypes: ge, setOrUpdateInterceptorsByTag: Te, setOrUpdateLeafTags: $e };
10315
+ return { inherit: G, inheritMany: Y, mixin: ie, mixinHard: oe, installStaticTearOff: ce, installInstanceTearOff: ge, _instance_0u: e(0, 0, null, ["call$0"], 0), _instance_1u: e(0, 1, null, ["call$1"], 0), _instance_2u: e(0, 2, null, ["call$2"], 0), _instance_0i: e(1, 0, null, ["call$0"], 0), _instance_1i: e(1, 1, null, ["call$1"], 0), _instance_2i: e(1, 2, null, ["call$2"], 0), _static_0: i(0, null, ["call$0"], 0), _static_1: i(1, null, ["call$1"], 0), _static_2: i(2, null, ["call$2"], 0), makeConstList: $e, lazy: ye, lazyFinal: se, lazyOld: ee, updateHolder: j, convertToFastObject: de, updateTypes: Se, setOrUpdateInterceptorsByTag: me, setOrUpdateLeafTags: ue };
10316
10316
  }(), o = {
10317
10317
  JS_CONST: function() {
10318
10318
  },
@@ -10358,8 +10358,8 @@ var Ue = {};
10358
10358
  }
10359
10359
  },
10360
10360
  Sort__dualPivotQuicksort(e, i, n, a) {
10361
- var s, l, _, d, c, f, $, g, m, h, A = p.JSInt_methods._tdivFast$1(n - i + 1, 6), E = i + A, M = n - A, b = p.JSInt_methods._tdivFast$1(i + n, 2), R = b - A, C = b + A, O = u.getInterceptor$asx(e), D = O.$index(e, E), L = O.$index(e, R), v = O.$index(e, b), x = O.$index(e, C), B = O.$index(e, M);
10362
- if (a.call$2(D, L) > 0 && (s = L, L = D, D = s), a.call$2(x, B) > 0 && (s = B, B = x, x = s), a.call$2(D, v) > 0 && (s = v, v = D, D = s), a.call$2(L, v) > 0 && (s = v, v = L, L = s), a.call$2(D, x) > 0 && (s = x, x = D, D = s), a.call$2(v, x) > 0 && (s = x, x = v, v = s), a.call$2(L, B) > 0 && (s = B, B = L, L = s), a.call$2(L, v) > 0 && (s = v, v = L, L = s), a.call$2(x, B) > 0 && (s = B, B = x, x = s), O.$indexSet(e, E, D), O.$indexSet(e, b, v), O.$indexSet(e, M, B), O.$indexSet(e, R, O.$index(e, i)), O.$indexSet(e, C, O.$index(e, n)), l = i + 1, _ = n - 1, u.$eq$(a.call$2(L, x), 0)) {
10361
+ var s, l, _, d, c, f, $, g, m, h, A = p.JSInt_methods._tdivFast$1(n - i + 1, 6), E = i + A, M = n - A, b = p.JSInt_methods._tdivFast$1(i + n, 2), R = b - A, C = b + A, O = u.getInterceptor$asx(e), D = O.$index(e, E), L = O.$index(e, R), v = O.$index(e, b), x = O.$index(e, C), q = O.$index(e, M);
10362
+ if (a.call$2(D, L) > 0 && (s = L, L = D, D = s), a.call$2(x, q) > 0 && (s = q, q = x, x = s), a.call$2(D, v) > 0 && (s = v, v = D, D = s), a.call$2(L, v) > 0 && (s = v, v = L, L = s), a.call$2(D, x) > 0 && (s = x, x = D, D = s), a.call$2(v, x) > 0 && (s = x, x = v, v = s), a.call$2(L, q) > 0 && (s = q, q = L, L = s), a.call$2(L, v) > 0 && (s = v, v = L, L = s), a.call$2(x, q) > 0 && (s = q, q = x, x = s), O.$indexSet(e, E, D), O.$indexSet(e, b, v), O.$indexSet(e, M, q), O.$indexSet(e, R, O.$index(e, i)), O.$indexSet(e, C, O.$index(e, n)), l = i + 1, _ = n - 1, u.$eq$(a.call$2(L, x), 0)) {
10363
10363
  for (d = l; d <= _; ++d)
10364
10364
  if (c = O.$index(e, d), f = a.call$2(c, L), f !== 0)
10365
10365
  if (f < 0)
@@ -11855,7 +11855,7 @@ var Ue = {};
11855
11855
  return c === 12 ? i === r.JavaScriptFunction ? !0 : l ? !1 : o._isFunctionSubtype(e, i, n, a, s) : _ === 9 ? c !== 9 ? !1 : o._isInterfaceSubtype(e, i, n, a, s) : (l = _ === 11, l && a === r.Record ? !0 : l && c === 11 ? o._isRecordSubtype(e, i, n, a, s) : !1);
11856
11856
  },
11857
11857
  _isFunctionSubtype(e, i, n, a, s) {
11858
- var l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L, v, x, B, ce;
11858
+ var l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L, v, x, q, pe;
11859
11859
  if (!o._isSubtype(e, i._primary, n, a._primary, s) || (l = i._rest, _ = a._rest, d = l._requiredPositional, c = _._requiredPositional, f = d.length, $ = c.length, f > $) || (g = $ - f, m = l._optionalPositional, h = _._optionalPositional, A = m.length, E = h.length, f + A < $ + E))
11860
11860
  return !1;
11861
11861
  for (M = 0; M < f; ++M)
@@ -11869,14 +11869,14 @@ var Ue = {};
11869
11869
  return !1;
11870
11870
  for (R = l._named, C = _._named, O = R.length, D = C.length, L = 0, v = 0; v < D; v += 3)
11871
11871
  for (x = C[v]; ; ) {
11872
- if (L >= O || (B = R[L], L += 3, x < B))
11872
+ if (L >= O || (q = R[L], L += 3, x < q))
11873
11873
  return !1;
11874
- if (ce = R[L - 2], B < x) {
11875
- if (ce)
11874
+ if (pe = R[L - 2], q < x) {
11875
+ if (pe)
11876
11876
  return !1;
11877
11877
  continue;
11878
11878
  }
11879
- if (b = C[v + 1], ce && !b || (b = R[L - 1], !o._isSubtype(e, C[v + 2], s, b, n)))
11879
+ if (b = C[v + 1], pe && !b || (b = R[L - 1], !o._isSubtype(e, C[v + 2], s, b, n)))
11880
11880
  return !1;
11881
11881
  break;
11882
11882
  }
@@ -13586,15 +13586,15 @@ var Ue = {};
13586
13586
  }
13587
13587
  },
13588
13588
  formatChartData(e) {
13589
- var i, n = p.C_JsonCodec.decode$2$reviver(N.JSON.stringify(e), null), a = u.getInterceptor$asx(n), s = u.map$1$1$ax(r.List_dynamic._as(a.$index(n, "responses")), new o.formatChartData_closure(), r.QueryResponse), l = o.List_List$of(s, !0, s.$ti._eval$1("ListIterable.E")), _ = o._getConfig(a.$index(n, "widget")), d = o.EnumByName_byName(p.List_OX3, u.$index$asx(a.$index(n, "widget"), "type")), c = a.$index(n, "country");
13590
- return _ instanceof o.CircularDatasourceConfigModel ? i = o.formatCircularChartData(_, l, c).toJson$0() : _ instanceof o.BaseXYDatasourceConfigModel ? i = o.formatBaseXYChartData(d, _, l, c).toJson$0() : _ instanceof o.TableDatasourceConfigModel ? i = o.formatTableChartData(_, l, c).toJson$0() : i = d === p.ChartType_3 ? o.formatScoreCardChartData(_, l, c).toJson$0() : null, N.JSON.parse(p.C_JsonCodec.encode$2$toEncodable(i, null));
13589
+ var i, n = p.C_JsonCodec.decode$2$reviver(P.JSON.stringify(e), null), a = u.getInterceptor$asx(n), s = u.map$1$1$ax(r.List_dynamic._as(a.$index(n, "responses")), new o.formatChartData_closure(), r.QueryResponse), l = o.List_List$of(s, !0, s.$ti._eval$1("ListIterable.E")), _ = o._getConfig(a.$index(n, "widget")), d = o.EnumByName_byName(p.List_OX3, u.$index$asx(a.$index(n, "widget"), "type")), c = a.$index(n, "country");
13590
+ return _ instanceof o.CircularDatasourceConfigModel ? i = o.formatCircularChartData(_, l, c).toJson$0() : _ instanceof o.BaseXYDatasourceConfigModel ? i = o.formatBaseXYChartData(d, _, l, c).toJson$0() : _ instanceof o.TableDatasourceConfigModel ? i = o.formatTableChartData(_, l, c).toJson$0() : i = d === p.ChartType_3 ? o.formatScoreCardChartData(_, l, c).toJson$0() : null, P.JSON.parse(p.C_JsonCodec.encode$2$toEncodable(i, null));
13591
13591
  },
13592
13592
  formatChartData_closure: function() {
13593
13593
  },
13594
13594
  Exports: function() {
13595
13595
  },
13596
13596
  main() {
13597
- u.set$formatChartData$x(N.exports, o.allowInterop(o.js__formatChartData$closure()));
13597
+ u.set$formatChartData$x(P.exports, o.allowInterop(o.js__formatChartData$closure()));
13598
13598
  },
13599
13599
  _Exports: function() {
13600
13600
  },
@@ -17366,18 +17366,18 @@ Arguments: [` + c + "]";
17366
17366
  $signature: 0
17367
17367
  }, o._formatTableResponse_closure5.prototype = {
17368
17368
  call$2(e, i) {
17369
- var n, a, s, l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L = null, v = r.JSArray_List_dynamic, x = o._setArrayType([[]], v), B = o._setArrayType([[]], v);
17369
+ var n, a, s, l, _, d, c, f, $, g, m, h, A, E, M, b, R, C, O, D, L = null, v = r.JSArray_List_dynamic, x = o._setArrayType([[]], v), q = o._setArrayType([[]], v);
17370
17370
  for (v = this.headers, n = i.value, a = r.dynamic, s = r.JSArray_String, l = r.String, _ = this.metricColumns, d = 0; d < v.length; ++d)
17371
17371
  if (c = v[d], f = u.getInterceptor$ax(c), $ = f.map$1$1(c, new o._formatTableResponse__closure5(), l).join$1(0, "|"), o.IterableExtension_firstWhereOrNull(c, new o._formatTableResponse__closure6()) != null)
17372
17372
  for (g = f.firstWhere$1(c, new o._formatTableResponse__closure7()), m = f.fold$2(c, !0, new o._formatTableResponse__closure8(i)), f = x.length, h = g.type, A = g.columnValue, E = 0; E < x.length; x.length === f || (0, o.throwConcurrentModificationError)(x), ++E)
17373
17373
  M = x[E], m ? (b = n.$index(0, A), R = M.length, d >= R && p.JSArray_methods.addAll$1(M, o.List_List$filled(d - R + 1, L, !1, a)), M[d] = b) : (b = h == null ? L : o.DataTypeExtension_toData(h, L), R = M.length, d >= R && p.JSArray_methods.addAll$1(M, o.List_List$filled(d - R + 1, L, !1, a)), M[d] = b);
17374
17374
  else if (p.JSArray_methods.contains$1(o._setArrayType(["_metric_name", "_metric_value"], s), $))
17375
17375
  for (f = $ === "_metric_value", h = $ === "_metric_name", C = 0; C < _.length; ++C)
17376
- O = _[C], o.ListExtension_elementAtOrNull(x, C) == null && (x.push(o.List_List$of(x[0], !0, a)), B.push(o.List_List$of(B[0], !0, a))), h ? (A = x[C], b = O.label, R = A.length, d >= R && p.JSArray_methods.addAll$1(A, o.List_List$filled(d - R + 1, L, !1, a)), A[d] = b, B[C].push(b)) : f && (A = x[C], b = n.$index(0, O.id), R = A.length, d >= R && p.JSArray_methods.addAll$1(A, o.List_List$filled(d - R + 1, L, !1, a)), A[d] = b);
17376
+ O = _[C], o.ListExtension_elementAtOrNull(x, C) == null && (x.push(o.List_List$of(x[0], !0, a)), q.push(o.List_List$of(q[0], !0, a))), h ? (A = x[C], b = O.label, R = A.length, d >= R && p.JSArray_methods.addAll$1(A, o.List_List$filled(d - R + 1, L, !1, a)), A[d] = b, q[C].push(b)) : f && (A = x[C], b = n.$index(0, O.id), R = A.length, d >= R && p.JSArray_methods.addAll$1(A, o.List_List$filled(d - R + 1, L, !1, a)), A[d] = b);
17377
17377
  else
17378
17378
  for (D = 0; D < x.length; ++D)
17379
- f = x[D], h = n.$index(0, $), A = f.length, d >= A && p.JSArray_methods.addAll$1(f, o.List_List$filled(d - A + 1, L, !1, a)), f[d] = h, B[D].push(n.$index(0, $));
17380
- return v = r.Map_String_dynamic, n = o.List_List$of(e, !0, v), p.JSArray_methods.addAll$1(n, o.ListExtensions_mapIndexed(x, new o._formatTableResponse__closure9(B, i), r.List_dynamic, v)), n;
17379
+ f = x[D], h = n.$index(0, $), A = f.length, d >= A && p.JSArray_methods.addAll$1(f, o.List_List$filled(d - A + 1, L, !1, a)), f[d] = h, q[D].push(n.$index(0, $));
17380
+ return v = r.Map_String_dynamic, n = o.List_List$of(e, !0, v), p.JSArray_methods.addAll$1(n, o.ListExtensions_mapIndexed(x, new o._formatTableResponse__closure9(q, i), r.List_dynamic, v)), n;
17381
17381
  },
17382
17382
  $signature: 76
17383
17383
  }, o._formatTableResponse__closure5.prototype = {
@@ -17795,7 +17795,7 @@ Arguments: [` + c + "]";
17795
17795
  }
17796
17796
  }
17797
17797
  function l(f, $) {
17798
- return N.HTMLElement && f instanceof HTMLElement ? "HTMLElement" : s(f, $);
17798
+ return P.HTMLElement && f instanceof HTMLElement ? "HTMLElement" : s(f, $);
17799
17799
  }
17800
17800
  function _(f) {
17801
17801
  if (typeof window > "u" || typeof window[f] > "u") return null;
@@ -17920,8 +17920,8 @@ Arguments: [` + c + "]";
17920
17920
  return a.message;
17921
17921
  }
17922
17922
  }())), i(T, "DateTime__parseFormat", "$get$DateTime__parseFormat", () => o.RegExp_RegExp("^([+-]?\\d{4,6})-?(\\d\\d)-?(\\d\\d)(?:[ T](\\d\\d)(?::?(\\d\\d)(?::?(\\d\\d)(?:[.,](\\d+))?)?)?( ?[zZ]| ?([-+])(\\d\\d)(?::?(\\d\\d))?)?)?$")), i(T, "_hashSeed", "$get$_hashSeed", () => o.objectHashCode(p.Type_Object_xQ6)), i(T, "Endian_host", "$get$Endian_host", () => o.NativeByteData_NativeByteData$view(o.NativeUint16List__create1(o._ensureNativeList(o._setArrayType([1], r.JSArray_int))).buffer, 0, null).getInt8(0) === 1 ? p.C_Endian0 : p.C_Endian), i(T, "_clockKey", "$get$_clockKey", () => new o.Object()), i(T, "en_USSymbols", "$get$en_USSymbols", () => new o.DateSymbols("en_US", p.List_BC_AD, p.List_6xs, p.List_qpm, p.List_qpm, p.List_cIc, p.List_cIc, p.List_h8w, p.List_h8w, p.List_wMy, p.List_wMy, p.List_gc6, p.List_gc6, p.List_3US, p.List_Q1_Q2_Q3_Q4, p.List_bJM, p.List_AM_PM)), n(T, "_dateTimeSymbols", "$get$_dateTimeSymbols", () => o.UninitializedLocaleData$("initializeDateFormatting(<locale>)", T.$get$en_USSymbols())), n(T, "dateTimePatterns", "$get$dateTimePatterns", () => o.UninitializedLocaleData$("initializeDateFormatting(<locale>)", p.Map_EQ6TW)), i(T, "asciiZeroCodeUnit", "$get$asciiZeroCodeUnit", () => 48), i(T, "DateFormat__matchers", "$get$DateFormat__matchers", () => o._setArrayType([o.RegExp_RegExp("^'(?:[^']|'')*'"), o.RegExp_RegExp("^(?:G+|y+|M+|k+|S+|E+|a+|h+|K+|H+|c+|L+|Q+|d+|D+|m+|s+|v+|z+|Z+)"), o.RegExp_RegExp("^[^'GyMkSEahKHcLQdDmsvzZ]+")], o.findType("JSArray<RegExp>"))), i(T, "_DateFormatQuotedField__twoEscapedQuotes", "$get$_DateFormatQuotedField__twoEscapedQuotes", () => o.RegExp_RegExp("''")), i(T, "asciiDigitMatcher", "$get$asciiDigitMatcher", () => o.RegExp_RegExp("^\\d+")), n(T, "_availableLocales", "$get$_availableLocales", () => {
17923
- var a, s, l = o.EnLocale$(p.StartOfWeek_1), _ = o.EnLocale$(p.StartOfWeek_1), d = o.EnLocale$(p.StartOfWeek_1), c = o.EnLocale$(p.StartOfWeek_1), f = o.EnLocale$(p.StartOfWeek_1), $ = o.EnLocale$(p.StartOfWeek_2), g = o.EnLocale$(p.StartOfWeek_2), m = o.EnLocale$(p.StartOfWeek_1), h = o.EnLocale$(p.StartOfWeek_1), A = o.EsLocale$(p.StartOfWeek_2), E = o.EsLocale$(p.StartOfWeek_2), M = o.EsLocale$(p.StartOfWeek_1), b = o.FrLocale$(p.StartOfWeek_2), R = o.FrLocale$(p.StartOfWeek_2), C = o.FrLocale$(p.StartOfWeek_1), O = o.ZhCnLocale$(p.StartOfWeek_1), D = o.ZhCnLocale$(p.StartOfWeek_1), L = o.ZhLocale$(p.StartOfWeek_1), v = o.ZhLocale$(p.StartOfWeek_1), x = o.DeLocale$(p.StartOfWeek_2), B = o.DeLocale$(p.StartOfWeek_2), ce = o.DeLocale$(p.StartOfWeek_2), Ce = o.DeLocale$(p.StartOfWeek_2), be = o.ItLocale$(p.StartOfWeek_2), Re = o.ItLocale$(p.StartOfWeek_2), Fe = o.ArLyLocale$(!0, p.StartOfWeek_0), Oe = o.ArLyLocale$(!1, p.StartOfWeek_0), Le = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_1), we = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_1), ve = o.ArSaMaDzKwTnLocale$(!0, p.StartOfWeek_1), De = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_0), Ye = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_0);
17924
- return o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), a = o.PtLocale$(p.StartOfWeek_2), s = o.PtLocale$(p.StartOfWeek_1), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.LinkedHashMap_LinkedHashMap$_literal(["en", l, "en_us", _, "en_sg", d, "en_au", c, "en_ca", f, "en_gb", $, "en_ie", g, "en_il", m, "en_nz", h, "es", A, "es_do", E, "es_us", M, "fr", b, "fr_ch", R, "fr_ca", C, "zh", O, "zh_cn", D, "zh_hk", L, "zh_tw", v, "de", x, "de_de", B, "de_at", ce, "de_ch", Ce, "it", be, "it_ch", Re, "ar", Fe, "ar_ly", Oe, "ar_dz", Le, "ar_kw", we, "ar_sa", ve, "ar_ma", De, "ar_tn", Ye, "az", new o.AzLocale(p.StartOfWeek_2), "id", new o.IdLocale(p.StartOfWeek_1), "ja", new o.JaLocale(p.StartOfWeek_1), "ko", new o.KoLocale(p.StartOfWeek_1), "ru", new o.RuLocale(p.StartOfWeek_2), "uk", new o.UkLocale(p.StartOfWeek_2), "hi", new o.HiLocale(p.StartOfWeek_1), "pt", a, "pt_br", s, "pl", new o.PlLocale(p.StartOfWeek_2), "tr", new o.TrLocale(p.StartOfWeek_2), "sv", new o.SvLocale(p.StartOfWeek_2), "nb", new o.NbLocale(p.StartOfWeek_2), "fa", new o.FaLocale(p.StartOfWeek_0), "bn", new o.BnLocale(p.StartOfWeek_1), "nl", new o.NlLocale(p.StartOfWeek_2), "th", new o.ThLocale(p.StartOfWeek_1)], r.String, o.findType("Locale"));
17923
+ var a, s, l = o.EnLocale$(p.StartOfWeek_1), _ = o.EnLocale$(p.StartOfWeek_1), d = o.EnLocale$(p.StartOfWeek_1), c = o.EnLocale$(p.StartOfWeek_1), f = o.EnLocale$(p.StartOfWeek_1), $ = o.EnLocale$(p.StartOfWeek_2), g = o.EnLocale$(p.StartOfWeek_2), m = o.EnLocale$(p.StartOfWeek_1), h = o.EnLocale$(p.StartOfWeek_1), A = o.EsLocale$(p.StartOfWeek_2), E = o.EsLocale$(p.StartOfWeek_2), M = o.EsLocale$(p.StartOfWeek_1), b = o.FrLocale$(p.StartOfWeek_2), R = o.FrLocale$(p.StartOfWeek_2), C = o.FrLocale$(p.StartOfWeek_1), O = o.ZhCnLocale$(p.StartOfWeek_1), D = o.ZhCnLocale$(p.StartOfWeek_1), L = o.ZhLocale$(p.StartOfWeek_1), v = o.ZhLocale$(p.StartOfWeek_1), x = o.DeLocale$(p.StartOfWeek_2), q = o.DeLocale$(p.StartOfWeek_2), pe = o.DeLocale$(p.StartOfWeek_2), Ce = o.DeLocale$(p.StartOfWeek_2), be = o.ItLocale$(p.StartOfWeek_2), Re = o.ItLocale$(p.StartOfWeek_2), Fe = o.ArLyLocale$(!0, p.StartOfWeek_0), Oe = o.ArLyLocale$(!1, p.StartOfWeek_0), Le = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_1), we = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_1), ve = o.ArSaMaDzKwTnLocale$(!0, p.StartOfWeek_1), De = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_0), Ye = o.ArSaMaDzKwTnLocale$(!1, p.StartOfWeek_0);
17924
+ return o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), a = o.PtLocale$(p.StartOfWeek_2), s = o.PtLocale$(p.StartOfWeek_1), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.LinkedHashMap_LinkedHashMap$_literal(["en", l, "en_us", _, "en_sg", d, "en_au", c, "en_ca", f, "en_gb", $, "en_ie", g, "en_il", m, "en_nz", h, "es", A, "es_do", E, "es_us", M, "fr", b, "fr_ch", R, "fr_ca", C, "zh", O, "zh_cn", D, "zh_hk", L, "zh_tw", v, "de", x, "de_de", q, "de_at", pe, "de_ch", Ce, "it", be, "it_ch", Re, "ar", Fe, "ar_ly", Oe, "ar_dz", Le, "ar_kw", we, "ar_sa", ve, "ar_ma", De, "ar_tn", Ye, "az", new o.AzLocale(p.StartOfWeek_2), "id", new o.IdLocale(p.StartOfWeek_1), "ja", new o.JaLocale(p.StartOfWeek_1), "ko", new o.KoLocale(p.StartOfWeek_1), "ru", new o.RuLocale(p.StartOfWeek_2), "uk", new o.UkLocale(p.StartOfWeek_2), "hi", new o.HiLocale(p.StartOfWeek_1), "pt", a, "pt_br", s, "pl", new o.PlLocale(p.StartOfWeek_2), "tr", new o.TrLocale(p.StartOfWeek_2), "sv", new o.SvLocale(p.StartOfWeek_2), "nb", new o.NbLocale(p.StartOfWeek_2), "fa", new o.FaLocale(p.StartOfWeek_0), "bn", new o.BnLocale(p.StartOfWeek_1), "nl", new o.NlLocale(p.StartOfWeek_2), "th", new o.ThLocale(p.StartOfWeek_1)], r.String, o.findType("Locale"));
17925
17925
  });
17926
17926
  }(), function() {
17927
17927
  (function() {
@@ -17953,7 +17953,7 @@ Arguments: [` + c + "]";
17953
17953
  return this(e, i, n, a, s, l, _, d);
17954
17954
  }, Function.prototype.call$3 = function(e, i, n) {
17955
17955
  return this(e, i, n);
17956
- }, ee(S), function(e) {
17956
+ }, ne(S), function(e) {
17957
17957
  if (typeof document > "u") {
17958
17958
  e(null);
17959
17959
  return;
@@ -18003,12 +18003,12 @@ function Ot(F) {
18003
18003
  return "Unknown";
18004
18004
  }
18005
18005
  }
18006
- const Se = "/report-settings", st = async () => {
18006
+ const Ae = "/report-settings", st = async () => {
18007
18007
  const { businessId: F } = W(te());
18008
18008
  if (F) {
18009
18009
  const w = {
18010
18010
  fetchType: re.Get,
18011
- url: `${Se}/${F.value}/reports`
18011
+ url: `${Ae}/${F.value}/reports`
18012
18012
  };
18013
18013
  return K.fetch(w);
18014
18014
  } else
@@ -18016,27 +18016,27 @@ const Se = "/report-settings", st = async () => {
18016
18016
  }, lt = (F) => {
18017
18017
  const { businessId: w } = W(te()), J = {
18018
18018
  fetchType: re.Put,
18019
- url: `${Se}/${w.value}/reports/${F.id}`,
18019
+ url: `${Ae}/${w.value}/reports/${F.id}`,
18020
18020
  data: F
18021
18021
  };
18022
18022
  return K.fetch(J);
18023
18023
  }, _t = (F) => {
18024
18024
  const { businessId: w } = W(te()), J = {
18025
18025
  fetchType: re.Post,
18026
- url: `${Se}/${w.value}/reports`,
18026
+ url: `${Ae}/${w.value}/reports`,
18027
18027
  data: F
18028
18028
  };
18029
18029
  return K.fetch(J);
18030
18030
  }, ut = (F) => {
18031
18031
  const { businessId: w } = W(te()), J = {
18032
18032
  fetchType: re.Delete,
18033
- url: `${Se}/${w.value}/reports/${F.id}`
18033
+ url: `${Ae}/${w.value}/reports/${F.id}`
18034
18034
  };
18035
18035
  return K.fetch(J);
18036
18036
  }, dt = (F) => {
18037
18037
  const { businessId: w } = W(te()), J = {
18038
18038
  fetchType: re.Put,
18039
- url: `${Se}/${w.value}/reports/default`,
18039
+ url: `${Ae}/${w.value}/reports/default`,
18040
18040
  data: { defaultReport: F }
18041
18041
  };
18042
18042
  return K.fetch(J);
@@ -18045,7 +18045,7 @@ const Se = "/report-settings", st = async () => {
18045
18045
  if (F) {
18046
18046
  const w = {
18047
18047
  fetchType: re.Get,
18048
- url: `${Se}/${F.value}/overview-report`
18048
+ url: `${Ae}/${F.value}/overview-report`
18049
18049
  };
18050
18050
  return K.fetch(w);
18051
18051
  } else
@@ -18055,7 +18055,7 @@ const Se = "/report-settings", st = async () => {
18055
18055
  if (F) {
18056
18056
  const w = {
18057
18057
  fetchType: re.Get,
18058
- url: `${Se}/${F.value}/config`
18058
+ url: `${Ae}/${F.value}/config`
18059
18059
  };
18060
18060
  return K.fetch(w);
18061
18061
  } else
@@ -18084,7 +18084,7 @@ function Je(F, w = {}) {
18084
18084
  const J = localStorage.getItem(F);
18085
18085
  return J === null && (w == null ? void 0 : w.fallback) !== void 0 ? w.fallback : J === null ? null : w.format ? w.format(J) : J;
18086
18086
  }
18087
- const me = {
18087
+ const he = {
18088
18088
  get: Je,
18089
18089
  getJson: (F) => Je(F, {
18090
18090
  fallback: {},
@@ -18099,133 +18099,133 @@ const me = {
18099
18099
  localStorage.setItem(F, JSON.stringify(w));
18100
18100
  }
18101
18101
  }, gt = "mf-reportreport-store", Be = ke(gt, () => {
18102
- const { business: F } = W(Ie()), { flags: w } = W(Ne()), J = X([]), U = X([]), N = X(0), Q = et(), k = Ae(() => J.value.filter((p) => p.editable)), P = Ae(() => J.value.filter((p) => !p.editable)), H = X(!1), q = X(""), V = X(), G = X(), Y = Ae(() => {
18102
+ const { business: F } = W(Ie()), { flags: w } = W(Ne()), J = Z([]), H = Z([]), P = Z(0), V = et(), k = Te(() => J.value.filter((p) => p.editable)), N = Te(() => J.value.filter((p) => !p.editable)), B = Z(!1), U = Z(""), Q = Z(), G = Z(), Y = Te(() => {
18103
18103
  const p = w.value.find(
18104
18104
  (S) => S.key === je.report_portal_integration_custom_report
18105
18105
  );
18106
18106
  return typeof (p == null ? void 0 : p.value) == "number" ? p.value : null;
18107
- }), ae = Ae(() => Y.value === null ? !0 : Y.value - k.value.length > 0);
18107
+ }), ie = Te(() => Y.value === null ? !0 : Y.value - k.value.length > 0);
18108
18108
  async function oe() {
18109
18109
  return G.value = await ct(), G.value;
18110
18110
  }
18111
- async function Z() {
18111
+ async function ee() {
18112
18112
  var p;
18113
18113
  try {
18114
- J.value = await st(), U.value = await yt(), J.value.find((T) => T.id === q.value) || (q.value = ((p = J.value.find((T) => T.isDefault)) == null ? void 0 : p.id) || J.value[0].id);
18114
+ J.value = await st(), H.value = await yt(), J.value.find((T) => T.id === U.value) || (U.value = ((p = J.value.find((T) => T.isDefault)) == null ? void 0 : p.id) || J.value[0].id);
18115
18115
  } catch (S) {
18116
- console.log(S), Q.open({
18116
+ console.log(S), V.open({
18117
18117
  title: "Report Fetch Error",
18118
18118
  message: "Internal Server Error",
18119
18119
  type: "error"
18120
18120
  });
18121
18121
  }
18122
18122
  }
18123
- const fe = Ae(
18124
- () => J.value.find((p) => p.id === q.value)
18125
- ), se = X(), ye = X(0), ie = X(), ee = X(!1), le = X(!1), ue = X(!1);
18126
- async function _e(p) {
18123
+ const ye = Te(
18124
+ () => J.value.find((p) => p.id === U.value)
18125
+ ), se = Z(), $e = Z(0), de = Z(), ne = Z(!1), X = Z(!1), _e = Z(!1);
18126
+ async function le(p) {
18127
18127
  if (k.value.findIndex((T) => T.id === p.id) >= 0) {
18128
18128
  const T = await lt(p);
18129
- q.value = T.id;
18129
+ U.value = T.id;
18130
18130
  } else {
18131
18131
  const T = await _t(p);
18132
- q.value = T.id;
18132
+ U.value = T.id;
18133
18133
  }
18134
- await Z();
18134
+ await ee();
18135
18135
  }
18136
- async function ne(p) {
18136
+ async function ae(p) {
18137
18137
  return await $t(p);
18138
18138
  }
18139
- async function de(p) {
18140
- await ut(p), await Z();
18139
+ async function ce(p) {
18140
+ await ut(p), await ee();
18141
18141
  }
18142
- async function he(p) {
18143
- await dt(p), await Z();
18142
+ async function ge(p) {
18143
+ await dt(p), await ee();
18144
18144
  }
18145
- function Te(p) {
18146
- J.value.findIndex((T) => T.id === p) !== -1 && (q.value = p);
18145
+ function me(p) {
18146
+ J.value.findIndex((T) => T.id === p) !== -1 && (U.value = p);
18147
18147
  }
18148
- const $e = X(null);
18149
- function ge() {
18148
+ const ue = Z(null);
18149
+ function Se() {
18150
18150
  var p;
18151
18151
  if ((p = F.value) != null && p._id) {
18152
- const S = me.getJson("pinReport")[F.value._id];
18152
+ const S = he.getJson("pinReport")[F.value._id];
18153
18153
  if ((S == null ? void 0 : S.length) > 0) {
18154
- $e.value = S;
18154
+ ue.value = S;
18155
18155
  return;
18156
18156
  }
18157
18157
  }
18158
- $e.value = null;
18158
+ ue.value = null;
18159
18159
  }
18160
18160
  function j(p) {
18161
18161
  var S;
18162
18162
  if (F.value && p) {
18163
- const T = me.getJson("pinReport");
18164
- T[(S = F.value) == null ? void 0 : S._id] ? T[F.value._id].push(p.id) : T[F.value._id] = [p.id], me.setJson("pinReport", T), ge();
18163
+ const T = he.getJson("pinReport");
18164
+ T[(S = F.value) == null ? void 0 : S._id] ? T[F.value._id].push(p.id) : T[F.value._id] = [p.id], he.setJson("pinReport", T), Se();
18165
18165
  }
18166
18166
  }
18167
18167
  function t(p) {
18168
18168
  if (F.value) {
18169
- const S = me.getJson("pinReport");
18169
+ const S = he.getJson("pinReport");
18170
18170
  S[F.value._id].length === 1 ? S[F.value._id] = [] : S[F.value._id] = S[F.value._id].filter(
18171
18171
  (T) => T !== p
18172
- ), me.setJson("pinReport", S), ge();
18172
+ ), he.setJson("pinReport", S), Se();
18173
18173
  }
18174
18174
  }
18175
18175
  function o() {
18176
18176
  if (F.value) {
18177
- const p = me.getJson("feedback");
18177
+ const p = he.getJson("feedback");
18178
18178
  if (!p[F.value._id])
18179
18179
  p[F.value._id] = {
18180
- date: pe().local().format("YYYY-MM-DD"),
18180
+ date: fe().local().format("YYYY-MM-DD"),
18181
18181
  feedback: !1
18182
18182
  };
18183
18183
  else {
18184
- const S = pe(p[F.value._id].date).local();
18185
- Math.abs(S.diff(pe().endOf("day").local(), "d")) >= 1 && !p[F.value._id].feedback && (le.value = !0);
18184
+ const S = fe(p[F.value._id].date).local();
18185
+ Math.abs(S.diff(fe().endOf("day").local(), "d")) >= 1 && !p[F.value._id].feedback && (X.value = !0);
18186
18186
  }
18187
- me.setJson("feedback", p);
18187
+ he.setJson("feedback", p);
18188
18188
  }
18189
18189
  }
18190
18190
  async function u() {
18191
18191
  return await pt();
18192
18192
  }
18193
18193
  return {
18194
- isOpenDownloadDialog: ee,
18195
- isOpenFeedbackDialog: le,
18196
- isOpenEmailDialog: ue,
18197
- currentSelectWidgetType: V,
18194
+ isOpenDownloadDialog: ne,
18195
+ isOpenFeedbackDialog: X,
18196
+ isOpenEmailDialog: _e,
18197
+ currentSelectWidgetType: Q,
18198
18198
  reports: J,
18199
- categories: U,
18200
- currentReport: fe,
18199
+ categories: H,
18200
+ currentReport: ye,
18201
18201
  editingReport: se,
18202
- editingIndex: ye,
18203
- editingTile: ie,
18204
- currentReportId: q,
18202
+ editingIndex: $e,
18203
+ editingTile: de,
18204
+ currentReportId: U,
18205
18205
  editableReports: k,
18206
- nonEditableReports: P,
18207
- isOpenAddReportDialog: H,
18206
+ nonEditableReports: N,
18207
+ isOpenAddReportDialog: B,
18208
18208
  overviewReport: G,
18209
- pinReport: $e,
18210
- scrollPositionY: N,
18209
+ pinReport: ue,
18210
+ scrollPositionY: P,
18211
18211
  customReportQuota: Y,
18212
- canCreateCustomReport: ae,
18213
- createOrUpdateReport: _e,
18214
- removeReport: de,
18215
- updateCurrentReportId: Te,
18216
- getReports: Z,
18217
- updateDefaultReport: he,
18212
+ canCreateCustomReport: ie,
18213
+ createOrUpdateReport: le,
18214
+ removeReport: ce,
18215
+ updateCurrentReportId: me,
18216
+ getReports: ee,
18217
+ updateDefaultReport: ge,
18218
18218
  checkFeedback: o,
18219
18219
  getOverviewReport: oe,
18220
- refreshPinReport: ge,
18220
+ refreshPinReport: Se,
18221
18221
  cachePinReport: j,
18222
18222
  clearPinReport: t,
18223
18223
  getReportConfig: u,
18224
- submitFeedback: ne
18224
+ submitFeedback: ae
18225
18225
  };
18226
18226
  }), mt = "mf-reportnavigation", Qe = ke(mt, () => {
18227
- const { disabled: F } = W(ze()), { isIntegrationWhitelist: w } = W(Ne()), J = X("v5"), U = Ae(() => {
18228
- const P = [
18227
+ const { disabled: F } = W(ze()), { isIntegrationWhitelist: w } = W(Ne()), J = Z("v5"), H = Te(() => {
18228
+ const N = [
18229
18229
  {
18230
18230
  label: "overview",
18231
18231
  value: "overview",
@@ -18248,83 +18248,83 @@ const me = {
18248
18248
  route: "setting"
18249
18249
  }
18250
18250
  ];
18251
- return !F.value && w.value && P.push({
18251
+ return !F.value && w.value && N.push({
18252
18252
  label: "integration",
18253
18253
  value: "integration",
18254
18254
  route: "integrations"
18255
- }), P;
18256
- }), N = X(""), { currentRoute: Q } = rt();
18257
- function k(P) {
18258
- switch (P.name) {
18255
+ }), N;
18256
+ }), P = Z(""), { currentRoute: V } = rt();
18257
+ function k(N) {
18258
+ switch (N.name) {
18259
18259
  case "report":
18260
18260
  case "reports":
18261
- N.value = "report";
18261
+ P.value = "report";
18262
18262
  break;
18263
18263
  case "overview":
18264
- N.value = "overview";
18264
+ P.value = "overview";
18265
18265
  break;
18266
18266
  case "setting":
18267
- N.value = "setting";
18267
+ P.value = "setting";
18268
18268
  break;
18269
18269
  case "insights":
18270
- N.value = "insight";
18270
+ P.value = "insight";
18271
18271
  break;
18272
18272
  case "integration":
18273
18273
  case "integrations":
18274
- N.value = "integration";
18274
+ P.value = "integration";
18275
18275
  break;
18276
18276
  }
18277
18277
  }
18278
18278
  return Ze(
18279
- Q,
18280
- (P) => {
18281
- k(P);
18279
+ V,
18280
+ (N) => {
18281
+ k(N);
18282
18282
  },
18283
18283
  { immediate: !0 }
18284
18284
  ), {
18285
- selectedNavigationTab: N,
18286
- navigationTabs: U,
18285
+ selectedNavigationTab: P,
18286
+ navigationTabs: H,
18287
18287
  version: J
18288
18288
  };
18289
18289
  });
18290
18290
  var Ve = /* @__PURE__ */ ((F) => (F.generating = "GENERATING", F.completed = "COMPLETED", F.failed = "FAILED", F.canceled = "CANCELLED", F))(Ve || {});
18291
- pe.extend(Ke);
18291
+ fe.extend(Ke);
18292
18292
  async function St(F, w) {
18293
18293
  for (let J = 0; J < F.length; J++)
18294
18294
  try {
18295
18295
  return await F[J]();
18296
- } catch (U) {
18297
- if (U.message === "Unauthorized" || J === F.length - 1) throw U;
18298
- await new Promise((N) => setTimeout(N, w));
18296
+ } catch (H) {
18297
+ if (H.message === "Unauthorized" || J === F.length - 1) throw H;
18298
+ await new Promise((P) => setTimeout(P, w));
18299
18299
  }
18300
18300
  throw new Error("No callback");
18301
18301
  }
18302
18302
  const Lt = async (F, w) => {
18303
- var Y, ae, oe, Z;
18304
- const { businessId: J, country: U } = W(te()), {
18305
- selectedRestaurantIds: N,
18306
- selectedWarehouseIds: Q,
18303
+ var Y, ie, oe, ee;
18304
+ const { businessId: J, country: H } = W(te()), {
18305
+ selectedRestaurantIds: P,
18306
+ selectedWarehouseIds: V,
18307
18307
  selectedLocationIds: k,
18308
- dateRange: P,
18309
- compareDateRange: H,
18310
- timeRange: q
18308
+ dateRange: N,
18309
+ compareDateRange: B,
18310
+ timeRange: U
18311
18311
  } = Ie();
18312
18312
  if (k.length === 0)
18313
18313
  return null;
18314
- const V = {
18314
+ const Q = {
18315
18315
  fetchType: re.Post,
18316
18316
  url: `/${J.value}/postgres-query`,
18317
18317
  data: Me.getQueryRequests({
18318
18318
  widget: F,
18319
- dateRange: [P.startDate, P.endDate],
18320
- compareDateRange: H.startDate && H.endDate ? [H.startDate, H.endDate] : void 0,
18319
+ dateRange: [N.startDate, N.endDate],
18320
+ compareDateRange: B.startDate && B.endDate ? [B.startDate, B.endDate] : void 0,
18321
18321
  timeRange: [
18322
- pe().set("hour", Number((Y = q.start) == null ? void 0 : Y.hour)).set("minute", Number((ae = q.start) == null ? void 0 : ae.minute)).toISOString(),
18323
- pe().set("hour", Number((oe = q.end) == null ? void 0 : oe.hour)).set("minute", Number((Z = q.end) == null ? void 0 : Z.minute)).toISOString()
18322
+ fe().set("hour", Number((Y = U.start) == null ? void 0 : Y.hour)).set("minute", Number((ie = U.start) == null ? void 0 : ie.minute)).toISOString(),
18323
+ fe().set("hour", Number((oe = U.end) == null ? void 0 : oe.hour)).set("minute", Number((ee = U.end) == null ? void 0 : ee.minute)).toISOString()
18324
18324
  ],
18325
18325
  businessIds: J.value ? [J.value] : [],
18326
- restaurantIds: N,
18327
- warehouseIds: Q,
18326
+ restaurantIds: P,
18327
+ warehouseIds: V,
18328
18328
  timezone: Intl.DateTimeFormat().resolvedOptions().timeZone
18329
18329
  }),
18330
18330
  requestConfig: {
@@ -18333,16 +18333,16 @@ const Lt = async (F, w) => {
18333
18333
  }
18334
18334
  }, G = await St(
18335
18335
  [
18336
- () => K.fetch(V),
18337
- () => K.fetch(V),
18338
- () => (V.url = V.url.replace("postgres-query", "query"), K.fetch(V))
18336
+ () => K.fetch(Q),
18337
+ () => K.fetch(Q),
18338
+ () => (Q.url = Q.url.replace("postgres-query", "query"), K.fetch(Q))
18339
18339
  ],
18340
18340
  2e3
18341
18341
  );
18342
18342
  return it.formatChartData({
18343
18343
  responses: G,
18344
18344
  widget: F,
18345
- country: U.value
18345
+ country: H.value
18346
18346
  });
18347
18347
  };
18348
18348
  function Ge(F) {
@@ -18383,43 +18383,49 @@ function We(F) {
18383
18383
  colWidths: w.colWidths
18384
18384
  };
18385
18385
  }
18386
- const wt = async (F, w, J) => {
18387
- const { businessId: U } = W(te()), { selectedRestaurantIds: N, selectedWarehouseIds: Q, dateRange: k, timeRange: P } = Ie(), { currentReport: H, overviewReport: q } = Be(), { selectedNavigationTab: V } = Qe();
18388
- let G = H == null ? void 0 : H.id, Y = (H == null ? void 0 : H.tiles) ?? [];
18389
- V === "overview" && q && (G = q == null ? void 0 : q.id, Y = (q == null ? void 0 : q.tiles) ?? []);
18390
- const ae = Y.filter((ee, le) => typeof w == "number" ? le === w : !0).map((ee) => ee.widget), oe = {
18386
+ const wt = async ({
18387
+ reportType: F,
18388
+ index: w,
18389
+ orientationTypes: J,
18390
+ locationIds: H,
18391
+ timeRange: P,
18392
+ dateRange: V
18393
+ }) => {
18394
+ const { businessId: k } = W(te()), { restaurants: N, warehouses: B } = Ie(), { currentReport: U, overviewReport: Q } = Be(), { selectedNavigationTab: G } = Qe();
18395
+ let Y = U == null ? void 0 : U.id, ie = (U == null ? void 0 : U.tiles) ?? [];
18396
+ G === "overview" && Q && (Y = Q == null ? void 0 : Q.id, ie = (Q == null ? void 0 : Q.tiles) ?? []);
18397
+ const oe = ie.filter((X, _e) => typeof w == "number" ? _e === w : !0).map((X) => X.widget), ee = {
18391
18398
  fetchType: re.Post,
18392
- url: `/${U.value}/file`,
18399
+ url: `/${k.value}/file`,
18393
18400
  data: {
18394
18401
  configs: [
18395
- ...ae.map((ee, le) => {
18396
- var ue, _e, ne, de;
18402
+ ...oe.map((X, _e) => {
18403
+ var le, ae, ce, ge;
18397
18404
  return {
18398
18405
  requests: Me.getQueryRequests({
18399
- widget: ee,
18400
- dateRange: [k.startDate, k.endDate],
18401
- // TODO: export with comparable data?
18402
- // compareDateRange:
18403
- // compareDateRange.start && compareDateRange.end
18404
- // ? [compareDateRange.start.toUTC().toISO(), compareDateRange.end.toUTC().toISO()]
18405
- // : undefined,
18406
+ widget: X,
18407
+ dateRange: [V.startDate, V.endDate],
18406
18408
  timeRange: [
18407
- pe().set("hour", Number((ue = P.start) == null ? void 0 : ue.hour)).set("minute", Number((_e = P.start) == null ? void 0 : _e.minute)).toISOString(),
18408
- pe().set("hour", Number((ne = P.end) == null ? void 0 : ne.hour)).set("minute", Number((de = P.end) == null ? void 0 : de.minute)).toISOString()
18409
+ fe().set("hour", Number((le = P.start) == null ? void 0 : le.hour)).set("minute", Number((ae = P.start) == null ? void 0 : ae.minute)).toISOString(),
18410
+ fe().set("hour", Number((ce = P.end) == null ? void 0 : ce.hour)).set("minute", Number((ge = P.end) == null ? void 0 : ge.minute)).toISOString()
18409
18411
  ],
18410
- businessIds: U ? [U.value] : [],
18411
- restaurantIds: N,
18412
- warehouseIds: Q,
18412
+ businessIds: k ? [k.value] : [],
18413
+ restaurantIds: H.filter(
18414
+ (me) => N.find((ue) => ue.id === me)
18415
+ ),
18416
+ warehouseIds: H.filter(
18417
+ (me) => B.find((ue) => ue.id === me)
18418
+ ),
18413
18419
  timezone: Intl.DateTimeFormat().resolvedOptions().timeZone
18414
18420
  }),
18415
- index: w || le,
18421
+ index: w || _e,
18416
18422
  drillDimension: null,
18417
- ...Ge(ee),
18418
- ...We(ee)
18423
+ ...Ge(X),
18424
+ ...We(X)
18419
18425
  };
18420
18426
  })
18421
18427
  ],
18422
- reportId: G,
18428
+ reportId: Y,
18423
18429
  type: F,
18424
18430
  orientationTypes: J
18425
18431
  },
@@ -18427,52 +18433,52 @@ const wt = async (F, w, J) => {
18427
18433
  responseType: "arraybuffer",
18428
18434
  timeout: 1e3 * 60 * 3
18429
18435
  }
18430
- }, { headers: Z, data: fe } = await K.rawFetch(oe), se = Z["content-disposition"].split("filename=")[1].replaceAll('"', ""), ye = window.URL.createObjectURL(new Blob([new Uint8Array(fe).buffer])), ie = document.createElement("a");
18431
- ie.href = ye, ie.setAttribute("download", decodeURIComponent(se)), document.body.appendChild(ie), ie.click(), ie.remove();
18436
+ }, { headers: ye, data: se } = await K.rawFetch(ee), $e = ye["content-disposition"].split("filename=")[1].replaceAll('"', ""), de = window.URL.createObjectURL(new Blob([new Uint8Array(se).buffer])), ne = document.createElement("a");
18437
+ ne.href = de, ne.setAttribute("download", decodeURIComponent($e)), document.body.appendChild(ne), ne.click(), ne.remove();
18432
18438
  }, vt = async ({
18433
18439
  emails: F,
18434
18440
  types: w,
18435
18441
  dateRange: J,
18436
- timeRange: U,
18437
- locationIds: N,
18438
- orientationTypes: Q
18442
+ timeRange: H,
18443
+ locationIds: P,
18444
+ orientationTypes: V
18439
18445
  }) => {
18440
- const { businessId: k } = W(te()), { currentReport: P, overviewReport: H } = Be(), { selectedNavigationTab: q } = Qe(), { restaurants: V, warehouses: G } = Ie();
18446
+ const { businessId: k } = W(te()), { currentReport: N, overviewReport: B } = Be(), { selectedNavigationTab: U } = Qe(), { restaurants: Q, warehouses: G } = Ie();
18441
18447
  if (F.length === 0) {
18442
18448
  console.error("No email addresses provided.");
18443
18449
  return;
18444
18450
  }
18445
- let Y = (P == null ? void 0 : P.id) || "", ae = (P == null ? void 0 : P.name) || "", oe = (P == null ? void 0 : P.tiles) ?? [];
18446
- q === "overview" && H && (Y = H == null ? void 0 : H.id, ae = H.name, oe = (H == null ? void 0 : H.tiles) ?? []);
18447
- const Z = oe.map((se) => se.widget), fe = {
18451
+ let Y = (N == null ? void 0 : N.id) || "", ie = (N == null ? void 0 : N.name) || "", oe = (N == null ? void 0 : N.tiles) ?? [];
18452
+ U === "overview" && B && (Y = B == null ? void 0 : B.id, ie = B.name, oe = (B == null ? void 0 : B.tiles) ?? []);
18453
+ const ee = oe.map((se) => se.widget), ye = {
18448
18454
  businessId: k.value,
18449
18455
  status: Ve.generating,
18450
18456
  dateRange: {
18451
18457
  start: J.startDate,
18452
18458
  end: J.endDate
18453
18459
  },
18454
- reportName: ae,
18460
+ reportName: ie,
18455
18461
  emails: F,
18456
- configs: Z.map((se, ye) => {
18457
- var ie, ee, le, ue;
18462
+ configs: ee.map((se, $e) => {
18463
+ var de, ne, X, _e;
18458
18464
  return {
18459
18465
  requests: Me.getQueryRequests({
18460
18466
  widget: se,
18461
18467
  dateRange: [J.startDate, J.endDate],
18462
18468
  timeRange: [
18463
- pe().hour(Number((ie = U.start) == null ? void 0 : ie.hour)).minute(Number((ee = U.start) == null ? void 0 : ee.minute)).toISOString(),
18464
- pe().hour(Number((le = U.end) == null ? void 0 : le.hour)).minute(Number((ue = U.end) == null ? void 0 : ue.minute)).toISOString()
18469
+ fe().hour(Number((de = H.start) == null ? void 0 : de.hour)).minute(Number((ne = H.start) == null ? void 0 : ne.minute)).toISOString(),
18470
+ fe().hour(Number((X = H.end) == null ? void 0 : X.hour)).minute(Number((_e = H.end) == null ? void 0 : _e.minute)).toISOString()
18465
18471
  ],
18466
18472
  businessIds: k ? [k.value] : [],
18467
- restaurantIds: N.filter(
18468
- (_e) => V.find((ne) => ne.id === _e)
18473
+ restaurantIds: P.filter(
18474
+ (le) => Q.find((ae) => ae.id === le)
18469
18475
  ),
18470
- warehouseIds: N.filter(
18471
- (_e) => G.find((ne) => ne.id === _e)
18476
+ warehouseIds: P.filter(
18477
+ (le) => G.find((ae) => ae.id === le)
18472
18478
  ),
18473
18479
  timezone: Intl.DateTimeFormat().resolvedOptions().timeZone
18474
18480
  }),
18475
- index: ye,
18481
+ index: $e,
18476
18482
  drillDimension: null,
18477
18483
  ...Ge(se),
18478
18484
  ...We(se)
@@ -18480,12 +18486,12 @@ const wt = async (F, w, J) => {
18480
18486
  }),
18481
18487
  reportId: Y,
18482
18488
  type: w,
18483
- orientationTypes: Q
18489
+ orientationTypes: V
18484
18490
  };
18485
18491
  await K.fetch({
18486
18492
  fetchType: re.Post,
18487
18493
  url: `/${k.value}/reports/email`,
18488
- data: fe,
18494
+ data: ye,
18489
18495
  requestConfig: { timeout: 1e3 * 60 * 3 }
18490
18496
  });
18491
18497
  }, Dt = async (F) => {
@@ -18530,14 +18536,14 @@ function Pt(F, w, J) {
18530
18536
  if (Pe.randomUUID && !w && !F)
18531
18537
  return Pe.randomUUID();
18532
18538
  F = F || {};
18533
- const U = F.random || (F.rng || At)();
18534
- if (U[6] = U[6] & 15 | 64, U[8] = U[8] & 63 | 128, w) {
18539
+ const H = F.random || (F.rng || At)();
18540
+ if (H[6] = H[6] & 15 | 64, H[8] = H[8] & 63 | 128, w) {
18535
18541
  J = J || 0;
18536
- for (let N = 0; N < 16; ++N)
18537
- w[J + N] = U[N];
18542
+ for (let P = 0; P < 16; ++P)
18543
+ w[J + P] = H[P];
18538
18544
  return w;
18539
18545
  }
18540
- return Tt(U);
18546
+ return Tt(H);
18541
18547
  }
18542
18548
  export {
18543
18549
  ot as P,