slw 0.5.981 → 0.5.983

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/lib/index.js CHANGED
@@ -37188,8 +37188,13 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
37188
37188
  formData.value[H.toUpperCase()] = Q[H];
37189
37189
  }, setInitData = (Q) => {
37190
37190
  setData(Q);
37191
- }, setValue = (Q, H) => {
37192
- formData.value[Q.toUpperCase()] = H;
37191
+ }, setValue = async (Q, H) => {
37192
+ let G = formConfig.value.columns.filter((X) => X.field == Q.toUpperCase())[0];
37193
+ G.remoteSearch ? (G.itemRender.options = await remoteMethod(
37194
+ H,
37195
+ G.id,
37196
+ G.selectorId
37197
+ ), G.itemRender.options.length > 0 ? formData.value[Q.toUpperCase()] = G.itemRender.options[0].VALUE : formData.value[Q.toUpperCase()] = H) : formData.value[Q.toUpperCase()] = H;
37193
37198
  }, getData = () => formData.value, getSelectRecord = () => formData.value, getForm = () => form.value, checkSubmitData = () => {
37194
37199
  let Q = !1;
37195
37200
  return form.value.validate().then((H) => {
@@ -38178,14 +38183,14 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
38178
38183
  emits: ["close"],
38179
38184
  setup(Q, { emit: H }) {
38180
38185
  const G = Q, X = inject("$componentMapping"), Z = inject("$base64Encode"), K = inject("$base64Decode"), ee = inject("$t");
38181
- let te = ref(!1), ne = shallowRef(), re = ref(!1), oe = ref(1e3), ae = ref({}), le = ref(500), se = ref(400), ce = ref();
38186
+ let te = ref(!1), ne = shallowRef(), re = ref(!1), oe = ref(1e3), ae = ref({}), le = ref("88%"), se = ref(75), ce = ref();
38182
38187
  const de = inject("$components"), he = inject("$componentsPath"), ue = () => {
38183
38188
  te.value = !1;
38184
38189
  };
38185
38190
  watch(
38186
38191
  () => G.actionData,
38187
38192
  async (fe) => {
38188
- fe.type === "show" ? (te.value = !0, fe.params && typeof fe.params.width < "u" && (le.value = fe.params.width), fe.params && typeof fe.params.height < "u" && (se.value = fe.params.height), fe.params && typeof fe.params.fullscreen < "u" && (re.value = fe.params.fullscreen), fe.params && typeof fe.params.zIndex < "u" && (oe.value = fe.params.zIndex), ae.value = XEUtils$1.clone(toRaw(fe.params), !0), fe.showComponent && (ne.value = (await de[`${he}/${fe.showComponent}`]()).default)) : te.value = !1;
38193
+ fe.type === "show" ? (te.value = !0, fe.params && typeof fe.params.width < "u" && (le.value = fe.params.width), fe.params && typeof fe.params.height < "u" && (typeof fe.params.height == "number" || fe.params.height.indexOf("px") > 0 ? (se.value = parseInt(fe.params.height) / document.documentElement.clientHeight * 100, se.value = Math.floor(se.value)) : fe.params.height.indexOf("%") > 0 || fe.params.height.indexOf("vh") > 0 ? se.value = parseInt(fe.params.height) : se.value = 75), fe.params && typeof fe.params.fullscreen < "u" && (re.value = fe.params.fullscreen), fe.params && typeof fe.params.zIndex < "u" && (oe.value = fe.params.zIndex), ae.value = XEUtils$1.clone(toRaw(fe.params), !0), fe.showComponent && (ne.value = (await de[`${he}/${fe.showComponent}`]()).default)) : te.value = !1;
38189
38194
  },
38190
38195
  { deep: !0 }
38191
38196
  );
@@ -38198,7 +38203,6 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
38198
38203
  ref_key: "selfModal",
38199
38204
  ref: ce,
38200
38205
  width: unref(le),
38201
- height: unref(se),
38202
38206
  modelValue: unref(te),
38203
38207
  "onUpdate:modelValue": me[0] || (me[0] = (ve) => isRef(te) ? te.value = ve : te = ve),
38204
38208
  visible: unref(te),
@@ -38210,6 +38214,7 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
38210
38214
  "append-to-body": "",
38211
38215
  transfer: "",
38212
38216
  resize: "",
38217
+ "align-center": "",
38213
38218
  "close-on-press-escape": "",
38214
38219
  "destroy-on-close": "",
38215
38220
  onShow: me[2] || (me[2] = (ve) => unref(re) ? unref(ce).maximize() : null),
@@ -38217,22 +38222,26 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
38217
38222
  onClosed: pe
38218
38223
  }, {
38219
38224
  default: withCtx(() => [
38220
- Q.actionData.showComponent && Q.actionData.showComponent.indexOf("http") !== -1 ? (openBlock(), createElementBlock("iframe", {
38221
- key: 0,
38222
- src: Q.actionData.showComponent,
38223
- frameborder: "0",
38224
- width: "100%",
38225
- height: "100%",
38226
- scrolling: "auto",
38227
- style: { "background-color": "#fff" }
38228
- }, null, 8, _hoisted_1$kT)) : (openBlock(), createBlock(resolveDynamicComponent(unref(ne)), {
38229
- key: 1,
38230
- componentData: unref(ae),
38231
- onClose: ue
38232
- }, null, 40, ["componentData"]))
38225
+ createElementVNode("div", {
38226
+ style: normalizeStyle({ height: unref(se) ? unref(se) + "vh" : "75vh" })
38227
+ }, [
38228
+ Q.actionData.showComponent && Q.actionData.showComponent.indexOf("http") !== -1 ? (openBlock(), createElementBlock("iframe", {
38229
+ key: 0,
38230
+ src: Q.actionData.showComponent,
38231
+ frameborder: "0",
38232
+ width: "100%",
38233
+ height: "100%",
38234
+ scrolling: "auto",
38235
+ style: { "background-color": "#fff" }
38236
+ }, null, 8, _hoisted_1$kT)) : (openBlock(), createBlock(resolveDynamicComponent(unref(ne)), {
38237
+ key: 1,
38238
+ componentData: unref(ae),
38239
+ onClose: ue
38240
+ }, null, 40, ["componentData"]))
38241
+ ], 4)
38233
38242
  ]),
38234
38243
  _: 1
38235
- }, 8, ["width", "height", "modelValue", "visible", "fullscreen", "z-index", "title"]);
38244
+ }, 8, ["width", "modelValue", "visible", "fullscreen", "z-index", "title"]);
38236
38245
  };
38237
38246
  }
38238
38247
  };
@@ -122174,7 +122183,7 @@ function reConsole() {
122174
122183
  }
122175
122184
  }
122176
122185
  console.info(
122177
- "%cSLW %cVer 0.5.981",
122186
+ "%cSLW %cVer 0.5.983",
122178
122187
  "color:#409EFF;font-size: 22px;font-weight:bolder",
122179
122188
  "color:#999;font-size: 12px"
122180
122189
  );