super-page-designer 2.2.25 → 2.2.30
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/design/utils/data-table-util.js +1 -1
- package/dist/es/components/design/utils/page-explore-util.js +9 -12
- package/dist/es/components/design/utils/page-table-util.js +1 -1
- package/dist/es/components/design/views/assemblys/chart/statistical-table/statisticalTable-design.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/chart/statistical-table/statisticalTable-design.vue2.js +52 -52
- package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/composite-header.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/composite-header.vue2.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/import-header.vue.js +32 -29
- package/dist/es/components/design/views/assemblys/data/component/table-children-column.vue.js +35 -35
- package/dist/es/components/design/views/assemblys/data/table/table-attr-base.vue.js +5 -5
- package/dist/es/components/design/views/assemblys/data/table/table-design.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/table/table-design.vue2.js +29 -29
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue2.js +1 -1
- package/dist/es/components/design/views/assemblys/form/checkbox/checkbox-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/custom/custom-attr-advanced.vue.js +12 -0
- package/dist/es/components/design/views/assemblys/form/custom/custom-attr-advanced.vue2.js +4 -0
- package/dist/es/components/design/views/assemblys/form/custom/custom-attr.vue2.js +8 -7
- package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-attr-base.vue.js +4 -4
- package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-design.vue2.js +1 -1
- package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/file-upload/fileupload-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/input-number/input-number-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/input-text/inputtext-attr-base.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/form/label/label-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/link/link-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/radio/radio-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/rich-text/richtext-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/select/select-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/switch/switch-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/tag/tag-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/textarea/textarea-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/workflow/component/combination.vue.js +10 -10
- package/dist/es/components/design/views/design/page-design.vue.js +83 -73
- package/dist/es/components/design/views/design/view/assemblys-container-explore.vue.js +3 -3
- package/dist/es/components/design/views/design/view/components/quick-add-fields.vue.js +26 -23
- package/dist/es/components/design/views/design/view/view-design-display.vue.js +31 -21
- package/dist/es/style.css +19 -833
- package/package.json +4 -4
- /package/dist/es/components/design/views/assemblys/common/{common-variable-bind.vue3.js → common-variable-bind.vue2.js} +0 -0
|
@@ -3,11 +3,11 @@ import { CirclePlus as s, Delete as f, Top as c, Bottom as v } from "@element-pl
|
|
|
3
3
|
import b from "../../common/common-variable-bind.vue.js";
|
|
4
4
|
import "element-plus";
|
|
5
5
|
import { getOperators as V } from "../../../../utils/data-table-util.js";
|
|
6
|
-
import { getModelOptionsByFields as
|
|
7
|
-
const
|
|
8
|
-
} }, dataFieldNameList: { type: Array, default: () => [] }, paramTypes: { type: Array, default: null } }, emits: ["remove", "save", "close"], setup(e2, { emit:
|
|
9
|
-
const w = e2, _ =
|
|
10
|
-
w.fieldNameList && w.fieldNameList.length > 0 && (U.value =
|
|
6
|
+
import { getModelOptionsByFields as y } from "../../../../utils/page-table-util.js";
|
|
7
|
+
const g = e({ __name: "combination", props: { list: { type: Array, default: () => [] }, fieldNameList: { type: Array, default: () => [] }, fieldMap: { type: Object, default: () => {
|
|
8
|
+
} }, dataFieldNameList: { type: Array, default: () => [] }, paramTypes: { type: Array, default: null } }, emits: ["remove", "save", "close"], setup(e2, { emit: g2 }) {
|
|
9
|
+
const w = e2, _ = g2, h = l({}), N = l([]), k = l([]), U = l([]);
|
|
10
|
+
w.fieldNameList && w.fieldNameList.length > 0 && (U.value = y(w.fieldNameList));
|
|
11
11
|
const C = l([]);
|
|
12
12
|
let j = w.dataFieldNameList;
|
|
13
13
|
function z() {
|
|
@@ -31,13 +31,13 @@ const y = e({ __name: "combination", props: { list: { type: Array, default: () =
|
|
|
31
31
|
}
|
|
32
32
|
return l2;
|
|
33
33
|
}
|
|
34
|
-
return w.dataFieldNameList && 0 !== w.dataFieldNameList.length ? C.value =
|
|
34
|
+
return w.dataFieldNameList && 0 !== w.dataFieldNameList.length ? C.value = y(j) : C.value = U.value, N.value = w.list, N.value.length > 0 && N.value.forEach((e3, l2) => {
|
|
35
35
|
"date" === e3.type ? N.value[l2].isDate = true : N.value[l2].isDate = false;
|
|
36
36
|
let a2 = w.fieldMap[e3.propDbName];
|
|
37
37
|
k.value[l2] = V(a2);
|
|
38
|
-
}), (l2,
|
|
39
|
-
const
|
|
40
|
-
return o(), t(A, { "model-value": "", title: "组合条件", width: "70%", "close-on-click-modal": false, "before-close": M }, { default: u(() => [d(_2, { style: { "padding-bottom": "8px" } }, { default: u(() => [d(
|
|
38
|
+
}), (l2, y2) => {
|
|
39
|
+
const g3 = a("el-button"), _2 = a("el-row"), h2 = a("el-icon"), j2 = a("el-table-column"), O = a("el-option"), T = a("el-select"), x = a("el-table"), A = a("el-dialog");
|
|
40
|
+
return o(), t(A, { "model-value": "", title: "组合条件", width: "70%", "close-on-click-modal": false, "before-close": M }, { default: u(() => [d(_2, { style: { "padding-bottom": "8px" } }, { default: u(() => [d(g3, { icon: r(s), plain: "", type: "primary", onClick: L }, { default: u(() => y2[0] || (y2[0] = [n(" 添加 ")])), _: 1 }, 8, ["icon"]), d(g3, { icon: r(f), plain: "", type: "primary", onClick: z }, { default: u(() => y2[1] || (y2[1] = [n(" 删除 ")])), _: 1 }, 8, ["icon"])]), _: 1 }), d(x, { ref: "tableRef", "highlight-current-row": "", onCurrentChange: D, data: N.value, "row-key": "propName", style: { width: "100%" } }, { default: u(() => [d(j2, { width: "50", align: "center" }, { default: u((e3) => [d(h2, { size: "14", style: { cursor: "pointer" }, onClick: (l3) => function(e4) {
|
|
41
41
|
let l4 = B(e4);
|
|
42
42
|
if (l4 < 1) return;
|
|
43
43
|
const a2 = N.value;
|
|
@@ -57,5 +57,5 @@ const y = e({ __name: "combination", props: { list: { type: Array, default: () =
|
|
|
57
57
|
};
|
|
58
58
|
} });
|
|
59
59
|
export {
|
|
60
|
-
|
|
60
|
+
g as default
|
|
61
61
|
};
|
|
@@ -1,88 +1,98 @@
|
|
|
1
|
-
import { defineComponent as e, ref as l, watch as o, resolveComponent as
|
|
1
|
+
import { defineComponent as e, ref as l, watch as o, resolveComponent as a, createElementBlock as s, openBlock as t, createElementVNode as i, createCommentVNode as n, createVNode as u, withCtx as r, createBlock as v, normalizeClass as p, withDirectives as c, vShow as f, unref as d } from "vue";
|
|
2
2
|
import m from "./view/view-design.vue.js";
|
|
3
3
|
import { initComponentRefState as g } from "../../utils/page-helper-util.js";
|
|
4
4
|
import { getTableNameByTableUuid as w, queryTableFields as k, changeFeieldToMap as y } from "../../utils/page-table-util.js";
|
|
5
|
-
import { addPermission as b, delPermission as
|
|
6
|
-
import { usePageContextStore as
|
|
5
|
+
import { addPermission as b, delPermission as h } from "../../utils/page-permission-util.js";
|
|
6
|
+
import { usePageContextStore as C } from "../../../../stores/page-store.js";
|
|
7
7
|
import S from "service-flow-designer";
|
|
8
|
-
import { getHighestVersionDefinition as
|
|
9
|
-
import { getPageConf as
|
|
10
|
-
import { fetchPageDesignData as
|
|
11
|
-
import { ElMessage as
|
|
12
|
-
import
|
|
13
|
-
import { undoRedo as
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
8
|
+
import { getHighestVersionDefinition as V } from "../../utils/page-design-util.js";
|
|
9
|
+
import { getPageConf as j } from "../../utils/assemblys-config.js";
|
|
10
|
+
import { fetchPageDesignData as _ } from "../../utils/page-service-util.js";
|
|
11
|
+
import { ElMessage as D, ElLoading as M } from "element-plus";
|
|
12
|
+
import W from "./view/page-switch.vue.js";
|
|
13
|
+
import { undoRedo as I } from "../../../../stores/undo-redo-store.js";
|
|
14
|
+
import x from "./page-event/page-event-view.vue.js";
|
|
15
|
+
import B from "../../utils/eventBus.js";
|
|
16
|
+
import { v4 as J } from "uuid";
|
|
17
|
+
const P = { class: "amb-page-container" }, T = { class: "amb-page-container-header-page" }, $ = { class: "amb-page-container-header" }, N = { class: "amb-page-container-header-type" }, R = { key: 0, class: "amb-page-container-main" }, A = e({ __name: "page-design", props: { pageId: { type: Number, default: null } }, setup(e2) {
|
|
18
|
+
const A2 = I(), E = e2, F = l(null), G = l(null), O = l(), z = C(), q = l("page"), L = l(null), U = l(null), H = l(null), K = l(false), Q = l(true), X = l(0);
|
|
19
|
+
let Y = l(null);
|
|
20
|
+
const Z = l(null);
|
|
21
|
+
function ee() {
|
|
22
|
+
q.value = "front", O.value && O.value.resize && O.value.resize();
|
|
22
23
|
}
|
|
23
|
-
function
|
|
24
|
-
const l2 =
|
|
24
|
+
function le(e3) {
|
|
25
|
+
const l2 = j();
|
|
25
26
|
return e3 ? Object.assign(l2, e3) : l2.systemCode || (l2.systemCode = "iqc", l2.systemVersion = 1), l2;
|
|
26
27
|
}
|
|
27
|
-
function
|
|
28
|
+
function oe(e3) {
|
|
28
29
|
let l2;
|
|
29
30
|
g(e3);
|
|
30
|
-
const
|
|
31
|
-
|
|
32
|
-
const
|
|
33
|
-
if (
|
|
31
|
+
const a2 = e3 == null ? void 0 : e3.tableUuids;
|
|
32
|
+
a2 && a2.length > 0 && (l2 = a2[0]);
|
|
33
|
+
const s2 = w(e3, l2);
|
|
34
|
+
if (s2) {
|
|
34
35
|
const l3 = e3.tableSysCode ? e3.tableSysCode : e3.systemCode, o2 = e3.tableSysVersion ? e3.tableSysVersion : e3.systemVersion;
|
|
35
|
-
k(l3, o2,
|
|
36
|
-
e3.modelFields = l4, e3.modelFieldsMap = y(e3.modelFieldsMap, l4),
|
|
36
|
+
k(l3, o2, s2).then((l4) => {
|
|
37
|
+
e3.modelFields = l4, e3.modelFieldsMap = y(e3.modelFieldsMap, l4), z.setPageContext(e3);
|
|
37
38
|
});
|
|
38
39
|
}
|
|
39
|
-
|
|
40
|
-
|
|
40
|
+
Y.value = e3.systemVersion, z.setPageContext(e3), o(() => e3, (e4) => {
|
|
41
|
+
se();
|
|
41
42
|
}, { deep: true }), o(e3.events, (l3) => {
|
|
42
43
|
if (e3.runtime || (e3.runtime = {}), e3.events) {
|
|
43
44
|
const l4 = e3.events.filter((e4) => !e4.isStandard && e4.jsContent || e4.isStandard && e4.eventName);
|
|
44
45
|
e3.runtime.events = l4;
|
|
45
46
|
}
|
|
46
47
|
}, { immediate: true }), o(() => e3.label, () => {
|
|
47
|
-
|
|
48
|
+
ue(e3);
|
|
48
49
|
}, { immediate: true }), o(() => e3.pageType, () => {
|
|
49
|
-
|
|
50
|
+
ue(e3);
|
|
50
51
|
}, { immediate: true }), e3.props && o(() => e3.props.activeWorkflow, () => {
|
|
51
|
-
|
|
52
|
-
}, { immediate: true }),
|
|
52
|
+
ue(e3);
|
|
53
|
+
}, { immediate: true }), B.$emit("changePageDesign"), function() {
|
|
54
|
+
ae("_isMobile", { level: 0, code: J(), name: "_isMobile", alias: "是否是移动端", type: "string", defaultValue: "", items: [], $editing: false });
|
|
55
|
+
ae("_isMobileApp", { level: 0, code: J(), name: "_isMobileApp", alias: "是否是移动端APP", type: "string", defaultValue: "", items: [], $editing: false });
|
|
56
|
+
ae("_isMobileBrowser", { level: 0, code: J(), name: "_isMobileBrowser", alias: "是否是移动端浏览器", type: "string", defaultValue: "", items: [], $editing: false });
|
|
57
|
+
}();
|
|
53
58
|
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
59
|
+
function ae(e3, l2) {
|
|
60
|
+
var _a;
|
|
61
|
+
const o2 = (_a = F.value.variables) == null ? void 0 : _a.filter((l3) => l3.name && l3.name === e3);
|
|
62
|
+
o2 && 0 !== o2.length || (F.value.variables || (F.value.variables = []), F.value.variables.push(l2));
|
|
63
|
+
}
|
|
64
|
+
B.$on("editComponentEvent", () => {
|
|
65
|
+
ee();
|
|
66
|
+
}), E.pageId ? _(E.pageId).then((e3) => {
|
|
57
67
|
if (e3 && e3.designJson) {
|
|
58
|
-
const l2 = e3.designJson, o2 =
|
|
59
|
-
o2.id =
|
|
60
|
-
} else
|
|
61
|
-
}) : (
|
|
62
|
-
let
|
|
68
|
+
const l2 = e3.designJson, o2 = le(JSON.parse(l2));
|
|
69
|
+
o2.id = E.pageId, F.value = o2, oe(F.value);
|
|
70
|
+
} else F.value = le(null), oe(F.value);
|
|
71
|
+
}) : (F.value = le(null), oe(F.value));
|
|
72
|
+
let se = /* @__PURE__ */ function(e3, l2) {
|
|
63
73
|
let o2 = null;
|
|
64
74
|
return function() {
|
|
65
|
-
let
|
|
75
|
+
let a2 = arguments;
|
|
66
76
|
o2 && clearTimeout(o2);
|
|
67
|
-
let
|
|
77
|
+
let s2 = !o2;
|
|
68
78
|
o2 = setTimeout(() => {
|
|
69
79
|
o2 = null;
|
|
70
|
-
}, l2),
|
|
80
|
+
}, l2), s2 && e3.apply(this, a2);
|
|
71
81
|
};
|
|
72
82
|
}(() => {
|
|
73
|
-
|
|
83
|
+
A2.addSnapshot(F.value);
|
|
74
84
|
}, 400);
|
|
75
|
-
function
|
|
76
|
-
|
|
85
|
+
function te() {
|
|
86
|
+
X.value++, A2.undo(F.value);
|
|
77
87
|
}
|
|
78
|
-
function
|
|
79
|
-
|
|
88
|
+
function ie() {
|
|
89
|
+
X.value++, A2.record(F.value);
|
|
80
90
|
}
|
|
81
|
-
function
|
|
91
|
+
function ne(e3) {
|
|
82
92
|
const l2 = e3.definitionVersion;
|
|
83
|
-
l2 && (
|
|
93
|
+
l2 && (F.value.props.workflowSource = "link", F.value.props.linkWorkflowVersion = l2, F.value.workflowVersion = l2, re(e3));
|
|
84
94
|
}
|
|
85
|
-
function
|
|
95
|
+
function ue(e3) {
|
|
86
96
|
b(e3, "page", e3.label, "-1");
|
|
87
97
|
const l2 = ["gets", "workflowGets", "listData", "listSubData"], o2 = [];
|
|
88
98
|
if (e3.pageType && "form" != e3.pageType) "list" == e3.pageType && (b(e3, "listData", "", "-1"), b(e3, "listSubData", "", "-1"), o2.push("listData"), o2.push("listSubData"));
|
|
@@ -90,39 +100,39 @@ const B = { class: "amb-page-container" }, N = { class: "amb-page-container-head
|
|
|
90
100
|
b(e3, "gets", "", "-1"), o2.push("gets");
|
|
91
101
|
(e3.props ? e3.props : {}).activeWorkflow && (b(e3, "workflowGets", "", "-1"), o2.push("workflowGets"));
|
|
92
102
|
}
|
|
93
|
-
for (let
|
|
103
|
+
for (let a2 of l2) o2.includes(a2) || h(e3, a2, "-1");
|
|
94
104
|
}
|
|
95
|
-
function
|
|
96
|
-
U.value = e3.code,
|
|
105
|
+
function re(e3) {
|
|
106
|
+
U.value = e3.code, H.value = e3.definitionVersion, L.value = e3.id;
|
|
97
107
|
}
|
|
98
|
-
function
|
|
99
|
-
if (!
|
|
108
|
+
function ve() {
|
|
109
|
+
if (!Q.value) return;
|
|
100
110
|
let e3, l2;
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
111
|
+
F.value.props.activeWorkflow && F.value.props.workflowSource && "link" === F.value.props.workflowSource ? (l2 = F.value.props.linkWorkflowCode, e3 = F.value.props.linkWorkflowVersion) : F.value.props.activeWorkflow && F.value.props.workflowSource && "create" === F.value.props.workflowSource && (l2 = F.value.props.createWorkflowCode, e3 = 1), l2 ? !U.value && !H.value || U.value !== l2 || H.value !== e3 ? (K.value = false, Q.value = false, function(e4, l3) {
|
|
112
|
+
V(e4, l3, Y.value).then((e5) => {
|
|
113
|
+
re(e5), q.value = "workflow", K.value = true;
|
|
104
114
|
}).finally(() => {
|
|
105
|
-
|
|
115
|
+
Q.value = true;
|
|
106
116
|
});
|
|
107
|
-
}(l2, e3)) : q.value = "workflow" :
|
|
117
|
+
}(l2, e3)) : q.value = "workflow" : D({ type: "warning", showClose: true, message: "请在页面设计/属性/工作流中先绑定流程" });
|
|
108
118
|
}
|
|
109
|
-
function
|
|
110
|
-
const l2 =
|
|
111
|
-
|
|
112
|
-
if (
|
|
113
|
-
const l3 = o2.designJson,
|
|
114
|
-
|
|
115
|
-
} else
|
|
119
|
+
function pe(e3) {
|
|
120
|
+
const l2 = M.service({ lock: true, text: "切换中,请稍后..." });
|
|
121
|
+
_(e3).then((o2) => {
|
|
122
|
+
if (X.value++, l2.close(), o2 && o2.designJson) {
|
|
123
|
+
const l3 = o2.designJson, a2 = le(JSON.parse(l3));
|
|
124
|
+
a2.id = e3, F.value = a2, F.value.items || (F.value.items = []), F.value.props || (F.value.props = {}), oe(F.value);
|
|
125
|
+
} else F.value = le(null), oe(F.value);
|
|
116
126
|
});
|
|
117
127
|
}
|
|
118
|
-
function
|
|
119
|
-
e3 && e3.system && (
|
|
128
|
+
function ce(e3) {
|
|
129
|
+
e3 && e3.system && (Z.value = e3.system), Z.value && z.setEnableI18n(Z.value.enableI18n);
|
|
120
130
|
}
|
|
121
131
|
return (e3, l2) => {
|
|
122
|
-
const o2 =
|
|
123
|
-
return t(),
|
|
132
|
+
const o2 = a("el-col"), g2 = a("el-row"), w2 = a("workflow-editor");
|
|
133
|
+
return t(), s("div", P, [i("div", T, [u(g2, null, { default: r(() => [u(o2, { span: 23, style: {} }, { default: r(() => [F.value && F.value.code ? (t(), v(W, { key: 0, pageDesign: F.value, onChangePage: pe, onInitLoaded: ce }, null, 8, ["pageDesign"])) : n("", true)]), _: 1 })]), _: 1 })]), i("div", $, [i("div", N, [i("label", { class: p({ selected: "page" === q.value }), onClick: l2[0] || (l2[0] = (e4) => q.value = "page") }, "页面设计", 2), i("label", { class: p({ selected: "front" === q.value }), onClick: l2[1] || (l2[1] = (e4) => ee()) }, "页面逻辑", 2), i("label", { class: p({ selected: "workflow" === q.value }), onClick: l2[2] || (l2[2] = (e4) => ve()) }, "工作流设计", 2), i("label", { class: p({ selected: "service" === q.value }), onClick: l2[3] || (l2[3] = (e4) => q.value = "service") }, "服务编排", 2)])]), F.value ? (t(), s("div", R, [c((t(), v(m, { ref_key: "ViewDesignRef", ref: G, key: X.value, configure: F.value, system: Z.value, onRegain: ie, onRevocation: te }, null, 8, ["configure", "system"])), [[f, "page" === q.value]]), K.value ? c((t(), v(w2, { key: 0, id: L.value, code: F.value.workflowCode, version: F.value.workflowVersion, "system-code": F.value.systemCode, "system-publish-version": F.value.systemVersion, "page-code": F.value.code, onBack: e3.goBack, onChangeDefVersion: ne }, null, 8, ["id", "code", "version", "system-code", "system-publish-version", "page-code", "onBack"])), [[f, "workflow" === q.value]]) : n("", true), "service" === q.value ? (t(), v(d(S), { key: 1, pageContext: F.value }, null, 8, ["pageContext"])) : n("", true), c(u(x, { ref_key: "pageEventContainerRef", ref: O, configure: F.value }, null, 8, ["configure"]), [[f, "front" === q.value]])])) : n("", true)]);
|
|
124
134
|
};
|
|
125
135
|
} });
|
|
126
136
|
export {
|
|
127
|
-
|
|
137
|
+
A as default
|
|
128
138
|
};
|
|
@@ -2,13 +2,13 @@ import { defineComponent as e, ref as l, computed as t, resolveComponent as n, c
|
|
|
2
2
|
import { Search as p } from "@element-plus/icons";
|
|
3
3
|
import { convertToExploreTreeDatas as u } from "../../../utils/page-explore-util.js";
|
|
4
4
|
const m = e({ __name: "assemblys-container-explore", props: { designItems: Array, selectWidget: Object, headerSearchClass: { type: String, default: "amb-assembly-header-search" }, treeMarginTop: { type: String, default: "margin-top:40px;" } }, emits: ["onSelectWidget", "selectComponent"], setup(e2, { emit: m2 }) {
|
|
5
|
-
const
|
|
5
|
+
const x = e2, g = m2, h = l(""), f = { children: "children", label: "label" }, v = l({}), y = t(() => u(x.designItems, h.value, v)), S = (e3) => {
|
|
6
6
|
let l2 = null;
|
|
7
|
-
null != e3.componentIndex && (l2 = v.value[e3.componentIndex]
|
|
7
|
+
null != e3.componentIndex && (l2 = v.value[e3.componentIndex], l2 && e3.componentIndex ? g("onSelectWidget", e3.componentIndex, l2) : g("onSelectWidget", -1), g("selectComponent", e3.componentIndex, l2, e3));
|
|
8
8
|
};
|
|
9
9
|
return (l2, t2) => {
|
|
10
10
|
const u2 = n("el-input"), m3 = n("el-tree");
|
|
11
|
-
return o(), a("div", null, [s("div", { class: i(e2.headerSearchClass) }, [r(u2, { modelValue:
|
|
11
|
+
return o(), a("div", null, [s("div", { class: i(e2.headerSearchClass) }, [r(u2, { modelValue: h.value, "onUpdate:modelValue": t2[0] || (t2[0] = (e3) => h.value = e3), style: { height: "36px" }, placeholder: "Search...", clearable: "", class: "input-with-select", "suffix-icon": c(p) }, null, 8, ["modelValue", "suffix-icon"])], 2), r(m3, { style: d(e2.treeMarginTop), data: y.value, props: f, "default-expand-all": "", "expand-on-click-node": false, onNodeClick: S }, null, 8, ["style", "data"])]);
|
|
12
12
|
};
|
|
13
13
|
} });
|
|
14
14
|
export {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent as e, ref as l, onMounted as a, onUnmounted as o, resolveComponent as t, createBlock as
|
|
2
|
-
import { Top as
|
|
1
|
+
import { defineComponent as e, ref as l, onMounted as a, onUnmounted as o, resolveComponent as t, createBlock as u, openBlock as d, withCtx as n, createVNode as i, createCommentVNode as m, unref as r, createElementBlock as s, toDisplayString as f, Fragment as p, renderList as c, createElementVNode as b, createTextVNode as v, withDirectives as w, vShow as h } from "vue";
|
|
2
|
+
import { Top as y, Bottom as g, Plus as V, Delete as N } from "@element-plus/icons";
|
|
3
3
|
import { ElMessageBox as k } from "element-plus";
|
|
4
|
-
import
|
|
5
|
-
import { getUuidv4 as
|
|
6
|
-
import { getFormComponentOptions as
|
|
7
|
-
import { useDraggable as
|
|
4
|
+
import _ from "../../../assemblys/common/common-variable-bind.vue.js";
|
|
5
|
+
import { getUuidv4 as x } from "../../../../utils/common-util.js";
|
|
6
|
+
import { getFormComponentOptions as I } from "../../../../utils/assemblys-config.js";
|
|
7
|
+
import { useDraggable as T } from "vue-draggable-plus";
|
|
8
8
|
const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "flex" } }, E = { key: 0 }, F = { style: { display: "flex" } }, L = { key: 0 }, q = { key: 0 }, O = ["title"], j = { key: 0 }, A = { key: 0 }, M = e({ __name: "quick-add-fields", props: { model: { type: Object, required: true } }, setup(e2, { expose: M2 }) {
|
|
9
9
|
const S = e2, D = l(null), R = l(null);
|
|
10
10
|
l([]);
|
|
@@ -12,13 +12,13 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
12
12
|
a(() => {
|
|
13
13
|
if (G.value.$el) {
|
|
14
14
|
let e3 = G.value.$el.getElementsByClassName("el-table__body");
|
|
15
|
-
e3 && e3.length > 0 && (e3 = e3[0].getElementsByTagName("tbody"), e3 && e3.length > 0 &&
|
|
15
|
+
e3 && e3.length > 0 && (e3 = e3[0].getElementsByTagName("tbody"), e3 && e3.length > 0 && T(e3[0], S.model.fieldInfos, { group: "el-table__row", handle: "amb-field-move", animation: 300, forceFallback: true, sort: true, onAdd(e4) {
|
|
16
16
|
} }));
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
19
|
const $ = l([{ value: "left", label: "靠左" }, { value: "center", label: "居中" }, { value: "right", label: "靠右" }]), P = l([{ value: "readonly", label: "只读" }, { value: "disabled", label: "禁用" }]), H = l([]);
|
|
20
20
|
for (let e3 = 2; e3 <= 24; e3 += 2) H.value.push({ value: e3, label: e3 });
|
|
21
|
-
const J = [{ value: "required", label: "必填" }, { value: "string", label: "文本" }, { value: "integer", label: "整形" }, { value: "number", label: "数字" }, { value: "boolean", label: "布尔" }, { value: "float", label: "小数" }, { value: "date", label: "日期" }, { value: "email", label: "邮箱" }, { value: "url", label: "网址" }], K = [{ value: "no", label: "不查询" }, { value: "normal", label: "普通查询" }, { value: "advanced", label: "高级查询" }], Q =
|
|
21
|
+
const J = [{ value: "required", label: "必填" }, { value: "string", label: "文本" }, { value: "integer", label: "整形" }, { value: "number", label: "数字" }, { value: "boolean", label: "布尔" }, { value: "float", label: "小数" }, { value: "date", label: "日期" }, { value: "email", label: "邮箱" }, { value: "url", label: "网址" }], K = [{ value: "no", label: "不查询" }, { value: "normal", label: "普通查询" }, { value: "advanced", label: "高级查询" }], Q = I(), W = l(null);
|
|
22
22
|
function X(e3) {
|
|
23
23
|
}
|
|
24
24
|
function Y(e3) {
|
|
@@ -30,7 +30,7 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
30
30
|
if (!S.model.fieldInfos || 0 == S.model.fieldInfos.length) return;
|
|
31
31
|
const e3 = D.value ? "确定全部设置为可编辑吗?" : "确定要全部取消可编辑吗?";
|
|
32
32
|
k.confirm(e3, "确认", { confirmButtonText: "确定", cancelButtonText: "取消", type: "warning" }).then(({ value: e4 }) => {
|
|
33
|
-
for (let e5 of S.model.fieldInfos) D.value ? e5.componentName || (e5.componentName =
|
|
33
|
+
for (let e5 of S.model.fieldInfos) D.value ? e5.componentName || (e5.componentName = de(e5.dataType)) : e5.componentName = null;
|
|
34
34
|
});
|
|
35
35
|
}
|
|
36
36
|
function le() {
|
|
@@ -48,14 +48,14 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
48
48
|
let oe;
|
|
49
49
|
function te(e3) {
|
|
50
50
|
oe && clearTimeout(oe);
|
|
51
|
-
const l2 = { uuid:
|
|
51
|
+
const l2 = { uuid: x() };
|
|
52
52
|
"list" == S.model.pageType && (l2.isTable = true);
|
|
53
|
-
const a2 =
|
|
53
|
+
const a2 = ue(e3);
|
|
54
54
|
a2 > -1 ? S.model.fieldInfos.splice(a2 + 1, 0, l2) : S.model.fieldInfos.push(l2), oe = setTimeout(() => {
|
|
55
55
|
W.value = l2.uuid;
|
|
56
56
|
}, 20);
|
|
57
57
|
}
|
|
58
|
-
function
|
|
58
|
+
function ue(e3) {
|
|
59
59
|
let l2 = -1;
|
|
60
60
|
if (!e3) return l2;
|
|
61
61
|
const a2 = S.model.fieldInfos.length;
|
|
@@ -65,6 +65,9 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
65
65
|
}
|
|
66
66
|
return l2;
|
|
67
67
|
}
|
|
68
|
+
function de(e3) {
|
|
69
|
+
return "DATE" == e3 || "TIME" == e3 ? "datePicker" : "INTEGER" == e3 || "LONG" == e3 || "FLOAT" == e3 || "DOUBLE" == e3 ? "inputNumber" : "BOOLEAN" == e3 ? "switch" : "CLOB" == e3 || "BLOB" == e3 ? "textarea" : "ENUM" == e3 ? "select" : "input-text";
|
|
70
|
+
}
|
|
68
71
|
return o(() => {
|
|
69
72
|
oe && clearTimeout(oe);
|
|
70
73
|
}), 0 == S.model.fieldInfos.length && te(null), M2({ updateInitFields: function() {
|
|
@@ -75,8 +78,8 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
75
78
|
if (S.model.modelFields) {
|
|
76
79
|
let e4 = false;
|
|
77
80
|
for (let a2 of S.model.modelFields) if ("ID" != a2.dbColumnName && !a2.edit && !l2[a2.dbColumnName]) {
|
|
78
|
-
const l3 = { uuid:
|
|
79
|
-
"form" == S.model.pageType && (
|
|
81
|
+
const l3 = { uuid: x(), fieldName: a2.dbColumnName, title: a2.alias, width: 8, dataType: a2.dataType };
|
|
82
|
+
"form" == S.model.pageType && (l3.componentName = de(a2.dataType), a2.alias && (a2.alias.includes("备注") || a2.alias.includes("说明")) && (l3.componentName = "textarea", l3.width = 24)), S.model.fieldInfos.push(l3), e4 = true;
|
|
80
83
|
}
|
|
81
84
|
if (e4) {
|
|
82
85
|
const e5 = S.model.fieldInfos[0];
|
|
@@ -84,25 +87,25 @@ const C = { key: 0 }, U = { key: 0 }, z = { key: 0 }, B = { style: { display: "f
|
|
|
84
87
|
}
|
|
85
88
|
}
|
|
86
89
|
} }), (l2, a2) => {
|
|
87
|
-
const o2 = t("el-icon"), k2 = t("el-table-column"),
|
|
88
|
-
return
|
|
89
|
-
let l4 =
|
|
90
|
+
const o2 = t("el-icon"), k2 = t("el-table-column"), x2 = t("el-option"), I2 = t("el-select"), T2 = t("el-input"), M3 = t("el-checkbox"), oe2 = t("el-switch"), de2 = t("el-table");
|
|
91
|
+
return d(), u(de2, { size: "small", border: "", "highlight-current-row": "", data: e2.model.fieldInfos, onRowClick: Z, onCellMouseEnter: X, onCellMouseLeave: Y, style: { width: "100%" }, ref_key: "thisRef", ref: G }, { default: n(() => [i(k2, { width: "36" }, { default: n((e3) => [i(o2, { size: "14", style: { cursor: "pointer" }, onClick: (l3) => function(e4) {
|
|
92
|
+
let l4 = ue(e4);
|
|
90
93
|
if (l4 < 1) return;
|
|
91
94
|
const a3 = S.model.fieldInfos;
|
|
92
95
|
[a3[l4 - 1], a3[l4]] = [a3[l4], a3[l4 - 1]];
|
|
93
|
-
}(e3.row) }, { default: n(() => [i(r(
|
|
94
|
-
let l4 =
|
|
96
|
+
}(e3.row) }, { default: n(() => [i(r(y))]), _: 2 }, 1032, ["onClick"]), i(o2, { size: "14", style: { "margin-left": "2px", cursor: "pointer" }, onClick: (l3) => function(e4) {
|
|
97
|
+
let l4 = ue(e4);
|
|
95
98
|
const a3 = S.model.fieldInfos;
|
|
96
99
|
-1 != l4 && a3.length != l4 + 1 && ([a3[l4], a3[l4 + 1]] = [a3[l4 + 1], a3[l4]]);
|
|
97
|
-
}(e3.row) }, { default: n(() => [i(r(g))]), _: 2 }, 1032, ["onClick"])]), _: 1 }), i(k2, { width: "40", align: "center" }, { header: n((e3) => [i(o2, { size: "14", style: { "margin-left": "2px", cursor: "pointer" }, onClick: ae }, { default: n(() => [i(r(
|
|
98
|
-
const l4 =
|
|
100
|
+
}(e3.row) }, { default: n(() => [i(r(g))]), _: 2 }, 1032, ["onClick"])]), _: 1 }), i(k2, { width: "40", align: "center" }, { header: n((e3) => [i(o2, { size: "14", style: { "margin-left": "2px", cursor: "pointer" }, onClick: ae }, { default: n(() => [i(r(N))]), _: 1 })]), default: n((e3) => [i(o2, { size: "14", style: { cursor: "pointer" }, onClick: (l3) => te(e3.row) }, { default: n(() => [i(r(V))]), _: 2 }, 1032, ["onClick"]), i(o2, { size: "14", style: { "margin-left": "2px", cursor: "pointer" }, onClick: (l3) => function(e4) {
|
|
101
|
+
const l4 = ue(e4);
|
|
99
102
|
l4 > -1 && (S.model.fieldInfos.splice(l4, 1), 0 == S.model.fieldInfos.length && te(null));
|
|
100
|
-
}(e3.row) }, { default: n(() => [i(r(
|
|
103
|
+
}(e3.row) }, { default: n(() => [i(r(N))]), _: 2 }, 1032, ["onClick"])]), _: 1 }), i(k2, { prop: "fieldName", label: "字段", width: "140" }, { default: n((l3) => [l3.row.uuid != W.value ? (d(), s("label", C, f(l3.row.fieldName), 1)) : (d(), u(I2, { key: 1, size: "small", modelValue: l3.row.fieldName, "onUpdate:modelValue": (e3) => l3.row.fieldName = e3, clearable: "", filterable: "", placeholder: "请选择", onChange: (e3) => function(e4) {
|
|
101
104
|
if (!e4.title && e4.fieldName) {
|
|
102
105
|
const l4 = S.model.modelFields.filter((l5) => l5.dbColumnName == e4.fieldName);
|
|
103
106
|
l4.length > 0 && (e4.title = l4[0].alias);
|
|
104
107
|
}
|
|
105
|
-
}(l3.row) }, { default: n(() => [(
|
|
108
|
+
}(l3.row) }, { default: n(() => [(d(true), s(p, null, c(e2.model.modelFields, (e3) => (d(), u(x2, { label: e3.alias + "(" + e3.dbColumnName + ")", value: e3.dbColumnName }, null, 8, ["label", "value"]))), 256))]), _: 2 }, 1032, ["modelValue", "onUpdate:modelValue", "onChange"]))]), _: 1 }), i(k2, { prop: "title", label: "标题", width: "140" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", U, f(e3.row.title), 1)) : (d(), u(T2, { key: 1, size: "small", modelValue: e3.row.title, "onUpdate:modelValue": (l3) => e3.row.title = l3, clearable: "", placeholder: "请输入" }, null, 8, ["modelValue", "onUpdate:modelValue"]))]), _: 1 }), i(k2, { prop: "querySettingName", label: "查询设置", width: "140" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", z, f(e3.row.querySettingName), 1)) : (d(), u(I2, { key: 1, size: "small", modelValue: e3.row.querySettingName, "onUpdate:modelValue": (l3) => e3.row.querySettingName = l3, clearable: "", filterable: "", placeholder: "请选择" }, { default: n(() => [(d(), s(p, null, c(K, (e4) => i(x2, { label: e4.label, value: e4.value }, null, 8, ["label", "value"])), 64))]), _: 2 }, 1032, ["modelValue", "onUpdate:modelValue"]))]), _: 1 }), i(k2, { prop: "exportable", label: "导出", width: "120" }, { header: n(() => [b("div", B, [a2[2] || (a2[2] = v(" 导出 ")), w(i(M3, { modelValue: R.value, "onUpdate:modelValue": a2[0] || (a2[0] = (e3) => R.value = e3), value: "1", label: "全部可导出", size: "small", style: { "margin-left": "6px" }, onChange: le }, null, 8, ["modelValue"]), [[h, "list" == e2.model.pageType]])])]), default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", E, f(e3.row.exportable), 1)) : (d(), u(oe2, { key: 1, modelValue: e3.row.exportable, "onUpdate:modelValue": (l3) => e3.row.exportable = l3 }, null, 8, ["modelValue", "onUpdate:modelValue"]))]), _: 1 }), i(k2, { prop: "componentName", width: "120" }, { header: n(() => [b("div", F, [a2[3] || (a2[3] = v(" 组件 ")), w(i(M3, { modelValue: D.value, "onUpdate:modelValue": a2[1] || (a2[1] = (e3) => D.value = e3), value: "1", label: "全部可编辑", size: "small", style: { "margin-left": "6px" }, onChange: ee }, null, 8, ["modelValue"]), [[h, "list" == e2.model.pageType]])])]), default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", L, f(e3.row.componentName), 1)) : (d(), u(I2, { key: 1, size: "small", modelValue: e3.row.componentName, "onUpdate:modelValue": (l3) => e3.row.componentName = l3, clearable: "", filterable: "", placeholder: "请选择" }, { default: n(() => [(d(true), s(p, null, c(r(Q), (e4) => (d(), u(x2, { label: e4.label, value: e4.name }, null, 8, ["label", "value"]))), 256))]), _: 2 }, 1032, ["modelValue", "onUpdate:modelValue"]))]), _: 1 }), i(k2, { prop: "state", label: "状态", width: "70" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", q, f(e3.row.state), 1)) : (d(), u(I2, { key: 1, size: "small", disabled: !e3.row.componentName, modelValue: e3.row.state, "onUpdate:modelValue": (l3) => e3.row.state = l3, clearable: "", filterable: "", placeholder: "默认" }, { default: n(() => [(d(true), s(p, null, c(P.value, (e4) => (d(), u(x2, { value: e4.value, label: e4.label }, null, 8, ["value", "label"]))), 256))]), _: 2 }, 1032, ["disabled", "modelValue", "onUpdate:modelValue"]))]), _: 1 }), i(k2, { prop: "valid", label: "校验", width: "120" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", { key: 0, title: e3.row.valid }, f(e3.row.valid), 9, O)) : (d(), u(I2, { key: 1, disabled: !e3.row.componentName, size: "small", modelValue: e3.row.valid, "onUpdate:modelValue": (l3) => e3.row.valid = l3, clearable: "", placeholder: "无校验", multiple: "", "collapse-tags": "", "collapse-tags-tooltip": "" }, { default: n(() => [(d(), s(p, null, c(J, (e4, l3) => i(x2, { label: e4.label, value: e4.value }, null, 8, ["label", "value"])), 64))]), _: 2 }, 1032, ["disabled", "modelValue", "onUpdate:modelValue"]))]), _: 1 }), "form" == e2.model.pageType ? (d(), u(k2, { key: 0, prop: "width", label: "宽度(栏数)", width: "75" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", j, f(e3.row.width), 1)) : (d(), u(I2, { key: 1, size: "small", modelValue: e3.row.width, "onUpdate:modelValue": (l3) => e3.row.width = l3, clearable: "", placeholder: "请选择" }, { default: n(() => [(d(true), s(p, null, c(H.value, (e4) => (d(), u(x2, { value: e4.value, label: e4.label }, null, 8, ["value", "label"]))), 256))]), _: 2 }, 1032, ["modelValue", "onUpdate:modelValue"]))]), _: 1 })) : m("", true), "list" == e2.model.pageType ? (d(), u(k2, { key: 1, prop: "align", label: "左右对齐", width: "70" }, { default: n((e3) => [e3.row.uuid != W.value ? (d(), s("label", A, f(e3.row.align), 1)) : (d(), u(I2, { key: 1, size: "small", modelValue: e3.row.align, "onUpdate:modelValue": (l3) => e3.row.align = l3, clearable: "", placeholder: "请选择" }, { default: n(() => [(d(true), s(p, null, c($.value, (e4) => (d(), u(x2, { value: e4.value, label: e4.label }, null, 8, ["value", "label"]))), 256))]), _: 2 }, 1032, ["modelValue", "onUpdate:modelValue"]))]), _: 1 })) : m("", true), i(k2, { prop: "value", label: "默认值", width: "120" }, { default: n((e3) => [i(_, { showLabel: e3.row.uuid != W.value || !e3.row.componentName, modelValue: e3.row.value, paramTypes: ["request", "context", "page", "fixed"], "onUpdate:modelValue": (l3) => function(e4, l4) {
|
|
106
109
|
l4.value = e4;
|
|
107
110
|
}(l3, e3.row) }, null, 8, ["showLabel", "modelValue", "onUpdate:modelValue"])]), _: 1 })]), _: 1 }, 8, ["data"]);
|
|
108
111
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { defineComponent as e, ref as i, reactive as n, computed as t, watch as l, onMounted as o, onUnmounted as s, resolveComponent as r, createElementBlock as u, openBlock as a, Fragment as c, createElementVNode as g, createBlock as m, createCommentVNode as p, createVNode as f, normalizeStyle as d, withDirectives as v, normalizeClass as b, withCtx as y, unref as h, vShow as
|
|
1
|
+
import { defineComponent as e, ref as i, reactive as n, computed as t, watch as l, onMounted as o, onUnmounted as s, resolveComponent as r, createElementBlock as u, openBlock as a, Fragment as c, createElementVNode as g, createBlock as m, createCommentVNode as p, createVNode as f, normalizeStyle as d, withDirectives as v, normalizeClass as b, withCtx as y, unref as h, vShow as C, renderList as j } from "vue";
|
|
2
2
|
import { Monitor as S, Cellphone as k, Iphone as O, Plus as _, Check as A, View as T } from "@element-plus/icons";
|
|
3
3
|
import { useDraggable as D } from "vue-draggable-plus";
|
|
4
4
|
import w from "../../assemblys/object-design.vue.js";
|
|
5
5
|
import { deepCopy as x, getUuidv4 as W, findDesignItemByUuid as N } from "../../../utils/common-util.js";
|
|
6
6
|
import { addComponentRef as E } from "../../../utils/page-helper-util.js";
|
|
7
|
-
import { caculatePageStyle as
|
|
8
|
-
import
|
|
9
|
-
import { ElMessage as
|
|
7
|
+
import { caculatePageStyle as R } from "../../../utils/container-design-util.js";
|
|
8
|
+
import U from "./view-design-preview.vue.js";
|
|
9
|
+
import { ElMessage as J } from "element-plus";
|
|
10
10
|
import "@vueuse/core";
|
|
11
11
|
import "@element-plus/icons-vue";
|
|
12
12
|
import "codemirror";
|
|
@@ -21,9 +21,9 @@ import "../../../utils/assemblys-config.js";
|
|
|
21
21
|
import "../../../../../stores/page-store.js";
|
|
22
22
|
import "../../../../../stores/event-undo-redo-store.js";
|
|
23
23
|
import "../../../utils/eventBus.js";
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import { setTableRuntimesFromConfigure as
|
|
24
|
+
import P from "./components/quick-add-dialog.vue.js";
|
|
25
|
+
import z from "./components/i18n-setting.vue.js";
|
|
26
|
+
import { setTableRuntimesFromConfigure as M } from "../../../utils/page-table-util.js";
|
|
27
27
|
import B from "agilebuilder-ui/src/utils/request";
|
|
28
28
|
import { copyHandleEvents as K, deleteDesignItem as q } from "../../../utils/page-design-util.js";
|
|
29
29
|
import { setHomeChartRuntimesFromConfigure as V } from "../../../utils/home-chart-util.js";
|
|
@@ -41,7 +41,7 @@ const H = { class: "amb-design-content-center-header" }, L = { class: "amb-desig
|
|
|
41
41
|
return se.value && (i2["min-height"] = se.value + "px"), i2;
|
|
42
42
|
});
|
|
43
43
|
function ue() {
|
|
44
|
-
|
|
44
|
+
R(X.configure, le, oe), X.configure.runtime || (X.configure.runtime = {}), X.configure.runtime.class = oe.value, X.configure.runtime.style = le.value;
|
|
45
45
|
}
|
|
46
46
|
l(X.configure.props, () => {
|
|
47
47
|
ue();
|
|
@@ -81,24 +81,34 @@ const H = { class: "amb-design-content-center-header" }, L = { class: "amb-desig
|
|
|
81
81
|
const e3 = JSON.parse(JSON.stringify(X.configure));
|
|
82
82
|
e3.tableRuntimes = {}, e3.currentTableConfig = {}, function(e4) {
|
|
83
83
|
"form" === e4.pageType && e4.items ? (e4.formPropTiltleMap = F(e4), X.configure.formPropTiltleMap = e4.formPropTiltleMap) : (delete e4.formPropLabelMap, delete X.configure.formPropLabelMap);
|
|
84
|
-
|
|
85
|
-
const
|
|
86
|
-
|
|
87
|
-
|
|
84
|
+
if (e4.tableUuids) {
|
|
85
|
+
const i2 = {};
|
|
86
|
+
e4.tableUuids = e4.tableUuids.filter((n2) => {
|
|
87
|
+
const t2 = N(e4, n2);
|
|
88
|
+
if (t2) {
|
|
89
|
+
if (M(t2, e4), e4.tableRuntimes && e4.tableRuntimes[n2]) {
|
|
90
|
+
const l2 = e4.tableRuntimes[n2];
|
|
91
|
+
l2.code && (t2.code ? i2[l2.code] = t2.code : i2[l2.code] = l2.code);
|
|
92
|
+
}
|
|
93
|
+
return true;
|
|
94
|
+
}
|
|
95
|
+
return false;
|
|
96
|
+
}), e4.listCodesMap = i2;
|
|
97
|
+
}
|
|
88
98
|
e4.homepageChartUuids && (e4.homepageChartUuids = e4.homepageChartUuids.filter((i2) => {
|
|
89
99
|
let n2 = N(e4, i2);
|
|
90
100
|
return !!n2 && (n2 = JSON.parse(JSON.stringify(n2)), V(n2, e4), true);
|
|
91
101
|
}));
|
|
92
102
|
}(e3), B.post(window.$vueApp.config.globalProperties.baseAPI + "/component/super-page-design/save", { id: X.configure.id, designJson: JSON.stringify(e3) }).then((e4) => {
|
|
93
|
-
|
|
103
|
+
J({ message: "保存成功", type: "success" });
|
|
94
104
|
}).catch((e4) => {
|
|
95
|
-
|
|
105
|
+
J({ message: "保存失败", type: "error" });
|
|
96
106
|
});
|
|
97
107
|
}
|
|
98
108
|
D(be, ie, { filter: ".el-scrollbar__bar", preventOnFilter: false, group: "amb-assembly-item", animation: 300, ghostClass: "amb-item-ghost", forceFallback: true, onAdd(e3) {
|
|
99
109
|
} });
|
|
100
110
|
const he = i(false);
|
|
101
|
-
const
|
|
111
|
+
const Ce = i(null), je = i({}), Se = i({}), ke = i(false);
|
|
102
112
|
let Oe;
|
|
103
113
|
function _e() {
|
|
104
114
|
Oe && clearTimeout(Oe), ke.value = false, Oe = setTimeout(() => {
|
|
@@ -116,18 +126,18 @@ const H = { class: "amb-design-content-center-header" }, L = { class: "amb-desig
|
|
|
116
126
|
}), G2({ onSelectEvent: function(e3) {
|
|
117
127
|
ke.value = !(!e3 || "selected" !== e3);
|
|
118
128
|
}, addEvent: function(e3, i2) {
|
|
119
|
-
|
|
129
|
+
je.value = e3;
|
|
120
130
|
const n2 = Ae(e3.eventName);
|
|
121
|
-
n2 && (Se.value = n2),
|
|
131
|
+
n2 && (Se.value = n2), Ce.value = i2 || "event", _e();
|
|
122
132
|
}, changeEvent: function(e3) {
|
|
123
133
|
if (e3) {
|
|
124
|
-
|
|
134
|
+
Ce.value = null, je.value = e3;
|
|
125
135
|
const i2 = Ae(e3.eventName);
|
|
126
136
|
Se.value = i2 || null, _e();
|
|
127
137
|
} else ke.value = false;
|
|
128
138
|
} }), (e3, i2) => {
|
|
129
139
|
const n2 = r("el-icon"), t2 = r("el-divider"), l2 = r("Setting");
|
|
130
|
-
return a(), u(c, null, [g("div", { class: "amb-design-content", ref_key: "ambPageDesignContent", ref: ge, style: d(ce.value) }, [g("div", H, [g("div", L, [g("div", I, [v(g("label", { class: b(["amb-page-type", { selected: !e3.configure.dimensions || "pc" == e3.configure.dimensions }]), onClick: i2[0] || (i2[0] = (i3) => e3.configure.dimensions = "pc") }, [f(n2, { size: 23 }, { default: y(() => [f(h(S))]), _: 1 })], 2), [[
|
|
140
|
+
return a(), u(c, null, [g("div", { class: "amb-design-content", ref_key: "ambPageDesignContent", ref: ge, style: d(ce.value) }, [g("div", H, [g("div", L, [g("div", I, [v(g("label", { class: b(["amb-page-type", { selected: !e3.configure.dimensions || "pc" == e3.configure.dimensions }]), onClick: i2[0] || (i2[0] = (i3) => e3.configure.dimensions = "pc") }, [f(n2, { size: 23 }, { default: y(() => [f(h(S))]), _: 1 })], 2), [[C, "assembly" === e3.selAsselbyType]]), v(g("label", { class: b(["amb-page-type", { selected: "ipad" == e3.configure.dimensions }]), onClick: i2[1] || (i2[1] = (i3) => e3.configure.dimensions = "ipad") }, [f(n2, { size: 23 }, { default: y(() => [f(h(k))]), _: 1 })], 2), [[C, "assembly" === e3.selAsselbyType]]), v(g("label", { class: b(["amb-page-type", { selected: "phone" == e3.configure.dimensions }]), onClick: i2[2] || (i2[2] = (i3) => e3.configure.dimensions = "phone") }, [f(n2, { size: 23 }, { default: y(() => [f(h(O))]), _: 1 })], 2), [[C, "assembly" === e3.selAsselbyType]]), v(f(t2, { direction: "vertical" }, null, 512), [[C, "assembly" === e3.selAsselbyType]])]), g("div", $, [g("label", { class: "amb-page-type", onClick: i2[3] || (i2[3] = (e4) => {
|
|
131
141
|
var _a;
|
|
132
142
|
(_a = Z.value) == null ? void 0 : _a.show();
|
|
133
143
|
}) }, [f(n2, { size: 18 }, { default: y(() => [f(l2)]), _: 1 }), i2[9] || (i2[9] = g("label", null, "国际化配置", -1))]), g("label", { class: "amb-page-type", onClick: i2[4] || (i2[4] = (e4) => {
|
|
@@ -136,9 +146,9 @@ const H = { class: "amb-design-content-center-header" }, L = { class: "amb-desig
|
|
|
136
146
|
const e5 = JSON.parse(JSON.stringify(X.configure));
|
|
137
147
|
e5.tableRuntimes = {}, e5.tableUuids && e5.tableUuids.forEach((i3) => {
|
|
138
148
|
const n3 = N(e5, i3);
|
|
139
|
-
n3 &&
|
|
149
|
+
n3 && M(n3, e5);
|
|
140
150
|
}), ne.value = e5, he.value = true;
|
|
141
|
-
}()) }, [f(n2, { size: 18 }, { default: y(() => [f(h(T))]), _: 1 }), i2[12] || (i2[12] = g("label", null, "预览", -1))])])])]), v(g("div", { class: b(["amb-design-board", oe.value]), ref_key: "pageDesignBoardMain", ref: be, style: d(re.value), onClick: me }, [(a(true), u(c, null,
|
|
151
|
+
}()) }, [f(n2, { size: 18 }, { default: y(() => [f(h(T))]), _: 1 }), i2[12] || (i2[12] = g("label", null, "预览", -1))])])])]), v(g("div", { class: b(["amb-design-board", oe.value]), ref_key: "pageDesignBoardMain", ref: be, style: d(re.value), onClick: me }, [(a(true), u(c, null, j(h(ie), (i3, n3) => (a(), m(w, { key: i3.uuid, indexObj: te, configure: i3, pageDesign: e3.configure, selectWidget: e3.selectWidget, onOnSelectWidget: pe, onOnCustomAttrWidget: fe, onOnCopy: de, onOnDelete: ve }, null, 8, ["indexObj", "configure", "pageDesign", "selectWidget"]))), 128))], 6), [[C, "assembly" === e3.selAsselbyType]])], 4), he.value ? (a(), m(U, { key: 0, pageDesign: ne.value, modelValue: he.value, "onUpdate:modelValue": i2[7] || (i2[7] = (e4) => he.value = e4), onClose: i2[8] || (i2[8] = (e4) => he.value = false) }, null, 8, ["pageDesign", "modelValue"])) : p("", true), f(P, { ref_key: "quickAddDialogRef", ref: Y, pageDesign: e3.configure }, null, 8, ["pageDesign"]), f(z, { ref_key: "i18nSettingRef", ref: Z, pageDesign: e3.configure }, null, 8, ["pageDesign"])], 64);
|
|
142
152
|
};
|
|
143
153
|
} });
|
|
144
154
|
export {
|