fec-dev-designer 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,92 +7,92 @@ import "../../node_modules/element-plus/theme-chalk/el-footer.css.js";
7
7
  import "../../node_modules/element-plus/theme-chalk/el-header.css.js";
8
8
  import "../../node_modules/element-plus/theme-chalk/el-main.css.js";
9
9
  import "../../node_modules/element-plus/theme-chalk/el-config-provider.css.js";
10
- import { ref as m, computed as w, openBlock as u, createBlock as d, withCtx as r, createVNode as o, unref as p, resolveDynamicComponent as D, createElementBlock as E, createTextVNode as N, createCommentVNode as B } from "vue";
11
- import { useStore as T } from "vuex";
10
+ import { ref as s, computed as b, openBlock as f, createBlock as _, withCtx as r, createVNode as o, unref as a, resolveDynamicComponent as w, createElementBlock as D, createTextVNode as E, createCommentVNode as N } from "vue";
11
+ import { useStore as B } from "vuex";
12
12
  import { useRoute as O, useRouter as R } from "vue-router";
13
- import A from "./aside/index.vue.js";
14
- import F from "./header/index.vue.js";
15
- import M from "./property/index.vue.js";
16
- import S from "../packages/table/index.vue.js";
17
- import V from "../packages/form/index.vue.js";
18
- import J from "../../node_modules/element-plus/dist/locale/zh-cn.js";
19
- import { setEditConfigData as v, setSelectedItem as K, setHoverItem as L } from "../packages/utils/common.js";
13
+ import T from "./aside/index.vue.js";
14
+ import A from "./header/index.vue.js";
15
+ import F from "./property/index.vue.js";
16
+ import M from "../packages/table/index.vue.js";
17
+ import S from "../packages/form/index.vue.js";
18
+ import V from "../../node_modules/element-plus/dist/locale/zh-cn.js";
19
+ import { setEditConfigData as d, setSelectedItem as J, setHoverItem as K } from "../packages/utils/common.js";
20
20
  import y from "../api/index.js";
21
- import { defaultTableConfig as P } from "../packages/table/default.js";
22
- import { defaultFormConfig as W } from "../packages/form/default.js";
21
+ import { defaultTableConfig as L } from "../packages/table/default.js";
22
+ import { defaultFormConfig as P } from "../packages/form/default.js";
23
23
  import "./index.vue2.js";
24
- import q from "../../_virtual/_plugin-vue_export-helper.js";
25
- import { ElConfigProvider as z } from "../../node_modules/element-plus/es/components/config-provider/index.js";
26
- import { ElMain as H, ElContainer as $ } from "../../node_modules/element-plus/es/components/container/index.js";
27
- import { ElButton as j } from "../../node_modules/element-plus/es/components/button/index.js";
28
- import { ElResult as G } from "../../node_modules/element-plus/es/components/result/index.js";
29
- const Q = {
24
+ import W from "../../_virtual/_plugin-vue_export-helper.js";
25
+ import { ElConfigProvider as q } from "../../node_modules/element-plus/es/components/config-provider/index.js";
26
+ import { ElMain as z, ElContainer as H } from "../../node_modules/element-plus/es/components/container/index.js";
27
+ import { ElButton as $ } from "../../node_modules/element-plus/es/components/button/index.js";
28
+ import { ElResult as j } from "../../node_modules/element-plus/es/components/result/index.js";
29
+ const G = {
30
30
  key: 1,
31
31
  class: "init-error-container"
32
- }, U = {
32
+ }, Q = {
33
33
  __name: "index",
34
- setup(X) {
35
- const l = T(), g = O(), k = R(), f = m("table"), c = g.query.pkId, n = m(0), _ = m(null);
36
- function h() {
37
- window.history.length > 1 ? k.back() : window.close();
34
+ setup(U) {
35
+ const m = B(), v = O(), g = R(), l = v.query.pkId, n = s(0), u = s(null);
36
+ function k() {
37
+ window.history.length > 1 ? g.back() : window.close();
38
38
  }
39
- c ? y.login4dev().then((i) => {
40
- l.commit("set_token", i.token), l.commit("set_refreshToken", i.refreshToken), y.getById(c).then((e) => {
41
- const s = e.templateName, a = e.templateKey;
42
- if (f.value = e.type, f.value === "table") {
43
- const t = m({
44
- pkId: c,
45
- templateName: s,
46
- templateKey: a,
47
- ...P,
39
+ l ? y.login4dev().then((i) => {
40
+ m.commit("set_token", i.token), m.commit("set_refreshToken", i.refreshToken), y.getById(l).then((e) => {
41
+ const c = e.templateName, p = e.templateKey;
42
+ if (e.type == "table") {
43
+ const t = s({
44
+ pkId: l,
45
+ templateName: c,
46
+ templateKey: p,
47
+ ...L,
48
48
  ...JSON.parse(e.context)
49
49
  });
50
- v(t.value), n.value = 1;
51
- } else if (f.value === "form") {
52
- const t = m({
53
- pkId: c,
54
- templateName: s,
55
- templateKey: a,
56
- ...W,
50
+ d(t.value), n.value = 1;
51
+ } else if (e.type == "form") {
52
+ const t = s({
53
+ pkId: l,
54
+ templateName: c,
55
+ templateKey: p,
56
+ ...P,
57
57
  ...JSON.parse(e.context)
58
58
  });
59
- v(t.value), n.value = 1;
59
+ d(t.value), n.value = 1;
60
60
  }
61
- l.commit("set_editing_type", e.type);
61
+ m.commit("set_editing_type", e.type);
62
62
  });
63
63
  }) : n.value = -1;
64
- const b = w(() => {
65
- switch (l.getters.editingType) {
64
+ const h = b(() => {
65
+ switch (m.getters.editingType) {
66
66
  case "table":
67
- return S;
67
+ return M;
68
68
  case "form":
69
- return V;
69
+ return S;
70
70
  }
71
71
  return null;
72
72
  });
73
- K(null), L(null);
73
+ J(null), K(null);
74
74
  function x(i) {
75
75
  var e;
76
- (e = _.value) == null || e.onFormDragMove(i);
76
+ (e = u.value) == null || e.onFormDragMove(i);
77
77
  }
78
78
  return (i, e) => {
79
- const s = z, a = H, t = $, C = j, I = G;
80
- return n.value == 1 ? (u(), d(t, {
79
+ const c = q, p = z, t = H, C = $, I = j;
80
+ return n.value == 1 ? (f(), _(t, {
81
81
  key: 0,
82
82
  style: { "flex-direction": "column", height: "100%" }
83
83
  }, {
84
84
  default: r(() => [
85
- o(p(F)),
85
+ o(a(A)),
86
86
  o(t, { class: "inner-container" }, {
87
87
  default: r(() => [
88
- o(p(A), { onOnFormDragMove: x }),
89
- o(a, { class: "root-main" }, {
88
+ o(a(T), { onOnFormDragMove: x }),
89
+ o(p, { class: "root-main" }, {
90
90
  default: r(() => [
91
- o(s, { locale: p(J) }, {
91
+ o(c, { locale: a(V) }, {
92
92
  default: r(() => [
93
- (u(), d(D(b.value), {
93
+ (f(), _(w(h.value), {
94
94
  ref_key: "compRef",
95
- ref: _
95
+ ref: u
96
96
  }, null, 512))
97
97
  ]),
98
98
  _: 1
@@ -100,13 +100,13 @@ const Q = {
100
100
  ]),
101
101
  _: 1
102
102
  }),
103
- o(p(M))
103
+ o(a(F))
104
104
  ]),
105
105
  _: 1
106
106
  })
107
107
  ]),
108
108
  _: 1
109
- })) : n.value == -1 ? (u(), E("div", Q, [
109
+ })) : n.value == -1 ? (f(), D("div", G, [
110
110
  o(I, {
111
111
  icon: "warning",
112
112
  title: "缺少模板ID",
@@ -115,20 +115,20 @@ const Q = {
115
115
  extra: r(() => [
116
116
  o(C, {
117
117
  type: "primary",
118
- onClick: h
118
+ onClick: k
119
119
  }, {
120
120
  default: r(() => [...e[0] || (e[0] = [
121
- N("返回", -1)
121
+ E("返回", -1)
122
122
  ])]),
123
123
  _: 1
124
124
  })
125
125
  ]),
126
126
  _: 1
127
127
  })
128
- ])) : B("", !0);
128
+ ])) : N("", !0);
129
129
  };
130
130
  }
131
- }, De = /* @__PURE__ */ q(U, [["__scopeId", "data-v-9ea74b78"]]);
131
+ }, we = /* @__PURE__ */ W(Q, [["__scopeId", "data-v-c751811d"]]);
132
132
  export {
133
- De as default
133
+ we as default
134
134
  };
@@ -1,43 +1,45 @@
1
1
  import "../../../../../node_modules/element-plus/theme-chalk/base.css.js";
2
2
  import "../../../../../node_modules/element-plus/theme-chalk/el-form-item.css.js";
3
- import { openBlock as r, createElementBlock as d, Fragment as n, createVNode as t, withCtx as m, createElementVNode as i } from "vue";
3
+ import { openBlock as d, createElementBlock as n, Fragment as i, createVNode as o, withCtx as m, createElementVNode as r } from "vue";
4
4
  import f from "../../../../components/DataSourceSelect.vue.js";
5
5
  import u from "../../../../components/FieldMapping.vue2.js";
6
6
  import "./FormSetValue.vue.js";
7
7
  import p from "../../../../../_virtual/_plugin-vue_export-helper.js";
8
8
  import { ElFormItem as c } from "../../../../../node_modules/element-plus/es/components/form/index.js";
9
- const s = {
9
+ const s = { class: "desc-content" }, V = {
10
10
  __name: "FormSetValue",
11
11
  props: {
12
12
  formData: Object
13
13
  },
14
- setup(o) {
15
- return (V, e) => {
14
+ setup(t) {
15
+ return (_, e) => {
16
16
  const l = c;
17
- return r(), d(n, null, [
18
- t(l, { label: "选择数据源" }, {
17
+ return d(), n(i, null, [
18
+ o(l, { label: "选择数据源" }, {
19
19
  default: m(() => [
20
- t(f, {
21
- modelValue: o.formData.dataSourceId,
22
- "onUpdate:modelValue": e[0] || (e[0] = (a) => o.formData.dataSourceId = a)
20
+ o(f, {
21
+ modelValue: t.formData.dataSourceId,
22
+ "onUpdate:modelValue": e[0] || (e[0] = (a) => t.formData.dataSourceId = a)
23
23
  }, null, 8, ["modelValue"])
24
24
  ]),
25
25
  _: 1
26
26
  }),
27
- t(l, { label: "字段映射" }, {
27
+ o(l, { label: "字段映射" }, {
28
28
  default: m(() => [
29
- e[2] || (e[2] = i("div", { class: "condition-desc" }, " 当返回的字段与表单字段不一致时,可通过此配置进行映射。 ", -1)),
30
- t(u, {
31
- modelValue: o.formData.fieldMapping,
32
- "onUpdate:modelValue": e[1] || (e[1] = (a) => o.formData.fieldMapping = a)
33
- }, null, 8, ["modelValue"])
29
+ r("div", s, [
30
+ e[2] || (e[2] = r("div", { class: "condition-desc" }, " 当返回的字段与表单字段不一致时,可通过此配置进行映射。 ", -1)),
31
+ o(u, {
32
+ modelValue: t.formData.fieldMapping,
33
+ "onUpdate:modelValue": e[1] || (e[1] = (a) => t.formData.fieldMapping = a)
34
+ }, null, 8, ["modelValue"])
35
+ ])
34
36
  ]),
35
37
  _: 1
36
38
  })
37
39
  ], 64);
38
40
  };
39
41
  }
40
- }, E = /* @__PURE__ */ p(s, [["__scopeId", "data-v-92d5d790"]]);
42
+ }, E = /* @__PURE__ */ p(V, [["__scopeId", "data-v-52671c1b"]]);
41
43
  export {
42
44
  E as default
43
45
  };
@@ -1,84 +1,90 @@
1
1
  import "../../../../../node_modules/element-plus/theme-chalk/base.css.js";
2
2
  import "../../../../../node_modules/element-plus/theme-chalk/el-form-item.css.js";
3
3
  import "../../../../../node_modules/element-plus/theme-chalk/el-switch.css.js";
4
- import { computed as n, openBlock as u, createElementBlock as s, Fragment as V, createVNode as a, withCtx as m, createElementVNode as d, unref as p } from "vue";
5
- import b from "../../../../components/DataSourceSelect.vue.js";
6
- import D from "../../../../components/FieldMapping.vue2.js";
7
- import F from "../../../../components/ParamsConfig.vue2.js";
8
- import { getEditConfigDataFields as g } from "../../../utils/common.js";
4
+ import { computed as f, openBlock as s, createElementBlock as u, Fragment as V, createVNode as o, withCtx as m, createElementVNode as a, unref as p } from "vue";
5
+ import c from "../../../../components/DataSourceSelect.vue.js";
6
+ import b from "../../../../components/FieldMapping.vue2.js";
7
+ import D from "../../../../components/ParamsConfig.vue2.js";
8
+ import { getEditConfigDataFields as v } from "../../../utils/common.js";
9
9
  import "./FormSubmit.vue.js";
10
- import v from "../../../../../_virtual/_plugin-vue_export-helper.js";
11
- import { ElSwitch as x } from "../../../../../node_modules/element-plus/es/components/switch/index.js";
12
- import { ElFormItem as c } from "../../../../../node_modules/element-plus/es/components/form/index.js";
13
- const E = {
10
+ import F from "../../../../../_virtual/_plugin-vue_export-helper.js";
11
+ import { ElSwitch as g } from "../../../../../node_modules/element-plus/es/components/switch/index.js";
12
+ import { ElFormItem as x } from "../../../../../node_modules/element-plus/es/components/form/index.js";
13
+ const E = { class: "desc-content" }, S = { class: "desc-content" }, U = { class: "desc-content" }, w = {
14
14
  __name: "FormSubmit",
15
15
  props: {
16
16
  formData: Object
17
17
  },
18
- setup(e) {
19
- const i = n(() => (g() || []).map((l) => ({
20
- id: l.id,
21
- label: l.label,
22
- fieldName: l.fieldName,
23
- fieldType: l.fieldType
18
+ setup(l) {
19
+ const r = f(() => (v() || []).map((e) => ({
20
+ id: e.id,
21
+ label: e.label,
22
+ fieldName: e.fieldName,
23
+ fieldType: e.fieldType
24
24
  })));
25
- return (f, l) => {
26
- const r = x, t = c;
27
- return u(), s(V, null, [
28
- a(t, { label: "表单校验" }, {
25
+ return (n, e) => {
26
+ const i = g, d = x;
27
+ return s(), u(V, null, [
28
+ o(d, { label: "表单校验" }, {
29
29
  default: m(() => [
30
- a(r, {
31
- modelValue: e.formData.formValidate,
32
- "onUpdate:modelValue": l[0] || (l[0] = (o) => e.formData.formValidate = o)
30
+ o(i, {
31
+ modelValue: l.formData.formValidate,
32
+ "onUpdate:modelValue": e[0] || (e[0] = (t) => l.formData.formValidate = t)
33
33
  }, null, 8, ["modelValue"])
34
34
  ]),
35
35
  _: 1
36
36
  }),
37
- a(t, { label: "选择数据源" }, {
37
+ o(d, { label: "选择数据源" }, {
38
38
  default: m(() => [
39
- a(b, {
40
- modelValue: e.formData.dataSourceId,
41
- "onUpdate:modelValue": l[1] || (l[1] = (o) => e.formData.dataSourceId = o)
39
+ o(c, {
40
+ modelValue: l.formData.dataSourceId,
41
+ "onUpdate:modelValue": e[1] || (e[1] = (t) => l.formData.dataSourceId = t)
42
42
  }, null, 8, ["modelValue"])
43
43
  ]),
44
44
  _: 1
45
45
  }),
46
- a(t, { label: "扩展参数" }, {
46
+ o(d, { label: "扩展参数" }, {
47
47
  default: m(() => [
48
- l[5] || (l[5] = d("div", { class: "condition-desc" }, " 配置额外的请求参数,用于补充表单上没有的字段。 ", -1)),
49
- a(F, {
50
- modelValue: e.formData.extraParams,
51
- "onUpdate:modelValue": l[2] || (l[2] = (o) => e.formData.extraParams = o),
52
- "available-fields": p(i)
53
- }, null, 8, ["modelValue", "available-fields"])
48
+ a("div", E, [
49
+ e[5] || (e[5] = a("div", { class: "condition-desc" }, " 配置额外的请求参数,用于补充表单上没有的字段。 ", -1)),
50
+ o(D, {
51
+ modelValue: l.formData.extraParams,
52
+ "onUpdate:modelValue": e[2] || (e[2] = (t) => l.formData.extraParams = t),
53
+ "available-fields": p(r)
54
+ }, null, 8, ["modelValue", "available-fields"])
55
+ ])
54
56
  ]),
55
57
  _: 1
56
58
  }),
57
- a(t, { label: "字段映射" }, {
59
+ o(d, { label: "字段映射" }, {
58
60
  default: m(() => [
59
- l[6] || (l[6] = d("div", { class: "condition-desc" }, " 当提交的字段与表单字段不一致时,可通过此配置进行映射。 ", -1)),
60
- a(D, {
61
- modelValue: e.formData.fieldMapping,
62
- "onUpdate:modelValue": l[3] || (l[3] = (o) => e.formData.fieldMapping = o)
63
- }, null, 8, ["modelValue"])
61
+ a("div", S, [
62
+ e[6] || (e[6] = a("div", { class: "condition-desc" }, " 当提交的字段与表单字段不一致时,可通过此配置进行映射。 ", -1)),
63
+ o(b, {
64
+ modelValue: l.formData.fieldMapping,
65
+ "onUpdate:modelValue": e[3] || (e[3] = (t) => l.formData.fieldMapping = t)
66
+ }, null, 8, ["modelValue"])
67
+ ])
64
68
  ]),
65
69
  _: 1
66
70
  }),
67
- a(t, { label: "赋值表单" }, {
71
+ o(d, { label: "赋值表单" }, {
68
72
  default: m(() => [
69
- a(r, {
70
- modelValue: e.formData.returnToForm,
71
- "onUpdate:modelValue": l[4] || (l[4] = (o) => e.formData.returnToForm = o),
72
- style: { width: "100%" }
73
- }, null, 8, ["modelValue"]),
74
- l[7] || (l[7] = d("div", { class: "condition-desc" }, " 当开启后,将返回的数据赋值到表单字段及隐藏域中。 ", -1))
73
+ a("div", U, [
74
+ o(i, {
75
+ modelValue: l.formData.returnToForm,
76
+ "onUpdate:modelValue": e[4] || (e[4] = (t) => l.formData.returnToForm = t),
77
+ style: { width: "100%" }
78
+ }, null, 8, ["modelValue"]),
79
+ e[7] || (e[7] = a("div", { class: "condition-desc" }, " 当开启后,将返回的数据赋值到表单字段及隐藏域中。 ", -1))
80
+ ])
75
81
  ]),
76
82
  _: 1
77
83
  })
78
84
  ], 64);
79
85
  };
80
86
  }
81
- }, j = /* @__PURE__ */ v(E, [["__scopeId", "data-v-adc2c3df"]]);
87
+ }, q = /* @__PURE__ */ F(w, [["__scopeId", "data-v-24a7b471"]]);
82
88
  export {
83
- j as default
89
+ q as default
84
90
  };
@@ -212,7 +212,7 @@ const re = { class: "fixed-mode-config" }, de = { class: "filter-form-section" }
212
212
  ]);
213
213
  };
214
214
  }
215
- }, Oe = /* @__PURE__ */ ee(ue, [["__scopeId", "data-v-fe8daba2"]]);
215
+ }, Oe = /* @__PURE__ */ ee(ue, [["__scopeId", "data-v-d6b0cd25"]]);
216
216
  export {
217
217
  Oe as default
218
218
  };
@@ -1,5 +1,5 @@
1
1
  const n = {
2
- editingType: "table",
2
+ editingType: null,
3
3
  hoverItem: null,
4
4
  selectedItem: null,
5
5
  editConfigData: null,