super-page-designer 2.0.17 → 2.0.23
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/assets/fonts/iconfont.css.js +1 -0
- package/dist/es/components/design/utils/assemblys-config.js +125 -63
- package/dist/es/components/design/utils/data-table-util.js +4 -4
- package/dist/es/components/design/utils/form-design-util.js +11 -0
- package/dist/es/components/design/utils/page-service-util.js +1 -1
- package/dist/es/components/design/utils/page-table-util.js +3 -3
- package/dist/es/components/design/views/assemblys/button/button/button-attr-base.vue.js +13 -7
- package/dist/es/components/design/views/assemblys/button/button-group/buttongroup-design.vue2.js +16 -8
- package/dist/es/components/design/views/assemblys/button/dropdown/dropdown-attr-base.vue.js +4 -1
- package/dist/es/components/design/views/assemblys/chart/column-line/column-line-design.vue2.js +1 -0
- package/dist/es/components/design/views/assemblys/common/common-icon-bind.vue.js +16 -12
- package/dist/es/components/design/views/assemblys/common/common-select-page.vue.js +10 -8
- package/dist/es/components/design/views/assemblys/common/common-select-table.vue.js +10 -7
- package/dist/es/components/design/views/assemblys/common/common-style-background.vue.js +31 -9
- package/dist/es/components/design/views/assemblys/common/common-variable-bind-option.js +6 -1
- package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue.d.ts +1 -1
- package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue2.js +5 -5
- package/dist/es/components/design/views/assemblys/common/page-permission-select.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/container/container/container-design.vue2.js +17 -7
- package/dist/es/components/design/views/assemblys/container/flex/flex-design.vue2.js +17 -7
- package/dist/es/components/design/views/assemblys/container/form/form-design.vue2.js +18 -8
- package/dist/es/components/design/views/assemblys/container/tools/tools-design.vue2.js +14 -8
- package/dist/es/components/design/views/assemblys/data/bar-code/barcode-attr-base.vue.js +33 -16
- package/dist/es/components/design/views/assemblys/data/component/column-config.vue.js +37 -34
- package/dist/es/components/design/views/assemblys/data/component/data-origin.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/data-origin.vue2.js +112 -13
- package/dist/es/components/design/views/assemblys/data/component/querySetting.vue.js +0 -5
- package/dist/es/components/design/views/assemblys/data/component/table-children-column.vue.js +18 -9
- package/dist/es/components/design/views/assemblys/data/table/table-attr-advanced.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/table/table-attr-base.vue.js +31 -8
- package/dist/es/components/design/views/assemblys/data/table/table-attr.vue2.js +10 -9
- 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 +13 -8
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue.js +64 -75
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-event.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/tree/tree-attr-base.vue.js +44 -37
- package/dist/es/components/design/views/assemblys/form/checkbox/checkbox-attr-base.vue.js +22 -13
- package/dist/es/components/design/views/assemblys/form/common/attr-event.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/common/attr-event.vue2.js +2 -1
- package/dist/es/components/design/views/assemblys/form/common/bar-code-rule.vue.js +15 -50
- package/dist/es/components/design/views/assemblys/form/common/data-format.vue.js +4 -3
- package/dist/es/components/design/views/assemblys/form/common/data-origin.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/common/data-origin.vue2.js +4 -1
- package/dist/es/components/design/views/assemblys/form/common/linkpage-page-callback.vue.js +3 -42
- package/dist/es/components/design/views/assemblys/form/common/parameter-table.vue.js +19 -13
- package/dist/es/components/design/views/assemblys/form/common/pre-suffix.vue.js +5 -68
- package/dist/es/components/design/views/assemblys/form/common/suffixmodule.vue.js +24 -14
- package/dist/es/components/design/views/assemblys/form/date-picker/datepicker-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-attr-base.vue.js +21 -11
- package/dist/es/components/design/views/assemblys/form/divider/divider-attr-base.vue.js +6 -4
- package/dist/es/components/design/views/assemblys/form/divider/divider-attr-event.vue.js +5 -5
- package/dist/es/components/design/views/assemblys/form/divider/divider-attr-style.vue.js +6 -0
- package/dist/es/components/design/views/assemblys/form/divider/divider-design.vue2.js +17 -16
- package/dist/es/components/design/views/assemblys/form/file-upload/fileupload-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/form/input-number/input-number-attr-base.vue.js +24 -9
- package/dist/es/components/design/views/assemblys/form/input-number/input-number-design.vue2.js +1 -0
- package/dist/es/components/design/views/assemblys/form/input-text/inputtext-attr-base.vue.js +19 -11
- package/dist/es/components/design/views/assemblys/form/input-text/inputtext-design.vue2.js +1 -0
- package/dist/es/components/design/views/assemblys/form/label/label-attr-base.vue.js +20 -10
- package/dist/es/components/design/views/assemblys/form/link/link-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/form/placeholder/placeholder-attr-base.vue.js +3 -2
- package/dist/es/components/design/views/assemblys/form/placeholder/placeholder-attr-style.vue.js +6 -0
- package/dist/es/components/design/views/assemblys/form/placeholder/placeholder-design.vue2.js +8 -13
- package/dist/es/components/design/views/assemblys/form/radio/radio-attr-base.vue.js +22 -13
- package/dist/es/components/design/views/assemblys/form/rich-text/richtext-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/form/rich-text/richtext-design.vue2.js +2 -2
- package/dist/es/components/design/views/assemblys/form/select/select-attr-base.vue.js +25 -15
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-advanced.vue.js +40 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-advanced.vue2.js +4 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-base.vue.js +142 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-base.vue2.js +4 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-style.vue.js +53 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr-style.vue2.js +4 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr.vue.js +4 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-attr.vue2.js +93 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-design.vue.js +4 -0
- package/dist/es/components/design/views/assemblys/form/separatelabel/separatelabel-design.vue2.js +56 -0
- package/dist/es/components/design/views/assemblys/form/switch/switch-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/form/tag/tag-attr-base.vue.js +13 -7
- package/dist/es/components/design/views/assemblys/form/textarea/textarea-attr-base.vue.js +16 -9
- package/dist/es/components/design/views/assemblys/object-design.vue.js +2 -1
- package/dist/es/components/design/views/assemblys/page/component/setting-form-rule-base-input.vue.d.ts +2 -2
- package/dist/es/components/design/views/assemblys/page/component/setting-form-rule-base-input.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/workflow/component/combination.vue.d.ts +1 -1
- package/dist/es/components/design/views/assemblys/workflow/component/combination.vue.js +9 -11
- package/dist/es/components/design/views/assemblys/workflow/picture-flow/pictureflow-attr-base.vue.js +20 -5
- package/dist/es/components/design/views/assemblys/workflow/text-history/texthistory-attr-base.vue.js +9 -7
- package/dist/es/components/design/views/design/page-design.vue.js +135 -133
- package/dist/es/components/design/views/design/view/attr-container.vue.js +1 -0
- package/dist/es/components/design/views/design/view/components/quick-add-dialog.vue.d.ts +18 -0
- package/dist/es/components/design/views/design/view/components/quick-add-dialog.vue.js +678 -0
- package/dist/es/components/design/views/design/view/components/quick-add-dialog.vue2.js +4 -0
- package/dist/es/components/design/views/design/view/components/quick-add-fields.vue.d.ts +16 -0
- package/dist/es/components/design/views/design/view/components/quick-add-fields.vue.js +602 -0
- package/dist/es/components/design/views/design/view/components/quick-add-fields.vue2.js +4 -0
- package/dist/es/components/design/views/design/view/page-switch.vue.js +1 -1
- package/dist/es/components/design/views/design/view/page-switch.vue2.js +2 -2
- package/dist/es/components/design/views/design/view/view-design-display.vue.d.ts +4 -0
- package/dist/es/components/design/views/design/view/view-design-display.vue.js +82 -39
- package/dist/es/components/design/views/design/view/view-design.vue.d.ts +13 -1
- package/dist/es/components/design/views/design/view/view-design.vue.js +13 -3
- package/dist/es/index.d.ts +1 -1
- package/dist/es/index.js +1 -0
- package/dist/es/stores/page-store.js +1 -1
- package/dist/es/stores/undo-redo-store.d.ts +13 -0
- package/dist/es/stores/undo-redo-store.js +44 -0
- package/dist/es/style.css +977 -177
- package/package.json +6 -4
- package/dist/es/components/design/views/assemblys/data/component/formatting.vue.js +0 -539
- package/dist/es/components/design/views/assemblys/data/component/formatting.vue2.js +0 -4
|
@@ -0,0 +1,602 @@
|
|
|
1
|
+
import { defineComponent, ref, onMounted, resolveComponent, openBlock, createBlock, withCtx, createVNode, unref, createElementBlock, toDisplayString, Fragment, renderList, createElementVNode, createTextVNode, withDirectives, vShow, createCommentVNode } from "vue";
|
|
2
|
+
import { Top, Bottom, Delete, Plus } from "@element-plus/icons";
|
|
3
|
+
import BindVariable from "../../../assemblys/common/common-variable-bind.vue.js";
|
|
4
|
+
import { getUuidv4 } from "../../../../utils/common-util.js";
|
|
5
|
+
import { getFormComponentOptions } from "../../../../utils/assemblys-config.js";
|
|
6
|
+
import { useDraggable } from "vue-draggable-plus";
|
|
7
|
+
const _hoisted_1 = { key: 0 };
|
|
8
|
+
const _hoisted_2 = { key: 0 };
|
|
9
|
+
const _hoisted_3 = { style: { "display": "flex" } };
|
|
10
|
+
const _hoisted_4 = { key: 0 };
|
|
11
|
+
const _hoisted_5 = { key: 0 };
|
|
12
|
+
const _hoisted_6 = ["title"];
|
|
13
|
+
const _hoisted_7 = { key: 0 };
|
|
14
|
+
const _hoisted_8 = { key: 0 };
|
|
15
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
16
|
+
__name: "quick-add-fields",
|
|
17
|
+
props: {
|
|
18
|
+
model: {
|
|
19
|
+
type: Object
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
setup(__props, { expose: __expose }) {
|
|
23
|
+
const props = __props;
|
|
24
|
+
const allEditState = ref(null);
|
|
25
|
+
ref([]);
|
|
26
|
+
const thisRef = ref(null);
|
|
27
|
+
onMounted(() => {
|
|
28
|
+
if (thisRef.value.$el) {
|
|
29
|
+
let tbody = thisRef.value.$el.getElementsByClassName("el-table__body");
|
|
30
|
+
if (tbody && tbody.length > 0) {
|
|
31
|
+
tbody = tbody[0].getElementsByTagName("tbody");
|
|
32
|
+
if (tbody && tbody.length > 0) {
|
|
33
|
+
console.log("tbody", tbody);
|
|
34
|
+
useDraggable(tbody[0], props.model.fieldInfos, {
|
|
35
|
+
group: "el-table__row",
|
|
36
|
+
handle: "amb-field-move",
|
|
37
|
+
animation: 300,
|
|
38
|
+
forceFallback: true,
|
|
39
|
+
sort: true,
|
|
40
|
+
onAdd(event) {
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
const alignOptions = ref([
|
|
48
|
+
{
|
|
49
|
+
value: "left",
|
|
50
|
+
label: "靠左"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
value: "center",
|
|
54
|
+
label: "居中"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
value: "right",
|
|
58
|
+
label: "靠右"
|
|
59
|
+
}
|
|
60
|
+
]);
|
|
61
|
+
const stateOptions = ref([
|
|
62
|
+
{
|
|
63
|
+
value: "readonly",
|
|
64
|
+
label: "只读"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
value: "disabled",
|
|
68
|
+
label: "禁用"
|
|
69
|
+
}
|
|
70
|
+
]);
|
|
71
|
+
const widthOptions = ref([]);
|
|
72
|
+
for (let i = 2; i <= 24; i += 2) {
|
|
73
|
+
widthOptions.value.push({
|
|
74
|
+
value: i,
|
|
75
|
+
label: i
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
const validOptions = [
|
|
79
|
+
{
|
|
80
|
+
value: "required",
|
|
81
|
+
label: "必填"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
value: "string",
|
|
85
|
+
label: "文本"
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
value: "integer",
|
|
89
|
+
label: "整形"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
value: "number",
|
|
93
|
+
label: "数字"
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
value: "boolean",
|
|
97
|
+
label: "布尔"
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
value: "float",
|
|
101
|
+
label: "小数"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
value: "date",
|
|
105
|
+
label: "日期"
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
value: "email",
|
|
109
|
+
label: "邮箱"
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
value: "url",
|
|
113
|
+
label: "网址"
|
|
114
|
+
}
|
|
115
|
+
];
|
|
116
|
+
const formComponents = getFormComponentOptions();
|
|
117
|
+
const selRowUuid = ref(null);
|
|
118
|
+
function onMouseEnter(obj) {
|
|
119
|
+
}
|
|
120
|
+
function onMouseLeave(obj) {
|
|
121
|
+
}
|
|
122
|
+
function onRowClick(obj) {
|
|
123
|
+
selRowUuid.value = obj.uuid;
|
|
124
|
+
}
|
|
125
|
+
function fieldChange(rowObj) {
|
|
126
|
+
if (!rowObj.title && rowObj.fieldName) {
|
|
127
|
+
const selItems = props.model.modelFields.filter((item) => {
|
|
128
|
+
return item.dbColumnName == rowObj.fieldName;
|
|
129
|
+
});
|
|
130
|
+
if (selItems.length > 0) {
|
|
131
|
+
rowObj.title = selItems[0].alias;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
function updateEditState() {
|
|
136
|
+
if (!props.model.fieldInfos || props.model.fieldInfos.length == 0) {
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
const message = allEditState.value ? "确定全部设置为可编辑吗?" : "确定要全部取消可编辑吗?";
|
|
140
|
+
ElMessageBox.confirm(message, "确认", {
|
|
141
|
+
confirmButtonText: "确定",
|
|
142
|
+
cancelButtonText: "取消",
|
|
143
|
+
type: "warning"
|
|
144
|
+
}).then(({ value }) => {
|
|
145
|
+
for (let f of props.model.fieldInfos) {
|
|
146
|
+
if (allEditState.value) {
|
|
147
|
+
if (!f.componentName) {
|
|
148
|
+
f.componentName = "input-text";
|
|
149
|
+
}
|
|
150
|
+
} else {
|
|
151
|
+
f.componentName = null;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
function removeAll() {
|
|
157
|
+
ElMessageBox.confirm("确定要全部清除吗?", "确认", {
|
|
158
|
+
confirmButtonText: "确定",
|
|
159
|
+
cancelButtonText: "取消",
|
|
160
|
+
type: "warning"
|
|
161
|
+
}).then(({ value }) => {
|
|
162
|
+
props.model.fieldInfos = [];
|
|
163
|
+
add(null);
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
function remove(rowObj) {
|
|
167
|
+
const existIndex = queryIndex(rowObj);
|
|
168
|
+
if (existIndex > -1) {
|
|
169
|
+
props.model.fieldInfos.splice(existIndex, 1);
|
|
170
|
+
if (props.model.fieldInfos.length == 0) {
|
|
171
|
+
add(null);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
function add(rowObj) {
|
|
176
|
+
const rowItem = {
|
|
177
|
+
uuid: getUuidv4()
|
|
178
|
+
};
|
|
179
|
+
const existIndex = queryIndex(rowObj);
|
|
180
|
+
if (existIndex > -1) {
|
|
181
|
+
props.model.fieldInfos.splice(existIndex + 1, 0, rowItem);
|
|
182
|
+
} else {
|
|
183
|
+
props.model.fieldInfos.push(rowItem);
|
|
184
|
+
}
|
|
185
|
+
setTimeout(() => {
|
|
186
|
+
selRowUuid.value = rowItem.uuid;
|
|
187
|
+
}, 20);
|
|
188
|
+
}
|
|
189
|
+
if (props.model.fieldInfos.length == 0) {
|
|
190
|
+
add(null);
|
|
191
|
+
}
|
|
192
|
+
function moveTop(rowItem) {
|
|
193
|
+
let sortIndex = queryIndex(rowItem);
|
|
194
|
+
if (sortIndex < 1) {
|
|
195
|
+
return;
|
|
196
|
+
}
|
|
197
|
+
const items = props.model.fieldInfos;
|
|
198
|
+
[items[sortIndex - 1], items[sortIndex]] = [items[sortIndex], items[sortIndex - 1]];
|
|
199
|
+
}
|
|
200
|
+
function moveToBottom(rowItem) {
|
|
201
|
+
let sortIndex = queryIndex(rowItem);
|
|
202
|
+
const items = props.model.fieldInfos;
|
|
203
|
+
if (sortIndex == -1 || items.length == sortIndex + 1) {
|
|
204
|
+
return;
|
|
205
|
+
}
|
|
206
|
+
[items[sortIndex], items[sortIndex + 1]] = [items[sortIndex + 1], items[sortIndex]];
|
|
207
|
+
}
|
|
208
|
+
function queryIndex(rowItem) {
|
|
209
|
+
let sortIndex = -1;
|
|
210
|
+
if (!rowItem) {
|
|
211
|
+
return sortIndex;
|
|
212
|
+
}
|
|
213
|
+
const itemLen = props.model.fieldInfos.length;
|
|
214
|
+
for (let index = 0; index < itemLen; index++) {
|
|
215
|
+
if (props.model.fieldInfos[index].uuid == rowItem.uuid) {
|
|
216
|
+
sortIndex = index;
|
|
217
|
+
break;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
return sortIndex;
|
|
221
|
+
}
|
|
222
|
+
function updatePropValue(val, rowObj) {
|
|
223
|
+
rowObj.value = val;
|
|
224
|
+
}
|
|
225
|
+
function updateInitFields() {
|
|
226
|
+
const nameMap = {};
|
|
227
|
+
if (props.model.modelFields) {
|
|
228
|
+
for (let f of props.model.modelFields) {
|
|
229
|
+
nameMap[f.dbColumnName] = f;
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
const existMap = {};
|
|
233
|
+
for (let row of props.model.fieldInfos) {
|
|
234
|
+
if (row.fieldName) {
|
|
235
|
+
if (!nameMap[row.fieldName]) {
|
|
236
|
+
row.fieldName = null;
|
|
237
|
+
} else {
|
|
238
|
+
existMap[row.fieldName] = true;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
if (props.model.modelFields) {
|
|
243
|
+
let hasAdd = false;
|
|
244
|
+
for (let f of props.model.modelFields) {
|
|
245
|
+
if (f.dbColumnName == "ID") {
|
|
246
|
+
continue;
|
|
247
|
+
}
|
|
248
|
+
if (f.edit) {
|
|
249
|
+
continue;
|
|
250
|
+
}
|
|
251
|
+
if (!existMap[f.dbColumnName]) {
|
|
252
|
+
const rowItem = {
|
|
253
|
+
uuid: getUuidv4(),
|
|
254
|
+
fieldName: f.dbColumnName,
|
|
255
|
+
title: f.alias,
|
|
256
|
+
width: 8
|
|
257
|
+
};
|
|
258
|
+
if (props.model.pageType == "form") {
|
|
259
|
+
if (f.type == "DATE" || f.type == "TIME") {
|
|
260
|
+
rowItem.componentName = "datePicker";
|
|
261
|
+
} else {
|
|
262
|
+
rowItem.componentName = "input-text";
|
|
263
|
+
}
|
|
264
|
+
if (f.alias && (f.alias.includes("备注") || f.alias.includes("说明"))) {
|
|
265
|
+
rowItem.componentName = "textarea";
|
|
266
|
+
rowItem.width = 24;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
props.model.fieldInfos.push(rowItem);
|
|
270
|
+
hasAdd = true;
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
if (hasAdd) {
|
|
274
|
+
const firstItem = props.model.fieldInfos[0];
|
|
275
|
+
if (!firstItem.fieldName && !firstItem.title && !firstItem.componentName) {
|
|
276
|
+
props.model.fieldInfos.splice(0, 1);
|
|
277
|
+
}
|
|
278
|
+
selRowUuid.value = props.model.fieldInfos[0].uuid;
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
__expose({
|
|
283
|
+
updateInitFields
|
|
284
|
+
});
|
|
285
|
+
return (_ctx, _cache) => {
|
|
286
|
+
const _component_el_icon = resolveComponent("el-icon");
|
|
287
|
+
const _component_el_table_column = resolveComponent("el-table-column");
|
|
288
|
+
const _component_el_option = resolveComponent("el-option");
|
|
289
|
+
const _component_el_select = resolveComponent("el-select");
|
|
290
|
+
const _component_el_input = resolveComponent("el-input");
|
|
291
|
+
const _component_el_checkbox = resolveComponent("el-checkbox");
|
|
292
|
+
const _component_el_table = resolveComponent("el-table");
|
|
293
|
+
return openBlock(), createBlock(_component_el_table, {
|
|
294
|
+
size: "small",
|
|
295
|
+
border: "",
|
|
296
|
+
"highlight-current-row": "",
|
|
297
|
+
data: __props.model.fieldInfos,
|
|
298
|
+
onRowClick,
|
|
299
|
+
onCellMouseEnter: onMouseEnter,
|
|
300
|
+
onCellMouseLeave: onMouseLeave,
|
|
301
|
+
style: { "width": "100%" },
|
|
302
|
+
ref_key: "thisRef",
|
|
303
|
+
ref: thisRef
|
|
304
|
+
}, {
|
|
305
|
+
default: withCtx(() => [
|
|
306
|
+
createVNode(_component_el_table_column, { width: "36" }, {
|
|
307
|
+
default: withCtx((scope) => [
|
|
308
|
+
createVNode(_component_el_icon, {
|
|
309
|
+
size: "14",
|
|
310
|
+
style: { "cursor": "pointer" },
|
|
311
|
+
onClick: ($event) => moveTop(scope.row)
|
|
312
|
+
}, {
|
|
313
|
+
default: withCtx(() => [
|
|
314
|
+
createVNode(unref(Top))
|
|
315
|
+
]),
|
|
316
|
+
_: 2
|
|
317
|
+
}, 1032, ["onClick"]),
|
|
318
|
+
createVNode(_component_el_icon, {
|
|
319
|
+
size: "14",
|
|
320
|
+
style: { "margin-left": "2px", "cursor": "pointer" },
|
|
321
|
+
onClick: ($event) => moveToBottom(scope.row)
|
|
322
|
+
}, {
|
|
323
|
+
default: withCtx(() => [
|
|
324
|
+
createVNode(unref(Bottom))
|
|
325
|
+
]),
|
|
326
|
+
_: 2
|
|
327
|
+
}, 1032, ["onClick"])
|
|
328
|
+
]),
|
|
329
|
+
_: 1
|
|
330
|
+
}),
|
|
331
|
+
createVNode(_component_el_table_column, {
|
|
332
|
+
width: "40",
|
|
333
|
+
align: "center"
|
|
334
|
+
}, {
|
|
335
|
+
header: withCtx((scope) => [
|
|
336
|
+
createVNode(_component_el_icon, {
|
|
337
|
+
size: "14",
|
|
338
|
+
style: { "margin-left": "2px", "cursor": "pointer" },
|
|
339
|
+
onClick: removeAll
|
|
340
|
+
}, {
|
|
341
|
+
default: withCtx(() => [
|
|
342
|
+
createVNode(unref(Delete))
|
|
343
|
+
]),
|
|
344
|
+
_: 1
|
|
345
|
+
})
|
|
346
|
+
]),
|
|
347
|
+
default: withCtx((scope) => [
|
|
348
|
+
createVNode(_component_el_icon, {
|
|
349
|
+
size: "14",
|
|
350
|
+
style: { "cursor": "pointer" },
|
|
351
|
+
onClick: ($event) => add(scope.row)
|
|
352
|
+
}, {
|
|
353
|
+
default: withCtx(() => [
|
|
354
|
+
createVNode(unref(Plus))
|
|
355
|
+
]),
|
|
356
|
+
_: 2
|
|
357
|
+
}, 1032, ["onClick"]),
|
|
358
|
+
createVNode(_component_el_icon, {
|
|
359
|
+
size: "14",
|
|
360
|
+
style: { "margin-left": "2px", "cursor": "pointer" },
|
|
361
|
+
onClick: ($event) => remove(scope.row)
|
|
362
|
+
}, {
|
|
363
|
+
default: withCtx(() => [
|
|
364
|
+
createVNode(unref(Delete))
|
|
365
|
+
]),
|
|
366
|
+
_: 2
|
|
367
|
+
}, 1032, ["onClick"])
|
|
368
|
+
]),
|
|
369
|
+
_: 1
|
|
370
|
+
}),
|
|
371
|
+
createVNode(_component_el_table_column, {
|
|
372
|
+
prop: "fieldName",
|
|
373
|
+
label: "字段",
|
|
374
|
+
width: "140"
|
|
375
|
+
}, {
|
|
376
|
+
default: withCtx((scope) => [
|
|
377
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_1, toDisplayString(scope.row.fieldName), 1)) : (openBlock(), createBlock(_component_el_select, {
|
|
378
|
+
key: 1,
|
|
379
|
+
size: "small",
|
|
380
|
+
modelValue: scope.row.fieldName,
|
|
381
|
+
"onUpdate:modelValue": ($event) => scope.row.fieldName = $event,
|
|
382
|
+
clearable: "",
|
|
383
|
+
filterable: "",
|
|
384
|
+
placeholder: "请选择",
|
|
385
|
+
onChange: ($event) => fieldChange(scope.row)
|
|
386
|
+
}, {
|
|
387
|
+
default: withCtx(() => [
|
|
388
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.model.modelFields, (f) => {
|
|
389
|
+
return openBlock(), createBlock(_component_el_option, {
|
|
390
|
+
label: f.alias + "(" + f.dbColumnName + ")",
|
|
391
|
+
value: f.dbColumnName
|
|
392
|
+
}, null, 8, ["label", "value"]);
|
|
393
|
+
}), 256))
|
|
394
|
+
]),
|
|
395
|
+
_: 2
|
|
396
|
+
}, 1032, ["modelValue", "onUpdate:modelValue", "onChange"]))
|
|
397
|
+
]),
|
|
398
|
+
_: 1
|
|
399
|
+
}),
|
|
400
|
+
createVNode(_component_el_table_column, {
|
|
401
|
+
prop: "title",
|
|
402
|
+
label: "标题",
|
|
403
|
+
width: "140"
|
|
404
|
+
}, {
|
|
405
|
+
default: withCtx((scope) => [
|
|
406
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_2, toDisplayString(scope.row.title), 1)) : (openBlock(), createBlock(_component_el_input, {
|
|
407
|
+
key: 1,
|
|
408
|
+
size: "small",
|
|
409
|
+
modelValue: scope.row.title,
|
|
410
|
+
"onUpdate:modelValue": ($event) => scope.row.title = $event,
|
|
411
|
+
clearable: "",
|
|
412
|
+
placeholder: "请输入"
|
|
413
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue"]))
|
|
414
|
+
]),
|
|
415
|
+
_: 1
|
|
416
|
+
}),
|
|
417
|
+
createVNode(_component_el_table_column, {
|
|
418
|
+
prop: "componentName",
|
|
419
|
+
width: "120"
|
|
420
|
+
}, {
|
|
421
|
+
header: withCtx(() => [
|
|
422
|
+
createElementVNode("div", _hoisted_3, [
|
|
423
|
+
createTextVNode(" 组件 "),
|
|
424
|
+
withDirectives(createVNode(_component_el_checkbox, {
|
|
425
|
+
modelValue: allEditState.value,
|
|
426
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => allEditState.value = $event),
|
|
427
|
+
value: "1",
|
|
428
|
+
label: "全部可编辑",
|
|
429
|
+
size: "small",
|
|
430
|
+
style: { "margin-left": "6px" },
|
|
431
|
+
onChange: updateEditState
|
|
432
|
+
}, null, 8, ["modelValue"]), [
|
|
433
|
+
[vShow, __props.model.pageType == "list"]
|
|
434
|
+
])
|
|
435
|
+
])
|
|
436
|
+
]),
|
|
437
|
+
default: withCtx((scope) => [
|
|
438
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_4, toDisplayString(scope.row.componentName), 1)) : (openBlock(), createBlock(_component_el_select, {
|
|
439
|
+
key: 1,
|
|
440
|
+
size: "small",
|
|
441
|
+
modelValue: scope.row.componentName,
|
|
442
|
+
"onUpdate:modelValue": ($event) => scope.row.componentName = $event,
|
|
443
|
+
clearable: "",
|
|
444
|
+
filterable: "",
|
|
445
|
+
placeholder: "请选择"
|
|
446
|
+
}, {
|
|
447
|
+
default: withCtx(() => [
|
|
448
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(formComponents), (o) => {
|
|
449
|
+
return openBlock(), createBlock(_component_el_option, {
|
|
450
|
+
label: o.label,
|
|
451
|
+
value: o.name
|
|
452
|
+
}, null, 8, ["label", "value"]);
|
|
453
|
+
}), 256))
|
|
454
|
+
]),
|
|
455
|
+
_: 2
|
|
456
|
+
}, 1032, ["modelValue", "onUpdate:modelValue"]))
|
|
457
|
+
]),
|
|
458
|
+
_: 1
|
|
459
|
+
}),
|
|
460
|
+
createVNode(_component_el_table_column, {
|
|
461
|
+
prop: "state",
|
|
462
|
+
label: "状态",
|
|
463
|
+
width: "70"
|
|
464
|
+
}, {
|
|
465
|
+
default: withCtx((scope) => [
|
|
466
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_5, toDisplayString(scope.row.state), 1)) : (openBlock(), createBlock(_component_el_select, {
|
|
467
|
+
key: 1,
|
|
468
|
+
size: "small",
|
|
469
|
+
disabled: !scope.row.componentName,
|
|
470
|
+
modelValue: scope.row.state,
|
|
471
|
+
"onUpdate:modelValue": ($event) => scope.row.state = $event,
|
|
472
|
+
clearable: "",
|
|
473
|
+
filterable: "",
|
|
474
|
+
placeholder: "默认"
|
|
475
|
+
}, {
|
|
476
|
+
default: withCtx(() => [
|
|
477
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(stateOptions.value, (o) => {
|
|
478
|
+
return openBlock(), createBlock(_component_el_option, {
|
|
479
|
+
value: o.value,
|
|
480
|
+
label: o.label
|
|
481
|
+
}, null, 8, ["value", "label"]);
|
|
482
|
+
}), 256))
|
|
483
|
+
]),
|
|
484
|
+
_: 2
|
|
485
|
+
}, 1032, ["disabled", "modelValue", "onUpdate:modelValue"]))
|
|
486
|
+
]),
|
|
487
|
+
_: 1
|
|
488
|
+
}),
|
|
489
|
+
createVNode(_component_el_table_column, {
|
|
490
|
+
prop: "valid",
|
|
491
|
+
label: "校验",
|
|
492
|
+
width: "120"
|
|
493
|
+
}, {
|
|
494
|
+
default: withCtx((scope) => [
|
|
495
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", {
|
|
496
|
+
key: 0,
|
|
497
|
+
title: scope.row.valid
|
|
498
|
+
}, toDisplayString(scope.row.valid), 9, _hoisted_6)) : (openBlock(), createBlock(_component_el_select, {
|
|
499
|
+
key: 1,
|
|
500
|
+
disabled: !scope.row.componentName,
|
|
501
|
+
size: "small",
|
|
502
|
+
modelValue: scope.row.valid,
|
|
503
|
+
"onUpdate:modelValue": ($event) => scope.row.valid = $event,
|
|
504
|
+
clearable: "",
|
|
505
|
+
placeholder: "无校验",
|
|
506
|
+
multiple: "",
|
|
507
|
+
"collapse-tags": "",
|
|
508
|
+
"collapse-tags-tooltip": ""
|
|
509
|
+
}, {
|
|
510
|
+
default: withCtx(() => [
|
|
511
|
+
(openBlock(), createElementBlock(Fragment, null, renderList(validOptions, (field, index) => {
|
|
512
|
+
return createVNode(_component_el_option, {
|
|
513
|
+
label: field.label,
|
|
514
|
+
value: field.value
|
|
515
|
+
}, null, 8, ["label", "value"]);
|
|
516
|
+
}), 64))
|
|
517
|
+
]),
|
|
518
|
+
_: 2
|
|
519
|
+
}, 1032, ["disabled", "modelValue", "onUpdate:modelValue"]))
|
|
520
|
+
]),
|
|
521
|
+
_: 1
|
|
522
|
+
}),
|
|
523
|
+
__props.model.pageType == "form" ? (openBlock(), createBlock(_component_el_table_column, {
|
|
524
|
+
key: 0,
|
|
525
|
+
prop: "width",
|
|
526
|
+
label: "宽度(栏数)",
|
|
527
|
+
width: "75"
|
|
528
|
+
}, {
|
|
529
|
+
default: withCtx((scope) => [
|
|
530
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_7, toDisplayString(scope.row.width), 1)) : (openBlock(), createBlock(_component_el_select, {
|
|
531
|
+
key: 1,
|
|
532
|
+
size: "small",
|
|
533
|
+
modelValue: scope.row.width,
|
|
534
|
+
"onUpdate:modelValue": ($event) => scope.row.width = $event,
|
|
535
|
+
clearable: "",
|
|
536
|
+
placeholder: "请选择"
|
|
537
|
+
}, {
|
|
538
|
+
default: withCtx(() => [
|
|
539
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(widthOptions.value, (o) => {
|
|
540
|
+
return openBlock(), createBlock(_component_el_option, {
|
|
541
|
+
value: o.value,
|
|
542
|
+
label: o.label
|
|
543
|
+
}, null, 8, ["value", "label"]);
|
|
544
|
+
}), 256))
|
|
545
|
+
]),
|
|
546
|
+
_: 2
|
|
547
|
+
}, 1032, ["modelValue", "onUpdate:modelValue"]))
|
|
548
|
+
]),
|
|
549
|
+
_: 1
|
|
550
|
+
})) : createCommentVNode("", true),
|
|
551
|
+
__props.model.pageType == "list" ? (openBlock(), createBlock(_component_el_table_column, {
|
|
552
|
+
key: 1,
|
|
553
|
+
prop: "align",
|
|
554
|
+
label: "左右对齐",
|
|
555
|
+
width: "70"
|
|
556
|
+
}, {
|
|
557
|
+
default: withCtx((scope) => [
|
|
558
|
+
scope.row.uuid != selRowUuid.value ? (openBlock(), createElementBlock("label", _hoisted_8, toDisplayString(scope.row.align), 1)) : (openBlock(), createBlock(_component_el_select, {
|
|
559
|
+
key: 1,
|
|
560
|
+
size: "small",
|
|
561
|
+
modelValue: scope.row.align,
|
|
562
|
+
"onUpdate:modelValue": ($event) => scope.row.align = $event,
|
|
563
|
+
clearable: "",
|
|
564
|
+
placeholder: "请选择"
|
|
565
|
+
}, {
|
|
566
|
+
default: withCtx(() => [
|
|
567
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(alignOptions.value, (o) => {
|
|
568
|
+
return openBlock(), createBlock(_component_el_option, {
|
|
569
|
+
value: o.value,
|
|
570
|
+
label: o.label
|
|
571
|
+
}, null, 8, ["value", "label"]);
|
|
572
|
+
}), 256))
|
|
573
|
+
]),
|
|
574
|
+
_: 2
|
|
575
|
+
}, 1032, ["modelValue", "onUpdate:modelValue"]))
|
|
576
|
+
]),
|
|
577
|
+
_: 1
|
|
578
|
+
})) : createCommentVNode("", true),
|
|
579
|
+
createVNode(_component_el_table_column, {
|
|
580
|
+
prop: "value",
|
|
581
|
+
label: "默认值",
|
|
582
|
+
width: "120"
|
|
583
|
+
}, {
|
|
584
|
+
default: withCtx((scope) => [
|
|
585
|
+
createVNode(BindVariable, {
|
|
586
|
+
showLabel: scope.row.uuid != selRowUuid.value || !scope.row.componentName,
|
|
587
|
+
modelValue: scope.row.value,
|
|
588
|
+
paramTypes: ["request", "context", "page", "fixed"],
|
|
589
|
+
"onUpdate:modelValue": (val) => updatePropValue(val, scope.row)
|
|
590
|
+
}, null, 8, ["showLabel", "modelValue", "onUpdate:modelValue"])
|
|
591
|
+
]),
|
|
592
|
+
_: 1
|
|
593
|
+
})
|
|
594
|
+
]),
|
|
595
|
+
_: 1
|
|
596
|
+
}, 8, ["data"]);
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
});
|
|
600
|
+
export {
|
|
601
|
+
_sfc_main as default
|
|
602
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _sfc_main from "./page-switch.vue2.js";
|
|
2
2
|
import "./page-switch.vue3.js";
|
|
3
3
|
import _export_sfc from "../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const PageSwitch = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
4
|
+
const PageSwitch = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-ecd3e513"]]);
|
|
5
5
|
export {
|
|
6
6
|
PageSwitch as default
|
|
7
7
|
};
|
|
@@ -54,13 +54,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
54
54
|
}
|
|
55
55
|
async function loadNodes(parent, resolve) {
|
|
56
56
|
if (systemId.value === -1) {
|
|
57
|
-
await http.get("/mms/systems/getByCode/" + props.pageDesign.systemCode).then((res) => {
|
|
57
|
+
await http.get(window["$vueApp"].config.globalProperties.baseAPI + "/mms/systems/getByCode/" + props.pageDesign.systemCode).then((res) => {
|
|
58
58
|
if (res) {
|
|
59
59
|
systemId.value = res.id;
|
|
60
60
|
}
|
|
61
61
|
});
|
|
62
62
|
}
|
|
63
|
-
let url = "/mms/menu-trees?isShowNoNode=false&isShowSystemNode=false&";
|
|
63
|
+
let url = window["$vueApp"].config.globalProperties.baseAPI + "/mms/menu-trees?isShowNoNode=false&isShowSystemNode=false&";
|
|
64
64
|
if (parent.level === 0) {
|
|
65
65
|
url += "systemId=system-" + systemId.value;
|
|
66
66
|
} else {
|
|
@@ -18,12 +18,16 @@ declare const _default: import('vue').DefineComponent<__VLS_TypePropsToRuntimePr
|
|
|
18
18
|
changeSelectStandardEvent: (...args: any[]) => void;
|
|
19
19
|
addEvent: (...args: any[]) => void;
|
|
20
20
|
onCustomAttrWidget: (...args: any[]) => void;
|
|
21
|
+
revocation: (...args: any[]) => void;
|
|
22
|
+
regain: (...args: any[]) => void;
|
|
21
23
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<MyProps>>> & {
|
|
22
24
|
onOnSelectWidget?: (...args: any[]) => any;
|
|
23
25
|
onAddEvent?: (...args: any[]) => any;
|
|
24
26
|
onOnCustomAttrWidget?: (...args: any[]) => any;
|
|
25
27
|
onChangeSelectEvent?: (...args: any[]) => any;
|
|
26
28
|
onChangeSelectStandardEvent?: (...args: any[]) => any;
|
|
29
|
+
onRevocation?: (...args: any[]) => any;
|
|
30
|
+
onRegain?: (...args: any[]) => any;
|
|
27
31
|
}, {}, {}>;
|
|
28
32
|
export default _default;
|
|
29
33
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|