@skyfox2000/webui 1.4.3 → 1.4.4
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-C92mDmCL.js → baseLayout-CYzXPj7i.js} +3 -3
- package/lib/assets/modules/{file-upload-DGCoBLP3.js → file-upload-Dmi2Kiqo.js} +27 -28
- package/lib/assets/modules/{index-ChjM1bSE.js → index-1Qt9-aFa.js} +2 -2
- package/lib/assets/modules/{index-BrDxf94o.js → index-QDkmhaJS.js} +1 -1
- package/lib/assets/modules/{index-C_7galsG.js → index-RrFsG5IK.js} +2 -2
- package/lib/assets/modules/{menuTabs-Boe_4pzK.js → menuTabs-sfALzkA5.js} +56 -56
- package/lib/assets/modules/{toolIcon-BddslNsJ.js → toolIcon-C6QsaAZ8.js} +1 -1
- package/lib/assets/modules/{uploadList-3sClH7Na.js → uploadList-Bh1TJ-XO.js} +4 -4
- package/lib/assets/modules/{uploadList-ZGWKyite.js → uploadList-C4BvnORD.js} +139 -139
- 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/stores/hostInfo.d.ts +2 -2
- package/lib/utils/micro-openapis.d.ts +7 -6
- package/lib/webui.es.js +12 -12
- package/package.json +1 -1
- package/src/components/layout/header/headerExits.vue +4 -4
- package/src/stores/appInfo.ts +5 -5
- package/src/stores/hostInfo.ts +6 -5
- package/src/utils/file-upload.ts +4 -3
- package/src/utils/micro-openapis.ts +9 -7
|
@@ -5,7 +5,7 @@ import { ref as f, h as H, nextTick as va, inject as se, provide as Le, watch as
|
|
|
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
6
|
import { createPinia as Ta, defineStore as ue } from "pinia";
|
|
7
7
|
import Pa from "pinia-plugin-persistedstate";
|
|
8
|
-
import { EnvConfig as ye, AppAction as Be, AppSource as ze,
|
|
8
|
+
import { EnvConfig as ye, AppAction as Be, AppSource as ze, isMicroApp as B, isBaseMicroApp as ka, combineParams as ce } from "@skyfox2000/microbase";
|
|
9
9
|
import { httpPost as G, ResStatus as T, setToken as me, fieldMapping as La, parseFieldTemplate as Se, API_HOST as Me, 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";
|
|
@@ -302,7 +302,102 @@ const Ua = (e) => {
|
|
|
302
302
|
}
|
|
303
303
|
},
|
|
304
304
|
persist: !1
|
|
305
|
-
})
|
|
305
|
+
});
|
|
306
|
+
class A {
|
|
307
|
+
/**
|
|
308
|
+
* 检查是否在微前端环境中运行
|
|
309
|
+
* @returns boolean
|
|
310
|
+
*/
|
|
311
|
+
static isInMicroApp() {
|
|
312
|
+
return typeof window < "u" && !!window.microApp;
|
|
313
|
+
}
|
|
314
|
+
/**
|
|
315
|
+
* 调用主应用方法的通用方法
|
|
316
|
+
* @param method 方法名
|
|
317
|
+
* @param params 参数
|
|
318
|
+
* @returns Promise
|
|
319
|
+
*/
|
|
320
|
+
static async callMainAppMethod(t, a) {
|
|
321
|
+
if (!this.isInMicroApp())
|
|
322
|
+
throw new Error(`未配置${t}接口!`);
|
|
323
|
+
const s = ++this.messageId, n = new Promise((r, l) => {
|
|
324
|
+
this.callbacks.set(s, { resolve: r, reject: l }), setTimeout(() => {
|
|
325
|
+
this.callbacks.has(s) && (this.callbacks.delete(s), l(new Error(`API调用超时: ${t}`)));
|
|
326
|
+
}, 1e4);
|
|
327
|
+
}), o = {
|
|
328
|
+
type: "API_REQUEST",
|
|
329
|
+
id: s,
|
|
330
|
+
method: t,
|
|
331
|
+
params: a
|
|
332
|
+
};
|
|
333
|
+
return window.microApp.dispatch(o), n;
|
|
334
|
+
}
|
|
335
|
+
/**
|
|
336
|
+
* 处理来自主应用的响应数据
|
|
337
|
+
* @param data 响应数据
|
|
338
|
+
*/
|
|
339
|
+
static handleResponseData(t) {
|
|
340
|
+
if (t && t.type === "API_RESPONSE" && typeof t.id == "number") {
|
|
341
|
+
const { id: a, success: s, result: n, error: o } = t, r = this.callbacks.get(a);
|
|
342
|
+
r && (this.callbacks.delete(a), s ? r.resolve(n) : r.reject(new Error(o || "未知错误")));
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
/**
|
|
346
|
+
* 初始化通信监听器
|
|
347
|
+
*/
|
|
348
|
+
static init() {
|
|
349
|
+
this.isInMicroApp() && window.microApp.addDataListener((t) => {
|
|
350
|
+
console.log("收到来自主应用的数据:", t), this.handleResponseData(t);
|
|
351
|
+
});
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* 获取应用信息
|
|
355
|
+
*/
|
|
356
|
+
static async getAppInfo() {
|
|
357
|
+
return this.callMainAppMethod("getAppInfo");
|
|
358
|
+
}
|
|
359
|
+
/**
|
|
360
|
+
* 获取主机信息
|
|
361
|
+
*/
|
|
362
|
+
static async getHostInfo() {
|
|
363
|
+
return this.callMainAppMethod("getHostInfo");
|
|
364
|
+
}
|
|
365
|
+
/**
|
|
366
|
+
* 获取用户信息
|
|
367
|
+
*/
|
|
368
|
+
static async getUserInfo() {
|
|
369
|
+
return this.callMainAppMethod("getUserInfo");
|
|
370
|
+
}
|
|
371
|
+
/**
|
|
372
|
+
* 获取授权令牌
|
|
373
|
+
*/
|
|
374
|
+
static async getToken() {
|
|
375
|
+
return this.callMainAppMethod("getToken");
|
|
376
|
+
}
|
|
377
|
+
/**
|
|
378
|
+
* 用户登出
|
|
379
|
+
*/
|
|
380
|
+
static async userLogout() {
|
|
381
|
+
return this.callMainAppMethod("userLogout");
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* 主应用推送
|
|
385
|
+
*/
|
|
386
|
+
static async mainAppPush(t) {
|
|
387
|
+
return this.callMainAppMethod("mainAppPush", t);
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
L(A, "messageId", 0), L(A, "callbacks", /* @__PURE__ */ new Map());
|
|
391
|
+
A.init();
|
|
392
|
+
const _e = {
|
|
393
|
+
getAppInfo: A.getAppInfo.bind(A),
|
|
394
|
+
getHostInfo: A.getHostInfo.bind(A),
|
|
395
|
+
getUserInfo: A.getUserInfo.bind(A),
|
|
396
|
+
getToken: A.getToken.bind(A),
|
|
397
|
+
userLogout: A.userLogout.bind(A),
|
|
398
|
+
mainAppPush: A.mainAppPush.bind(A),
|
|
399
|
+
isInMicroApp: A.isInMicroApp.bind(A)
|
|
400
|
+
}, Ka = {
|
|
306
401
|
appList: {
|
|
307
402
|
api: "PLATFORM_API",
|
|
308
403
|
authorize: !0,
|
|
@@ -413,7 +508,7 @@ const Ua = (e) => {
|
|
|
413
508
|
flattenRoutes: {},
|
|
414
509
|
Routes: t ?? [],
|
|
415
510
|
defaultPage: ""
|
|
416
|
-
}), (!
|
|
511
|
+
}), (!B() || !ka()) && (await _().getRolePermits(a.Id), this.appInfo.Routes.length && this.setAppRoutes(this.appInfo.Routes)));
|
|
417
512
|
},
|
|
418
513
|
/**
|
|
419
514
|
* 设置当前应用路由信息
|
|
@@ -435,9 +530,9 @@ const Ua = (e) => {
|
|
|
435
530
|
}), _().isLogin) {
|
|
436
531
|
const a = ta(this.appInfo.Routes);
|
|
437
532
|
if (Na(a), this.appInfo.defaultPage = sa(a) || "", this.appInfo.defaultPage) {
|
|
438
|
-
if (this.menuLoaded = !0,
|
|
533
|
+
if (this.menuLoaded = !0, B()) {
|
|
439
534
|
const s = this.formatRoute(this.appInfo.defaultPage);
|
|
440
|
-
|
|
535
|
+
_e.mainAppPush(s);
|
|
441
536
|
}
|
|
442
537
|
Ua(this.appInfo.defaultPage);
|
|
443
538
|
}
|
|
@@ -458,9 +553,9 @@ const Ua = (e) => {
|
|
|
458
553
|
*/
|
|
459
554
|
push(e) {
|
|
460
555
|
this.findRoute(e) && Ve().setTabActive(e), va(() => {
|
|
461
|
-
if (xe.push({ path: e }),
|
|
556
|
+
if (xe.push({ path: e }), B()) {
|
|
462
557
|
const a = this.formatRoute(e);
|
|
463
|
-
|
|
558
|
+
_e.mainAppPush(a);
|
|
464
559
|
}
|
|
465
560
|
});
|
|
466
561
|
},
|
|
@@ -604,7 +699,7 @@ const Ua = (e) => {
|
|
|
604
699
|
* 启动时初始化用户信息
|
|
605
700
|
*/
|
|
606
701
|
init() {
|
|
607
|
-
|
|
702
|
+
B() || (this.token ? (me(this.token), M.value = this.userInfo.UserLevel, this.isLogin = !0) : this.clean());
|
|
608
703
|
},
|
|
609
704
|
/**
|
|
610
705
|
* 登录操作
|
|
@@ -749,7 +844,7 @@ const Ua = (e) => {
|
|
|
749
844
|
return Promise.resolve();
|
|
750
845
|
}
|
|
751
846
|
},
|
|
752
|
-
persist:
|
|
847
|
+
persist: B() ? !1 : {
|
|
753
848
|
key: "MICROAPP_USER_INFO",
|
|
754
849
|
storage: localStorage,
|
|
755
850
|
pick: ["token", "userInfo"],
|
|
@@ -1172,12 +1267,12 @@ class et {
|
|
|
1172
1267
|
this.listeners[t] && this.listeners[t].forEach((s) => s(t, ...a));
|
|
1173
1268
|
}
|
|
1174
1269
|
}
|
|
1175
|
-
const
|
|
1270
|
+
const W = new et(), ee = (e, t, a) => {
|
|
1176
1271
|
if (t.inputFactory && (a != null && a.reloadEvent)) {
|
|
1177
1272
|
const s = t.inputFactory.value;
|
|
1178
1273
|
s.reloadHandler = (n, o) => {
|
|
1179
1274
|
at(t.url, t, o);
|
|
1180
|
-
},
|
|
1275
|
+
}, W.on(a.reloadEvent, s.reloadHandler);
|
|
1181
1276
|
}
|
|
1182
1277
|
if (a != null && a.data)
|
|
1183
1278
|
g(
|
|
@@ -1210,7 +1305,7 @@ const B = new et(), ee = (e, t, a) => {
|
|
|
1210
1305
|
Array.isArray(a) ? Ge(t, a, !0) : ua(e, t, a);
|
|
1211
1306
|
}, de = (e, t) => {
|
|
1212
1307
|
var a;
|
|
1213
|
-
(a = e.inputFactory) != null && a.value && t.reloadEvent && e.inputFactory.value.reloadHandler &&
|
|
1308
|
+
(a = e.inputFactory) != null && a.value && t.reloadEvent && e.inputFactory.value.reloadHandler && W.off(t.reloadEvent, e.inputFactory.value.reloadHandler);
|
|
1214
1309
|
}, ua = (e, t, a) => {
|
|
1215
1310
|
const s = JSON.parse(JSON.stringify(e.params ?? {})), n = JSON.parse(JSON.stringify(t.params ?? {})), o = ce(s, n, a);
|
|
1216
1311
|
tt(e, t, t.fieldMap, o).then((r) => {
|
|
@@ -1310,7 +1405,7 @@ const B = new et(), ee = (e, t, a) => {
|
|
|
1310
1405
|
const c = Se(u, { selectedValues: a });
|
|
1311
1406
|
try {
|
|
1312
1407
|
const p = JSON.parse(c);
|
|
1313
|
-
|
|
1408
|
+
W.emit(i, p, a, n);
|
|
1314
1409
|
} catch (p) {
|
|
1315
1410
|
console.error("eventParamsValue: ", c, p);
|
|
1316
1411
|
}
|
|
@@ -1319,15 +1414,15 @@ const B = new et(), ee = (e, t, a) => {
|
|
|
1319
1414
|
const i = Se(u, { selectedValues: a });
|
|
1320
1415
|
try {
|
|
1321
1416
|
const c = JSON.parse(i);
|
|
1322
|
-
|
|
1417
|
+
W.emit(l, c, a, n);
|
|
1323
1418
|
} catch (c) {
|
|
1324
1419
|
console.error("eventParamsValue: ", i, c);
|
|
1325
1420
|
}
|
|
1326
1421
|
}
|
|
1327
1422
|
else
|
|
1328
1423
|
Array.isArray(l) ? l.every((i) => {
|
|
1329
|
-
|
|
1330
|
-
}) :
|
|
1424
|
+
W.emit(i, n, a);
|
|
1425
|
+
}) : W.emit(l, n, a);
|
|
1331
1426
|
}
|
|
1332
1427
|
return s != null && s.inputEmit && s.inputEmit("change", a, n), n;
|
|
1333
1428
|
}, S = {
|
|
@@ -1745,28 +1840,28 @@ const B = new et(), ee = (e, t, a) => {
|
|
|
1745
1840
|
* 加载站点信息
|
|
1746
1841
|
* @param hostApi 启动配置主机地址
|
|
1747
1842
|
* @param hostKey 站点信息,默认为当前主域名
|
|
1748
|
-
* @param mainOpenApis 宿主机开放接口
|
|
1749
1843
|
*/
|
|
1750
|
-
async loadHostInfo(e, t
|
|
1751
|
-
if (
|
|
1752
|
-
|
|
1844
|
+
async loadHostInfo(e, t) {
|
|
1845
|
+
if (B()) {
|
|
1846
|
+
const s = await _e.getHostInfo();
|
|
1847
|
+
this._setHostInfo(s);
|
|
1753
1848
|
return;
|
|
1754
1849
|
}
|
|
1755
|
-
let
|
|
1756
|
-
return (!
|
|
1757
|
-
Me.SITEHOST_API || (Me.SITEHOST_API =
|
|
1758
|
-
const
|
|
1850
|
+
let a = (e || this.getSiteHostApi()).trim();
|
|
1851
|
+
return (!a || a === "/") && (a = window.location.origin), a.endsWith("/") && (a = a.slice(0, -1)), new Promise((s) => {
|
|
1852
|
+
Me.SITEHOST_API || (Me.SITEHOST_API = a);
|
|
1853
|
+
const n = t || window.location.origin;
|
|
1759
1854
|
G(dt.host, {
|
|
1760
1855
|
Query: {
|
|
1761
|
-
Host:
|
|
1856
|
+
Host: n
|
|
1762
1857
|
}
|
|
1763
|
-
}).then((
|
|
1764
|
-
if ((
|
|
1765
|
-
const
|
|
1766
|
-
this._setHostInfo(
|
|
1858
|
+
}).then((o) => {
|
|
1859
|
+
if ((o == null ? void 0 : o.status) === T.SUCCESS && o.data) {
|
|
1860
|
+
const r = o.data;
|
|
1861
|
+
this._setHostInfo(r);
|
|
1767
1862
|
} else
|
|
1768
1863
|
this._setHostInfo(null);
|
|
1769
|
-
|
|
1864
|
+
s();
|
|
1770
1865
|
});
|
|
1771
1866
|
});
|
|
1772
1867
|
},
|
|
@@ -1813,102 +1908,7 @@ const B = new et(), ee = (e, t, a) => {
|
|
|
1813
1908
|
// storage: localStorage,
|
|
1814
1909
|
// pick: ['hostInfo'],
|
|
1815
1910
|
// },
|
|
1816
|
-
})
|
|
1817
|
-
class A {
|
|
1818
|
-
/**
|
|
1819
|
-
* 检查是否在微前端环境中运行
|
|
1820
|
-
* @returns boolean
|
|
1821
|
-
*/
|
|
1822
|
-
static isInMicroApp() {
|
|
1823
|
-
return typeof window < "u" && !!window.microApp;
|
|
1824
|
-
}
|
|
1825
|
-
/**
|
|
1826
|
-
* 调用主应用方法的通用方法
|
|
1827
|
-
* @param method 方法名
|
|
1828
|
-
* @param params 参数
|
|
1829
|
-
* @returns Promise
|
|
1830
|
-
*/
|
|
1831
|
-
static async callMainAppMethod(t, a) {
|
|
1832
|
-
if (!this.isInMicroApp())
|
|
1833
|
-
throw new Error(`未配置${t}接口!`);
|
|
1834
|
-
const s = ++this.messageId, n = new Promise((r, l) => {
|
|
1835
|
-
this.callbacks.set(s, { resolve: r, reject: l }), setTimeout(() => {
|
|
1836
|
-
this.callbacks.has(s) && (this.callbacks.delete(s), l(new Error(`API调用超时: ${t}`)));
|
|
1837
|
-
}, 1e4);
|
|
1838
|
-
}), o = {
|
|
1839
|
-
type: "API_REQUEST",
|
|
1840
|
-
id: s,
|
|
1841
|
-
method: t,
|
|
1842
|
-
params: a
|
|
1843
|
-
};
|
|
1844
|
-
return window.microApp.dispatch(o), n;
|
|
1845
|
-
}
|
|
1846
|
-
/**
|
|
1847
|
-
* 处理来自主应用的响应数据
|
|
1848
|
-
* @param data 响应数据
|
|
1849
|
-
*/
|
|
1850
|
-
static handleResponseData(t) {
|
|
1851
|
-
if (t && t.type === "API_RESPONSE" && typeof t.id == "number") {
|
|
1852
|
-
const { id: a, success: s, result: n, error: o } = t, r = this.callbacks.get(a);
|
|
1853
|
-
r && (this.callbacks.delete(a), s ? r.resolve(n) : r.reject(new Error(o || "未知错误")));
|
|
1854
|
-
}
|
|
1855
|
-
}
|
|
1856
|
-
/**
|
|
1857
|
-
* 初始化通信监听器
|
|
1858
|
-
*/
|
|
1859
|
-
static init() {
|
|
1860
|
-
this.isInMicroApp() && window.microApp.addDataListener((t) => {
|
|
1861
|
-
console.log("收到来自主应用的数据:", t), this.handleResponseData(t);
|
|
1862
|
-
});
|
|
1863
|
-
}
|
|
1864
|
-
/**
|
|
1865
|
-
* 获取应用信息
|
|
1866
|
-
*/
|
|
1867
|
-
static async getAppInfo() {
|
|
1868
|
-
return this.callMainAppMethod("getAppInfo");
|
|
1869
|
-
}
|
|
1870
|
-
/**
|
|
1871
|
-
* 获取主机信息
|
|
1872
|
-
*/
|
|
1873
|
-
static async getHostInfo() {
|
|
1874
|
-
return this.callMainAppMethod("getHostInfo");
|
|
1875
|
-
}
|
|
1876
|
-
/**
|
|
1877
|
-
* 获取用户信息
|
|
1878
|
-
*/
|
|
1879
|
-
static async getUserInfo() {
|
|
1880
|
-
return this.callMainAppMethod("getUserInfo");
|
|
1881
|
-
}
|
|
1882
|
-
/**
|
|
1883
|
-
* 获取授权令牌
|
|
1884
|
-
*/
|
|
1885
|
-
static async getToken() {
|
|
1886
|
-
return this.callMainAppMethod("getToken");
|
|
1887
|
-
}
|
|
1888
|
-
/**
|
|
1889
|
-
* 用户登出
|
|
1890
|
-
*/
|
|
1891
|
-
static async userLogout() {
|
|
1892
|
-
return this.callMainAppMethod("userLogout");
|
|
1893
|
-
}
|
|
1894
|
-
/**
|
|
1895
|
-
* 主应用推送
|
|
1896
|
-
*/
|
|
1897
|
-
static async mainAppPush(t) {
|
|
1898
|
-
return this.callMainAppMethod("mainAppPush", t);
|
|
1899
|
-
}
|
|
1900
|
-
}
|
|
1901
|
-
L(A, "messageId", 0), L(A, "callbacks", /* @__PURE__ */ new Map());
|
|
1902
|
-
A.init();
|
|
1903
|
-
const ts = {
|
|
1904
|
-
getAppInfo: A.getAppInfo.bind(A),
|
|
1905
|
-
getHostInfo: A.getHostInfo.bind(A),
|
|
1906
|
-
getUserInfo: A.getUserInfo.bind(A),
|
|
1907
|
-
getToken: A.getToken.bind(A),
|
|
1908
|
-
userLogout: A.userLogout.bind(A),
|
|
1909
|
-
mainAppPush: A.mainAppPush.bind(A),
|
|
1910
|
-
isInMicroApp: A.isInMicroApp.bind(A)
|
|
1911
|
-
}, ss = ue("settingInfo", {
|
|
1911
|
+
}), ts = ue("settingInfo", {
|
|
1912
1912
|
state: () => ({
|
|
1913
1913
|
fullscreen: !1,
|
|
1914
1914
|
menuCollapse: !1,
|
|
@@ -1950,7 +1950,7 @@ const ts = {
|
|
|
1950
1950
|
}
|
|
1951
1951
|
},
|
|
1952
1952
|
persist: !1
|
|
1953
|
-
}),
|
|
1953
|
+
}), ss = /* @__PURE__ */ Z({
|
|
1954
1954
|
__name: "index",
|
|
1955
1955
|
props: {
|
|
1956
1956
|
...fe,
|
|
@@ -2002,7 +2002,7 @@ const ts = {
|
|
|
2002
2002
|
}, p.$attrs), null, 16, ["class", "checkedChildren", "checkedValue", "unCheckedChildren", "unCheckedValue"])) : z("", !0);
|
|
2003
2003
|
};
|
|
2004
2004
|
}
|
|
2005
|
-
}),
|
|
2005
|
+
}), ns = /* @__PURE__ */ Z({
|
|
2006
2006
|
inheritAttrs: !1,
|
|
2007
2007
|
__name: "index",
|
|
2008
2008
|
props: {
|
|
@@ -2096,7 +2096,7 @@ const ts = {
|
|
|
2096
2096
|
}), ht = { class: "min-h-[32px] pt-[5px]" }, mt = {
|
|
2097
2097
|
key: 1,
|
|
2098
2098
|
class: "text-center text-gray-500"
|
|
2099
|
-
},
|
|
2099
|
+
}, rs = /* @__PURE__ */ Z({
|
|
2100
2100
|
inheritAttrs: !1,
|
|
2101
2101
|
__name: "index",
|
|
2102
2102
|
props: {
|
|
@@ -2182,7 +2182,7 @@ const ts = {
|
|
|
2182
2182
|
}), vt = { class: "min-h-[32px] pt-1" }, gt = {
|
|
2183
2183
|
key: 1,
|
|
2184
2184
|
class: "text-center text-gray-500"
|
|
2185
|
-
},
|
|
2185
|
+
}, os = /* @__PURE__ */ Z({
|
|
2186
2186
|
inheritAttrs: !1,
|
|
2187
2187
|
__name: "index",
|
|
2188
2188
|
props: {
|
|
@@ -2289,7 +2289,7 @@ const ts = {
|
|
|
2289
2289
|
}), yt = {
|
|
2290
2290
|
key: 0,
|
|
2291
2291
|
class: "absolute z-10 mt-[5px] mr-[10px] text-[#999] flex items-center"
|
|
2292
|
-
},
|
|
2292
|
+
}, is = /* @__PURE__ */ Z({
|
|
2293
2293
|
inheritAttrs: !1,
|
|
2294
2294
|
__name: "index",
|
|
2295
2295
|
props: {
|
|
@@ -2438,9 +2438,9 @@ const ts = {
|
|
|
2438
2438
|
export {
|
|
2439
2439
|
Mt as $,
|
|
2440
2440
|
pe as A,
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2441
|
+
rs as B,
|
|
2442
|
+
os as C,
|
|
2443
|
+
is as D,
|
|
2444
2444
|
Qe as E,
|
|
2445
2445
|
_a as F,
|
|
2446
2446
|
Wt as G,
|
|
@@ -2463,8 +2463,8 @@ export {
|
|
|
2463
2463
|
ra as X,
|
|
2464
2464
|
Ht as Y,
|
|
2465
2465
|
oa as Z,
|
|
2466
|
-
|
|
2467
|
-
|
|
2466
|
+
ss as _,
|
|
2467
|
+
ts as a,
|
|
2468
2468
|
Ft as a0,
|
|
2469
2469
|
Je as a1,
|
|
2470
2470
|
$t as a2,
|
|
@@ -2476,8 +2476,8 @@ export {
|
|
|
2476
2476
|
na as a8,
|
|
2477
2477
|
Ba as a9,
|
|
2478
2478
|
Ne as aa,
|
|
2479
|
-
|
|
2480
|
-
|
|
2479
|
+
W as ab,
|
|
2480
|
+
_e as ac,
|
|
2481
2481
|
ne as ad,
|
|
2482
2482
|
ge as ae,
|
|
2483
2483
|
V as af,
|
|
@@ -2496,7 +2496,7 @@ export {
|
|
|
2496
2496
|
ia as k,
|
|
2497
2497
|
Xa as l,
|
|
2498
2498
|
Jt as m,
|
|
2499
|
-
|
|
2499
|
+
ns as n,
|
|
2500
2500
|
Nt as o,
|
|
2501
2501
|
fe as p,
|
|
2502
2502
|
za as q,
|
|
@@ -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-C6QsaAZ8.js";
|
|
4
4
|
import "@skyfox2000/fapi";
|
|
5
|
-
import "../../assets/modules/uploadList-
|
|
5
|
+
import "../../assets/modules/uploadList-C4BvnORD.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-RrFsG5IK.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-CYzXPj7i.js";
|
|
3
|
+
import { af as A, a as S } from "../../assets/modules/uploadList-C4BvnORD.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-C4BvnORD.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-C4BvnORD.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-QDkmhaJS.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-C4BvnORD.js";
|
|
6
|
+
import { A as Re, p as De, U as ce } from "../../assets/modules/file-upload-Dmi2Kiqo.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-1Qt9-aFa.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-1Qt9-aFa.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-CYzXPj7i.js";
|
|
3
|
+
import { af as A, a as S } from "../../assets/modules/uploadList-C4BvnORD.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-QDkmhaJS.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-C4BvnORD.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-Dmi2Kiqo.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-Bh1TJ-XO.js";
|
|
13
13
|
const K = /* @__PURE__ */ y({
|
|
14
14
|
__name: "uploadForm",
|
|
15
15
|
props: {
|
package/lib/stores/hostInfo.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { HostInfo
|
|
1
|
+
import { HostInfo } from '../../../502424_MicroBase';
|
|
2
2
|
import { StoreDefinition } from 'pinia';
|
|
3
3
|
export declare const useHostInfo: StoreDefinition<"hostInfo", {
|
|
4
4
|
hostInfo: HostInfo;
|
|
5
5
|
}, {}, {
|
|
6
6
|
getSiteHostApi(): string;
|
|
7
|
-
loadHostInfo(hostApi: string, hostKey?: string
|
|
7
|
+
loadHostInfo(hostApi: string, hostKey?: string): Promise<void>;
|
|
8
8
|
clear(): void;
|
|
9
9
|
_setHostInfo(hostInfo: HostInfo | null): void;
|
|
10
10
|
getHostInfo(): HostInfo;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AppInfo, HostInfo, UserInfo } from '../../../502424_MicroBase';
|
|
1
2
|
declare class MicroAppSDK {
|
|
2
3
|
private static messageId;
|
|
3
4
|
private static callbacks;
|
|
@@ -5,12 +6,12 @@ declare class MicroAppSDK {
|
|
|
5
6
|
private static callMainAppMethod;
|
|
6
7
|
static handleResponseData(data: any): void;
|
|
7
8
|
static init(): void;
|
|
8
|
-
static getAppInfo(): Promise<
|
|
9
|
-
static getHostInfo(): Promise<
|
|
10
|
-
static getUserInfo(): Promise<
|
|
11
|
-
static getToken(): Promise<
|
|
12
|
-
static userLogout(): Promise<
|
|
13
|
-
static mainAppPush(
|
|
9
|
+
static getAppInfo(): Promise<AppInfo>;
|
|
10
|
+
static getHostInfo(): Promise<HostInfo>;
|
|
11
|
+
static getUserInfo(): Promise<UserInfo>;
|
|
12
|
+
static getToken(): Promise<string>;
|
|
13
|
+
static userLogout(): Promise<void>;
|
|
14
|
+
static mainAppPush(path: string): Promise<void>;
|
|
14
15
|
}
|
|
15
16
|
export declare const MicroOpenApis: {
|
|
16
17
|
getAppInfo: typeof MicroAppSDK.getAppInfo;
|
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-C4BvnORD.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-C4BvnORD.js";
|
|
3
|
+
import { A as ds, U as ps, p as fs } from "./assets/modules/file-upload-Dmi2Kiqo.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-Bh1TJ-XO.js";
|
|
13
|
+
import { C as ms, U as hs, a as gs, p as bs } from "./assets/modules/uploadList-Bh1TJ-XO.js";
|
|
14
|
+
import { c as He } from "./assets/modules/index-1Qt9-aFa.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-1Qt9-aFa.js";
|
|
16
|
+
import { _ as A } from "./assets/modules/index-QDkmhaJS.js";
|
|
17
|
+
import { _ as U } from "./assets/modules/toolIcon-C6QsaAZ8.js";
|
|
18
|
+
import { a as Ns } from "./assets/modules/toolIcon-C6QsaAZ8.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-sfALzkA5.js";
|
|
20
|
+
import { _ as Ws } from "./assets/modules/index-RrFsG5IK.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,16 +1,16 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import { ref } from 'vue';
|
|
3
3
|
import { Modal, Flex } from 'ant-design-vue';
|
|
4
|
-
import { mainAppApis } from '@skyfox2000/microbase';
|
|
5
4
|
import { ToolIcon, Tooltip } from '../../common';
|
|
6
|
-
import { useUserInfo } from '@/index';
|
|
5
|
+
import { MicroOpenApis, useUserInfo } from '@/index';
|
|
6
|
+
import { isMicroApp } from '@skyfox2000/microbase';
|
|
7
7
|
|
|
8
8
|
const userInfoStore = useUserInfo();
|
|
9
9
|
const open = ref(false);
|
|
10
10
|
const confirmExit = () => {
|
|
11
11
|
open.value = false;
|
|
12
|
-
if (
|
|
13
|
-
|
|
12
|
+
if (isMicroApp()) {
|
|
13
|
+
MicroOpenApis.userLogout!();
|
|
14
14
|
} else {
|
|
15
15
|
userInfoStore.logout(true);
|
|
16
16
|
}
|