@skyfox2000/webui 1.4.5 → 1.4.6

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.
@@ -1,8 +1,8 @@
1
1
  import { defineComponent as _, onMounted as I, createBlock as s, openBlock as o, unref as e, withCtx as l, createCommentVNode as r, createVNode as p, createElementVNode as x, createElementBlock as y, toDisplayString as g, renderSlot as h } from "vue";
2
2
  import { Layout as i, LayoutSider as k } from "ant-design-vue";
3
- import { a as b } from "./toolIcon-BiWBb2pJ.js";
4
- import { I as C, _ as S, f as w, d as $, g as N } from "./menuTabs-D_UlXkmm.js";
5
- import { af as v, a as B, ah as E } from "./uploadList-C_hqJ4X1.js";
3
+ import { a as b } from "./toolIcon-DHKszGtC.js";
4
+ import { I as C, _ as S, f as w, d as $, g as N } from "./menuTabs-BaZAmaXz.js";
5
+ import { af as v, a as B, ah as E } from "./uploadList-DSN9t4r8.js";
6
6
  import "@skyfox2000/microbase";
7
7
  import "@skyfox2000/fapi";
8
8
  import L from "vue-m-message";
@@ -4,7 +4,7 @@ var f = (n, r, a) => m(n, typeof r != "symbol" ? r + "" : r, a);
4
4
  import { hostUrl as w } from "@skyfox2000/fapi";
5
5
  import y from "dayjs";
6
6
  import d from "vue-m-message";
7
- import { ac as b, u as g } from "./uploadList-C_hqJ4X1.js";
7
+ import { ac as b, u as g } from "./uploadList-DSN9t4r8.js";
8
8
  import { isMicroApp as F } from "@skyfox2000/microbase";
9
9
  var i = /* @__PURE__ */ ((n) => (n.Pending = "pending", n.Uploading = "uploading", n.Success = "success", n.Error = "error", n.Online = "online", n.Offline = "offline", n))(i || {});
10
10
  class I {
@@ -125,7 +125,7 @@ class x {
125
125
  * @param onProgress 上传进度回调
126
126
  */
127
127
  async uploadFile(r, a, c) {
128
- return r.status = i.Uploading, new Promise((o, e) => {
128
+ return r.status = i.Uploading, new Promise(async (o, e) => {
129
129
  const l = new FormData();
130
130
  if (l.append("file", r.originFileObj), r.params)
131
131
  for (const s in r.params)
@@ -135,7 +135,7 @@ class x {
135
135
  if (t.open("POST", h, !0), this.urlInfo.header && typeof this.urlInfo.header == "object" && Object.entries(this.urlInfo.header).forEach(([s, u]) => {
136
136
  t.setRequestHeader(s, u);
137
137
  }), this.urlInfo.authorize) {
138
- const s = F() ? b.getToken() : g().getToken();
138
+ const s = F() ? await b.getToken() : g().getToken();
139
139
  if (!s) {
140
140
  e(new Error("未授权或授权过期"));
141
141
  return;
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as d, useAttrs as f, createElementBlock as u, openBlock as x, createVNode as e, withCtx as n, unref as o, mergeProps as r, renderSlot as p } from "vue";
2
2
  import { Button as _ } from "ant-design-vue";
3
- import { a as P, _ as k } from "./toolIcon-BiWBb2pJ.js";
3
+ import { a as P, _ as k } from "./toolIcon-DHKszGtC.js";
4
4
  const C = /* @__PURE__ */ d({
5
5
  inheritAttrs: !1,
6
6
  __name: "index",
@@ -1,8 +1,8 @@
1
1
  import { defineComponent as F, provide as _, ref as w, watch as p, onMounted as B, createBlock as n, openBlock as r, unref as a, withCtx as i, createElementVNode as N, renderSlot as b, createVNode as V, createCommentVNode as d, createTextVNode as u, toDisplayString as v } from "vue";
2
- import { _ as m } from "./index-iozooZXX.js";
2
+ import { _ as m } from "./index-BqoqvtEv.js";
3
3
  import { Modal as D, Space as E } from "ant-design-vue";
4
4
  import "@skyfox2000/fapi";
5
- import { P as M, d as P, o as $, b as K } from "./uploadList-C_hqJ4X1.js";
5
+ import { P as M, d as P, o as $, b as K } from "./uploadList-DSN9t4r8.js";
6
6
  import "@skyfox2000/microbase";
7
7
  import "vue-m-message";
8
8
  import "async-validator";
@@ -1,10 +1,10 @@
1
1
  import H from "async-validator";
2
2
  import { httpPost as M, ResStatus as V } from "@skyfox2000/fapi";
3
- import { i as T, ai as U, L as $, u as z } from "./uploadList-C_hqJ4X1.js";
3
+ import { i as T, ai as U, L as $, u as z } from "./uploadList-DSN9t4r8.js";
4
4
  import m from "vue-m-message";
5
5
  import { defineComponent as _, useAttrs as B, createElementBlock as A, openBlock as b, createVNode as O, unref as v, mergeProps as S, computed as E, createBlock as R, withCtx as L, normalizeStyle as N } from "vue";
6
6
  import { Spin as K, Alert as P } from "ant-design-vue";
7
- import { _ as W } from "./toolIcon-BiWBb2pJ.js";
7
+ import { _ as W } from "./toolIcon-DHKszGtC.js";
8
8
  const D = (i) => {
9
9
  const e = i.split(`
10
10
  `).filter((l) => l.trim() !== "");
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as x, createBlock as h, createCommentVNode as I, openBlock as u, unref as t, mergeProps as C, useAttrs as H, computed as j, ref as y, watch as k, withCtx as d, createElementBlock as g, normalizeStyle as T, createElementVNode as m, inject as W, onMounted as N, createVNode as l, toDisplayString as $, Fragment as R, createTextVNode as K, reactive as q, nextTick as J, renderList as Y, withModifiers as G } from "vue";
2
- import { a as w, _ as b } from "./toolIcon-BiWBb2pJ.js";
3
- import { c as L, T as E, ah as P, W as M, V as U, u as D, ac as Q, a as F, U as X, r as V, af as z } from "./uploadList-C_hqJ4X1.js";
2
+ import { a as w, _ as b } from "./toolIcon-DHKszGtC.js";
3
+ import { c as L, T as E, ah as P, W as M, V as U, u as D, ac as Q, a as F, U as X, r as V, af as z } from "./uploadList-DSN9t4r8.js";
4
4
  import { _ as Z } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
5
  import { theme as O, Breadcrumb as ee, Modal as te, Flex as ne, LayoutHeader as oe, Space as se, Menu as ie, Tabs as ce, TabPane as ae } from "ant-design-vue";
6
6
  import { isMicroApp as le } from "@skyfox2000/microbase";
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as i, createBlock as s, openBlock as l, unref as a, withCtx as p, renderSlot as f, createCommentVNode as u, mergeProps as d } from "vue";
2
2
  import { Tooltip as I } from "ant-design-vue";
3
3
  import { SERVER_HOST as r } from "@skyfox2000/fapi";
4
- import { c as S } from "./uploadList-C_hqJ4X1.js";
4
+ import { c as S } from "./uploadList-DSN9t4r8.js";
5
5
  const T = /* @__PURE__ */ i({
6
6
  __name: "index",
7
7
  props: {
@@ -1,9 +1,9 @@
1
1
  import { defineComponent as Z, ref as L, computed as K, watch as P, resolveDirective as ee, createElementBlock as v, openBlock as m, normalizeClass as O, unref as n, createElementVNode as f, withDirectives as x, createBlock as te, mergeProps as oe, withCtx as y, createVNode as p, createTextVNode as E, toDisplayString as $, Fragment as ne, renderList as ae, createCommentVNode as S } from "vue";
2
- import { _ as se } from "./index-iozooZXX.js";
3
- import { a as z, _ as A } from "./toolIcon-BiWBb2pJ.js";
2
+ import { _ as se } from "./index-BqoqvtEv.js";
3
+ import { a as z, _ as A } from "./toolIcon-DHKszGtC.js";
4
4
  import { httpPost as R, ResStatus as D } from "@skyfox2000/fapi";
5
- import { L as V, u as Q, s as ie, _ as re } from "./uploadList-C_hqJ4X1.js";
6
- import { p as M, U as i } from "./file-upload-DicHRX1r.js";
5
+ import { L as V, u as Q, s as ie, _ as re } from "./uploadList-DSN9t4r8.js";
6
+ import { p as M, U as i } from "./file-upload-BrTPBL29.js";
7
7
  import { combineParams as q } from "@skyfox2000/microbase";
8
8
  import g from "vue-m-message";
9
9
  import "async-validator";
@@ -1,12 +1,12 @@
1
1
  var ha = Object.defineProperty;
2
2
  var ma = (e, t, a) => t in e ? ha(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a;
3
3
  var L = (e, t, a) => ma(e, typeof t != "symbol" ? t + "" : t, a);
4
- import { ref as f, h as H, nextTick as va, inject as se, provide as Me, watch as g, toRaw as Ze, shallowRef as Q, defineComponent as Z, reactive as ga, onMounted as Ie, onUnmounted as ie, createBlock as Ae, createCommentVNode as z, openBlock as w, unref as b, mergeProps as le, useAttrs as Ee, createElementBlock as $, createVNode as C, withCtx as K, createTextVNode as xe, toDisplayString as Y, Fragment as re, renderList as Ue, normalizeClass as ea, createElementVNode as ya } from "vue";
4
+ import { ref as f, h as H, nextTick as va, inject as se, provide as Me, watch as g, toRaw as Ze, shallowRef as J, defineComponent as Z, reactive as ga, onMounted as Ie, onUnmounted as le, createBlock as Ae, createCommentVNode as z, openBlock as w, unref as b, mergeProps as ue, useAttrs as Ee, createElementBlock as $, createVNode as C, withCtx as Q, createTextVNode as xe, toDisplayString as Y, Fragment as oe, renderList as Ue, normalizeClass as ea, createElementVNode as ya } from "vue";
5
5
  import { Switch as Sa, AutoComplete as ba, Input as Ia, CheckboxGroup as Aa, Checkbox as Ea, RadioGroup as xa, Radio as wa, Select as Oa, SelectOption as Ra } from "ant-design-vue";
6
- import { createPinia as Ta, defineStore as ue } from "pinia";
6
+ import { createPinia as Ta, defineStore as ce } from "pinia";
7
7
  import Pa from "pinia-plugin-persistedstate";
8
- import { EnvConfig as Se, AppAction as Be, AppSource as ze, isMicroApp as j, isBaseMicroApp as ka, combineParams as ce } from "@skyfox2000/microbase";
9
- import { httpPost as q, ResStatus as T, setToken as me, fieldMapping as La, parseFieldTemplate as be, API_HOST as $e, SERVER_HOST as Ma } from "@skyfox2000/fapi";
8
+ import { EnvConfig as Se, AppAction as Be, AppSource as ze, isMicroApp as V, isBaseMicroApp as ka, combineParams as fe } from "@skyfox2000/microbase";
9
+ import { httpPost as q, ResStatus as T, setToken as ve, fieldMapping as La, parseFieldTemplate as be, API_HOST as $e, SERVER_HOST as Ma } from "@skyfox2000/fapi";
10
10
  import E from "vue-m-message";
11
11
  import { createRouter as $a, createWebHashHistory as Fa } from "vue-router";
12
12
  import He from "async-validator";
@@ -110,7 +110,7 @@ N.setOptions("EnableDisable", N.EnableDisable);
110
110
  N.setOptions("SuccessResult", N.SuccessResult);
111
111
  N.setOptions("YesNo", N.YesNo);
112
112
  N.setOptions("MaleFemale", N.MaleFemale);
113
- const fe = {
113
+ const pe = {
114
114
  /**
115
115
  * 选项数据接口
116
116
  */
@@ -173,17 +173,17 @@ const fe = {
173
173
  type: Object,
174
174
  required: !1
175
175
  }
176
- }, F = (e) => e == null || e === "" ? !0 : Array.isArray(e) ? e.length === 0 : typeof e == "object" ? Object.keys(e).length === 0 : !1, Ce = "/login/", ge = [], Na = (e) => {
176
+ }, F = (e) => e == null || e === "" ? !0 : Array.isArray(e) ? e.length === 0 : typeof e == "object" ? Object.keys(e).length === 0 : !1, Ce = "/login/", ye = [], Na = (e) => {
177
177
  for (const t of e) {
178
- const a = ge.findIndex((s) => s.path === t.path);
179
- a !== -1 && ge.splice(a, 1), ge.push(t), we.addRoute(t);
178
+ const a = ye.findIndex((s) => s.path === t.path);
179
+ a !== -1 && ye.splice(a, 1), ye.push(t), we.addRoute(t);
180
180
  }
181
181
  }, aa = (e, t, a, s = "") => {
182
182
  const n = s + (s ? "/" : "") + e.path;
183
183
  t[n] = { ...e, parent: a }, e.children && e.children.forEach((o) => aa(o, t, e, n));
184
184
  }, we = $a({
185
185
  history: Fa("/"),
186
- routes: ge
186
+ routes: ye
187
187
  }), Da = (e, t) => {
188
188
  var n, o;
189
189
  const a = ((n = e.meta) == null ? void 0 : n.roles) ?? [], s = (o = e.meta) == null ? void 0 : o.permission;
@@ -209,7 +209,7 @@ we.beforeEach((e, t, a) => {
209
209
  return a();
210
210
  const n = s.meta, r = ((n == null ? void 0 : n.roles) ?? []).length > 0 || ((l = n == null ? void 0 : n.permission) == null ? void 0 : l.length);
211
211
  if (e.path === "/") {
212
- const u = V();
212
+ const u = K();
213
213
  if (!u.menuLoaded) {
214
214
  ne.value = {
215
215
  to: e,
@@ -229,7 +229,7 @@ we.beforeEach((e, t, a) => {
229
229
  if (!u.isLogin)
230
230
  a({ path: Ce });
231
231
  else {
232
- if (!V().menuLoaded) {
232
+ if (!K().menuLoaded) {
233
233
  ne.value = {
234
234
  to: e,
235
235
  next: a
@@ -253,7 +253,7 @@ const Ua = (e) => {
253
253
  return;
254
254
  t.TabPanes.push(e);
255
255
  }
256
- }, Va = (e, t) => t.find((a) => a.key === e), Ve = ue("pageInfo", {
256
+ }, Va = (e, t) => t.find((a) => a.key === e), Ve = ce("pageInfo", {
257
257
  state: () => ({
258
258
  TabActive: "",
259
259
  TabPanes: [],
@@ -266,7 +266,7 @@ const Ua = (e) => {
266
266
  */
267
267
  removeTabPane(e) {
268
268
  if (this.TabEnabled) {
269
- V().excludeComponent(e);
269
+ K().excludeComponent(e);
270
270
  let a = 0, s = [...this.TabPanes];
271
271
  for (let n = 0; n < s.length; n++)
272
272
  if (s[n].key === e) {
@@ -287,7 +287,7 @@ const Ua = (e) => {
287
287
  * @returns
288
288
  */
289
289
  async setTabActive(e) {
290
- let a = V().findRoute(e);
290
+ let a = K().findRoute(e);
291
291
  if (!a) return;
292
292
  const s = {
293
293
  key: e,
@@ -389,7 +389,7 @@ class A {
389
389
  }
390
390
  L(A, "messageId", 0), L(A, "callbacks", /* @__PURE__ */ new Map());
391
391
  A.init();
392
- const ye = {
392
+ const re = {
393
393
  getAppInfo: A.getAppInfo.bind(A),
394
394
  getHostInfo: A.getHostInfo.bind(A),
395
395
  getUserInfo: A.getUserInfo.bind(A),
@@ -430,7 +430,7 @@ const ye = {
430
430
  return s;
431
431
  }
432
432
  }
433
- }, V = ue("appInfo", {
433
+ }, K = ce("appInfo", {
434
434
  state: () => ({
435
435
  appInfo: {
436
436
  Id: "",
@@ -508,7 +508,7 @@ const ye = {
508
508
  flattenRoutes: {},
509
509
  Routes: t ?? [],
510
510
  defaultPage: ""
511
- }), (!j() || !ka()) && (await _().getRolePermits(a.Id), this.appInfo.Routes.length && this.setAppRoutes(this.appInfo.Routes)));
511
+ }), (!V() || !ka()) && (await _().getRolePermits(a.Id), this.appInfo.Routes.length && this.setAppRoutes(this.appInfo.Routes)));
512
512
  },
513
513
  /**
514
514
  * 设置当前应用路由信息
@@ -530,9 +530,9 @@ const ye = {
530
530
  }), _().isLogin) {
531
531
  const a = ta(this.appInfo.Routes);
532
532
  if (Na(a), this.appInfo.defaultPage = sa(a) || "", this.appInfo.defaultPage) {
533
- if (this.menuLoaded = !0, j()) {
533
+ if (this.menuLoaded = !0, V()) {
534
534
  const s = this.formatRoute(this.appInfo.defaultPage);
535
- ye.mainAppPush(s);
535
+ re.mainAppPush(s);
536
536
  }
537
537
  Ua(this.appInfo.defaultPage);
538
538
  }
@@ -553,9 +553,9 @@ const ye = {
553
553
  */
554
554
  push(e) {
555
555
  this.findRoute(e) && Ve().setTabActive(e), va(() => {
556
- if (we.push({ path: e }), j()) {
556
+ if (we.push({ path: e }), V()) {
557
557
  const a = this.formatRoute(e);
558
- ye.mainAppPush(a);
558
+ re.mainAppPush(a);
559
559
  }
560
560
  });
561
561
  },
@@ -623,7 +623,7 @@ const ye = {
623
623
  }, this.CachedComponents.splice(0, this.CachedComponents.length), this.ExcludeComponents.splice(0, this.ExcludeComponents.length), this.appList.splice(0, this.appList.length), this.menuLoaded = !1;
624
624
  },
625
625
  logout() {
626
- this.clean(), j() ? ye.mainAppPush("/") : window.location.assign("/");
626
+ this.clean(), V() ? re.mainAppPush("/") : window.location.assign("/");
627
627
  }
628
628
  },
629
629
  persist: !1
@@ -681,7 +681,7 @@ const ye = {
681
681
  } catch (t) {
682
682
  return console.error(Ja, t), !1;
683
683
  }
684
- }, M = f(""), ae = f(null), _ = ue("userInfo", {
684
+ }, M = f(""), ae = f(null), _ = ce("userInfo", {
685
685
  state: () => ({
686
686
  isLogin: !1,
687
687
  userInfo: {
@@ -699,7 +699,7 @@ const ye = {
699
699
  * 启动时初始化用户信息
700
700
  */
701
701
  init() {
702
- j() || (this.token ? (me(this.token), M.value = this.userInfo.UserLevel, this.isLogin = !0) : this.clean());
702
+ V() || (this.token ? (ve(this.token), M.value = this.userInfo.UserLevel, this.isLogin = !0) : this.clean());
703
703
  },
704
704
  /**
705
705
  * 登录操作
@@ -714,7 +714,7 @@ const ye = {
714
714
  return s;
715
715
  {
716
716
  const n = a.data;
717
- if (this.token = n.token, me(this.token), this.isLogin = !0, Wa(n))
717
+ if (this.token = n.token, ve(this.token), this.isLogin = !0, Wa(n))
718
718
  this.userInfo = {
719
719
  ...this.userInfo,
720
720
  ...n.UserInfo
@@ -723,7 +723,7 @@ const ye = {
723
723
  E.error("用户信息解析失败");
724
724
  return;
725
725
  }
726
- t && V().toDefaultApp();
726
+ t && K().toDefaultApp();
727
727
  }
728
728
  }
729
729
  },
@@ -784,7 +784,7 @@ const ye = {
784
784
  M.value || (M.value = e.UserLevel, this.userInfo = {
785
785
  ...this.userInfo,
786
786
  ...e
787
- }, this.token = t, me(this.token), this.isLogin = !0);
787
+ }, this.token = t, ve(this.token), this.isLogin = !0);
788
788
  },
789
789
  /**
790
790
  * 获取用户Token
@@ -822,7 +822,7 @@ const ye = {
822
822
  Code: "",
823
823
  TenantId: "",
824
824
  UserLevel: ""
825
- }, this.token = "", me(this.token), this.isLogin = !1, ae.value = null, M.value = "", V().clean(), Promise.resolve();
825
+ }, this.token = "", ve(this.token), this.isLogin = !1, ae.value = null, M.value = "", K().clean(), Promise.resolve();
826
826
  },
827
827
  /**
828
828
  * 登出操作
@@ -830,6 +830,8 @@ const ye = {
830
830
  * @returns
831
831
  */
832
832
  async logout(e) {
833
+ if (V())
834
+ return re.userLogout(), Promise.resolve();
833
835
  try {
834
836
  e && await qa();
835
837
  } catch (t) {
@@ -838,13 +840,13 @@ const ye = {
838
840
  await this.clean(), e && setTimeout(async () => {
839
841
  E.success("已退出登录");
840
842
  }, 1e3), setTimeout(async () => {
841
- V().logout();
843
+ K().logout();
842
844
  }, 2e3);
843
845
  }
844
846
  return Promise.resolve();
845
847
  }
846
848
  },
847
- persist: j() ? !1 : {
849
+ persist: V() ? !1 : {
848
850
  key: "MICROAPP_USER_INFO",
849
851
  storage: localStorage,
850
852
  pick: ["token", "userInfo"],
@@ -870,7 +872,7 @@ const ye = {
870
872
  return console.warn(o), Promise.reject(new Error(o));
871
873
  }
872
874
  s.api || (s.api = a.api), s.authorize === void 0 && (s.authorize = a.authorize);
873
- let n = ce(
875
+ let n = fe(
874
876
  JSON.parse(JSON.stringify(s.params ?? {})),
875
877
  JSON.parse(JSON.stringify(t.params ?? {}))
876
878
  );
@@ -908,11 +910,11 @@ const ye = {
908
910
  params: {},
909
911
  loadingState: e.isTreeLoading,
910
912
  loadingText: !1,
911
- processParams: () => ce(e.treeQuery, t)
913
+ processParams: () => fe(e.treeQuery, t)
912
914
  }).then((a) => (a == null ? void 0 : a.status) === T.SUCCESS ? (e.data.value = a.data || [], e.afterLoad && e.afterLoad(e.data.value), e.data.value) : (e.afterLoad && e.afterLoad((a == null ? void 0 : a.data) || []), []));
913
- let oe;
915
+ let ie;
914
916
  const Mt = (e) => {
915
- oe = new He({}), oe.messages({
917
+ ie = new He({}), ie.messages({
916
918
  required: "${label}不能为空",
917
919
  types: {
918
920
  number: "${label}必须是数字"
@@ -941,7 +943,7 @@ const Mt = (e) => {
941
943
  }, $t = (e) => {
942
944
  if (!e || F(e))
943
945
  return [];
944
- const t = [], a = oe.messages(), s = (o, r, l) => {
946
+ const t = [], a = ie.messages(), s = (o, r, l) => {
945
947
  const u = r.type;
946
948
  if (u && a.types && u in a.types) {
947
949
  const c = a.types[u];
@@ -992,11 +994,11 @@ const Mt = (e) => {
992
994
  rules: u
993
995
  });
994
996
  }), t;
995
- }, pe = async (e) => {
997
+ }, de = async (e) => {
996
998
  const t = e.formData.value, a = e.formRules.value;
997
- F(a) || (Je(e), e.ruleValidator || (e.ruleValidator = new He({}), e.ruleValidator.messages(oe.messages()), e.ruleValidator.define(a)), e.ruleResults.value = await e.ruleValidator.validate(t).then(() => {
999
+ F(a) || (Je(e), e.ruleValidator || (e.ruleValidator = new He({}), e.ruleValidator.messages(ie.messages()), e.ruleValidator.define(a)), e.ruleResults.value = await e.ruleValidator.validate(t).then(() => {
998
1000
  }).catch(({ fields: s }) => s));
999
- }, Ft = async (e, t, a) => (a || (a = new He({}), a.messages(oe.messages()), a.define(t)), a.validate(e).then(() => {
1001
+ }, Ft = async (e, t, a) => (a || (a = new He({}), a.messages(ie.messages()), a.define(t)), a.validate(e).then(() => {
1000
1002
  }).catch(({ fields: s }) => s)), Je = (e) => {
1001
1003
  e.ruleResults.value = void 0;
1002
1004
  }, X = () => {
@@ -1075,7 +1077,7 @@ const Mt = (e) => {
1075
1077
  const t = e.page;
1076
1078
  if (e.isFormSaving.value = !0, Je(e), e.beforeSave && e.beforeSave() === !1)
1077
1079
  return e.isFormSaving.value = !1, Promise.resolve();
1078
- if (e.formRules.value && await pe(e), e.ruleResults.value)
1080
+ if (e.formRules.value && await de(e), e.ruleResults.value)
1079
1081
  return E.error("提交表单时,验证失败!"), console.error("表单验证失败!", e.ruleResults.value), e.isFormSaving.value = !1, Promise.resolve();
1080
1082
  const a = e.formData.value;
1081
1083
  return na(
@@ -1168,7 +1170,7 @@ const Mt = (e) => {
1168
1170
  loadingState: e.isGridLoading,
1169
1171
  processParams: (a) => {
1170
1172
  var n;
1171
- return e.remotePage && (a.Query.$limit = [(e.pageNo.value - 1) * e.pageSize.value, e.pageSize.value]), ce((n = e.gridUrl) == null ? void 0 : n.params, a, e.gridQuery);
1173
+ return e.remotePage && (a.Query.$limit = [(e.pageNo.value - 1) * e.pageSize.value, e.pageSize.value]), fe((n = e.gridUrl) == null ? void 0 : n.params, a, e.gridQuery);
1172
1174
  }
1173
1175
  }).then((a) => {
1174
1176
  if ((a == null ? void 0 : a.status) === T.SUCCESS) {
@@ -1303,11 +1305,11 @@ const B = new et(), ee = (e, t, a) => {
1303
1305
  }), e.options.value = t;
1304
1306
  }, at = (e, t, a) => {
1305
1307
  Array.isArray(a) ? Ge(t, a, !0) : ua(e, t, a);
1306
- }, de = (e, t) => {
1308
+ }, he = (e, t) => {
1307
1309
  var a;
1308
1310
  (a = e.inputFactory) != null && a.value && t.reloadEvent && e.inputFactory.value.reloadHandler && B.off(t.reloadEvent, e.inputFactory.value.reloadHandler);
1309
1311
  }, ua = (e, t, a) => {
1310
- const s = JSON.parse(JSON.stringify(e.params ?? {})), n = JSON.parse(JSON.stringify(t.params ?? {})), o = ce(s, n, a);
1312
+ const s = JSON.parse(JSON.stringify(e.params ?? {})), n = JSON.parse(JSON.stringify(t.params ?? {})), o = fe(s, n, a);
1311
1313
  tt(e, t, t.fieldMap, o).then((r) => {
1312
1314
  Ge(t, r, !1);
1313
1315
  });
@@ -1395,7 +1397,7 @@ const B = new et(), ee = (e, t, a) => {
1395
1397
  }, ke = (e, t, a) => {
1396
1398
  var o, r;
1397
1399
  const s = (o = e.inputFactory) == null ? void 0 : o.value;
1398
- s != null && s.editorCtrl && ((r = s.errInfo) != null && r.value.errClass) && pe(s.editorCtrl), e.selected.value = a;
1400
+ s != null && s.editorCtrl && ((r = s.errInfo) != null && r.value.errClass) && de(s.editorCtrl), e.selected.value = a;
1399
1401
  const n = st(a, e.options.value);
1400
1402
  if (e.selectedOptions.value = n, t.formData && t.outFields && ca(t.formData, t.outFields, n), t.changeEvent) {
1401
1403
  const [l, u] = t.changeEvent;
@@ -1517,7 +1519,7 @@ const B = new et(), ee = (e, t, a) => {
1517
1519
  selectRows: f([]),
1518
1520
  rowData: f(void 0),
1519
1521
  gridQuery: {},
1520
- tableData: Q(void 0),
1522
+ tableData: J(void 0),
1521
1523
  expandRows: f({}),
1522
1524
  isGridLoading: f(!1),
1523
1525
  isGridSaving: f(!1),
@@ -1543,7 +1545,7 @@ const B = new et(), ee = (e, t, a) => {
1543
1545
  page: t,
1544
1546
  node: f(void 0),
1545
1547
  url: e.urls.tree,
1546
- data: Q(void 0),
1548
+ data: J(void 0),
1547
1549
  isTreeLoading: f(!1)
1548
1550
  };
1549
1551
  return g(
@@ -1556,13 +1558,13 @@ const B = new et(), ee = (e, t, a) => {
1556
1558
  ), {
1557
1559
  treeCtrl: a
1558
1560
  };
1559
- }, he = (e, t) => {
1561
+ }, me = (e, t) => {
1560
1562
  const a = {
1561
1563
  ...S.OptionOption,
1562
1564
  url: e,
1563
1565
  reload: f(!1),
1564
1566
  optionQuery: {},
1565
- data: Q([]),
1567
+ data: J([]),
1566
1568
  selected: f([]),
1567
1569
  selectedOptions: f([]),
1568
1570
  options: f([]),
@@ -1635,21 +1637,21 @@ const B = new et(), ee = (e, t, a) => {
1635
1637
  ), g(
1636
1638
  () => u.value,
1637
1639
  (c) => {
1638
- o.icons && (c >= o.icons.length && (u.value = 0), l.value = o.icons[u.value], ve(a, l, l.value), r("update:iconIndex", u.value));
1640
+ o.icons && (c >= o.icons.length && (u.value = 0), l.value = o.icons[u.value], ge(a, l, l.value), r("update:iconIndex", u.value));
1639
1641
  },
1640
1642
  { immediate: !0 }
1641
1643
  ), g(
1642
1644
  () => G.value,
1643
1645
  () => {
1644
- ve(a, l, l.value);
1646
+ ge(a, l, l.value);
1645
1647
  },
1646
1648
  { deep: !0 }
1647
1649
  ), g(
1648
1650
  () => o.icon,
1649
1651
  (c) => {
1650
- ve(a, l, c);
1652
+ ge(a, l, c);
1651
1653
  }
1652
- ), ve(a, l, l.value), { isLoaded: t, Icon: a, handleClick: i };
1654
+ ), ge(a, l, l.value), { isLoaded: t, Icon: a, handleClick: i };
1653
1655
  },
1654
1656
  render() {
1655
1657
  if (!t.value)
@@ -1733,7 +1735,7 @@ const B = new et(), ee = (e, t, a) => {
1733
1735
  const a = localStorage.getItem(t);
1734
1736
  a && JSON.parse(a).expireTime < e && localStorage.removeItem(t);
1735
1737
  }
1736
- }, ve = (e, t, a) => {
1738
+ }, ge = (e, t, a) => {
1737
1739
  setTimeout(() => {
1738
1740
  t.value = a, t.value && (e.value = G.value[t.value]);
1739
1741
  }, 1);
@@ -1795,7 +1797,7 @@ const B = new et(), ee = (e, t, a) => {
1795
1797
  return n;
1796
1798
  }, Xe = ga([]), es = () => {
1797
1799
  Xe.length = 0;
1798
- const e = V();
1800
+ const e = K();
1799
1801
  let a = Ve().TabActive;
1800
1802
  e.matchedRoutes(a).forEach((n, o) => {
1801
1803
  var l;
@@ -1818,7 +1820,7 @@ const B = new et(), ee = (e, t, a) => {
1818
1820
  // 不显示错误
1819
1821
  hideErrorToast: !0
1820
1822
  }
1821
- }, as = ue("hostInfo", {
1823
+ }, as = ce("hostInfo", {
1822
1824
  state: () => ({
1823
1825
  hostInfo: {
1824
1826
  Host: "",
@@ -1842,8 +1844,8 @@ const B = new et(), ee = (e, t, a) => {
1842
1844
  * @param hostKey 站点信息,默认为当前主域名
1843
1845
  */
1844
1846
  async loadHostInfo(e, t) {
1845
- if (j()) {
1846
- const s = await ye.getHostInfo();
1847
+ if (V()) {
1848
+ const s = await re.getHostInfo();
1847
1849
  this._setHostInfo(s);
1848
1850
  return;
1849
1851
  }
@@ -1908,7 +1910,7 @@ const B = new et(), ee = (e, t, a) => {
1908
1910
  // storage: localStorage,
1909
1911
  // pick: ['hostInfo'],
1910
1912
  // },
1911
- }), ts = ue("settingInfo", {
1913
+ }), ts = ce("settingInfo", {
1912
1914
  state: () => ({
1913
1915
  fullscreen: !1,
1914
1916
  menuCollapse: !1,
@@ -1953,7 +1955,7 @@ const B = new et(), ee = (e, t, a) => {
1953
1955
  }), ss = /* @__PURE__ */ Z({
1954
1956
  __name: "index",
1955
1957
  props: {
1956
- ...fe,
1958
+ ...pe,
1957
1959
  /**
1958
1960
  * 选择项数据
1959
1961
  */
@@ -1964,8 +1966,8 @@ const B = new et(), ee = (e, t, a) => {
1964
1966
  },
1965
1967
  emits: ["change"],
1966
1968
  setup(e, { emit: t }) {
1967
- const a = e, s = X(), n = he(a.url, a), o = a.optionCtrl ?? n.optionCtrl;
1968
- o.inputFactory = Q(s);
1969
+ const a = e, s = X(), n = me(a.url, a), o = a.optionCtrl ?? n.optionCtrl;
1970
+ o.inputFactory = J(s);
1969
1971
  const r = f([]);
1970
1972
  o && g(
1971
1973
  () => o.options.value,
@@ -1975,7 +1977,7 @@ const B = new et(), ee = (e, t, a) => {
1975
1977
  { immediate: !0, deep: !0 }
1976
1978
  );
1977
1979
  const l = t, { editorCtrl: u, errInfo: i } = X(), c = (p) => {
1978
- i != null && i.value.errClass && u && pe(u), l("change", p);
1980
+ i != null && i.value.errClass && u && de(u), l("change", p);
1979
1981
  };
1980
1982
  return Ie(() => {
1981
1983
  if (!a.data || a.data.length != 2) {
@@ -1983,11 +1985,11 @@ const B = new et(), ee = (e, t, a) => {
1983
1985
  return;
1984
1986
  }
1985
1987
  o && ee(o.autoload, o, a);
1986
- }), ie(() => {
1987
- o && de(o, a);
1988
+ }), le(() => {
1989
+ o && he(o, a);
1988
1990
  }), (p, v) => {
1989
1991
  var d;
1990
- return r.value.length === 2 ? (w(), Ae(b(Sa), le({
1992
+ return r.value.length === 2 ? (w(), Ae(b(Sa), ue({
1991
1993
  key: 0,
1992
1994
  class: [
1993
1995
  ((d = b(i)) == null ? void 0 : d.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : "",
@@ -2006,7 +2008,7 @@ const B = new et(), ee = (e, t, a) => {
2006
2008
  inheritAttrs: !1,
2007
2009
  __name: "index",
2008
2010
  props: {
2009
- ...fe,
2011
+ ...pe,
2010
2012
  value: {
2011
2013
  type: [String, Number, Array, null],
2012
2014
  default: void 0
@@ -2023,8 +2025,8 @@ const B = new et(), ee = (e, t, a) => {
2023
2025
  },
2024
2026
  emits: ["update:value", "select", "change", "update:labels"],
2025
2027
  setup(e, { emit: t }) {
2026
- const a = e, s = Ee(), n = X(), o = he(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2027
- r.inputFactory = Q(n), r.fieldMap = {
2028
+ const a = e, s = Ee(), n = X(), o = me(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2029
+ r.inputFactory = J(n), r.fieldMap = {
2028
2030
  label: "Name",
2029
2031
  value: "Id",
2030
2032
  ...r == null ? void 0 : r.fieldMap
@@ -2059,19 +2061,19 @@ const B = new et(), ee = (e, t, a) => {
2059
2061
  SearchField: "%" + y.trim() + "%"
2060
2062
  }
2061
2063
  };
2062
- r.params = ce(r.params, h), r && ee(!0, r, a);
2064
+ r.params = fe(r.params, h), r && ee(!0, r, a);
2063
2065
  }, O = (y) => {
2064
2066
  const x = ke(r, a, y);
2065
2067
  p("update:value", y), p("select", y);
2066
2068
  const h = Pe(x);
2067
- p("update:labels", h), i != null && i.value.errClass && u && pe(u);
2069
+ p("update:labels", h), i != null && i.value.errClass && u && de(u);
2068
2070
  };
2069
- return ie(() => {
2070
- r && de(r, a);
2071
+ return le(() => {
2072
+ r && he(r, a);
2071
2073
  }), (y, x) => {
2072
2074
  var h;
2073
2075
  return w(), $("div", null, [
2074
- C(b(ba), le({
2076
+ C(b(ba), ue({
2075
2077
  value: l.value,
2076
2078
  "onUpdate:value": x[0] || (x[0] = (I) => l.value = I),
2077
2079
  class: ["w-full", (h = b(i)) == null ? void 0 : h.errClass],
@@ -2079,10 +2081,10 @@ const B = new et(), ee = (e, t, a) => {
2079
2081
  onSearch: d,
2080
2082
  onSelect: O
2081
2083
  }, b(s), { "allow-clear": !1 }), {
2082
- option: K(({ label: I }) => [
2084
+ option: Q(({ label: I }) => [
2083
2085
  xe(Y(I), 1)
2084
2086
  ]),
2085
- default: K(() => [
2087
+ default: Q(() => [
2086
2088
  C(b(Ia), {
2087
2089
  "allow-clear": "",
2088
2090
  placeholder: "请输入并选择" + b(c)
@@ -2100,7 +2102,7 @@ const B = new et(), ee = (e, t, a) => {
2100
2102
  inheritAttrs: !1,
2101
2103
  __name: "index",
2102
2104
  props: {
2103
- ...fe,
2105
+ ...pe,
2104
2106
  nodata: {
2105
2107
  type: String,
2106
2108
  default: ""
@@ -2118,8 +2120,8 @@ const B = new et(), ee = (e, t, a) => {
2118
2120
  emits: ["change", "update:labels"],
2119
2121
  setup(e, { emit: t }) {
2120
2122
  var v, d, O;
2121
- const a = e, s = Ee(), n = X(), o = he(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2122
- r.inputFactory = Q(n);
2123
+ const a = e, s = Ee(), n = X(), o = me(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2124
+ r.inputFactory = J(n);
2123
2125
  const l = f({
2124
2126
  ...r == null ? void 0 : r.url,
2125
2127
  url: ((v = r == null ? void 0 : r.url) == null ? void 0 : v.url) || "",
@@ -2147,15 +2149,15 @@ const B = new et(), ee = (e, t, a) => {
2147
2149
  value: "Id",
2148
2150
  key: "Id"
2149
2151
  }), r && ee(r.autoload, r, a);
2150
- }), ie(() => {
2151
- r && de(r, a);
2152
+ }), le(() => {
2153
+ r && he(r, a);
2152
2154
  }), (y, x) => (w(), $("div", ht, [
2153
- C(b(Aa), le({
2155
+ C(b(Aa), ue({
2154
2156
  onChange: p,
2155
2157
  class: "w-full mb-[-3px]"
2156
2158
  }, b(s)), {
2157
- default: K(() => [
2158
- c.value.length > 0 ? (w(!0), $(re, { key: 0 }, Ue(c.value, (h) => {
2159
+ default: Q(() => [
2160
+ c.value.length > 0 ? (w(!0), $(oe, { key: 0 }, Ue(c.value, (h) => {
2159
2161
  var I;
2160
2162
  return w(), Ae(b(Ea), {
2161
2163
  key: h.value,
@@ -2168,7 +2170,7 @@ const B = new et(), ee = (e, t, a) => {
2168
2170
  e.wrap ? `w-1/${a.wrap}` : ""
2169
2171
  ])
2170
2172
  }, {
2171
- default: K(() => [
2173
+ default: Q(() => [
2172
2174
  xe(Y(h.label), 1)
2173
2175
  ]),
2174
2176
  _: 2
@@ -2186,7 +2188,7 @@ const B = new et(), ee = (e, t, a) => {
2186
2188
  inheritAttrs: !1,
2187
2189
  __name: "index",
2188
2190
  props: {
2189
- ...fe,
2191
+ ...pe,
2190
2192
  value: {
2191
2193
  type: [String, Number, null, Array],
2192
2194
  default: void 0
@@ -2205,8 +2207,8 @@ const B = new et(), ee = (e, t, a) => {
2205
2207
  emits: ["change", "update:value", "update:labels"],
2206
2208
  setup(e, { emit: t }) {
2207
2209
  var O, y, x;
2208
- const a = e, s = Ee(), n = X(), o = he(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2209
- r.inputFactory = Q(n);
2210
+ const a = e, s = Ee(), n = X(), o = me(a.url, a), r = a.optionCtrl ?? o.optionCtrl;
2211
+ r.inputFactory = J(n);
2210
2212
  const l = f({
2211
2213
  ...r == null ? void 0 : r.url,
2212
2214
  url: ((O = r == null ? void 0 : r.url) == null ? void 0 : O.url) || "",
@@ -2238,8 +2240,8 @@ const B = new et(), ee = (e, t, a) => {
2238
2240
  }
2239
2241
  return h === I;
2240
2242
  }, d = (h) => {
2241
- const I = h.target.value, R = ke(r, a, I), J = Pe(R);
2242
- p("update:labels", J);
2243
+ const I = h.target.value, R = ke(r, a, I), j = Pe(R);
2244
+ p("update:labels", j);
2243
2245
  };
2244
2246
  return Ie(() => {
2245
2247
  l.value && !l.value.fieldMap && (l.value.fieldMap = {
@@ -2247,20 +2249,20 @@ const B = new et(), ee = (e, t, a) => {
2247
2249
  value: "Id",
2248
2250
  key: "Id"
2249
2251
  }), r && ee(r.autoload, r, a);
2250
- }), ie(() => {
2251
- r && de(r, a);
2252
+ }), le(() => {
2253
+ r && he(r, a);
2252
2254
  }), (h, I) => (w(), $("div", vt, [
2253
- C(b(xa), le({
2255
+ C(b(xa), ue({
2254
2256
  value: u.value,
2255
2257
  "onUpdate:value": I[0] || (I[0] = (R) => u.value = R),
2256
2258
  autocheck: !1,
2257
2259
  onChange: d,
2258
2260
  class: "w-full flex align-items flex-wrap mb-[-3px]"
2259
2261
  }, b(s)), {
2260
- default: K(() => [
2261
- c.value.length > 0 ? (w(!0), $(re, { key: 0 }, Ue(c.value, (R) => {
2262
- var J;
2263
- return w(), $(re, {
2262
+ default: Q(() => [
2263
+ c.value.length > 0 ? (w(!0), $(oe, { key: 0 }, Ue(c.value, (R) => {
2264
+ var j;
2265
+ return w(), $(oe, {
2264
2266
  key: R.value
2265
2267
  }, [
2266
2268
  R.visible !== !1 ? (w(), Ae(b(wa), {
@@ -2268,13 +2270,13 @@ const B = new et(), ee = (e, t, a) => {
2268
2270
  checked: v(R.value, a.value),
2269
2271
  value: R.value,
2270
2272
  class: ea([
2271
- ((J = b(i)) == null ? void 0 : J.errClass) === "error" ? "error !text-red-400" : "",
2273
+ ((j = b(i)) == null ? void 0 : j.errClass) === "error" ? "error !text-red-400" : "",
2272
2274
  "text-nowrap",
2273
2275
  "pb-1",
2274
2276
  e.wrap ? `w-1/${a.wrap}` : ""
2275
2277
  ])
2276
2278
  }, {
2277
- default: K(() => [
2279
+ default: Q(() => [
2278
2280
  xe(Y(R.label), 1)
2279
2281
  ]),
2280
2282
  _: 2
@@ -2293,7 +2295,7 @@ const B = new et(), ee = (e, t, a) => {
2293
2295
  inheritAttrs: !1,
2294
2296
  __name: "index",
2295
2297
  props: {
2296
- ...fe,
2298
+ ...pe,
2297
2299
  value: {
2298
2300
  type: [String, Number, Array, null],
2299
2301
  default: void 0
@@ -2324,20 +2326,20 @@ const B = new et(), ee = (e, t, a) => {
2324
2326
  },
2325
2327
  emits: ["change", "update:value", "update:label", "update:labels"],
2326
2328
  setup(e, { emit: t }) {
2327
- var I, R, J;
2328
- const a = e, s = a.value === void 0 ? !0 : a.undefValue, n = X(), { editorCtrl: o, errInfo: r, labelText: l } = n, u = he(a.url, a), i = a.optionCtrl ?? u.optionCtrl;
2329
- i.inputFactory = Q(n);
2329
+ var I, R, j;
2330
+ const a = e, s = a.value === void 0 ? !0 : a.undefValue, n = X(), { editorCtrl: o, errInfo: r, labelText: l } = n, u = me(a.url, a), i = a.optionCtrl ?? u.optionCtrl;
2331
+ i.inputFactory = J(n);
2330
2332
  const c = Ee(), p = f({
2331
2333
  ...i == null ? void 0 : i.url,
2332
2334
  url: ((I = i == null ? void 0 : i.url) == null ? void 0 : I.url) || "",
2333
2335
  fieldMap: (i == null ? void 0 : i.fieldMap) || ((R = i == null ? void 0 : i.url) == null ? void 0 : R.fieldMap),
2334
- params: (i == null ? void 0 : i.params) || ((J = i == null ? void 0 : i.url) == null ? void 0 : J.params),
2336
+ params: (i == null ? void 0 : i.params) || ((j = i == null ? void 0 : i.url) == null ? void 0 : j.params),
2335
2337
  loadingText: !1
2336
2338
  }), v = f(c.placeholder), d = f(i == null ? void 0 : i.selected.value), O = t;
2337
2339
  n.inputEmit = O;
2338
2340
  const y = (m) => {
2339
2341
  const k = ke(i, a, m), D = Pe(k);
2340
- d.value = m, O("update:labels", D), O("update:label", D.join(";")), O("change", m), r != null && r.value.errClass && o && pe(o);
2342
+ d.value = m, O("update:labels", D), O("update:label", D.join(";")), O("change", m), r != null && r.value.errClass && o && de(o);
2341
2343
  }, x = f((i == null ? void 0 : i.options.value) || []), h = (m) => {
2342
2344
  if (m.length > 0 && F(a.value) && a.selectFirst)
2343
2345
  for (let k = 0; k < m.length; k++) {
@@ -2396,8 +2398,8 @@ const B = new et(), ee = (e, t, a) => {
2396
2398
  const m = i.options.value || [];
2397
2399
  m.length > 0 ? (x.value = m, h(m)) : ee(i.autoload, i, a);
2398
2400
  }
2399
- }), ie(() => {
2400
- i && de(i, a);
2401
+ }), le(() => {
2402
+ i && he(i, a);
2401
2403
  }), (m, k) => {
2402
2404
  var D, qe, We;
2403
2405
  return w(), $("div", null, [
@@ -2405,7 +2407,7 @@ const B = new et(), ee = (e, t, a) => {
2405
2407
  C(b(De), { class: "text-[#555] mx-[5px] !ml-[10px] !w-4 !h-4" }),
2406
2408
  k[1] || (k[1] = ya("span", null, "数据加载中...", -1))
2407
2409
  ])) : z("", !0),
2408
- C(b(Oa), le({
2410
+ C(b(Oa), ue({
2409
2411
  class: [(We = b(r)) == null ? void 0 : We.errClass, "w-full"],
2410
2412
  value: d.value,
2411
2413
  "onUpdate:value": k[0] || (k[0] = (W) => d.value = W),
@@ -2414,15 +2416,15 @@ const B = new et(), ee = (e, t, a) => {
2414
2416
  placeholder: v.value,
2415
2417
  "label-in-value": !1
2416
2418
  }, b(c)), {
2417
- default: K(() => [
2418
- (w(!0), $(re, null, Ue(x.value, (W) => (w(), $(re, {
2419
+ default: Q(() => [
2420
+ (w(!0), $(oe, null, Ue(x.value, (W) => (w(), $(oe, {
2419
2421
  key: W.value
2420
2422
  }, [
2421
2423
  W.visible !== !1 ? (w(), Ae(b(Ra), {
2422
2424
  key: 0,
2423
2425
  value: W.value
2424
2426
  }, {
2425
- default: K(() => [
2427
+ default: Q(() => [
2426
2428
  xe(Y(W.label), 1)
2427
2429
  ]),
2428
2430
  _: 2
@@ -2437,7 +2439,7 @@ const B = new et(), ee = (e, t, a) => {
2437
2439
  });
2438
2440
  export {
2439
2441
  Mt as $,
2440
- pe as A,
2442
+ de as A,
2441
2443
  rs as B,
2442
2444
  os as C,
2443
2445
  is as D,
@@ -2477,13 +2479,13 @@ export {
2477
2479
  Ba as a9,
2478
2480
  Ne as aa,
2479
2481
  B as ab,
2480
- ye as ac,
2482
+ re as ac,
2481
2483
  ne as ad,
2482
- ge as ae,
2483
- V as af,
2484
+ ye as ae,
2485
+ K as af,
2484
2486
  as as ag,
2485
2487
  Ve as ah,
2486
- oe as ai,
2488
+ ie as ai,
2487
2489
  Dt as b,
2488
2490
  Yt as c,
2489
2491
  Ut as d,
@@ -2498,14 +2500,14 @@ export {
2498
2500
  Jt as m,
2499
2501
  ns as n,
2500
2502
  Nt as o,
2501
- fe as p,
2503
+ pe as p,
2502
2504
  za as q,
2503
2505
  we as r,
2504
2506
  X as s,
2505
- he as t,
2507
+ me as t,
2506
2508
  _ as u,
2507
2509
  ee as v,
2508
- de as w,
2510
+ he as w,
2509
2511
  De as x,
2510
2512
  ke as y,
2511
2513
  Pe as z
@@ -1,13 +1,13 @@
1
1
  import { defineComponent as F, defineAsyncComponent as M, ref as m, watch as V, onMounted as J, createElementBlock as x, openBlock as p, Fragment as K, createElementVNode as v, createVNode as _, toDisplayString as W, unref as i, createBlock as P, withKeys as f, normalizeClass as N, withModifiers as w, withCtx as z, createCommentVNode as L } from "vue";
2
2
  import "ant-design-vue";
3
- import { _ as q } from "../../assets/modules/toolIcon-BiWBb2pJ.js";
3
+ import { _ as q } from "../../assets/modules/toolIcon-DHKszGtC.js";
4
4
  import "@skyfox2000/fapi";
5
- import "../../assets/modules/uploadList-C_hqJ4X1.js";
5
+ import "../../assets/modules/uploadList-DSN9t4r8.js";
6
6
  import "@skyfox2000/microbase";
7
7
  import "vue-m-message";
8
8
  import "async-validator";
9
9
  import "dayjs";
10
- import { _ as D } from "../../assets/modules/index-BURe9YrF.js";
10
+ import { _ as D } from "../../assets/modules/index-DP1u2P1k.js";
11
11
  import "vue-draggable-next";
12
12
  const h = async (s) => window.ace ? window.ace : new Promise((l, t) => {
13
13
  const o = document.createElement("script");
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as f, ref as d, watch as _, onMounted as v, resolveComponent as h, createBlock as o, openBlock as t, withCtx as s, createElementVNode as C, normalizeClass as x, createVNode as w, KeepAlive as y, unref as n, resolveDynamicComponent as I } from "vue";
2
- import { _ as g } from "../../assets/modules/baseLayout-BT7tGUB1.js";
3
- import { af as A, a as S } from "../../assets/modules/uploadList-C_hqJ4X1.js";
2
+ import { _ as g } from "../../assets/modules/baseLayout-CUZpKmC0.js";
3
+ import { af as A, a as S } from "../../assets/modules/uploadList-DSN9t4r8.js";
4
4
  import "@skyfox2000/microbase";
5
5
  import "@skyfox2000/fapi";
6
6
  import b from "vue-m-message";
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as i, createBlock as p, openBlock as m, unref as r, withCtx as e, createVNode as n, createTextVNode as a } from "vue";
2
- import { r as s } from "../../assets/modules/uploadList-C_hqJ4X1.js";
2
+ import { r as s } from "../../assets/modules/uploadList-DSN9t4r8.js";
3
3
  import "@skyfox2000/microbase";
4
4
  import "@skyfox2000/fapi";
5
5
  import "vue-m-message";
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as i, createBlock as p, openBlock as m, unref as r, withCtx as e, createVNode as n, createTextVNode as a } from "vue";
2
- import { r as s } from "../../assets/modules/uploadList-C_hqJ4X1.js";
2
+ import { r as s } from "../../assets/modules/uploadList-DSN9t4r8.js";
3
3
  import "@skyfox2000/microbase";
4
4
  import "@skyfox2000/fapi";
5
5
  import "vue-m-message";
@@ -1,12 +1,12 @@
1
1
  import { defineComponent as we, ref as f, computed as T, watch as W, onMounted as be, createBlock as H, openBlock as d, unref as n, withCtx as S, renderSlot as J, createElementBlock as g, createCommentVNode as K, createElementVNode as h, createVNode as C, createTextVNode as X, toDisplayString as E, normalizeClass as Ce, Fragment as ie, renderList as ne } from "vue";
2
- import { _ as Y } from "../../assets/modules/index-iozooZXX.js";
2
+ import { _ as Y } from "../../assets/modules/index-BqoqvtEv.js";
3
3
  import { Modal as Fe, Upload as ue, Space as _e } from "ant-design-vue";
4
4
  import { httpGet as Ue, ResStatus as fe } from "@skyfox2000/fapi";
5
- import { E as Te, a2 as Se, a8 as Ee } from "../../assets/modules/uploadList-C_hqJ4X1.js";
6
- import { A as Re, p as De, U as ce } from "../../assets/modules/file-upload-DicHRX1r.js";
5
+ import { E as Te, a2 as Se, a8 as Ee } from "../../assets/modules/uploadList-DSN9t4r8.js";
6
+ import { A as Re, p as De, U as ce } from "../../assets/modules/file-upload-BrTPBL29.js";
7
7
  import "@skyfox2000/microbase";
8
8
  import p from "vue-m-message";
9
- import { c as ke, _ as Z, h as Le, p as Ne, i as Ke } from "../../assets/modules/index-BjXLzCF2.js";
9
+ import { c as ke, _ as Z, h as Le, p as Ne, i as Ke } from "../../assets/modules/index-NDOzpgzV.js";
10
10
  import "dayjs";
11
11
  import "vue-draggable-next";
12
12
  import "async-validator";
@@ -306,7 +306,7 @@ const Be = (l) => l.includes(",") || l.includes(`
306
306
  return p.error(v), ue.LIST_IGNORE;
307
307
  try {
308
308
  if (A(), y.value = t.name, q.value = u ? "text/csv" : "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", u) {
309
- const w = await t.arrayBuffer(), O = new TextDecoder("utf-8").decode(w), { csvToExcelView: G } = await import("../../assets/modules/index-BjXLzCF2.js").then((he) => he.j), M = await G(O, t.name);
309
+ const w = await t.arrayBuffer(), O = new TextDecoder("utf-8").decode(w), { csvToExcelView: G } = await import("../../assets/modules/index-NDOzpgzV.js").then((he) => he.j), M = await G(O, t.name);
310
310
  if (!M.success)
311
311
  throw new Error(M.error || "CSV文件处理失败");
312
312
  const oe = await (await fetch(M.blobUrl)).arrayBuffer();
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as f, ref as d, watch as _, onMounted as v, resolveComponent as h, createBlock as o, openBlock as t, withCtx as s, createElementVNode as C, normalizeClass as x, createVNode as w, KeepAlive as I, unref as n, resolveDynamicComponent as g } from "vue";
2
- import { _ as y } from "../../assets/modules/baseLayout-BT7tGUB1.js";
3
- import { af as A, a as S } from "../../assets/modules/uploadList-C_hqJ4X1.js";
2
+ import { _ as y } from "../../assets/modules/baseLayout-CUZpKmC0.js";
3
+ import { af as A, a as S } from "../../assets/modules/uploadList-DSN9t4r8.js";
4
4
  import "@skyfox2000/microbase";
5
5
  import "@skyfox2000/fapi";
6
6
  import k from "vue-m-message";
@@ -1,15 +1,15 @@
1
1
  import { defineComponent as y, ref as f, watch as S, onMounted as z, createBlock as D, openBlock as F, unref as u, withCtx as s, createVNode as m, createTextVNode as C } from "vue";
2
- import { _ as c } from "../../assets/modules/index-iozooZXX.js";
2
+ import { _ as c } from "../../assets/modules/index-BqoqvtEv.js";
3
3
  import { Modal as _, Space as k } from "ant-design-vue";
4
4
  import { ResStatus as E } from "@skyfox2000/fapi";
5
- import { a4 as h } from "../../assets/modules/uploadList-C_hqJ4X1.js";
5
+ import { a4 as h } from "../../assets/modules/uploadList-DSN9t4r8.js";
6
6
  import "@skyfox2000/microbase";
7
7
  import L from "vue-m-message";
8
8
  import "async-validator";
9
9
  import "dayjs";
10
- import { A as N } from "../../assets/modules/file-upload-DicHRX1r.js";
10
+ import { A as N } from "../../assets/modules/file-upload-BrTPBL29.js";
11
11
  import "vue-draggable-next";
12
- import { U as B } from "../../assets/modules/uploadList-61wZlPUk.js";
12
+ import { U as B } from "../../assets/modules/uploadList-C5R2XD5x.js";
13
13
  const K = /* @__PURE__ */ y({
14
14
  __name: "uploadForm",
15
15
  props: {
package/lib/webui.es.js CHANGED
@@ -1,6 +1,6 @@
1
- import { u as Ee, i as Z, a as me, L as Xe, c as Ze, P as j, o as Pe, b as ea, d as aa, e as Fe, r as ce, f as ta, g as la, h as Ne, j as sa, k as ke, l as ra, _ as oa, m as na, O as Me, q as Be, n as ia, p as ca, s as L, t as ua, v as da, w as pa, x as fa, y as va, z as ma, A as Y, B as ha, C as ga, D as ba, E as Re } from "./assets/modules/uploadList-C_hqJ4X1.js";
2
- import { aa as $l, Q as Il, ac as Dl, R as El, V as Pl, a9 as Fl, a7 as Nl, a8 as Ml, ab as Bl, Y as Rl, T as Ol, a5 as Al, a2 as Ll, M as zl, a4 as Ul, U as Vl, G as Yl, $ as Kl, a3 as Wl, a6 as Hl, N as jl, S as Ql, ad as ql, F as Gl, a1 as Jl, ae as Xl, X as Zl, Z as es, W as as, af as ts, H as ls, I as ss, ag as rs, K as os, ah as ns, J as is, a0 as cs } from "./assets/modules/uploadList-C_hqJ4X1.js";
3
- import { A as ds, U as ps, p as fs } from "./assets/modules/file-upload-DicHRX1r.js";
1
+ import { u as Ee, i as Z, a as me, L as Xe, c as Ze, P as j, o as Pe, b as ea, d as aa, e as Fe, r as ce, f as ta, g as la, h as Ne, j as sa, k as ke, l as ra, _ as oa, m as na, O as Me, q as Be, n as ia, p as ca, s as L, t as ua, v as da, w as pa, x as fa, y as va, z as ma, A as Y, B as ha, C as ga, D as ba, E as Re } from "./assets/modules/uploadList-DSN9t4r8.js";
2
+ import { aa as $l, Q as Il, ac as Dl, R as El, V as Pl, a9 as Fl, a7 as Nl, a8 as Ml, ab as Bl, Y as Rl, T as Ol, a5 as Al, a2 as Ll, M as zl, a4 as Ul, U as Vl, G as Yl, $ as Kl, a3 as Wl, a6 as Hl, N as jl, S as Ql, ad as ql, F as Gl, a1 as Jl, ae as Xl, X as Zl, Z as es, W as as, af as ts, H as ls, I as ss, ag as rs, K as os, ah as ns, J as is, a0 as cs } from "./assets/modules/uploadList-DSN9t4r8.js";
3
+ import { A as ds, U as ps, p as fs } from "./assets/modules/file-upload-BrTPBL29.js";
4
4
  import { EnvConfig as we } from "@skyfox2000/microbase";
5
5
  import { FrontCache as re, httpPost as Oe, ResStatus as Ae, SERVER_HOST as _a, fieldMapping as oe } from "@skyfox2000/fapi";
6
6
  import he from "vue-m-message";
@@ -9,15 +9,15 @@ import "async-validator";
9
9
  import fe from "dayjs";
10
10
  import { Popover as Ca, theme as ze, Drawer as Ta, Space as te, Form as Ue, message as $a, FormItem as Ve, ConfigProvider as Ce, Popconfirm as Ia, Button as Ye, DropdownButton as Da, Menu as _e, MenuItem as xe, Dropdown as ve, Checkbox as Ea, Table as Ke, Tree as Pa, Cascader as Fa, DatePicker as Na, Input as ee, InputPassword as Ma, InputNumber as Ba, RangePicker as Ra, Textarea as Oa, TimePicker as Aa, Transfer as La, TreeSelect as za, LayoutContent as Ua } from "ant-design-vue";
11
11
  import { VueDraggableNext as Va } from "vue-draggable-next";
12
- import { d as We } from "./assets/modules/uploadList-61wZlPUk.js";
13
- import { C as ms, U as hs, a as gs, p as bs } from "./assets/modules/uploadList-61wZlPUk.js";
14
- import { c as He } from "./assets/modules/index-BjXLzCF2.js";
15
- import { _ as xs, h as ys, b as ks, a as ws, d as Ss, e as Cs, g as Ts, f as $s, n as Is, p as Ds, t as Es, v as Ps } from "./assets/modules/index-BjXLzCF2.js";
16
- import { _ as A } from "./assets/modules/index-iozooZXX.js";
17
- import { _ as U } from "./assets/modules/toolIcon-BiWBb2pJ.js";
18
- import { a as Ns } from "./assets/modules/toolIcon-BiWBb2pJ.js";
19
- import { _ as Bs, b as Rs, c as Os, d as As, e as Ls, I as zs, f as Us, g as Vs, a as Ys } from "./assets/modules/menuTabs-D_UlXkmm.js";
20
- import { _ as Ws } from "./assets/modules/index-BURe9YrF.js";
12
+ import { d as We } from "./assets/modules/uploadList-C5R2XD5x.js";
13
+ import { C as ms, U as hs, a as gs, p as bs } from "./assets/modules/uploadList-C5R2XD5x.js";
14
+ import { c as He } from "./assets/modules/index-NDOzpgzV.js";
15
+ import { _ as xs, h as ys, b as ks, a as ws, d as Ss, e as Cs, g as Ts, f as $s, n as Is, p as Ds, t as Es, v as Ps } from "./assets/modules/index-NDOzpgzV.js";
16
+ import { _ as A } from "./assets/modules/index-BqoqvtEv.js";
17
+ import { _ as U } from "./assets/modules/toolIcon-DHKszGtC.js";
18
+ import { a as Ns } from "./assets/modules/toolIcon-DHKszGtC.js";
19
+ import { _ as Bs, b as Rs, c as Os, d as As, e as Ls, I as zs, f as Us, g as Vs, a as Ys } from "./assets/modules/menuTabs-BaZAmaXz.js";
20
+ import { _ as Ws } from "./assets/modules/index-DP1u2P1k.js";
21
21
  import { _ as q } from "./assets/modules/_plugin-vue_export-helper-CHgC5LLL.js";
22
22
  const Te = (s, a, e, t = "remove") => {
23
23
  if (!e)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skyfox2000/webui",
3
- "version": "1.4.5",
3
+ "version": "1.4.6",
4
4
  "description": "后台前端通用组件定义",
5
5
  "type": "module",
6
6
  "keywords": [],
@@ -65,4 +65,4 @@
65
65
  "vite-plugin-dts": "^4.5.4",
66
66
  "vue-tsc": "^2.2.0"
67
67
  }
68
- }
68
+ }
@@ -4,6 +4,7 @@ import message from 'vue-m-message';
4
4
  import { isMicroApp, LoginInfo, UserInfo } from '@skyfox2000/microbase';
5
5
  import { ref } from 'vue';
6
6
  import { useAppInfo } from './appInfo';
7
+ import { MicroOpenApis } from '@/utils/micro-openapis';
7
8
 
8
9
  const TokenError = 'Token解析失败';
9
10
  export const LoginExpiredError = 1400;
@@ -375,6 +376,11 @@ export const useUserInfo = defineStore('userInfo', {
375
376
  * @returns
376
377
  */
377
378
  async logout(exit: boolean): Promise<void> {
379
+ if (isMicroApp()) {
380
+ // 调用基座退出登录
381
+ MicroOpenApis.userLogout();
382
+ return Promise.resolve();
383
+ }
378
384
  try {
379
385
  if (exit) {
380
386
  // 调用后端登出接口
@@ -206,7 +206,7 @@ export class AsyncUploader {
206
206
  file.status = UploadStatus.Uploading;
207
207
 
208
208
  // 以 Promise 化的方式处理上传请求
209
- return new Promise((resolve, reject) => {
209
+ return new Promise(async (resolve, reject) => {
210
210
  // 创建表单数据
211
211
  const formData = new FormData();
212
212
  formData.append('file', file.originFileObj as File);
@@ -235,7 +235,7 @@ export class AsyncUploader {
235
235
 
236
236
  // 添加授权 Token(如果需要)
237
237
  if (this.urlInfo.authorize) {
238
- const token = isMicroApp() ? MicroOpenApis.getToken() : useUserInfo().getToken(); // 假设 getToken 是获取 Token 的方法
238
+ const token = isMicroApp() ? await MicroOpenApis.getToken() : useUserInfo().getToken(); // 假设 getToken 是获取 Token 的方法
239
239
  if (!token) {
240
240
  reject(new Error('未授权或授权过期'));
241
241
  return;