@skyfox2000/webui 1.4.4 → 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.
- package/lib/assets/modules/{baseLayout-CYzXPj7i.js → baseLayout-CUZpKmC0.js} +3 -3
- package/lib/assets/modules/{file-upload-Dmi2Kiqo.js → file-upload-BrTPBL29.js} +3 -3
- package/lib/assets/modules/{index-QDkmhaJS.js → index-BqoqvtEv.js} +1 -1
- package/lib/assets/modules/{index-RrFsG5IK.js → index-DP1u2P1k.js} +2 -2
- package/lib/assets/modules/{index-1Qt9-aFa.js → index-NDOzpgzV.js} +2 -2
- package/lib/assets/modules/{menuTabs-sfALzkA5.js → menuTabs-BaZAmaXz.js} +2 -2
- package/lib/assets/modules/{toolIcon-C6QsaAZ8.js → toolIcon-DHKszGtC.js} +1 -1
- package/lib/assets/modules/{uploadList-Bh1TJ-XO.js → uploadList-C5R2XD5x.js} +4 -4
- package/lib/assets/modules/{uploadList-C4BvnORD.js → uploadList-DSN9t4r8.js} +205 -203
- package/lib/es/AceEditor/index.js +3 -3
- package/lib/es/BasicLayout/index.js +2 -2
- package/lib/es/Error403/index.js +1 -1
- package/lib/es/Error404/index.js +1 -1
- package/lib/es/ExcelForm/index.js +5 -5
- package/lib/es/MenuLayout/index.js +2 -2
- package/lib/es/UploadForm/index.js +4 -4
- package/lib/webui.es.js +12 -12
- package/package.json +2 -2
- package/src/stores/appInfo.ts +5 -1
- package/src/stores/userInfo.ts +6 -0
- package/src/utils/file-upload.ts +2 -2
- package/src/utils/micro-openapis.ts +0 -1
|
@@ -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-
|
|
3
|
+
import { _ as q } from "../../assets/modules/toolIcon-DHKszGtC.js";
|
|
4
4
|
import "@skyfox2000/fapi";
|
|
5
|
-
import "../../assets/modules/uploadList-
|
|
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-
|
|
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-
|
|
3
|
-
import { af as A, a as S } from "../../assets/modules/uploadList-
|
|
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";
|
package/lib/es/Error403/index.js
CHANGED
|
@@ -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-
|
|
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";
|
package/lib/es/Error404/index.js
CHANGED
|
@@ -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-
|
|
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-
|
|
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-
|
|
6
|
-
import { A as Re, p as De, U as ce } from "../../assets/modules/file-upload-
|
|
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-
|
|
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-
|
|
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-
|
|
3
|
-
import { af as A, a as S } from "../../assets/modules/uploadList-
|
|
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-
|
|
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-
|
|
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-
|
|
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-
|
|
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-
|
|
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-
|
|
3
|
-
import { A as ds, U as ps, p as fs } from "./assets/modules/file-upload-
|
|
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-
|
|
13
|
-
import { C as ms, U as hs, a as gs, p as bs } from "./assets/modules/uploadList-
|
|
14
|
-
import { c as He } from "./assets/modules/index-
|
|
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-
|
|
16
|
-
import { _ as A } from "./assets/modules/index-
|
|
17
|
-
import { _ as U } from "./assets/modules/toolIcon-
|
|
18
|
-
import { a as Ns } from "./assets/modules/toolIcon-
|
|
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-
|
|
20
|
-
import { _ as Ws } from "./assets/modules/index-
|
|
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
package/src/stores/appInfo.ts
CHANGED
|
@@ -495,7 +495,11 @@ export const useAppInfo = defineStore('appInfo', {
|
|
|
495
495
|
logout() {
|
|
496
496
|
// 清理应用信息
|
|
497
497
|
this.clean();
|
|
498
|
-
|
|
498
|
+
if (isMicroApp()) {
|
|
499
|
+
MicroOpenApis.mainAppPush('/');
|
|
500
|
+
} else {
|
|
501
|
+
window.location.assign('/');
|
|
502
|
+
}
|
|
499
503
|
},
|
|
500
504
|
},
|
|
501
505
|
persist: false,
|
package/src/stores/userInfo.ts
CHANGED
|
@@ -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
|
// 调用后端登出接口
|
package/src/utils/file-upload.ts
CHANGED
|
@@ -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;
|