@fecp/designer 5.6.16 → 5.6.18
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.
|
@@ -7,18 +7,18 @@ import "../../../node_modules/element-plus/es/index.mjs";
|
|
|
7
7
|
/* empty css */
|
|
8
8
|
/* empty css */
|
|
9
9
|
import "../../../node_modules/element-plus/theme-chalk/el-config-provider.css.mjs";
|
|
10
|
-
import { getCurrentInstance, ref, computed,
|
|
10
|
+
import { getCurrentInstance, ref, computed, createBlock, openBlock, unref, withCtx, createElementBlock, createCommentVNode, createVNode, resolveDynamicComponent } from "vue";
|
|
11
11
|
import zh_cn_default from "../../../node_modules/element-plus/es/locale/lang/zh-cn.mjs";
|
|
12
12
|
import LayoutAside from "./aside/index.vue.mjs";
|
|
13
13
|
import _sfc_main$1 from "./header/index.vue.mjs";
|
|
14
14
|
import LayoutProperty from "./property/index.vue.mjs";
|
|
15
15
|
import tableWorkArea from "../packages/table/index.vue.mjs";
|
|
16
16
|
import formWorkArea from "../packages/form/index.vue.mjs";
|
|
17
|
-
import
|
|
17
|
+
import store from "../store/index.mjs";
|
|
18
|
+
import { setEditConfigData, setSelectedItem, setHoverItem } from "../packages/utils/common.mjs";
|
|
18
19
|
import api from "../api/index.mjs";
|
|
19
20
|
import { defaultTableConfig } from "../packages/table/default.mjs";
|
|
20
21
|
import { defaultFormConfig } from "../packages/form/default.mjs";
|
|
21
|
-
import { useStore } from "../../../node_modules/vuex/dist/vuex.esm-bundler.mjs";
|
|
22
22
|
/* empty css */
|
|
23
23
|
import _export_sfc from "../../../_virtual/_plugin-vue_export-helper.mjs";
|
|
24
24
|
import { ElConfigProvider } from "../../../node_modules/element-plus/es/components/config-provider/index.mjs";
|
|
@@ -31,48 +31,45 @@ const _hoisted_1 = {
|
|
|
31
31
|
const _sfc_main = {
|
|
32
32
|
__name: "index",
|
|
33
33
|
setup(__props) {
|
|
34
|
-
const store = useStore();
|
|
35
34
|
const currentInstance = getCurrentInstance();
|
|
36
35
|
const ctx = currentInstance.proxy;
|
|
37
36
|
const pkId = getUrlParam("pkId");
|
|
38
37
|
const isInitd = ref(0);
|
|
39
38
|
const compRef = ref(null);
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
})
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
store.commit("set_editing_type", data.type);
|
|
75
|
-
}
|
|
39
|
+
if (!pkId) {
|
|
40
|
+
isInitd.value = -1;
|
|
41
|
+
} else {
|
|
42
|
+
api.login4dev(ctx.$http).then((data) => {
|
|
43
|
+
store.commit("set_token", data.token);
|
|
44
|
+
store.commit("set_refreshToken", data.refreshToken);
|
|
45
|
+
api.getById(ctx.$http, pkId).then((data2) => {
|
|
46
|
+
const templateName = data2.templateName;
|
|
47
|
+
const templateKey = data2.templateKey;
|
|
48
|
+
document.title = templateName || "表单设计器";
|
|
49
|
+
if (data2.type == "table") {
|
|
50
|
+
const tableOptions = ref({
|
|
51
|
+
pkId,
|
|
52
|
+
templateName,
|
|
53
|
+
templateKey,
|
|
54
|
+
...defaultTableConfig,
|
|
55
|
+
...JSON.parse(data2.context)
|
|
56
|
+
});
|
|
57
|
+
setEditConfigData(tableOptions.value);
|
|
58
|
+
isInitd.value = 1;
|
|
59
|
+
} else if (data2.type == "form") {
|
|
60
|
+
const formOptions = ref({
|
|
61
|
+
pkId,
|
|
62
|
+
templateName,
|
|
63
|
+
templateKey,
|
|
64
|
+
...defaultFormConfig,
|
|
65
|
+
...JSON.parse(data2.context)
|
|
66
|
+
});
|
|
67
|
+
setEditConfigData(formOptions.value);
|
|
68
|
+
isInitd.value = 1;
|
|
69
|
+
}
|
|
70
|
+
store.commit("set_editing_type", data2.type);
|
|
71
|
+
});
|
|
72
|
+
});
|
|
76
73
|
}
|
|
77
74
|
const editingArea = computed(() => {
|
|
78
75
|
switch (store.getters.editingType) {
|
|
@@ -98,9 +95,6 @@ const _sfc_main = {
|
|
|
98
95
|
if (values.length === 0) return null;
|
|
99
96
|
return values.length === 1 ? values[0] : values;
|
|
100
97
|
}
|
|
101
|
-
onMounted(() => {
|
|
102
|
-
init();
|
|
103
|
-
});
|
|
104
98
|
return (_ctx, _cache) => {
|
|
105
99
|
const _component_el_config_provider = ElConfigProvider;
|
|
106
100
|
const _component_el_main = ElMain;
|
|
@@ -150,7 +144,7 @@ const _sfc_main = {
|
|
|
150
144
|
};
|
|
151
145
|
}
|
|
152
146
|
};
|
|
153
|
-
const layout = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
147
|
+
const layout = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-ae1b4337"]]);
|
|
154
148
|
export {
|
|
155
149
|
layout as default
|
|
156
150
|
};
|
package/es/designer.css
CHANGED
|
@@ -5344,7 +5344,7 @@ to {
|
|
|
5344
5344
|
padding: 0 10px;
|
|
5345
5345
|
border-radius: 4px;
|
|
5346
5346
|
font-size: 13px;
|
|
5347
|
-
}.init-error-container[data-v-
|
|
5347
|
+
}.init-error-container[data-v-ae1b4337] {
|
|
5348
5348
|
width: 100%;
|
|
5349
5349
|
height: 100vh;
|
|
5350
5350
|
display: flex;
|
|
@@ -5352,39 +5352,39 @@ to {
|
|
|
5352
5352
|
justify-content: center;
|
|
5353
5353
|
background-color: #f5f7fa;
|
|
5354
5354
|
}
|
|
5355
|
-
.inner-container[data-v-
|
|
5355
|
+
.inner-container[data-v-ae1b4337] {
|
|
5356
5356
|
height: 0px;
|
|
5357
5357
|
z-index: 1;
|
|
5358
5358
|
background-color: #f7f8fa;
|
|
5359
5359
|
}
|
|
5360
|
-
.inner-container[data-v-
|
|
5360
|
+
.inner-container[data-v-ae1b4337] .el-collapse {
|
|
5361
5361
|
border-bottom: none;
|
|
5362
5362
|
}
|
|
5363
|
-
.inner-container[data-v-
|
|
5363
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header {
|
|
5364
5364
|
height: 45px;
|
|
5365
5365
|
background: rgb(242, 242, 242);
|
|
5366
5366
|
color: #1a1a1a;
|
|
5367
5367
|
padding-left: 40px;
|
|
5368
5368
|
position: relative;
|
|
5369
5369
|
}
|
|
5370
|
-
.inner-container[data-v-
|
|
5370
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header .el-collapse-item__arrow {
|
|
5371
5371
|
position: absolute;
|
|
5372
5372
|
left: 14px;
|
|
5373
5373
|
font-size: 12px;
|
|
5374
5374
|
}
|
|
5375
|
-
.inner-container[data-v-
|
|
5375
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header .el-collapse-item__title {
|
|
5376
5376
|
font-size: 14px;
|
|
5377
5377
|
font-weight: 600;
|
|
5378
5378
|
}
|
|
5379
|
-
.inner-container[data-v-
|
|
5379
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__wrap {
|
|
5380
5380
|
border: none;
|
|
5381
5381
|
}
|
|
5382
|
-
.root-main[data-v-
|
|
5382
|
+
.root-main[data-v-ae1b4337] {
|
|
5383
5383
|
padding: 0;
|
|
5384
5384
|
margin: 0 20px;
|
|
5385
5385
|
background-color: #fff;
|
|
5386
5386
|
}
|
|
5387
|
-
.fec-designer-container[data-v-
|
|
5387
|
+
.fec-designer-container[data-v-ae1b4337] {
|
|
5388
5388
|
flex-direction: column;
|
|
5389
5389
|
height: 100%;
|
|
5390
5390
|
}/* 弹层样式 */
|
|
@@ -11,21 +11,21 @@ require("../../../node_modules/element-plus/es/index.js");
|
|
|
11
11
|
require("../../../node_modules/element-plus/theme-chalk/el-config-provider.css.js");
|
|
12
12
|
const Vue = require("vue");
|
|
13
13
|
const zhCn = require("../../../node_modules/element-plus/es/locale/lang/zh-cn.js");
|
|
14
|
-
const index$
|
|
15
|
-
const index$
|
|
16
|
-
const index$
|
|
17
|
-
const index$
|
|
18
|
-
const index = ;/* empty css */
|
|
14
|
+
const index$7 = ;/* empty css */
|
|
15
|
+
const index$6 = ;/* empty css */
|
|
16
|
+
const index$8 = ;/* empty css */
|
|
17
|
+
const index$3 = ;/* empty css */
|
|
18
|
+
const index$2 = ;/* empty css */
|
|
19
|
+
const index$1 = require("../store/index.js");
|
|
19
20
|
const common = require("../packages/utils/common.js");
|
|
20
|
-
const index
|
|
21
|
+
const index = require("../api/index.js");
|
|
21
22
|
const _default = require("../packages/table/default.js");
|
|
22
23
|
const _default$1 = require("../packages/form/default.js");
|
|
23
|
-
const vuex_esmBundler = require("../../../node_modules/vuex/dist/vuex.esm-bundler.js");
|
|
24
24
|
;/* empty css */
|
|
25
25
|
const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
|
|
26
|
-
const index$
|
|
27
|
-
const index$
|
|
28
|
-
const index$
|
|
26
|
+
const index$4 = require("../../../node_modules/element-plus/es/components/config-provider/index.js");
|
|
27
|
+
const index$5 = require("../../../node_modules/element-plus/es/components/container/index.js");
|
|
28
|
+
const index$9 = require("../../../node_modules/element-plus/es/components/result/index.js");
|
|
29
29
|
const _hoisted_1 = {
|
|
30
30
|
key: 1,
|
|
31
31
|
class: "init-error-container"
|
|
@@ -33,55 +33,52 @@ const _hoisted_1 = {
|
|
|
33
33
|
const _sfc_main = {
|
|
34
34
|
__name: "index",
|
|
35
35
|
setup(__props) {
|
|
36
|
-
const store = vuex_esmBundler.useStore();
|
|
37
36
|
const currentInstance = Vue.getCurrentInstance();
|
|
38
37
|
const ctx = currentInstance.proxy;
|
|
39
38
|
const pkId = getUrlParam("pkId");
|
|
40
39
|
const isInitd = Vue.ref(0);
|
|
41
40
|
const compRef = Vue.ref(null);
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
})
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
store.commit("set_editing_type", data.type);
|
|
77
|
-
}
|
|
41
|
+
if (!pkId) {
|
|
42
|
+
isInitd.value = -1;
|
|
43
|
+
} else {
|
|
44
|
+
index.default.login4dev(ctx.$http).then((data) => {
|
|
45
|
+
index$1.default.commit("set_token", data.token);
|
|
46
|
+
index$1.default.commit("set_refreshToken", data.refreshToken);
|
|
47
|
+
index.default.getById(ctx.$http, pkId).then((data2) => {
|
|
48
|
+
const templateName = data2.templateName;
|
|
49
|
+
const templateKey = data2.templateKey;
|
|
50
|
+
document.title = templateName || "表单设计器";
|
|
51
|
+
if (data2.type == "table") {
|
|
52
|
+
const tableOptions = Vue.ref({
|
|
53
|
+
pkId,
|
|
54
|
+
templateName,
|
|
55
|
+
templateKey,
|
|
56
|
+
..._default.defaultTableConfig,
|
|
57
|
+
...JSON.parse(data2.context)
|
|
58
|
+
});
|
|
59
|
+
common.setEditConfigData(tableOptions.value);
|
|
60
|
+
isInitd.value = 1;
|
|
61
|
+
} else if (data2.type == "form") {
|
|
62
|
+
const formOptions = Vue.ref({
|
|
63
|
+
pkId,
|
|
64
|
+
templateName,
|
|
65
|
+
templateKey,
|
|
66
|
+
..._default$1.defaultFormConfig,
|
|
67
|
+
...JSON.parse(data2.context)
|
|
68
|
+
});
|
|
69
|
+
common.setEditConfigData(formOptions.value);
|
|
70
|
+
isInitd.value = 1;
|
|
71
|
+
}
|
|
72
|
+
index$1.default.commit("set_editing_type", data2.type);
|
|
73
|
+
});
|
|
74
|
+
});
|
|
78
75
|
}
|
|
79
76
|
const editingArea = Vue.computed(() => {
|
|
80
|
-
switch (
|
|
77
|
+
switch (index$1.default.getters.editingType) {
|
|
81
78
|
case "table":
|
|
82
|
-
return index$
|
|
79
|
+
return index$3.default;
|
|
83
80
|
case "form":
|
|
84
|
-
return index.default;
|
|
81
|
+
return index$2.default;
|
|
85
82
|
}
|
|
86
83
|
return null;
|
|
87
84
|
});
|
|
@@ -100,14 +97,11 @@ const _sfc_main = {
|
|
|
100
97
|
if (values.length === 0) return null;
|
|
101
98
|
return values.length === 1 ? values[0] : values;
|
|
102
99
|
}
|
|
103
|
-
Vue.onMounted(() => {
|
|
104
|
-
init();
|
|
105
|
-
});
|
|
106
100
|
return (_ctx, _cache) => {
|
|
107
|
-
const _component_el_config_provider = index$
|
|
108
|
-
const _component_el_main = index$
|
|
109
|
-
const _component_el_container = index$
|
|
110
|
-
const _component_el_result = index$
|
|
101
|
+
const _component_el_config_provider = index$4.ElConfigProvider;
|
|
102
|
+
const _component_el_main = index$5.ElMain;
|
|
103
|
+
const _component_el_container = index$5.ElContainer;
|
|
104
|
+
const _component_el_result = index$9.ElResult;
|
|
111
105
|
return Vue.openBlock(), Vue.createBlock(_component_el_config_provider, { locale: Vue.unref(zhCn.default) }, {
|
|
112
106
|
default: Vue.withCtx(() => [
|
|
113
107
|
isInitd.value == 1 ? (Vue.openBlock(), Vue.createBlock(_component_el_container, {
|
|
@@ -115,10 +109,10 @@ const _sfc_main = {
|
|
|
115
109
|
class: "fec-designer-container"
|
|
116
110
|
}, {
|
|
117
111
|
default: Vue.withCtx(() => [
|
|
118
|
-
Vue.createVNode(Vue.unref(index$
|
|
112
|
+
Vue.createVNode(Vue.unref(index$6.default)),
|
|
119
113
|
Vue.createVNode(_component_el_container, { class: "inner-container" }, {
|
|
120
114
|
default: Vue.withCtx(() => [
|
|
121
|
-
Vue.createVNode(Vue.unref(index$
|
|
115
|
+
Vue.createVNode(Vue.unref(index$7.default), { onOnFormDragMove: onFormDragMove }),
|
|
122
116
|
Vue.createVNode(_component_el_main, { class: "root-main" }, {
|
|
123
117
|
default: Vue.withCtx(() => [
|
|
124
118
|
Vue.createVNode(_component_el_config_provider, { locale: Vue.unref(zhCn.default) }, {
|
|
@@ -133,7 +127,7 @@ const _sfc_main = {
|
|
|
133
127
|
]),
|
|
134
128
|
_: 1
|
|
135
129
|
}),
|
|
136
|
-
Vue.createVNode(Vue.unref(index$
|
|
130
|
+
Vue.createVNode(Vue.unref(index$8.default))
|
|
137
131
|
]),
|
|
138
132
|
_: 1
|
|
139
133
|
})
|
|
@@ -152,5 +146,5 @@ const _sfc_main = {
|
|
|
152
146
|
};
|
|
153
147
|
}
|
|
154
148
|
};
|
|
155
|
-
const layout = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
149
|
+
const layout = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-ae1b4337"]]);
|
|
156
150
|
exports.default = layout;
|
package/lib/designer.css
CHANGED
|
@@ -5344,7 +5344,7 @@ to {
|
|
|
5344
5344
|
padding: 0 10px;
|
|
5345
5345
|
border-radius: 4px;
|
|
5346
5346
|
font-size: 13px;
|
|
5347
|
-
}.init-error-container[data-v-
|
|
5347
|
+
}.init-error-container[data-v-ae1b4337] {
|
|
5348
5348
|
width: 100%;
|
|
5349
5349
|
height: 100vh;
|
|
5350
5350
|
display: flex;
|
|
@@ -5352,39 +5352,39 @@ to {
|
|
|
5352
5352
|
justify-content: center;
|
|
5353
5353
|
background-color: #f5f7fa;
|
|
5354
5354
|
}
|
|
5355
|
-
.inner-container[data-v-
|
|
5355
|
+
.inner-container[data-v-ae1b4337] {
|
|
5356
5356
|
height: 0px;
|
|
5357
5357
|
z-index: 1;
|
|
5358
5358
|
background-color: #f7f8fa;
|
|
5359
5359
|
}
|
|
5360
|
-
.inner-container[data-v-
|
|
5360
|
+
.inner-container[data-v-ae1b4337] .el-collapse {
|
|
5361
5361
|
border-bottom: none;
|
|
5362
5362
|
}
|
|
5363
|
-
.inner-container[data-v-
|
|
5363
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header {
|
|
5364
5364
|
height: 45px;
|
|
5365
5365
|
background: rgb(242, 242, 242);
|
|
5366
5366
|
color: #1a1a1a;
|
|
5367
5367
|
padding-left: 40px;
|
|
5368
5368
|
position: relative;
|
|
5369
5369
|
}
|
|
5370
|
-
.inner-container[data-v-
|
|
5370
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header .el-collapse-item__arrow {
|
|
5371
5371
|
position: absolute;
|
|
5372
5372
|
left: 14px;
|
|
5373
5373
|
font-size: 12px;
|
|
5374
5374
|
}
|
|
5375
|
-
.inner-container[data-v-
|
|
5375
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__header .el-collapse-item__title {
|
|
5376
5376
|
font-size: 14px;
|
|
5377
5377
|
font-weight: 600;
|
|
5378
5378
|
}
|
|
5379
|
-
.inner-container[data-v-
|
|
5379
|
+
.inner-container[data-v-ae1b4337] .el-collapse .el-collapse-item__wrap {
|
|
5380
5380
|
border: none;
|
|
5381
5381
|
}
|
|
5382
|
-
.root-main[data-v-
|
|
5382
|
+
.root-main[data-v-ae1b4337] {
|
|
5383
5383
|
padding: 0;
|
|
5384
5384
|
margin: 0 20px;
|
|
5385
5385
|
background-color: #fff;
|
|
5386
5386
|
}
|
|
5387
|
-
.fec-designer-container[data-v-
|
|
5387
|
+
.fec-designer-container[data-v-ae1b4337] {
|
|
5388
5388
|
flex-direction: column;
|
|
5389
5389
|
height: 100%;
|
|
5390
5390
|
}/* 弹层样式 */
|