@fecp/designer 5.4.6 → 5.4.9

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.
Files changed (27) hide show
  1. package/es/designer/package.json.mjs +1 -1
  2. package/es/designer/src/components/FieldMapping.vue2.mjs +1 -1
  3. package/es/designer/src/components/FieldSetMapping.vue2.mjs +1 -1
  4. package/es/designer/src/components/OptionConfig.vue.mjs +39 -12
  5. package/es/designer.css +94 -94
  6. package/es/packages/vue/src/components/dialog/DialogRenderer.vue2.mjs +2 -2
  7. package/es/packages/vue/src/components/forms/checkbox/Checkbox.vue.mjs +17 -2
  8. package/es/packages/vue/src/components/forms/form/Form.vue.mjs +26 -8
  9. package/es/packages/vue/src/components/forms/radio/Radio.vue.mjs +17 -2
  10. package/es/packages/vue/src/components/forms/select/Select.vue.mjs +17 -2
  11. package/es/packages/vue/src/components/forms/textarea/Textarea.vue.mjs +1 -2
  12. package/es/packages/vue/src/utils/common.mjs +20 -4
  13. package/es/packages/vue/src/utils/datasource.mjs +6 -2
  14. package/lib/designer/package.json.js +1 -1
  15. package/lib/designer/src/components/FieldMapping.vue2.js +1 -1
  16. package/lib/designer/src/components/FieldSetMapping.vue2.js +1 -1
  17. package/lib/designer/src/components/OptionConfig.vue.js +38 -11
  18. package/lib/designer.css +94 -94
  19. package/lib/packages/vue/src/components/dialog/DialogRenderer.vue2.js +2 -2
  20. package/lib/packages/vue/src/components/forms/checkbox/Checkbox.vue.js +16 -1
  21. package/lib/packages/vue/src/components/forms/form/Form.vue.js +26 -8
  22. package/lib/packages/vue/src/components/forms/radio/Radio.vue.js +16 -1
  23. package/lib/packages/vue/src/components/forms/select/Select.vue.js +16 -1
  24. package/lib/packages/vue/src/components/forms/textarea/Textarea.vue.js +1 -2
  25. package/lib/packages/vue/src/utils/common.js +19 -3
  26. package/lib/packages/vue/src/utils/datasource.js +6 -2
  27. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- const version = "5.4.6";
1
+ const version = "5.4.9";
2
2
  const packageJson = {
3
3
  version
4
4
  };
@@ -185,7 +185,7 @@ const _sfc_main = {
185
185
  };
186
186
  }
187
187
  };
188
- const FieldMapping = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-bd18993e"]]);
188
+ const FieldMapping = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-a09f49c9"]]);
189
189
  export {
190
190
  FieldMapping as default
191
191
  };
@@ -405,7 +405,7 @@ const _sfc_main = {
405
405
  };
406
406
  }
407
407
  };
408
- const FieldSetMapping = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-ac24177e"]]);
408
+ const FieldSetMapping = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-87a3bc4a"]]);
409
409
  export {
410
410
  FieldSetMapping as default
411
411
  };
@@ -8,10 +8,12 @@ import "../../../node_modules/element-plus/es/index.mjs";
8
8
  /* empty css */
9
9
  /* empty css */
10
10
  /* empty css */
11
- import { ref, watch, createElementBlock, openBlock, Fragment, createVNode, createBlock, createCommentVNode, withCtx, unref, isRef, createElementVNode, renderList, nextTick } from "vue";
11
+ import { computed, ref, watch, createElementBlock, openBlock, Fragment, createVNode, createBlock, createCommentVNode, withCtx, unref, isRef, createElementVNode, renderList, nextTick } from "vue";
12
12
  import { Plus as plus_default, Rank as rank_default, Minus as minus_default } from "../../../node_modules/@element-plus/icons-vue/dist/index.mjs";
13
13
  import { VueDraggable as lo } from "../../../node_modules/vue-draggable-plus/dist/vue-draggable-plus.mjs";
14
14
  import _sfc_main$1 from "./DataSourceSelect.vue.mjs";
15
+ import FieldMapping from "./FieldMapping.vue2.mjs";
16
+ import { getEditConfigDataFields, getEditConfigData } from "../packages/utils/common.mjs";
15
17
  /* empty css */
16
18
  import _export_sfc from "../../../_virtual/_plugin-vue_export-helper.mjs";
17
19
  import { ElFormItem } from "../../../node_modules/element-plus/es/components/form/index.mjs";
@@ -25,6 +27,10 @@ const _hoisted_4 = ["onClick"];
25
27
  const _hoisted_5 = { class: "data-source-fields" };
26
28
  const _hoisted_6 = { class: "field-item" };
27
29
  const _hoisted_7 = { class: "field-item" };
30
+ const _hoisted_8 = {
31
+ class: "field-item",
32
+ style: { "flex-direction": "column", "align-items": "start" }
33
+ };
28
34
  const _sfc_main = {
29
35
  __name: "OptionConfig",
30
36
  props: {
@@ -52,21 +58,29 @@ const _sfc_main = {
52
58
  dataSourceValue: "",
53
59
  displayField: "",
54
60
  valueField: "",
55
- dictionaryValue: ""
61
+ dictionaryValue: "",
62
+ fieldMapping: []
56
63
  })
57
64
  }
58
65
  },
59
66
  emits: ["update:modelValue"],
60
67
  setup(__props, { emit: __emit }) {
61
- var _a, _b, _c, _d, _e, _f;
68
+ var _a, _b, _c, _d, _e, _f, _g;
62
69
  const props = __props;
63
70
  const emit = __emit;
71
+ computed(() => {
72
+ const displayFields = getEditConfigDataFields() || [];
73
+ const editConfigData = getEditConfigData();
74
+ const hiddenList = (editConfigData == null ? void 0 : editConfigData.hiddenFields) || [];
75
+ return [...displayFields, ...hiddenList];
76
+ });
64
77
  const optionSource = ref(((_a = props.modelValue) == null ? void 0 : _a.optionSource) || "custom");
65
78
  const options = ref(((_b = props.modelValue) == null ? void 0 : _b.options) || []);
66
79
  const dataSourceValue = ref(((_c = props.modelValue) == null ? void 0 : _c.dataSourceValue) || "");
67
80
  const displayField = ref(((_d = props.modelValue) == null ? void 0 : _d.displayField) || "");
68
81
  const valueField = ref(((_e = props.modelValue) == null ? void 0 : _e.valueField) || "");
69
82
  const dictionaryValue = ref(((_f = props.modelValue) == null ? void 0 : _f.dictionaryValue) || "");
83
+ const fieldMapping = ref(((_g = props.modelValue) == null ? void 0 : _g.fieldMapping) || []);
70
84
  const isUpdatingFromProps = ref(false);
71
85
  watch(
72
86
  () => props.modelValue,
@@ -78,6 +92,7 @@ const _sfc_main = {
78
92
  displayField.value = newVal.displayField || "";
79
93
  valueField.value = newVal.valueField || "";
80
94
  dictionaryValue.value = newVal.dictionaryValue || "";
95
+ fieldMapping.value = newVal.fieldMapping || [];
81
96
  }
82
97
  },
83
98
  { deep: true }
@@ -90,7 +105,8 @@ const _sfc_main = {
90
105
  dataSourceValue: dataSourceValue.value,
91
106
  displayField: displayField.value,
92
107
  valueField: valueField.value,
93
- dictionaryValue: dictionaryValue.value
108
+ dictionaryValue: dictionaryValue.value,
109
+ fieldMapping: fieldMapping.value
94
110
  };
95
111
  emit("update:modelValue", data);
96
112
  nextTick(() => {
@@ -104,7 +120,8 @@ const _sfc_main = {
104
120
  dataSourceValue,
105
121
  displayField,
106
122
  valueField,
107
- dictionaryValue
123
+ dictionaryValue,
124
+ fieldMapping
108
125
  ],
109
126
  updateParent,
110
127
  { deep: true, immediate: true }
@@ -160,9 +177,9 @@ const _sfc_main = {
160
177
  default: withCtx(() => [
161
178
  createElementVNode("div", _hoisted_1, [
162
179
  createElementVNode("div", _hoisted_2, [
163
- _cache[6] || (_cache[6] = createElementVNode("span", null, null, -1)),
164
- _cache[7] || (_cache[7] = createElementVNode("span", { class: "header-label" }, "显示值", -1)),
165
- _cache[8] || (_cache[8] = createElementVNode("span", { class: "header-label" }, "真实值", -1)),
180
+ _cache[7] || (_cache[7] = createElementVNode("span", null, null, -1)),
181
+ _cache[8] || (_cache[8] = createElementVNode("span", { class: "header-label" }, "显示值", -1)),
182
+ _cache[9] || (_cache[9] = createElementVNode("span", { class: "header-label" }, "真实值", -1)),
166
183
  createElementVNode("div", {
167
184
  class: "icon-btn add-btn",
168
185
  onClick: handleAddOption
@@ -236,7 +253,7 @@ const _sfc_main = {
236
253
  }),
237
254
  createElementVNode("div", _hoisted_5, [
238
255
  createElementVNode("div", _hoisted_6, [
239
- _cache[9] || (_cache[9] = createElementVNode("span", { class: "field-label" }, "显示字段", -1)),
256
+ _cache[10] || (_cache[10] = createElementVNode("span", { class: "field-label" }, "显示字段", -1)),
240
257
  createVNode(_component_el_input, {
241
258
  modelValue: unref(displayField),
242
259
  "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => isRef(displayField) ? displayField.value = $event : null),
@@ -244,19 +261,29 @@ const _sfc_main = {
244
261
  }, null, 8, ["modelValue"])
245
262
  ]),
246
263
  createElementVNode("div", _hoisted_7, [
247
- _cache[10] || (_cache[10] = createElementVNode("span", { class: "field-label" }, "值字段", -1)),
264
+ _cache[11] || (_cache[11] = createElementVNode("span", { class: "field-label" }, "值字段", -1)),
248
265
  createVNode(_component_el_input, {
249
266
  modelValue: unref(valueField),
250
267
  "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => isRef(valueField) ? valueField.value = $event : null),
251
268
  placeholder: "如:optCode"
252
269
  }, null, 8, ["modelValue"])
270
+ ]),
271
+ createElementVNode("div", _hoisted_8, [
272
+ _cache[12] || (_cache[12] = createElementVNode("span", {
273
+ class: "field-label",
274
+ style: { "width": "auto" }
275
+ }, "选中数据映射表单字段", -1)),
276
+ createVNode(FieldMapping, {
277
+ modelValue: unref(fieldMapping),
278
+ "onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => isRef(fieldMapping) ? fieldMapping.value = $event : null)
279
+ }, null, 8, ["modelValue"])
253
280
  ])
254
281
  ])
255
282
  ], 64)) : unref(optionSource) === "dictionary" ? (openBlock(), createBlock(_component_el_form_item, { key: 2 }, {
256
283
  default: withCtx(() => [
257
284
  createVNode(_component_el_input, {
258
285
  modelValue: unref(dictionaryValue),
259
- "onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => isRef(dictionaryValue) ? dictionaryValue.value = $event : null),
286
+ "onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => isRef(dictionaryValue) ? dictionaryValue.value = $event : null),
260
287
  placeholder: "keyName"
261
288
  }, null, 8, ["modelValue"])
262
289
  ]),
@@ -266,7 +293,7 @@ const _sfc_main = {
266
293
  };
267
294
  }
268
295
  };
269
- const OptionConfig = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-96075352"]]);
296
+ const OptionConfig = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-fd4c229c"]]);
270
297
  export {
271
298
  OptionConfig as default
272
299
  };