super-page-runtime 2.2.29-tmp2 → 2.2.32
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 +5 -7
- package/dist/es/assets/chart-themes/theme1.js +2 -6
- package/dist/es/assets/chart-themes/theme2.js +2 -6
- package/dist/es/assets/chart-themes/theme3.js +2 -6
- package/dist/es/components/runtime/utils/api/api-util.js +4 -7
- package/dist/es/components/runtime/utils/api/page-expose-util.js +135 -443
- package/dist/es/components/runtime/utils/assemblys-config.js +13 -369
- package/dist/es/components/runtime/utils/barcode-util.js +9 -33
- package/dist/es/components/runtime/utils/charts/chart-columnline-util.js +122 -306
- package/dist/es/components/runtime/utils/charts/chart-gauge-util.js +29 -68
- package/dist/es/components/runtime/utils/charts/chart-pie-util.js +68 -152
- package/dist/es/components/runtime/utils/charts/chart-radar-util.js +46 -124
- package/dist/es/components/runtime/utils/charts/chart-scatter-util.js +36 -99
- package/dist/es/components/runtime/utils/charts/chart-util.js +224 -522
- package/dist/es/components/runtime/utils/common-util.js +76 -156
- package/dist/es/components/runtime/utils/eventBus.js +3 -8
- package/dist/es/components/runtime/utils/events/event-util.js +362 -775
- package/dist/es/components/runtime/utils/events/print-label.js +72 -140
- package/dist/es/components/runtime/utils/events/standard-event.js +808 -2320
- package/dist/es/components/runtime/utils/events/validator-util.js +224 -560
- package/dist/es/components/runtime/utils/form/date-shortcuts.js +28 -88
- package/dist/es/components/runtime/utils/form/scan-util.js +61 -162
- package/dist/es/components/runtime/utils/global-refs.js +53 -84
- package/dist/es/components/runtime/utils/i18n-util.js +11 -20
- package/dist/es/components/runtime/utils/interfaces/page-design-types.d.ts +6 -0
- package/dist/es/components/runtime/utils/interfaces/page-design-types.js +2 -7
- package/dist/es/components/runtime/utils/page-helper-util.js +280 -660
- package/dist/es/components/runtime/utils/page-init-util.js +141 -406
- package/dist/es/components/runtime/utils/page-permission-util.js +22 -531
- package/dist/es/components/runtime/utils/page-store.js +23 -68
- package/dist/es/components/runtime/utils/store-util.js +9 -13
- package/dist/es/components/runtime/utils/store.js +2 -2
- package/dist/es/components/runtime/utils/table-utils.d.ts +4 -0
- package/dist/es/components/runtime/utils/table-utils.js +40 -81
- package/dist/es/components/runtime/utils/tree-utils.js +17 -37
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue2.js +21 -83
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue2.js +14 -46
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue2.js +36 -132
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue2.js +4 -18
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue2.js +17 -107
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +50 -198
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue.js +12 -42
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +7 -60
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +52 -203
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue.js +4 -4
- package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue2.js +46 -162
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +32 -109
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +43 -166
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +32 -117
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +32 -118
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +246 -597
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue.js +4 -42
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue.js +8 -62
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue.js +29 -160
- package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue.js +13 -62
- package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +212 -594
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +29 -139
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue.js +21 -125
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.js +16 -102
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +18 -81
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue2.js +17 -82
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue2.js +14 -86
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue2.js +21 -79
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue2.js +16 -61
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue2.js +10 -37
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue2.js +38 -127
- package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue2.js +28 -76
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +61 -178
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +317 -810
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +262 -635
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +40 -115
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +56 -215
- package/dist/es/components/runtime/views/assemblys/error-render.vue.js +3 -21
- package/dist/es/components/runtime/views/assemblys/error-render.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +42 -154
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue.js +34 -98
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +52 -200
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +68 -239
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +31 -109
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue2.js +21 -59
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +56 -188
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +22 -103
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +57 -245
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +32 -174
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +28 -107
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue.js +4 -4
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue2.js +13 -50
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +64 -194
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +88 -249
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +80 -263
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue2.js +13 -57
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +30 -155
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue2.js +40 -129
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +22 -107
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue.js +89 -188
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/object-render.vue.js +133 -272
- package/dist/es/components/runtime/views/assemblys/object-render.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue2.js +18 -46
- package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue2.js +21 -49
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue2.js +20 -58
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue2.js +16 -53
- package/dist/es/components/runtime/views/home-chart.vue.js +41 -160
- package/dist/es/components/runtime/views/home-chart.vue2.js +2 -2
- package/dist/es/components/runtime/views/super-page-dialog.vue.js +20 -139
- package/dist/es/components/runtime/views/super-page-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/super-page.vue.js +226 -754
- package/dist/es/components/runtime/views/super-page.vue2.js +2 -2
- package/dist/es/i18n/langs/cn.js +2 -55
- package/dist/es/i18n/langs/en.js +2 -55
- package/package.json +2 -2
package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js
CHANGED
|
@@ -1,193 +1,61 @@
|
|
|
1
|
-
import { defineComponent, ref, onMounted, nextTick, onUnmounted, resolveComponent, createBlock, createCommentVNode, openBlock, normalizeStyle, normalizeClass, unref, withCtx, createElementBlock, toDisplayString } from "vue";
|
|
2
|
-
import { getVariableValue, setVariableValue } from "../../../../utils/page-helper-util.js";
|
|
3
|
-
import { handleAfterInitEvent, fileUploadBeforeUpload } from "../../../../utils/events/event-util.js";
|
|
4
|
-
import
|
|
5
|
-
import { FsUploadNew } from "agilebuilder-ui";
|
|
6
|
-
import
|
|
7
|
-
import { $t } from "../../../../utils/i18n-util.js";
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
const runtimeClass = runtimeInfo.class;
|
|
20
|
-
const headerStyle = runtimeInfo.headerStyle;
|
|
21
|
-
const titleExceedStyle = runtimeInfo.titleExceedStyle;
|
|
22
|
-
const entity = props.pageContext.entity ? props.pageContext.entity : {};
|
|
23
|
-
const propsBase = props.configure.props.base ? props.configure.props.base : {};
|
|
24
|
-
const pathFields = getFieldsByVariable(propsBase.prop);
|
|
25
|
-
const nameFields = getFieldsByVariable(propsBase.propName);
|
|
26
|
-
const pageCode = props.pageContext.code;
|
|
27
|
-
const componentId = ref(pathFields ? pageCode + "__" + pathFields.join("__") : null);
|
|
28
|
-
const initPaths = getVariableValue(entity, pathFields);
|
|
29
|
-
const fileUploadRef = ref(null);
|
|
30
|
-
const hasLoad = ref(false);
|
|
31
|
-
const fileList = ref([]);
|
|
32
|
-
const fileInfo = ref({});
|
|
33
|
-
if (initPaths) {
|
|
34
|
-
const uuids = initPaths.split(",");
|
|
35
|
-
if (uuids.length > 0) {
|
|
36
|
-
const backendUrl = props.pageContext.backendUrl;
|
|
37
|
-
http.post(backendUrl + "/common/fs-upload/search-file-names", uuids).then((result) => {
|
|
38
|
-
const names = [];
|
|
39
|
-
for (let index = 0; index < uuids.length; index++) {
|
|
40
|
-
const uuid = uuids[index];
|
|
41
|
-
names.push(result[uuid]);
|
|
42
|
-
fileList.value.push({ showName: result[uuid], serverPath: uuid });
|
|
43
|
-
}
|
|
44
|
-
if (designProperty.value.displayType === "input") {
|
|
45
|
-
fileInfo.value.showName = names.join(",");
|
|
46
|
-
fileInfo.value.serverPath = uuids.join(",");
|
|
47
|
-
}
|
|
48
|
-
}).finally(() => {
|
|
49
|
-
hasLoad.value = true;
|
|
50
|
-
});
|
|
51
|
-
} else {
|
|
52
|
-
hasLoad.value = true;
|
|
53
|
-
}
|
|
54
|
-
} else {
|
|
55
|
-
hasLoad.value = true;
|
|
56
|
-
}
|
|
57
|
-
function getFieldsByVariable(variableName) {
|
|
58
|
-
if (!variableName) {
|
|
59
|
-
return [];
|
|
60
|
-
}
|
|
61
|
-
if (variableName.startsWith("${")) {
|
|
62
|
-
variableName = variableName.substring(2, variableName.length - 1);
|
|
63
|
-
}
|
|
64
|
-
return variableName.split(".");
|
|
65
|
-
}
|
|
66
|
-
function beforeUpload(params) {
|
|
67
|
-
return fileUploadBeforeUpload(params);
|
|
68
|
-
}
|
|
69
|
-
const onSuccess = (response, uploadFile, uploadFiles) => {
|
|
70
|
-
updateValue();
|
|
71
|
-
};
|
|
72
|
-
const onRemove = (file) => {
|
|
73
|
-
updateValue();
|
|
74
|
-
};
|
|
75
|
-
const updateValue = () => {
|
|
76
|
-
const names = [];
|
|
77
|
-
const uuids = [];
|
|
78
|
-
if (designProperty.value.limit) {
|
|
79
|
-
if (fileList.value.length > designProperty.value.limit) {
|
|
80
|
-
const diff = fileList.value.length - designProperty.value.limit;
|
|
81
|
-
for (let index = 0; index < diff; index++) {
|
|
82
|
-
fileList.value.shift();
|
|
83
|
-
}
|
|
1
|
+
import { defineComponent as e, ref as l, onMounted as t, nextTick as i, onUnmounted as o, resolveComponent as a, createBlock as s, createCommentVNode as u, openBlock as n, normalizeStyle as p, normalizeClass as r, unref as m, withCtx as f, createElementBlock as v, toDisplayString as c } from "vue";
|
|
2
|
+
import { getVariableValue as d, setVariableValue as h } from "../../../../utils/page-helper-util.js";
|
|
3
|
+
import { handleAfterInitEvent as y, fileUploadBeforeUpload as g } from "../../../../utils/events/event-util.js";
|
|
4
|
+
import C from "agilebuilder-ui/src/utils/request";
|
|
5
|
+
import { FsUploadNew as x } from "agilebuilder-ui";
|
|
6
|
+
import b from "../../../../utils/eventBus.js";
|
|
7
|
+
import { $t as k } from "../../../../utils/i18n-util.js";
|
|
8
|
+
const _ = e({ __name: "fileupload-runtime", props: { pageContext: {}, configure: {} }, setup(e2) {
|
|
9
|
+
const _2 = e2, w = _2.configure.runtime ? _2.configure.runtime : {}, P = l(w.props ? w.props : {}), j = w.style, R = w.class, T = w.headerStyle, z = w.titleExceedStyle, I = _2.pageContext.entity ? _2.pageContext.entity : {}, O = _2.configure.props.base ? _2.configure.props.base : {}, S = E(O.prop), F = E(O.propName), N = _2.pageContext.code, q = l(S ? N + "__" + S.join("__") : null), D = d(I, S), U = l(null), $ = l(false), W = l([]), B = l({});
|
|
10
|
+
if (D) {
|
|
11
|
+
const e3 = D.split(",");
|
|
12
|
+
if (e3.length > 0) {
|
|
13
|
+
const l2 = _2.pageContext.backendUrl;
|
|
14
|
+
C.post(l2 + "/common/fs-upload/search-file-names", e3).then((l3) => {
|
|
15
|
+
const t2 = [];
|
|
16
|
+
for (let i2 = 0; i2 < e3.length; i2++) {
|
|
17
|
+
const o2 = e3[i2];
|
|
18
|
+
t2.push(l3[o2]), W.value.push({ showName: l3[o2], serverPath: o2 });
|
|
84
19
|
}
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
uuids.push(fileList.value[index].serverPath);
|
|
89
|
-
}
|
|
90
|
-
setVariableValue(props.pageContext.entity, pathFields, uuids.join(","));
|
|
91
|
-
setVariableValue(props.pageContext.entity, nameFields, names.join(","));
|
|
92
|
-
};
|
|
93
|
-
const formItemRef = ref(null);
|
|
94
|
-
const titleRef = ref(null);
|
|
95
|
-
onMounted(() => {
|
|
96
|
-
bus.$on(componentId.value + "-pickFileDone", (data) => {
|
|
97
|
-
console.log(
|
|
98
|
-
"superPage4444---pickFileDone--componentId.value=",
|
|
99
|
-
componentId.value,
|
|
100
|
-
"data=",
|
|
101
|
-
data
|
|
102
|
-
);
|
|
103
|
-
fileUploadRef.value.pickFileDone(data);
|
|
20
|
+
"input" === P.value.displayType && (B.value.showName = t2.join(","), B.value.serverPath = e3.join(","));
|
|
21
|
+
}).finally(() => {
|
|
22
|
+
$.value = true;
|
|
104
23
|
});
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
titleRef: titleRef.value,
|
|
113
|
-
value,
|
|
114
|
-
entity: props.pageContext.entity.data,
|
|
115
|
-
pageData: props.pageContext.entity.page
|
|
116
|
-
});
|
|
117
|
-
});
|
|
118
|
-
});
|
|
119
|
-
onUnmounted(() => {
|
|
120
|
-
bus.$off(componentId.value + "-pickFileDone");
|
|
121
|
-
});
|
|
122
|
-
return (_ctx, _cache) => {
|
|
123
|
-
const _component_el_form_item = resolveComponent("el-form-item");
|
|
124
|
-
return designProperty.value.tittleShow ? (openBlock(), createBlock(_component_el_form_item, {
|
|
125
|
-
key: 0,
|
|
126
|
-
ref_key: "formItemRef",
|
|
127
|
-
ref: formItemRef,
|
|
128
|
-
required: designProperty.value.required,
|
|
129
|
-
class: normalizeClass(unref(runtimeClass)),
|
|
130
|
-
"label-width": designProperty.value.labelWidth,
|
|
131
|
-
style: normalizeStyle(unref(runtimeStyle))
|
|
132
|
-
}, {
|
|
133
|
-
label: withCtx(() => [
|
|
134
|
-
designProperty.value.tittleShow ? (openBlock(), createElementBlock("div", {
|
|
135
|
-
key: 0,
|
|
136
|
-
ref_key: "titleRef",
|
|
137
|
-
ref: titleRef,
|
|
138
|
-
style: normalizeStyle({ ...unref(headerStyle), ...unref(titleExceedStyle) })
|
|
139
|
-
}, toDisplayString(unref($t)(designProperty.value.title)), 5)) : createCommentVNode("", true)
|
|
140
|
-
]),
|
|
141
|
-
default: withCtx(() => [
|
|
142
|
-
hasLoad.value ? (openBlock(), createBlock(unref(FsUploadNew), {
|
|
143
|
-
key: 0,
|
|
144
|
-
ref_key: "fileUploadRef",
|
|
145
|
-
ref: fileUploadRef,
|
|
146
|
-
style: { "width": "100%" },
|
|
147
|
-
disabled: designProperty.value.state === "disabled",
|
|
148
|
-
displayType: designProperty.value.displayType,
|
|
149
|
-
accept: designProperty.value.accept,
|
|
150
|
-
multiple: designProperty.value.multiple,
|
|
151
|
-
placeholder: designProperty.value.placeholder,
|
|
152
|
-
limit: designProperty.value.limit,
|
|
153
|
-
"limit-file-size": designProperty.value.limitFileSize,
|
|
154
|
-
openCameraOrChoosePhoto: designProperty.value.openCameraOrChoosePhoto,
|
|
155
|
-
"file-info": fileInfo.value,
|
|
156
|
-
"file-list": fileList.value,
|
|
157
|
-
"system-code": _ctx.pageContext.systemCode,
|
|
158
|
-
componentId: componentId.value,
|
|
159
|
-
"on-success": onSuccess,
|
|
160
|
-
"on-remove": onRemove,
|
|
161
|
-
"before-upload": beforeUpload,
|
|
162
|
-
pageContext: _ctx.pageContext
|
|
163
|
-
}, null, 8, ["disabled", "displayType", "accept", "multiple", "placeholder", "limit", "limit-file-size", "openCameraOrChoosePhoto", "file-info", "file-list", "system-code", "componentId", "pageContext"])) : createCommentVNode("", true)
|
|
164
|
-
]),
|
|
165
|
-
_: 1
|
|
166
|
-
}, 8, ["required", "class", "label-width", "style"])) : hasLoad.value ? (openBlock(), createBlock(unref(FsUploadNew), {
|
|
167
|
-
key: 1,
|
|
168
|
-
ref_key: "fileUploadRef",
|
|
169
|
-
ref: fileUploadRef,
|
|
170
|
-
style: { "width": "100%" },
|
|
171
|
-
disabled: designProperty.value.state === "disabled",
|
|
172
|
-
displayType: designProperty.value.displayType,
|
|
173
|
-
accept: designProperty.value.accept,
|
|
174
|
-
multiple: designProperty.value.multiple,
|
|
175
|
-
placeholder: designProperty.value.placeholder,
|
|
176
|
-
limit: designProperty.value.limit,
|
|
177
|
-
"limit-file-size": designProperty.value.limitFileSize,
|
|
178
|
-
openCameraOrChoosePhoto: designProperty.value.openCameraOrChoosePhoto,
|
|
179
|
-
"file-info": fileInfo.value,
|
|
180
|
-
"file-list": fileList.value,
|
|
181
|
-
"system-code": _ctx.pageContext.systemCode,
|
|
182
|
-
componentId: componentId.value,
|
|
183
|
-
"on-success": onSuccess,
|
|
184
|
-
"on-remove": onRemove,
|
|
185
|
-
"before-upload": beforeUpload,
|
|
186
|
-
pageContext: _ctx.pageContext
|
|
187
|
-
}, null, 8, ["disabled", "displayType", "accept", "multiple", "placeholder", "limit", "limit-file-size", "openCameraOrChoosePhoto", "file-info", "file-list", "system-code", "componentId", "pageContext"])) : createCommentVNode("", true);
|
|
188
|
-
};
|
|
24
|
+
} else $.value = true;
|
|
25
|
+
} else $.value = true;
|
|
26
|
+
function E(e3) {
|
|
27
|
+
return e3 ? (e3.startsWith("${") && (e3 = e3.substring(2, e3.length - 1)), e3.split(".")) : [];
|
|
28
|
+
}
|
|
29
|
+
function A(e3) {
|
|
30
|
+
return g(e3);
|
|
189
31
|
}
|
|
190
|
-
|
|
32
|
+
const G = (e3, l2, t2) => {
|
|
33
|
+
J();
|
|
34
|
+
}, H = (e3) => {
|
|
35
|
+
J();
|
|
36
|
+
}, J = () => {
|
|
37
|
+
const e3 = [], l2 = [];
|
|
38
|
+
if (P.value.limit && W.value.length > P.value.limit) {
|
|
39
|
+
const e4 = W.value.length - P.value.limit;
|
|
40
|
+
for (let l3 = 0; l3 < e4; l3++) W.value.shift();
|
|
41
|
+
}
|
|
42
|
+
for (let t2 = 0; t2 < W.value.length; t2++) e3.push(W.value[t2].showName), l2.push(W.value[t2].serverPath);
|
|
43
|
+
h(_2.pageContext.entity, S, l2.join(",")), h(_2.pageContext.entity, F, e3.join(","));
|
|
44
|
+
}, K = l(null), L = l(null);
|
|
45
|
+
return t(() => {
|
|
46
|
+
b.$on(q.value + "-pickFileDone", (e3) => {
|
|
47
|
+
U.value.pickFileDone(e3);
|
|
48
|
+
}), i(() => {
|
|
49
|
+
const e3 = d(I, S), l2 = { showName: d(I, F), serverPath: e3 };
|
|
50
|
+
y(l2, _2.pageContext, _2.configure, { formItemRef: K.value, componentRef: U.value, titleRef: L.value, value: l2, entity: _2.pageContext.entity.data, pageData: _2.pageContext.entity.page });
|
|
51
|
+
});
|
|
52
|
+
}), o(() => {
|
|
53
|
+
b.$off(q.value + "-pickFileDone");
|
|
54
|
+
}), (e3, l2) => {
|
|
55
|
+
const t2 = a("el-form-item");
|
|
56
|
+
return P.value.tittleShow ? (n(), s(t2, { key: 0, ref_key: "formItemRef", ref: K, required: P.value.required, class: r(m(R)), "label-width": P.value.labelWidth, style: p(m(j)) }, { label: f(() => [P.value.tittleShow ? (n(), v("div", { key: 0, ref_key: "titleRef", ref: L, style: p({ ...m(T), ...m(z) }) }, c(m(k)(P.value.title)), 5)) : u("", true)]), default: f(() => [$.value ? (n(), s(m(x), { key: 0, ref_key: "fileUploadRef", ref: U, style: { width: "100%" }, disabled: "disabled" === P.value.state, displayType: P.value.displayType, accept: P.value.accept, multiple: P.value.multiple, placeholder: P.value.placeholder, limit: P.value.limit, "limit-file-size": P.value.limitFileSize, openCameraOrChoosePhoto: P.value.openCameraOrChoosePhoto, "file-info": B.value, "file-list": W.value, "system-code": e3.pageContext.systemCode, componentId: q.value, "on-success": G, "on-remove": H, "before-upload": A, pageContext: e3.pageContext }, null, 8, ["disabled", "displayType", "accept", "multiple", "placeholder", "limit", "limit-file-size", "openCameraOrChoosePhoto", "file-info", "file-list", "system-code", "componentId", "pageContext"])) : u("", true)]), _: 1 }, 8, ["required", "class", "label-width", "style"])) : $.value ? (n(), s(m(x), { key: 1, ref_key: "fileUploadRef", ref: U, style: { width: "100%" }, disabled: "disabled" === P.value.state, displayType: P.value.displayType, accept: P.value.accept, multiple: P.value.multiple, placeholder: P.value.placeholder, limit: P.value.limit, "limit-file-size": P.value.limitFileSize, openCameraOrChoosePhoto: P.value.openCameraOrChoosePhoto, "file-info": B.value, "file-list": W.value, "system-code": e3.pageContext.systemCode, componentId: q.value, "on-success": G, "on-remove": H, "before-upload": A, pageContext: e3.pageContext }, null, 8, ["disabled", "displayType", "accept", "multiple", "placeholder", "limit", "limit-file-size", "openCameraOrChoosePhoto", "file-info", "file-list", "system-code", "componentId", "pageContext"])) : u("", true);
|
|
57
|
+
};
|
|
58
|
+
} });
|
|
191
59
|
export {
|
|
192
|
-
|
|
60
|
+
_ as default
|
|
193
61
|
};
|
package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js
CHANGED
|
@@ -1,106 +1,25 @@
|
|
|
1
|
-
import { defineComponent, computed, ref, onMounted, nextTick, resolveComponent, createBlock, openBlock, normalizeStyle, normalizeClass, unref, withCtx, createVNode, createElementBlock, createCommentVNode, Fragment, createTextVNode, toDisplayString } from "vue";
|
|
2
|
-
import { getFormModelFields } from "../../../../utils/page-init-util.js";
|
|
3
|
-
import { setVariableValue, getVariableValue } from "../../../../utils/page-helper-util.js";
|
|
4
|
-
import { handleAfterInitEvent, handleFormEvent } from "../../../../utils/events/event-util.js";
|
|
5
|
-
import
|
|
6
|
-
import { $t } from "../../../../utils/i18n-util.js";
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
},
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const dynamicModelMethod = computed({
|
|
18
|
-
get() {
|
|
19
|
-
return getVariableValue(entity, dynamicFields);
|
|
20
|
-
},
|
|
21
|
-
set(value) {
|
|
22
|
-
setVariableValue(entity, dynamicFields, value);
|
|
23
|
-
}
|
|
1
|
+
import { defineComponent as e, computed as t, ref as l, onMounted as o, nextTick as a, resolveComponent as n, createBlock as u, openBlock as r, normalizeStyle as i, normalizeClass as p, unref as s, withCtx as m, createVNode as f, createElementBlock as c, createCommentVNode as d, Fragment as g, createTextVNode as v, toDisplayString as y } from "vue";
|
|
2
|
+
import { getFormModelFields as x } from "../../../../utils/page-init-util.js";
|
|
3
|
+
import { setVariableValue as C, getVariableValue as h } from "../../../../utils/page-helper-util.js";
|
|
4
|
+
import { handleAfterInitEvent as b, handleFormEvent as k } from "../../../../utils/events/event-util.js";
|
|
5
|
+
import R from "../common/title-suffix-element.vue.js";
|
|
6
|
+
import { $t as _ } from "../../../../utils/i18n-util.js";
|
|
7
|
+
const j = e({ __name: "input-number-runtime", props: { pageContext: {}, configure: {} }, setup(e2) {
|
|
8
|
+
const j2 = e2, w = j2.pageContext.entity ? j2.pageContext.entity : {};
|
|
9
|
+
let q = x(j2.pageContext, j2.configure);
|
|
10
|
+
const z = t({ get: () => h(w, q), set(e3) {
|
|
11
|
+
C(w, q, e3);
|
|
12
|
+
} }), S = j2.configure.runtime ? j2.configure.runtime : {}, V = S.style, B = S.class, I = S.headerStyle, D = S.titleExceedStyle, E = l(S.props ? S.props : {}), F = l(null), T = l(null), U = l(null);
|
|
13
|
+
return o(() => {
|
|
14
|
+
a(() => {
|
|
15
|
+
const e3 = z.value;
|
|
16
|
+
b(e3, j2.pageContext, j2.configure, { formItemRef: F.value, componentRef: T.value, titleRef: U.value, value: e3, entity: j2.pageContext.entity.data, pageData: j2.pageContext.entity.page });
|
|
24
17
|
});
|
|
25
|
-
|
|
26
|
-
const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
const designProperty = ref(runtimeInfo.props ? runtimeInfo.props : {});
|
|
31
|
-
const formItemRef = ref(null);
|
|
32
|
-
const componentRef = ref(null);
|
|
33
|
-
const titleRef = ref(null);
|
|
34
|
-
onMounted(() => {
|
|
35
|
-
nextTick(() => {
|
|
36
|
-
const value = dynamicModelMethod.value;
|
|
37
|
-
handleAfterInitEvent(
|
|
38
|
-
value,
|
|
39
|
-
props.pageContext,
|
|
40
|
-
props.configure,
|
|
41
|
-
{
|
|
42
|
-
formItemRef: formItemRef.value,
|
|
43
|
-
componentRef: componentRef.value,
|
|
44
|
-
titleRef: titleRef.value,
|
|
45
|
-
value,
|
|
46
|
-
entity: props.pageContext.entity.data,
|
|
47
|
-
pageData: props.pageContext.entity.page
|
|
48
|
-
}
|
|
49
|
-
);
|
|
50
|
-
});
|
|
51
|
-
});
|
|
52
|
-
return (_ctx, _cache) => {
|
|
53
|
-
const _component_el_input_number = resolveComponent("el-input-number");
|
|
54
|
-
const _component_el_form_item = resolveComponent("el-form-item");
|
|
55
|
-
return openBlock(), createBlock(_component_el_form_item, {
|
|
56
|
-
ref_key: "formItemRef",
|
|
57
|
-
ref: formItemRef,
|
|
58
|
-
required: designProperty.value.required,
|
|
59
|
-
class: normalizeClass(unref(runtimeClass)),
|
|
60
|
-
"label-width": designProperty.value.labelWidth,
|
|
61
|
-
style: normalizeStyle(unref(runtimeStyle))
|
|
62
|
-
}, {
|
|
63
|
-
label: withCtx(() => [
|
|
64
|
-
designProperty.value.tittleShow ? (openBlock(), createElementBlock("div", {
|
|
65
|
-
key: 0,
|
|
66
|
-
ref_key: "titleRef",
|
|
67
|
-
ref: titleRef,
|
|
68
|
-
style: normalizeStyle({ ...unref(headerStyle), ...unref(titleExceedStyle) })
|
|
69
|
-
}, [
|
|
70
|
-
designProperty.value.prefixType ? (openBlock(), createBlock(_sfc_main$1, {
|
|
71
|
-
key: 0,
|
|
72
|
-
pageContext: _ctx.pageContext,
|
|
73
|
-
property: designProperty.value
|
|
74
|
-
}, null, 8, ["pageContext", "property"])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
75
|
-
createTextVNode(toDisplayString(unref($t)(designProperty.value.title)), 1)
|
|
76
|
-
], 64))
|
|
77
|
-
], 4)) : createCommentVNode("", true)
|
|
78
|
-
]),
|
|
79
|
-
default: withCtx(() => [
|
|
80
|
-
createVNode(_component_el_input_number, {
|
|
81
|
-
ref_key: "componentRef",
|
|
82
|
-
ref: componentRef,
|
|
83
|
-
disabled: designProperty.value.state === "disabled",
|
|
84
|
-
readonly: designProperty.value.state === "readonly",
|
|
85
|
-
controls: designProperty.value.showButton,
|
|
86
|
-
size: designProperty.value.size,
|
|
87
|
-
placeholder: designProperty.value.placeholder,
|
|
88
|
-
modelValue: dynamicModelMethod.value,
|
|
89
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => dynamicModelMethod.value = $event),
|
|
90
|
-
precision: designProperty.value.precision,
|
|
91
|
-
step: designProperty.value.step,
|
|
92
|
-
min: designProperty.value.min,
|
|
93
|
-
max: designProperty.value.max,
|
|
94
|
-
onChange: _cache[1] || (_cache[1] = ($event) => unref(handleFormEvent)($event, _ctx.pageContext, _ctx.configure, "change")),
|
|
95
|
-
onBlur: _cache[2] || (_cache[2] = ($event) => unref(handleFormEvent)($event, _ctx.pageContext, _ctx.configure, "blur")),
|
|
96
|
-
onFocus: _cache[3] || (_cache[3] = ($event) => unref(handleFormEvent)($event, _ctx.pageContext, _ctx.configure, "focus"))
|
|
97
|
-
}, null, 8, ["disabled", "readonly", "controls", "size", "placeholder", "modelValue", "precision", "step", "min", "max"])
|
|
98
|
-
]),
|
|
99
|
-
_: 1
|
|
100
|
-
}, 8, ["required", "class", "label-width", "style"]);
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
});
|
|
18
|
+
}), (e3, t2) => {
|
|
19
|
+
const l2 = n("el-input-number"), o2 = n("el-form-item");
|
|
20
|
+
return r(), u(o2, { ref_key: "formItemRef", ref: F, required: E.value.required, class: p(s(B)), "label-width": E.value.labelWidth, style: i(s(V)) }, { label: m(() => [E.value.tittleShow ? (r(), c("div", { key: 0, ref_key: "titleRef", ref: U, style: i({ ...s(I), ...s(D) }) }, [E.value.prefixType ? (r(), u(R, { key: 0, pageContext: e3.pageContext, property: E.value }, null, 8, ["pageContext", "property"])) : (r(), c(g, { key: 1 }, [v(y(s(_)(E.value.title)), 1)], 64))], 4)) : d("", true)]), default: m(() => [f(l2, { ref_key: "componentRef", ref: T, disabled: "disabled" === E.value.state, readonly: "readonly" === E.value.state, controls: E.value.showButton, size: E.value.size, placeholder: E.value.placeholder, modelValue: z.value, "onUpdate:modelValue": t2[0] || (t2[0] = (e4) => z.value = e4), precision: E.value.precision, step: E.value.step, min: E.value.min, max: E.value.max, onChange: t2[1] || (t2[1] = (t3) => s(k)(t3, e3.pageContext, e3.configure, "change")), onBlur: t2[2] || (t2[2] = (t3) => s(k)(t3, e3.pageContext, e3.configure, "blur")), onFocus: t2[3] || (t2[3] = (t3) => s(k)(t3, e3.pageContext, e3.configure, "focus")) }, null, 8, ["disabled", "readonly", "controls", "size", "placeholder", "modelValue", "precision", "step", "min", "max"])]), _: 1 }, 8, ["required", "class", "label-width", "style"]);
|
|
21
|
+
};
|
|
22
|
+
} });
|
|
104
23
|
export {
|
|
105
|
-
|
|
24
|
+
j as default
|
|
106
25
|
};
|