form-custom-test 3.0.215 → 3.0.217

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.
@@ -10945,6 +10945,9 @@ var fieldMixin = {
10945
10945
  if (!foundRef && (!this.subFormItemFlag || this.designState)) {
10946
10946
  foundRef = this.refList[widgetName];
10947
10947
  }
10948
+ if (!foundRef) {
10949
+ foundRef = this.refList[widgetName];
10950
+ }
10948
10951
  if (!foundRef && !!showError) {
10949
10952
  this.$message.error(this.i18nt("render.hint.refNotFound") + widgetName);
10950
10953
  }
@@ -11267,7 +11270,10 @@ const _sfc_main$3F = {
11267
11270
  },
11268
11271
  rules: Array
11269
11272
  },
11270
- inject: ["getFormConfig"],
11273
+ inject: {
11274
+ getFormConfig: { from: "getFormConfig" },
11275
+ getCustomSubFormFieldLabelHidden: { default: null }
11276
+ },
11271
11277
  computed: {
11272
11278
  formConfig() {
11273
11279
  return this.getFormConfig();
@@ -11276,13 +11282,13 @@ const _sfc_main$3F = {
11276
11282
  return !!this.designer && this.field.id === this.designer.selectedId;
11277
11283
  },
11278
11284
  label() {
11279
- if (!!this.field.options.labelHidden) {
11285
+ if (!!this.field.options.labelHidden || this.isParentSubFormLabelHidden) {
11280
11286
  return "";
11281
11287
  }
11282
11288
  return this.field.options.label;
11283
11289
  },
11284
11290
  labelWidth() {
11285
- if (!!this.field.options.labelHidden) {
11291
+ if (!!this.field.options.labelHidden || this.isParentSubFormLabelHidden) {
11286
11292
  return 0;
11287
11293
  }
11288
11294
  if (!!this.field.options.labelWidth) {
@@ -11312,6 +11318,12 @@ const _sfc_main$3F = {
11312
11318
  },
11313
11319
  subFormItemFlag() {
11314
11320
  return !!this.parentWidget ? this.parentWidget.type === "sub-form" || this.parentWidget.type === "custom-sub-form" : false;
11321
+ },
11322
+ isParentSubFormLabelHidden() {
11323
+ if (typeof this.getCustomSubFormFieldLabelHidden === "function") {
11324
+ return !!this.getCustomSubFormFieldLabelHidden();
11325
+ }
11326
+ return false;
11315
11327
  }
11316
11328
  },
11317
11329
  created() {
@@ -11503,7 +11515,7 @@ function _sfc_render$3F(_ctx, _cache, $props, $setup, $data, $options) {
11503
11515
  ], 64)) : createCommentVNode("", true)
11504
11516
  ], 2);
11505
11517
  }
11506
- var FormItemWrapper = /* @__PURE__ */ _export_sfc$1(_sfc_main$3F, [["render", _sfc_render$3F], ["__scopeId", "data-v-a42827ee"]]);
11518
+ var FormItemWrapper = /* @__PURE__ */ _export_sfc$1(_sfc_main$3F, [["render", _sfc_render$3F], ["__scopeId", "data-v-3cbbbdb2"]]);
11507
11519
  var __glob_0_8$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
11508
11520
  __proto__: null,
11509
11521
  "default": FormItemWrapper
@@ -54472,7 +54484,7 @@ const _hoisted_12$2 = {
54472
54484
  class: ""
54473
54485
  };
54474
54486
  const _hoisted_13$2 = { style: { "border": "1px solid #DCDFE6" } };
54475
- const _hoisted_14$2 = { class: "dialog-footer" };
54487
+ const _hoisted_14$1 = { class: "dialog-footer" };
54476
54488
  const _hoisted_15$1 = {
54477
54489
  key: 5,
54478
54490
  class: ""
@@ -54984,7 +54996,7 @@ function _sfc_render$2Z(_ctx, _cache, $props, $setup, $data, $options) {
54984
54996
  "append-to-body": true
54985
54997
  }, {
54986
54998
  footer: withCtx(() => [
54987
- createElementVNode("div", _hoisted_14$2, [
54999
+ createElementVNode("div", _hoisted_14$1, [
54988
55000
  createVNode(_component_el_button, {
54989
55001
  type: "primary",
54990
55002
  class: "copy-form-data-json-btn",
@@ -56915,7 +56927,7 @@ const _hoisted_12$1 = {
56915
56927
  class: ""
56916
56928
  };
56917
56929
  const _hoisted_13$1 = { class: "dialog-footer" };
56918
- const _hoisted_14$1 = {
56930
+ const _hoisted_14 = {
56919
56931
  key: 10,
56920
56932
  class: ""
56921
56933
  };
@@ -57303,7 +57315,7 @@ function _sfc_render$2m(_ctx, _cache, $props, $setup, $data, $options) {
57303
57315
  ])), [
57304
57316
  [_directive_drag, [".drag-dialog.el-dialog", ".drag-dialog .el-dialog__header"]]
57305
57317
  ]) : createCommentVNode("", true),
57306
- $data.showImportTreeDialogFlag ? withDirectives((openBlock(), createElementBlock("div", _hoisted_14$1, [
57318
+ $data.showImportTreeDialogFlag ? withDirectives((openBlock(), createElementBlock("div", _hoisted_14, [
57307
57319
  createVNode(_component_el_dialog, {
57308
57320
  title: _ctx.i18nt("designer.setting.importOptions"),
57309
57321
  modelValue: $data.showImportTreeDialogFlag,
@@ -69198,13 +69210,13 @@ function registerIcon(app) {
69198
69210
  if (typeof window !== "undefined") {
69199
69211
  let loadSvg = function() {
69200
69212
  var body = document.body;
69201
- var svgDom = document.getElementById("__svg__icons__dom__1782180945157__");
69213
+ var svgDom = document.getElementById("__svg__icons__dom__1782264802990__");
69202
69214
  if (!svgDom) {
69203
69215
  svgDom = document.createElementNS("http://www.w3.org/2000/svg", "svg");
69204
69216
  svgDom.style.position = "absolute";
69205
69217
  svgDom.style.width = "0";
69206
69218
  svgDom.style.height = "0";
69207
- svgDom.id = "__svg__icons__dom__1782180945157__";
69219
+ svgDom.id = "__svg__icons__dom__1782264802990__";
69208
69220
  svgDom.setAttribute("xmlns", "http://www.w3.org/2000/svg");
69209
69221
  svgDom.setAttribute("xmlns:link", "http://www.w3.org/1999/xlink");
69210
69222
  }
@@ -75058,6 +75070,7 @@ service$1.interceptors.request.use((config) => {
75058
75070
  const accessToken = getToken();
75059
75071
  const company = sessionStorage.getItem("companyId");
75060
75072
  const post = sessionStorage.getItem("postId");
75073
+ console.log(accessToken, "accessToken");
75061
75074
  if (accessToken) {
75062
75075
  config.headers["Authorization"] = getToken();
75063
75076
  }
@@ -76183,6 +76196,7 @@ const customSubFormSchema = {
76183
76196
  disabled: false,
76184
76197
  showBlankRow: true,
76185
76198
  showRowNumber: true,
76199
+ labelHidden: false,
76186
76200
  customClass: "",
76187
76201
  onSubFormRowChange: "",
76188
76202
  onSubFormRowAdd: "",
@@ -76222,6 +76236,15 @@ const _sfc_main$l = {
76222
76236
  return this.widget.options.customClass || "";
76223
76237
  }
76224
76238
  },
76239
+ provide() {
76240
+ const vm = this;
76241
+ return {
76242
+ getCustomSubFormFieldLabelHidden() {
76243
+ var _a2, _b2;
76244
+ return !!((_b2 = (_a2 = vm.widget) == null ? void 0 : _a2.options) == null ? void 0 : _b2.labelHidden);
76245
+ }
76246
+ };
76247
+ },
76225
76248
  created() {
76226
76249
  this.initRefList();
76227
76250
  },
@@ -76242,7 +76265,10 @@ const _sfc_main$l = {
76242
76265
  }
76243
76266
  };
76244
76267
  const _hoisted_1$i = { class: "sub-form-header" };
76245
- const _hoisted_2$d = { class: "sub-form-label" };
76268
+ const _hoisted_2$d = {
76269
+ key: 0,
76270
+ class: "sub-form-label"
76271
+ };
76246
76272
  const _hoisted_3$b = { class: "group-header" };
76247
76273
  const _hoisted_4$9 = { class: "group-title" };
76248
76274
  const _hoisted_5$7 = {
@@ -76279,7 +76305,7 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
76279
76305
  onClick: _cache[1] || (_cache[1] = withModifiers(($event) => _ctx.selectWidget($props.widget), ["stop"]))
76280
76306
  }, [
76281
76307
  createElementVNode("div", _hoisted_1$i, [
76282
- createElementVNode("span", _hoisted_2$d, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355"), 1)
76308
+ !$props.widget.options.labelHidden ? (openBlock(), createElementBlock("span", _hoisted_2$d, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355"), 1)) : createCommentVNode("", true)
76283
76309
  ]),
76284
76310
  (openBlock(true), createElementBlock(Fragment, null, renderList($data.previewRows, (row, rowIdx) => {
76285
76311
  return openBlock(), createElementBlock("div", {
@@ -76367,7 +76393,7 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
76367
76393
  _: 1
76368
76394
  }, 8, ["designer", "widget", "parent-widget", "parent-list", "index-of-parent-list"]);
76369
76395
  }
76370
- var CustomSubFormWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$l, [["render", _sfc_render$l], ["__scopeId", "data-v-787fff1a"]]);
76396
+ var CustomSubFormWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$l, [["render", _sfc_render$l], ["__scopeId", "data-v-0d784fb7"]]);
76371
76397
  var customSubFormItem_vue_vue_type_style_index_0_scoped_true_lang = "";
76372
76398
  const _sfc_main$k = {
76373
76399
  name: "custom-sub-form-item",
@@ -76382,6 +76408,15 @@ const _sfc_main$k = {
76382
76408
  widget: Object
76383
76409
  },
76384
76410
  inject: ["refList", "sfRefList", "globalModel"],
76411
+ provide() {
76412
+ const vm = this;
76413
+ return {
76414
+ getCustomSubFormFieldLabelHidden() {
76415
+ var _a2, _b2;
76416
+ return !!((_b2 = (_a2 = vm.widget) == null ? void 0 : _a2.options) == null ? void 0 : _b2.labelHidden);
76417
+ }
76418
+ };
76419
+ },
76385
76420
  data() {
76386
76421
  return {
76387
76422
  rowIdData: [],
@@ -76736,7 +76771,10 @@ const _sfc_main$k = {
76736
76771
  }
76737
76772
  }
76738
76773
  };
76739
- const _hoisted_1$h = { class: "sub-form-header" };
76774
+ const _hoisted_1$h = {
76775
+ key: 0,
76776
+ class: "sub-form-header"
76777
+ };
76740
76778
  const _hoisted_2$c = { class: "sub-form-label" };
76741
76779
  const _hoisted_3$a = { class: "group-header" };
76742
76780
  const _hoisted_4$8 = { class: "group-title" };
@@ -76744,29 +76782,25 @@ const _hoisted_5$6 = {
76744
76782
  key: 0,
76745
76783
  class: "row-number-span"
76746
76784
  };
76747
- const _hoisted_6$6 = {
76748
- key: 1,
76749
- class: "row-number-span"
76750
- };
76751
- const _hoisted_7$5 = { class: "group-actions" };
76752
- const _hoisted_8$3 = { class: "group-content" };
76753
- const _hoisted_9$2 = {
76785
+ const _hoisted_6$6 = { class: "group-actions" };
76786
+ const _hoisted_7$5 = { class: "group-content" };
76787
+ const _hoisted_8$3 = {
76754
76788
  key: 1,
76755
76789
  class: "field-loading",
76756
76790
  style: { "color": "#909399", "font-size": "12px", "padding": "8px" }
76757
76791
  };
76758
- const _hoisted_10$1 = {
76792
+ const _hoisted_9$2 = {
76759
76793
  key: 1,
76760
76794
  class: "empty-hint"
76761
76795
  };
76762
- const _hoisted_11 = { key: 0 };
76763
- const _hoisted_12 = { key: 1 };
76764
- const _hoisted_13 = {
76765
- key: 0,
76796
+ const _hoisted_10$1 = { key: 0 };
76797
+ const _hoisted_11 = { key: 1 };
76798
+ const _hoisted_12 = {
76799
+ key: 1,
76766
76800
  class: "empty-hint"
76767
76801
  };
76768
- const _hoisted_14 = {
76769
- key: 1,
76802
+ const _hoisted_13 = {
76803
+ key: 2,
76770
76804
  class: "empty-hint"
76771
76805
  };
76772
76806
  function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
@@ -76779,9 +76813,9 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
76779
76813
  key: $props.widget.id,
76780
76814
  class: normalizeClass(["custom-sub-form-container", $options.customClass])
76781
76815
  }, [
76782
- createElementVNode("div", _hoisted_1$h, [
76816
+ !$props.widget.options.labelHidden ? (openBlock(), createElementBlock("div", _hoisted_1$h, [
76783
76817
  createElementVNode("span", _hoisted_2$c, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355"), 1)
76784
- ]),
76818
+ ])) : createCommentVNode("", true),
76785
76819
  (openBlock(true), createElementBlock(Fragment, null, renderList($data.rowIdData, (subFormRowId, sfrIdx) => {
76786
76820
  return openBlock(), createElementBlock("div", {
76787
76821
  class: "form-group-row",
@@ -76789,9 +76823,9 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
76789
76823
  }, [
76790
76824
  createElementVNode("div", _hoisted_3$a, [
76791
76825
  createElementVNode("div", _hoisted_4$8, [
76792
- $props.widget.options.showRowNumber ? (openBlock(), createElementBlock("span", _hoisted_5$6, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355") + " " + toDisplayString(sfrIdx + 1), 1)) : (openBlock(), createElementBlock("span", _hoisted_6$6, "\u8868\u5355\u7EC4"))
76826
+ $props.widget.options.showRowNumber && !$props.widget.options.labelHidden ? (openBlock(), createElementBlock("span", _hoisted_5$6, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355") + " " + toDisplayString(sfrIdx + 1), 1)) : createCommentVNode("", true)
76793
76827
  ]),
76794
- createElementVNode("div", _hoisted_7$5, [
76828
+ createElementVNode("div", _hoisted_6$6, [
76795
76829
  sfrIdx > 0 && !$props.widget.options.disabled ? (openBlock(), createBlock(_component_el_button, {
76796
76830
  key: 0,
76797
76831
  size: "small",
@@ -76807,7 +76841,7 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
76807
76841
  }, 8, ["onClick"])) : createCommentVNode("", true)
76808
76842
  ])
76809
76843
  ]),
76810
- createElementVNode("div", _hoisted_8$3, [
76844
+ createElementVNode("div", _hoisted_7$5, [
76811
76845
  $props.widget && $props.widget.widgetList && $props.widget.widgetList.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList($props.widget.widgetList, (subWidget, swIdx) => {
76812
76846
  return openBlock(), createElementBlock(Fragment, {
76813
76847
  key: subWidget ? subWidget.id + "gc" + subFormRowId + "-" + swIdx : "gc" + subFormRowId + "-" + swIdx
@@ -76834,18 +76868,18 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
76834
76868
  "sub-form-row-index": sfrIdx,
76835
76869
  "sub-form-col-index": swIdx,
76836
76870
  "sub-form-disabled": $props.widget.options.disabled
76837
- }, null, 8, ["field", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index", "sub-form-disabled"])) : (openBlock(), createElementBlock("div", _hoisted_9$2, " \u5B57\u6BB5\u52A0\u8F7D\u4E2D... "))
76871
+ }, null, 8, ["field", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index", "sub-form-disabled"])) : (openBlock(), createElementBlock("div", _hoisted_8$3, " \u5B57\u6BB5\u52A0\u8F7D\u4E2D... "))
76838
76872
  ], 64)) : createCommentVNode("", true)
76839
76873
  ], 64);
76840
- }), 128)) : (openBlock(), createElementBlock("div", _hoisted_10$1, [
76841
- !$props.widget ? (openBlock(), createElementBlock("div", _hoisted_11, "\u7EC4\u4EF6\u672A\u521D\u59CB\u5316")) : !$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_12, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : createCommentVNode("", true)
76874
+ }), 128)) : (openBlock(), createElementBlock("div", _hoisted_9$2, [
76875
+ !$props.widget ? (openBlock(), createElementBlock("div", _hoisted_10$1, "\u7EC4\u4EF6\u672A\u521D\u59CB\u5316")) : !$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_11, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : createCommentVNode("", true)
76842
76876
  ]))
76843
76877
  ])
76844
76878
  ]);
76845
76879
  }), 128)),
76846
- !$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_13, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : $data.rowIdData.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_14, ' \u70B9\u51FB"\u6DFB\u52A0"\u6309\u94AE\u6DFB\u52A0\u6570\u636E\u884C ')) : createCommentVNode("", true),
76880
+ !$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_12, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : $data.rowIdData.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_13, ' \u70B9\u51FB"\u6DFB\u52A0"\u6309\u94AE\u6DFB\u52A0\u6570\u636E\u884C ')) : createCommentVNode("", true),
76847
76881
  !$props.widget.options.disabled ? (openBlock(), createBlock(_component_el_button, {
76848
- key: 2,
76882
+ key: 3,
76849
76883
  disabled: $data.actionDisabled,
76850
76884
  type: "primary",
76851
76885
  plain: "",
@@ -76865,7 +76899,7 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
76865
76899
  _: 1
76866
76900
  }, 8, ["widget"]);
76867
76901
  }
76868
- var CustomSubFormItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$k, [["render", _sfc_render$k], ["__scopeId", "data-v-6bd07e4e"]]);
76902
+ var CustomSubFormItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$k, [["render", _sfc_render$k], ["__scopeId", "data-v-09af068c"]]);
76869
76903
  const customTableCellSchema = {
76870
76904
  type: "custom-table-cell",
76871
76905
  category: "container",
@@ -82978,18 +83012,6 @@ const loadExtension = function(app) {
82978
83012
  addCustomWidgetSchema(customInputSchema);
82979
83013
  app.component(CustomInputWidget.name, CustomInputWidget);
82980
83014
  };
82981
- function setupDict(app, service2, options = {}) {
82982
- const dictConfig = options.dict || {};
82983
- app.config.globalProperties.$dictManager = dictManager;
82984
- app.provide("dictManager", dictManager);
82985
- if (typeof window !== "undefined") {
82986
- window.dictManager = dictManager;
82987
- }
82988
- if (dictConfig.autoLoad !== false && service2) {
82989
- dictManager.fetchFromApi(service2, dictConfig);
82990
- }
82991
- return dictManager;
82992
- }
82993
83015
  const { cookies } = useCookies();
82994
83016
  function getElMessage(app) {
82995
83017
  var _a2, _b2, _c2;
@@ -83027,7 +83049,6 @@ VFormDesigner.install = function(app, options = {}) {
83027
83049
  if (typeof window !== "undefined") {
83028
83050
  window.service = service$1;
83029
83051
  }
83030
- setupDict(app, service$1, options);
83031
83052
  };
83032
83053
  VFormRender.install = function(app, options = {}) {
83033
83054
  loadExtension(app);
@@ -83041,7 +83062,6 @@ VFormRender.install = function(app, options = {}) {
83041
83062
  if (typeof window !== "undefined") {
83042
83063
  window.service = service$1;
83043
83064
  }
83044
- setupDict(app, service$1, options);
83045
83065
  };
83046
83066
  const components = [
83047
83067
  VFormDesigner,
@@ -83063,7 +83083,6 @@ const install = (app, options = {}) => {
83063
83083
  if (typeof window !== "undefined") {
83064
83084
  window.service = service$1;
83065
83085
  }
83066
- setupDict(app, service$1, options);
83067
83086
  };
83068
83087
  var install$1 = {
83069
83088
  install,