@feedmepos/mf-report 5.33.0 → 5.33.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.
- package/dist/{App-UAlzwh8W.js → App-UhJDa13j.js} +4 -4
- package/dist/{DateRangeSelect-DGymHTm5.js → DateRangeSelect-B4-MgrD0.js} +1 -1
- package/dist/{Default.vue_vue_type_script_setup_true_lang-BAwuWy0R.js → Default.vue_vue_type_script_setup_true_lang-GGtPfxs3.js} +1 -1
- package/dist/{DigestListView-eoOXNOE9.js → DigestListView-BHz0b0o8.js} +3 -3
- package/dist/{DigestReaderView-CRQ0-vqh.js → DigestReaderView-j7SHeieI.js} +4 -4
- package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-rmTQHyLU.js → DynamicWidget.vue_vue_type_script_setup_true_lang-CSQxSBH6.js} +7 -7
- package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-Cy021Z5V.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-CsX4EOdl.js} +299 -295
- package/dist/{InsightView-CnAL5JFt.js → InsightView-BPaOKk4B.js} +5 -5
- package/dist/{Integration-Bb3VR2SI.js → Integration-Bm8wMPWD.js} +3 -3
- package/dist/{Integrations-BiUJVHDh.js → Integrations-CyLLU8W8.js} +2 -2
- package/dist/{Layout-DKpfLtDn.js → Layout-B0PqazFQ.js} +1 -1
- package/dist/{LocationSelect.vue_vue_type_script_setup_true_lang-bs8OthZm.js → LocationSelect.vue_vue_type_script_setup_true_lang-h1xIY9i5.js} +2 -2
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-DG6xjZEY.js → MenuTab.vue_vue_type_script_setup_true_lang-gm7J8atP.js} +5 -5
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-BjDehTWf.js → NavigationTab.vue_vue_type_script_setup_true_lang-SuWL1ncK.js} +5 -5
- package/dist/{OverviewView-BziKFl9t.js → OverviewView-qKzND69V.js} +5 -5
- package/dist/{Report-DlvT1bzh.js → Report-Ct4JeUQk.js} +3 -3
- package/dist/{ReportCanvasView-CMjmwsXO.js → ReportCanvasView-ClGwud-9.js} +5 -5
- package/dist/ReportEditor-B3tGyl-5.js +2117 -0
- package/dist/{ReportView-9qFfZYsM.js → ReportView-C-cmm-Fd.js} +6 -6
- package/dist/{ReportViewRoute-DdQof8f9.js → ReportViewRoute-DnNFoHOw.js} +2 -2
- package/dist/{Setting-CfRLIBY5.js → Setting-CASVb8Rm.js} +3 -3
- package/dist/{Template-J8TO_oZh.js → Template-BBUxUTFy.js} +3 -3
- package/dist/{TileEditor-DB53kEQW.js → TileEditor-De_F-7ds.js} +6 -6
- package/dist/{TilePageStack.vue_vue_type_script_setup_true_lang-BPh52iAb.js → TilePageStack.vue_vue_type_script_setup_true_lang-CdoiMoTQ.js} +2 -2
- package/dist/{TransitionFade-DwTnsmO6.js → TransitionFade-TTr9MyTn.js} +5 -5
- package/dist/{app-DJ8E_G1l.js → app-hV8LtdmM.js} +30 -14
- package/dist/app.js +1 -1
- package/dist/assets/{formatChartData.worker-o6kHvamD.js → formatChartData.worker-DvK7K5ca.js} +9 -9
- package/dist/assets/{processTableData.worker-B7UZDrcg.js → processTableData.worker-C3l4iUXL.js} +9 -9
- package/dist/{currency-6k8Wfqi_.js → currency-NkW-Vt9H.js} +1 -1
- package/dist/{index-DPXFXAit.js → index-DT7UhcKk.js} +231 -230
- package/dist/{report-DUMq52dp.js → report-Dxk_LHB_.js} +1 -1
- package/dist/{useDigestFont-BD2sKGUr.js → useDigestFont-lRnNGFKY.js} +1 -1
- package/dist/{useReportCanvasPanel-BQBD11bU.js → useReportCanvasPanel-DEo12E93.js} +3 -3
- package/dist/{useRestaurantPermission-CrSYU-Wn.js → useRestaurantPermission-B22jfD3v.js} +1 -1
- package/package.json +1 -1
- package/dist/ReportEditor-DZyU_Os7.js +0 -2094
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { al as br, ai as dr } from "./app-
|
|
1
|
+
import { al as br, ai as dr } from "./app-hV8LtdmM.js";
|
|
2
2
|
function bt(c) {
|
|
3
3
|
throw new Error('Could not dynamically require "' + c + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
4
4
|
}
|
|
@@ -33,9 +33,9 @@ var dt = {};
|
|
|
33
33
|
} catch (Y) {
|
|
34
34
|
var N = Y.stack, P = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), J = null;
|
|
35
35
|
do {
|
|
36
|
-
var
|
|
37
|
-
|
|
38
|
-
} while (
|
|
36
|
+
var X = P.exec(N);
|
|
37
|
+
X != null && (J = X);
|
|
38
|
+
} while (X != null);
|
|
39
39
|
return J[1];
|
|
40
40
|
}
|
|
41
41
|
}
|
|
@@ -90,7 +90,7 @@ var dt = {};
|
|
|
90
90
|
}
|
|
91
91
|
return !1;
|
|
92
92
|
}();
|
|
93
|
-
function
|
|
93
|
+
function X(r, e) {
|
|
94
94
|
if (r.prototype.constructor = r, r.prototype["$is" + r.name] = r, e != null) {
|
|
95
95
|
if (J) {
|
|
96
96
|
r.prototype.__proto__ = e.prototype;
|
|
@@ -102,7 +102,7 @@ var dt = {};
|
|
|
102
102
|
}
|
|
103
103
|
function Y(r, e) {
|
|
104
104
|
for (var n = 0; n < e.length; n++)
|
|
105
|
-
|
|
105
|
+
X(e[n], r);
|
|
106
106
|
}
|
|
107
107
|
function e0(r, e) {
|
|
108
108
|
P(e.prototype, r.prototype), r.prototype.constructor = r;
|
|
@@ -193,7 +193,7 @@ var dt = {};
|
|
|
193
193
|
}
|
|
194
194
|
F(r, e);
|
|
195
195
|
}
|
|
196
|
-
function
|
|
196
|
+
function q0(r) {
|
|
197
197
|
var e = L.leafTags;
|
|
198
198
|
if (!e) {
|
|
199
199
|
L.leafTags = r;
|
|
@@ -218,7 +218,7 @@ var dt = {};
|
|
|
218
218
|
return M0(l, p, n, a, i, [_], M, s);
|
|
219
219
|
};
|
|
220
220
|
};
|
|
221
|
-
return { inherit:
|
|
221
|
+
return { inherit: X, inheritMany: Y, mixin: e0, mixinHard: i0, installStaticTearOff: M0, installInstanceTearOff: n0, _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: V, lazy: o0, lazyFinal: U, lazyOld: p0, updateHolder: c0, convertToFastObject: _0, updateTypes: d0, setOrUpdateInterceptorsByTag: C0, setOrUpdateLeafTags: q0 };
|
|
222
222
|
}(), t = {
|
|
223
223
|
JS_CONST: function() {
|
|
224
224
|
},
|
|
@@ -265,8 +265,8 @@ var dt = {};
|
|
|
265
265
|
}
|
|
266
266
|
},
|
|
267
267
|
Sort__dualPivotQuicksort(r, e, n, a) {
|
|
268
|
-
var i, s, l, p, _, M, b, O, D, $, E = u.JSInt_methods._tdivFast$1(n - e + 1, 6), g = e + E, h = n - E, R = u.JSInt_methods._tdivFast$1(e + n, 2), C = R - E, W = R + E, B = o.getInterceptor$asx(r), I = B.$index(r, g), x = B.$index(r, C), w = B.$index(r, R), v = B.$index(r, W),
|
|
269
|
-
if (a.call$2(I, x) > 0 && (i = x, x = I, I = i), a.call$2(v,
|
|
268
|
+
var i, s, l, p, _, M, b, O, D, $, E = u.JSInt_methods._tdivFast$1(n - e + 1, 6), g = e + E, h = n - E, R = u.JSInt_methods._tdivFast$1(e + n, 2), C = R - E, W = R + E, B = o.getInterceptor$asx(r), I = B.$index(r, g), x = B.$index(r, C), w = B.$index(r, R), v = B.$index(r, W), H = B.$index(r, h);
|
|
269
|
+
if (a.call$2(I, x) > 0 && (i = x, x = I, I = i), a.call$2(v, H) > 0 && (i = H, H = v, v = i), a.call$2(I, w) > 0 && (i = w, w = I, I = i), a.call$2(x, w) > 0 && (i = w, w = x, x = i), a.call$2(I, v) > 0 && (i = v, v = I, I = i), a.call$2(w, v) > 0 && (i = v, v = w, w = i), a.call$2(x, H) > 0 && (i = H, H = x, x = i), a.call$2(x, w) > 0 && (i = w, w = x, x = i), a.call$2(v, H) > 0 && (i = H, H = v, v = i), B.$indexSet(r, g, I), B.$indexSet(r, R, w), B.$indexSet(r, h, H), B.$indexSet(r, C, B.$index(r, e)), B.$indexSet(r, W, B.$index(r, n)), s = e + 1, l = n - 1, o.$eq$(a.call$2(x, v), 0)) {
|
|
270
270
|
for (p = s; p <= l; ++p)
|
|
271
271
|
if (_ = B.$index(r, p), M = a.call$2(_, x), M !== 0)
|
|
272
272
|
if (M < 0)
|
|
@@ -1804,7 +1804,7 @@ var dt = {};
|
|
|
1804
1804
|
return _ === 12 ? e === d.JavaScriptFunction ? !0 : s ? !1 : t._isFunctionSubtype(r, e, n, a, i) : l === 9 ? _ !== 9 ? !1 : t._isInterfaceSubtype(r, e, n, a, i) : (s = l === 11, s && a === d.Record ? !0 : s && _ === 11 ? t._isRecordSubtype(r, e, n, a, i) : !1);
|
|
1805
1805
|
},
|
|
1806
1806
|
_isFunctionSubtype(r, e, n, a, i) {
|
|
1807
|
-
var s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
1807
|
+
var s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j;
|
|
1808
1808
|
if (!t._isSubtype(r, e._primary, n, a._primary, i) || (s = e._rest, l = a._rest, p = s._requiredPositional, _ = l._requiredPositional, M = p.length, b = _.length, M > b) || (O = b - M, D = s._optionalPositional, $ = l._optionalPositional, E = D.length, g = $.length, M + E < b + g))
|
|
1809
1809
|
return !1;
|
|
1810
1810
|
for (h = 0; h < M; ++h)
|
|
@@ -1818,9 +1818,9 @@ var dt = {};
|
|
|
1818
1818
|
return !1;
|
|
1819
1819
|
for (C = s._named, W = l._named, B = C.length, I = W.length, x = 0, w = 0; w < I; w += 3)
|
|
1820
1820
|
for (v = W[w]; ; ) {
|
|
1821
|
-
if (x >= B || (
|
|
1821
|
+
if (x >= B || (H = C[x], x += 3, v < H))
|
|
1822
1822
|
return !1;
|
|
1823
|
-
if (j = C[x - 2],
|
|
1823
|
+
if (j = C[x - 2], H < v) {
|
|
1824
1824
|
if (j)
|
|
1825
1825
|
return !1;
|
|
1826
1826
|
continue;
|
|
@@ -2979,16 +2979,16 @@ select
|
|
|
2979
2979
|
Index$(r, e, n, a) {
|
|
2980
2980
|
return new t.Index(r, e, a, n);
|
|
2981
2981
|
},
|
|
2982
|
-
Schema$(r, e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
2983
|
-
return new t.Schema(w, W, p, C, I0, y0, h, R, $, g, O, j, s0,
|
|
2982
|
+
Schema$(r, e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0, u0, z0, y0, h0, $0, I0) {
|
|
2983
|
+
return new t.Schema(w, W, p, C, I0, y0, h, R, $, g, O, j, s0, H, $0, I, B, v, z0, s, b, _, D, n, e, a, x, l, i, M, h0, r, E, u0);
|
|
2984
2984
|
},
|
|
2985
|
-
Schema_Schema$build(r, e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
2985
|
+
Schema_Schema$build(r, e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0, u0, z0, y0, h0, $0, I0) {
|
|
2986
2986
|
var W0 = p.call$1(w), Z = C.call$1(w);
|
|
2987
|
-
return t.Schema$(r, e, n, a, i, s, l, W0, _, M, b, O ?? 300, D, $, E, g, h, R, Z, W, B, I, x, w, v,
|
|
2987
|
+
return t.Schema$(r, e, n, a, i, s, l, W0, _, M, b, O ?? 300, D, $, E, g, h, R, Z, W, B, I, x, w, v, H, j, s0, u0, z0, y0, h0, $0, I0);
|
|
2988
2988
|
},
|
|
2989
2989
|
Schema_fromJson(r) {
|
|
2990
|
-
var e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
2991
|
-
return O1 = O1 == null ? u0 : o.cast$1$0$ax(O1, d.String), e = S0.$index(0, "timeColumn"), S0 = B0._as(S0.$index(0, "dateColumns")), S0 = S0 == null ? u0 : o.cast$1$0$ax(S0, d.String), n = r.$index(0, "rawTableName"), a = r.$index(0, "rawTopicName"), i = r.$index(0, "postgresqlDynamicRawTable"), s = r.$index(0, "sqliteDynamicRawTable"), l = r.$index(0, "materializedTableName"), p = r.$index(0, "materializedPostgresqlTableName"), _ = r.$index(0, "isJoinOnly"), M = r.$index(0, "isMaterializeOnly"), b = r.$index(0, "isContinuousUpdate"), O = r.$index(0, "interval"), D = r.$index(0, "partition"), $ = r.$index(0, "requirePartitionFilter"), $ == null && ($ = !0), E = B0._as(r.$index(0, "clusters")), E = E == null ? u0 : o.cast$1$0$ax(E, d.String), E == null && (E = t._setArrayType([], d.JSArray_String)), g = B0._as(r.$index(0, "indexes")), g = g == null ? u0 : o.map$1$1$ax(g, new t.Schema_fromJson_closure1(), d.Index).toList$0(0), g == null && (g = t._setArrayType([], d.JSArray_Index)), h = B0._as(r.$index(0, "filters")), h = h == null ? u0 : o.map$1$1$ax(h, new t.Schema_fromJson_closure2(), d.QueryRequestFilter).toList$0(0), h == null && (h = t._setArrayType([], d.JSArray_QueryRequestFilter)), R = r.$index(0, "isGlobal"), R == null && (R = !1), C = r.$index(0, "isAiHidden"), C == null && (C = !1), B0 = B0._as(r.$index(0, "aiKeywords")), B0 = B0 == null ? u0 : o.cast$1$0$ax(B0, d.String), B0 == null && (B0 = t._setArrayType([], d.JSArray_String)), W = r.$index(0, "aiCategory"), B = r.$index(0, "aiPriority"), B == null && (B = 3), I = r.$index(0, "mergeFilterType"), I = t.EnumByName_byName(u.List_EfK, I ?? "dates"), x = r.$index(0, "description"), w = r.$index(0, z0) == null ? u0 : t.Canonical_fromJson(r.$index(0, z0)), r.$index(0, y0) == null ? v = u0 : (v = r.$index(0, y0), v = new t.Hierarchy(t._asString(v.$index(0, "depth")), o.toString$0$(v.$index(0, "root")), t._asStringQ(v.$index(0, "parent")), t._asStringQ(v.$index(0, "rootKey")))),
|
|
2990
|
+
var e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0, u0 = null, z0 = "canonical", y0 = "hierarchy", h0 = "readPiece", $0 = d.List_dynamic, I0 = o.map$1$1$ax($0._as(r.$index(0, "fields")), new t.Schema_fromJson_closure(), d.Field).toList$0(0), W0 = r.$index(0, "label"), Z = t.EnumByName_byName(u.List_8aB, r.$index(0, "name")), H0 = o.map$1$1$ax($0._as(r.$index(0, "joins")), new t.Schema_fromJson_closure0(), d.Join).toList$0(0), v0 = t.TopLevelFilters_fromJson(r.$index(0, "topLevelFilters")), S0 = r.$index(0, "source"), H1 = t.EnumByName_byName(u.List_ytA, S0.$index(0, "type")), X1 = S0.$index(0, "table"), k1 = S0.$index(0, "field"), U1 = S0.$index(0, "dataset"), B0 = d.nullable_List_dynamic, O1 = B0._as(S0.$index(0, "uniqueKey"));
|
|
2991
|
+
return O1 = O1 == null ? u0 : o.cast$1$0$ax(O1, d.String), e = S0.$index(0, "timeColumn"), S0 = B0._as(S0.$index(0, "dateColumns")), S0 = S0 == null ? u0 : o.cast$1$0$ax(S0, d.String), n = r.$index(0, "rawTableName"), a = r.$index(0, "rawTopicName"), i = r.$index(0, "postgresqlDynamicRawTable"), s = r.$index(0, "sqliteDynamicRawTable"), l = r.$index(0, "materializedTableName"), p = r.$index(0, "materializedPostgresqlTableName"), _ = r.$index(0, "isJoinOnly"), M = r.$index(0, "isMaterializeOnly"), b = r.$index(0, "isContinuousUpdate"), O = r.$index(0, "interval"), D = r.$index(0, "partition"), $ = r.$index(0, "requirePartitionFilter"), $ == null && ($ = !0), E = B0._as(r.$index(0, "clusters")), E = E == null ? u0 : o.cast$1$0$ax(E, d.String), E == null && (E = t._setArrayType([], d.JSArray_String)), g = B0._as(r.$index(0, "indexes")), g = g == null ? u0 : o.map$1$1$ax(g, new t.Schema_fromJson_closure1(), d.Index).toList$0(0), g == null && (g = t._setArrayType([], d.JSArray_Index)), h = B0._as(r.$index(0, "filters")), h = h == null ? u0 : o.map$1$1$ax(h, new t.Schema_fromJson_closure2(), d.QueryRequestFilter).toList$0(0), h == null && (h = t._setArrayType([], d.JSArray_QueryRequestFilter)), R = r.$index(0, "isGlobal"), R == null && (R = !1), C = r.$index(0, "isAiHidden"), C == null && (C = !1), B0 = B0._as(r.$index(0, "aiKeywords")), B0 = B0 == null ? u0 : o.cast$1$0$ax(B0, d.String), B0 == null && (B0 = t._setArrayType([], d.JSArray_String)), W = r.$index(0, "aiCategory"), B = r.$index(0, "aiPriority"), B == null && (B = 3), I = r.$index(0, "mergeFilterType"), I = t.EnumByName_byName(u.List_EfK, I ?? "dates"), x = r.$index(0, "description"), w = r.$index(0, z0) == null ? u0 : t.Canonical_fromJson(r.$index(0, z0)), r.$index(0, y0) == null ? v = u0 : (v = r.$index(0, y0), v = new t.Hierarchy(t._asString(v.$index(0, "depth")), o.toString$0$(v.$index(0, "root")), t._asStringQ(v.$index(0, "parent")), t._asStringQ(v.$index(0, "rootKey")))), $0 = r.$index(0, "splits") == null ? u.List_empty1 : o.map$1$1$ax($0._as(r.$index(0, "splits")), new t.Schema_fromJson_closure3(), d.Split).toList$0(0), H = r.$index(0, "activityAnchor"), H == null && (H = !1), j = r.$index(0, "isDeprecated"), j == null && (j = !1), r.$index(0, h0) == null ? s0 = u0 : (s0 = r.$index(0, h0), s0 = new t.ReadPiece(t._asInt(s0.$index(0, "outlets")), t._asInt(s0.$index(0, "days")))), t.Schema$(H, W, B0, B, w, E, x, I0, h, v, g, O, C, b, j, R, _, M, H0, W0, p, l, I, Z, D, i, n, a, s0, $, new t.Source(H1, X1, k1, U1, O1, e, S0), $0, s, v0);
|
|
2992
2992
|
},
|
|
2993
2993
|
Field_Field$numeric(r, e, n, a, i, s, l, p, _, M, b) {
|
|
2994
2994
|
return new t._NumericField(l, p, u.DATA_TYPE_3, e, s, _, n, b, i, !1, r, M, a);
|
|
@@ -3135,9 +3135,9 @@ select
|
|
|
3135
3135
|
var s = this;
|
|
3136
3136
|
s.column = e, s.customName = n, s.indexMethod = a, s.include = i;
|
|
3137
3137
|
},
|
|
3138
|
-
Schema: function(e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
3138
|
+
Schema: function(e, n, a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0, u0, z0, y0, h0, $0, I0, W0) {
|
|
3139
3139
|
var Z = this;
|
|
3140
|
-
Z.name = e, Z.label = n, Z.fields = a, Z.joins = i, Z.topLevelFilters = s, Z.source = l, Z.isJoinOnly = p, Z.isMaterializeOnly = _, Z.isContinuousUpdate = M, Z.isGlobal = b, Z.interval = O, Z.rawTableName = D, Z.rawTopicName = $, Z.postgresqlDynamicRawTable = E, Z.sqliteDynamicRawTable = g, Z.materializedTableName = h, Z.materializedPostgresqlTableName = R, Z.partition = C, Z.requirePartitionFilter = W, Z.clusters = B, Z.indexes = I, Z._materializeTablePrefix = Z._rawTablePrefix = "", Z.filters = x, Z.isAiHidden = w, Z.aiKeywords = v, Z.aiCategory =
|
|
3140
|
+
Z.name = e, Z.label = n, Z.fields = a, Z.joins = i, Z.topLevelFilters = s, Z.source = l, Z.isJoinOnly = p, Z.isMaterializeOnly = _, Z.isContinuousUpdate = M, Z.isGlobal = b, Z.interval = O, Z.rawTableName = D, Z.rawTopicName = $, Z.postgresqlDynamicRawTable = E, Z.sqliteDynamicRawTable = g, Z.materializedTableName = h, Z.materializedPostgresqlTableName = R, Z.partition = C, Z.requirePartitionFilter = W, Z.clusters = B, Z.indexes = I, Z._materializeTablePrefix = Z._rawTablePrefix = "", Z.filters = x, Z.isAiHidden = w, Z.aiKeywords = v, Z.aiCategory = H, Z.aiPriority = j, Z.mergeFilterType = s0, Z.description = u0, Z.canonical = z0, Z.hierarchy = y0, Z.splits = h0, Z.activityAnchor = $0, Z.isDeprecated = I0, Z.readPiece = W0;
|
|
3141
3141
|
},
|
|
3142
3142
|
Schema_visualizationSchema_closure: function() {
|
|
3143
3143
|
},
|
|
@@ -9076,8 +9076,8 @@ Arguments: [` + _ + "]";
|
|
|
9076
9076
|
$signature: 1
|
|
9077
9077
|
}, t.billSchema_closure.prototype = {
|
|
9078
9078
|
call$1(r) {
|
|
9079
|
-
var e = null, n = "seqNumber", a = "deliveryName", i = "isRefund", s = "isPickup", l = "isInHouseDelivery", p = "isDelivery", _ = "completedAt", M = "integratedOrderId", b = "itemCount", O = "taxTotal", D = "discountTotal", $ = "grossTotal", E = "rounding", g = "takeawayPrice", h = "thirdPartyExtraCharge", R = "deliveryFee", C = "nettTotal", W = "deliveryFeeWithTax", B = "deliveryFeeWithoutTax", I = "otherChargeWithTax", x = "otherChargeWithoutTax", w = "discountInclusiveTaxTotal", v = "customerName",
|
|
9080
|
-
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, u.FIELD_ROLE_5, r), t.Field_Field$string("Values: COMPLETED (a sale, or a refund bill: see is_refund), REFUNDED (a sale later refunded in full; the refund is a separate COMPLETED bill), VOIDED (cancelled: not a sale, its figures 0), DRAFT (still open: not a sale).", e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "No.", n, n, e, e, r), t.Field_Field$string("Dine-in table name/identifier", e, !1, e, !1, !1, "Table", "slot", "slot", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Delivery", a, a, e, e, r), t.Field_Field$string("On a refund bill, the id of the bill it refunds.", e, !1, e, !1, !1, "Refund ID", "refundFrom", "refundedFrom", e, e, r), t.Field_Field$bool("A refund bill: a row of its own with status COMPLETED, its figures negated, refund_from naming the bill it refunds. A full refund also turns that bill REFUNDED; a partial one leaves it COMPLETED.", e, !1, e, !1, "Refund", i, i, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundApprovedById", "refund.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund approver", "refundApprovedByName", "refund.approvedBy.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundedById", "refund.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund user", "refundedByName", "refund.by.name", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", "refundReason", "refund.reason", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member ID", "memberId", "membership.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member user ID", "memberUserId", "membership.userId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member name", "memberUserName", "membership.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Member phone", "memberPhoneNumber", "membership.phoneNumber", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Member birthday", "memberBirthday", "membership.birthday", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string("Sales channel. FEEDME is FeedMe's own POS and online ordering (raw ''/POS normalize to it) and is never a delivery platform; a third-party delivery platform passes through under its own name and shows in the sampled values only when the business uses one — no such value sampled means no delivery-platform rows.", e, !1, e, !1, !1, "Source", "source", "source", T.x28case_x28, e, r), t.Field_Field$string("Order type. PICKUP/DELIVERY/DRIVE THRU/KIOSK/TAKEAWAY are normalized; any other POS-configured value passes through raw — filter with the sampled values, never a guessed label. COUNTER is a dine-in order taken at the counter: a 'Dine-in' choice maps to it.", e, !1, e, !1, !1, "Type", "type", "type", "(case when upper(@type) in ('PICKUP','DELIVERY','DRIVE THRU','KIOSK') then upper(@type) when @is_takeaway is true then 'TAKEAWAY' else upper(@type) end)", e, r), t.Field_Field$bool(e, e, !0, e, !1, "Pickup", s, s, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is in house delivery", l, l, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is other delivery", p, p, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is takeaway", "isTakeaway", "is.takeaway", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Closed at", _, _, e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SST", "sstInclusive", "nettTaxes.SST.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST before discount", "sstBeforeDiscount", "nettTaxes.SST.beforeDiscount", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SC", "serviceChargeInclusive", "nettTaxes.SERVICE_CHARGE.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC before discount", "serviceChargeBeforeDiscount", "nettTaxes.SERVICE_CHARGE.beforeDiscount", e, e, r), t.Field_Field$numeric("Number of guests. Negated for refund, 0 for voided", "IF(@status = 'VOIDED', 0, IFNULL(@pax,0)*IF(@isRefund, -1, 1))", !1, e, !1, "Pax", "pax", "person", "(CASE WHEN @status = 'VOIDED' THEN 0 ELSE (COALESCE(@pax,0)*CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Integrated order ID", M, M, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric(e, T.IFNULLi, !0, e, !1, "Item count", b, b, T.COALESi, e, r), t.Field_Field$numeric(e, T.IFNULLtax, !1, e, !1, "Tax", O, O, T.COALEStax_, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Discount given on the bill, refund sign applied — the discount measure. adjustment is a different grain: it holds a row per discount, bill-level (target = 'BILL') and item-level alike, so summing those per bill counts a bill's discount twice.", T.IFNULLdiT, !1, e, !1, "Discount", D, D, T.COALESdit, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLg, !1, e, !1, "Item gross", $, $, T.COALESg, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-IFNULL(@discountTotal,0)-IFNULL(@thirdPartyExtraCharge,0)-IFNULL(@deliveryFee,0)-IFNULL(@taxTotal,IFNULL(@sstTotal, 0))-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross", "billGrossTotal", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-COALESCE(@discount_total,0)-COALESCE(@third_party_extra_charge,0)-COALESCE(@delivery_fee,0)-COALESCE(@tax_total,@sst_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@rounding,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Rounding", E, E, T.COALESr, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@sstTotal,0)*IF(@isRefund, -1, 1)", !0, e, !1, "SST", "sstTotal", "nettTaxes.SST.total", T.COALESss, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST %", "sstPercentage", "nettTaxes.SST.percentage", e, e, r), t.Field_Field$numeric(e, T.IFNULLse, !1, e, !1, "SC", "serviceChargeTotal", "nettTaxes.SERVICE_CHARGE.total", T.COALESse, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC %", "serviceChargePercentage", "nettTaxes.SERVICE_CHARGE.percentage", e, e, r), t.Field_Field$numeric(e, T.x28IFNULo, !1, e, !1, "Other charge", "otherChargeTotal", "nettTaxes.OTHER_CHARGE.total", T.x28COALEo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2d, !1, e, !1, "Gross w/ takeaway", "subTotalWithoutTakeaway", e, T.x28COALEgx2d, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtak, !1, e, !1, "Takeaway", g, g, T.COALEStak, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLth, !1, e, !1, "Extra charge", h, h, T.COALESth, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLde_, !1, e, !1, "Delivery fee", R, R, T.COALESdex2c, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Revenue after discounts and before taxes — the default sales measure.", T.IFNULLn, !1, e, !1, "Nett", C, C, T.COALESn, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@grossTotal,0)+(case when @deliveryFeeWithTax>0 then IFNULL(@deliveryFee,0) else 0 end)+IFNULL(case when @otherChargeWithTax>0 then IFNULL(@thirdPartyExtraCharge,0) else 0 end)+IFNULL(@discountTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Item gross before charges", "grossBeforeCharges", e, "(COALESCE(@gross_total,0)+(case when @delivery_fee_with_tax>0 then COALESCE(@delivery_fee,0) else 0 end)+(case when @other_charge_with_tax>0 then COALESCE(@third_party_extra_charge,0) else 0 end)+COALESCE(@discount_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-(case when @otherChargeWithTax>0 then 0 else IFNULL(@thirdPartyExtraCharge,0) end)-(case when @deliveryFeeWithTax>0 then 0 else IFNULL(@deliveryFee,0) end)-IFNULL(@taxTotal,IFNULL(@sstTotal,0))-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross before charges", "billGrossBeforeCharges", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-(case when @other_charge_with_tax>0 then 0 else COALESCE(@third_party_extra_charge,0) end)-(case when @delivery_fee_with_tax>0 then 0 else COALESCE(@delivery_fee,0) end)-COALESCE(@tax_total,@sst_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member Recency", "recency", e, T.MIN_EX, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member frequency", "frequency", e, T.COUNT_, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member monetary", "monetary", e, T.SUM__n, e, r), t.Field_Field$numeric(e, T.IFNULLdeWT, !1, e, !1, "Delivery fee with tax", W, W, T.COALESdex5f_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdeWo, !1, e, !1, "Delivery fee without tax", B, B, T.COALESdex5fo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoT, !1, e, !1, "Other charge with tax", I, I, T.COALESo_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoo, !1, e, !1, "Other charge without tax", x, x, T.COALESoo, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Bill duration in seconds from creation to completion", e, !1, e, !1, "Duration", "duration", e, T.EXTRAC, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant", "restaurantName", e, T.x28selecn, u.FIELD_ROLE_4, r), t.Field_Field$numeric(e, e, !1, e, !1, "Labour hour", "labourHour", e, T.x28selecS, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payments", "payments", e, T.x28selecstn, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Items", "items", e, "(select string_agg(CONCAT(flatten_items.quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN flatten_items.code='' THEN NULL ELSE flatten_items.code END, flatten_items.name], ' ')), ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0 and flatten_items.status!='VOIDED')", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Discount reasons", "discountReasons", e, T.x28selecsta, e, r), t.Field_Field$numeric(e, T.IFNULLdiI, !1, e, !1, "Discount inc tax", w, w, T.COALESdii, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment Summaries", "paymentSummaries", e, "(select string_agg(distinct CONCAT(name, CASE WHEN card_type is not null THEN CONCAT(' (',UPPER(card_type), ')') WHEN payment_gateway_issuer is not null THEN CONCAT(' (',payment_gateway_issuer, ')') ELSE '' END), ',') from payments where payments.bill_id=@id and payments.restaurant_id=@restaurant_id)", e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is new member", "isNewMember", e, "(CASE WHEN EXISTS (SELECT 1 FROM members WHERE members.id=@member_id AND members.created_at::date = @created_at::date) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is 30 days recency", "is30DaysRecency", e, "(CASE WHEN EXISTS (SELECT 1 FROM bills WHERE bills.member_id = @member_id AND bills.status != 'VOIDED' AND bills.restaurant_id = @restaurant_id AND bills.created_at >= @created_at - INTERVAL '30 days' AND bills.created_at < @created_at) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is 60 days recency", "is60DaysRecency", e, "(CASE WHEN EXISTS (SELECT 1 FROM bills WHERE bills.member_id = @member_id AND bills.status != 'VOIDED' AND bills.restaurant_id = @restaurant_id AND bills.created_at >= @created_at - INTERVAL '60 days' AND bills.created_at < @created_at) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Bill count flag: 1 normal, -1 refund, 0 voided. Its SUM over the sold bills (COMPLETED and REFUNDED) is the net count, in which a refund cancels its sale. FeedMe's standard reports (Close up, Summary) count rows instead, over every bill that is not DRAFT or VOIDED, so a refunded sale and its refund count as two.", "IF(@status = 'VOIDED', 0, IF(@isRefund, -1, 1))", !1, e, !1, "Table count", "tableCount", e, "(CASE WHEN @status = 'VOIDED' THEN 0 ELSE (CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Member count flag: 1 normal, -1 refund, 0 voided. Use SUM to count members", "IF((@status = 'VOIDED' OR @memberId is null), 0, IF(@isRefund, -1, 1))", !1, e, !1, "Member count", "memberCount", e, "(CASE WHEN (@status = 'VOIDED' OR @member_id is null) THEN 0 ELSE (CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$string("Customer name from pickup / in-house delivery / delivery channel", e, !1, e, !1, !1, "Customer", v, v, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer phone", X, X, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer address", j, j, e, e, r), t.Field_Field$string("Remark on the pickup / delivery order", e, !1, e, !1, !1, "Customer remark", s0, s0, e, e, r), t.Field_Field$timestamp("Scheduled pickup / delivery time", e, !1, e, !1, "Fulfillment time", u0, u0, e, u.FIELD_ROLE_0, r), t.Field_Field$string("Pax count by type (e.g. ADULTS, CHILDREN)", e, !1, e, !1, !1, "Pax breakdown", "paxBreakdown", "personMetaBreakdown", e, e, r), t.Field_Field$numeric("Refund rows only: original bill nett less every earlier refund of it. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Nett balance before refund", "refundNettBalanceBefore", e, "(CASE WHEN @refund_from IS NULL THEN NULL ELSE (SELECT COALESCE(ob.nett_total,0) FROM bills ob WHERE ob.id=@refund_from AND ob.restaurant_id=@restaurant_id)-COALESCE((SELECT SUM(COALESCE(pr.nett_total,0)) FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: nett balance before refund less this refund nett. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Nett balance after refund", "refundNettBalanceAfter", e, "(CASE WHEN @refund_from IS NULL THEN NULL ELSE (SELECT COALESCE(ob.nett_total,0) FROM bills ob WHERE ob.id=@refund_from AND ob.restaurant_id=@restaurant_id)-COALESCE((SELECT SUM(COALESCE(pr.nett_total,0)) FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0)-CASE WHEN @status='VOIDED' THEN 0 ELSE COALESCE(@nett_total,0) END END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: original bill gross less every earlier refund of it. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Gross balance before refund", "refundGrossBalanceBefore", e, z0 + t._billGross("ob.") + y0 + t._billGross("pr.") + ") FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: gross balance before refund less this refund gross. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Gross balance after refund", "refundGrossBalanceAfter", e, z0 + t._billGross("ob.") + y0 + t._billGross("pr.") + ") FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0)-CASE WHEN @status='VOIDED' THEN 0 ELSE " + t._billGross("@") + " END END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(T.BCRS_c, T.IFNULLst, !1, e, !1, "Statutory charges", g0, g0, T.COALESst, u.FIELD_ROLE_1, r), t.Field_Field$string("Comma-joined distinct categories of the bill top-level, non-voided item lines (add-ons excluded), named as item Category is (Other for open items). A text list: filter with LIKE / NOT LIKE, not equality", e, !1, e, !1, !1, "Categories", "categories", e, "(select string_agg(distinct CASE WHEN flatten_items.category_name IS NULL OR flatten_items.product_id IS NULL OR flatten_items.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 flatten_items.category_name END, ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0 and flatten_items.status!='VOIDED')", e, r)], d.JSArray_Field);
|
|
9079
|
+
var e = null, n = "seqNumber", a = "deliveryName", i = "isRefund", s = "isPickup", l = "isInHouseDelivery", p = "isDelivery", _ = "completedAt", M = "integratedOrderId", b = "itemCount", O = "taxTotal", D = "discountTotal", $ = "grossTotal", E = "rounding", g = "takeawayPrice", h = "thirdPartyExtraCharge", R = "deliveryFee", C = "nettTotal", W = "deliveryFeeWithTax", B = "deliveryFeeWithoutTax", I = "otherChargeWithTax", x = "otherChargeWithoutTax", w = "discountInclusiveTaxTotal", v = "customerName", H = "customerPhone", j = "customerAddress", s0 = "customerRemark", u0 = "fulfillmentAt", z0 = "(CASE WHEN @refund_from IS NULL THEN NULL ELSE (SELECT ", y0 = " FROM bills ob WHERE ob.id=@refund_from AND ob.restaurant_id=@restaurant_id)-COALESCE((SELECT SUM(", h0 = "statutoryChargeTotal", $0 = "foodCourtOrderId";
|
|
9080
|
+
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, u.FIELD_ROLE_5, r), t.Field_Field$string("Values: COMPLETED (a sale, or a refund bill: see is_refund), REFUNDED (a sale later refunded in full; the refund is a separate COMPLETED bill), VOIDED (cancelled: not a sale, its figures 0), DRAFT (still open: not a sale).", e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "No.", n, n, e, e, r), t.Field_Field$string("Dine-in table name/identifier", e, !1, e, !1, !1, "Table", "slot", "slot", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Delivery", a, a, e, e, r), t.Field_Field$string("On a refund bill, the id of the bill it refunds.", e, !1, e, !1, !1, "Refund ID", "refundFrom", "refundedFrom", e, e, r), t.Field_Field$bool("A refund bill: a row of its own with status COMPLETED, its figures negated, refund_from naming the bill it refunds. A full refund also turns that bill REFUNDED; a partial one leaves it COMPLETED.", e, !1, e, !1, "Refund", i, i, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundApprovedById", "refund.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund approver", "refundApprovedByName", "refund.approvedBy.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundedById", "refund.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund user", "refundedByName", "refund.by.name", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", "refundReason", "refund.reason", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member ID", "memberId", "membership.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member user ID", "memberUserId", "membership.userId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member name", "memberUserName", "membership.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Member phone", "memberPhoneNumber", "membership.phoneNumber", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Member birthday", "memberBirthday", "membership.birthday", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string("Sales channel. FEEDME is FeedMe's own POS and online ordering (raw ''/POS normalize to it) and is never a delivery platform; FOOD_COURT is a stall's part of a food court order, paid to the food court, which owes the stall; a third-party delivery platform passes through under its own name and shows in the sampled values only when the business uses one — no such value sampled means no delivery-platform rows.", e, !1, e, !1, !1, "Source", "source", "source", T.x28case_x28, e, r), t.Field_Field$string("Order type. PICKUP/DELIVERY/DRIVE THRU/KIOSK/TAKEAWAY are normalized; any other POS-configured value passes through raw — filter with the sampled values, never a guessed label. COUNTER is a dine-in order taken at the counter: a 'Dine-in' choice maps to it.", e, !1, e, !1, !1, "Type", "type", "type", "(case when upper(@type) in ('PICKUP','DELIVERY','DRIVE THRU','KIOSK') then upper(@type) when @is_takeaway is true then 'TAKEAWAY' else upper(@type) end)", e, r), t.Field_Field$bool(e, e, !0, e, !1, "Pickup", s, s, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is in house delivery", l, l, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is other delivery", p, p, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is takeaway", "isTakeaway", "is.takeaway", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Closed at", _, _, e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SST", "sstInclusive", "nettTaxes.SST.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST before discount", "sstBeforeDiscount", "nettTaxes.SST.beforeDiscount", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SC", "serviceChargeInclusive", "nettTaxes.SERVICE_CHARGE.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC before discount", "serviceChargeBeforeDiscount", "nettTaxes.SERVICE_CHARGE.beforeDiscount", e, e, r), t.Field_Field$numeric("Number of guests. Negated for refund, 0 for voided", "IF(@status = 'VOIDED', 0, IFNULL(@pax,0)*IF(@isRefund, -1, 1))", !1, e, !1, "Pax", "pax", "person", "(CASE WHEN @status = 'VOIDED' THEN 0 ELSE (COALESCE(@pax,0)*CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Integrated order ID", M, M, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric(e, T.IFNULLi, !0, e, !1, "Item count", b, b, T.COALESi, e, r), t.Field_Field$numeric(e, T.IFNULLtax, !1, e, !1, "Tax", O, O, T.COALEStax_, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Discount given on the bill, refund sign applied — the discount measure. adjustment is a different grain: it holds a row per discount, bill-level (target = 'BILL') and item-level alike, so summing those per bill counts a bill's discount twice.", T.IFNULLdiT, !1, e, !1, "Discount", D, D, T.COALESdit, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLg, !1, e, !1, "Item gross", $, $, T.COALESg, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-IFNULL(@discountTotal,0)-IFNULL(@thirdPartyExtraCharge,0)-IFNULL(@deliveryFee,0)-IFNULL(@taxTotal,IFNULL(@sstTotal, 0))-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross", "billGrossTotal", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-COALESCE(@discount_total,0)-COALESCE(@third_party_extra_charge,0)-COALESCE(@delivery_fee,0)-COALESCE(@tax_total,@sst_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@rounding,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Rounding", E, E, T.COALESr, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@sstTotal,0)*IF(@isRefund, -1, 1)", !0, e, !1, "SST", "sstTotal", "nettTaxes.SST.total", T.COALESss, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST %", "sstPercentage", "nettTaxes.SST.percentage", e, e, r), t.Field_Field$numeric(e, T.IFNULLse, !1, e, !1, "SC", "serviceChargeTotal", "nettTaxes.SERVICE_CHARGE.total", T.COALESse, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC %", "serviceChargePercentage", "nettTaxes.SERVICE_CHARGE.percentage", e, e, r), t.Field_Field$numeric(e, T.x28IFNULo, !1, e, !1, "Other charge", "otherChargeTotal", "nettTaxes.OTHER_CHARGE.total", T.x28COALEo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2d, !1, e, !1, "Gross w/ takeaway", "subTotalWithoutTakeaway", e, T.x28COALEgx2d, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtak, !1, e, !1, "Takeaway", g, g, T.COALEStak, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLth, !1, e, !1, "Extra charge", h, h, T.COALESth, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLde_, !1, e, !1, "Delivery fee", R, R, T.COALESdex2c, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Revenue after discounts and before taxes — the default sales measure.", T.IFNULLn, !1, e, !1, "Nett", C, C, T.COALESn, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@grossTotal,0)+(case when @deliveryFeeWithTax>0 then IFNULL(@deliveryFee,0) else 0 end)+IFNULL(case when @otherChargeWithTax>0 then IFNULL(@thirdPartyExtraCharge,0) else 0 end)+IFNULL(@discountTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Item gross before charges", "grossBeforeCharges", e, "(COALESCE(@gross_total,0)+(case when @delivery_fee_with_tax>0 then COALESCE(@delivery_fee,0) else 0 end)+(case when @other_charge_with_tax>0 then COALESCE(@third_party_extra_charge,0) else 0 end)+COALESCE(@discount_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-(case when @otherChargeWithTax>0 then 0 else IFNULL(@thirdPartyExtraCharge,0) end)-(case when @deliveryFeeWithTax>0 then 0 else IFNULL(@deliveryFee,0) end)-IFNULL(@taxTotal,IFNULL(@sstTotal,0))-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross before charges", "billGrossBeforeCharges", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-(case when @other_charge_with_tax>0 then 0 else COALESCE(@third_party_extra_charge,0) end)-(case when @delivery_fee_with_tax>0 then 0 else COALESCE(@delivery_fee,0) end)-COALESCE(@tax_total,@sst_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member Recency", "recency", e, T.MIN_EX, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member frequency", "frequency", e, T.COUNT_, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member monetary", "monetary", e, T.SUM__n, e, r), t.Field_Field$numeric(e, T.IFNULLdeWT, !1, e, !1, "Delivery fee with tax", W, W, T.COALESdex5f_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdeWo, !1, e, !1, "Delivery fee without tax", B, B, T.COALESdex5fo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoT, !1, e, !1, "Other charge with tax", I, I, T.COALESo_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoo, !1, e, !1, "Other charge without tax", x, x, T.COALESoo, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Bill duration in seconds from creation to completion", e, !1, e, !1, "Duration", "duration", e, T.EXTRAC, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant", "restaurantName", e, T.x28selecn, u.FIELD_ROLE_4, r), t.Field_Field$numeric(e, e, !1, e, !1, "Labour hour", "labourHour", e, T.x28selecS, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payments", "payments", e, T.x28selecstn, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Items", "items", e, "(select string_agg(CONCAT(flatten_items.quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN flatten_items.code='' THEN NULL ELSE flatten_items.code END, flatten_items.name], ' ')), ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0 and flatten_items.status!='VOIDED')", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Discount reasons", "discountReasons", e, T.x28selecsta, e, r), t.Field_Field$numeric(e, T.IFNULLdiI, !1, e, !1, "Discount inc tax", w, w, T.COALESdii, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment Summaries", "paymentSummaries", e, "(select string_agg(distinct CONCAT(name, CASE WHEN card_type is not null THEN CONCAT(' (',UPPER(card_type), ')') WHEN payment_gateway_issuer is not null THEN CONCAT(' (',payment_gateway_issuer, ')') ELSE '' END), ',') from payments where payments.bill_id=@id and payments.restaurant_id=@restaurant_id)", e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is new member", "isNewMember", e, "(CASE WHEN EXISTS (SELECT 1 FROM members WHERE members.id=@member_id AND members.created_at::date = @created_at::date) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is 30 days recency", "is30DaysRecency", e, "(CASE WHEN EXISTS (SELECT 1 FROM bills WHERE bills.member_id = @member_id AND bills.status != 'VOIDED' AND bills.restaurant_id = @restaurant_id AND bills.created_at >= @created_at - INTERVAL '30 days' AND bills.created_at < @created_at) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Is 60 days recency", "is60DaysRecency", e, "(CASE WHEN EXISTS (SELECT 1 FROM bills WHERE bills.member_id = @member_id AND bills.status != 'VOIDED' AND bills.restaurant_id = @restaurant_id AND bills.created_at >= @created_at - INTERVAL '60 days' AND bills.created_at < @created_at) THEN 1 ELSE 0 END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Bill count flag: 1 normal, -1 refund, 0 voided. Its SUM over the sold bills (COMPLETED and REFUNDED) is the net count, in which a refund cancels its sale. FeedMe's standard reports (Close up, Summary) count rows instead, over every bill that is not DRAFT or VOIDED, so a refunded sale and its refund count as two.", "IF(@status = 'VOIDED', 0, IF(@isRefund, -1, 1))", !1, e, !1, "Table count", "tableCount", e, "(CASE WHEN @status = 'VOIDED' THEN 0 ELSE (CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Member count flag: 1 normal, -1 refund, 0 voided. Use SUM to count members", "IF((@status = 'VOIDED' OR @memberId is null), 0, IF(@isRefund, -1, 1))", !1, e, !1, "Member count", "memberCount", e, "(CASE WHEN (@status = 'VOIDED' OR @member_id is null) THEN 0 ELSE (CASE WHEN @is_refund THEN -1 ELSE 1 END) END)", u.FIELD_ROLE_1, r), t.Field_Field$string("Customer name from pickup / in-house delivery / delivery channel", e, !1, e, !1, !1, "Customer", v, v, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer phone", H, H, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer address", j, j, e, e, r), t.Field_Field$string("Remark on the pickup / delivery order", e, !1, e, !1, !1, "Customer remark", s0, s0, e, e, r), t.Field_Field$timestamp("Scheduled pickup / delivery time", e, !1, e, !1, "Fulfillment time", u0, u0, e, u.FIELD_ROLE_0, r), t.Field_Field$string("Pax count by type (e.g. ADULTS, CHILDREN)", e, !1, e, !1, !1, "Pax breakdown", "paxBreakdown", "personMetaBreakdown", e, e, r), t.Field_Field$numeric("Refund rows only: original bill nett less every earlier refund of it. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Nett balance before refund", "refundNettBalanceBefore", e, "(CASE WHEN @refund_from IS NULL THEN NULL ELSE (SELECT COALESCE(ob.nett_total,0) FROM bills ob WHERE ob.id=@refund_from AND ob.restaurant_id=@restaurant_id)-COALESCE((SELECT SUM(COALESCE(pr.nett_total,0)) FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: nett balance before refund less this refund nett. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Nett balance after refund", "refundNettBalanceAfter", e, "(CASE WHEN @refund_from IS NULL THEN NULL ELSE (SELECT COALESCE(ob.nett_total,0) FROM bills ob WHERE ob.id=@refund_from AND ob.restaurant_id=@restaurant_id)-COALESCE((SELECT SUM(COALESCE(pr.nett_total,0)) FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0)-CASE WHEN @status='VOIDED' THEN 0 ELSE COALESCE(@nett_total,0) END END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: original bill gross less every earlier refund of it. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Gross balance before refund", "refundGrossBalanceBefore", e, z0 + t._billGross("ob.") + y0 + t._billGross("pr.") + ") FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0) END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Refund rows only: gross balance before refund less this refund gross. NULL elsewhere; per-row, do not sum", e, !1, e, !0, "Gross balance after refund", "refundGrossBalanceAfter", e, z0 + t._billGross("ob.") + y0 + t._billGross("pr.") + ") FROM bills pr WHERE pr.refund_from=@refund_from AND pr.restaurant_id=@restaurant_id AND pr.status<>'VOIDED' AND (pr.created_at<@created_at OR (pr.created_at=@created_at AND pr.id<@id))),0)-CASE WHEN @status='VOIDED' THEN 0 ELSE " + t._billGross("@") + " END END)", u.FIELD_ROLE_1, r), t.Field_Field$numeric(T.BCRS_c, T.IFNULLst, !1, e, !1, "Statutory charges", h0, h0, T.COALESst, u.FIELD_ROLE_1, r), t.Field_Field$string("Comma-joined distinct categories of the bill top-level, non-voided item lines (add-ons excluded), named as item Category is (Other for open items). A text list: filter with LIKE / NOT LIKE, not equality", e, !1, e, !1, !1, "Categories", "categories", e, "(select string_agg(distinct CASE WHEN flatten_items.category_name IS NULL OR flatten_items.product_id IS NULL OR flatten_items.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 flatten_items.category_name END, ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0 and flatten_items.status!='VOIDED')", e, r), t.Field_Field$string(T.The_fo, e, !1, e, !1, !1, "Food court order ID", $0, $0, e, u.FIELD_ROLE_5, r)], d.JSArray_Field);
|
|
9081
9081
|
},
|
|
9082
9082
|
$signature: 0
|
|
9083
9083
|
}, t.billSchema_closure0.prototype = {
|
|
@@ -9228,8 +9228,8 @@ Arguments: [` + _ + "]";
|
|
|
9228
9228
|
$signature: 1
|
|
9229
9229
|
}, t.completeTimeBillSchema_closure.prototype = {
|
|
9230
9230
|
call$1(r) {
|
|
9231
|
-
var e = null, n = "seqNumber", a = "deliveryName", i = "isRefund", s = "isPickup", l = "isInHouseDelivery", p = "isDelivery", _ = "completedAt", M = "integratedOrderId", b = "itemCount", O = "taxTotal", D = "discountTotal", $ = "grossTotal", E = "rounding", g = "takeawayPrice", h = "thirdPartyExtraCharge", R = "deliveryFee", C = "nettTotal", W = "deliveryFeeWithTax", B = "deliveryFeeWithoutTax", I = "otherChargeWithTax", x = "otherChargeWithoutTax", w = "discountInclusiveTaxTotal", v = "statutoryChargeTotal";
|
|
9232
|
-
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "No.", n, n, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Table", "slot", "slot", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Delivery", a, a, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund ID", "refundFrom", "refundedFrom", e, e, r), t.Field_Field$bool(e, e, !1, e, !1, "Refund", i, i, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundApprovedById", "refund.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund approver", "refundApprovedByName", "refund.approvedBy.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundedById", "refund.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund user", "refundedByName", "refund.by.name", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", "refundReason", "refund.reason", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member ID", "memberId", "membership.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member user ID", "memberUserId", "membership.userId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member name", "memberUserName", "membership.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Member phone", "memberPhoneNumber", "membership.phoneNumber", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Member birthday", "memberBirthday", "membership.birthday", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Source", "source", "source", T.x28case_x28, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Type", "type", "type", "(case when upper(@type)='PICKUP' then upper(@type) when upper(@type)='DELIVERY' then upper(@type) when @is_takeaway is true then 'TAKEAWAY' else upper(@type) end)", e, r), t.Field_Field$bool(e, e, !0, e, !1, "Pickup", s, s, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is in house delivery", l, l, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is other delivery", p, p, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is takeaway", "isTakeaway", "is.takeaway", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Closed at", _, _, e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SST", "sstInclusive", "nettTaxes.SST.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST before discount", "sstBeforeDiscount", "nettTaxes.SST.beforeDiscount", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SC", "serviceChargeInclusive", "nettTaxes.SERVICE_CHARGE.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC before discount", "serviceChargeBeforeDiscount", "nettTaxes.SERVICE_CHARGE.beforeDiscount", e, e, r), t.Field_Field$numeric(e, "IFNULL(@pax,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Pax", "pax", "person", T.COALESp, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Integrated order ID", M, M, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric(e, T.IFNULLi, !0, e, !1, "Item count", b, b, T.COALESi, e, r), t.Field_Field$numeric(e, "IFNULL(@taxTotal,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Tax", O, O, T.COALEStax0, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdiT, !1, e, !1, "Discount", D, D, T.COALESdit, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLg, !1, e, !1, "Item gross", $, $, T.COALESg, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-IFNULL(@discountTotal,0)-IFNULL(@thirdPartyExtraCharge,0)-IFNULL(@deliveryFee,0)-IFNULL(@taxTotal,0)-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross", "billGrossTotal", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-COALESCE(@discount_total,0)-COALESCE(@third_party_extra_charge,0)-COALESCE(@delivery_fee,0)-COALESCE(@tax_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@rounding,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Rounding", E, E, T.COALESr, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@sstTotal,0)*IF(@isRefund, -1, 1)", !0, e, !1, "SST", "sstTotal", "nettTaxes.SST.total", T.COALESss, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST %", "sstPercentage", "nettTaxes.SST.percentage", e, e, r), t.Field_Field$numeric(e, T.IFNULLse, !1, e, !1, "SC", "serviceChargeTotal", "nettTaxes.SERVICE_CHARGE.total", T.COALESse, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC %", "serviceChargePercentage", "nettTaxes.SERVICE_CHARGE.percentage", e, e, r), t.Field_Field$numeric(e, T.x28IFNULo, !1, e, !1, "Other charge", "otherChargeTotal", "nettTaxes.OTHER_CHARGE.total", T.x28COALEo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2d, !1, e, !1, "Gross w/ takeaway", "subTotalWithoutTakeaway", e, T.x28COALEgx2d, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtak, !1, e, !1, "Takeaway", g, g, T.COALEStak, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLth, !1, e, !1, "Extra charge", h, h, T.COALESth, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLde_, !1, e, !1, "Delivery fee", R, R, T.COALESdex2c, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLn, !1, e, !1, "Nett", C, C, T.COALESn, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@grossTotal,0)+IFNULL(@deliveryFeeWithTax,0)+IFNULL(@otherChargeWithTax,0)+IFNULL(@discountTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Item gross before charges", "grossBeforeCharges", e, "(COALESCE(@gross_total,0)+COALESCE(@delivery_fee_with_tax,0)+COALESCE(@other_charge_with_tax,0)+COALESCE(@discount_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-(case when @otherChargeWithTax>0 then 0 else IFNULL(@thirdPartyExtraCharge,0) end)-(case when @deliveryFeeWithTax>0 then 0 else IFNULL(@deliveryFee,0) end)-IFNULL(@taxTotal,0)-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross before charges", "billGrossBeforeCharges", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-(case when @other_charge_with_tax>0 then 0 else COALESCE(@third_party_extra_charge,0) end)-(case when @delivery_fee_with_tax>0 then 0 else COALESCE(@delivery_fee,0) end)-COALESCE(@tax_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member Recency", "recency", e, T.MIN_EX, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member frequency", "frequency", e, T.COUNT_, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member monetary", "monetary", e, T.SUM__n, e, r), t.Field_Field$numeric(e, T.IFNULLdeWT, !1, e, !1, "Delivery fee with tax", W, W, T.COALESdex5f_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdeWo, !1, e, !1, "Delivery fee without tax", B, B, T.COALESdex5fo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoT, !1, e, !1, "Other charge with tax", I, I, T.COALESo_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoo, !1, e, !1, "Other charge without tax", x, x, T.COALESoo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Duration", "duration", e, T.EXTRAC, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant", "restaurantName", e, T.x28selecn, u.FIELD_ROLE_4, r), t.Field_Field$numeric(e, e, !1, e, !1, "Labour hour", "labourHour", e, T.x28selecS, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payments", "payments", e, T.x28selecstn, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Items", "items", e, "(select string_agg(CONCAT(flatten_items.quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN flatten_items.code='' THEN NULL ELSE flatten_items.code END, flatten_items.name], ' ')), ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Discount reasons", "discountReasons", e, T.x28selecsta, e, r), t.Field_Field$numeric(e, T.IFNULLdiI, !1, e, !1, "Discount inc tax", w, w, T.COALESdii, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment Summaries", "paymentSummaries", e, "(select string_agg(distinct CONCAT(name, CASE WHEN card_type is not null THEN CONCAT(' (',card_type, ')') WHEN payment_gateway_issuer is not null THEN CONCAT(' (',payment_gateway_issuer, ')') ELSE '' END), ',') from payments where payments.bill_id=@id and payments.restaurant_id=@restaurant_id)", e, r), t.Field_Field$numeric(T.BCRS_c, T.IFNULLst, !1, e, !1, "Statutory charges", v, v, T.COALESst, u.FIELD_ROLE_1, r)], d.JSArray_Field);
|
|
9231
|
+
var e = null, n = "seqNumber", a = "deliveryName", i = "isRefund", s = "isPickup", l = "isInHouseDelivery", p = "isDelivery", _ = "completedAt", M = "integratedOrderId", b = "itemCount", O = "taxTotal", D = "discountTotal", $ = "grossTotal", E = "rounding", g = "takeawayPrice", h = "thirdPartyExtraCharge", R = "deliveryFee", C = "nettTotal", W = "deliveryFeeWithTax", B = "deliveryFeeWithoutTax", I = "otherChargeWithTax", x = "otherChargeWithoutTax", w = "discountInclusiveTaxTotal", v = "statutoryChargeTotal", H = "foodCourtOrderId";
|
|
9232
|
+
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "No.", n, n, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Table", "slot", "slot", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Delivery", a, a, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund ID", "refundFrom", "refundedFrom", e, e, r), t.Field_Field$bool(e, e, !1, e, !1, "Refund", i, i, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundApprovedById", "refund.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund approver", "refundApprovedByName", "refund.approvedBy.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "refundedById", "refund.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund user", "refundedByName", "refund.by.name", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", "refundReason", "refund.reason", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member ID", "memberId", "membership.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member user ID", "memberUserId", "membership.userId", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Member name", "memberUserName", "membership.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Member phone", "memberPhoneNumber", "membership.phoneNumber", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Member birthday", "memberBirthday", "membership.birthday", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Source", "source", "source", T.x28case_x28, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Type", "type", "type", "(case when upper(@type)='PICKUP' then upper(@type) when upper(@type)='DELIVERY' then upper(@type) when @is_takeaway is true then 'TAKEAWAY' else upper(@type) end)", e, r), t.Field_Field$bool(e, e, !0, e, !1, "Pickup", s, s, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is in house delivery", l, l, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is other delivery", p, p, e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "Is takeaway", "isTakeaway", "is.takeaway", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Closed at", _, _, e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SST", "sstInclusive", "nettTaxes.SST.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST before discount", "sstBeforeDiscount", "nettTaxes.SST.beforeDiscount", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "Inclusive SC", "serviceChargeInclusive", "nettTaxes.SERVICE_CHARGE.inclusive", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC before discount", "serviceChargeBeforeDiscount", "nettTaxes.SERVICE_CHARGE.beforeDiscount", e, e, r), t.Field_Field$numeric(e, "IFNULL(@pax,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Pax", "pax", "person", T.COALESp, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Integrated order ID", M, M, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric(e, T.IFNULLi, !0, e, !1, "Item count", b, b, T.COALESi, e, r), t.Field_Field$numeric(e, "IFNULL(@taxTotal,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Tax", O, O, T.COALEStax0, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdiT, !1, e, !1, "Discount", D, D, T.COALESdit, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLg, !1, e, !1, "Item gross", $, $, T.COALESg, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-IFNULL(@discountTotal,0)-IFNULL(@thirdPartyExtraCharge,0)-IFNULL(@deliveryFee,0)-IFNULL(@taxTotal,0)-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross", "billGrossTotal", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-COALESCE(@discount_total,0)-COALESCE(@third_party_extra_charge,0)-COALESCE(@delivery_fee,0)-COALESCE(@tax_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@rounding,0)*IF(@isRefund, -1, 1)", !1, e, !1, "Rounding", E, E, T.COALESr, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IFNULL(@sstTotal,0)*IF(@isRefund, -1, 1)", !0, e, !1, "SST", "sstTotal", "nettTaxes.SST.total", T.COALESss, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SST %", "sstPercentage", "nettTaxes.SST.percentage", e, e, r), t.Field_Field$numeric(e, T.IFNULLse, !1, e, !1, "SC", "serviceChargeTotal", "nettTaxes.SERVICE_CHARGE.total", T.COALESse, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, "SC %", "serviceChargePercentage", "nettTaxes.SERVICE_CHARGE.percentage", e, e, r), t.Field_Field$numeric(e, T.x28IFNULo, !1, e, !1, "Other charge", "otherChargeTotal", "nettTaxes.OTHER_CHARGE.total", T.x28COALEo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2d, !1, e, !1, "Gross w/ takeaway", "subTotalWithoutTakeaway", e, T.x28COALEgx2d, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtak, !1, e, !1, "Takeaway", g, g, T.COALEStak, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLth, !1, e, !1, "Extra charge", h, h, T.COALESth, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLde_, !1, e, !1, "Delivery fee", R, R, T.COALESdex2c, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLn, !1, e, !1, "Nett", C, C, T.COALESn, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@grossTotal,0)+IFNULL(@deliveryFeeWithTax,0)+IFNULL(@otherChargeWithTax,0)+IFNULL(@discountTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Item gross before charges", "grossBeforeCharges", e, "(COALESCE(@gross_total,0)+COALESCE(@delivery_fee_with_tax,0)+COALESCE(@other_charge_with_tax,0)+COALESCE(@discount_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@nettTotal,0)-IFNULL(@rounding,0)-(case when @otherChargeWithTax>0 then 0 else IFNULL(@thirdPartyExtraCharge,0) end)-(case when @deliveryFeeWithTax>0 then 0 else IFNULL(@deliveryFee,0) end)-IFNULL(@taxTotal,0)-IFNULL(@serviceChargeTotal,0)-IFNULL(@statutoryChargeTotal,0))*IF(@isRefund, -1, 1)", !1, e, !1, "Bill gross before charges", "billGrossBeforeCharges", e, "(COALESCE(@nett_total,0)-COALESCE(@rounding,0)-(case when @other_charge_with_tax>0 then 0 else COALESCE(@third_party_extra_charge,0) end)-(case when @delivery_fee_with_tax>0 then 0 else COALESCE(@delivery_fee,0) end)-COALESCE(@tax_total,0)-COALESCE(@service_charge_total,0)-COALESCE(@statutory_charge_total,0))*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member Recency", "recency", e, T.MIN_EX, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member frequency", "frequency", e, T.COUNT_, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Member monetary", "monetary", e, T.SUM__n, e, r), t.Field_Field$numeric(e, T.IFNULLdeWT, !1, e, !1, "Delivery fee with tax", W, W, T.COALESdex5f_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLdeWo, !1, e, !1, "Delivery fee without tax", B, B, T.COALESdex5fo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoT, !1, e, !1, "Other charge with tax", I, I, T.COALESo_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLoo, !1, e, !1, "Other charge without tax", x, x, T.COALESoo, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Duration", "duration", e, T.EXTRAC, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant", "restaurantName", e, T.x28selecn, u.FIELD_ROLE_4, r), t.Field_Field$numeric(e, e, !1, e, !1, "Labour hour", "labourHour", e, T.x28selecS, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payments", "payments", e, T.x28selecstn, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Items", "items", e, "(select string_agg(CONCAT(flatten_items.quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN flatten_items.code='' THEN NULL ELSE flatten_items.code END, flatten_items.name], ' ')), ',') from flatten_items where flatten_items.bill_id=@id and flatten_items.restaurant_id=@restaurant_id and flatten_items.layer=0)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Discount reasons", "discountReasons", e, T.x28selecsta, e, r), t.Field_Field$numeric(e, T.IFNULLdiI, !1, e, !1, "Discount inc tax", w, w, T.COALESdii, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment Summaries", "paymentSummaries", e, "(select string_agg(distinct CONCAT(name, CASE WHEN card_type is not null THEN CONCAT(' (',card_type, ')') WHEN payment_gateway_issuer is not null THEN CONCAT(' (',payment_gateway_issuer, ')') ELSE '' END), ',') from payments where payments.bill_id=@id and payments.restaurant_id=@restaurant_id)", e, r), t.Field_Field$numeric(T.BCRS_c, T.IFNULLst, !1, e, !1, "Statutory charges", v, v, T.COALESst, u.FIELD_ROLE_1, r), t.Field_Field$string(T.The_fo, e, !1, e, !1, !1, "Food court order ID", H, H, e, u.FIELD_ROLE_5, r)], d.JSArray_Field);
|
|
9233
9233
|
},
|
|
9234
9234
|
$signature: 0
|
|
9235
9235
|
}, t.completeTimeBillSchema_closure0.prototype = {
|
|
@@ -9275,8 +9275,8 @@ Arguments: [` + _ + "]";
|
|
|
9275
9275
|
$signature: 1
|
|
9276
9276
|
}, t.depositSchema_closure.prototype = {
|
|
9277
9277
|
call$1(r) {
|
|
9278
|
-
var e = null, n = "businessId", a = "restaurantId", i = "referenceNo", s = "targetDate", l = "currency", p = "customerName", _ = "customerPhone", M = "createdByName", b = "createdById", O = "paymentName", D = "paidAmount", $ = "collectedAmount", E = "appliedAt", g = "appliedAmount", h = "appliedBillId", R = "excessAmount", C = "excessHandling", W = "refundedAt", B = "refundedAmount", I = "retainedAmount", x = "refundReason", w = "refundPercentage", v = "refundDaysBefore",
|
|
9279
|
-
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Business ID", n, n, e, u.FIELD_ROLE_5, r), t.Field_Field$string("Outlet that created the deposit", e, !1, e, !1, !1, "Restaurant ID", a, a, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Reference no", i, i, e, e, r), t.Field_Field$string("draft, active, applied, refunded or forfeited", e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$timestamp("Date the deposit is reserved for", e, !1, e, !1, "Target date", s, s, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Deposit amount", "amount", "amount", e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, l, l, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer", p, p, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer phone", _, _, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Created by", M, M, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, b, b, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Paid time", "paidAt", "paidAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment method", O, O, e, e, r), t.Field_Field$numeric("Amount tendered, which can exceed the deposit amount", e, !0, e, !1, e, D, D, e, e, r), t.Field_Field$numeric("Deposit amount once paid, 0 while still a draft", e, !1, e, !1, "Collected", $, $, e, u.FIELD_ROLE_1, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Applied time", E, E, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric("Part of the deposit spent on the bill", e, !1, e, !1, "Applied", g, g, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Applied bill ID", h, h, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric("Deposit left over after the bill was paid", e, !1, e, !1, "Excess", R, R, e, u.FIELD_ROLE_1, r), t.Field_Field$string("retain keeps the excess, returnBalance pays it back", e, !1, e, !1, !1, "Excess handling", C, C, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Refunded time", W, W, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Refunded", B, B, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Retained on refund", I, I, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", x, x, e, e, r), t.Field_Field$numeric("Refund policy tier applied, as a percentage", e, !0, e, !1, e, w, w, e, e, r), t.Field_Field$numeric(e, e, !0, e, !1, e, v, v, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Forfeited time",
|
|
9278
|
+
var e = null, n = "businessId", a = "restaurantId", i = "referenceNo", s = "targetDate", l = "currency", p = "customerName", _ = "customerPhone", M = "createdByName", b = "createdById", O = "paymentName", D = "paidAmount", $ = "collectedAmount", E = "appliedAt", g = "appliedAmount", h = "appliedBillId", R = "excessAmount", C = "excessHandling", W = "refundedAt", B = "refundedAmount", I = "retainedAmount", x = "refundReason", w = "refundPercentage", v = "refundDaysBefore", H = "forfeitedAt", j = "forfeitedAmount", s0 = "forfeitReason", u0 = "cashOutAmount", z0 = "outstandingAmount", y0 = "depositIncomeAmount";
|
|
9279
|
+
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Business ID", n, n, e, u.FIELD_ROLE_5, r), t.Field_Field$string("Outlet that created the deposit", e, !1, e, !1, !1, "Restaurant ID", a, a, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Reference no", i, i, e, e, r), t.Field_Field$string("draft, active, applied, refunded or forfeited", e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$timestamp("Date the deposit is reserved for", e, !1, e, !1, "Target date", s, s, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Deposit amount", "amount", "amount", e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, l, l, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer", p, p, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Customer phone", _, _, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Created by", M, M, e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, b, b, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Paid time", "paidAt", "paidAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Payment method", O, O, e, e, r), t.Field_Field$numeric("Amount tendered, which can exceed the deposit amount", e, !0, e, !1, e, D, D, e, e, r), t.Field_Field$numeric("Deposit amount once paid, 0 while still a draft", e, !1, e, !1, "Collected", $, $, e, u.FIELD_ROLE_1, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Applied time", E, E, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric("Part of the deposit spent on the bill", e, !1, e, !1, "Applied", g, g, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Applied bill ID", h, h, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric("Deposit left over after the bill was paid", e, !1, e, !1, "Excess", R, R, e, u.FIELD_ROLE_1, r), t.Field_Field$string("retain keeps the excess, returnBalance pays it back", e, !1, e, !1, !1, "Excess handling", C, C, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Refunded time", W, W, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Refunded", B, B, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Retained on refund", I, I, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Refund reason", x, x, e, e, r), t.Field_Field$numeric("Refund policy tier applied, as a percentage", e, !0, e, !1, e, w, w, e, e, r), t.Field_Field$numeric(e, e, !0, e, !1, e, v, v, e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Forfeited time", H, H, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Forfeited", j, j, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Forfeit reason", s0, s0, e, e, r), t.Field_Field$numeric("Refund plus any excess returned to the customer", e, !1, e, !1, "Cash out", u0, u0, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Collected deposit not yet applied, refunded or forfeited", e, !1, e, !1, "Outstanding", z0, z0, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(T.Forfei, e, !1, e, !1, "Deposit income", y0, y0, e, u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant", "restaurantName", e, T.x28selecn, e, r)], d.JSArray_Field);
|
|
9280
9280
|
},
|
|
9281
9281
|
$signature: 0
|
|
9282
9282
|
}, t.depositSchema_closure0.prototype = {
|
|
@@ -9322,10 +9322,10 @@ Arguments: [` + _ + "]";
|
|
|
9322
9322
|
$signature: 1
|
|
9323
9323
|
}, t.flattenItemSchema_closure.prototype = {
|
|
9324
9324
|
call$1(r) {
|
|
9325
|
-
var e = null, n = "itemCreatedAt", a = "billCompletedAt", i = "productId", s = "perXUnit", l = "takeawayId", p = "takeawayName", _ = "isRefund", M = "servedAt", b = "isTakeaway", O = "quantity", D = "unitQuantity", $ = "billAdjustmentTotal", E = "itemAdjustmentTotal", g = "grossTotal", h = "takeawayPrice", R = "nettTotal", C = "parentId", W = "layerNettTotal", B = "layerBillAdjustmentTotal", I = "layerItemAdjustmentTotal", x = "layerGrossTotal", w = "layerTakeawayPrice", v = "layerTaxTotal",
|
|
9325
|
+
var e = null, n = "itemCreatedAt", a = "billCompletedAt", i = "productId", s = "perXUnit", l = "takeawayId", p = "takeawayName", _ = "isRefund", M = "servedAt", b = "isTakeaway", O = "quantity", D = "unitQuantity", $ = "billAdjustmentTotal", E = "itemAdjustmentTotal", g = "grossTotal", h = "takeawayPrice", R = "nettTotal", C = "parentId", W = "layerNettTotal", B = "layerBillAdjustmentTotal", I = "layerItemAdjustmentTotal", x = "layerGrossTotal", w = "layerTakeawayPrice", v = "layerTaxTotal", H = "layerScTotal", j = "layerOtherChargeTotal", s0 = "customAttributes", u0 = "layerZeroParentId", z0 = "collectedAt", y0 = "subCategories", h0 = "billAdjustmentInclusiveTaxTotal", $0 = "itemAdjustmentInclusiveTaxTotal", I0 = "layerBillAdjustmentInclusiveTaxTotal", W0 = "layerItemAdjustmentInclusiveTaxTotal", Z = "billAdjustmentExclusiveTaxTotal", H0 = "itemAdjustmentExclusiveTaxTotal", v0 = "layerBillAdjustmentExclusiveTaxTotal", S0 = "layerItemAdjustmentExclusiveTaxTotal", H1 = "priceGroup", X1 = "originalPrice", k1 = "catalogId", U1 = "baseItemPrice", B0 = "catalogName", O1 = "priceExclusiveTax", Ve = "originalPriceExclusiveTax", je = "baseItemPriceExclusiveTax", Ke = "serveDelayId", Ze = "serveDelayName", et = "serveDelayInMins";
|
|
9326
9326
|
return t._setArrayType([t.Field_Field$string(e, e, !1, e, !1, !1, "ID", "id", "_id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "docId", "_docId", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Restaurant ID", "restaurantId", "_restaurantId", e, u.FIELD_ROLE_5, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Time", "createdAt", "_createdAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !0, e, !1, e, "publishedAt", "_publishedAt", e, e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Item time", n, n, e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Bill close time", a, a, e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Bill ID", "billId", "billId", e, u.FIELD_ROLE_5, r), t.Field_Field$string("Values: DRAFT, VOIDED, SENT, REFUNDED. DRAFT and SENT both considered valid sales. REFUNDED is a line whose sale was refunded: it stays a sale, and the refund bill's own line (is_refund) takes it back off.", e, !1, e, !1, !1, "Status", "status", "status", e, e, r), t.Field_Field$string(e, e, !1, i, !1, !0, "Name", "name", "name", e, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Per unit", s, s, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Unit", "unit", "unit", e, e, r), t.Field_Field$string(e, `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)
|
|
9327
9327
|
`, !1, e, !1, !0, "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
|
|
9328
|
-
`, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Takeaway ID", l, l, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Takeaway name", p, p, e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Code", "code", "code", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Product ID", i, i, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Variant ID", "variantId", "variant.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Variant", "variantName", "variant.name", e, u.FIELD_ROLE_4, r), t.Field_Field$bool("A line of a refund bill: what was given back, its quantity and money negated. The refunded sale keeps its own line.", e, !1, e, !1, "Refund", _, _, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "User id", "createdById", "createdBy.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "User", "createdByName", "createdBy.name", e, u.FIELD_ROLE_4, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Sent time", "sentAt", "sentAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Served time", M, M, e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Printed time", "printedAt", "printBy.printAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Void time", "voidAt", "void.voidAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void reason", "voidReason", "void.reason", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "voidedById", "void.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void user", "voidedByName", "void.by.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "voidApprovedById", "void.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, e, r), t.Field_Field$bool(e, e, !1, e, !1, "Takeaway", b, b, e, e, r), t.Field_Field$numeric("Units sold on the line, valid at every layer: a nested line already carries its parent quantity, so never multiply by the parent again. To count a product wherever it is sold — standalone and inside bundles — match the line itself and do not filter layer.", "@quantity*IF(@isRefund, -1, 1)", !1, e, !1, "Qty", O, O, T.x40quant, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IF(@perXUnit IS NULL, 0, @unitQuantity)*IF(@isRefund, -1, 1)", !1, e, !1, "Unit qty", D, D, "CASE WHEN @per_x_unit IS NULL THEN 0 ELSE @unit_quantity END*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@sstTotal*IF(@isRefund, -1, 1)", !1, e, !1, "SST", "sstTotal", "sst.total", T.x40sst_t, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !0, e, !1, "SST %", "sstPercentage", "sst.percentage", e, e, r), t.Field_Field$numeric(e, e, !0, e, !1, "SC %", "serviceChargePercentage", "sc.percentage", e, e, r), t.Field_Field$numeric(e, "@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "SC", "serviceChargeTotal", "sc.total", T.x40servi, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@otherChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Other charge", "otherChargeTotal", "otherCharge.total", T.x40other, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x40billA, !1, e, !1, "Bill discount", $, $, T.x40bill_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x40itemA, !1, e, !1, "Item discount", E, E, T.x40item_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@grossTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Gross", g, g, T.x40gross, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28_grosT, !1, e, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, T.x28_gros_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@takeawayPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Takeaway price", h, h, T.x40takea, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Net sales of the line after discounts, before tax, refund sign applied; a layer-0 row already carries its addons and layer 1+ rows carry 0 — SUM over layer = 0 reconciles to bill.nett_total. The product sales measure.", "@nettTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Nett", R, R, T.x40nett_, u.FIELD_ROLE_1, r), t.Field_Field$string("The line a layer 1+ line sits under, as that line's id: the product an option was chosen on, or the set a product was sold inside. Empty on layer 0 lines.", e, !1, e, !1, !1, "Parent ID", C, "parent.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, C, !1, !1, "Parent name", "parentName", "parent.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string("What a layer 1+ line names: product = a menu product, carrying its own product_id, name and category — a product sold inside a set, or an option the menu defines as a product, so it does not tell the two apart; normal = an option or modifier that names no menu product; dynamic = a sub-item that names no menu product. Which kinds appear depends on how the business built its menu. Empty on layer 0 lines.", e, !1, e, !1, !1, "Addon type", "addonType", "addon.type", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Addon ID", "addonId", "addon.selectionId", e, u.FIELD_ROLE_5, r), t.Field_Field$string("The option group (menu_v3_group.id) an option line was chosen from, taken from addon_id: set on lines chosen under a parent line (layer 1+), empty on layer 0 product lines.", "SPLIT(@addonId, '/')[OFFSET(0)]", !1, e, !1, !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", u.FIELD_ROLE_5, r), t.Field_Field$numeric("Item depth: 0 = a line ordered on its own (a product, or a set). 1+ = a line under another: an option or modifier chosen on it, or a product sold inside the set it is. -1 = bill level modifier, usually not consider item sales.", e, !1, e, !1, "Layer", "layer", "layer", e, e, r), t.Field_Field$numeric("The price of an option line for its whole quantity (the option's price times the line's quantity): set on option lines (layer 1+), empty on layer 0. Its layer 0 line's nett total already carries it, so it adds to no product total.", "@addonPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Addon price", "addonPrice", "addon.price", T.x40addon, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtax, !1, e, !1, "Tax", "taxTotal", "tax.total", T.COALEStax_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULb, !1, e, !1, "Discount", "discountTotal", e, T.x28COALEb, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2b, !1, e, !1, "Gross before charges", "grossBeforeCharges", e, T.x28COALEgx2b, u.FIELD_ROLE_1, r), t.Field_Field$string(e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING([IF(@code='', NULL, @code), @name], ' '))", !1, e, !1, !1, "Summary", "summary", e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN @code='' THEN NULL ELSE @code END, @name], ' '))", e, r), t.Field_Field$numeric("The root line's nett allocated across its whole tree by nonnegative price weights (equal shares when every weight is zero). A line's own allocation plus its descendants' is an attributed value, never a separately charged price; summing it across layers under-counts sales — not a sales measure.", "@layerNettTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer nett", W, W, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_3, r), t.Field_Field$numeric(e, "@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount", B, B, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount", I, I, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerGrossTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer gross total", x, x, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Layer takeaway price", w, w, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer tax total", v, v, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerScTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer sc", X, X, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer other charge", j, j, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, e, !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", u.FIELD_ROLE_1, r), t.Field_Field$string("The menu product's custom attributes as JSON text, set on a line that names a menu product: an object whose keys and values the business defines, so each business has its own. Read a key with custom_attributes::jsonb ->> '<key>'.", e, !1, e, !1, !1, "Custom attributes", s0, s0, e, e, r), t.Field_Field$string("The layer 0 product line a line belongs to: an option line's root line, and a layer 0 line's own id. Grouping by it gathers a product line with every option chosen under it.", e, !1, e, !1, !1, "Layer 0 parent ID", u0, u0, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Charge variant", "chargeVariant", e, "(select string_agg(variant, ', ' order by 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 not in ('SERVICE_CHARGE','BCRS'))", e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Collected time", z0, z0, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Costing", "costing", "costing", e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "ROUND(TIMESTAMP_DIFF(IFNULL(@servedAt, CURRENT_TIMESTAMP), @sentAt, SECOND),0)", !1, e, !1, "Preparation seconds", "preparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM AGE(COALESCE(@served_at, CURRENT_TIMESTAMP),@sent_at)),0)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Computed: nett total minus costing", "((@nettTotal-coalesce(@costing, 0))*IF(@isRefund, -1, 1))", !1, e, !1, "Profit", "profit", e, "((@nett_total-coalesce(@costing, 0))*CASE WHEN @is_refund THEN -1 ELSE 1 END)", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, u0, !1, !1, "Layer 0 parent name", "layerZeroParentName", e, "(select name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Layer 0 parent code", "layerZeroParentCode", e, "(select code from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Layer 0 parent category", "layerZeroParentCategory", e, "(select category_name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Sub categories", y0, y0, e, e, r), t.Field_Field$numeric(e, "@billAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Bill discount inc tax", g0, g0, "@bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@itemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Item discount inc tax", h0, h0, "@item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerBillAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount inc tax", I0, I0, "@layer_bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount inc tax", W0, W0, "@layer_item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@billAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Bill discount exc tax", Z, Z, "@bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@itemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Item discount exc tax", H0, H0, "@item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerBillAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount exc tax", v0, v0, "@layer_bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount exc tax", S0, S0, "@layer_item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$string(e, "IF(@variantId IS NULL OR @variantId = '', @productId, CONCAT(@productId, '/', @variantId))", !0, e, !1, !1, "Menu item ID", "menuItemId", e, "CASE WHEN @variant_id IS NULL OR @variant_id = '' THEN @product_id ELSE @product_id || '/' || @variant_id END", e, r), t.Field_Field$string("Special-price tier when a member/promotion PRICE_CHANGE effect set the item price (e.g. vip). Null for normal sales.", e, !1, e, !1, !1, "Price group", H1, H1, e, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Original price", X1, X1, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Price", "price", "price", e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Sold price minus original price, per unit (not multiplied by quantity). Positive means marked up. Non-zero for member/promotion price tiers, open price (original price is 0, so this equals the full price) and manual overrides. Null when either side is unknown.", "@price - @originalPrice", !1, e, !1, "Price difference", "priceDifference", e, "@price - @original_price", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Addons", "addons", e, "(select string_agg(distinct name || coalesce(' (' || nullif(variant_name, '') || ')', ''), ',' order by name || coalesce(' (' || nullif(variant_name, '') || ')', '')) from flatten_items where flatten_items.parent_id=@id and flatten_items.restaurant_id=@restaurant_id)", e, r), t.Field_Field$string("Catalog used at order time. Null means not recorded; an empty string means the base menu.", e, !1, e, !1, !1, "Catalog ID", k1, k1, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric("Item price from the menu as resolved at order time, after catalog markup, catalog override and POS override, before bill-level repricing or adjustments.", e, !1, e, !1, "Menu item price", U1, U1, e, u.FIELD_ROLE_1, r), t.Field_Field$string("Catalog name recorded on the item at order time.", e, !1, e, !1, !1, "Catalog name", B0, B0, e, u.FIELD_ROLE_4, r), t.Field_Field$numeric("Price with the inclusive product tax of the layer-0 item removed. Equals price when that tax is exclusive or absent.", e, !1, e, !1, "Price (excl. tax)", O1, O1, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Original price with the inclusive product tax removed.", e, !1, e, !1, "Original price (excl. tax)", Ve, Ve, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Menu item price with the inclusive product tax removed.", e, !1, e, !1, "Menu item price (excl. tax)", je, je, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Seconds from sent to kitchen until the last KDS station finished cooking. Null until every station of the item has finished, and on items with no KDS station.", e, !1, e, !1, "Kitchen preparation seconds", "kitchenPreparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM ((select CASE WHEN count(*)=count(finished_at) THEN max(finished_at) END from kitchen_stations where kitchen_stations.bill_id=@bill_id and kitchen_stations.restaurant_id=@restaurant_id and kitchen_stations.item_id=@id)-@sent_at)),0)", u.FIELD_ROLE_1, r), t.Field_Field$string("Order pacing rule applied to the item at order time. Plumbing id; chart serveDelayName instead.", e, !0, e, !1, !1, "Serve later ID", Ke, Ke, e, e, r), t.Field_Field$string('Name of the order pacing (serve later) rule on the item, e.g. "30 mins" or "custom". Null when the item is served immediately.', e, !1, e, !1, !1, "Serve later", Ze, Ze, e, e, r), t.Field_Field$numeric("Minutes the kitchen was asked to hold the item before starting it (order pacing). Subtract from a prep-time target to exclude intentional delay. Null when the item is served immediately.", e, !1, e, !1, "Serve later delay (mins)", et, et, e, u.FIELD_ROLE_1, r)], d.JSArray_Field);
|
|
9328
|
+
`, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Takeaway ID", l, l, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Takeaway name", p, p, e, u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Code", "code", "code", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Remark", "remark", "remark", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Product ID", i, i, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Variant ID", "variantId", "variant.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Variant", "variantName", "variant.name", e, u.FIELD_ROLE_4, r), t.Field_Field$bool("A line of a refund bill: what was given back, its quantity and money negated. The refunded sale keeps its own line.", e, !1, e, !1, "Refund", _, _, e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "User id", "createdById", "createdBy.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "User", "createdByName", "createdBy.name", e, u.FIELD_ROLE_4, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Sent time", "sentAt", "sentAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Served time", M, M, e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Printed time", "printedAt", "printBy.printAt", e, u.FIELD_ROLE_0, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Void time", "voidAt", "void.voidAt", e, u.FIELD_ROLE_0, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void reason", "voidReason", "void.reason", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "voidedById", "void.by.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void user", "voidedByName", "void.by.name", e, e, r), t.Field_Field$string(e, e, !0, e, !1, !1, e, "voidApprovedById", "void.approvedBy.id", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Void approver", "voidApprovedByName", "void.approvedBy.name", e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "SST before discount", "sstBeforeDiscount", "sst.beforeDiscount", e, e, r), t.Field_Field$bool(e, e, !0, e, !1, "SC before discount", "serviceChargeBeforeDiscount", "sc.beforeDiscount", e, e, r), t.Field_Field$bool(e, e, !1, e, !1, "Takeaway", b, b, e, e, r), t.Field_Field$numeric("Units sold on the line, valid at every layer: a nested line already carries its parent quantity, so never multiply by the parent again. To count a product wherever it is sold — standalone and inside bundles — match the line itself and do not filter layer.", "@quantity*IF(@isRefund, -1, 1)", !1, e, !1, "Qty", O, O, T.x40quant, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "IF(@perXUnit IS NULL, 0, @unitQuantity)*IF(@isRefund, -1, 1)", !1, e, !1, "Unit qty", D, D, "CASE WHEN @per_x_unit IS NULL THEN 0 ELSE @unit_quantity END*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@sstTotal*IF(@isRefund, -1, 1)", !1, e, !1, "SST", "sstTotal", "sst.total", T.x40sst_t, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !0, e, !1, "SST %", "sstPercentage", "sst.percentage", e, e, r), t.Field_Field$numeric(e, e, !0, e, !1, "SC %", "serviceChargePercentage", "sc.percentage", e, e, r), t.Field_Field$numeric(e, "@serviceChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "SC", "serviceChargeTotal", "sc.total", T.x40servi, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@otherChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Other charge", "otherChargeTotal", "otherCharge.total", T.x40other, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x40billA, !1, e, !1, "Bill discount", $, $, T.x40bill_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x40itemA, !1, e, !1, "Item discount", E, E, T.x40item_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@grossTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Gross", g, g, T.x40gross, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28_grosT, !1, e, !1, "Gross w/ takeaway", "grossTotalWithoutTakeaway", e, T.x28_gros_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@takeawayPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Takeaway price", h, h, T.x40takea, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Net sales of the line after discounts, before tax, refund sign applied; a layer-0 row already carries its addons and layer 1+ rows carry 0 — SUM over layer = 0 reconciles to bill.nett_total. The product sales measure.", "@nettTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Nett", R, R, T.x40nett_, u.FIELD_ROLE_1, r), t.Field_Field$string("The line a layer 1+ line sits under, as that line's id: the product an option was chosen on, or the set a product was sold inside. Empty on layer 0 lines.", e, !1, e, !1, !1, "Parent ID", C, "parent.id", e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, C, !1, !1, "Parent name", "parentName", "parent.name", e, u.FIELD_ROLE_4, r), t.Field_Field$string("What a layer 1+ line names: product = a menu product, carrying its own product_id, name and category — a product sold inside a set, or an option the menu defines as a product, so it does not tell the two apart; normal = an option or modifier that names no menu product; dynamic = a sub-item that names no menu product. Which kinds appear depends on how the business built its menu. Empty on layer 0 lines.", e, !1, e, !1, !1, "Addon type", "addonType", "addon.type", e, e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Addon ID", "addonId", "addon.selectionId", e, u.FIELD_ROLE_5, r), t.Field_Field$string("The option group (menu_v3_group.id) an option line was chosen from, taken from addon_id: set on lines chosen under a parent line (layer 1+), empty on layer 0 product lines.", "SPLIT(@addonId, '/')[OFFSET(0)]", !1, e, !1, !1, "Group ID", "groupId", e, "SPLIT_PART(@addon_id, '/',1)", u.FIELD_ROLE_5, r), t.Field_Field$numeric("Item depth: 0 = a line ordered on its own (a product, or a set). 1+ = a line under another: an option or modifier chosen on it, or a product sold inside the set it is. -1 = bill level modifier, usually not consider item sales.", e, !1, e, !1, "Layer", "layer", "layer", e, e, r), t.Field_Field$numeric("The price of an option line for its whole quantity (the option's price times the line's quantity): set on option lines (layer 1+), empty on layer 0. Its layer 0 line's nett total already carries it, so it adds to no product total.", "@addonPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Addon price", "addonPrice", "addon.price", T.x40addon, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.IFNULLtax, !1, e, !1, "Tax", "taxTotal", "tax.total", T.COALEStax_, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULb, !1, e, !1, "Discount", "discountTotal", e, T.x28COALEb, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, T.x28IFNULgx2b, !1, e, !1, "Gross before charges", "grossBeforeCharges", e, T.x28COALEgx2b, u.FIELD_ROLE_1, r), t.Field_Field$string(e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING([IF(@code='', NULL, @code), @name], ' '))", !1, e, !1, !1, "Summary", "summary", e, "CONCAT(@quantity,'x ',ARRAY_TO_STRING(ARRAY[CASE WHEN @code='' THEN NULL ELSE @code END, @name], ' '))", e, r), t.Field_Field$numeric("The root line's nett allocated across its whole tree by nonnegative price weights (equal shares when every weight is zero). A line's own allocation plus its descendants' is an attributed value, never a separately charged price; summing it across layers under-counts sales — not a sales measure.", "@layerNettTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer nett", W, W, "@layer_nett_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_3, r), t.Field_Field$numeric(e, "@layerBillAdjustmentTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount", B, B, "@layer_bill_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount", I, I, "@layer_item_adjustment_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerGrossTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer gross total", x, x, "@layer_gross_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerTakeawayPrice*IF(@isRefund, -1, 1)", !1, e, !1, "Layer takeaway price", w, w, "@layer_takeaway_price*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer tax total", v, v, "@layer_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerScTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer sc", H, H, "@layer_sc_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerOtherChargeTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer other charge", j, j, "@layer_other_charge_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "(IFNULL(@layerGrossTotal,0)+IFNULL(@layerBillAdjustmentTotal,0)+IFNULL(@layerItemAdjustmentTotal,0))*IF(@isRefund, -1, 1)", !1, e, !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", u.FIELD_ROLE_1, r), t.Field_Field$string("The menu product's custom attributes as JSON text, set on a line that names a menu product: an object whose keys and values the business defines, so each business has its own. Read a key with custom_attributes::jsonb ->> '<key>'.", e, !1, e, !1, !1, "Custom attributes", s0, s0, e, e, r), t.Field_Field$string("The layer 0 product line a line belongs to: an option line's root line, and a layer 0 line's own id. Grouping by it gathers a product line with every option chosen under it.", e, !1, e, !1, !1, "Layer 0 parent ID", u0, u0, e, u.FIELD_ROLE_5, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Charge variant", "chargeVariant", e, "(select string_agg(variant, ', ' order by 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 not in ('SERVICE_CHARGE','BCRS'))", e, r), t.Field_Field$timestamp(e, e, !1, e, !1, "Collected time", z0, z0, e, u.FIELD_ROLE_0, r), t.Field_Field$numeric(e, e, !1, e, !1, "Costing", "costing", "costing", e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "ROUND(TIMESTAMP_DIFF(IFNULL(@servedAt, CURRENT_TIMESTAMP), @sentAt, SECOND),0)", !1, e, !1, "Preparation seconds", "preparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM AGE(COALESCE(@served_at, CURRENT_TIMESTAMP),@sent_at)),0)", u.FIELD_ROLE_1, r), t.Field_Field$numeric("Computed: nett total minus costing", "((@nettTotal-coalesce(@costing, 0))*IF(@isRefund, -1, 1))", !1, e, !1, "Profit", "profit", e, "((@nett_total-coalesce(@costing, 0))*CASE WHEN @is_refund THEN -1 ELSE 1 END)", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, u0, !1, !1, "Layer 0 parent name", "layerZeroParentName", e, "(select name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", u.FIELD_ROLE_4, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Layer 0 parent code", "layerZeroParentCode", e, "(select code from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Layer 0 parent category", "layerZeroParentCategory", e, "(select category_name from flatten_items where flatten_items.id=@layer_zero_parent_id and flatten_items.restaurant_id=@restaurant_id and flatten_items.bill_id=@bill_id)", e, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Sub categories", y0, y0, e, e, r), t.Field_Field$numeric(e, "@billAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Bill discount inc tax", h0, h0, "@bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@itemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Item discount inc tax", $0, $0, "@item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerBillAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount inc tax", I0, I0, "@layer_bill_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentInclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount inc tax", W0, W0, "@layer_item_adjustment_inclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@billAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Bill discount exc tax", Z, Z, "@bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@itemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Item discount exc tax", H0, H0, "@item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerBillAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer bill discount exc tax", v0, v0, "@layer_bill_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, "@layerItemAdjustmentExclusiveTaxTotal*IF(@isRefund, -1, 1)", !1, e, !1, "Layer item discount exc tax", S0, S0, "@layer_item_adjustment_exclusive_tax_total*CASE WHEN @is_refund THEN -1 ELSE 1 END", u.FIELD_ROLE_1, r), t.Field_Field$string(e, "IF(@variantId IS NULL OR @variantId = '', @productId, CONCAT(@productId, '/', @variantId))", !0, e, !1, !1, "Menu item ID", "menuItemId", e, "CASE WHEN @variant_id IS NULL OR @variant_id = '' THEN @product_id ELSE @product_id || '/' || @variant_id END", e, r), t.Field_Field$string("Special-price tier when a member/promotion PRICE_CHANGE effect set the item price (e.g. vip). Null for normal sales.", e, !1, e, !1, !1, "Price group", H1, H1, e, e, r), t.Field_Field$numeric(e, e, !1, e, !1, "Original price", X1, X1, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric(e, e, !1, e, !1, "Price", "price", "price", e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Sold price minus original price, per unit (not multiplied by quantity). Positive means marked up. Non-zero for member/promotion price tiers, open price (original price is 0, so this equals the full price) and manual overrides. Null when either side is unknown.", "@price - @originalPrice", !1, e, !1, "Price difference", "priceDifference", e, "@price - @original_price", u.FIELD_ROLE_1, r), t.Field_Field$string(e, e, !1, e, !1, !1, "Addons", "addons", e, "(select string_agg(distinct name || coalesce(' (' || nullif(variant_name, '') || ')', ''), ',' order by name || coalesce(' (' || nullif(variant_name, '') || ')', '')) from flatten_items where flatten_items.parent_id=@id and flatten_items.restaurant_id=@restaurant_id)", e, r), t.Field_Field$string("Catalog used at order time. Null means not recorded; an empty string means the base menu.", e, !1, e, !1, !1, "Catalog ID", k1, k1, e, u.FIELD_ROLE_5, r), t.Field_Field$numeric("Item price from the menu as resolved at order time, after catalog markup, catalog override and POS override, before bill-level repricing or adjustments.", e, !1, e, !1, "Menu item price", U1, U1, e, u.FIELD_ROLE_1, r), t.Field_Field$string("Catalog name recorded on the item at order time.", e, !1, e, !1, !1, "Catalog name", B0, B0, e, u.FIELD_ROLE_4, r), t.Field_Field$numeric("Price with the inclusive product tax of the layer-0 item removed. Equals price when that tax is exclusive or absent.", e, !1, e, !1, "Price (excl. tax)", O1, O1, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Original price with the inclusive product tax removed.", e, !1, e, !1, "Original price (excl. tax)", Ve, Ve, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Menu item price with the inclusive product tax removed.", e, !1, e, !1, "Menu item price (excl. tax)", je, je, e, u.FIELD_ROLE_1, r), t.Field_Field$numeric("Seconds from sent to kitchen until the last KDS station finished cooking. Null until every station of the item has finished, and on items with no KDS station.", e, !1, e, !1, "Kitchen preparation seconds", "kitchenPreparationSeconds", e, "ROUND(EXTRACT(EPOCH FROM ((select CASE WHEN count(*)=count(finished_at) THEN max(finished_at) END from kitchen_stations where kitchen_stations.bill_id=@bill_id and kitchen_stations.restaurant_id=@restaurant_id and kitchen_stations.item_id=@id)-@sent_at)),0)", u.FIELD_ROLE_1, r), t.Field_Field$string("Order pacing rule applied to the item at order time. Plumbing id; chart serveDelayName instead.", e, !0, e, !1, !1, "Serve later ID", Ke, Ke, e, e, r), t.Field_Field$string('Name of the order pacing (serve later) rule on the item, e.g. "30 mins" or "custom". Null when the item is served immediately.', e, !1, e, !1, !1, "Serve later", Ze, Ze, e, e, r), t.Field_Field$numeric("Minutes the kitchen was asked to hold the item before starting it (order pacing). Subtract from a prep-time target to exclude intentional delay. Null when the item is served immediately.", e, !1, e, !1, "Serve later delay (mins)", et, et, e, u.FIELD_ROLE_1, r)], d.JSArray_Field);
|
|
9329
9329
|
},
|
|
9330
9330
|
$signature: 0
|
|
9331
9331
|
}, t.flattenItemSchema_closure0.prototype = {
|
|
@@ -11246,6 +11246,7 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
|
|
|
11246
11246
|
Status: "Status of the parent order. Values: DRAFT, NEW, ACCEPTED, REJECTED, PENDING_PAYMENT",
|
|
11247
11247
|
Submis: "Submission period in year-month form, e.g. 2026-7",
|
|
11248
11248
|
Test__: 'Test, Invoice, Credit Note, Debit Note or Refund Note; Test when the document bill id is "test"',
|
|
11249
|
+
The_fo: "The food court order this stall bill is part of. One customer order at a food court splits into one bill per stall, all carrying the same id, so count distinct this id for food court orders, never bills. Null on a bill that did not come through a food court",
|
|
11249
11250
|
This_t: "This tender's share of the BCRS container deposit, split by received amount like SC. A pass-through, not sales or tax",
|
|
11250
11251
|
Time_t: "Time the order was placed. May be null on DRAFT orders",
|
|
11251
11252
|
ValuesD: "Values: DRAFT, NEW, ACCEPTED, REJECTED, PENDING_PAYMENT",
|
|
@@ -11487,8 +11488,8 @@ then EXTRACT(EPOCH FROM COALESCE(timesheets.ended_at,!end)-(timesheets.created_a
|
|
|
11487
11488
|
return a.message;
|
|
11488
11489
|
}
|
|
11489
11490
|
}())), e(q, "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))?)?)?$", !1)), e(q, "_hashSeed", "$get$_hashSeed", () => t.objectHashCode(u.Type_Object_xQ6)), e(q, "Endian_host", "$get$Endian_host", () => t.NativeByteData_NativeByteData$view(t.NativeUint16List_NativeUint16List$fromList(t._setArrayType([1], d.JSArray_int)).buffer, 0, null).getInt8(0) === 1 ? u.C_Endian0 : u.C_Endian), e(q, "_clockKey", "$get$_clockKey", () => new t.Object()), e(q, "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)), n(q, "_dateTimeSymbols", "$get$_dateTimeSymbols", () => t.UninitializedLocaleData$("initializeDateFormatting(<locale>)", q.$get$en_USSymbols())), n(q, "dateTimePatterns", "$get$dateTimePatterns", () => t.UninitializedLocaleData$("initializeDateFormatting(<locale>)", u.Map_EQ6TW)), e(q, "asciiZeroCodeUnit", "$get$asciiZeroCodeUnit", () => 48), e(q, "DateFormat__matchers", "$get$DateFormat__matchers", () => t._setArrayType([t.RegExp_RegExp("^'(?:[^']|'')*'", !1), t.RegExp_RegExp("^(?:G+|y+|M+|k+|S+|E+|a+|h+|K+|H+|c+|L+|Q+|d+|D+|m+|s+|v+|z+|Z+)", !1), t.RegExp_RegExp("^[^'GyMkSEahKHcLQdDmsvzZ]+", !1)], t.findType("JSArray<RegExp>"))), e(q, "_DateFormatQuotedField__twoEscapedQuotes", "$get$_DateFormatQuotedField__twoEscapedQuotes", () => t.RegExp_RegExp("''", !1)), e(q, "asciiDigitMatcher", "$get$asciiDigitMatcher", () => t.RegExp_RegExp("^\\d+", !1)), n(q, "_availableLocales", "$get$_availableLocales", () => {
|
|
11490
|
-
var a, i, s = t.EnLocale$(u.StartOfWeek_1), l = t.EnLocale$(u.StartOfWeek_1), p = t.EnLocale$(u.StartOfWeek_1), _ = t.EnLocale$(u.StartOfWeek_1), M = t.EnLocale$(u.StartOfWeek_1), b = t.EnLocale$(u.StartOfWeek_2), O = t.EnLocale$(u.StartOfWeek_2), D = t.EnLocale$(u.StartOfWeek_1), $ = t.EnLocale$(u.StartOfWeek_1), E = t.EsLocale$(u.StartOfWeek_2), g = t.EsLocale$(u.StartOfWeek_2), h = t.EsLocale$(u.StartOfWeek_1), R = t.FrLocale$(u.StartOfWeek_2), C = t.FrLocale$(u.StartOfWeek_2), W = t.FrLocale$(u.StartOfWeek_1), B = t.ZhCnLocale$(u.StartOfWeek_1), I = t.ZhCnLocale$(u.StartOfWeek_1), x = t.ZhLocale$(u.StartOfWeek_1), w = t.ZhLocale$(u.StartOfWeek_1), v = t.DeLocale$(u.StartOfWeek_2),
|
|
11491
|
-
return t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), a = t.PtLocale$(u.StartOfWeek_2), i = 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", p, "en_au", _, "en_ca", M, "en_gb", b, "en_ie", O, "en_il", D, "en_nz", $, "es", E, "es_do", g, "es_us", h, "fr", R, "fr_ch", C, "fr_ca", W, "zh", B, "zh_cn", I, "zh_hk", x, "zh_tw", w, "de", v, "de_de",
|
|
11491
|
+
var a, i, s = t.EnLocale$(u.StartOfWeek_1), l = t.EnLocale$(u.StartOfWeek_1), p = t.EnLocale$(u.StartOfWeek_1), _ = t.EnLocale$(u.StartOfWeek_1), M = t.EnLocale$(u.StartOfWeek_1), b = t.EnLocale$(u.StartOfWeek_2), O = t.EnLocale$(u.StartOfWeek_2), D = t.EnLocale$(u.StartOfWeek_1), $ = t.EnLocale$(u.StartOfWeek_1), E = t.EsLocale$(u.StartOfWeek_2), g = t.EsLocale$(u.StartOfWeek_2), h = t.EsLocale$(u.StartOfWeek_1), R = t.FrLocale$(u.StartOfWeek_2), C = t.FrLocale$(u.StartOfWeek_2), W = t.FrLocale$(u.StartOfWeek_1), B = t.ZhCnLocale$(u.StartOfWeek_1), I = t.ZhCnLocale$(u.StartOfWeek_1), x = t.ZhLocale$(u.StartOfWeek_1), w = t.ZhLocale$(u.StartOfWeek_1), v = t.DeLocale$(u.StartOfWeek_2), H = t.DeLocale$(u.StartOfWeek_2), j = t.DeLocale$(u.StartOfWeek_2), s0 = t.DeLocale$(u.StartOfWeek_2), u0 = t.ItLocale$(u.StartOfWeek_2), z0 = t.ItLocale$(u.StartOfWeek_2), y0 = t.ArLyLocale$(!0, u.StartOfWeek_0), h0 = t.ArLyLocale$(!1, u.StartOfWeek_0), $0 = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), I0 = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_1), W0 = t.ArSaMaDzKwTnLocale$(!0, u.StartOfWeek_1), Z = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0), H0 = t.ArSaMaDzKwTnLocale$(!1, u.StartOfWeek_0);
|
|
11492
|
+
return t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), t.createSentinel(), a = t.PtLocale$(u.StartOfWeek_2), i = 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", p, "en_au", _, "en_ca", M, "en_gb", b, "en_ie", O, "en_il", D, "en_nz", $, "es", E, "es_do", g, "es_us", h, "fr", R, "fr_ch", C, "fr_ca", W, "zh", B, "zh_cn", I, "zh_hk", x, "zh_tw", w, "de", v, "de_de", H, "de_at", j, "de_ch", s0, "it", u0, "it_ch", z0, "ar", y0, "ar_ly", h0, "ar_dz", $0, "ar_kw", I0, "ar_sa", W0, "ar_ma", Z, "ar_tn", H0, "az", new t.AzLocale(), "id", new t.IdLocale(), "ja", new t.JaLocale(), "ko", new t.KoLocale(), "ru", new t.RuLocale(), "uk", new t.UkLocale(), "hi", new t.HiLocale(), "pt", a, "pt_br", i, "pl", new t.PlLocale(), "tr", new t.TrLocale(), "sv", new t.SvLocale(), "nb", new t.NbLocale(), "fa", new t.FaLocale(), "bn", new t.BnLocale(), "nl", new t.NlLocale(), "th", new t.ThLocale()], d.String, t.findType("Locale"));
|
|
11492
11493
|
}), e(q, "addonFlattenItemSchema", "$get$addonFlattenItemSchema", () => {
|
|
11493
11494
|
var a = "createdAt", i = null, s = t.Source_Source$couchdb("", ""), l = t.TopLevelFilters$(t._setArrayType([t.Permission_Permission$restaurant("restaurantId")], d.JSArray_Permission), a);
|
|
11494
11495
|
return t.Schema_Schema$build(!1, "sales", u.List_empty, 3, i, t._setArrayType(["restaurantId"], d.JSArray_String), "flatten_item under an addon-oriented name for classic joins — query flatten_item directly instead.", new t.addonFlattenItemSchema_closure(), u.List_empty0, i, i, i, !0, !1, !1, !1, !0, !1, new t.addonFlattenItemSchema_closure0(), "Addon", "flatten_items", "flatten_item", u.MERGE_FILTER_TYPE_0, u.SCHEMA_NAME_7, a, i, "", "", i, !0, s, u.List_empty1, i, l);
|
|
@@ -12338,12 +12339,12 @@ var Ar = Or, Ot = {};
|
|
|
12338
12339
|
try {
|
|
12339
12340
|
throw new Error();
|
|
12340
12341
|
} catch (e0) {
|
|
12341
|
-
var P = e0.stack, J = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"),
|
|
12342
|
+
var P = e0.stack, J = new RegExp("^ *at [^(]*\\((.*):[0-9]*:[0-9]*\\)$", "mg"), X = null;
|
|
12342
12343
|
do {
|
|
12343
12344
|
var Y = J.exec(P);
|
|
12344
|
-
Y != null && (
|
|
12345
|
+
Y != null && (X = Y);
|
|
12345
12346
|
} while (Y != null);
|
|
12346
|
-
return
|
|
12347
|
+
return X[1];
|
|
12347
12348
|
}
|
|
12348
12349
|
}
|
|
12349
12350
|
var N = null;
|
|
@@ -12378,7 +12379,7 @@ var Ar = Or, Ot = {};
|
|
|
12378
12379
|
function J(e, n) {
|
|
12379
12380
|
Object.assign(n, e);
|
|
12380
12381
|
}
|
|
12381
|
-
var
|
|
12382
|
+
var X = function() {
|
|
12382
12383
|
var e = function() {
|
|
12383
12384
|
};
|
|
12384
12385
|
e.prototype = { p: {} };
|
|
@@ -12399,7 +12400,7 @@ var Ar = Or, Ot = {};
|
|
|
12399
12400
|
}();
|
|
12400
12401
|
function Y(e, n) {
|
|
12401
12402
|
if (e.prototype.constructor = e, e.prototype["$is" + e.name] = e, n != null) {
|
|
12402
|
-
if (
|
|
12403
|
+
if (X) {
|
|
12403
12404
|
e.prototype.__proto__ = n.prototype;
|
|
12404
12405
|
return;
|
|
12405
12406
|
}
|
|
@@ -12492,7 +12493,7 @@ var Ar = Or, Ot = {};
|
|
|
12492
12493
|
var O = M0(e, !1, a, i, s, l, p, _, M, !!b), D = w0(a, O);
|
|
12493
12494
|
e[n] = D;
|
|
12494
12495
|
}
|
|
12495
|
-
function
|
|
12496
|
+
function q0(e) {
|
|
12496
12497
|
var n = T.interceptorsByTag;
|
|
12497
12498
|
if (!n) {
|
|
12498
12499
|
T.interceptorsByTag = e;
|
|
@@ -12525,7 +12526,7 @@ var Ar = Or, Ot = {};
|
|
|
12525
12526
|
return n0(p, _, a, i, s, [M], b, l);
|
|
12526
12527
|
};
|
|
12527
12528
|
};
|
|
12528
|
-
return { inherit: Y, inheritMany: e0, mixin: i0, mixinHard: p0, installStaticTearOff: n0, installInstanceTearOff: C0, _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: n(0, null, ["call$0"], 0), _static_1: n(1, null, ["call$1"], 0), _static_2: n(2, null, ["call$2"], 0), makeConstList: _0, lazy: U, lazyFinal: V, lazyOld: o0, updateHolder: a0, convertToFastObject: L0, updateTypes: c0, setOrUpdateInterceptorsByTag:
|
|
12529
|
+
return { inherit: Y, inheritMany: e0, mixin: i0, mixinHard: p0, installStaticTearOff: n0, installInstanceTearOff: C0, _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: n(0, null, ["call$0"], 0), _static_1: n(1, null, ["call$1"], 0), _static_2: n(2, null, ["call$2"], 0), makeConstList: _0, lazy: U, lazyFinal: V, lazyOld: o0, updateHolder: a0, convertToFastObject: L0, updateTypes: c0, setOrUpdateInterceptorsByTag: q0, setOrUpdateLeafTags: d0 };
|
|
12529
12530
|
}(), o = {
|
|
12530
12531
|
JS_CONST: function() {
|
|
12531
12532
|
},
|
|
@@ -12575,8 +12576,8 @@ var Ar = Or, Ot = {};
|
|
|
12575
12576
|
}
|
|
12576
12577
|
},
|
|
12577
12578
|
Sort__dualPivotQuicksort(e, n, a, i) {
|
|
12578
|
-
var s, l, p, _, M, b, O, D, $, E, g = z.JSInt_methods._tdivFast$1(a - n + 1, 6), h = n + g, R = a - g, C = z.JSInt_methods._tdivFast$1(n + a, 2), W = C - g, B = C + g, I = u.getInterceptor$asx(e), x = I.$index(e, h), w = I.$index(e, W), v = I.$index(e, C),
|
|
12579
|
-
if (i.call$2(x, w) > 0 && (s = w, w = x, x = s), i.call$2(
|
|
12579
|
+
var s, l, p, _, M, b, O, D, $, E, g = z.JSInt_methods._tdivFast$1(a - n + 1, 6), h = n + g, R = a - g, C = z.JSInt_methods._tdivFast$1(n + a, 2), W = C - g, B = C + g, I = u.getInterceptor$asx(e), x = I.$index(e, h), w = I.$index(e, W), v = I.$index(e, C), H = I.$index(e, B), j = I.$index(e, R);
|
|
12580
|
+
if (i.call$2(x, w) > 0 && (s = w, w = x, x = s), i.call$2(H, j) > 0 && (s = j, j = H, H = s), i.call$2(x, v) > 0 && (s = v, v = x, x = s), i.call$2(w, v) > 0 && (s = v, v = w, w = s), i.call$2(x, H) > 0 && (s = H, H = x, x = s), i.call$2(v, H) > 0 && (s = H, H = v, v = s), i.call$2(w, j) > 0 && (s = j, j = w, w = s), i.call$2(w, v) > 0 && (s = v, v = w, w = s), i.call$2(H, j) > 0 && (s = j, j = H, H = s), I.$indexSet(e, h, x), I.$indexSet(e, C, v), I.$indexSet(e, R, j), I.$indexSet(e, W, I.$index(e, n)), I.$indexSet(e, B, I.$index(e, a)), l = n + 1, p = a - 1, u.$eq$(i.call$2(w, H), 0)) {
|
|
12580
12581
|
for (_ = l; _ <= p; ++_)
|
|
12581
12582
|
if (M = I.$index(e, _), b = i.call$2(M, w), b !== 0)
|
|
12582
12583
|
if (b < 0)
|
|
@@ -12598,9 +12599,9 @@ var Ar = Or, Ot = {};
|
|
|
12598
12599
|
for (_ = l; _ <= p; ++_)
|
|
12599
12600
|
if (M = I.$index(e, _), i.call$2(M, w) < 0)
|
|
12600
12601
|
_ !== l && (I.$indexSet(e, _, I.$index(e, l)), I.$indexSet(e, l, M)), ++l;
|
|
12601
|
-
else if (i.call$2(M,
|
|
12602
|
+
else if (i.call$2(M, H) > 0)
|
|
12602
12603
|
for (; ; )
|
|
12603
|
-
if (i.call$2(I.$index(e, p),
|
|
12604
|
+
if (i.call$2(I.$index(e, p), H) > 0) {
|
|
12604
12605
|
if (--p, p < _)
|
|
12605
12606
|
break;
|
|
12606
12607
|
continue;
|
|
@@ -12610,18 +12611,18 @@ var Ar = Or, Ot = {};
|
|
|
12610
12611
|
}
|
|
12611
12612
|
$ = !1;
|
|
12612
12613
|
}
|
|
12613
|
-
if (E = l - 1, I.$indexSet(e, n, I.$index(e, E)), I.$indexSet(e, E, w), E = p + 1, I.$indexSet(e, a, I.$index(e, E)), I.$indexSet(e, E,
|
|
12614
|
+
if (E = l - 1, I.$indexSet(e, n, I.$index(e, E)), I.$indexSet(e, E, w), E = p + 1, I.$indexSet(e, a, I.$index(e, E)), I.$indexSet(e, E, H), o.Sort__doSort(e, n, l - 2, i), o.Sort__doSort(e, p + 2, a, i), !$)
|
|
12614
12615
|
if (l < h && p > R) {
|
|
12615
12616
|
for (; u.$eq$(i.call$2(I.$index(e, l), w), 0); )
|
|
12616
12617
|
++l;
|
|
12617
|
-
for (; u.$eq$(i.call$2(I.$index(e, p),
|
|
12618
|
+
for (; u.$eq$(i.call$2(I.$index(e, p), H), 0); )
|
|
12618
12619
|
--p;
|
|
12619
12620
|
for (_ = l; _ <= p; ++_)
|
|
12620
12621
|
if (M = I.$index(e, _), i.call$2(M, w) === 0)
|
|
12621
12622
|
_ !== l && (I.$indexSet(e, _, I.$index(e, l)), I.$indexSet(e, l, M)), ++l;
|
|
12622
|
-
else if (i.call$2(M,
|
|
12623
|
+
else if (i.call$2(M, H) === 0)
|
|
12623
12624
|
for (; ; )
|
|
12624
|
-
if (i.call$2(I.$index(e, p),
|
|
12625
|
+
if (i.call$2(I.$index(e, p), H) === 0) {
|
|
12625
12626
|
if (--p, p < _)
|
|
12626
12627
|
break;
|
|
12627
12628
|
continue;
|
|
@@ -12986,8 +12987,8 @@ var Ar = Or, Ot = {};
|
|
|
12986
12987
|
var n, a, i, s, l, p, _, M, b, O, D = e.co, $ = e.iS, E = e.iI, g = e.nDA, h = e.aI, R = e.fs, C = e.cs, W = R[0], B = C[0], I = D[W], x = e.fT;
|
|
12987
12988
|
for (x.toString, n = Object.create($ ? new o.StaticClosure().constructor.prototype : new o.BoundClosure(null, null).constructor.prototype), n.$initialize = n.constructor, $ ? a = function() {
|
|
12988
12989
|
this.$initialize();
|
|
12989
|
-
} : a = function(v,
|
|
12990
|
-
this.$initialize(v,
|
|
12990
|
+
} : a = function(v, H) {
|
|
12991
|
+
this.$initialize(v, H);
|
|
12991
12992
|
}, n.constructor = a, a.prototype = n, n.$_name = W, n.$_target = I, i = !$, i ? s = o.Closure_forwardCallTo(W, I, E, g) : (n.$static_name = W, s = I), n.$signature = o.Closure__computeSignatureFunctionNewRti(x, $, E), n[B] = s, l = s, p = 1; p < R.length; ++p)
|
|
12992
12993
|
_ = R[p], typeof _ == "string" ? (M = D[_], b = _, _ = M) : b = "", O = C[p], O != null && (i && (_ = o.Closure_forwardCallTo(b, _, E, g)), n[O] = _), p === h && (l = _);
|
|
12993
12994
|
return n["call*"] = l, n.$requiredArgCount = e.rC, n.$defaultValues = e.dV, a;
|
|
@@ -13723,24 +13724,24 @@ var Ar = Or, Ot = {};
|
|
|
13723
13724
|
return l + "})";
|
|
13724
13725
|
},
|
|
13725
13726
|
_functionRtiToString(e, n, a) {
|
|
13726
|
-
var i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
13727
|
+
var i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H = ", ";
|
|
13727
13728
|
if (a != null) {
|
|
13728
13729
|
for (i = a.length, n == null ? (n = o._setArrayType([], r.JSArray_String), s = null) : s = n.length, l = n.length, p = i; p > 0; --p)
|
|
13729
13730
|
n.push("T" + (l + p));
|
|
13730
|
-
for (_ = r.nullable_Object, M = r.legacy_Object, b = "<", O = "", p = 0; p < i; ++p, O =
|
|
13731
|
+
for (_ = r.nullable_Object, M = r.legacy_Object, b = "<", O = "", p = 0; p < i; ++p, O = H)
|
|
13731
13732
|
b = z.JSString_methods.$add(b + O, n[n.length - 1 - p]), D = a[p], $ = D._kind, $ === 2 || $ === 3 || $ === 4 || $ === 5 || D === _ ? E = !0 : D !== M ? E = !1 : E = !0, E || (b += " extends " + o._rtiToString(D, n));
|
|
13732
13733
|
b += ">";
|
|
13733
13734
|
} else
|
|
13734
13735
|
b = "", s = null;
|
|
13735
|
-
for (_ = e._primary, g = e._rest, h = g._requiredPositional, R = h.length, C = g._optionalPositional, W = C.length, B = g._named, I = B.length, x = o._rtiToString(_, n), w = "", v = "", p = 0; p < R; ++p, v =
|
|
13736
|
+
for (_ = e._primary, g = e._rest, h = g._requiredPositional, R = h.length, C = g._optionalPositional, W = C.length, B = g._named, I = B.length, x = o._rtiToString(_, n), w = "", v = "", p = 0; p < R; ++p, v = H)
|
|
13736
13737
|
w += v + o._rtiToString(h[p], n);
|
|
13737
13738
|
if (W > 0) {
|
|
13738
|
-
for (w += v + "[", v = "", p = 0; p < W; ++p, v =
|
|
13739
|
+
for (w += v + "[", v = "", p = 0; p < W; ++p, v = H)
|
|
13739
13740
|
w += v + o._rtiToString(C[p], n);
|
|
13740
13741
|
w += "]";
|
|
13741
13742
|
}
|
|
13742
13743
|
if (I > 0) {
|
|
13743
|
-
for (w += v + "{", v = "", p = 0; p < I; p += 3, v =
|
|
13744
|
+
for (w += v + "{", v = "", p = 0; p < I; p += 3, v = H)
|
|
13744
13745
|
w += v, B[p + 1] && (w += "required "), w += o._rtiToString(B[p + 2], n) + " " + B[p];
|
|
13745
13746
|
w += "}";
|
|
13746
13747
|
}
|
|
@@ -14102,7 +14103,7 @@ var Ar = Or, Ot = {};
|
|
|
14102
14103
|
return M === 12 ? n === r.JavaScriptFunction ? !0 : l ? !1 : o._isFunctionSubtype(e, n, a, i, s) : p === 9 ? M !== 9 ? !1 : o._isInterfaceSubtype(e, n, a, i, s) : (l = p === 11, l && i === r.Record ? !0 : l && M === 11 ? o._isRecordSubtype(e, n, a, i, s) : !1);
|
|
14103
14104
|
},
|
|
14104
14105
|
_isFunctionSubtype(e, n, a, i, s) {
|
|
14105
|
-
var l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
14106
|
+
var l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0;
|
|
14106
14107
|
if (!o._isSubtype(e, n._primary, a, i._primary, s) || (l = n._rest, p = i._rest, _ = l._requiredPositional, M = p._requiredPositional, b = _.length, O = M.length, b > O) || (D = O - b, $ = l._optionalPositional, E = p._optionalPositional, g = $.length, h = E.length, b + g < O + h))
|
|
14107
14108
|
return !1;
|
|
14108
14109
|
for (R = 0; R < b; ++R)
|
|
@@ -14115,10 +14116,10 @@ var Ar = Or, Ot = {};
|
|
|
14115
14116
|
if (C = $[D + R], !o._isSubtype(e, E[R], s, C, a))
|
|
14116
14117
|
return !1;
|
|
14117
14118
|
for (W = l._named, B = p._named, I = W.length, x = B.length, w = 0, v = 0; v < x; v += 3)
|
|
14118
|
-
for (
|
|
14119
|
-
if (w >= I || (j = W[w], w += 3,
|
|
14119
|
+
for (H = B[v]; ; ) {
|
|
14120
|
+
if (w >= I || (j = W[w], w += 3, H < j))
|
|
14120
14121
|
return !1;
|
|
14121
|
-
if (s0 = W[w - 2], j <
|
|
14122
|
+
if (s0 = W[w - 2], j < H) {
|
|
14122
14123
|
if (s0)
|
|
14123
14124
|
return !1;
|
|
14124
14125
|
continue;
|
|
@@ -15570,7 +15571,7 @@ var Ar = Or, Ot = {};
|
|
|
15570
15571
|
return e instanceof o.BaseXYDatasourceConfigModel && e.isCumulative === !0 ? a = !0 : a = e instanceof o.ScorecardDatasourceConfigModel && e.isCumulative, a ? (a = r.XYDatasetModel, o.List_List$of(o.ListExtensions_mapIndexed(n, new o.accumulate_closure(e), a, a), !0, a)) : n;
|
|
15571
15572
|
},
|
|
15572
15573
|
formatBaseXYChartData(e, n, a, i, s) {
|
|
15573
|
-
var l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
15574
|
+
var l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H, j, s0, u0, z0, y0, h0, $0, I0, W0, Z, H0, v0, S0 = null;
|
|
15574
15575
|
if (a.length === 0)
|
|
15575
15576
|
return l = o._setArrayType([], r.JSArray_String), p = o._setArrayType([], r.JSArray_XYDatasetModel), _ = o.IterableExtension_get_firstOrNull(a), new o.BaseXYChartDataModel(e, l, p, new o.DateComparison(_ == null ? S0 : _.dateRange, S0));
|
|
15576
15577
|
for (M = z.JSArray_methods.get$first(a).columns, l = o._arrayInstanceType(M), p = l._eval$1("WhereIterable<1>"), b = o.List_List$of(new o.WhereIterable(M, new o.formatBaseXYChartData_closure(), p), !0, p._eval$1("Iterable.E")), p = o._arrayInstanceType(b)._eval$1("WhereIterable<1>"), O = o.List_List$of(new o.WhereIterable(b, new o.formatBaseXYChartData_closure0(), p), !0, p._eval$1("Iterable.E")), p = r.QueryResponse, D = o._formatRows(o.ListExtension_sublistOrEmpty(a, 0, 1, p), s), $ = o._formatRows(o.ListExtension_sublistOrEmpty(a, 1, 2, p), s), $.length !== 0 && (l = l._eval$1("MappedListIterable<1,ComparisonDataColumn>"), E = o.List_List$of(new o.MappedListIterable(M, new o.formatBaseXYChartData_closure1(), l), !0, l._eval$1("ListIterable.E")), g = o.compare(new o.ComparisonData(E, $), new o.ComparisonData(E, D)), $ = g.comparison, D = g.main), l = r.String, p = o.LinkedHashMap_LinkedHashMap$_empty(l, r.bool), _ = O.length, h = 0; R = O.length, h < R; O.length === _ || (0, o.throwConcurrentModificationError)(O), ++h)
|
|
@@ -15588,12 +15589,12 @@ var Ar = Or, Ot = {};
|
|
|
15588
15589
|
R.$indexSet(0, M[I].id, I);
|
|
15589
15590
|
R = new o.formatBaseXYChartData_expandRowsByMetric(z.JSArray_methods.indexWhere$1(M, new o.formatBaseXYChartData_closure4(n)), O, R, _, W, B), D = R.call$1(D), $.length !== 0 && ($ = R.call$1($));
|
|
15590
15591
|
}
|
|
15591
|
-
for (R = r.JSArray_String, v = o._setArrayType([], R),
|
|
15592
|
-
j = D[h], x = u.getInterceptor$asx(j), v.push(u.toString$0$(x.$index(j, 0))),
|
|
15593
|
-
for (R = o.LinkedHashSet_LinkedHashSet$from(v, l), v = o.List_List$of(R, !0, o._instanceType(R)._precomputed1), l = o.LinkedHashSet_LinkedHashSet$from(
|
|
15594
|
-
for (z0 = s0[h], y0 = o._setArrayType([], x),
|
|
15595
|
-
H0 = v[Z], v0 = o.IterableExtension_firstWhereOrNull(D, new o.formatBaseXYChartData_closure5(H0, z0)), y0.push(o._parseMetricValue(v0 == null ? S0 : o.ListExtension_elementAtOrNull(v0, 2), I0)), R.get$length($) !== 0 && (v0 = o.IterableExtension_firstWhereOrNull($, new o.formatBaseXYChartData_closure6(H0, z0)),
|
|
15596
|
-
u0.push(new o.XYDatasetModel(W0, !1, y0)),
|
|
15592
|
+
for (R = r.JSArray_String, v = o._setArrayType([], R), H = o._setArrayType([], R), R = D.length, h = 0; h < D.length; D.length === R || (0, o.throwConcurrentModificationError)(D), ++h)
|
|
15593
|
+
j = D[h], x = u.getInterceptor$asx(j), v.push(u.toString$0$(x.$index(j, 0))), H.push(u.toString$0$(x.$index(j, 1)));
|
|
15594
|
+
for (R = o.LinkedHashSet_LinkedHashSet$from(v, l), v = o.List_List$of(R, !0, o._instanceType(R)._precomputed1), l = o.LinkedHashSet_LinkedHashSet$from(H, l), s0 = o.List_List$of(l, !0, o._instanceType(l)._precomputed1), u0 = o._setArrayType([], r.JSArray_XYDatasetModel), l = s0.length, R = u.getInterceptor$asx($), x = r.JSArray_nullable_num, h = 0; h < s0.length; s0.length === l || (0, o.throwConcurrentModificationError)(s0), ++h) {
|
|
15595
|
+
for (z0 = s0[h], y0 = o._setArrayType([], x), h0 = o._setArrayType([], x), $0 = B.$index(0, z0), w = p.$index(0, $0 ?? z0), I0 = w === !0, w = W.$index(0, z0), W0 = w ?? _.$index(0, z0), W0 == null && (W0 = z0), w = v.length, Z = 0; Z < v.length; v.length === w || (0, o.throwConcurrentModificationError)(v), ++Z)
|
|
15596
|
+
H0 = v[Z], v0 = o.IterableExtension_firstWhereOrNull(D, new o.formatBaseXYChartData_closure5(H0, z0)), y0.push(o._parseMetricValue(v0 == null ? S0 : o.ListExtension_elementAtOrNull(v0, 2), I0)), R.get$length($) !== 0 && (v0 = o.IterableExtension_firstWhereOrNull($, new o.formatBaseXYChartData_closure6(H0, z0)), h0.push(o._parseMetricValue(v0 == null ? S0 : o.ListExtension_elementAtOrNull(v0, 2), I0)));
|
|
15597
|
+
u0.push(new o.XYDatasetModel(W0, !1, y0)), h0.length !== 0 && u0.push(new o.XYDatasetModel(W0, !0, h0));
|
|
15597
15598
|
}
|
|
15598
15599
|
return u0 = o.accumulate(n, u0), l = o.IterableExtension_get_firstOrNull(a), l = l == null ? S0 : l.dateRange, p = o.ListExtension_elementAtOrNull(a, 1), new o.BaseXYChartDataModel(e, v, u0, new o.DateComparison(l, p == null ? S0 : p.dateRange));
|
|
15599
15600
|
},
|
|
@@ -15802,16 +15803,16 @@ var Ar = Or, Ot = {};
|
|
|
15802
15803
|
return s = g.mainResponse, b = s.rows, O = o._arrayInstanceType(b)._eval$1("MappedListIterable<1,TableRowModel>"), s.copyWith$1$rows(o.List_List$of(new o.MappedListIterable(b, new o._formatTableData_closure3(), O), !0, O._eval$1("ListIterable.E")));
|
|
15803
15804
|
},
|
|
15804
15805
|
formatTableChartData(e, n, a, i) {
|
|
15805
|
-
var s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v,
|
|
15806
|
+
var s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w, v, H = {};
|
|
15806
15807
|
if (n.length === 0)
|
|
15807
15808
|
return new o.TableDataModel(o._setArrayType([], r.JSArray_TableRowModel), o._setArrayType([], r.JSArray_TableColumnModel));
|
|
15808
|
-
for (e.isBlend && (s = o.List_List$of(e.get$dimensions(), !0, r.QueryRequestDimension), z.JSArray_methods.addAll$1(s, z.JSArray_methods.fold$2(e.get$joinDatasources(), o._setArrayType([], r.JSArray_QueryRequestDimension), new o.formatTableChartData_closure())), l = o.List_List$of(e.get$metrics(), !0, r.QueryRequestMetric), z.JSArray_methods.addAll$1(l, z.JSArray_methods.fold$2(e.get$joinDatasources(), o._setArrayType([], r.JSArray_QueryRequestMetric), new o.formatTableChartData_closure0())), p = o._setArrayType([], r.JSArray_JoinDatasourceConfig), _ = e.rowsPerPage, M = e.get$columnIds(), b = e.get$rowIds(), O = e.get$drillDimension(), e = o.TableDatasourceConfigModel$(M, e.columnsWidth, s, O, e.filters, !0, e.isComparable, e.isDrillable, p, e.limit, l, e.periodType, e.rollup, e.rollupPosition, b, _, e.schemaNames, e.showGrandTotal, e.sorts, e.timezone)), D = e.get$joinDatasources().length + 1, s = r.QueryResponse, $ = o._formatTableData(e, o.ListExtension_sublistOrEmpty(n, 0, D, s), a, i), E =
|
|
15809
|
+
for (e.isBlend && (s = o.List_List$of(e.get$dimensions(), !0, r.QueryRequestDimension), z.JSArray_methods.addAll$1(s, z.JSArray_methods.fold$2(e.get$joinDatasources(), o._setArrayType([], r.JSArray_QueryRequestDimension), new o.formatTableChartData_closure())), l = o.List_List$of(e.get$metrics(), !0, r.QueryRequestMetric), z.JSArray_methods.addAll$1(l, z.JSArray_methods.fold$2(e.get$joinDatasources(), o._setArrayType([], r.JSArray_QueryRequestMetric), new o.formatTableChartData_closure0())), p = o._setArrayType([], r.JSArray_JoinDatasourceConfig), _ = e.rowsPerPage, M = e.get$columnIds(), b = e.get$rowIds(), O = e.get$drillDimension(), e = o.TableDatasourceConfigModel$(M, e.columnsWidth, s, O, e.filters, !0, e.isComparable, e.isDrillable, p, e.limit, l, e.periodType, e.rollup, e.rollupPosition, b, _, e.schemaNames, e.showGrandTotal, e.sorts, e.timezone)), D = e.get$joinDatasources().length + 1, s = r.QueryResponse, $ = o._formatTableData(e, o.ListExtension_sublistOrEmpty(n, 0, D, s), a, i), E = H.comparison = o._formatTableData(e, o.ListExtension_sublistOrEmpty(n, D, D * 2, s), a, i), s = E.rows, s.length !== 0 && (l = $.rows, p = o._arrayInstanceType(l)._eval$1("MappedListIterable<1,List<@>>"), p = o.List_List$of(new o.MappedListIterable(l, new o.formatTableChartData_closure1(), p), !0, p._eval$1("ListIterable.E")), _ = $.columns, M = o._arrayInstanceType(_)._eval$1("MappedListIterable<1,ComparisonDataColumn>"), M = o.List_List$of(new o.MappedListIterable(_, new o.formatTableChartData_closure2(), M), !0, M._eval$1("ListIterable.E")), _ = o._arrayInstanceType(s)._eval$1("MappedListIterable<1,List<@>>"), _ = o.List_List$of(new o.MappedListIterable(s, new o.formatTableChartData_closure3(), _), !0, _._eval$1("ListIterable.E")), b = E.columns, O = o._arrayInstanceType(b)._eval$1("MappedListIterable<1,ComparisonDataColumn>"), g = o.compare(new o.ComparisonData(o.List_List$of(new o.MappedListIterable(b, new o.formatTableChartData_closure4(), O), !0, O._eval$1("ListIterable.E")), _), new o.ComparisonData(M, p)), p = r.TableRowModel, l = o.ListExtensions_mapIndexed(l, new o.formatTableChartData_closure5(g), p, p), $ = $.copyWith$1$rows(o.List_List$of(l, !0, l.$ti._eval$1("Iterable.E"))), p = o.ListExtensions_mapIndexed(s, new o.formatTableChartData_closure6(g), p, p), H.comparison = E.copyWith$1$rows(o.List_List$of(p, !0, p.$ti._eval$1("Iterable.E")))), s = $.columns, l = o._arrayInstanceType(s)._eval$1("WhereIterable<1>"), h = o.List_List$of(new o.WhereIterable(s, new o.formatTableChartData_closure7(), l), !0, l._eval$1("Iterable.E")), l = r.String, p = r.int, R = o.LinkedHashMap_LinkedHashMap$_empty(l, p), C = 0; C < s.length; ++C)
|
|
15809
15810
|
W = s[C], R.$indexSet(0, W.key + "_" + W.hide, C);
|
|
15810
|
-
for (B = o.LinkedHashMap_LinkedHashMap$_empty(l, p), C = 0; s =
|
|
15811
|
+
for (B = o.LinkedHashMap_LinkedHashMap$_empty(l, p), C = 0; s = H.comparison.columns, C < s.length; ++C)
|
|
15811
15812
|
W = s[C], B.$indexSet(0, W.key + "_" + W.hide, C);
|
|
15812
15813
|
for (I = o._setArrayType([], r.JSArray__ColumnMapping), s = h.length, x = 0; x < s; ++x)
|
|
15813
15814
|
W = h[x], l = W.key, w = l + "_" + W.hide, l = o.stringReplaceAllUnchecked(l, ".", "_"), p = R.$index(0, w), p == null && (p = -1), _ = B.$index(0, w), I.push(new o._ColumnMapping(W, l, p, _ ?? -1));
|
|
15814
|
-
return s = r.MappedListIterable__ColumnMapping_TableColumnModel, v = o.List_List$of(new o.MappedListIterable(I, new o.formatTableChartData_closure8(), s), !0, s._eval$1("ListIterable.E")), s =
|
|
15815
|
+
return s = r.MappedListIterable__ColumnMapping_TableColumnModel, v = o.List_List$of(new o.MappedListIterable(I, new o.formatTableChartData_closure8(), s), !0, s._eval$1("ListIterable.E")), s = H.comparison.rows.length, l = r.TableRowModel, l = o.ListExtensions_mapIndexed($.rows, new o.formatTableChartData_closure9(H, I, a, i, s !== 0, s), l, l), $.copyWith$2$columns$rows(v, o.List_List$of(l, !0, l.$ti._eval$1("Iterable.E")));
|
|
15815
15816
|
},
|
|
15816
15817
|
_formatTableResponse_closure: function(n) {
|
|
15817
15818
|
this.config = n;
|
|
@@ -20057,18 +20058,18 @@ Arguments: [` + M + "]";
|
|
|
20057
20058
|
$signature: 0
|
|
20058
20059
|
}, o._formatTableResponse_closure5.prototype = {
|
|
20059
20060
|
call$2(e, n) {
|
|
20060
|
-
var a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w = null, v = r.JSArray_List_dynamic,
|
|
20061
|
+
var a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I, x, w = null, v = r.JSArray_List_dynamic, H = o._setArrayType([[]], v), j = o._setArrayType([[]], v);
|
|
20061
20062
|
for (v = this.headers, a = n.value, i = r.dynamic, s = r.JSArray_String, l = r.String, p = this.metricColumns, _ = 0; _ < v.length; ++_)
|
|
20062
20063
|
if (M = v[_], b = u.getInterceptor$ax(M), O = b.map$1$1(M, new o._formatTableResponse__closure4(), l).join$1(0, "|"), o.IterableExtension_firstWhereOrNull(M, new o._formatTableResponse__closure5()) != null)
|
|
20063
|
-
for (D = b.firstWhere$1(M, new o._formatTableResponse__closure6()), $ = b.fold$2(M, !0, new o._formatTableResponse__closure7(n)), b =
|
|
20064
|
-
R =
|
|
20064
|
+
for (D = b.firstWhere$1(M, new o._formatTableResponse__closure6()), $ = b.fold$2(M, !0, new o._formatTableResponse__closure7(n)), b = H.length, E = D.type, g = D.columnValue, h = 0; h < H.length; H.length === b || (0, o.throwConcurrentModificationError)(H), ++h)
|
|
20065
|
+
R = H[h], $ ? (C = a.$index(0, g), W = R.length, _ >= W && z.JSArray_methods.addAll$1(R, o.List_List$filled(_ - W + 1, w, !1, i)), R[_] = C) : (C = E == null ? w : o.DataTypeExtension_toData(E, w), W = R.length, _ >= W && z.JSArray_methods.addAll$1(R, o.List_List$filled(_ - W + 1, w, !1, i)), R[_] = C);
|
|
20065
20066
|
else if (z.JSArray_methods.contains$1(o._setArrayType(["_metric_name", "_metric_value"], s), O))
|
|
20066
20067
|
for (b = O === "_metric_value", E = O === "_metric_name", B = 0; B < p.length; ++B)
|
|
20067
|
-
I = p[B], o.ListExtension_elementAtOrNull(
|
|
20068
|
+
I = p[B], o.ListExtension_elementAtOrNull(H, B) == null && (H.push(o.List_List$of(H[0], !0, i)), j.push(o.List_List$of(j[0], !0, i))), E ? (g = H[B], C = I.label, W = g.length, _ >= W && z.JSArray_methods.addAll$1(g, o.List_List$filled(_ - W + 1, w, !1, i)), g[_] = C, j[B].push(C)) : b && (g = H[B], C = a.$index(0, I.id), W = g.length, _ >= W && z.JSArray_methods.addAll$1(g, o.List_List$filled(_ - W + 1, w, !1, i)), g[_] = C);
|
|
20068
20069
|
else
|
|
20069
|
-
for (x = 0; x <
|
|
20070
|
-
b =
|
|
20071
|
-
return u.addAll$1$ax(e, o.ListExtensions_mapIndexed(
|
|
20070
|
+
for (x = 0; x < H.length; ++x)
|
|
20071
|
+
b = H[x], E = a.$index(0, O), g = b.length, _ >= g && z.JSArray_methods.addAll$1(b, o.List_List$filled(_ - g + 1, w, !1, i)), b[_] = E, j[x].push(a.$index(0, O));
|
|
20072
|
+
return u.addAll$1$ax(e, o.ListExtensions_mapIndexed(H, new o._formatTableResponse__closure8(j, n), r.List_dynamic, r.Map_String_dynamic)), e;
|
|
20072
20073
|
},
|
|
20073
20074
|
$signature: 79
|
|
20074
20075
|
}, o._formatTableResponse__closure4.prototype = {
|
|
@@ -20307,9 +20308,9 @@ Arguments: [` + M + "]";
|
|
|
20307
20308
|
$signature: 99
|
|
20308
20309
|
}, o.formatTableChartData_closure9.prototype = {
|
|
20309
20310
|
call$2(e, n) {
|
|
20310
|
-
var a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I = this, x = [], w = [], v = n.cells,
|
|
20311
|
+
var a, i, s, l, p, _, M, b, O, D, $, E, g, h, R, C, W, B, I = this, x = [], w = [], v = n.cells, H = u.getInterceptor$asx(v), j = H.get$length(v);
|
|
20311
20312
|
for (a = I.columnMappings, i = a.length, s = I.hasComparison, l = I.country, p = I.timezone, _ = e < I.comparisonRowsLength, M = I._box_0, b = 0; b < a.length; a.length === i || (0, o.throwConcurrentModificationError)(a), ++b)
|
|
20312
|
-
O = a[b], D = O.mainIndex, $ = D >= 0 && D < j ?
|
|
20313
|
+
O = a[b], D = O.mainIndex, $ = D >= 0 && D < j ? H.$index(v, D) : o.ListExtension_elementAtOrNull(v, D), D = O.column, E = D.type, g = E == null, x.push(g ? null : o.DataTypeExtension_toDisplay(E, D.aggregationType, l, D.decimal, D.dimensionOption, D.formatter, !1, D.timeFormatter, p, $)), s && (_ ? (h = M.comparison.rows[e].cells, R = u.getInterceptor$asx(h), C = R.get$length(h), W = O.comparisonIndex, B = W >= 0 && W < C ? R.$index(h, W) : o.ListExtension_elementAtOrNull(h, W)) : B = o.ListExtension_elementAtOrNull([], O.comparisonIndex), w.push(g ? null : o.DataTypeExtension_toDisplay(E, D.aggregationType, l, D.decimal, D.dimensionOption, D.formatter, !1, D.timeFormatter, p, B)));
|
|
20313
20314
|
return n.copyWith$2$cells$comparisonCells(x, w);
|
|
20314
20315
|
},
|
|
20315
20316
|
$signature: 7
|
|
@@ -20748,8 +20749,8 @@ Arguments: [` + M + "]";
|
|
|
20748
20749
|
return i.message;
|
|
20749
20750
|
}
|
|
20750
20751
|
}())), n(L, "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))?)?)?$", !1)), n(L, "_hashSeed", "$get$_hashSeed", () => o.objectHashCode(z.Type_Object_xQ6)), n(L, "Endian_host", "$get$Endian_host", () => o.NativeByteData_NativeByteData$view(o.NativeUint16List_NativeUint16List$fromList(o._setArrayType([1], r.JSArray_int)).buffer, 0, null).getInt8(0) === 1 ? z.C_Endian0 : z.C_Endian), n(L, "_clockKey", "$get$_clockKey", () => new o.Object()), n(L, "en_USSymbols", "$get$en_USSymbols", () => new o.DateSymbols("en_US", z.List_BC_AD, z.List_6xs, z.List_qpm, z.List_qpm, z.List_cIc, z.List_cIc, z.List_h8w, z.List_h8w, z.List_wMy, z.List_wMy, z.List_gc6, z.List_gc6, z.List_3US, z.List_Q1_Q2_Q3_Q4, z.List_bJM, z.List_AM_PM)), a(L, "_dateTimeSymbols", "$get$_dateTimeSymbols", () => o.UninitializedLocaleData$("initializeDateFormatting(<locale>)", L.$get$en_USSymbols())), a(L, "dateTimePatterns", "$get$dateTimePatterns", () => o.UninitializedLocaleData$("initializeDateFormatting(<locale>)", z.Map_EQ6TW)), n(L, "asciiZeroCodeUnit", "$get$asciiZeroCodeUnit", () => 48), n(L, "DateFormat__matchers", "$get$DateFormat__matchers", () => o._setArrayType([o.RegExp_RegExp("^'(?:[^']|'')*'", !1), o.RegExp_RegExp("^(?:G+|y+|M+|k+|S+|E+|a+|h+|K+|H+|c+|L+|Q+|d+|D+|m+|s+|v+|z+|Z+)", !1), o.RegExp_RegExp("^[^'GyMkSEahKHcLQdDmsvzZ]+", !1)], o.findType("JSArray<RegExp>"))), n(L, "_DateFormatQuotedField__twoEscapedQuotes", "$get$_DateFormatQuotedField__twoEscapedQuotes", () => o.RegExp_RegExp("''", !1)), n(L, "asciiDigitMatcher", "$get$asciiDigitMatcher", () => o.RegExp_RegExp("^\\d+", !1)), a(L, "_availableLocales", "$get$_availableLocales", () => {
|
|
20751
|
-
var i, s, l = o.EnLocale$(z.StartOfWeek_1), p = o.EnLocale$(z.StartOfWeek_1), _ = o.EnLocale$(z.StartOfWeek_1), M = o.EnLocale$(z.StartOfWeek_1), b = o.EnLocale$(z.StartOfWeek_1), O = o.EnLocale$(z.StartOfWeek_2), D = o.EnLocale$(z.StartOfWeek_2), $ = o.EnLocale$(z.StartOfWeek_1), E = o.EnLocale$(z.StartOfWeek_1), g = o.EsLocale$(z.StartOfWeek_2), h = o.EsLocale$(z.StartOfWeek_2), R = o.EsLocale$(z.StartOfWeek_1), C = o.FrLocale$(z.StartOfWeek_2), W = o.FrLocale$(z.StartOfWeek_2), B = o.FrLocale$(z.StartOfWeek_1), I = o.ZhCnLocale$(z.StartOfWeek_1), x = o.ZhCnLocale$(z.StartOfWeek_1), w = o.ZhLocale$(z.StartOfWeek_1), v = o.ZhLocale$(z.StartOfWeek_1),
|
|
20752
|
-
return o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), i = o.PtLocale$(z.StartOfWeek_2), s = o.PtLocale$(z.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", p, "en_sg", _, "en_au", M, "en_ca", b, "en_gb", O, "en_ie", D, "en_il", $, "en_nz", E, "es", g, "es_do", h, "es_us", R, "fr", C, "fr_ch", W, "fr_ca", B, "zh", I, "zh_cn", x, "zh_hk", w, "zh_tw", v, "de",
|
|
20752
|
+
var i, s, l = o.EnLocale$(z.StartOfWeek_1), p = o.EnLocale$(z.StartOfWeek_1), _ = o.EnLocale$(z.StartOfWeek_1), M = o.EnLocale$(z.StartOfWeek_1), b = o.EnLocale$(z.StartOfWeek_1), O = o.EnLocale$(z.StartOfWeek_2), D = o.EnLocale$(z.StartOfWeek_2), $ = o.EnLocale$(z.StartOfWeek_1), E = o.EnLocale$(z.StartOfWeek_1), g = o.EsLocale$(z.StartOfWeek_2), h = o.EsLocale$(z.StartOfWeek_2), R = o.EsLocale$(z.StartOfWeek_1), C = o.FrLocale$(z.StartOfWeek_2), W = o.FrLocale$(z.StartOfWeek_2), B = o.FrLocale$(z.StartOfWeek_1), I = o.ZhCnLocale$(z.StartOfWeek_1), x = o.ZhCnLocale$(z.StartOfWeek_1), w = o.ZhLocale$(z.StartOfWeek_1), v = o.ZhLocale$(z.StartOfWeek_1), H = o.DeLocale$(z.StartOfWeek_2), j = o.DeLocale$(z.StartOfWeek_2), s0 = o.DeLocale$(z.StartOfWeek_2), u0 = o.DeLocale$(z.StartOfWeek_2), z0 = o.ItLocale$(z.StartOfWeek_2), y0 = o.ItLocale$(z.StartOfWeek_2), h0 = o.ArLyLocale$(!0, z.StartOfWeek_0), $0 = o.ArLyLocale$(!1, z.StartOfWeek_0), I0 = o.ArSaMaDzKwTnLocale$(!1, z.StartOfWeek_1), W0 = o.ArSaMaDzKwTnLocale$(!1, z.StartOfWeek_1), Z = o.ArSaMaDzKwTnLocale$(!0, z.StartOfWeek_1), H0 = o.ArSaMaDzKwTnLocale$(!1, z.StartOfWeek_0), v0 = o.ArSaMaDzKwTnLocale$(!1, z.StartOfWeek_0);
|
|
20753
|
+
return o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), o.createSentinel(), i = o.PtLocale$(z.StartOfWeek_2), s = o.PtLocale$(z.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", p, "en_sg", _, "en_au", M, "en_ca", b, "en_gb", O, "en_ie", D, "en_il", $, "en_nz", E, "es", g, "es_do", h, "es_us", R, "fr", C, "fr_ch", W, "fr_ca", B, "zh", I, "zh_cn", x, "zh_hk", w, "zh_tw", v, "de", H, "de_de", j, "de_at", s0, "de_ch", u0, "it", z0, "it_ch", y0, "ar", h0, "ar_ly", $0, "ar_dz", I0, "ar_kw", W0, "ar_sa", Z, "ar_ma", H0, "ar_tn", v0, "az", new o.AzLocale(z.StartOfWeek_2), "id", new o.IdLocale(z.StartOfWeek_1), "ja", new o.JaLocale(z.StartOfWeek_1), "ko", new o.KoLocale(z.StartOfWeek_1), "ru", new o.RuLocale(z.StartOfWeek_2), "uk", new o.UkLocale(z.StartOfWeek_2), "hi", new o.HiLocale(z.StartOfWeek_1), "pt", i, "pt_br", s, "pl", new o.PlLocale(z.StartOfWeek_2), "tr", new o.TrLocale(z.StartOfWeek_2), "sv", new o.SvLocale(z.StartOfWeek_2), "nb", new o.NbLocale(z.StartOfWeek_2), "fa", new o.FaLocale(z.StartOfWeek_0), "bn", new o.BnLocale(z.StartOfWeek_1), "nl", new o.NlLocale(z.StartOfWeek_2), "th", new o.ThLocale(z.StartOfWeek_1)], r.String, o.findType("Locale"));
|
|
20753
20754
|
}), n(L, "_UTC", "$get$_UTC", () => {
|
|
20754
20755
|
var i = r.JSArray_int;
|
|
20755
20756
|
return o.Location$("UTC", o._setArrayType([-864e13], i), o._setArrayType([0], i), o._setArrayType([z.TimeZone_0_false_UTC], r.JSArray_TimeZone));
|
|
@@ -20833,12 +20834,12 @@ function rt(c) {
|
|
|
20833
20834
|
/^(\d{1,2})\/(\d{1,2})\/(\d{4})\s+(\d{1,2}):(\d{2})(?::(\d{2}))?$/
|
|
20834
20835
|
);
|
|
20835
20836
|
if (m) {
|
|
20836
|
-
const [, J,
|
|
20837
|
+
const [, J, X, Y, e0, i0, p0 = "0"] = m;
|
|
20837
20838
|
return {
|
|
20838
20839
|
type: "fullDateTime",
|
|
20839
20840
|
value: new Date(
|
|
20840
20841
|
parseInt(Y),
|
|
20841
|
-
parseInt(
|
|
20842
|
+
parseInt(X) - 1,
|
|
20842
20843
|
parseInt(J),
|
|
20843
20844
|
parseInt(e0),
|
|
20844
20845
|
parseInt(i0),
|
|
@@ -20848,42 +20849,42 @@ function rt(c) {
|
|
|
20848
20849
|
}
|
|
20849
20850
|
const S = A.match(/^(\d{1,2})\/(\d{1,2})\/(\d{4})$/);
|
|
20850
20851
|
if (S) {
|
|
20851
|
-
const [, J,
|
|
20852
|
+
const [, J, X, Y] = S;
|
|
20852
20853
|
return {
|
|
20853
20854
|
type: "date",
|
|
20854
20855
|
value: new Date(
|
|
20855
20856
|
parseInt(Y),
|
|
20856
|
-
parseInt(
|
|
20857
|
+
parseInt(X) - 1,
|
|
20857
20858
|
parseInt(J)
|
|
20858
20859
|
).getTime()
|
|
20859
20860
|
};
|
|
20860
20861
|
}
|
|
20861
20862
|
const F = A.match(/^(\d{4})\/(\d{1,2})\/(\d{1,2})$/);
|
|
20862
20863
|
if (F) {
|
|
20863
|
-
const [, J,
|
|
20864
|
+
const [, J, X, Y] = F;
|
|
20864
20865
|
return {
|
|
20865
20866
|
type: "date",
|
|
20866
20867
|
value: new Date(
|
|
20867
20868
|
parseInt(J),
|
|
20868
|
-
parseInt(
|
|
20869
|
+
parseInt(X) - 1,
|
|
20869
20870
|
parseInt(Y)
|
|
20870
20871
|
).getTime()
|
|
20871
20872
|
};
|
|
20872
20873
|
}
|
|
20873
20874
|
const N = A.match(/^(\d{1,2})\/(\d{4})$/);
|
|
20874
20875
|
if (N) {
|
|
20875
|
-
const [, J,
|
|
20876
|
+
const [, J, X] = N;
|
|
20876
20877
|
return {
|
|
20877
20878
|
type: "monthYear",
|
|
20878
|
-
value: new Date(parseInt(
|
|
20879
|
+
value: new Date(parseInt(X), parseInt(J) - 1, 1).getTime()
|
|
20879
20880
|
};
|
|
20880
20881
|
}
|
|
20881
20882
|
const P = A.match(/^(\d{1,2}):(\d{2})(?::(\d{2}))?$/);
|
|
20882
20883
|
if (P) {
|
|
20883
|
-
const [, J,
|
|
20884
|
+
const [, J, X, Y = "0"] = P;
|
|
20884
20885
|
return {
|
|
20885
20886
|
type: "time",
|
|
20886
|
-
value: parseInt(J) * 3600 + parseInt(
|
|
20887
|
+
value: parseInt(J) * 3600 + parseInt(X) * 60 + parseInt(Y)
|
|
20887
20888
|
};
|
|
20888
20889
|
}
|
|
20889
20890
|
return /^\d+$/.test(A) ? { type: "number", value: parseInt(A) } : null;
|
|
@@ -20981,21 +20982,21 @@ function qr(c, A, f) {
|
|
|
20981
20982
|
return function(m, S) {
|
|
20982
20983
|
const F = ot(m), N = ot(S);
|
|
20983
20984
|
for (const { key: P, type: J } of c) {
|
|
20984
|
-
const
|
|
20985
|
+
const X = J === "ASC" ? 1 : -1, Y = nt(F, P, f) ?? "", e0 = nt(N, P, f) ?? "";
|
|
20985
20986
|
if (A[P]) {
|
|
20986
20987
|
const i0 = at(Y), p0 = at(e0);
|
|
20987
20988
|
if (i0 !== null && p0 !== null) {
|
|
20988
20989
|
const U = i0 - p0;
|
|
20989
|
-
if (U !== 0) return U *
|
|
20990
|
+
if (U !== 0) return U * X;
|
|
20990
20991
|
}
|
|
20991
20992
|
const o0 = tt.compare(String(Y), String(e0));
|
|
20992
|
-
if (o0 !== 0) return o0 *
|
|
20993
|
+
if (o0 !== 0) return o0 * X;
|
|
20993
20994
|
} else {
|
|
20994
20995
|
const i0 = fr(Y, e0);
|
|
20995
20996
|
if (i0 !== null && i0 !== 0)
|
|
20996
|
-
return i0 *
|
|
20997
|
+
return i0 * X;
|
|
20997
20998
|
const p0 = tt.compare(String(Y), String(e0));
|
|
20998
|
-
if (p0 !== 0) return p0 *
|
|
20999
|
+
if (p0 !== 0) return p0 * X;
|
|
20999
21000
|
}
|
|
21000
21001
|
}
|
|
21001
21002
|
return 0;
|
|
@@ -21034,9 +21035,9 @@ function hr(c) {
|
|
|
21034
21035
|
S === "BOTTOM" && ((p0 = P.at(-1)) != null && p0.isRollup) && P.pop(), S === "TOP" && ((o0 = P[0]) != null && o0.isRollup) && P.shift();
|
|
21035
21036
|
const J = {};
|
|
21036
21037
|
for (const U of f) J[U.key] = U.type === "NUMERIC";
|
|
21037
|
-
const
|
|
21038
|
+
const X = y.filter(
|
|
21038
21039
|
(U) => U.key && f.some((V) => V.key === U.key)
|
|
21039
|
-
), Y =
|
|
21040
|
+
), Y = X.length > 0;
|
|
21040
21041
|
let e0 = P;
|
|
21041
21042
|
m !== null && (e0 = e0.filter((U) => !(m !== "" && (U.isRollup === !0 || !U.cells.some(
|
|
21042
21043
|
(V) => (String(V ?? "").toLowerCase() || "").includes(
|
|
@@ -21046,7 +21047,7 @@ function hr(c) {
|
|
|
21046
21047
|
let i0 = e0;
|
|
21047
21048
|
if (Y) {
|
|
21048
21049
|
const U = (F ?? S ?? gr(e0)) === "BOTTOM", V = mr(e0, U);
|
|
21049
|
-
zt(V, qr(
|
|
21050
|
+
zt(V, qr(X, J, f)), i0 = fe(V, U, []);
|
|
21050
21051
|
} else
|
|
21051
21052
|
i0 = [...e0];
|
|
21052
21053
|
if (N > 0) {
|
|
@@ -21424,7 +21425,7 @@ function Yr(c) {
|
|
|
21424
21425
|
return y.priority - m.priority;
|
|
21425
21426
|
}), A;
|
|
21426
21427
|
}
|
|
21427
|
-
var gt = /\d/, P0 = /\d\d/, ht = /\d{3}/, Ie = /\d{4}/, oe = /[+-]?\d{6}/,
|
|
21428
|
+
var gt = /\d/, P0 = /\d\d/, ht = /\d{3}/, Ie = /\d{4}/, oe = /[+-]?\d{6}/, m0 = /\d\d?/, St = /\d\d\d\d?/, Tt = /\d\d\d\d\d\d?/, se = /\d{1,3}/, We = /\d{1,4}/, ue = /[+-]?\d{1,6}/, h1 = /\d+/, le = /[+-]?\d+/, Gr = /Z|[+-]\d\d:?\d\d/gi, pe = /Z|[+-]\d\d(?::?\d\d)?/gi, Qr = /[+-]?\d+(\.\d{1,3})?/, P1 = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i, S1 = /^[1-9]\d?/, Be = /^([1-9]\d|\d)/, Z1;
|
|
21428
21429
|
Z1 = {};
|
|
21429
21430
|
function Q(c, A, f) {
|
|
21430
21431
|
Z1[c] = t1(A) ? A : function(y, m) {
|
|
@@ -21485,7 +21486,7 @@ K(0, ["YYYY", 4], 0, "year");
|
|
|
21485
21486
|
K(0, ["YYYYY", 5], 0, "year");
|
|
21486
21487
|
K(0, ["YYYYYY", 6, !0], 0, "year");
|
|
21487
21488
|
Q("Y", le);
|
|
21488
|
-
Q("YY",
|
|
21489
|
+
Q("YY", m0, P0);
|
|
21489
21490
|
Q("YYYY", We, Ie);
|
|
21490
21491
|
Q("YYYYY", ue, oe);
|
|
21491
21492
|
Q("YYYYYY", ue, oe);
|
|
@@ -21600,8 +21601,8 @@ K("MMM", 0, 0, function(c) {
|
|
|
21600
21601
|
K("MMMM", 0, 0, function(c) {
|
|
21601
21602
|
return this.localeData().months(this, c);
|
|
21602
21603
|
});
|
|
21603
|
-
Q("M",
|
|
21604
|
-
Q("MM",
|
|
21604
|
+
Q("M", m0, S1);
|
|
21605
|
+
Q("MM", m0, P0);
|
|
21605
21606
|
Q("MMM", function(c, A) {
|
|
21606
21607
|
return A.monthsShortRegex(c);
|
|
21607
21608
|
});
|
|
@@ -21724,10 +21725,10 @@ function u1(c, A, f) {
|
|
|
21724
21725
|
}
|
|
21725
21726
|
K("w", ["ww", 2], "wo", "week");
|
|
21726
21727
|
K("W", ["WW", 2], "Wo", "isoWeek");
|
|
21727
|
-
Q("w",
|
|
21728
|
-
Q("ww",
|
|
21729
|
-
Q("W",
|
|
21730
|
-
Q("WW",
|
|
21728
|
+
Q("w", m0, S1);
|
|
21729
|
+
Q("ww", m0, P0);
|
|
21730
|
+
Q("W", m0, S1);
|
|
21731
|
+
Q("WW", m0, P0);
|
|
21731
21732
|
J1(
|
|
21732
21733
|
["w", "ww", "W", "WW"],
|
|
21733
21734
|
function(c, A, f, y) {
|
|
@@ -21769,9 +21770,9 @@ K("dddd", 0, 0, function(c) {
|
|
|
21769
21770
|
});
|
|
21770
21771
|
K("e", 0, 0, "weekday");
|
|
21771
21772
|
K("E", 0, 0, "isoWeekday");
|
|
21772
|
-
Q("d",
|
|
21773
|
-
Q("e",
|
|
21774
|
-
Q("E",
|
|
21773
|
+
Q("d", m0);
|
|
21774
|
+
Q("e", m0);
|
|
21775
|
+
Q("E", m0);
|
|
21775
21776
|
Q("dd", function(c, A) {
|
|
21776
21777
|
return A.weekdaysMinRegex(c);
|
|
21777
21778
|
});
|
|
@@ -21876,8 +21877,8 @@ function vn(c) {
|
|
|
21876
21877
|
return this._weekdaysParseExact ? (O0(this, "_weekdaysRegex") || xe.call(this), c ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex) : (O0(this, "_weekdaysMinRegex") || (this._weekdaysMinRegex = Tn), this._weekdaysMinStrictRegex && c ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex);
|
|
21877
21878
|
}
|
|
21878
21879
|
function xe() {
|
|
21879
|
-
function c(
|
|
21880
|
-
return Y.length -
|
|
21880
|
+
function c(X, Y) {
|
|
21881
|
+
return Y.length - X.length;
|
|
21881
21882
|
}
|
|
21882
21883
|
var A = [], f = [], y = [], m = [], S, F, N, P, J;
|
|
21883
21884
|
for (S = 0; S < 7; S++)
|
|
@@ -21930,12 +21931,12 @@ function vt(c, A) {
|
|
|
21930
21931
|
}
|
|
21931
21932
|
Q("a", vt);
|
|
21932
21933
|
Q("A", vt);
|
|
21933
|
-
Q("H",
|
|
21934
|
-
Q("h",
|
|
21935
|
-
Q("k",
|
|
21936
|
-
Q("HH",
|
|
21937
|
-
Q("hh",
|
|
21938
|
-
Q("kk",
|
|
21934
|
+
Q("H", m0, Be);
|
|
21935
|
+
Q("h", m0, S1);
|
|
21936
|
+
Q("k", m0, S1);
|
|
21937
|
+
Q("HH", m0, P0);
|
|
21938
|
+
Q("hh", m0, P0);
|
|
21939
|
+
Q("kk", m0, P0);
|
|
21939
21940
|
Q("hmm", St);
|
|
21940
21941
|
Q("hmmss", Tt);
|
|
21941
21942
|
Q("Hmm", St);
|
|
@@ -21988,7 +21989,7 @@ var Pt = {
|
|
|
21988
21989
|
weekdaysMin: gn,
|
|
21989
21990
|
weekdaysShort: wt,
|
|
21990
21991
|
meridiemParse: Hn
|
|
21991
|
-
},
|
|
21992
|
+
}, g0 = {}, R1 = {}, N1;
|
|
21992
21993
|
function Un(c, A) {
|
|
21993
21994
|
var f, y = Math.min(c.length, A.length);
|
|
21994
21995
|
for (f = 0; f < y; f += 1)
|
|
@@ -22017,13 +22018,13 @@ function Gn(c) {
|
|
|
22017
22018
|
}
|
|
22018
22019
|
function ce(c) {
|
|
22019
22020
|
var A = null, f;
|
|
22020
|
-
if (
|
|
22021
|
+
if (g0[c] === void 0 && typeof module < "u" && module && module.exports && Gn(c))
|
|
22021
22022
|
try {
|
|
22022
22023
|
A = N1._abbr, f = require, f("./locale/" + c), d1(A);
|
|
22023
22024
|
} catch {
|
|
22024
|
-
|
|
22025
|
+
g0[c] = null;
|
|
22025
22026
|
}
|
|
22026
|
-
return
|
|
22027
|
+
return g0[c];
|
|
22027
22028
|
}
|
|
22028
22029
|
function d1(c, A) {
|
|
22029
22030
|
var f;
|
|
@@ -22034,14 +22035,14 @@ function d1(c, A) {
|
|
|
22034
22035
|
function Pe(c, A) {
|
|
22035
22036
|
if (A !== null) {
|
|
22036
22037
|
var f, y = Pt;
|
|
22037
|
-
if (A.abbr = c,
|
|
22038
|
+
if (A.abbr = c, g0[c] != null)
|
|
22038
22039
|
mt(
|
|
22039
22040
|
"defineLocaleOverride",
|
|
22040
22041
|
"use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."
|
|
22041
|
-
), y =
|
|
22042
|
+
), y = g0[c]._config;
|
|
22042
22043
|
else if (A.parentLocale != null)
|
|
22043
|
-
if (
|
|
22044
|
-
y =
|
|
22044
|
+
if (g0[A.parentLocale] != null)
|
|
22045
|
+
y = g0[A.parentLocale]._config;
|
|
22045
22046
|
else if (f = ce(A.parentLocale), f != null)
|
|
22046
22047
|
y = f._config;
|
|
22047
22048
|
else
|
|
@@ -22049,19 +22050,19 @@ function Pe(c, A) {
|
|
|
22049
22050
|
name: c,
|
|
22050
22051
|
config: A
|
|
22051
22052
|
}), null;
|
|
22052
|
-
return
|
|
22053
|
+
return g0[c] = new Le($e(y, A)), R1[c] && R1[c].forEach(function(m) {
|
|
22053
22054
|
Pe(m.name, m.config);
|
|
22054
|
-
}), d1(c),
|
|
22055
|
+
}), d1(c), g0[c];
|
|
22055
22056
|
} else
|
|
22056
|
-
return delete
|
|
22057
|
+
return delete g0[c], null;
|
|
22057
22058
|
}
|
|
22058
22059
|
function Qn(c, A) {
|
|
22059
22060
|
if (A != null) {
|
|
22060
22061
|
var f, y, m = Pt;
|
|
22061
|
-
|
|
22062
|
+
g0[c] != null && g0[c].parentLocale != null ? g0[c].set($e(g0[c]._config, A)) : (y = ce(c), y != null && (m = y._config), A = $e(m, A), y == null && (A.abbr = c), f = new Le(A), f.parentLocale = g0[c], g0[c] = f), d1(c);
|
|
22062
22063
|
} else
|
|
22063
|
-
|
|
22064
|
-
return
|
|
22064
|
+
g0[c] != null && (g0[c].parentLocale != null ? (g0[c] = g0[c].parentLocale, c === d1() && d1(c)) : g0[c] != null && delete g0[c]);
|
|
22065
|
+
return g0[c];
|
|
22065
22066
|
}
|
|
22066
22067
|
function p1(c) {
|
|
22067
22068
|
var A;
|
|
@@ -22075,7 +22076,7 @@ function p1(c) {
|
|
|
22075
22076
|
return Yn(c);
|
|
22076
22077
|
}
|
|
22077
22078
|
function Vn() {
|
|
22078
|
-
return Ee(
|
|
22079
|
+
return Ee(g0);
|
|
22079
22080
|
}
|
|
22080
22081
|
function Je(c) {
|
|
22081
22082
|
var A, f = c._a;
|
|
@@ -22118,7 +22119,7 @@ var jn = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(
|
|
|
22118
22119
|
PST: -8 * 60
|
|
22119
22120
|
};
|
|
22120
22121
|
function Jt(c) {
|
|
22121
|
-
var A, f, y = c._i, m = jn.exec(y) || Kn.exec(y), S, F, N, P, J = G1.length,
|
|
22122
|
+
var A, f, y = c._i, m = jn.exec(y) || Kn.exec(y), S, F, N, P, J = G1.length, X = ze.length;
|
|
22122
22123
|
if (m) {
|
|
22123
22124
|
for (t0(c).iso = !0, A = 0, f = J; A < f; A++)
|
|
22124
22125
|
if (G1[A][1].exec(m[1])) {
|
|
@@ -22130,7 +22131,7 @@ function Jt(c) {
|
|
|
22130
22131
|
return;
|
|
22131
22132
|
}
|
|
22132
22133
|
if (m[3]) {
|
|
22133
|
-
for (A = 0, f =
|
|
22134
|
+
for (A = 0, f = X; A < f; A++)
|
|
22134
22135
|
if (ze[A][1].exec(m[3])) {
|
|
22135
22136
|
N = (m[2] || " ") + ze[A][0];
|
|
22136
22137
|
break;
|
|
@@ -22259,8 +22260,8 @@ function pa(c) {
|
|
|
22259
22260
|
A = c._w, A.GG != null || A.W != null || A.E != null ? (S = 1, F = 4, f = $1(
|
|
22260
22261
|
A.GG,
|
|
22261
22262
|
c._a[N0],
|
|
22262
|
-
B1(
|
|
22263
|
-
), y = $1(A.W, 1), m = $1(A.E, 1), (m < 1 || m > 7) && (P = !0)) : (S = c._locale._week.dow, F = c._locale._week.doy, J = B1(
|
|
22263
|
+
B1(E0(), 1, 4).year
|
|
22264
|
+
), y = $1(A.W, 1), m = $1(A.E, 1), (m < 1 || m > 7) && (P = !0)) : (S = c._locale._week.dow, F = c._locale._week.doy, J = B1(E0(), S, F), f = $1(A.gg, c._a[N0], J.year), y = $1(A.w, J.week), A.d != null ? (m = A.d, (m < 0 || m > 6) && (P = !0)) : A.e != null ? (m = A.e + S, (A.e < 0 || A.e > 6) && (P = !0)) : m = S), y < 1 || y > u1(f, S, F) ? t0(c)._overflowWeeks = !0 : P != null ? t0(c)._overflowWeekday = !0 : (N = Nt(f, y, m, S, F), c._a[N0] = N.year, c._dayOfYear = N.dayOfYear);
|
|
22264
22265
|
}
|
|
22265
22266
|
G.ISO_8601 = function() {
|
|
22266
22267
|
};
|
|
@@ -22276,8 +22277,8 @@ function Xe(c) {
|
|
|
22276
22277
|
return;
|
|
22277
22278
|
}
|
|
22278
22279
|
c._a = [], t0(c).empty = !0;
|
|
22279
|
-
var A = "" + c._i, f, y, m, S, F, N = A.length, P = 0, J,
|
|
22280
|
-
for (m = qt(c._f, c._locale).match(Ce) || [],
|
|
22280
|
+
var A = "" + c._i, f, y, m, S, F, N = A.length, P = 0, J, X;
|
|
22281
|
+
for (m = qt(c._f, c._locale).match(Ce) || [], X = m.length, f = 0; f < X; f++)
|
|
22281
22282
|
S = m[f], y = (A.match(Vr(S, c)) || [])[0], y && (F = A.substr(0, A.indexOf(y)), F.length > 0 && t0(c).unusedInput.push(F), A = A.slice(
|
|
22282
22283
|
A.indexOf(y) + y.length
|
|
22283
22284
|
), P += y.length), m1[S] ? (y ? t0(c).empty = !1 : t0(c).unusedTokens.push(S), Kr(S, y, c)) : c._strict && !y && t0(c).unusedTokens.push(S);
|
|
@@ -22330,26 +22331,26 @@ function kt(c, A, f, y, m) {
|
|
|
22330
22331
|
var S = {};
|
|
22331
22332
|
return (A === !0 || A === !1) && (y = A, A = void 0), (f === !0 || f === !1) && (y = f, f = void 0), (D1(c) && Se(c) || Q0(c) && c.length === 0) && (c = void 0), S._isAMomentObject = !0, S._useUTC = S._isUTC = m, S._l = f, S._i = c, S._f = A, S._strict = y, ba(S);
|
|
22332
22333
|
}
|
|
22333
|
-
function
|
|
22334
|
+
function E0(c, A, f, y) {
|
|
22334
22335
|
return kt(c, A, f, y, !1);
|
|
22335
22336
|
}
|
|
22336
22337
|
var Oa = U0(
|
|
22337
22338
|
"moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",
|
|
22338
22339
|
function() {
|
|
22339
|
-
var c =
|
|
22340
|
+
var c = E0.apply(null, arguments);
|
|
22340
22341
|
return this.isValid() && c.isValid() ? c < this ? this : c : ie();
|
|
22341
22342
|
}
|
|
22342
22343
|
), Aa = U0(
|
|
22343
22344
|
"moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",
|
|
22344
22345
|
function() {
|
|
22345
|
-
var c =
|
|
22346
|
+
var c = E0.apply(null, arguments);
|
|
22346
22347
|
return this.isValid() && c.isValid() ? c > this ? this : c : ie();
|
|
22347
22348
|
}
|
|
22348
22349
|
);
|
|
22349
22350
|
function Ut(c, A) {
|
|
22350
22351
|
var f, y;
|
|
22351
22352
|
if (A.length === 1 && Q0(A[0]) && (A = A[0]), !A.length)
|
|
22352
|
-
return
|
|
22353
|
+
return E0();
|
|
22353
22354
|
for (f = A[0], y = 1; y < A.length; ++y)
|
|
22354
22355
|
(!A[y].isValid() || A[y][c](f)) && (f = A[y]);
|
|
22355
22356
|
return f;
|
|
@@ -22395,8 +22396,8 @@ function Ea() {
|
|
|
22395
22396
|
return j0(NaN);
|
|
22396
22397
|
}
|
|
22397
22398
|
function Me(c) {
|
|
22398
|
-
var A = Fe(c), f = A.year || 0, y = A.quarter || 0, m = A.month || 0, S = A.week || A.isoWeek || 0, F = A.day || 0, N = A.hour || 0, P = A.minute || 0, J = A.second || 0,
|
|
22399
|
-
this._isValid = ya(A), this._milliseconds = +
|
|
22399
|
+
var A = Fe(c), f = A.year || 0, y = A.quarter || 0, m = A.month || 0, S = A.week || A.isoWeek || 0, F = A.day || 0, N = A.hour || 0, P = A.minute || 0, J = A.second || 0, X = A.millisecond || 0;
|
|
22400
|
+
this._isValid = ya(A), this._milliseconds = +X + J * 1e3 + // 1000
|
|
22400
22401
|
P * 6e4 + // 1000 * 60
|
|
22401
22402
|
N * 1e3 * 60 * 60, this._days = +F + S * 7, this._months = +m + y * 3 + f * 12, this._data = {}, this._locale = p1(), this._bubble();
|
|
22402
22403
|
}
|
|
@@ -22432,7 +22433,7 @@ function ke(c, A) {
|
|
|
22432
22433
|
}
|
|
22433
22434
|
function Ue(c, A) {
|
|
22434
22435
|
var f, y;
|
|
22435
|
-
return A._isUTC ? (f = A.clone(), y = (V0(c) || x1(c) ? c.valueOf() :
|
|
22436
|
+
return A._isUTC ? (f = A.clone(), y = (V0(c) || x1(c) ? c.valueOf() : E0(c).valueOf()) - f.valueOf(), f._d.setTime(f._d.valueOf() + y), G.updateOffset(f, !1), f) : E0(c).local();
|
|
22436
22437
|
}
|
|
22437
22438
|
function ge(c) {
|
|
22438
22439
|
return -Math.round(c._d.getTimezoneOffset());
|
|
@@ -22476,7 +22477,7 @@ function Ra() {
|
|
|
22476
22477
|
return this;
|
|
22477
22478
|
}
|
|
22478
22479
|
function La(c) {
|
|
22479
|
-
return this.isValid() ? (c = c ?
|
|
22480
|
+
return this.isValid() ? (c = c ? E0(c).utcOffset() : 0, (this.utcOffset() - c) % 60 === 0) : !1;
|
|
22480
22481
|
}
|
|
22481
22482
|
function Ca() {
|
|
22482
22483
|
return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset();
|
|
@@ -22485,7 +22486,7 @@ function Fa() {
|
|
|
22485
22486
|
if (!x0(this._isDSTShifted))
|
|
22486
22487
|
return this._isDSTShifted;
|
|
22487
22488
|
var c = {}, A;
|
|
22488
|
-
return Re(c, this), c = Xt(c), c._a ? (A = c._isUTC ? e1(c._a) :
|
|
22489
|
+
return Re(c, this), c = Xt(c), c._a ? (A = c._isUTC ? e1(c._a) : E0(c._a), this._isDSTShifted = this.isValid() && ma(c._a, A.toArray()) > 0) : this._isDSTShifted = !1, this._isDSTShifted;
|
|
22489
22490
|
}
|
|
22490
22491
|
function Ia() {
|
|
22491
22492
|
return this.isValid() ? !this._isUTC : !1;
|
|
@@ -22520,8 +22521,8 @@ function j0(c, A) {
|
|
|
22520
22521
|
m: A1(y[7], m),
|
|
22521
22522
|
s: A1(y[8], m)
|
|
22522
22523
|
}) : f == null ? f = {} : typeof f == "object" && ("from" in f || "to" in f) && (F = wa(
|
|
22523
|
-
|
|
22524
|
-
|
|
22524
|
+
E0(f.from),
|
|
22525
|
+
E0(f.to)
|
|
22525
22526
|
), f = {}, f.ms = F.milliseconds, f.M = F.months), S = new Me(f), V1(c) && O0(c, "_locale") && (S._locale = c._locale), V1(c) && O0(c, "_isValid") && (S._isValid = c._isValid), S;
|
|
22526
22527
|
}
|
|
22527
22528
|
j0.fn = Me.prototype;
|
|
@@ -22614,28 +22615,28 @@ function ka(c, A) {
|
|
|
22614
22615
|
}
|
|
22615
22616
|
function Ua(c, A) {
|
|
22616
22617
|
arguments.length === 1 && (arguments[0] ? Pa(arguments[0]) ? (c = arguments[0], A = void 0) : Xa(arguments[0]) && (A = arguments[0], c = void 0) : (c = void 0, A = void 0));
|
|
22617
|
-
var f = c ||
|
|
22618
|
+
var f = c || E0(), y = Ue(f, this).startOf("day"), m = G.calendarFormat(this, y) || "sameElse", S = A && (t1(A[m]) ? A[m].call(this, f) : A[m]);
|
|
22618
22619
|
return this.format(
|
|
22619
|
-
S || this.localeData().calendar(m, this,
|
|
22620
|
+
S || this.localeData().calendar(m, this, E0(f))
|
|
22620
22621
|
);
|
|
22621
22622
|
}
|
|
22622
22623
|
function Ya() {
|
|
22623
22624
|
return new v1(this);
|
|
22624
22625
|
}
|
|
22625
22626
|
function Ga(c, A) {
|
|
22626
|
-
var f = V0(c) ? c :
|
|
22627
|
+
var f = V0(c) ? c : E0(c);
|
|
22627
22628
|
return this.isValid() && f.isValid() ? (A = Y0(A) || "millisecond", A === "millisecond" ? this.valueOf() > f.valueOf() : f.valueOf() < this.clone().startOf(A).valueOf()) : !1;
|
|
22628
22629
|
}
|
|
22629
22630
|
function Qa(c, A) {
|
|
22630
|
-
var f = V0(c) ? c :
|
|
22631
|
+
var f = V0(c) ? c : E0(c);
|
|
22631
22632
|
return this.isValid() && f.isValid() ? (A = Y0(A) || "millisecond", A === "millisecond" ? this.valueOf() < f.valueOf() : this.clone().endOf(A).valueOf() < f.valueOf()) : !1;
|
|
22632
22633
|
}
|
|
22633
22634
|
function Va(c, A, f, y) {
|
|
22634
|
-
var m = V0(c) ? c :
|
|
22635
|
+
var m = V0(c) ? c : E0(c), S = V0(A) ? A : E0(A);
|
|
22635
22636
|
return this.isValid() && m.isValid() && S.isValid() ? (y = y || "()", (y[0] === "(" ? this.isAfter(m, f) : !this.isBefore(m, f)) && (y[1] === ")" ? this.isBefore(S, f) : !this.isAfter(S, f))) : !1;
|
|
22636
22637
|
}
|
|
22637
22638
|
function ja(c, A) {
|
|
22638
|
-
var f = V0(c) ? c :
|
|
22639
|
+
var f = V0(c) ? c : E0(c), y;
|
|
22639
22640
|
return this.isValid() && f.isValid() ? (A = Y0(A) || "millisecond", A === "millisecond" ? this.valueOf() === f.valueOf() : (y = f.valueOf(), this.clone().startOf(A).valueOf() <= y && y <= this.clone().endOf(A).valueOf())) : !1;
|
|
22640
22641
|
}
|
|
22641
22642
|
function Ka(c, A) {
|
|
@@ -22715,16 +22716,16 @@ function ai(c) {
|
|
|
22715
22716
|
return this.localeData().postformat(A);
|
|
22716
22717
|
}
|
|
22717
22718
|
function ii(c, A) {
|
|
22718
|
-
return this.isValid() && (V0(c) && c.isValid() ||
|
|
22719
|
+
return this.isValid() && (V0(c) && c.isValid() || E0(c).isValid()) ? j0({ to: this, from: c }).locale(this.locale()).humanize(!A) : this.localeData().invalidDate();
|
|
22719
22720
|
}
|
|
22720
22721
|
function oi(c) {
|
|
22721
|
-
return this.from(
|
|
22722
|
+
return this.from(E0(), c);
|
|
22722
22723
|
}
|
|
22723
22724
|
function si(c, A) {
|
|
22724
|
-
return this.isValid() && (V0(c) && c.isValid() ||
|
|
22725
|
+
return this.isValid() && (V0(c) && c.isValid() || E0(c).isValid()) ? j0({ from: this, to: c }).locale(this.locale()).humanize(!A) : this.localeData().invalidDate();
|
|
22725
22726
|
}
|
|
22726
22727
|
function ui(c) {
|
|
22727
|
-
return this.to(
|
|
22728
|
+
return this.to(E0(), c);
|
|
22728
22729
|
}
|
|
22729
22730
|
function Kt(c) {
|
|
22730
22731
|
var A;
|
|
@@ -23055,8 +23056,8 @@ be("GGGG", "isoWeekYear");
|
|
|
23055
23056
|
be("GGGGG", "isoWeekYear");
|
|
23056
23057
|
Q("G", le);
|
|
23057
23058
|
Q("g", le);
|
|
23058
|
-
Q("GG",
|
|
23059
|
-
Q("gg",
|
|
23059
|
+
Q("GG", m0, P0);
|
|
23060
|
+
Q("gg", m0, P0);
|
|
23060
23061
|
Q("GGGG", We, Ie);
|
|
23061
23062
|
Q("gggg", We, Ie);
|
|
23062
23063
|
Q("GGGGG", ue, oe);
|
|
@@ -23121,14 +23122,14 @@ function Pi(c) {
|
|
|
23121
23122
|
return c == null ? Math.ceil((this.month() + 1) / 3) : this.month((c - 1) * 3 + this.month() % 3);
|
|
23122
23123
|
}
|
|
23123
23124
|
K("D", ["DD", 2], "Do", "date");
|
|
23124
|
-
Q("D",
|
|
23125
|
-
Q("DD",
|
|
23125
|
+
Q("D", m0, S1);
|
|
23126
|
+
Q("DD", m0, P0);
|
|
23126
23127
|
Q("Do", function(c, A) {
|
|
23127
23128
|
return c ? A._dayOfMonthOrdinalParse || A._ordinalParse : A._dayOfMonthOrdinalParseLenient;
|
|
23128
23129
|
});
|
|
23129
23130
|
f0(["D", "DD"], K0);
|
|
23130
23131
|
f0("Do", function(c, A) {
|
|
23131
|
-
A[K0] = l0(c.match(
|
|
23132
|
+
A[K0] = l0(c.match(m0)[0]);
|
|
23132
23133
|
});
|
|
23133
23134
|
var ir = T1("Date", !0);
|
|
23134
23135
|
K("DDD", ["DDDD", 3], "DDDo", "dayOfYear");
|
|
@@ -23144,13 +23145,13 @@ function Ji(c) {
|
|
|
23144
23145
|
return c == null ? A : this.add(c - A, "d");
|
|
23145
23146
|
}
|
|
23146
23147
|
K("m", ["mm", 2], 0, "minute");
|
|
23147
|
-
Q("m",
|
|
23148
|
-
Q("mm",
|
|
23148
|
+
Q("m", m0, Be);
|
|
23149
|
+
Q("mm", m0, P0);
|
|
23149
23150
|
f0(["m", "mm"], G0);
|
|
23150
23151
|
var Hi = T1("Minutes", !1);
|
|
23151
23152
|
K("s", ["ss", 2], 0, "second");
|
|
23152
|
-
Q("s",
|
|
23153
|
-
Q("ss",
|
|
23153
|
+
Q("s", m0, Be);
|
|
23154
|
+
Q("ss", m0, P0);
|
|
23154
23155
|
f0(["s", "ss"], o1);
|
|
23155
23156
|
var Xi = T1("Seconds", !1);
|
|
23156
23157
|
K("S", 0, 0, function() {
|
|
@@ -23299,10 +23300,10 @@ k.isDSTShifted = U0(
|
|
|
23299
23300
|
Fa
|
|
23300
23301
|
);
|
|
23301
23302
|
function Gi(c) {
|
|
23302
|
-
return
|
|
23303
|
+
return E0(c * 1e3);
|
|
23303
23304
|
}
|
|
23304
23305
|
function Qi() {
|
|
23305
|
-
return
|
|
23306
|
+
return E0.apply(null, arguments).parseZone();
|
|
23306
23307
|
}
|
|
23307
23308
|
function sr(c) {
|
|
23308
23309
|
return c;
|
|
@@ -23509,8 +23510,8 @@ function go(c, A, f, y, m) {
|
|
|
23509
23510
|
return m.relativeTime(A || 1, !!f, c, y);
|
|
23510
23511
|
}
|
|
23511
23512
|
function ho(c, A, f, y) {
|
|
23512
|
-
var m = j0(c).abs(), S = a1(m.as("s")), F = a1(m.as("m")), N = a1(m.as("h")), P = a1(m.as("d")), J = a1(m.as("M")),
|
|
23513
|
-
return f.w != null && (e0 = e0 ||
|
|
23513
|
+
var m = j0(c).abs(), S = a1(m.as("s")), F = a1(m.as("m")), N = a1(m.as("h")), P = a1(m.as("d")), J = a1(m.as("M")), X = a1(m.as("w")), Y = a1(m.as("y")), e0 = S <= f.ss && ["s", S] || S < f.s && ["ss", S] || F <= 1 && ["m"] || F < f.m && ["mm", F] || N <= 1 && ["h"] || N < f.h && ["hh", N] || P <= 1 && ["d"] || P < f.d && ["dd", P];
|
|
23514
|
+
return f.w != null && (e0 = e0 || X <= 1 && ["w"] || X < f.w && ["ww", X]), e0 = e0 || J <= 1 && ["M"] || J < f.M && ["MM", J] || Y <= 1 && ["y"] || ["yy", Y], e0[2] = A, e0[3] = +c > 0, e0[4] = y, go.apply(null, e0);
|
|
23514
23515
|
}
|
|
23515
23516
|
function So(c) {
|
|
23516
23517
|
return c === void 0 ? a1 : typeof c == "function" ? (a1 = c, !0) : !1;
|
|
@@ -23531,8 +23532,8 @@ function y1(c) {
|
|
|
23531
23532
|
function de() {
|
|
23532
23533
|
if (!this.isValid())
|
|
23533
23534
|
return this.localeData().invalidDate();
|
|
23534
|
-
var c = De(this._milliseconds) / 1e3, A = De(this._days), f = De(this._months), y, m, S, F, N = this.asSeconds(), P, J,
|
|
23535
|
-
return N ? (y = X0(c / 60), m = X0(y / 60), c %= 60, y %= 60, S = X0(f / 12), f %= 12, F = c ? c.toFixed(3).replace(/\.?0+$/, "") : "", P = N < 0 ? "-" : "", J = y1(this._months) !== y1(N) ? "-" : "",
|
|
23535
|
+
var c = De(this._milliseconds) / 1e3, A = De(this._days), f = De(this._months), y, m, S, F, N = this.asSeconds(), P, J, X, Y;
|
|
23536
|
+
return N ? (y = X0(c / 60), m = X0(y / 60), c %= 60, y %= 60, S = X0(f / 12), f %= 12, F = c ? c.toFixed(3).replace(/\.?0+$/, "") : "", P = N < 0 ? "-" : "", J = y1(this._months) !== y1(N) ? "-" : "", X = y1(this._days) !== y1(N) ? "-" : "", Y = y1(this._milliseconds) !== y1(N) ? "-" : "", P + "P" + (S ? J + S + "Y" : "") + (f ? J + f + "M" : "") + (A ? X + A + "D" : "") + (m || y || c ? "T" : "") + (m ? Y + m + "H" : "") + (y ? Y + y + "M" : "") + (c ? Y + F + "S" : "")) : "P0D";
|
|
23536
23537
|
}
|
|
23537
23538
|
var b0 = Me.prototype;
|
|
23538
23539
|
b0.isValid = $a;
|
|
@@ -23584,7 +23585,7 @@ f0("x", function(c, A, f) {
|
|
|
23584
23585
|
});
|
|
23585
23586
|
//! moment.js
|
|
23586
23587
|
G.version = "2.30.1";
|
|
23587
|
-
Tr(
|
|
23588
|
+
Tr(E0);
|
|
23588
23589
|
G.fn = k;
|
|
23589
23590
|
G.min = za;
|
|
23590
23591
|
G.max = Da;
|
|
@@ -23648,8 +23649,8 @@ const Lo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
23648
23649
|
A.version === void 0 && A.default && (A = A.default);
|
|
23649
23650
|
var f = "0.5.48", y = {}, m = {}, S = {}, F = {}, N = {}, P;
|
|
23650
23651
|
(!A || typeof A.version != "string") && a("Moment Timezone requires Moment.js. See https://momentjs.com/timezone/docs/#/use-it/browser/");
|
|
23651
|
-
var J = A.version.split("."),
|
|
23652
|
-
(
|
|
23652
|
+
var J = A.version.split("."), X = +J[0], Y = +J[1];
|
|
23653
|
+
(X < 2 || X === 2 && Y < 6) && a("Moment Timezone requires Moment.js >= 2.6.0. You are using Moment.js " + A.version + ". See momentjs.com");
|
|
23653
23654
|
function e0(b) {
|
|
23654
23655
|
return b > 96 ? b - 87 : b > 64 ? b - 29 : b - 48;
|
|
23655
23656
|
}
|
|
@@ -23767,7 +23768,7 @@ const Lo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
23767
23768
|
for (p0(O), D = 0; D < O.length; D++)
|
|
23768
23769
|
$ = O[D], N[$] = N[$] || {}, N[$][b] = !0;
|
|
23769
23770
|
}
|
|
23770
|
-
function
|
|
23771
|
+
function q0(b) {
|
|
23771
23772
|
var O = b.length, D = {}, $ = [], E = {}, g, h, R, C;
|
|
23772
23773
|
for (g = 0; g < O; g++)
|
|
23773
23774
|
if (R = b[g].offset, !E.hasOwnProperty(R)) {
|
|
@@ -23791,7 +23792,7 @@ const Lo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
23791
23792
|
}
|
|
23792
23793
|
} catch {
|
|
23793
23794
|
}
|
|
23794
|
-
var D = M0(), $ = D.length, E =
|
|
23795
|
+
var D = M0(), $ = D.length, E = q0(D), g = [], h, R, C;
|
|
23795
23796
|
for (R = 0; R < E.length; R++) {
|
|
23796
23797
|
for (h = new J0(o(E[R])), C = 0; C < $; C++)
|
|
23797
23798
|
h.scoreOffsetAt(D[C]);
|
|
@@ -23904,7 +23905,7 @@ const Lo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
23904
23905
|
};
|
|
23905
23906
|
}
|
|
23906
23907
|
s.zoneName = l(s.zoneName), s.zoneAbbr = l(s.zoneAbbr), s.utc = p(s.utc), s.local = p(s.local), s.utcOffset = _(s.utcOffset), A.tz.setDefault = function(b) {
|
|
23907
|
-
return (
|
|
23908
|
+
return (X < 2 || X === 2 && Y < 9) && a("Moment Timezone setDefault() requires Moment.js >= 2.9.0. You are using Moment.js " + A.version + "."), A.defaultZone = b ? o(b) : null, A;
|
|
23908
23909
|
};
|
|
23909
23910
|
var M = A.momentProperties;
|
|
23910
23911
|
return Object.prototype.toString.call(M) === "[object Array]" ? (M.push("_z"), M.push("_a")) : M && (M._z = null), A;
|
|
@@ -24819,7 +24820,7 @@ function Ho(c) {
|
|
|
24819
24820
|
decimal: U.decimal || 0
|
|
24820
24821
|
})), N = S.columns, P = (U, V) => U.isRollup && V.aggregationType === "ANY", J = N.map(
|
|
24821
24822
|
(U) => w1(U, S.dateRange, m)
|
|
24822
|
-
),
|
|
24823
|
+
), X = S.rows.map((U) => ({
|
|
24823
24824
|
cells: N.map((V, _0) => {
|
|
24824
24825
|
const L0 = U.value[V.id] ?? null;
|
|
24825
24826
|
return P(U, V) || U.isRollup && V.fieldType === "DIMENSION" && V.dataType === "NUMERIC" && L0 == null ? null : J[_0](R0(L0, V, m));
|
|
@@ -24838,8 +24839,8 @@ function Ho(c) {
|
|
|
24838
24839
|
), L0 = N.map(
|
|
24839
24840
|
(D0) => w1(D0, V.dateRange, m)
|
|
24840
24841
|
);
|
|
24841
|
-
for (let D0 = 0; D0 <
|
|
24842
|
-
const w0 =
|
|
24842
|
+
for (let D0 = 0; D0 < X.length; D0++) {
|
|
24843
|
+
const w0 = X[D0], J0 = S.rows[D0], r0 = _0(J0);
|
|
24843
24844
|
r0 && (w0.comparisonCells = N.map(
|
|
24844
24845
|
(M0, n0) => P(J0, M0) ? null : L0[n0](
|
|
24845
24846
|
R0(
|
|
@@ -24854,13 +24855,13 @@ function Ho(c) {
|
|
|
24854
24855
|
}
|
|
24855
24856
|
const Y = new Set(
|
|
24856
24857
|
F.reduce((U, V, _0) => (V.hide && U.push(_0), U), [])
|
|
24857
|
-
), e0 = Y.size > 0 ? F.filter((U, V) => !Y.has(V)) : F, i0 = Y.size > 0 ?
|
|
24858
|
+
), e0 = Y.size > 0 ? F.filter((U, V) => !Y.has(V)) : F, i0 = Y.size > 0 ? X.map((U) => ({
|
|
24858
24859
|
...U,
|
|
24859
24860
|
cells: U.cells.filter((V, _0) => !Y.has(_0)),
|
|
24860
24861
|
comparisonCells: U.comparisonCells.filter(
|
|
24861
24862
|
(V, _0) => !Y.has(_0)
|
|
24862
24863
|
)
|
|
24863
|
-
})) :
|
|
24864
|
+
})) : X, p0 = S.source || c.source || "postgresql", o0 = typeof p0 == "string" && p0.toLowerCase() === "bigquery" ? "bigquery" : "postgresql";
|
|
24864
24865
|
return {
|
|
24865
24866
|
type: "TABLE",
|
|
24866
24867
|
columns: e0,
|
|
@@ -24881,10 +24882,10 @@ function Xo(c) {
|
|
|
24881
24882
|
(r0) => r0.fieldType === "DIMENSION" && !r0.hide
|
|
24882
24883
|
), J = N.columns.filter(
|
|
24883
24884
|
(r0) => r0.fieldType === "METRIC" && !r0.hide
|
|
24884
|
-
),
|
|
24885
|
+
), X = P[0], Y = P.length > 1 ? P[1] : null, e0 = [], i0 = /* @__PURE__ */ new Set();
|
|
24885
24886
|
for (const r0 of N.rows) {
|
|
24886
24887
|
if (r0.isRollup) continue;
|
|
24887
|
-
const M0 =
|
|
24888
|
+
const M0 = X ? R0(r0.value[X.id] ?? null, X, S) : "";
|
|
24888
24889
|
i0.has(M0) || (i0.add(M0), e0.push(M0));
|
|
24889
24890
|
}
|
|
24890
24891
|
const p0 = /* @__PURE__ */ new Map();
|
|
@@ -24900,12 +24901,12 @@ function Xo(c) {
|
|
|
24900
24901
|
const r0 = /* @__PURE__ */ new Set(), M0 = e0.map(() => /* @__PURE__ */ new Set());
|
|
24901
24902
|
for (const n0 of N.rows) {
|
|
24902
24903
|
if (n0.isRollup) continue;
|
|
24903
|
-
const C0 =
|
|
24904
|
-
n0.value[
|
|
24905
|
-
|
|
24904
|
+
const C0 = X ? R0(
|
|
24905
|
+
n0.value[X.id] ?? null,
|
|
24906
|
+
X,
|
|
24906
24907
|
S
|
|
24907
|
-
) : "",
|
|
24908
|
-
if (
|
|
24908
|
+
) : "", q0 = p0.get(C0);
|
|
24909
|
+
if (q0 == null) continue;
|
|
24909
24910
|
const d0 = R0(
|
|
24910
24911
|
n0.value[Y.id] ?? null,
|
|
24911
24912
|
Y,
|
|
@@ -24913,24 +24914,24 @@ function Xo(c) {
|
|
|
24913
24914
|
);
|
|
24914
24915
|
r0.has(d0) || (r0.add(d0), _0.push(d0));
|
|
24915
24916
|
for (const c0 of J)
|
|
24916
|
-
M0[
|
|
24917
|
+
M0[q0].add(
|
|
24917
24918
|
`${d0}\0${c0.id}`
|
|
24918
24919
|
), U.push({
|
|
24919
24920
|
...c1(c0),
|
|
24920
24921
|
name: J.length > 1 ? `${d0} - ${c0.label}` : d0,
|
|
24921
24922
|
values: [C1(n0.value[c0.id], c0)],
|
|
24922
|
-
xAxisIndex:
|
|
24923
|
+
xAxisIndex: q0,
|
|
24923
24924
|
dateRange: o0
|
|
24924
24925
|
});
|
|
24925
24926
|
}
|
|
24926
24927
|
for (let n0 = 0; n0 < e0.length; n0++)
|
|
24927
24928
|
for (const C0 of _0)
|
|
24928
|
-
for (const
|
|
24929
|
-
const d0 = `${C0}\0${
|
|
24929
|
+
for (const q0 of J) {
|
|
24930
|
+
const d0 = `${C0}\0${q0.id}`;
|
|
24930
24931
|
M0[n0].has(d0) || U.push({
|
|
24931
|
-
...c1(
|
|
24932
|
-
name: J.length > 1 ? `${C0} - ${
|
|
24933
|
-
values: [
|
|
24932
|
+
...c1(q0),
|
|
24933
|
+
name: J.length > 1 ? `${C0} - ${q0.label}` : C0,
|
|
24934
|
+
values: [q0.nullable ? null : 0],
|
|
24934
24935
|
xAxisIndex: n0,
|
|
24935
24936
|
dateRange: o0
|
|
24936
24937
|
});
|
|
@@ -24956,9 +24957,9 @@ function Xo(c) {
|
|
|
24956
24957
|
S
|
|
24957
24958
|
) !== M0)
|
|
24958
24959
|
continue;
|
|
24959
|
-
const c0 =
|
|
24960
|
-
d0.value[
|
|
24961
|
-
|
|
24960
|
+
const c0 = X ? R0(
|
|
24961
|
+
d0.value[X.id] ?? null,
|
|
24962
|
+
X,
|
|
24962
24963
|
S
|
|
24963
24964
|
) : "", a0 = p0.get(c0);
|
|
24964
24965
|
a0 != null && (C0[a0] = C1(
|
|
@@ -24966,10 +24967,10 @@ function Xo(c) {
|
|
|
24966
24967
|
n0
|
|
24967
24968
|
));
|
|
24968
24969
|
}
|
|
24969
|
-
const
|
|
24970
|
+
const q0 = J.length > 1 ? `${M0} - ${n0.label}` : M0;
|
|
24970
24971
|
U.push({
|
|
24971
24972
|
...c1(n0),
|
|
24972
|
-
name:
|
|
24973
|
+
name: q0,
|
|
24973
24974
|
values: C0,
|
|
24974
24975
|
dateRange: o0
|
|
24975
24976
|
});
|
|
@@ -24980,12 +24981,12 @@ function Xo(c) {
|
|
|
24980
24981
|
const M0 = new Array(e0.length).fill(0);
|
|
24981
24982
|
for (const n0 of N.rows) {
|
|
24982
24983
|
if (n0.isRollup) continue;
|
|
24983
|
-
const C0 =
|
|
24984
|
-
n0.value[
|
|
24985
|
-
|
|
24984
|
+
const C0 = X ? R0(
|
|
24985
|
+
n0.value[X.id] ?? null,
|
|
24986
|
+
X,
|
|
24986
24987
|
S
|
|
24987
|
-
) : "",
|
|
24988
|
-
|
|
24988
|
+
) : "", q0 = p0.get(C0);
|
|
24989
|
+
q0 != null && (M0[q0] = C1(
|
|
24989
24990
|
n0.value[r0.id],
|
|
24990
24991
|
r0
|
|
24991
24992
|
));
|
|
@@ -25004,21 +25005,21 @@ function Xo(c) {
|
|
|
25004
25005
|
}, n0 = [], C0 = /* @__PURE__ */ new Set();
|
|
25005
25006
|
for (const d0 of r0.rows) {
|
|
25006
25007
|
if (d0.isRollup) continue;
|
|
25007
|
-
const c0 =
|
|
25008
|
+
const c0 = X ? R0(d0.value[X.id] ?? null, X, S) : "";
|
|
25008
25009
|
C0.has(c0) || (C0.add(c0), n0.push(c0));
|
|
25009
25010
|
}
|
|
25010
|
-
const
|
|
25011
|
+
const q0 = /* @__PURE__ */ new Map();
|
|
25011
25012
|
if (n0.forEach(
|
|
25012
|
-
(d0, c0) =>
|
|
25013
|
+
(d0, c0) => q0.set(d0, c0)
|
|
25013
25014
|
), V = n0, Y && F) {
|
|
25014
25015
|
const d0 = /* @__PURE__ */ new Map();
|
|
25015
25016
|
for (const c0 of r0.rows) {
|
|
25016
25017
|
if (c0.isRollup) continue;
|
|
25017
|
-
const a0 =
|
|
25018
|
-
c0.value[
|
|
25019
|
-
|
|
25018
|
+
const a0 = X ? R0(
|
|
25019
|
+
c0.value[X.id] ?? null,
|
|
25020
|
+
X,
|
|
25020
25021
|
S
|
|
25021
|
-
) : "", t =
|
|
25022
|
+
) : "", t = q0.get(a0), o = X != null && X.dateComparison ? t : p0.get(a0);
|
|
25022
25023
|
if (o == null) continue;
|
|
25023
25024
|
const u = R0(
|
|
25024
25025
|
c0.value[Y.id] ?? null,
|
|
@@ -25036,7 +25037,7 @@ function Xo(c) {
|
|
|
25036
25037
|
});
|
|
25037
25038
|
}
|
|
25038
25039
|
for (const c0 of n0) {
|
|
25039
|
-
const a0 =
|
|
25040
|
+
const a0 = q0.get(c0), t = X != null && X.dateComparison ? a0 : p0.get(c0);
|
|
25040
25041
|
if (t != null)
|
|
25041
25042
|
for (const o of _0)
|
|
25042
25043
|
for (const u of J) {
|
|
@@ -25069,11 +25070,11 @@ function Xo(c) {
|
|
|
25069
25070
|
S
|
|
25070
25071
|
) !== c0)
|
|
25071
25072
|
continue;
|
|
25072
|
-
const z =
|
|
25073
|
-
u.value[
|
|
25074
|
-
|
|
25073
|
+
const z = X ? R0(
|
|
25074
|
+
u.value[X.id] ?? null,
|
|
25075
|
+
X,
|
|
25075
25076
|
S
|
|
25076
|
-
) : "", q =
|
|
25077
|
+
) : "", q = q0.get(z), L = X != null && X.dateComparison ? q : p0.get(z);
|
|
25077
25078
|
L != null && (t[L] = C1(
|
|
25078
25079
|
u.value[a0.id],
|
|
25079
25080
|
a0
|
|
@@ -25095,8 +25096,8 @@ function Xo(c) {
|
|
|
25095
25096
|
start: f[m].dateRange.start,
|
|
25096
25097
|
end: f[m].dateRange.end
|
|
25097
25098
|
});
|
|
25098
|
-
const D0 = w1(
|
|
25099
|
-
|
|
25099
|
+
const D0 = w1(X, N.dateRange, S), w0 = w1(
|
|
25100
|
+
X,
|
|
25100
25101
|
L0.comparison,
|
|
25101
25102
|
S
|
|
25102
25103
|
);
|
|
@@ -25124,7 +25125,7 @@ function ko(c) {
|
|
|
25124
25125
|
return null;
|
|
25125
25126
|
const P = N.columns.find(
|
|
25126
25127
|
(V) => V.fieldType === "METRIC" && !V.hide
|
|
25127
|
-
), J = N.rows.find((V) => !V.isRollup) ?? N.rows[0],
|
|
25128
|
+
), J = N.rows.find((V) => !V.isRollup) ?? N.rows[0], X = J && P ? J.value[P.id] : null, Y = (P == null ? void 0 : P.label) ?? "", e0 = R0(X, P ?? null, m);
|
|
25128
25129
|
let i0;
|
|
25129
25130
|
if (f && A.length > y) {
|
|
25130
25131
|
const V = A[y], _0 = V ? V.rows.find((L0) => !L0.isRollup) ?? V.rows[0] : null;
|
|
@@ -25182,10 +25183,10 @@ function Uo(c) {
|
|
|
25182
25183
|
start: S.dateRange.start,
|
|
25183
25184
|
end: S.dateRange.end
|
|
25184
25185
|
};
|
|
25185
|
-
let J = null,
|
|
25186
|
+
let J = null, X;
|
|
25186
25187
|
if (f && A.length > y) {
|
|
25187
25188
|
const o0 = A[y];
|
|
25188
|
-
|
|
25189
|
+
X = {
|
|
25189
25190
|
start: o0.dateRange.start,
|
|
25190
25191
|
end: o0.dateRange.end
|
|
25191
25192
|
}, J = /* @__PURE__ */ new Map();
|
|
@@ -25196,7 +25197,7 @@ function Uo(c) {
|
|
|
25196
25197
|
}
|
|
25197
25198
|
}
|
|
25198
25199
|
const Y = [], e0 = { main: P };
|
|
25199
|
-
|
|
25200
|
+
X && (e0.comparison = X);
|
|
25200
25201
|
const i0 = w1(F, P, m);
|
|
25201
25202
|
for (const o0 of S.rows) {
|
|
25202
25203
|
if (o0.isRollup) continue;
|
|
@@ -25263,8 +25264,8 @@ function Vo(c, A) {
|
|
|
25263
25264
|
function jo(c, A) {
|
|
25264
25265
|
const f = c < 0, y = Math.abs(c), m = (J) => String(Math.floor(J)).padStart(2, "0"), S = m(y % 3600 / 60), F = m(y % 60), N = f ? "-" : "";
|
|
25265
25266
|
if (A) {
|
|
25266
|
-
const J = Math.floor(y / 86400),
|
|
25267
|
-
return `${N}${Y}${
|
|
25267
|
+
const J = Math.floor(y / 86400), X = m(y % 86400 / 3600), Y = J > 0 ? `${J} day${J > 1 ? "s" : ""} ` : "";
|
|
25268
|
+
return `${N}${Y}${X}:${S}:${F}`;
|
|
25268
25269
|
}
|
|
25269
25270
|
const P = m(y / 3600);
|
|
25270
25271
|
return `${N}${P}:${S}:${F}`;
|
|
@@ -25455,8 +25456,8 @@ function is(c, A, f) {
|
|
|
25455
25456
|
}
|
|
25456
25457
|
), S = (N, P) => JSON.stringify([
|
|
25457
25458
|
!!N.isRollup,
|
|
25458
|
-
...y.map((J,
|
|
25459
|
-
const Y = N.value[J.id] ?? null, e0 = m[
|
|
25459
|
+
...y.map((J, X) => {
|
|
25460
|
+
const Y = N.value[J.id] ?? null, e0 = m[X];
|
|
25460
25461
|
if (e0 == null || Y == null || Y === "") return Y;
|
|
25461
25462
|
const i0 = k0.tz(Y, f);
|
|
25462
25463
|
return i0.isValid() ? (P ? i0.add(e0, Mr[J.optionType]) : i0).toISOString() : Y;
|