super-page-runtime 2.2.0 → 2.2.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/es/_virtual/_plugin-vue_export-helper.js +1 -2
- package/dist/es/components/runtime/index.d.ts +2 -1
- package/dist/es/components/runtime/utils/api/page-expose-util.js +70 -72
- package/dist/es/components/runtime/utils/assemblys-config.js +2 -4
- package/dist/es/components/runtime/utils/barcode-util.js +1 -2
- package/dist/es/components/runtime/utils/charts/chart-columnline-util.js +59 -81
- package/dist/es/components/runtime/utils/charts/chart-gauge-util.js +2 -4
- package/dist/es/components/runtime/utils/charts/chart-pie-util.js +8 -16
- package/dist/es/components/runtime/utils/charts/chart-radar-util.js +10 -18
- package/dist/es/components/runtime/utils/charts/chart-scatter-util.js +20 -25
- package/dist/es/components/runtime/utils/charts/chart-util.d.ts +1 -0
- package/dist/es/components/runtime/utils/charts/chart-util.js +200 -218
- package/dist/es/components/runtime/utils/common-util.js +7 -14
- package/dist/es/components/runtime/utils/events/event-util.js +97 -115
- package/dist/es/components/runtime/utils/events/print-label.js +20 -21
- package/dist/es/components/runtime/utils/events/standard-event.d.ts +2 -2
- package/dist/es/components/runtime/utils/events/standard-event.js +295 -337
- package/dist/es/components/runtime/utils/events/validator-util.js +85 -116
- package/dist/es/components/runtime/utils/form/date-shortcuts.js +1 -2
- package/dist/es/components/runtime/utils/form/scan-util.js +10 -17
- package/dist/es/components/runtime/utils/global-refs.js +7 -14
- package/dist/es/components/runtime/utils/i18n-util.js +1 -2
- package/dist/es/components/runtime/utils/interfaces/page-design-types.d.ts +2 -0
- package/dist/es/components/runtime/utils/page-helper-util.js +66 -116
- package/dist/es/components/runtime/utils/page-init-util.d.ts +6 -1
- package/dist/es/components/runtime/utils/page-init-util.js +65 -69
- package/dist/es/components/runtime/utils/page-permission-util.js +2 -4
- package/dist/es/components/runtime/utils/page-store.d.ts +2 -2
- package/dist/es/components/runtime/utils/table-utils.js +4 -8
- package/dist/es/components/runtime/utils/tree-utils.js +13 -15
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +24 -28
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +44 -40
- package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue.js +44 -0
- package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue2.js +4 -0
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +20 -20
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +20 -20
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +20 -20
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +22 -22
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.d.ts +34 -1
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +205 -170
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue.js +19 -50
- package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +151 -120
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.d.ts +4 -4
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue.d.ts +6 -6
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue.js +9 -11
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.d.ts +6 -6
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +7 -7
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +60 -72
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +91 -95
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +6 -9
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +5 -5
- package/dist/es/components/runtime/views/assemblys/error-render.vue.d.ts +4 -4
- package/dist/es/components/runtime/views/assemblys/error-render.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +6 -8
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue.js +4 -6
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +7 -9
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +10 -13
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +25 -28
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +5 -5
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +9 -10
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +9 -11
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue.js +1 -1
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +15 -20
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +20 -25
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +15 -20
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue2.js +4 -5
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +5 -5
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue.d.ts +17 -0
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue.js +97 -0
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue2.js +4 -0
- package/dist/es/components/runtime/views/assemblys/object-render.vue.d.ts +1 -1
- package/dist/es/components/runtime/views/assemblys/object-render.vue.js +33 -43
- package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/home-chart.vue.d.ts +23 -0
- package/dist/es/components/runtime/views/home-chart.vue.js +36 -0
- package/dist/es/components/runtime/views/home-chart.vue2.js +4 -0
- package/dist/es/components/runtime/views/super-page-dialog.vue.d.ts +3 -3
- package/dist/es/components/runtime/views/super-page-dialog.vue.js +15 -13
- package/dist/es/components/runtime/views/super-page.vue.d.ts +15 -6
- package/dist/es/components/runtime/views/super-page.vue.js +171 -182
- package/dist/es/index.d.ts +2 -2
- package/dist/es/index.js +6 -4
- package/package.json +74 -74
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue3.js +0 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { default as SuperPageNew } from './views/super-page.vue';
|
|
2
2
|
import { default as SuperPageDialogNew } from './views/super-page-dialog.vue';
|
|
3
|
+
import { default as HomeChart } from './views/home-chart.vue';
|
|
3
4
|
|
|
4
|
-
export { SuperPageNew, SuperPageDialogNew };
|
|
5
|
+
export { SuperPageNew, SuperPageDialogNew, HomeChart };
|
|
@@ -1,68 +1,69 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { getOptionDatasSourceMap as e, getComponentOptionDatasFromPage as t, getVariableValue as n, setVariableValue as i, setValueForVariableName as o } from "../page-helper-util.js";
|
|
2
|
+
import { getComponentRef as a, getComponentRefByCode as r } from "../global-refs.js";
|
|
3
3
|
import s from "../eventBus.js";
|
|
4
4
|
import l from "agilebuilder-ui/src/utils/request";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
5
|
+
import { getFormData as c, getAdditionalParamMap as u, refreshPage as f } from "../events/standard-event.js";
|
|
6
|
+
import { dynamicControlTableEdit as m, disabledAllFields as p, updateFormItemEditState as d } from "../events/validator-util.js";
|
|
7
|
+
import { deepCopy as g, getBaseUrl as y } from "../common-util.js";
|
|
8
8
|
import { isMobileBrowser as b } from "agilebuilder-ui/src/utils/common-util";
|
|
9
9
|
import { getFormModelFields as h, getModelFields as E } from "../page-init-util.js";
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
import { getCustomFunc as P } from "../events/event-util.js";
|
|
11
|
+
const C = { showElement: function(e2, t2, n2) {
|
|
12
|
+
n2 ? $(e2, "showElement", t2) : t2.forEach((t3) => {
|
|
13
|
+
const n3 = r(e2, t3);
|
|
13
14
|
n3 && n3.show();
|
|
14
15
|
});
|
|
15
16
|
}, hideElement: function(e2, t2, n2) {
|
|
16
|
-
n2 ?
|
|
17
|
-
const n3 =
|
|
17
|
+
n2 ? $(e2, "hideElement", t2) : t2.forEach((t3) => {
|
|
18
|
+
const n3 = r(e2, t3);
|
|
18
19
|
n3 && n3.hide();
|
|
19
20
|
});
|
|
20
21
|
}, enableElement: function(e2, t2, n2) {
|
|
21
|
-
n2 ?
|
|
22
|
-
const n3 =
|
|
22
|
+
n2 ? $(e2, "enableElement", t2) : t2.forEach((t3) => {
|
|
23
|
+
const n3 = r(e2, t3);
|
|
23
24
|
if (n3) {
|
|
24
25
|
const e3 = n3.getConfigure();
|
|
25
26
|
e3 && e3.runtime.props && (e3.runtime.props.state = "enabled");
|
|
26
27
|
}
|
|
27
28
|
});
|
|
28
29
|
}, disableElement: function(e2, t2, n2) {
|
|
29
|
-
n2 ?
|
|
30
|
-
const n3 =
|
|
30
|
+
n2 ? $(e2, "disableElement", t2) : t2.forEach((t3) => {
|
|
31
|
+
const n3 = r(e2, t3);
|
|
31
32
|
if (n3) {
|
|
32
33
|
const e3 = n3.getConfigure();
|
|
33
34
|
e3 && e3.runtime.props && (e3.runtime.props.state = "disabled");
|
|
34
35
|
}
|
|
35
36
|
});
|
|
36
|
-
}, setEntityDataValue: function(
|
|
37
|
-
Object.keys(
|
|
38
|
-
|
|
37
|
+
}, setEntityDataValue: function(e2, t2) {
|
|
38
|
+
Object.keys(t2).forEach((n2) => {
|
|
39
|
+
o(e2.entity, n2.startsWith("${") ? n2 : "${data." + n2 + "}", t2[n2]);
|
|
39
40
|
});
|
|
40
|
-
}, setEntityPageValue: function(
|
|
41
|
-
Object.keys(
|
|
42
|
-
|
|
41
|
+
}, setEntityPageValue: function(e2, t2) {
|
|
42
|
+
Object.keys(t2).forEach((n2) => {
|
|
43
|
+
o(e2.entity, n2.startsWith("${") ? n2 : "${page." + n2 + "}", t2[n2]);
|
|
43
44
|
});
|
|
44
|
-
}, setEntityValueByType: function(t2, n2
|
|
45
|
-
Object.keys(
|
|
46
|
-
|
|
45
|
+
}, setEntityValueByType: function(e2, t2, n2) {
|
|
46
|
+
Object.keys(n2).forEach((i2) => {
|
|
47
|
+
o(e2.entity, i2.startsWith("${") ? i2 : "${" + t2 + "." + i2 + "}", n2[i2]);
|
|
47
48
|
});
|
|
48
49
|
}, dynamicControlFormEdit: function(e2, t2, n2) {
|
|
49
|
-
n2 ?
|
|
50
|
+
n2 ? $(e2, "dynamicControlFormEdit", t2) : d(e2, t2);
|
|
50
51
|
}, disabledAllFields(e2) {
|
|
51
52
|
p(e2);
|
|
52
53
|
}, dynamicControlTableEdit(e2, t2, n2) {
|
|
53
|
-
|
|
54
|
+
m(e2, t2, n2);
|
|
54
55
|
}, executeServiceFlow: function(e2, t2, n2) {
|
|
55
56
|
const i2 = e2.code;
|
|
56
|
-
n2 || (n2 = { entity: e2.entity.data, serviceVariables: {}, requestParams:
|
|
57
|
-
const o2 = e2.backendUrl, a2 =
|
|
57
|
+
n2 || (n2 = { entity: e2.entity.data, serviceVariables: {}, requestParams: u(e2), taskParamMap: e2.entity.task, dynamicDimensionValue: [], dynamicSortValue: "" }), n2.entity || (n2.entity = e2.entity.data), n2.requestParams || (n2.requestParams = u(e2)), n2.taskParamMap || (n2.taskParamMap = e2.entity.task);
|
|
58
|
+
const o2 = e2.backendUrl, a2 = y(o2, e2.isTest);
|
|
58
59
|
return l.post(`${a2}/dsc/service-flow/execute/${i2}/${t2}`, n2);
|
|
59
60
|
}, openPage: function(e2, t2) {
|
|
60
61
|
s.$emit(e2.code + "_open-dialog", { pageContext: e2, eventParams: t2.eventParams, configureObj: { props: { linkPage: t2 } } });
|
|
61
62
|
}, refreshPage: function(e2, t2) {
|
|
62
|
-
|
|
63
|
+
f(e2, t2);
|
|
63
64
|
}, refreshSubTableHandle: function(e2, t2) {
|
|
64
65
|
let n2;
|
|
65
|
-
const i2 =
|
|
66
|
+
const i2 = r(e2, t2);
|
|
66
67
|
if (i2) {
|
|
67
68
|
const e3 = i2.getConfigure();
|
|
68
69
|
e3 && e3.uuid && e3.name && "table" === e3.name && (n2 = e3.uuid);
|
|
@@ -70,7 +71,7 @@ const P = { showElement: function(e2, t2, n2) {
|
|
|
70
71
|
n2 && s.$emit("_refreshSubTableHandle_" + n2);
|
|
71
72
|
}, refreshChildData(e2, t2, n2) {
|
|
72
73
|
let i2;
|
|
73
|
-
const o2 =
|
|
74
|
+
const o2 = r(e2, t2);
|
|
74
75
|
if (o2) {
|
|
75
76
|
const e3 = o2.getConfigure();
|
|
76
77
|
e3 && e3.uuid && e3.name && "table" === e3.name && (i2 = e3.uuid);
|
|
@@ -78,42 +79,41 @@ const P = { showElement: function(e2, t2, n2) {
|
|
|
78
79
|
i2 && setTimeout(() => {
|
|
79
80
|
s.$emit("_refreshChildData_" + i2, n2);
|
|
80
81
|
}, 10);
|
|
81
|
-
}, getServerConfigValue: (e2) => window.$vueApp.config.globalProperties[e2], getBackendUrl: (e2) =>
|
|
82
|
-
const n2 =
|
|
82
|
+
}, getServerConfigValue: (e2) => window.$vueApp.config.globalProperties[e2], getBackendUrl: (e2) => y(e2.backendUrl, false), getPlateBackendUrl: () => window.$vueApp.config.globalProperties.baseAPI, getEntity: (e2) => e2.entity.data, getEntityValue: (e2, t2) => e2.entity.data ? e2.entity.data[t2] : null, getPageData: (e2) => e2.entity.page, getPageDataValue: (e2, t2) => e2.entity.page ? e2.entity.page[t2] : null, getAdditionalParams: (e2) => u(e2), getAdditionalParamValue(e2, t2) {
|
|
83
|
+
const n2 = u(e2);
|
|
83
84
|
return n2 ? n2[t2] : null;
|
|
84
|
-
}, isMobile: () => b(), getComponentRefByProp: (e2, t2) =>
|
|
85
|
+
}, isMobile: () => b(), getComponentRefByProp: (e2, t2) => r(e2, t2), getComponentRefByCode: (e2, t2) => a(e2, t2), getFormViewData(o2) {
|
|
85
86
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
86
|
-
const
|
|
87
|
-
for (const
|
|
88
|
-
const
|
|
87
|
+
const r2 = o2.entity ? o2.entity : {}, s2 = g(r2), l2 = e(o2);
|
|
88
|
+
for (const e2 in l2) {
|
|
89
|
+
const r3 = t(o2, e2), l3 = a(o2, e2);
|
|
89
90
|
if (l3) {
|
|
90
|
-
const
|
|
91
|
-
if (
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
o(s2, n2, e3);
|
|
97
|
-
}
|
|
98
|
-
} else {
|
|
99
|
-
const n2 = h(e2, t3), r2 = C(i(s2, n2), a3);
|
|
100
|
-
o(s2, n2, r2);
|
|
91
|
+
const e3 = l3.getConfigure();
|
|
92
|
+
if (e3 && ((_b = (_a = e3.props) == null ? void 0 : _a.dataOrigin) == null ? void 0 : _b.optionValueSetType) && ("static" === ((_d = (_c = e3.props) == null ? void 0 : _c.dataOrigin) == null ? void 0 : _d.optionValueSetType) || "optionGroup" === ((_f = (_e = e3.props) == null ? void 0 : _e.dataOrigin) == null ? void 0 : _f.optionValueSetType))) if (e3.name && ("select" === e3.name && ((_h = (_g = e3.props) == null ? void 0 : _g.base) == null ? void 0 : _h.multiple) || "checkbox" === e3.name)) {
|
|
93
|
+
const t2 = h(o2, e3), a2 = n(s2, t2);
|
|
94
|
+
if (a2) {
|
|
95
|
+
const e4 = v(a2.split(","), r3);
|
|
96
|
+
i(s2, t2, e4);
|
|
101
97
|
}
|
|
98
|
+
} else {
|
|
99
|
+
const t2 = h(o2, e3), a2 = v(n(s2, t2), r3);
|
|
100
|
+
i(s2, t2, a2);
|
|
101
|
+
}
|
|
102
102
|
}
|
|
103
103
|
}
|
|
104
|
-
const c2 =
|
|
105
|
-
for (const
|
|
106
|
-
let
|
|
107
|
-
if (
|
|
108
|
-
const
|
|
109
|
-
if (
|
|
110
|
-
const
|
|
111
|
-
k(
|
|
104
|
+
const c2 = o2.listCodesMap;
|
|
105
|
+
for (const e2 in c2) {
|
|
106
|
+
let t2;
|
|
107
|
+
if (e2.indexOf("__") > 0 && (t2 = e2.substring(e2.lastIndexOf("__") + 2)), t2) {
|
|
108
|
+
const i2 = a(o2, t2);
|
|
109
|
+
if (i2) {
|
|
110
|
+
const t3 = i2.getConfigure(), o3 = t3.code ? t3.code : e2, a2 = E(t3, o3), r3 = n(s2, a2);
|
|
111
|
+
k(i2.getTableSelectOptions(e2), r3);
|
|
112
112
|
}
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
115
|
return s2.data;
|
|
116
|
-
}, getFormData: (e2, t2) =>
|
|
116
|
+
}, getFormData: (e2, t2) => c(e2, t2), getCustomFunc: (e2, t2) => P(e2, t2) };
|
|
117
117
|
function k(e2, t2) {
|
|
118
118
|
e2 && t2 && t2.forEach((t3) => {
|
|
119
119
|
Object.keys(e2).forEach((n2) => {
|
|
@@ -121,35 +121,33 @@ function k(e2, t2) {
|
|
|
121
121
|
let s2;
|
|
122
122
|
if (r2 && r2.componentType && ("multiselect" === r2.componentType || "checkbox" === r2.componentType)) {
|
|
123
123
|
if (i2) {
|
|
124
|
-
s2 =
|
|
124
|
+
s2 = v(i2.split(","), a2);
|
|
125
125
|
}
|
|
126
|
-
} else
|
|
127
|
-
s2 = C(i2, a2);
|
|
126
|
+
} else s2 = v(i2, a2);
|
|
128
127
|
t3[n2] = s2;
|
|
129
128
|
});
|
|
130
129
|
});
|
|
131
130
|
}
|
|
132
|
-
function
|
|
131
|
+
function v(e2, t2) {
|
|
133
132
|
let n2;
|
|
134
133
|
return null != e2 && t2 && (Array.isArray(e2) ? (n2 = "", e2.forEach((i2) => {
|
|
135
|
-
n2 = n2 +
|
|
136
|
-
}), n2.indexOf(",") > 0 && (n2 = n2.substring(0, n2.lastIndexOf(",")))) : (n2 = e2, n2 =
|
|
134
|
+
n2 = n2 + V(e2, t2) + ",";
|
|
135
|
+
}), n2.indexOf(",") > 0 && (n2 = n2.substring(0, n2.lastIndexOf(",")))) : (n2 = e2, n2 = V(e2, t2))), n2;
|
|
137
136
|
}
|
|
138
|
-
function
|
|
137
|
+
function V(e2, t2) {
|
|
139
138
|
let n2 = e2;
|
|
140
|
-
if (null != e2 && t2)
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
break;
|
|
146
|
-
}
|
|
139
|
+
if (null != e2 && t2) for (let i2 = 0; i2 < t2.length; i2++) {
|
|
140
|
+
const o2 = t2[i2].value, a2 = t2[i2].label ? t2[i2].label : t2[i2].name;
|
|
141
|
+
if (e2 + "" == o2 + "" && null != a2) {
|
|
142
|
+
n2 = a2;
|
|
143
|
+
break;
|
|
147
144
|
}
|
|
145
|
+
}
|
|
148
146
|
return n2;
|
|
149
147
|
}
|
|
150
|
-
function
|
|
148
|
+
function $(e2, t2, n2) {
|
|
151
149
|
e2.initInfo || (e2.initInfo = {}), e2.initInfo[t2] = n2;
|
|
152
150
|
}
|
|
153
151
|
export {
|
|
154
|
-
|
|
152
|
+
C as functions
|
|
155
153
|
};
|
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
import { defineAsyncComponent as e } from "vue";
|
|
2
2
|
const t = [{ name: "container", label: "容器", icon: "assets/images/group-container.png", items: [{ name: "form", label: "表单", runtimeComponent: e(() => import("../views/assemblys/container/form/form-runtime.vue.js")) }, { name: "card", label: "卡片", runtimeComponent: e(() => import("../views/assemblys/container/card/card-runtime.vue.js")) }, { name: "collapse", label: "折叠面板", runtimeComponent: e(() => import("../views/assemblys/container/collapse/collapse-runtime.vue.js")) }, { name: "layout", label: "Flex", runtimeComponent: e(() => import("../views/assemblys/container/flex/flex-runtime.vue.js")) }, { name: "tabs", label: "Tabs", runtimeComponent: e(() => import("../views/assemblys/container/tabs/tabs-runtime.vue.js")) }, { name: "tools", label: "工具栏", runtimeComponent: e(() => import("../views/assemblys/container/tools/tools-runtime.vue.js")) }, { name: "iframe", label: "Iframe", runtimeComponent: e(() => import("../views/assemblys/container/iframe/iframe-runtime.vue.js")) }, { name: "container", label: "布局", runtimeComponent: e(() => import("../views/assemblys/container/container/container-runtime.vue.js")) }] }, { name: "form", label: "表单", items: [{ name: "input-text", label: "文本框", runtimeComponent: e(() => import("../views/assemblys/form/input-text/inputtext-runtime.vue.js")) }, { name: "select", label: "下拉框", runtimeComponent: e(() => import("../views/assemblys/form/select/select-runtime.vue.js")) }, { name: "radio", label: "单选框", runtimeComponent: e(() => import("../views/assemblys/form/radio/radio-runtime.vue.js")) }, { name: "checkbox", label: "复选框", runtimeComponent: e(() => import("../views/assemblys/form/checkbox/checkbox-runtime.vue.js")) }, { name: "textarea", label: "文本域", runtimeComponent: e(() => import("../views/assemblys/form/textarea/textarea-runtime.vue.js")) }, { name: "datePicker", label: "日期/时间", runtimeComponent: e(() => import("../views/assemblys/form/date-picker/datepicker-runtime.vue.js")) }, { name: "switch", label: "开关", runtimeComponent: e(() => import("../views/assemblys/form/switch/switch-runtime.vue.js")) }, { name: "inputNumber", label: "计数器", runtimeComponent: e(() => import("../views/assemblys/form/input-number/input-number-runtime.vue.js")) }, { name: "tag", label: "标签", runtimeComponent: e(() => import("../views/assemblys/form/tag/tag-runtime.vue.js")) }, { name: "richText", label: "富文本", runtimeComponent: e(() => import("../views/assemblys/form/rich-text/richtext-runtime.vue.js")) }, { name: "divider", label: "分割线", runtimeComponent: e(() => import("../views/assemblys/form/divider/divider-runtime.vue.js")) }, { name: "separatelabel", label: "分割标签", runtimeComponent: e(() => import("../views/assemblys/form/separatelabel/separatelabel-runtime.vue.js")) }, { name: "placeholder", label: "占位符", runtimeComponent: e(() => import("../views/assemblys/form/placeholder/placeholder-runtime.vue.js")) }, { name: "link", label: "链接", runtimeComponent: e(() => import("../views/assemblys/form/link/link-runtime.vue.js")) }, { name: "label", label: "Label组件", runtimeComponent: e(() => import("../views/assemblys/form/label/label-runtime.vue.js")) }, { name: "dept-tree", label: "组织树", runtimeComponent: e(() => import("../views/assemblys/form/dept-tree/depttree-runtime.vue.js")) }, { name: "file-upload", label: "文件上传", runtimeComponent: e(() => import("../views/assemblys/form/file-upload/fileupload-runtime.vue.js")) }] }, { name: "button", label: "按钮", items: [{ name: "button-detail", label: "按钮", runtimeComponent: e(() => import("../views/assemblys/button/button/button-runtime.vue.js")) }, { name: "button-group", label: "按钮组", runtimeComponent: e(() => import("../views/assemblys/button/button-group/buttongroup-runtime.vue.js")) }, { name: "dropdown", label: "下拉菜单", runtimeComponent: e(() => import("../views/assemblys/button/dropdown/dropdown-runtime.vue.js")) }, { name: "print-label", label: "打印标签", runtimeComponent: e(() => import("../views/assemblys/button/print-label/printlabel-runtime.vue.js")) }, { name: "export-pdf", label: "打印标签", runtimeComponent: e(() => import("../views/assemblys/button/export-pdf/exportpdf-runtime.vue.js")) }] }, { name: "workflow", label: "工作流", items: [{ name: "workflow-button", label: "工作流按钮", runtimeComponent: e(() => import("../views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue.js")) }, { name: "picture-flow", label: "图形历史", runtimeComponent: e(() => import("../views/assemblys/workflow/picture-flow/pictureflow-runtime.vue.js")) }, { name: "text-flow", label: "文本历史", runtimeComponent: e(() => import("../views/assemblys/workflow/text-history/textflow-runtime.vue.js")) }, { name: "workflow-node", label: "流程环节", runtimeComponent: e(() => import("../views/assemblys/workflow/workflow-node/workflownode-runtime.vue.js")) }] }, { name: "chart", label: "统计图", items: [{ name: "chart-column-line", label: "柱/折图", runtimeComponent: e(() => import("../views/assemblys/chart/column-line/column-line-runtime.vue.js")) }, { name: "chart-pie", label: "饼图", runtimeComponent: e(() => import("../views/assemblys/chart/pie/pie-runtime.vue.js")) }, { name: "chart-gauge", label: "仪表盘", runtimeComponent: e(() => import("../views/assemblys/chart/gauge/gauge-runtime.vue.js")) }, { name: "chart-radar", label: "雷达图", runtimeComponent: e(() => import("../views/assemblys/chart/radar/radar-runtime.vue.js")) }, { name: "chart-scatter", label: "散点图", runtimeComponent: e(() => import("../views/assemblys/chart/scatter/scatter-runtime.vue.js")) }, { name: "statistical-table", label: "统计表格", runtimeComponent: e(() => import("../views/assemblys/chart/table/table-runtime.vue.js")) }] }, { name: "data", label: "数据", items: [{ name: "table", label: "表格", runtimeComponent: e(() => import("../views/assemblys/data/table/table-runtime.vue.js")) }, { name: "tree", label: "树控件", runtimeComponent: e(() => import("../views/assemblys/data/tree/tree-runtime.vue.js")) }, { name: "bar-code", label: "条码", runtimeComponent: e(() => import("../views/assemblys/data/bar-code/barcode-runtime.vue.js")) }] }, { name: "other", label: "其他", items: [{ name: "custom", label: "自定义", runtimeComponent: e(() => import("../views/assemblys/form/custom/custom-runtime.vue.js")) }] }];
|
|
3
3
|
function m(e2) {
|
|
4
|
-
if (!e2)
|
|
5
|
-
return null;
|
|
4
|
+
if (!e2) return null;
|
|
6
5
|
for (let m2 = 0; m2 < t.length; m2++) {
|
|
7
6
|
let n = t[m2].items;
|
|
8
7
|
for (let t2 = 0; t2 < n.length; t2++) {
|
|
9
8
|
let m3 = n[t2];
|
|
10
|
-
if (m3.name == e2)
|
|
11
|
-
return m3.runtimeComponent;
|
|
9
|
+
if (m3.name == e2) return m3.runtimeComponent;
|
|
12
10
|
}
|
|
13
11
|
}
|
|
14
12
|
return null;
|
|
@@ -4,8 +4,7 @@ function e(e2, t) {
|
|
|
4
4
|
if ("-1" !== e3.propDbName && -1 !== e3.propDbName) {
|
|
5
5
|
const a = t[e3.propDbName];
|
|
6
6
|
e3.supplementaryCharacters && e3.length ? a ? a.length > e3.length ? r += a.substring(0, e3.length) : r += a.padEnd(e3.length, e3.supplementaryCharacters) : r += "".padEnd(e3.length, e3.supplementaryCharacters) : a ? r += a : n = false;
|
|
7
|
-
} else
|
|
8
|
-
r += e3.fixedValue;
|
|
7
|
+
} else r += e3.fixedValue;
|
|
9
8
|
}), n ? r : null;
|
|
10
9
|
}
|
|
11
10
|
export {
|
|
@@ -3,8 +3,7 @@ import { deepCopy as s } from "../common-util.js";
|
|
|
3
3
|
import { CommonName as o, caculateFormulaValue as a, sortDatas as l, limitDatas as n, executeChartFormula as u } from "./chart-util.js";
|
|
4
4
|
import { handleChartEvent as r } from "../events/event-util.js";
|
|
5
5
|
function c(c2, d, f, p) {
|
|
6
|
-
if (!p || !p.result)
|
|
7
|
-
return;
|
|
6
|
+
if (!p || !p.result) return;
|
|
8
7
|
r(c2, d, "beforeUpdateChart", f, { resultData: p });
|
|
9
8
|
const m = p && p.result ? p.result : {};
|
|
10
9
|
let h = p && p.groupValue ? p.groupValue : void 0;
|
|
@@ -14,17 +13,14 @@ function c(c2, d, f, p) {
|
|
|
14
13
|
let v = d.props ? d.props.groups : null;
|
|
15
14
|
if (v || (v = []), !h || 0 === h.length) {
|
|
16
15
|
h = [];
|
|
17
|
-
for (const e2 of v)
|
|
18
|
-
h.push(e2.group);
|
|
16
|
+
for (const e2 of v) h.push(e2.group);
|
|
19
17
|
}
|
|
20
18
|
const F = {}, D = [], S = [];
|
|
21
|
-
for (const e2 of v)
|
|
22
|
-
F[e2.group] = e2.target, e2.target && !D.includes(e2.target) && (D.push(e2.target), h.includes(e2.group) && S.push(e2.target));
|
|
19
|
+
for (const e2 of v) F[e2.group] = e2.target, e2.target && !D.includes(e2.target) && (D.push(e2.target), h.includes(e2.group) && S.push(e2.target));
|
|
23
20
|
let x = d.props ? d.props.mulGroupShow : "";
|
|
24
21
|
x = "break" == x ? "\r\n" : " ";
|
|
25
22
|
for (const i2 of g) {
|
|
26
|
-
if (!i2)
|
|
27
|
-
continue;
|
|
23
|
+
if (!i2) continue;
|
|
28
24
|
const t2 = [];
|
|
29
25
|
for (const s3 of h) {
|
|
30
26
|
const o2 = F[s3], a2 = e(i2, o2, void 0);
|
|
@@ -34,51 +30,41 @@ function c(c2, d, f, p) {
|
|
|
34
30
|
i2[o.X_FIELD_NAME] = s2;
|
|
35
31
|
}
|
|
36
32
|
const N = d.items ? d.items : [], E = [], A = {}, _ = [], b = {}, C = [], I = [], X = [], w = a(N, g, X);
|
|
37
|
-
for (const e2 of X)
|
|
38
|
-
C.push(e2);
|
|
33
|
+
for (const e2 of X) C.push(e2);
|
|
39
34
|
for (const e2 of N) {
|
|
40
35
|
const i2 = e2.props ? e2.props : {}, t2 = i2.yaxisSource, s2 = i2.yaxisField, o2 = i2.isCumulative;
|
|
41
36
|
let a2 = null;
|
|
42
|
-
if (!s2 || t2 && "variable" != t2)
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
} else
|
|
49
|
-
a2 = { uuid: e2.uuid, type: "fixed", field: i2.yaxisFix, data: [], dynamicDatas: [] };
|
|
50
|
-
else
|
|
51
|
-
a2 = { uuid: e2.uuid, type: "variable", field: s2, isCumulative: o2, data: [], dynamicDatas: [] }, s2 && !C.includes(s2) && (C.push(s2), I.push(s2)), o2 && !X.includes(s2) && X.push(s2);
|
|
37
|
+
if (!s2 || t2 && "variable" != t2) if ("formula" == t2) {
|
|
38
|
+
let t3 = i2.formula ? i2.formula : "";
|
|
39
|
+
for (const e3 in w) t3 = t3.replace(new RegExp(e3.replace("$", "\\$"), "g"), w[e3]);
|
|
40
|
+
a2 = { uuid: e2.uuid, type: "formula", formula: t3, data: [], dynamicDatas: [] };
|
|
41
|
+
} else a2 = { uuid: e2.uuid, type: "fixed", field: i2.yaxisFix, data: [], dynamicDatas: [] };
|
|
42
|
+
else a2 = { uuid: e2.uuid, type: "variable", field: s2, isCumulative: o2, data: [], dynamicDatas: [] }, s2 && !C.includes(s2) && (C.push(s2), I.push(s2)), o2 && !X.includes(s2) && X.push(s2);
|
|
52
43
|
null != a2 && (E.push(a2), A[e2.uuid] = a2), i2.dynamicSeriesField && !_.includes(i2.dynamicSeriesField) && a2 && (a2.dynamicField = i2.dynamicSeriesField, a2.dynamicSeriesTitle = i2.dynamicSeriesTitle, a2.dynamicShowStack = i2.dynamicShowStack, _.push(i2.dynamicSeriesField), b[i2.dynamicSeriesField] = s2);
|
|
53
44
|
}
|
|
54
45
|
const L = {};
|
|
55
46
|
if (_.length > 0) {
|
|
56
47
|
const i2 = [], t2 = {};
|
|
57
|
-
for (const s2 of g)
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
isNaN || (u2 += e2), n2[a2] = u2;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
48
|
+
for (const s2 of g) if (s2) for (const a2 of C) {
|
|
49
|
+
const l2 = s2[o.X_FIELD_NAME];
|
|
50
|
+
let n2 = t2[l2];
|
|
51
|
+
if (!n2) {
|
|
52
|
+
n2 = {};
|
|
53
|
+
for (const e2 of D) n2[e2] = s2[e2];
|
|
54
|
+
n2[o.X_FIELD_NAME] = s2[o.X_FIELD_NAME], t2[l2] = n2, i2.push(n2);
|
|
55
|
+
}
|
|
56
|
+
let u2 = e(s2, a2, void 0);
|
|
57
|
+
if (!isNaN(u2)) {
|
|
58
|
+
const e2 = n2[a2];
|
|
59
|
+
isNaN || (u2 += e2), n2[a2] = u2;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
74
62
|
for (const i3 of _) {
|
|
75
63
|
const s2 = [];
|
|
76
64
|
for (const a2 of g) {
|
|
77
|
-
if (!a2)
|
|
78
|
-
continue;
|
|
65
|
+
if (!a2) continue;
|
|
79
66
|
const l2 = t2[a2[o.X_FIELD_NAME]];
|
|
80
|
-
if (!l2)
|
|
81
|
-
continue;
|
|
67
|
+
if (!l2) continue;
|
|
82
68
|
let n2 = e(a2, i3, void 0);
|
|
83
69
|
n2 = null == n2 || null == n2 ? "" : n2, s2.includes(n2) || (s2.push(n2), I.push(n2), X.push(n2));
|
|
84
70
|
const u2 = b[i3];
|
|
@@ -94,38 +80,35 @@ function c(c2, d, f, p) {
|
|
|
94
80
|
}
|
|
95
81
|
l(c2, d, g), g = n(c2, d, g, D, I);
|
|
96
82
|
const M = [], j = {};
|
|
97
|
-
for (const i2 of g)
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
s2.push(e2);
|
|
125
|
-
} else
|
|
126
|
-
s2.push(void 0);
|
|
127
|
-
}
|
|
83
|
+
for (const i2 of g) if (i2) {
|
|
84
|
+
for (const t2 of X) {
|
|
85
|
+
const s2 = e(i2, t2, void 0);
|
|
86
|
+
let o2 = j[t2];
|
|
87
|
+
void 0 === s2 || isNaN(s2) || (void 0 === o2 ? o2 = s2 : o2 += s2), j[t2] = o2;
|
|
88
|
+
}
|
|
89
|
+
M.push(i2[o.X_FIELD_NAME]);
|
|
90
|
+
for (const t2 of E) {
|
|
91
|
+
let s2 = t2.data;
|
|
92
|
+
const o2 = t2.dynamicDatas;
|
|
93
|
+
if (t2.dynamicField) {
|
|
94
|
+
let a2 = L[t2.dynamicField];
|
|
95
|
+
a2 = a2 || [];
|
|
96
|
+
for (let l2 = 0; l2 < a2.length; l2++) {
|
|
97
|
+
l2 >= o2.length && o2.push([]), s2 = o2[l2];
|
|
98
|
+
const n2 = a2[l2];
|
|
99
|
+
let u2 = e(i2, n2, void 0);
|
|
100
|
+
t2.isCumulative && (u2 = j[n2]), s2.push(u2);
|
|
101
|
+
}
|
|
102
|
+
} else if ("fixed" === t2.type) s2.push(t2.field);
|
|
103
|
+
else if ("variable" === t2.type) {
|
|
104
|
+
let o3 = e(i2, t2.field, void 0);
|
|
105
|
+
t2.isCumulative && (o3 = j[t2.field]), s2.push(o3);
|
|
106
|
+
} else if ("formula" === t2.type) {
|
|
107
|
+
const e2 = u(t2.formula, j, i2, c2);
|
|
108
|
+
s2.push(e2);
|
|
109
|
+
} else s2.push(void 0);
|
|
128
110
|
}
|
|
111
|
+
}
|
|
129
112
|
const k = d.defaultSeries, T = s(null == k ? [] : k), V = [];
|
|
130
113
|
for (const e2 of T) {
|
|
131
114
|
const t2 = A[e2.uuid];
|
|
@@ -138,22 +121,17 @@ function c(c2, d, f, p) {
|
|
|
138
121
|
if (t2.dynamicSeriesTitle) {
|
|
139
122
|
const e3 = t2.dynamicSeriesTitle.replace("${name}", n2);
|
|
140
123
|
u2.name = i(c2, e3);
|
|
141
|
-
} else
|
|
142
|
-
u2.name = n2;
|
|
124
|
+
} else u2.name = n2;
|
|
143
125
|
u2.data = l2 < a2.length ? a2[l2] : [], "bar" == e2.type && t2.dynamicShowStack && (u2.stack = e2.uuid), V.push(u2);
|
|
144
126
|
}
|
|
145
|
-
} else
|
|
146
|
-
e2.data = t2 ? t2.data : [], V.push(e2);
|
|
127
|
+
} else e2.data = t2 ? t2.data : [], V.push(e2);
|
|
147
128
|
}
|
|
148
129
|
f.series = V;
|
|
149
130
|
const $ = d.defaultXaxis, G = d.defaultYaxis;
|
|
150
131
|
if (f.isBar) {
|
|
151
|
-
if (G)
|
|
152
|
-
for (const e2 of G)
|
|
153
|
-
e2.data = M;
|
|
132
|
+
if (G) for (const e2 of G) e2.data = M;
|
|
154
133
|
f.xAxis = $, f.yAxis = G;
|
|
155
|
-
} else
|
|
156
|
-
$ && $.length > 0 && ($[0].data = M), f.xAxis = $, f.yAxis = G;
|
|
134
|
+
} else $ && $.length > 0 && ($[0].data = M), f.xAxis = $, f.yAxis = G;
|
|
157
135
|
const R = d.props ? d.props.selGroupVariable : null;
|
|
158
136
|
!(d.props ? d.props.enableDrill : null) && R && (d.highlightInfos = [], t(c2.entity, R, null)), r(c2, d, "afterUpdateChart", f, { resultData: p }), d.groupFields = S, d.cacheDatas = g, d.rawResult = p;
|
|
159
137
|
}
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import { formatVariableValue as e, getValueFromSource as o } from "../page-helper-util.js";
|
|
2
2
|
import { deepCopy as t } from "../common-util.js";
|
|
3
3
|
function s(s2, l, r, i) {
|
|
4
|
-
if (!i || !i.result)
|
|
5
|
-
return;
|
|
4
|
+
if (!i || !i.result) return;
|
|
6
5
|
const p = i && i.result ? i.result : {}, n = l.serviceDataField;
|
|
7
6
|
let a = null;
|
|
8
7
|
n ? a = p[n] : p && (a = [p]), a || (a = []);
|
|
9
8
|
const u = l.props ? l.props.nameSource : void 0, c = l.props ? l.props.nameField : void 0, d = l.props ? l.props.nameFixed : void 0, m = l.props ? l.props.yaxisField : void 0, f = [c], h = [], v = [];
|
|
10
9
|
for (let t2 of a) {
|
|
11
|
-
if (!t2)
|
|
12
|
-
continue;
|
|
10
|
+
if (!t2) continue;
|
|
13
11
|
let l2 = null;
|
|
14
12
|
l2 = "fixed" == u ? e(s2, d) : o(t2, c, void 0), h.push(l2);
|
|
15
13
|
const r2 = o(t2, m, void 0);
|
|
@@ -2,8 +2,7 @@ import { getValueFromSource as o, setValueForVariableName as t } from "../page-h
|
|
|
2
2
|
import { deepCopy as r } from "../common-util.js";
|
|
3
3
|
import { CommonName as s, caculateFormulaValue as e, executeChartFormula as l, sortDatas as n, limitDatas as p } from "./chart-util.js";
|
|
4
4
|
function i(i2, u, c, a) {
|
|
5
|
-
if (!a || !a.result)
|
|
6
|
-
return;
|
|
5
|
+
if (!a || !a.result) return;
|
|
7
6
|
const f = a && a.result ? a.result : {};
|
|
8
7
|
let g = a && a.groupValue ? a.groupValue : void 0;
|
|
9
8
|
const m = u.serviceDataField;
|
|
@@ -12,17 +11,14 @@ function i(i2, u, c, a) {
|
|
|
12
11
|
let d = u.props ? u.props.groups : null;
|
|
13
12
|
if (d || (d = []), !g || 0 === g.length) {
|
|
14
13
|
g = [];
|
|
15
|
-
for (const o2 of d)
|
|
16
|
-
g.push(o2.group);
|
|
14
|
+
for (const o2 of d) g.push(o2.group);
|
|
17
15
|
}
|
|
18
16
|
const y = {}, x = [], v = [];
|
|
19
|
-
for (const o2 of d)
|
|
20
|
-
y[o2.group] = o2.target, o2.target && !x.includes(o2.target) && (x.push(o2.target), g.includes(o2.group) && v.push(o2.target));
|
|
17
|
+
for (const o2 of d) y[o2.group] = o2.target, o2.target && !x.includes(o2.target) && (x.push(o2.target), g.includes(o2.group) && v.push(o2.target));
|
|
21
18
|
let E = u.props ? u.props.mulGroupShow : "";
|
|
22
19
|
E = "break" == E ? "\r\n" : " ";
|
|
23
20
|
for (const t2 of h) {
|
|
24
|
-
if (!t2)
|
|
25
|
-
continue;
|
|
21
|
+
if (!t2) continue;
|
|
26
22
|
const r2 = [];
|
|
27
23
|
for (const s2 of g) {
|
|
28
24
|
const e3 = y[s2], l2 = o(t2, e3, void 0);
|
|
@@ -32,20 +28,17 @@ function i(i2, u, c, a) {
|
|
|
32
28
|
t2[s.X_FIELD_NAME] = e2;
|
|
33
29
|
}
|
|
34
30
|
const F = u.items ? u.items : [];
|
|
35
|
-
if (0 == F.length)
|
|
36
|
-
return;
|
|
31
|
+
if (0 == F.length) return;
|
|
37
32
|
const S = u.props ? u.props : {};
|
|
38
33
|
let _ = S.yaxisField;
|
|
39
34
|
if (F[0].props.yaxisField = _, F[0].props.yaxisSource = S.yaxisSource, F[0].props.formula = S.formula, "formula" === S.yaxisSource) {
|
|
40
35
|
const t2 = [], r2 = e(F, h, t2);
|
|
41
36
|
let n2 = S.formula ? S.formula : "";
|
|
42
|
-
for (const o2 in r2)
|
|
43
|
-
n2 = n2.replace(new RegExp(o2.replace("$", "\\$"), "g"), r2[o2]);
|
|
37
|
+
for (const o2 in r2) n2 = n2.replace(new RegExp(o2.replace("$", "\\$"), "g"), r2[o2]);
|
|
44
38
|
_ = s.Y_TEMP_NAME;
|
|
45
39
|
const p2 = {};
|
|
46
40
|
for (const r3 of h) {
|
|
47
|
-
if (!r3)
|
|
48
|
-
continue;
|
|
41
|
+
if (!r3) continue;
|
|
49
42
|
for (const s3 of t2) {
|
|
50
43
|
const t3 = o(r3, s3, void 0);
|
|
51
44
|
let e2 = p2[s3];
|
|
@@ -58,8 +51,7 @@ function i(i2, u, c, a) {
|
|
|
58
51
|
F[0].props.yaxisField = _, F[0].props.yaxisSource = "", n(i2, u, h), h = p(i2, u, h, x, [_]);
|
|
59
52
|
const A = [], D = [];
|
|
60
53
|
for (const t2 of h) {
|
|
61
|
-
if (!t2)
|
|
62
|
-
continue;
|
|
54
|
+
if (!t2) continue;
|
|
63
55
|
A.push(t2[s.X_FIELD_NAME]);
|
|
64
56
|
const r2 = o(t2, _, void 0);
|
|
65
57
|
D.push(r2);
|
|
@@ -2,8 +2,7 @@ import { getValueFromSource as e } from "../page-helper-util.js";
|
|
|
2
2
|
import { deepCopy as o } from "../common-util.js";
|
|
3
3
|
import { caculateFormulaValue as i, executeChartFormula as t } from "./chart-util.js";
|
|
4
4
|
function a(a2, s, r, l) {
|
|
5
|
-
if (!l || !l.result)
|
|
6
|
-
return;
|
|
5
|
+
if (!l || !l.result) return;
|
|
7
6
|
const u = l && l.result ? l.result : {}, f = s.serviceDataField;
|
|
8
7
|
let d = null;
|
|
9
8
|
f ? d = u[f] : u && (d = Array.isArray(u) ? u : [u]), d || (d = []);
|
|
@@ -11,22 +10,17 @@ function a(a2, s, r, l) {
|
|
|
11
10
|
for (const e2 of n) {
|
|
12
11
|
const o2 = e2.props ? e2.props : {}, i2 = o2.yaxisSource, t2 = o2.yaxisField;
|
|
13
12
|
let a3 = null;
|
|
14
|
-
if (!t2 || i2 && "variable" != i2)
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
} else
|
|
21
|
-
a3 = { uuid: e2.uuid, type: "fixed", field: o2.yaxisFix, data: [] };
|
|
22
|
-
else
|
|
23
|
-
a3 = { uuid: e2.uuid, type: "variable", field: t2, data: [] };
|
|
13
|
+
if (!t2 || i2 && "variable" != i2) if ("formula" == i2) {
|
|
14
|
+
let i3 = o2.formula ? o2.formula : "";
|
|
15
|
+
for (const e3 in x) i3 = i3.replace(new RegExp(e3.replace("$", "\\$"), "g"), x[e3]);
|
|
16
|
+
a3 = { uuid: e2.uuid, type: "formula", formula: i3, data: [] };
|
|
17
|
+
} else a3 = { uuid: e2.uuid, type: "fixed", field: o2.yaxisFix, data: [] };
|
|
18
|
+
else a3 = { uuid: e2.uuid, type: "variable", field: t2, data: [] };
|
|
24
19
|
a3 && (c.push(a3), p[a3.uuid] = a3);
|
|
25
20
|
}
|
|
26
21
|
const v = s.props ? s.props : {}, y = v.nameField, h = v.maxSource, F = v.maxField, b = v.maxFixed, g = [], j = {};
|
|
27
22
|
for (const o2 of d) {
|
|
28
|
-
if (!o2)
|
|
29
|
-
continue;
|
|
23
|
+
if (!o2) continue;
|
|
30
24
|
const i2 = e(o2, y, void 0);
|
|
31
25
|
let s2 = null;
|
|
32
26
|
s2 = h && "variable" != h ? b : e(o2, F, void 0), g.push({ text: i2, max: s2 });
|
|
@@ -37,16 +31,14 @@ function a(a2, s, r, l) {
|
|
|
37
31
|
}
|
|
38
32
|
for (const i3 of c) {
|
|
39
33
|
const s3 = i3.data;
|
|
40
|
-
if ("fixed" == i3.type)
|
|
41
|
-
s3.push(i3.field);
|
|
34
|
+
if ("fixed" == i3.type) s3.push(i3.field);
|
|
42
35
|
else if ("variable" == i3.type) {
|
|
43
36
|
const t2 = e(o2, i3.field, void 0);
|
|
44
37
|
s3.push(t2);
|
|
45
38
|
} else if ("formula" == i3.type) {
|
|
46
39
|
const e2 = t(i3.formula, j, o2, a2);
|
|
47
40
|
s3.push(e2);
|
|
48
|
-
} else
|
|
49
|
-
s3.push(void 0);
|
|
41
|
+
} else s3.push(void 0);
|
|
50
42
|
}
|
|
51
43
|
}
|
|
52
44
|
r.radar[0].indicator = g;
|