mooho-base-admin-plus 2.10.81 → 2.10.83

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/history.md CHANGED
@@ -252,3 +252,5 @@ mooho-base-admin-plus@2.10.78 - 修复上一版本的bug
252
252
  mooho-base-admin-plus@2.10.79 - Excel表格必填标致放标题左边
253
253
  mooho-base-admin-plus@2.10.80 - Excel表格支持可筛选选择框
254
254
  mooho-base-admin-plus@2.10.81 - 优化弹出选择控件
255
+ mooho-base-admin-plus@2.10.82 - 优化弹出选择控件
256
+ mooho-base-admin-plus@2.10.83 - 修复上一版本的bug
@@ -30340,6 +30340,18 @@ const comboSelect = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["render", _sfc_re
30340
30340
  modelValue: {
30341
30341
  type: String
30342
30342
  },
30343
+ /**
30344
+ * 原始数据
30345
+ */
30346
+ rawData: {
30347
+ type: Object
30348
+ },
30349
+ /**
30350
+ * 字段代码
30351
+ */
30352
+ columnCode: {
30353
+ type: String
30354
+ },
30343
30355
  /**
30344
30356
  * 数据源
30345
30357
  */
@@ -30431,6 +30443,13 @@ const comboSelect = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["render", _sfc_re
30431
30443
  }
30432
30444
  });
30433
30445
  } else {
30446
+ if (this.rawData && this.columnCode.endsWith("ID")) {
30447
+ let r = this.parseData(this.rawData, this.columnCode.substring(0, this.columnCode.length - 2));
30448
+ if (r != null) {
30449
+ this.selected = this.parseData(r, this.sourceDisplayCode), this.selectedData = r;
30450
+ return;
30451
+ }
30452
+ }
30434
30453
  let a = {
30435
30454
  page: 1,
30436
30455
  per: 1
@@ -42653,15 +42672,17 @@ function _sfc_render$p(a, r, o, s, l, c) {
42653
42672
  }, null, 8, ["model-value", "onUpdate:modelValue", "readonly", "remote-method", "data", "param", "column", "onOnChange"])) : W.controlType === "DialogSelect" ? (openBlock(), createBlock(b, {
42654
42673
  key: 14,
42655
42674
  "model-value": a.parseData(l.data, W.code),
42675
+ "raw-data": l.data,
42676
+ "column-code": W.code,
42656
42677
  "onUpdate:modelValue": (he) => a.setData(l.data, W.code, he),
42657
42678
  readonly: o.readonly || W.isReadonly,
42658
42679
  source: W.source,
42659
42680
  "source-data-code": W.sourceDataCode,
42660
42681
  "source-display-code": W.sourceDisplayCode,
42661
42682
  param: a.getParam(l.data, W),
42662
- controlWidth: W.controlWidth,
42683
+ "control-width": W.controlWidth,
42663
42684
  onOnChange: (he) => c.onSelectDataChange(W, he)
42664
- }, null, 8, ["model-value", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "controlWidth", "onOnChange"])) : W.controlType === "MultiDialogSelect" ? (openBlock(), createBlock(b, {
42685
+ }, null, 8, ["model-value", "raw-data", "column-code", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "control-width", "onOnChange"])) : W.controlType === "MultiDialogSelect" ? (openBlock(), createBlock(b, {
42665
42686
  key: 15,
42666
42687
  "model-value": a.parseData(l.data, W.code),
42667
42688
  "onUpdate:modelValue": (he) => a.setData(l.data, W.code, he),
@@ -42671,9 +42692,9 @@ function _sfc_render$p(a, r, o, s, l, c) {
42671
42692
  "source-data-code": W.sourceDataCode,
42672
42693
  "source-display-code": W.sourceDisplayCode,
42673
42694
  param: a.getParam(l.data, W),
42674
- controlWidth: W.controlWidth,
42695
+ "control-width": W.controlWidth,
42675
42696
  onOnChange: (he) => c.onSelectDataChange(W, he)
42676
- }, null, 8, ["model-value", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "controlWidth", "onOnChange"])) : W.controlType === "SelectWithOther" ? (openBlock(), createElementBlock(Fragment, { key: 16 }, [
42697
+ }, null, 8, ["model-value", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "control-width", "onOnChange"])) : W.controlType === "SelectWithOther" ? (openBlock(), createElementBlock(Fragment, { key: 16 }, [
42677
42698
  createVNode$1(_, {
42678
42699
  "model-value": c.parseDataWithOther(l.data, W),
42679
42700
  "onUpdate:modelValue": (he) => c.setDataWithOther(l.data, W.code, he),
@@ -105203,7 +105224,11 @@ const _sfc_main$n = {
105203
105224
  l = o;
105204
105225
  else
105205
105226
  a._rawData && a._rawData[r.code] ? l = a._rawData[r.code].find((c) => this.parseData(c, r.sourceDataCode) == o) : l = o;
105206
- s && this.setData(a, s, l), this.onDataChange(a, r, l);
105227
+ if (s) {
105228
+ let c = l;
105229
+ r.sourceDataCode.endsWith("ID") && (c = this.parseData(l, r.sourceDataCode.substr(0, r.sourceDataCode.length - 2))), this.setData(a, s, c);
105230
+ }
105231
+ this.onDataChange(a, r, l);
105207
105232
  },
105208
105233
  // 数据变化事件
105209
105234
  onDataChange(a, r, o) {
@@ -105911,6 +105936,8 @@ function _sfc_render$n(a, r, o, s, l, c) {
105911
105936
  }, 1032, ["model-value", "onUpdate:modelValue", "disabled", "clearable", "style", "placeholder", "onOnChange"])) : ee.controlType === "DialogSelect" ? (openBlock(), createBlock(A, {
105912
105937
  key: 10,
105913
105938
  "model-value": a.parseData(c.rowData(ce, V), ee.code),
105939
+ "raw-data": c.rowData(ce, V),
105940
+ "column-code": ee.code,
105914
105941
  size: "small",
105915
105942
  "onUpdate:modelValue": (H) => a.setData(c.rowData(ce, V), ee.code, H),
105916
105943
  readonly: c.isReadonly(c.rowData(ce, V), ee),
@@ -105922,7 +105949,7 @@ function _sfc_render$n(a, r, o, s, l, c) {
105922
105949
  onOnChange: (H) => c.onSelectDataChange(c.rowData(ce, V), ee, H),
105923
105950
  onClick: r[9] || (r[9] = withModifiers(() => {
105924
105951
  }, ["stop"]))
105925
- }, null, 8, ["model-value", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "controlWidth", "onOnChange"])) : ee.controlType === "MultiDialogSelect" ? (openBlock(), createBlock(A, {
105952
+ }, null, 8, ["model-value", "raw-data", "column-code", "onUpdate:modelValue", "readonly", "source", "source-data-code", "source-display-code", "param", "controlWidth", "onOnChange"])) : ee.controlType === "MultiDialogSelect" ? (openBlock(), createBlock(A, {
105926
105953
  key: 11,
105927
105954
  "model-value": a.parseData(c.rowData(ce, V), ee.code),
105928
105955
  size: "small",
@@ -106357,7 +106384,7 @@ function _sfc_render$n(a, r, o, s, l, c) {
106357
106384
  ], 2)
106358
106385
  ], 2);
106359
106386
  }
106360
- const viewTable = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["render", _sfc_render$n], ["__scopeId", "data-v-22006e27"]]), __vite_glob_1_33 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
106387
+ const viewTable = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["render", _sfc_render$n], ["__scopeId", "data-v-cf405477"]]), __vite_glob_1_33 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
106361
106388
  __proto__: null,
106362
106389
  default: viewTable
106363
106390
  }, Symbol.toStringTag, { value: "Module" })), _sfc_main$m = {