super-page-runtime 2.3.7 → 2.3.9-sit1
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/es/components/runtime/utils/api/page-expose-util.js +50 -50
- package/dist/es/components/runtime/utils/charts/chart-columnline-util.js +102 -102
- package/dist/es/components/runtime/utils/charts/chart-gauge-util.js +26 -24
- package/dist/es/components/runtime/utils/charts/chart-pie-util.js +59 -58
- package/dist/es/components/runtime/utils/charts/chart-radar-util.js +38 -37
- package/dist/es/components/runtime/utils/charts/chart-scatter-util.js +28 -27
- package/dist/es/components/runtime/utils/charts/chart-util.d.ts +1 -0
- package/dist/es/components/runtime/utils/charts/chart-util.js +29 -22
- package/dist/es/components/runtime/utils/common-util.d.ts +4 -0
- package/dist/es/components/runtime/utils/common-util.js +4 -0
- package/dist/es/components/runtime/utils/events/event-util.js +3 -3
- package/dist/es/components/runtime/utils/events/print-label.js +25 -26
- package/dist/es/components/runtime/utils/events/standard-event.js +18 -18
- package/dist/es/components/runtime/utils/events/validator-util.d.ts +1 -1
- package/dist/es/components/runtime/utils/events/validator-util.js +122 -104
- package/dist/es/components/runtime/utils/page-init-util.js +24 -25
- package/dist/es/components/runtime/utils/page-store.js +10 -10
- package/dist/es/components/runtime/utils/table-utils.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue.js +4 -1
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +4 -4
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +6 -10
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +6 -8
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue.js +4 -1
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +15 -15
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue.js +4 -1
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +7 -7
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue.js +4 -1
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +8 -8
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue.js +4 -1
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +7 -7
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +11 -12
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +9 -11
- package/dist/es/components/runtime/views/assemblys/container/fixed/YxAffix.vue2.js +0 -2
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +10 -12
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +19 -17
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +26 -20
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +10 -4
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +31 -28
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +32 -25
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +52 -49
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +33 -30
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +38 -35
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +18 -15
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +57 -55
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +3 -5
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +0 -1
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +46 -43
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +55 -53
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +63 -61
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +25 -22
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +16 -13
- package/dist/es/components/runtime/views/home-chart.vue.js +7 -7
- package/dist/es/components/runtime/views/super-page-dialog.vue.js +0 -1
- package/dist/es/components/runtime/views/super-page.vue2.js +11 -12
- package/dist/es/style.css +30 -0
- package/package.json +2 -2
- package/dist/es.zip +0 -0
|
@@ -1,80 +1,81 @@
|
|
|
1
1
|
import { getValueFromSource as o, setValueForVariableName as t } from "../page-helper-util.js";
|
|
2
2
|
import { deepCopy as r } from "../common-util.js";
|
|
3
|
-
import {
|
|
4
|
-
function
|
|
5
|
-
if (!
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
3
|
+
import { setDefaultGrid as s, CommonName as e, caculateFormulaValue as l, executeChartFormula as n, sortDatas as p, limitDatas as i } from "./chart-util.js";
|
|
4
|
+
function u(u2, c, a, f) {
|
|
5
|
+
if (!f || !f.result) return;
|
|
6
|
+
s(a);
|
|
7
|
+
const g = f && f.result ? f.result : {};
|
|
8
|
+
let m = f && f.groupValue ? f.groupValue : void 0;
|
|
9
|
+
const h = c.serviceDataField;
|
|
10
|
+
let d = null;
|
|
11
|
+
h ? d = g[h] : g && (d = Array.isArray(g) ? g : [g]), d || (d = []);
|
|
12
|
+
let y = c.props ? c.props.groups : null;
|
|
13
|
+
if (y || (y = []), !m || 0 === m.length) {
|
|
14
|
+
m = [];
|
|
15
|
+
for (const o2 of y) m.push(o2.group);
|
|
15
16
|
}
|
|
16
|
-
const
|
|
17
|
-
for (const o2 of
|
|
18
|
-
let
|
|
19
|
-
|
|
20
|
-
for (const t2 of
|
|
17
|
+
const x = {}, v = [], E = [];
|
|
18
|
+
for (const o2 of y) x[o2.group] = o2.target, o2.target && !v.includes(o2.target) && (v.push(o2.target), m.includes(o2.group) && E.push(o2.target));
|
|
19
|
+
let F = c.props ? c.props.mulGroupShow : "";
|
|
20
|
+
F = "break" == F ? "\r\n" : " ";
|
|
21
|
+
for (const t2 of d) {
|
|
21
22
|
if (!t2) continue;
|
|
22
23
|
const r2 = [];
|
|
23
|
-
for (const
|
|
24
|
-
const
|
|
24
|
+
for (const s3 of m) {
|
|
25
|
+
const e2 = x[s3], l2 = o(t2, e2, void 0);
|
|
25
26
|
l2 && r2.push(l2);
|
|
26
27
|
}
|
|
27
|
-
const
|
|
28
|
-
t2[
|
|
28
|
+
const s2 = r2.join(F);
|
|
29
|
+
t2[e.X_FIELD_NAME] = s2;
|
|
29
30
|
}
|
|
30
|
-
const
|
|
31
|
-
if (0 ==
|
|
32
|
-
const
|
|
33
|
-
let
|
|
34
|
-
if (
|
|
35
|
-
const t2 = [], r2 =
|
|
36
|
-
let
|
|
37
|
-
for (const o2 in r2)
|
|
38
|
-
|
|
31
|
+
const S = c.items ? c.items : [];
|
|
32
|
+
if (0 == S.length) return;
|
|
33
|
+
const _ = c.props ? c.props : {};
|
|
34
|
+
let A = _.yaxisField;
|
|
35
|
+
if (S[0].props.yaxisField = A, S[0].props.yaxisSource = _.yaxisSource, S[0].props.formula = _.formula, "formula" === _.yaxisSource) {
|
|
36
|
+
const t2 = [], r2 = l(S, d, t2);
|
|
37
|
+
let s2 = _.formula ? _.formula : "";
|
|
38
|
+
for (const o2 in r2) s2 = s2.replace(new RegExp(o2.replace("$", "\\$"), "g"), r2[o2]);
|
|
39
|
+
A = e.Y_TEMP_NAME;
|
|
39
40
|
const p2 = {};
|
|
40
|
-
for (const r3 of
|
|
41
|
+
for (const r3 of d) {
|
|
41
42
|
if (!r3) continue;
|
|
42
43
|
for (const s3 of t2) {
|
|
43
44
|
const t3 = o(r3, s3, void 0);
|
|
44
|
-
let
|
|
45
|
-
void 0 === t3 || isNaN(t3) || (void 0 ===
|
|
45
|
+
let e3 = p2[s3];
|
|
46
|
+
void 0 === t3 || isNaN(t3) || (void 0 === e3 ? e3 = t3 : e3 += t3), p2[s3] = e3;
|
|
46
47
|
}
|
|
47
|
-
const
|
|
48
|
-
r3[
|
|
48
|
+
const e2 = n(s2, p2, r3, u2);
|
|
49
|
+
r3[A] = e2;
|
|
49
50
|
}
|
|
50
51
|
}
|
|
51
|
-
|
|
52
|
-
const
|
|
53
|
-
for (const t2 of
|
|
52
|
+
S[0].props.yaxisField = A, S[0].props.yaxisSource = "", p(u2, c, d), d = i(u2, c, d, v, [A]);
|
|
53
|
+
const D = [], M = [];
|
|
54
|
+
for (const t2 of d) {
|
|
54
55
|
if (!t2) continue;
|
|
55
|
-
|
|
56
|
-
const r2 = o(t2,
|
|
57
|
-
|
|
56
|
+
D.push(t2[e.X_FIELD_NAME]);
|
|
57
|
+
const r2 = o(t2, A, void 0);
|
|
58
|
+
M.push(r2);
|
|
58
59
|
}
|
|
59
|
-
const
|
|
60
|
-
let
|
|
61
|
-
|
|
62
|
-
let
|
|
63
|
-
|
|
64
|
-
const
|
|
65
|
-
for (let o2 = 0; o2 <
|
|
66
|
-
const t2 = { value:
|
|
67
|
-
if (o2 <
|
|
68
|
-
let r2 =
|
|
69
|
-
r2 || (r2 =
|
|
60
|
+
const N = c.defaultSeries;
|
|
61
|
+
let j = N[0].pieColors;
|
|
62
|
+
j = j || [];
|
|
63
|
+
let b = N[0].pieColorMap;
|
|
64
|
+
b = b || {};
|
|
65
|
+
const w = [];
|
|
66
|
+
for (let o2 = 0; o2 < D.length && o2 < M.length; o2++) {
|
|
67
|
+
const t2 = { value: M[o2], name: D[o2] };
|
|
68
|
+
if (o2 < j.length || b[t2.name]) {
|
|
69
|
+
let r2 = b[t2.name];
|
|
70
|
+
r2 || (r2 = j[o2]), r2 && (t2.itemStyle = { color: r2 });
|
|
70
71
|
}
|
|
71
|
-
|
|
72
|
+
w.push(t2);
|
|
72
73
|
}
|
|
73
|
-
const
|
|
74
|
-
|
|
75
|
-
const
|
|
76
|
-
!(
|
|
74
|
+
const I = r(N);
|
|
75
|
+
I[0].data = w, a.series = [I[0]];
|
|
76
|
+
const V = c.props ? c.props.selGroupVariable : null;
|
|
77
|
+
!(c.props ? c.props.enableDrill : null) && V && (c.highlightInfos = [], t(u2.entity, V, null)), c.groupFields = E, c.cacheDatas = d, c.rawResult = f;
|
|
77
78
|
}
|
|
78
79
|
export {
|
|
79
|
-
|
|
80
|
+
u as updateChartOption
|
|
80
81
|
};
|
|
@@ -1,54 +1,55 @@
|
|
|
1
1
|
import { getValueFromSource as e } from "../page-helper-util.js";
|
|
2
2
|
import { deepCopy as o } from "../common-util.js";
|
|
3
|
-
import {
|
|
4
|
-
function
|
|
5
|
-
if (!
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
3
|
+
import { setDefaultGrid as i, caculateFormulaValue as t, executeChartFormula as a } from "./chart-util.js";
|
|
4
|
+
function s(s2, r, l, u) {
|
|
5
|
+
if (!u || !u.result) return;
|
|
6
|
+
i(l);
|
|
7
|
+
const f = u && u.result ? u.result : {}, d = r.serviceDataField;
|
|
8
|
+
let n = null;
|
|
9
|
+
d ? n = f[d] : f && (n = Array.isArray(f) ? f : [f]), n || (n = []);
|
|
10
|
+
const c = r.items ? r.items : [], p = [], m = {}, x = [], v = t(c, n, x);
|
|
11
|
+
for (const e2 of c) {
|
|
11
12
|
const o2 = e2.props ? e2.props : {}, i2 = o2.yaxisSource, t2 = o2.yaxisField;
|
|
12
|
-
let
|
|
13
|
+
let a2 = null;
|
|
13
14
|
if (!t2 || i2 && "variable" != i2) if ("formula" == i2) {
|
|
14
15
|
let i3 = o2.formula ? o2.formula : "";
|
|
15
|
-
for (const e3 in
|
|
16
|
-
|
|
17
|
-
} else
|
|
18
|
-
else
|
|
19
|
-
|
|
16
|
+
for (const e3 in v) i3 = i3.replace(new RegExp(e3.replace("$", "\\$"), "g"), v[e3]);
|
|
17
|
+
a2 = { uuid: e2.uuid, type: "formula", formula: i3, data: [] };
|
|
18
|
+
} else a2 = { uuid: e2.uuid, type: "fixed", field: o2.yaxisFix, data: [] };
|
|
19
|
+
else a2 = { uuid: e2.uuid, type: "variable", field: t2, data: [] };
|
|
20
|
+
a2 && (p.push(a2), m[a2.uuid] = a2);
|
|
20
21
|
}
|
|
21
|
-
const
|
|
22
|
-
for (const o2 of
|
|
22
|
+
const y = r.props ? r.props : {}, h = y.nameField, F = y.maxSource, b = y.maxField, g = y.maxFixed, j = [], S = {};
|
|
23
|
+
for (const o2 of n) {
|
|
23
24
|
if (!o2) continue;
|
|
24
|
-
const i2 = e(o2,
|
|
25
|
-
let
|
|
26
|
-
|
|
27
|
-
for (const i3 of
|
|
28
|
-
const
|
|
29
|
-
let
|
|
30
|
-
void 0 ===
|
|
25
|
+
const i2 = e(o2, h, void 0);
|
|
26
|
+
let t2 = null;
|
|
27
|
+
t2 = F && "variable" != F ? g : e(o2, b, void 0), j.push({ text: i2, max: t2 });
|
|
28
|
+
for (const i3 of x) {
|
|
29
|
+
const t3 = e(o2, i3, void 0);
|
|
30
|
+
let a2 = S[i3];
|
|
31
|
+
void 0 === t3 || isNaN(t3) || (void 0 === a2 ? a2 = t3 : a2 += t3), S[i3] = a2;
|
|
31
32
|
}
|
|
32
|
-
for (const i3 of
|
|
33
|
-
const
|
|
34
|
-
if ("fixed" == i3.type)
|
|
33
|
+
for (const i3 of p) {
|
|
34
|
+
const t3 = i3.data;
|
|
35
|
+
if ("fixed" == i3.type) t3.push(i3.field);
|
|
35
36
|
else if ("variable" == i3.type) {
|
|
36
|
-
const
|
|
37
|
-
|
|
37
|
+
const a2 = e(o2, i3.field, void 0);
|
|
38
|
+
t3.push(a2);
|
|
38
39
|
} else if ("formula" == i3.type) {
|
|
39
|
-
const e2 =
|
|
40
|
-
|
|
41
|
-
} else
|
|
40
|
+
const e2 = a(i3.formula, S, o2, s2);
|
|
41
|
+
t3.push(e2);
|
|
42
|
+
} else t3.push(void 0);
|
|
42
43
|
}
|
|
43
44
|
}
|
|
44
|
-
|
|
45
|
-
const
|
|
46
|
-
for (const e2 of
|
|
47
|
-
const o2 =
|
|
45
|
+
l.radar[0].indicator = j;
|
|
46
|
+
const w = r.defaultSeries, A = o(w), D = A[0].data;
|
|
47
|
+
for (const e2 of D) {
|
|
48
|
+
const o2 = m[e2.uuid];
|
|
48
49
|
e2.value = o2.data;
|
|
49
50
|
}
|
|
50
|
-
|
|
51
|
+
l.series = A, r.cacheDatas = n, r.rawResult = u;
|
|
51
52
|
}
|
|
52
53
|
export {
|
|
53
|
-
|
|
54
|
+
s as updateChartOption
|
|
54
55
|
};
|
|
@@ -1,45 +1,46 @@
|
|
|
1
1
|
import { getValueFromSource as o } from "../page-helper-util.js";
|
|
2
2
|
import { deepCopy as s } from "../common-util.js";
|
|
3
|
-
import {
|
|
4
|
-
function
|
|
5
|
-
if (!
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
import { setDefaultGrid as i, caculateFormulaValue as e, executeChartFormula as r } from "./chart-util.js";
|
|
4
|
+
function t(t2, a, l, u) {
|
|
5
|
+
if (!u || !u.result) return;
|
|
6
|
+
i(l);
|
|
7
|
+
const f = u && u.result ? u.result : {}, c = a.serviceDataField;
|
|
8
|
+
let d = null;
|
|
9
|
+
c ? d = f[c] : f && (d = Array.isArray(f) ? f : [f]), d || (d = []);
|
|
10
|
+
const n = a.items ? a.items : [], p = [], m = {};
|
|
11
|
+
for (const o2 of n) {
|
|
12
|
+
const s2 = o2.props ? o2.props : {}, i2 = o2.props ? o2.style : {}, e2 = s2.xaxisField, r2 = s2.sizeField, t3 = { uuid: o2.uuid, xaxisField: e2, yaxisField: s2.yaxisField, yaxisSource: s2.yaxisSource, formula: s2.formula, sizeField: r2, symbolSize: i2.symbolSize, data: [] };
|
|
13
|
+
p.push(t3), m[t3.uuid] = t3;
|
|
13
14
|
}
|
|
14
|
-
const
|
|
15
|
-
for (const o2 of
|
|
15
|
+
const x = [], y = e(n, d, x);
|
|
16
|
+
for (const o2 of p) if ("formula" === o2.yaxisSource) {
|
|
16
17
|
let s2 = o2.formula ? o2.formula : "";
|
|
17
|
-
for (const o3 in
|
|
18
|
+
for (const o3 in y) s2 = s2.replace(new RegExp(o3.replace("$", "\\$"), "g"), y[o3]);
|
|
18
19
|
o2.formula = s2;
|
|
19
20
|
}
|
|
20
|
-
const
|
|
21
|
-
for (const s2 of
|
|
22
|
-
for (const i2 of
|
|
21
|
+
const F = {};
|
|
22
|
+
for (const s2 of d) if (s2) {
|
|
23
|
+
for (const i2 of x) {
|
|
23
24
|
const e2 = o(s2, i2, void 0);
|
|
24
|
-
let
|
|
25
|
-
void 0 === e2 || isNaN(e2) || (void 0 ===
|
|
25
|
+
let r2 = F[i2];
|
|
26
|
+
void 0 === e2 || isNaN(e2) || (void 0 === r2 ? r2 = e2 : r2 += e2), F[i2] = r2;
|
|
26
27
|
}
|
|
27
|
-
for (const i2 of
|
|
28
|
-
const
|
|
28
|
+
for (const i2 of p) {
|
|
29
|
+
const e2 = i2.data, a2 = [];
|
|
29
30
|
if (a2.push(o(s2, i2.xaxisField, void 0)), "formula" === i2.yaxisSource) {
|
|
30
|
-
const o2 =
|
|
31
|
+
const o2 = r(i2.formula, F, s2, t2);
|
|
31
32
|
a2.push(o2);
|
|
32
33
|
} else a2.push(o(s2, i2.yaxisField, void 0));
|
|
33
|
-
i2.sizeField ? a2.push(o(s2, i2.xaxisField, void 0)) : a2.push(i2.symbolSize),
|
|
34
|
+
i2.sizeField ? a2.push(o(s2, i2.xaxisField, void 0)) : a2.push(i2.symbolSize), e2.push(a2);
|
|
34
35
|
}
|
|
35
36
|
}
|
|
36
|
-
const
|
|
37
|
-
for (const o2 of
|
|
38
|
-
const s2 =
|
|
37
|
+
const h = a.defaultSeries, S = s(h);
|
|
38
|
+
for (const o2 of S) {
|
|
39
|
+
const s2 = m[o2.uuid];
|
|
39
40
|
o2.data = s2.data;
|
|
40
41
|
}
|
|
41
|
-
|
|
42
|
+
l.series = S, a.cacheDatas = d, a.rawResult = u;
|
|
42
43
|
}
|
|
43
44
|
export {
|
|
44
|
-
|
|
45
|
+
t as updateChartOption
|
|
45
46
|
};
|
|
@@ -110,3 +110,4 @@ export declare function exportCommonChart(chartRef: any): {
|
|
|
110
110
|
fileSize: string;
|
|
111
111
|
};
|
|
112
112
|
export declare function setHomeChartInitConfigValue(initConfig: any, tempContext: any, homeChartSettingUserId: any): void;
|
|
113
|
+
export declare function setDefaultGrid(chartOption: any): void;
|
|
@@ -2,7 +2,7 @@ import t from "../../../../assets/chart-themes/theme1.js";
|
|
|
2
2
|
import e from "../../../../assets/chart-themes/theme2.js";
|
|
3
3
|
import n from "../../../../assets/chart-themes/theme3.js";
|
|
4
4
|
import { getDefaultValue as i } from "../page-init-util.js";
|
|
5
|
-
import { getValueFromSource as s, setValueForVariableName as o, getParamNames as r, formatVariableValue as
|
|
5
|
+
import { getValueFromSource as s, setValueForVariableName as o, getParamNames as r, formatVariableValue as l, getValueFromVariable as a, setVariableValue as c } from "../page-helper-util.js";
|
|
6
6
|
import { appendDefaultMethods as f } from "../events/event-util.js";
|
|
7
7
|
var u = ((t2) => (t2.X_FIELD_NAME = "__x", t2.Y_TEMP_NAME = "__y", t2))(u || {});
|
|
8
8
|
const d = { theme1: t, theme2: e, theme3: n };
|
|
@@ -22,10 +22,10 @@ function m(t2, e2, n2, i2, s2) {
|
|
|
22
22
|
let t3 = parseInt(e2);
|
|
23
23
|
(null == t3 || isNaN(t3)) && (t3 = 2), r2 = parseFloat(parseFloat(r2).toFixed(t3));
|
|
24
24
|
}
|
|
25
|
-
let a2 = "";
|
|
26
|
-
t2.indexOf("prefix") > -1 && n2 && (a2 = n2);
|
|
27
25
|
let l2 = "";
|
|
28
|
-
|
|
26
|
+
t2.indexOf("prefix") > -1 && n2 && (l2 = n2);
|
|
27
|
+
let a2 = "";
|
|
28
|
+
return t2.indexOf("append") > -1 && i2 && (a2 = i2), l2 + r2.toLocaleString() + a2;
|
|
29
29
|
};
|
|
30
30
|
}
|
|
31
31
|
function g(t2, e2) {
|
|
@@ -54,15 +54,15 @@ function x(t2, e2, n2) {
|
|
|
54
54
|
let o2 = e2.highlightInfos ? e2.highlightInfos : [], r2 = -1;
|
|
55
55
|
if (o2) {
|
|
56
56
|
const t3 = [];
|
|
57
|
-
for (let
|
|
58
|
-
const
|
|
57
|
+
for (let l2 = 0; l2 < o2.length; l2++) {
|
|
58
|
+
const a2 = o2[l2], c2 = a2.seriesIndex === s2.seriesIndex && a2.dataIndex === s2.dataIndex;
|
|
59
59
|
if (c2 || !i2.multiple) {
|
|
60
60
|
if (i2.selected) {
|
|
61
61
|
const t4 = "chart-pie" === e2.name ? "unselect" : "downplay";
|
|
62
|
-
n2.dispatchAction({ type: t4, seriesIndex:
|
|
62
|
+
n2.dispatchAction({ type: t4, seriesIndex: a2.seriesIndex, dataIndex: a2.dataIndex });
|
|
63
63
|
}
|
|
64
|
-
} else t3.push(
|
|
65
|
-
c2 && (r2 =
|
|
64
|
+
} else t3.push(a2);
|
|
65
|
+
c2 && (r2 = l2);
|
|
66
66
|
}
|
|
67
67
|
o2 = t3;
|
|
68
68
|
}
|
|
@@ -89,12 +89,12 @@ function b(t2, e2) {
|
|
|
89
89
|
if (!e2.clickSet) return;
|
|
90
90
|
const n2 = e2.clickSet, i2 = n2.variables;
|
|
91
91
|
if (!i2 || 0 == i2.length) return;
|
|
92
|
-
const r2 = e2.highlightInfos ? e2.highlightInfos : [],
|
|
93
|
-
for (const t3 of r2) c2.includes(t3.dataIndex) || (c2.push(t3.dataIndex), t3.dataIndex <
|
|
92
|
+
const r2 = e2.highlightInfos ? e2.highlightInfos : [], l2 = e2.cacheDatas ? e2.cacheDatas : [], a2 = [], c2 = [];
|
|
93
|
+
for (const t3 of r2) c2.includes(t3.dataIndex) || (c2.push(t3.dataIndex), t3.dataIndex < l2.length && a2.push(l2[t3.dataIndex]));
|
|
94
94
|
for (const e3 of i2) {
|
|
95
95
|
if (!e3.fieldName || !e3.variable) continue;
|
|
96
96
|
const i3 = [];
|
|
97
|
-
for (const t3 of
|
|
97
|
+
for (const t3 of a2) {
|
|
98
98
|
const n3 = s(t3, e3.fieldName, void 0);
|
|
99
99
|
null != n3 && i3.push(n3);
|
|
100
100
|
}
|
|
@@ -115,11 +115,11 @@ function v(t2, e2, n2) {
|
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
if (!r2) return;
|
|
118
|
-
const
|
|
118
|
+
const a2 = e2.props ? e2.props.orderSource : "";
|
|
119
119
|
let c2 = e2.props ? e2.props.orderFix : "";
|
|
120
|
-
if ("variable" ==
|
|
120
|
+
if ("variable" == a2) {
|
|
121
121
|
const n3 = e2.props ? e2.props.orderVariable : "";
|
|
122
|
-
c2 =
|
|
122
|
+
c2 = l(t2, n3);
|
|
123
123
|
}
|
|
124
124
|
c2 = "desc" == c2 || "DESC" == c2 ? "desc" : "asc", n2.sort((t3, e3) => {
|
|
125
125
|
const n3 = s(t3, r2, void 0), i3 = s(e3, r2, void 0);
|
|
@@ -130,14 +130,14 @@ function N(t2, e2, n2, i2, o2) {
|
|
|
130
130
|
if (!n2) return n2;
|
|
131
131
|
const r2 = e2.props ? e2.props : {};
|
|
132
132
|
if (!r2.limitQuantity) return n2;
|
|
133
|
-
let
|
|
134
|
-
if (r2.itemNumVariable ? (
|
|
135
|
-
if (n2.length <
|
|
133
|
+
let a2 = null;
|
|
134
|
+
if (r2.itemNumVariable ? (a2 = l(t2, r2.itemNumVariable), a2 = parseInt(a2)) : a2 = r2.itemNumFix ? r2.itemNumFix : 10, null == a2 || null == a2 || isNaN(a2)) return n2;
|
|
135
|
+
if (n2.length < a2) return n2;
|
|
136
136
|
const c2 = r2.overItemAlias, f2 = [], u2 = {};
|
|
137
137
|
i2 = i2 || [], o2 = o2 || [];
|
|
138
138
|
for (let t3 = 0; t3 < n2.length; t3++) {
|
|
139
139
|
const e3 = n2[t3];
|
|
140
|
-
if (t3 <
|
|
140
|
+
if (t3 < a2) f2.push(e3);
|
|
141
141
|
else {
|
|
142
142
|
if (!c2) break;
|
|
143
143
|
for (const t4 of i2) {
|
|
@@ -212,11 +212,11 @@ function k(t2, e2, n2, i2) {
|
|
|
212
212
|
const o2 = r(t2);
|
|
213
213
|
for (const e3 of o2) {
|
|
214
214
|
let o3 = null;
|
|
215
|
-
o3 = e3.startsWith("${row.") ? s(n2, e3.substring(6, e3.length - 1), null) :
|
|
215
|
+
o3 = e3.startsWith("${row.") ? s(n2, e3.substring(6, e3.length - 1), null) : a(i2.entity, e3), t2 = t2.replace(new RegExp(e3.replace("$", "\\$"), "g"), o3);
|
|
216
216
|
}
|
|
217
217
|
t2.includes("return ") || (t2 = "return " + t2);
|
|
218
|
-
const
|
|
219
|
-
return f(
|
|
218
|
+
const l2 = new Function("params", t2);
|
|
219
|
+
return f(l2, i2), l2({ pageContext: i2, row: n2 });
|
|
220
220
|
}
|
|
221
221
|
function M(t2) {
|
|
222
222
|
if (!t2 || !t2.$el) return;
|
|
@@ -245,6 +245,12 @@ function $(t2, e2, n2) {
|
|
|
245
245
|
}
|
|
246
246
|
}
|
|
247
247
|
}
|
|
248
|
+
function w(t2) {
|
|
249
|
+
if (t2 == null ? void 0 : t2.grid) {
|
|
250
|
+
const e2 = t2.grid, n2 = (t3) => !t3 || "0" === t3;
|
|
251
|
+
n2(e2.top) && n2(e2.right) && n2(e2.bottom) && n2(e2.left) && Object.assign(e2, { right: "10%", bottom: "60", left: "10%" });
|
|
252
|
+
}
|
|
253
|
+
}
|
|
248
254
|
export {
|
|
249
255
|
u as CommonName,
|
|
250
256
|
y as caculateFormulaValue,
|
|
@@ -261,6 +267,7 @@ export {
|
|
|
261
267
|
g as initChartOption,
|
|
262
268
|
N as limitDatas,
|
|
263
269
|
x as monitorChartClickToVariable,
|
|
270
|
+
w as setDefaultGrid,
|
|
264
271
|
$ as setHomeChartInitConfigValue,
|
|
265
272
|
v as sortDatas,
|
|
266
273
|
b as updateClickVariablesForSelected
|
|
@@ -27,3 +27,7 @@ export declare function isNumber(numStr: any): boolean;
|
|
|
27
27
|
export declare function isWorkflowPage(pageContext: PageContext): boolean;
|
|
28
28
|
export declare function refreshMobileDialogType(jumpPageSetting: any, isMobile: boolean): void;
|
|
29
29
|
export declare function isVariableInvalidValue(values: any, variable: string): boolean;
|
|
30
|
+
/**
|
|
31
|
+
* 给主表字段添加必填高亮样式
|
|
32
|
+
*/
|
|
33
|
+
export declare function addRequiredClassUtil(): string;
|
|
@@ -99,7 +99,11 @@ function g(e2, t2) {
|
|
|
99
99
|
function h(e2, t2) {
|
|
100
100
|
return null === e2[t2] || void 0 === e2[t2] || "" === e2[t2];
|
|
101
101
|
}
|
|
102
|
+
function y() {
|
|
103
|
+
return "required_bg";
|
|
104
|
+
}
|
|
102
105
|
export {
|
|
106
|
+
y as addRequiredClassUtil,
|
|
103
107
|
p as deepCopy,
|
|
104
108
|
i as getBaseUrl,
|
|
105
109
|
s as getListCode,
|
|
@@ -146,10 +146,10 @@ function F(e2, t2, i2) {
|
|
|
146
146
|
r3 ? n(r3) ? r3.then((n2) => {
|
|
147
147
|
n2 ? A(e2, t2, c2, i2) : e2.canClick = true;
|
|
148
148
|
}).catch((n2) => {
|
|
149
|
-
|
|
149
|
+
e2.canClick = true;
|
|
150
150
|
}) : A(e2, t2, c2, i2) : e2.canClick = true;
|
|
151
151
|
}).catch((n2) => {
|
|
152
|
-
|
|
152
|
+
e2.canClick = true;
|
|
153
153
|
});
|
|
154
154
|
}
|
|
155
155
|
function T(e2, n2, t2, i2, o2) {
|
|
@@ -214,7 +214,7 @@ function A(e2, t2, i2, o2) {
|
|
|
214
214
|
n(a2) ? a2.then((n2) => {
|
|
215
215
|
n2 ? q(e3, t3, o3, c2, n2, u3) : e3.canClick = true;
|
|
216
216
|
}).catch((n2) => {
|
|
217
|
-
|
|
217
|
+
e3.canClick = true;
|
|
218
218
|
}) : q(e3, t3, o3, c2, a2, u3);
|
|
219
219
|
} else q(e3, t3, o3, false, null, u3);
|
|
220
220
|
}(e2, t2, i2, o2);
|
|
@@ -3,27 +3,26 @@ import { hiprint as t, disAutoConnect as n } from "vue-plugin-hiprint";
|
|
|
3
3
|
import { generateCodeByRule as o } from "../barcode-util.js";
|
|
4
4
|
function a(n2, a2) {
|
|
5
5
|
e.post(window.$vueApp.config.globalProperties.baseAPI + "/dc/print-models/by-codes", [a2]).then((e2) => {
|
|
6
|
-
const a3 = JSON.parse(e2[0].template),
|
|
6
|
+
const a3 = JSON.parse(e2[0].template), i2 = [];
|
|
7
7
|
a3.panels.forEach((e3) => {
|
|
8
8
|
e3.printElements.forEach((e4) => {
|
|
9
|
-
"barcode" !== e4.options.textType && "qrcode" !== e4.options.textType ||
|
|
9
|
+
"barcode" !== e4.options.textType && "qrcode" !== e4.options.textType || i2.push(e4.options);
|
|
10
10
|
});
|
|
11
11
|
});
|
|
12
|
-
const
|
|
12
|
+
const l = new t.PrintTemplate({ template: a3 }), r = { callback: () => {
|
|
13
13
|
}, styleHandler: () => "" }, c = { leftOffset: -1, topOffset: -1 }, f = {};
|
|
14
14
|
a3.panels[0].printElements.forEach((e3) => {
|
|
15
15
|
if ("datetime" === e3.options.dataType && e3.options.field) {
|
|
16
16
|
const t2 = e3.options.field.substring(6);
|
|
17
17
|
f[t2] = e3.options.dateFormat;
|
|
18
18
|
}
|
|
19
|
-
}), n2.pageContext.pageType ? "list" === n2.pageContext.pageType ? function(e3, t2, n3, a4, s2,
|
|
20
|
-
const
|
|
21
|
-
if (
|
|
19
|
+
}), n2.pageContext.pageType ? "list" === n2.pageContext.pageType ? function(e3, t2, n3, a4, s2, i3) {
|
|
20
|
+
const l2 = JSON.parse(JSON.stringify(e3.selections));
|
|
21
|
+
if (l2.forEach((e4) => {
|
|
22
22
|
Object.keys(t2).forEach((t3) => {
|
|
23
23
|
if (e4[t3] && "number" == typeof e4[t3] && !isNaN(e4[t3])) try {
|
|
24
24
|
e4[t3] = new Date(e4[t3]);
|
|
25
25
|
} catch (e5) {
|
|
26
|
-
console.error(`日期格式化失败: ${e5}`);
|
|
27
26
|
}
|
|
28
27
|
});
|
|
29
28
|
}), n3.length > 0) {
|
|
@@ -31,51 +30,51 @@ function a(n2, a2) {
|
|
|
31
30
|
n3.forEach((t3) => {
|
|
32
31
|
e4.push(function(e5, t4) {
|
|
33
32
|
return new Promise((n4, a5) => {
|
|
34
|
-
const s3 = e5.field.split("."),
|
|
33
|
+
const s3 = e5.field.split("."), i4 = [];
|
|
35
34
|
s3.length < 2 && n4([]);
|
|
36
35
|
try {
|
|
37
36
|
p(s3[1]).then((e6) => {
|
|
38
37
|
t4.forEach((t5, n5) => {
|
|
39
38
|
const a6 = { type: s3[0], name: s3[1], value: null, index: n5 };
|
|
40
|
-
a6.value = o(JSON.parse(e6.barcodeModelItems), t5),
|
|
41
|
-
}), n4(
|
|
39
|
+
a6.value = o(JSON.parse(e6.barcodeModelItems), t5), i4.push(a6);
|
|
40
|
+
}), n4(i4);
|
|
42
41
|
});
|
|
43
42
|
} catch (e6) {
|
|
44
|
-
|
|
43
|
+
n4([]);
|
|
45
44
|
}
|
|
46
45
|
});
|
|
47
|
-
}(t3,
|
|
46
|
+
}(t3, l2));
|
|
48
47
|
}), Promise.all(e4).then((e5) => {
|
|
49
48
|
e5.forEach((e6) => {
|
|
50
49
|
e6.forEach((e7) => {
|
|
51
|
-
const t3 = e7.index, n4 =
|
|
50
|
+
const t3 = e7.index, n4 = l2[t3];
|
|
52
51
|
n4[e7.type] || (n4[e7.type] = {}), n4[e7.type][e7.name] = e7.value;
|
|
53
52
|
});
|
|
54
|
-
}), a4.print(
|
|
53
|
+
}), a4.print(l2, s2, i3);
|
|
55
54
|
});
|
|
56
|
-
} else a4.print(
|
|
57
|
-
}(n2, f,
|
|
55
|
+
} else a4.print(l2, s2, i3);
|
|
56
|
+
}(n2, f, i2, l, c, r) : "form" === n2.pageContext.pageType && s(n2, i2, l, c, r) : s(n2, i2, l, c, r);
|
|
58
57
|
});
|
|
59
58
|
}
|
|
60
59
|
function s(e2, t2, n2, a2, s2) {
|
|
61
60
|
if (t2.length > 0) {
|
|
62
|
-
const
|
|
61
|
+
const i2 = [];
|
|
63
62
|
t2.forEach((t3) => {
|
|
64
|
-
|
|
63
|
+
i2.push(function(e3, t4) {
|
|
65
64
|
return new Promise((n3, a3) => {
|
|
66
|
-
const s3 = t4.field.split("."),
|
|
67
|
-
s3.length < 2 && n3(
|
|
65
|
+
const s3 = t4.field.split("."), i3 = { type: null, name: null, value: null };
|
|
66
|
+
s3.length < 2 && n3(i3), i3.type = s3[0], i3.name = s3[1];
|
|
68
67
|
try {
|
|
69
|
-
p(
|
|
68
|
+
p(i3.name).then((t5) => {
|
|
70
69
|
const a4 = JSON.parse(t5.barcodeModelItems);
|
|
71
|
-
|
|
70
|
+
i3.value = o(a4, e3.entity.data), n3(i3);
|
|
72
71
|
});
|
|
73
72
|
} catch (e4) {
|
|
74
|
-
|
|
73
|
+
n3(i3);
|
|
75
74
|
}
|
|
76
75
|
});
|
|
77
76
|
}(e2.pageContext, t3));
|
|
78
|
-
}), Promise.all(
|
|
77
|
+
}), Promise.all(i2).then((t3) => {
|
|
79
78
|
const o2 = {};
|
|
80
79
|
t3.forEach((e3) => {
|
|
81
80
|
e3.type && e3.name && e3.value && (o2[e3.type] || (o2[e3.type] = {}), o2[e3.type][e3.name] = e3.value);
|
|
@@ -93,8 +92,8 @@ function p(t2) {
|
|
|
93
92
|
return e.get(window.$vueApp.config.globalProperties.baseAPI + `/dc/setting-barcode-models/by-name?name=${n2}`);
|
|
94
93
|
}
|
|
95
94
|
n();
|
|
96
|
-
const
|
|
95
|
+
const i = { printLabel: a };
|
|
97
96
|
export {
|
|
98
|
-
|
|
97
|
+
i as default,
|
|
99
98
|
a as printLabel
|
|
100
99
|
};
|