x-essential-lib 0.5.68 → 0.5.73
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/dist/index.js +522 -451
- package/dist/store/global.d.ts +3 -3
- package/dist/utils/globalState.d.ts +16 -0
- package/dist/utils/index.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,65 +1,22 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var a=document.createElement("style");a.id="x-essential-lib",a.appendChild(document.createTextNode('.x-cont[data-v-f4ad116e]{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;align-items:center;justify-content:center}.lds-spinner[data-v-f4ad116e]{color:official;display:inline-block;position:relative;width:40px;height:40px}.lds-spinner div[data-v-f4ad116e]{transform-origin:20px 20px;animation:lds-spinner-f4ad116e 1.2s linear infinite}.lds-spinner div[data-v-f4ad116e]:after{content:" ";display:block;position:absolute;top:3px;left:18px;width:2px;height:6px;border-radius:5%;background:#9e9e9e}.lds-spinner div[data-v-f4ad116e]:nth-child(1){transform:rotate(0);animation-delay:-1.1s}.lds-spinner div[data-v-f4ad116e]:nth-child(2){transform:rotate(30deg);animation-delay:-1s}.lds-spinner div[data-v-f4ad116e]:nth-child(3){transform:rotate(60deg);animation-delay:-.9s}.lds-spinner div[data-v-f4ad116e]:nth-child(4){transform:rotate(90deg);animation-delay:-.8s}.lds-spinner div[data-v-f4ad116e]:nth-child(5){transform:rotate(120deg);animation-delay:-.7s}.lds-spinner div[data-v-f4ad116e]:nth-child(6){transform:rotate(150deg);animation-delay:-.6s}.lds-spinner div[data-v-f4ad116e]:nth-child(7){transform:rotate(180deg);animation-delay:-.5s}.lds-spinner div[data-v-f4ad116e]:nth-child(8){transform:rotate(210deg);animation-delay:-.4s}.lds-spinner div[data-v-f4ad116e]:nth-child(9){transform:rotate(240deg);animation-delay:-.3s}.lds-spinner div[data-v-f4ad116e]:nth-child(10){transform:rotate(270deg);animation-delay:-.2s}.lds-spinner div[data-v-f4ad116e]:nth-child(11){transform:rotate(300deg);animation-delay:-.1s}.lds-spinner div[data-v-f4ad116e]:nth-child(12){transform:rotate(330deg);animation-delay:0s}@keyframes lds-spinner-f4ad116e{0%{opacity:1}to{opacity:0}}.x-cont[data-v-8c2268ea]{position:absolute;left:50%;bottom:20px;transform:translate(-50%);z-index:9999}')),document.head.appendChild(a)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import Ce from "
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
dark: e,
|
|
11
|
-
locale: a,
|
|
12
|
-
permissionObjects: t,
|
|
13
|
-
permissionChecksum: l,
|
|
14
|
-
lastAppPath: o
|
|
15
|
-
};
|
|
16
|
-
}), re = le("viewMgr", () => {
|
|
17
|
-
const e = i([]);
|
|
18
|
-
function a() {
|
|
19
|
-
return e.value.length <= 0;
|
|
20
|
-
}
|
|
21
|
-
function t() {
|
|
22
|
-
const p = e.value.length;
|
|
23
|
-
if (p > 0)
|
|
24
|
-
return e.value[p - 1];
|
|
25
|
-
}
|
|
26
|
-
function l(p) {
|
|
27
|
-
return e.value.find((s) => s === p) !== void 0;
|
|
28
|
-
}
|
|
29
|
-
function o(p) {
|
|
30
|
-
e.value.push(p);
|
|
31
|
-
}
|
|
32
|
-
function r(p) {
|
|
33
|
-
const s = e.value.findIndex((v) => v === p);
|
|
34
|
-
s !== -1 && e.value.splice(s, 1);
|
|
35
|
-
}
|
|
36
|
-
function n() {
|
|
37
|
-
console.assert(e.value.length > 0), e.value.pop();
|
|
38
|
-
}
|
|
39
|
-
function c() {
|
|
40
|
-
e.value = [];
|
|
41
|
-
}
|
|
42
|
-
return {
|
|
43
|
-
views: e,
|
|
44
|
-
isEmpty: a,
|
|
45
|
-
lastView: t,
|
|
46
|
-
hasView: l,
|
|
47
|
-
addView: o,
|
|
48
|
-
delView: r,
|
|
49
|
-
popView: n,
|
|
50
|
-
clearViews: c
|
|
51
|
-
};
|
|
52
|
-
});
|
|
2
|
+
var ve = Object.defineProperty;
|
|
3
|
+
var me = (e, t, a) => t in e ? ve(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a;
|
|
4
|
+
var U = (e, t, a) => (me(e, typeof t != "symbol" ? t + "" : t, a), a);
|
|
5
|
+
import { ref as i, watch as R, computed as f, onMounted as A, onBeforeUnmount as T, defineComponent as B, resolveComponent as v, openBlock as k, createBlock as I, unref as K, isRef as Y, withKeys as N, withModifiers as $, withCtx as m, createVNode as y, createTextVNode as O, toDisplayString as V, createElementBlock as J, normalizeStyle as he, pushScopeId as we, popScopeId as ye, createElementVNode as g, reactive as xe, Fragment as be, renderList as ke, createCommentVNode as Ce } from "vue";
|
|
6
|
+
import { useLocale as Z, useTheme as P, useDisplay as Se } from "vuetify";
|
|
7
|
+
import { defineStore as ne } from "pinia";
|
|
8
|
+
import De from "axios";
|
|
9
|
+
import { useRouter as re, useRoute as Re } from "vue-router";
|
|
53
10
|
/*! js-cookie v3.0.5 | MIT */
|
|
54
|
-
function
|
|
55
|
-
for (var
|
|
56
|
-
var
|
|
57
|
-
for (var l in
|
|
58
|
-
e[l] =
|
|
11
|
+
function F(e) {
|
|
12
|
+
for (var t = 1; t < arguments.length; t++) {
|
|
13
|
+
var a = arguments[t];
|
|
14
|
+
for (var l in a)
|
|
15
|
+
e[l] = a[l];
|
|
59
16
|
}
|
|
60
17
|
return e;
|
|
61
18
|
}
|
|
62
|
-
var
|
|
19
|
+
var Ve = {
|
|
63
20
|
read: function(e) {
|
|
64
21
|
return e[0] === '"' && (e = e.slice(1, -1)), e.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
|
|
65
22
|
},
|
|
@@ -70,23 +27,23 @@ var De = {
|
|
|
70
27
|
);
|
|
71
28
|
}
|
|
72
29
|
};
|
|
73
|
-
function
|
|
74
|
-
function
|
|
30
|
+
function Q(e, t) {
|
|
31
|
+
function a(o, r, n) {
|
|
75
32
|
if (!(typeof document > "u")) {
|
|
76
|
-
n =
|
|
77
|
-
var
|
|
78
|
-
for (var
|
|
79
|
-
n[
|
|
80
|
-
return document.cookie = o + "=" + e.write(r, o) +
|
|
33
|
+
n = F({}, t, n), typeof n.expires == "number" && (n.expires = new Date(Date.now() + n.expires * 864e5)), n.expires && (n.expires = n.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
|
|
34
|
+
var s = "";
|
|
35
|
+
for (var u in n)
|
|
36
|
+
n[u] && (s += "; " + u, n[u] !== !0 && (s += "=" + n[u].split(";")[0]));
|
|
37
|
+
return document.cookie = o + "=" + e.write(r, o) + s;
|
|
81
38
|
}
|
|
82
39
|
}
|
|
83
40
|
function l(o) {
|
|
84
41
|
if (!(typeof document > "u" || arguments.length && !o)) {
|
|
85
|
-
for (var r = document.cookie ? document.cookie.split("; ") : [], n = {},
|
|
86
|
-
var
|
|
42
|
+
for (var r = document.cookie ? document.cookie.split("; ") : [], n = {}, s = 0; s < r.length; s++) {
|
|
43
|
+
var u = r[s].split("="), _ = u.slice(1).join("=");
|
|
87
44
|
try {
|
|
88
|
-
var
|
|
89
|
-
if (n[
|
|
45
|
+
var h = decodeURIComponent(u[0]);
|
|
46
|
+
if (n[h] = e.read(_, h), o === h)
|
|
90
47
|
break;
|
|
91
48
|
} catch {
|
|
92
49
|
}
|
|
@@ -96,170 +53,226 @@ function X(e, a) {
|
|
|
96
53
|
}
|
|
97
54
|
return Object.create(
|
|
98
55
|
{
|
|
99
|
-
set:
|
|
56
|
+
set: a,
|
|
100
57
|
get: l,
|
|
101
58
|
remove: function(o, r) {
|
|
102
|
-
|
|
59
|
+
a(
|
|
103
60
|
o,
|
|
104
61
|
"",
|
|
105
|
-
|
|
62
|
+
F({}, r, {
|
|
106
63
|
expires: -1
|
|
107
64
|
})
|
|
108
65
|
);
|
|
109
66
|
},
|
|
110
67
|
withAttributes: function(o) {
|
|
111
|
-
return
|
|
68
|
+
return Q(this.converter, F({}, this.attributes, o));
|
|
112
69
|
},
|
|
113
70
|
withConverter: function(o) {
|
|
114
|
-
return
|
|
71
|
+
return Q(F({}, this.converter, o), this.attributes);
|
|
115
72
|
}
|
|
116
73
|
},
|
|
117
74
|
{
|
|
118
|
-
attributes: { value: Object.freeze(
|
|
75
|
+
attributes: { value: Object.freeze(t) },
|
|
119
76
|
converter: { value: Object.freeze(e) }
|
|
120
77
|
}
|
|
121
78
|
);
|
|
122
79
|
}
|
|
123
|
-
var
|
|
124
|
-
function
|
|
125
|
-
const
|
|
80
|
+
var j = Q(Ve, { path: "/" });
|
|
81
|
+
function ct(e) {
|
|
82
|
+
const t = De.create({
|
|
126
83
|
timeout: 6e3
|
|
127
84
|
});
|
|
128
|
-
return
|
|
129
|
-
(
|
|
130
|
-
(
|
|
131
|
-
|
|
85
|
+
return t.defaults.baseURL = e.baseUrl, t.interceptors.request.use(
|
|
86
|
+
(a) => Ae(a),
|
|
87
|
+
(a) => {
|
|
88
|
+
qe(a, e.onError);
|
|
132
89
|
}
|
|
133
|
-
),
|
|
134
|
-
(
|
|
135
|
-
(
|
|
136
|
-
),
|
|
90
|
+
), t.interceptors.response.use(
|
|
91
|
+
(a) => Oe(a),
|
|
92
|
+
(a) => je(a, e.onError)
|
|
93
|
+
), t;
|
|
137
94
|
}
|
|
138
|
-
function
|
|
139
|
-
const
|
|
140
|
-
return e.headers.Authorization = "Basic " +
|
|
95
|
+
function Ae(e) {
|
|
96
|
+
const t = j.get("accessToken") ?? "";
|
|
97
|
+
return e.headers.Authorization = "Basic " + t, e.headers["Content-Type"] = "application/json", e.data = JSON.stringify(e.data), e;
|
|
141
98
|
}
|
|
142
|
-
function
|
|
143
|
-
console.error(e),
|
|
99
|
+
function qe(e, t) {
|
|
100
|
+
console.error(e), t("request timeout");
|
|
144
101
|
}
|
|
145
|
-
function
|
|
102
|
+
function Oe(e) {
|
|
146
103
|
return e.data;
|
|
147
104
|
}
|
|
148
|
-
function
|
|
105
|
+
function je(e, t) {
|
|
149
106
|
var o;
|
|
150
|
-
const
|
|
151
|
-
if (!
|
|
107
|
+
const a = e.response;
|
|
108
|
+
if (!a)
|
|
152
109
|
return Promise.reject(e);
|
|
153
|
-
|
|
154
|
-
let l = (o =
|
|
110
|
+
a.status === 401 && Ie();
|
|
111
|
+
let l = (o = a.data) == null ? void 0 : o.message;
|
|
155
112
|
return l || (l = {
|
|
156
|
-
code:
|
|
157
|
-
message:
|
|
158
|
-
}),
|
|
159
|
-
}
|
|
160
|
-
function
|
|
161
|
-
|
|
162
|
-
}
|
|
163
|
-
function
|
|
164
|
-
return { all: e = e || /* @__PURE__ */ new Map(), on: function(
|
|
165
|
-
var l = e.get(
|
|
166
|
-
l ? l.push(
|
|
167
|
-
}, off: function(
|
|
168
|
-
var l = e.get(
|
|
169
|
-
l && (
|
|
170
|
-
}, emit: function(
|
|
171
|
-
var l = e.get(
|
|
113
|
+
code: a.status,
|
|
114
|
+
message: a.statusText
|
|
115
|
+
}), t(l), Promise.reject(e);
|
|
116
|
+
}
|
|
117
|
+
function Ie() {
|
|
118
|
+
j.remove("accessToken"), j.remove("refreshToken"), j.remove("activeOrg"), re().replace({ path: "/passport/login" });
|
|
119
|
+
}
|
|
120
|
+
function Te(e) {
|
|
121
|
+
return { all: e = e || /* @__PURE__ */ new Map(), on: function(t, a) {
|
|
122
|
+
var l = e.get(t);
|
|
123
|
+
l ? l.push(a) : e.set(t, [a]);
|
|
124
|
+
}, off: function(t, a) {
|
|
125
|
+
var l = e.get(t);
|
|
126
|
+
l && (a ? l.splice(l.indexOf(a) >>> 0, 1) : e.set(t, []));
|
|
127
|
+
}, emit: function(t, a) {
|
|
128
|
+
var l = e.get(t);
|
|
172
129
|
l && l.slice().map(function(o) {
|
|
173
|
-
o(
|
|
130
|
+
o(a);
|
|
174
131
|
}), (l = e.get("*")) && l.slice().map(function(o) {
|
|
175
|
-
o(
|
|
132
|
+
o(t, a);
|
|
176
133
|
});
|
|
177
134
|
} };
|
|
178
135
|
}
|
|
179
|
-
const
|
|
180
|
-
return window.eventBus || (window.eventBus =
|
|
136
|
+
const c = function() {
|
|
137
|
+
return window.eventBus || (window.eventBus = Te()), window.eventBus;
|
|
181
138
|
}();
|
|
182
|
-
async function
|
|
183
|
-
return new Promise((
|
|
184
|
-
setTimeout(
|
|
139
|
+
async function st(e) {
|
|
140
|
+
return new Promise((t) => {
|
|
141
|
+
setTimeout(t, e);
|
|
185
142
|
});
|
|
186
143
|
}
|
|
187
|
-
async function
|
|
144
|
+
async function ee(e, t, a) {
|
|
188
145
|
const l = Date.now();
|
|
189
146
|
return new Promise((o) => {
|
|
190
147
|
const r = async () => {
|
|
191
|
-
e() ? o(!0) :
|
|
148
|
+
e() ? o(!0) : t && Date.now() - l > t ? o(!1) : setTimeout(r, a ?? 30);
|
|
192
149
|
};
|
|
193
150
|
r();
|
|
194
151
|
});
|
|
195
152
|
}
|
|
196
|
-
function
|
|
153
|
+
function Be(e, t) {
|
|
197
154
|
var o;
|
|
198
|
-
const
|
|
199
|
-
l && (l.remove("app-left", "app-right", "app-reset"),
|
|
155
|
+
const a = "single-spa-application:" + e, l = (o = document.getElementById(a)) == null ? void 0 : o.classList;
|
|
156
|
+
l && (l.remove("app-left", "app-right", "app-reset"), t ? l.add("app-left") : l.add("app-right"), setTimeout(() => {
|
|
200
157
|
l.add("app-reset");
|
|
201
158
|
}, 50));
|
|
202
159
|
}
|
|
203
|
-
let
|
|
160
|
+
let oe = Date.now();
|
|
204
161
|
function ce() {
|
|
205
162
|
const e = Date.now();
|
|
206
|
-
return e -
|
|
163
|
+
return e - oe > 500 ? (oe = e, !0) : !1;
|
|
207
164
|
}
|
|
208
|
-
let
|
|
209
|
-
function
|
|
210
|
-
return ++
|
|
165
|
+
let Le = 0;
|
|
166
|
+
function se() {
|
|
167
|
+
return ++Le;
|
|
211
168
|
}
|
|
212
|
-
async function
|
|
169
|
+
async function ut(e) {
|
|
213
170
|
if (!ce())
|
|
214
171
|
return;
|
|
215
|
-
let
|
|
172
|
+
let t = !1, a;
|
|
216
173
|
const l = (r) => {
|
|
217
|
-
|
|
218
|
-
}, o =
|
|
219
|
-
return
|
|
174
|
+
a = r, t = !0;
|
|
175
|
+
}, o = se();
|
|
176
|
+
return c.on("confirmDlgResult" + o, l), c.emit("confirmDlg", { ...e, seq: o }), await ee(() => t), console.log("confirm dlg closed", o, t, a), c.off("confirmDlgResult" + o, l), a;
|
|
220
177
|
}
|
|
221
|
-
async function
|
|
178
|
+
async function pt(e) {
|
|
222
179
|
if (!ce())
|
|
223
180
|
return;
|
|
224
|
-
let
|
|
181
|
+
let t = !1, a;
|
|
225
182
|
const l = (r) => {
|
|
226
|
-
|
|
227
|
-
}, o =
|
|
228
|
-
return
|
|
229
|
-
}
|
|
230
|
-
function
|
|
231
|
-
|
|
232
|
-
}
|
|
233
|
-
function
|
|
234
|
-
|
|
183
|
+
a = r, t = !0;
|
|
184
|
+
}, o = se();
|
|
185
|
+
return c.on("promptDlgResult" + o, l), c.emit("promptDlg", { ...e, seq: o }), await ee(() => t), console.log("prompt dlg closed", o, t, a), c.off("promptDlgResult" + o, l), a;
|
|
186
|
+
}
|
|
187
|
+
function _t() {
|
|
188
|
+
c.emit("openWaitDlg");
|
|
189
|
+
}
|
|
190
|
+
function dt() {
|
|
191
|
+
c.emit("closeWaitDlg");
|
|
192
|
+
}
|
|
193
|
+
class it {
|
|
194
|
+
constructor(t, a) {
|
|
195
|
+
U(this, "master");
|
|
196
|
+
U(this, "localeHook");
|
|
197
|
+
U(this, "alreadySync", !1);
|
|
198
|
+
U(this, "handlers", [
|
|
199
|
+
(t) => this.onDarkChange(t),
|
|
200
|
+
(t) => this.onLocaleChange(t),
|
|
201
|
+
(t) => this.onPermissionChange(t),
|
|
202
|
+
(t) => this.onLastAppPathChange(t),
|
|
203
|
+
() => this.onSync()
|
|
204
|
+
]);
|
|
205
|
+
this.master = t, this.localeHook = a, c.on("globalStateDarkChange", this.handlers[0]), c.on("globalStateLocaleChange", this.handlers[1]), c.on("globalStatePermissionChange", this.handlers[2]), c.on("globalStateLastAppPathChange", this.handlers[3]), this.master && c.on("globalStateSync", this.handlers[4]);
|
|
206
|
+
}
|
|
207
|
+
async sync() {
|
|
208
|
+
var a;
|
|
209
|
+
if (this.master) {
|
|
210
|
+
console.assert(!1, "master can not call sync");
|
|
211
|
+
return;
|
|
212
|
+
}
|
|
213
|
+
if (this.alreadySync) {
|
|
214
|
+
console.assert(!1, "call sync duplicate");
|
|
215
|
+
return;
|
|
216
|
+
}
|
|
217
|
+
c.emit("globalStateSync");
|
|
218
|
+
const t = C();
|
|
219
|
+
await ((a = this.localeHook) == null ? void 0 : a.call(this, t.locale)), this.alreadySync = !0;
|
|
220
|
+
}
|
|
221
|
+
dispose() {
|
|
222
|
+
c.off("globalStateDarkChange", this.handlers[0]), c.off("globalStateLocaleChange", this.handlers[1]), c.off("globalStatePermissionChange", this.handlers[2]), c.off("globalStateLastAppPathChange", this.handlers[3]), this.master && c.off("globalStateSync", this.handlers[4]);
|
|
223
|
+
}
|
|
224
|
+
onDarkChange(t) {
|
|
225
|
+
const a = C();
|
|
226
|
+
a.dark = t;
|
|
227
|
+
}
|
|
228
|
+
onLocaleChange(t) {
|
|
229
|
+
var l;
|
|
230
|
+
const a = C();
|
|
231
|
+
a.locale = t, this.alreadySync && ((l = this.localeHook) == null || l.call(this, t));
|
|
232
|
+
}
|
|
233
|
+
onPermissionChange(t) {
|
|
234
|
+
const a = C();
|
|
235
|
+
a.permissionObjects = t[0], a.permissionChecksum = t[1];
|
|
236
|
+
}
|
|
237
|
+
onLastAppPathChange(t) {
|
|
238
|
+
const a = C();
|
|
239
|
+
a.lastAppPath = t;
|
|
240
|
+
}
|
|
241
|
+
onSync() {
|
|
242
|
+
const t = C();
|
|
243
|
+
c.emit("globalStateDarkChange", t.dark), c.emit("globalStateLocaleChange", t.locale), c.emit("globalStatePermissionChange", [
|
|
244
|
+
t.permissionObjects,
|
|
245
|
+
t.permissionChecksum
|
|
246
|
+
]), c.emit("globalStateLastAppPathChange", t.lastAppPath);
|
|
247
|
+
}
|
|
235
248
|
}
|
|
236
|
-
function
|
|
237
|
-
|
|
249
|
+
function ft(e, t) {
|
|
250
|
+
c.emit("message", { type: "error", text: e, timeout: t });
|
|
238
251
|
}
|
|
239
|
-
function
|
|
240
|
-
|
|
252
|
+
function gt(e, t) {
|
|
253
|
+
c.emit("message", { type: "info", text: e, timeout: t });
|
|
241
254
|
}
|
|
242
|
-
function
|
|
243
|
-
|
|
255
|
+
function vt(e, t) {
|
|
256
|
+
c.emit("message", { type: "success", text: e, timeout: t });
|
|
244
257
|
}
|
|
245
|
-
function
|
|
246
|
-
|
|
258
|
+
function mt(e, t) {
|
|
259
|
+
c.emit("message", { type: "warning", text: e, timeout: t });
|
|
247
260
|
}
|
|
248
|
-
var
|
|
249
|
-
function
|
|
261
|
+
var Ee = /* @__PURE__ */ ((e) => (e.list_app_group = "list_app_group", e.create_app_group = "create_app_group", e.delete_app_group = "delete_app_group", e.update_app_group = "update_app_group", e.arrange_app_group = "arrange_app_group", e.list_app = "list_app", e.get_app = "get_app", e.create_app = "create_app", e.delete_app = "delete_app", e.update_app = "update_app", e.list_app_release = "list_app_release", e.get_app_release = "get_app_release", e.create_app_release = "create_app_release", e.delete_app_release = "delete_app_release", e.deploy_app_release = "deploy_app_release", e.open_app_layer = "open_app_layer", e.open_app = "open_app", e.list_calc_space = "list_calc_space", e.get_calc_space = "get_calc_space", e.create_calc_space = "create_calc_space", e.delete_calc_space = "delete_calc_space", e.update_calc_space = "update_calc_space", e.arrange_calc_space = "arrange_calc_space", e.list_func_group = "list_func_group", e.create_func_group = "create_func_group", e.delete_func_group = "delete_func_group", e.update_func_group = "update_func_group", e.arrange_func_group = "arrange_func_group", e.list_func = "list_func", e.get_func = "get_func", e.create_func = "create_func", e.delete_func = "delete_func", e.update_func = "update_func", e.debug_func = "debug_func", e.call_func = "call_func", e.list_func_release = "list_func_release", e.get_func_release = "get_func_release", e.create_func_release = "create_func_release", e.delete_func_release = "delete_func_release", e.deploy_func_release = "deploy_func_release", e.list_flow_group = "list_flow_group", e.create_flow_group = "create_flow_group", e.delete_flow_group = "delete_flow_group", e.update_flow_group = "update_flow_group", e.arrange_flow_group = "arrange_flow_group", e.list_flow = "list_flow", e.get_flow = "get_flow", e.create_flow = "create_flow", e.delete_flow = "delete_flow", e.update_flow = "update_flow", e.call_flow = "call_flow", e.list_flow_release = "list_flow_release", e.get_flow_release = "get_flow_release", e.create_flow_release = "create_flow_release", e.delete_flow_release = "delete_flow_release", e.deploy_flow_release = "deploy_flow_release", e.list_task = "list_task", e.get_task = "get_task", e.create_task = "create_task", e.delete_task = "delete_task", e.update_task = "update_task", e.call_task = "call_task", e.open_calc_layer = "open_calc_layer", e.list_db_space = "list_db_space", e.get_db_space = "get_db_space", e.create_db_space = "create_db_space", e.delete_db_space = "delete_db_space", e.update_db_space = "update_db_space", e.arrange_db_space = "arrange_db_space", e.list_model_group = "list_model_group", e.create_model_group = "create_model_group", e.delete_model_group = "delete_model_group", e.update_model_group = "update_model_group", e.arrange_model_group = "arrange_model_group", e.list_model = "list_model", e.get_model = "get_model", e.create_model = "create_model", e.delete_model = "delete_model", e.update_model = "update_model", e.get_model_data = "get_model_data", e.create_model_data = "create_model_data", e.delete_model_data = "delete_model_data", e.update_model_data = "update_model_data", e.get_graph = "get_graph", e.update_graph = "update_graph", e.list_change = "list_change", e.apply_change = "apply_change", e.open_data_layer = "open_data_layer", e.list_asset_space = "list_asset_space", e.get_asset_space = "get_asset_space", e.create_asset_space = "create_asset_space", e.delete_asset_space = "delete_asset_space", e.update_asset_space = "update_asset_space", e.arrange_asset_space = "arrange_asset_space", e.list_dir = "list_dir", e.create_dir = "create_dir", e.delete_dir = "delete_dir", e.update_dir = "update_dir", e.move_dir = "move_dir", e.list_asset = "list_asset", e.get_asset = "get_asset", e.create_asset = "create_asset", e.delete_asset = "delete_asset", e.update_asset = "update_asset", e.move_asset = "move_asset", e.open_asset_layer = "open_asset_layer", e.list_org_member = "list_org_member", e.add_org_member = "add_org_member", e.remove_org_member = "remove_org_member", e.update_org_member = "update_org_member", e.list_org_role = "list_org_role", e.get_org_role = "get_org_role", e.create_org_role = "create_org_role", e.delete_org_role = "delete_org_role", e.update_org_role = "update_org_role", e.arrange_org_role = "arrange_org_role", e.get_org_structure = "get_org_structure", e.update_org_structure = "update_org_structure", e.filter_model = "filter_model", e))(Ee || {});
|
|
262
|
+
function le(e, t) {
|
|
250
263
|
if (!e)
|
|
251
264
|
return !1;
|
|
252
|
-
let
|
|
253
|
-
return Object.keys(
|
|
254
|
-
if (Object.keys(
|
|
265
|
+
let a = e;
|
|
266
|
+
return Object.keys(a).length <= 0 || (t.split("/").forEach((o) => {
|
|
267
|
+
if (Object.keys(a).length <= 0)
|
|
255
268
|
return !0;
|
|
256
|
-
if (
|
|
257
|
-
|
|
269
|
+
if (a[o])
|
|
270
|
+
a = a[o];
|
|
258
271
|
else
|
|
259
272
|
return !1;
|
|
260
|
-
}), Object.keys(
|
|
273
|
+
}), Object.keys(a).length <= 0);
|
|
261
274
|
}
|
|
262
|
-
const
|
|
275
|
+
const Me = [
|
|
263
276
|
{
|
|
264
277
|
app: "x-passport-mf",
|
|
265
278
|
path: "/passport/login",
|
|
@@ -367,164 +380,229 @@ const Be = [
|
|
|
367
380
|
mainActive: 2
|
|
368
381
|
}
|
|
369
382
|
];
|
|
370
|
-
function
|
|
371
|
-
let
|
|
383
|
+
function G(e) {
|
|
384
|
+
let t, a = 0;
|
|
372
385
|
const l = e.split("/").filter((o) => o.trim() !== "");
|
|
373
|
-
return
|
|
374
|
-
const r = o.path.split("/").filter((
|
|
386
|
+
return Me.forEach((o) => {
|
|
387
|
+
const r = o.path.split("/").filter((s) => s.trim() !== "");
|
|
375
388
|
let n = 0;
|
|
376
|
-
for (let
|
|
389
|
+
for (let s = 0; s < l.length && !(s >= r.length || l[s] !== r[s]); s++)
|
|
377
390
|
n++;
|
|
378
|
-
n > 0 && n >=
|
|
379
|
-
}),
|
|
380
|
-
}
|
|
381
|
-
const
|
|
382
|
-
function b(e,
|
|
383
|
-
const
|
|
384
|
-
|
|
385
|
-
const l =
|
|
391
|
+
n > 0 && n >= a && (t = o, a = n);
|
|
392
|
+
}), t;
|
|
393
|
+
}
|
|
394
|
+
const X = i("");
|
|
395
|
+
function b(e, t) {
|
|
396
|
+
const a = C();
|
|
397
|
+
t === "/" && (t = a.lastAppPath);
|
|
398
|
+
const l = G(e), o = G(t);
|
|
386
399
|
if (!l) {
|
|
387
400
|
console.assert(!1, "invalid to route meta");
|
|
388
401
|
return;
|
|
389
402
|
}
|
|
390
|
-
if (console.info(`~~~~routeChange~~~~ ${
|
|
403
|
+
if (console.info(`~~~~routeChange~~~~ ${t} -> ${e}`), !o)
|
|
391
404
|
return;
|
|
392
|
-
const r = l.app === o.app, n = l.path === o.path,
|
|
393
|
-
r ? n ?
|
|
405
|
+
const r = l.app === o.app, n = l.path === o.path, s = l.level >= o.level;
|
|
406
|
+
r ? n ? X.value = "" : X.value = s ? "inner-left" : "inner-right" : (X.value = "", Be(l.app, s));
|
|
394
407
|
}
|
|
395
|
-
function
|
|
396
|
-
return !!
|
|
408
|
+
function Ue() {
|
|
409
|
+
return !!j.get("accessToken");
|
|
397
410
|
}
|
|
398
|
-
function
|
|
399
|
-
return !!
|
|
411
|
+
function $e() {
|
|
412
|
+
return !!j.get("activeOrg");
|
|
400
413
|
}
|
|
401
|
-
function
|
|
402
|
-
const l =
|
|
414
|
+
function ht(e, t, a) {
|
|
415
|
+
const l = Ue(), o = $e(), r = G(e.path);
|
|
403
416
|
if (!r) {
|
|
404
|
-
|
|
417
|
+
a();
|
|
405
418
|
return;
|
|
406
419
|
}
|
|
407
420
|
if (r.requiredState === "auth")
|
|
408
421
|
if (l)
|
|
409
422
|
if (o) {
|
|
410
423
|
const n = "/main";
|
|
411
|
-
b(n,
|
|
424
|
+
b(n, t.path), a({ path: n });
|
|
412
425
|
} else
|
|
413
|
-
b(e.path,
|
|
426
|
+
b(e.path, t.path), a();
|
|
414
427
|
else {
|
|
415
428
|
const n = "/passport/login";
|
|
416
|
-
b(n,
|
|
429
|
+
b(n, t.path), a({ path: n });
|
|
417
430
|
}
|
|
418
431
|
else if (r.requiredState === "org")
|
|
419
432
|
if (l)
|
|
420
433
|
if (o)
|
|
421
|
-
b(e.path,
|
|
434
|
+
b(e.path, t.path), a();
|
|
422
435
|
else {
|
|
423
436
|
const n = "/org/joinOrCreate";
|
|
424
|
-
b(n,
|
|
437
|
+
b(n, t.path), a({ path: n });
|
|
425
438
|
}
|
|
426
439
|
else {
|
|
427
440
|
const n = "/passport/login";
|
|
428
|
-
b(n,
|
|
441
|
+
b(n, t.path), a({ path: n });
|
|
429
442
|
}
|
|
430
443
|
else if (l)
|
|
431
444
|
if (o) {
|
|
432
445
|
const n = "/main";
|
|
433
|
-
b(n,
|
|
446
|
+
b(n, t.path), a({ path: n });
|
|
434
447
|
} else {
|
|
435
448
|
const n = "/org/joinOrCreate";
|
|
436
|
-
b(n,
|
|
449
|
+
b(n, t.path), a({ path: n });
|
|
437
450
|
}
|
|
438
451
|
else
|
|
439
|
-
b(e.path,
|
|
440
|
-
}
|
|
441
|
-
|
|
442
|
-
|
|
452
|
+
b(e.path, t.path), a();
|
|
453
|
+
}
|
|
454
|
+
const C = ne(
|
|
455
|
+
"global",
|
|
456
|
+
() => {
|
|
457
|
+
const e = i(), t = i("en"), a = i({}), l = i(""), o = i("");
|
|
458
|
+
return R(e, (r) => {
|
|
459
|
+
c.emit("globalStateDarkChange", r);
|
|
460
|
+
}), R(t, (r) => {
|
|
461
|
+
c.emit("globalStateLocaleChange", r);
|
|
462
|
+
}), R([a, l], (r) => {
|
|
463
|
+
c.emit("globalStatePermissionChange", r);
|
|
464
|
+
}), R(o, (r) => {
|
|
465
|
+
c.emit("globalStateLastAppPathChange", r);
|
|
466
|
+
}), {
|
|
467
|
+
dark: e,
|
|
468
|
+
locale: t,
|
|
469
|
+
permissionObjects: a,
|
|
470
|
+
permissionChecksum: l,
|
|
471
|
+
lastAppPath: o
|
|
472
|
+
};
|
|
473
|
+
},
|
|
474
|
+
{
|
|
475
|
+
persist: [
|
|
476
|
+
{
|
|
477
|
+
paths: ["dark", "locale"],
|
|
478
|
+
storage: localStorage
|
|
479
|
+
}
|
|
480
|
+
]
|
|
481
|
+
}
|
|
482
|
+
), ue = ne("viewMgr", () => {
|
|
483
|
+
const e = i([]);
|
|
484
|
+
function t() {
|
|
485
|
+
return e.value.length <= 0;
|
|
486
|
+
}
|
|
487
|
+
function a() {
|
|
488
|
+
const u = e.value.length;
|
|
489
|
+
if (u > 0)
|
|
490
|
+
return e.value[u - 1];
|
|
491
|
+
}
|
|
492
|
+
function l(u) {
|
|
493
|
+
return e.value.find((_) => _ === u) !== void 0;
|
|
494
|
+
}
|
|
495
|
+
function o(u) {
|
|
496
|
+
e.value.push(u);
|
|
497
|
+
}
|
|
498
|
+
function r(u) {
|
|
499
|
+
const _ = e.value.findIndex((h) => h === u);
|
|
500
|
+
_ !== -1 && e.value.splice(_, 1);
|
|
501
|
+
}
|
|
502
|
+
function n() {
|
|
503
|
+
console.assert(e.value.length > 0), e.value.pop();
|
|
504
|
+
}
|
|
505
|
+
function s() {
|
|
506
|
+
e.value = [];
|
|
507
|
+
}
|
|
508
|
+
return {
|
|
509
|
+
views: e,
|
|
510
|
+
isEmpty: t,
|
|
511
|
+
lastView: a,
|
|
512
|
+
hasView: l,
|
|
513
|
+
addView: o,
|
|
514
|
+
delView: r,
|
|
515
|
+
popView: n,
|
|
516
|
+
clearViews: s
|
|
517
|
+
};
|
|
518
|
+
});
|
|
519
|
+
function te(e, t) {
|
|
520
|
+
const a = ue(), l = f({
|
|
443
521
|
get() {
|
|
444
|
-
return
|
|
522
|
+
return a.hasView(e);
|
|
445
523
|
},
|
|
446
524
|
set(r) {
|
|
447
|
-
r ?
|
|
525
|
+
r ? a.addView(e) : a.delView(e);
|
|
448
526
|
}
|
|
449
527
|
}), o = (r) => {
|
|
450
|
-
|
|
528
|
+
t == null || t(r), l.value = !0;
|
|
451
529
|
};
|
|
452
|
-
return
|
|
453
|
-
|
|
454
|
-
}),
|
|
455
|
-
|
|
530
|
+
return A(() => {
|
|
531
|
+
c.on(e, o);
|
|
532
|
+
}), T(() => {
|
|
533
|
+
c.off(e, o);
|
|
456
534
|
}), { open: l };
|
|
457
535
|
}
|
|
458
|
-
const
|
|
536
|
+
const We = /* @__PURE__ */ B({
|
|
459
537
|
__name: "index",
|
|
460
538
|
setup(e) {
|
|
461
|
-
const
|
|
539
|
+
const t = Z(), { open: a } = te("confirmDlgInternal"), l = i(""), o = i(""), r = i(), n = i(), s = f(() => {
|
|
462
540
|
var d;
|
|
463
541
|
return ((d = r.value) == null ? void 0 : d.color) ?? "primary";
|
|
464
|
-
}),
|
|
542
|
+
}), u = f(() => {
|
|
465
543
|
var d;
|
|
466
|
-
return ((d = r.value) == null ? void 0 : d.text) ??
|
|
467
|
-
}),
|
|
544
|
+
return ((d = r.value) == null ? void 0 : d.text) ?? t.t("cancel");
|
|
545
|
+
}), _ = f(() => {
|
|
468
546
|
var d;
|
|
469
547
|
return ((d = n.value) == null ? void 0 : d.color) ?? "primary";
|
|
470
|
-
}),
|
|
548
|
+
}), h = f(() => {
|
|
471
549
|
var d;
|
|
472
|
-
return ((d = n.value) == null ? void 0 : d.text) ??
|
|
550
|
+
return ((d = n.value) == null ? void 0 : d.text) ?? t.t("confirm");
|
|
473
551
|
});
|
|
474
|
-
let
|
|
475
|
-
const
|
|
476
|
-
l.value = d.title, o.value = d.text, r.value = d.cancel, n.value = d.confirm,
|
|
552
|
+
let q = 0, S = !1;
|
|
553
|
+
const W = (d) => {
|
|
554
|
+
l.value = d.title, o.value = d.text, r.value = d.cancel, n.value = d.confirm, q = d.seq, S = !1, a.value = !0;
|
|
477
555
|
};
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
}),
|
|
481
|
-
|
|
556
|
+
A(() => {
|
|
557
|
+
c.on("confirmDlg", W);
|
|
558
|
+
}), T(() => {
|
|
559
|
+
c.off("confirmDlg", W);
|
|
482
560
|
});
|
|
483
|
-
const
|
|
484
|
-
|
|
561
|
+
const z = () => {
|
|
562
|
+
a.value = !1, S || (c.emit("confirmDlgResult" + q, !0), S = !0);
|
|
485
563
|
};
|
|
486
|
-
return
|
|
487
|
-
!d && !
|
|
488
|
-
}), (d,
|
|
489
|
-
const
|
|
490
|
-
return
|
|
491
|
-
modelValue:
|
|
492
|
-
"onUpdate:modelValue":
|
|
564
|
+
return R(a, (d) => {
|
|
565
|
+
!d && !S && (c.emit("confirmDlgResult" + q, !1), S = !0);
|
|
566
|
+
}), (d, x) => {
|
|
567
|
+
const D = v("v-card-text"), L = v("v-btn"), H = v("v-card-actions"), p = v("v-card"), w = v("v-dialog");
|
|
568
|
+
return k(), I(w, {
|
|
569
|
+
modelValue: K(a),
|
|
570
|
+
"onUpdate:modelValue": x[1] || (x[1] = (E) => Y(a) ? a.value = E : null),
|
|
493
571
|
onKeydown: [
|
|
494
|
-
|
|
495
|
-
|
|
572
|
+
x[2] || (x[2] = N($((E) => a.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
573
|
+
N($(z, ["stop", "prevent"]), ["enter"])
|
|
496
574
|
],
|
|
497
575
|
transition: "dialog-top-transition",
|
|
498
576
|
"max-width": "600px"
|
|
499
577
|
}, {
|
|
500
|
-
default:
|
|
501
|
-
y(
|
|
502
|
-
default:
|
|
503
|
-
y(
|
|
504
|
-
default:
|
|
505
|
-
|
|
578
|
+
default: m(() => [
|
|
579
|
+
y(p, { title: l.value }, {
|
|
580
|
+
default: m(() => [
|
|
581
|
+
y(D, null, {
|
|
582
|
+
default: m(() => [
|
|
583
|
+
O(V(o.value), 1)
|
|
506
584
|
]),
|
|
507
585
|
_: 1
|
|
508
586
|
}),
|
|
509
|
-
y(
|
|
510
|
-
default:
|
|
511
|
-
y(
|
|
512
|
-
onClick:
|
|
513
|
-
color:
|
|
587
|
+
y(H, { class: "d-flex justify-end" }, {
|
|
588
|
+
default: m(() => [
|
|
589
|
+
y(L, {
|
|
590
|
+
onClick: x[0] || (x[0] = (E) => a.value = !1),
|
|
591
|
+
color: s.value,
|
|
514
592
|
variant: "text"
|
|
515
593
|
}, {
|
|
516
|
-
default:
|
|
517
|
-
|
|
594
|
+
default: m(() => [
|
|
595
|
+
O(V(u.value), 1)
|
|
518
596
|
]),
|
|
519
597
|
_: 1
|
|
520
598
|
}, 8, ["color"]),
|
|
521
|
-
y(
|
|
522
|
-
onClick:
|
|
523
|
-
color:
|
|
599
|
+
y(L, {
|
|
600
|
+
onClick: z,
|
|
601
|
+
color: _.value,
|
|
524
602
|
variant: "text"
|
|
525
603
|
}, {
|
|
526
|
-
default:
|
|
527
|
-
|
|
604
|
+
default: m(() => [
|
|
605
|
+
O(V(h.value), 1)
|
|
528
606
|
]),
|
|
529
607
|
_: 1
|
|
530
608
|
}, 8, ["color"])
|
|
@@ -539,22 +617,22 @@ const Ue = /* @__PURE__ */ T({
|
|
|
539
617
|
}, 8, ["modelValue", "onKeydown"]);
|
|
540
618
|
};
|
|
541
619
|
}
|
|
542
|
-
}),
|
|
543
|
-
/* @__PURE__ */
|
|
544
|
-
/* @__PURE__ */
|
|
545
|
-
/* @__PURE__ */
|
|
546
|
-
/* @__PURE__ */
|
|
547
|
-
/* @__PURE__ */
|
|
548
|
-
/* @__PURE__ */
|
|
549
|
-
/* @__PURE__ */
|
|
550
|
-
/* @__PURE__ */
|
|
551
|
-
/* @__PURE__ */
|
|
552
|
-
/* @__PURE__ */
|
|
553
|
-
/* @__PURE__ */
|
|
554
|
-
/* @__PURE__ */
|
|
555
|
-
], -1)),
|
|
556
|
-
|
|
557
|
-
],
|
|
620
|
+
}), ze = (e) => (we("data-v-f4ad116e"), e = e(), ye(), e), He = /* @__PURE__ */ ze(() => /* @__PURE__ */ g("div", { class: "lds-spinner" }, [
|
|
621
|
+
/* @__PURE__ */ g("div"),
|
|
622
|
+
/* @__PURE__ */ g("div"),
|
|
623
|
+
/* @__PURE__ */ g("div"),
|
|
624
|
+
/* @__PURE__ */ g("div"),
|
|
625
|
+
/* @__PURE__ */ g("div"),
|
|
626
|
+
/* @__PURE__ */ g("div"),
|
|
627
|
+
/* @__PURE__ */ g("div"),
|
|
628
|
+
/* @__PURE__ */ g("div"),
|
|
629
|
+
/* @__PURE__ */ g("div"),
|
|
630
|
+
/* @__PURE__ */ g("div"),
|
|
631
|
+
/* @__PURE__ */ g("div"),
|
|
632
|
+
/* @__PURE__ */ g("div")
|
|
633
|
+
], -1)), Fe = [
|
|
634
|
+
He
|
|
635
|
+
], Ke = /* @__PURE__ */ B({
|
|
558
636
|
__name: "index",
|
|
559
637
|
props: {
|
|
560
638
|
zIndex: {
|
|
@@ -563,21 +641,21 @@ const Ue = /* @__PURE__ */ T({
|
|
|
563
641
|
}
|
|
564
642
|
},
|
|
565
643
|
setup(e) {
|
|
566
|
-
const
|
|
567
|
-
background:
|
|
568
|
-
zIndex:
|
|
644
|
+
const t = P(), a = e, l = f(() => ({
|
|
645
|
+
background: t.current.value.dark ? "#1e1e1e" : "#ffffff",
|
|
646
|
+
zIndex: a.zIndex
|
|
569
647
|
}));
|
|
570
|
-
return (o, r) => (
|
|
648
|
+
return (o, r) => (k(), J("div", {
|
|
571
649
|
class: "x-cont",
|
|
572
|
-
style:
|
|
573
|
-
},
|
|
650
|
+
style: he(l.value)
|
|
651
|
+
}, Fe, 4));
|
|
574
652
|
}
|
|
575
|
-
}), pe = (e,
|
|
576
|
-
const
|
|
577
|
-
for (const [l, o] of
|
|
578
|
-
|
|
579
|
-
return
|
|
580
|
-
},
|
|
653
|
+
}), pe = (e, t) => {
|
|
654
|
+
const a = e.__vccOpts || e;
|
|
655
|
+
for (const [l, o] of t)
|
|
656
|
+
a[l] = o;
|
|
657
|
+
return a;
|
|
658
|
+
}, Ne = /* @__PURE__ */ pe(Ke, [["__scopeId", "data-v-f4ad116e"]]), Ge = /* @__PURE__ */ B({
|
|
581
659
|
__name: "item",
|
|
582
660
|
props: {
|
|
583
661
|
id: {},
|
|
@@ -586,19 +664,19 @@ const Ue = /* @__PURE__ */ T({
|
|
|
586
664
|
timeout: { default: 5e3 }
|
|
587
665
|
},
|
|
588
666
|
emits: ["timeout"],
|
|
589
|
-
setup(e, { emit:
|
|
590
|
-
const
|
|
591
|
-
return
|
|
667
|
+
setup(e, { emit: t }) {
|
|
668
|
+
const a = e, l = i(!0), o = t;
|
|
669
|
+
return A(() => {
|
|
592
670
|
setTimeout(() => {
|
|
593
|
-
o("timeout",
|
|
594
|
-
},
|
|
595
|
-
}),
|
|
596
|
-
r || o("timeout",
|
|
671
|
+
o("timeout", a.id);
|
|
672
|
+
}, a.timeout);
|
|
673
|
+
}), R(l, (r) => {
|
|
674
|
+
r || o("timeout", a.id);
|
|
597
675
|
}), (r, n) => {
|
|
598
|
-
const
|
|
599
|
-
return
|
|
676
|
+
const s = v("v-alert");
|
|
677
|
+
return k(), I(s, {
|
|
600
678
|
modelValue: l.value,
|
|
601
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
679
|
+
"onUpdate:modelValue": n[0] || (n[0] = (u) => l.value = u),
|
|
602
680
|
class: "mt-2",
|
|
603
681
|
"max-width": "90%",
|
|
604
682
|
width: "500px",
|
|
@@ -610,128 +688,128 @@ const Ue = /* @__PURE__ */ T({
|
|
|
610
688
|
}, null, 8, ["modelValue", "type", "text"]);
|
|
611
689
|
};
|
|
612
690
|
}
|
|
613
|
-
}),
|
|
691
|
+
}), Xe = /* @__PURE__ */ B({
|
|
614
692
|
__name: "index",
|
|
615
693
|
setup(e) {
|
|
616
|
-
const
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
}),
|
|
620
|
-
|
|
694
|
+
const t = xe({ items: [] });
|
|
695
|
+
A(() => {
|
|
696
|
+
c.on("message", a);
|
|
697
|
+
}), T(() => {
|
|
698
|
+
c.off("message", a);
|
|
621
699
|
});
|
|
622
|
-
const
|
|
623
|
-
r(
|
|
624
|
-
}, l = (
|
|
625
|
-
n(
|
|
700
|
+
const a = (s) => {
|
|
701
|
+
r(s.type, s.text, s.timeout);
|
|
702
|
+
}, l = (s) => {
|
|
703
|
+
n(s);
|
|
626
704
|
};
|
|
627
705
|
let o = 0;
|
|
628
|
-
const r = (
|
|
629
|
-
const
|
|
630
|
-
|
|
631
|
-
}, n = (
|
|
632
|
-
const
|
|
633
|
-
|
|
706
|
+
const r = (s, u, _) => {
|
|
707
|
+
const h = o++;
|
|
708
|
+
t.items.push({ id: h, type: s, text: u, timeout: _ });
|
|
709
|
+
}, n = (s) => {
|
|
710
|
+
const u = t.items.findIndex((_) => _.id === s);
|
|
711
|
+
u >= 0 && t.items.splice(u, 1);
|
|
634
712
|
};
|
|
635
|
-
return (
|
|
636
|
-
onClick:
|
|
713
|
+
return (s, u) => (k(), J("div", {
|
|
714
|
+
onClick: u[0] || (u[0] = $(() => {
|
|
637
715
|
}, ["stop"])),
|
|
638
716
|
class: "x-cont d-flex flex-column-reverse align-center"
|
|
639
717
|
}, [
|
|
640
|
-
(
|
|
718
|
+
(k(!0), J(be, null, ke(t.items, (_) => (k(), I(Ge, {
|
|
641
719
|
onTimeout: l,
|
|
642
|
-
id:
|
|
643
|
-
type:
|
|
644
|
-
text:
|
|
645
|
-
timeout:
|
|
646
|
-
key:
|
|
720
|
+
id: _.id,
|
|
721
|
+
type: _.type,
|
|
722
|
+
text: _.text,
|
|
723
|
+
timeout: _.timeout,
|
|
724
|
+
key: _.id
|
|
647
725
|
}, null, 8, ["id", "type", "text", "timeout"]))), 128))
|
|
648
726
|
]));
|
|
649
727
|
}
|
|
650
|
-
}),
|
|
728
|
+
}), Je = /* @__PURE__ */ pe(Xe, [["__scopeId", "data-v-8c2268ea"]]), Qe = /* @__PURE__ */ B({
|
|
651
729
|
__name: "index",
|
|
652
730
|
setup(e) {
|
|
653
|
-
const
|
|
654
|
-
var
|
|
655
|
-
return ((
|
|
656
|
-
}),
|
|
657
|
-
var
|
|
658
|
-
return ((
|
|
659
|
-
}),
|
|
660
|
-
var
|
|
661
|
-
return ((
|
|
662
|
-
}),
|
|
663
|
-
var
|
|
664
|
-
return ((
|
|
731
|
+
const t = Z(), { open: a } = te("promptDlgInternal"), l = i(""), o = i(""), r = i(), n = i(), s = i(), u = i(""), _ = i(), h = i(), q = f(() => {
|
|
732
|
+
var p;
|
|
733
|
+
return ((p = _.value) == null ? void 0 : p.color) ?? "primary";
|
|
734
|
+
}), S = f(() => {
|
|
735
|
+
var p;
|
|
736
|
+
return ((p = _.value) == null ? void 0 : p.text) ?? t.t("cancel");
|
|
737
|
+
}), W = f(() => {
|
|
738
|
+
var p;
|
|
739
|
+
return ((p = h.value) == null ? void 0 : p.color) ?? "primary";
|
|
740
|
+
}), z = f(() => {
|
|
741
|
+
var p;
|
|
742
|
+
return ((p = h.value) == null ? void 0 : p.text) ?? t.t("confirm");
|
|
665
743
|
}), d = i();
|
|
666
|
-
let
|
|
667
|
-
const
|
|
668
|
-
var
|
|
669
|
-
l.value =
|
|
744
|
+
let x = 0, D = !1;
|
|
745
|
+
const L = async (p) => {
|
|
746
|
+
var w;
|
|
747
|
+
l.value = p.title, o.value = p.text, r.value = p.label, n.value = p.placeholder, s.value = p.rules, u.value = p.value, _.value = p.cancel, h.value = p.confirm, x = p.seq, D = !1, a.value = !0, await ee(() => d.value !== void 0, 1e3), (w = d.value) == null || w.focus();
|
|
670
748
|
};
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
}),
|
|
674
|
-
|
|
749
|
+
A(() => {
|
|
750
|
+
c.on("promptDlg", L);
|
|
751
|
+
}), T(() => {
|
|
752
|
+
c.off("promptDlg", L);
|
|
675
753
|
});
|
|
676
|
-
const
|
|
677
|
-
|
|
754
|
+
const H = () => {
|
|
755
|
+
a.value = !1, D || (c.emit("promptDlgResult" + x, u.value ?? ""), D = !0);
|
|
678
756
|
};
|
|
679
|
-
return
|
|
680
|
-
!
|
|
681
|
-
}), (
|
|
682
|
-
const E =
|
|
683
|
-
return
|
|
684
|
-
modelValue:
|
|
685
|
-
"onUpdate:modelValue":
|
|
757
|
+
return R(a, (p) => {
|
|
758
|
+
!p && !D && (c.emit("promptDlgResult" + x, void 0), D = !0);
|
|
759
|
+
}), (p, w) => {
|
|
760
|
+
const E = v("v-card-text"), _e = v("v-text-field"), de = v("v-form"), ae = v("v-btn"), ie = v("v-card-actions"), fe = v("v-card"), ge = v("v-dialog");
|
|
761
|
+
return k(), I(ge, {
|
|
762
|
+
modelValue: K(a),
|
|
763
|
+
"onUpdate:modelValue": w[2] || (w[2] = (M) => Y(a) ? a.value = M : null),
|
|
686
764
|
onKeydown: [
|
|
687
|
-
|
|
688
|
-
|
|
765
|
+
w[3] || (w[3] = N($((M) => a.value = !1, ["stop", "prevent"]), ["esc"])),
|
|
766
|
+
N($(H, ["stop", "prevent"]), ["enter"])
|
|
689
767
|
],
|
|
690
768
|
transition: "dialog-top-transition",
|
|
691
769
|
"max-width": "600px"
|
|
692
770
|
}, {
|
|
693
|
-
default:
|
|
771
|
+
default: m(() => [
|
|
694
772
|
y(fe, { title: l.value }, {
|
|
695
|
-
default:
|
|
696
|
-
o.value ? (
|
|
697
|
-
default:
|
|
698
|
-
|
|
773
|
+
default: m(() => [
|
|
774
|
+
o.value ? (k(), I(E, { key: 0 }, {
|
|
775
|
+
default: m(() => [
|
|
776
|
+
O(V(o.value), 1)
|
|
699
777
|
]),
|
|
700
778
|
_: 1
|
|
701
|
-
})) :
|
|
702
|
-
y(
|
|
703
|
-
default:
|
|
704
|
-
y(
|
|
705
|
-
modelValue:
|
|
706
|
-
"onUpdate:modelValue":
|
|
779
|
+
})) : Ce("", !0),
|
|
780
|
+
y(de, { class: "mx-3" }, {
|
|
781
|
+
default: m(() => [
|
|
782
|
+
y(_e, {
|
|
783
|
+
modelValue: u.value,
|
|
784
|
+
"onUpdate:modelValue": w[0] || (w[0] = (M) => u.value = M),
|
|
707
785
|
label: r.value,
|
|
708
786
|
placeholder: n.value,
|
|
709
|
-
rules:
|
|
787
|
+
rules: s.value,
|
|
710
788
|
ref_key: "target",
|
|
711
789
|
ref: d
|
|
712
790
|
}, null, 8, ["modelValue", "label", "placeholder", "rules"])
|
|
713
791
|
]),
|
|
714
792
|
_: 1
|
|
715
793
|
}),
|
|
716
|
-
y(
|
|
717
|
-
default:
|
|
718
|
-
y(
|
|
719
|
-
onClick:
|
|
720
|
-
color:
|
|
794
|
+
y(ie, { class: "d-flex justify-end" }, {
|
|
795
|
+
default: m(() => [
|
|
796
|
+
y(ae, {
|
|
797
|
+
onClick: w[1] || (w[1] = (M) => a.value = !1),
|
|
798
|
+
color: q.value,
|
|
721
799
|
variant: "text"
|
|
722
800
|
}, {
|
|
723
|
-
default:
|
|
724
|
-
|
|
801
|
+
default: m(() => [
|
|
802
|
+
O(V(S.value), 1)
|
|
725
803
|
]),
|
|
726
804
|
_: 1
|
|
727
805
|
}, 8, ["color"]),
|
|
728
|
-
y(
|
|
729
|
-
onClick:
|
|
730
|
-
color:
|
|
806
|
+
y(ae, {
|
|
807
|
+
onClick: H,
|
|
808
|
+
color: W.value,
|
|
731
809
|
variant: "text"
|
|
732
810
|
}, {
|
|
733
|
-
default:
|
|
734
|
-
|
|
811
|
+
default: m(() => [
|
|
812
|
+
O(V(z.value), 1)
|
|
735
813
|
]),
|
|
736
814
|
_: 1
|
|
737
815
|
}, 8, ["color"])
|
|
@@ -746,37 +824,37 @@ const Ue = /* @__PURE__ */ T({
|
|
|
746
824
|
}, 8, ["modelValue", "onKeydown"]);
|
|
747
825
|
};
|
|
748
826
|
}
|
|
749
|
-
}),
|
|
827
|
+
}), Ye = { class: "mx-auto my-auto" }, Ze = { class: "d-flex align-center justify-center w-100 h-100" }, Pe = /* @__PURE__ */ B({
|
|
750
828
|
__name: "index",
|
|
751
829
|
setup(e) {
|
|
752
|
-
const
|
|
753
|
-
|
|
830
|
+
const t = Z(), { open: a } = te("waitDlg"), l = () => {
|
|
831
|
+
a.value = !0;
|
|
754
832
|
}, o = () => {
|
|
755
|
-
|
|
833
|
+
a.value = !1;
|
|
756
834
|
};
|
|
757
|
-
return
|
|
758
|
-
|
|
759
|
-
}),
|
|
760
|
-
|
|
835
|
+
return A(() => {
|
|
836
|
+
c.on("openWaitDlg", l), c.on("closeWaitDlg", o);
|
|
837
|
+
}), T(() => {
|
|
838
|
+
c.off("openWaitDlg", l), c.off("closeWaitDlg", o);
|
|
761
839
|
}), (r, n) => {
|
|
762
|
-
const
|
|
763
|
-
return
|
|
764
|
-
modelValue:
|
|
765
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
840
|
+
const s = v("v-card"), u = v("v-dialog");
|
|
841
|
+
return k(), I(u, {
|
|
842
|
+
modelValue: K(a),
|
|
843
|
+
"onUpdate:modelValue": n[0] || (n[0] = (_) => Y(a) ? a.value = _ : null),
|
|
766
844
|
persistent: "",
|
|
767
845
|
"no-click-animation": "",
|
|
768
846
|
fullscreen: ""
|
|
769
847
|
}, {
|
|
770
|
-
default:
|
|
771
|
-
|
|
772
|
-
y(
|
|
848
|
+
default: m(() => [
|
|
849
|
+
g("div", Ye, [
|
|
850
|
+
y(s, {
|
|
773
851
|
width: "300px",
|
|
774
852
|
height: "80px",
|
|
775
853
|
loading: ""
|
|
776
854
|
}, {
|
|
777
|
-
default:
|
|
778
|
-
|
|
779
|
-
|
|
855
|
+
default: m(() => [
|
|
856
|
+
g("div", Ze, [
|
|
857
|
+
g("span", null, V(K(t).t("waitingResponse")), 1)
|
|
780
858
|
])
|
|
781
859
|
]),
|
|
782
860
|
_: 1
|
|
@@ -787,97 +865,90 @@ const Ue = /* @__PURE__ */ T({
|
|
|
787
865
|
}, 8, ["modelValue"]);
|
|
788
866
|
};
|
|
789
867
|
}
|
|
790
|
-
}),
|
|
791
|
-
e.component("x-confirm-dlg",
|
|
868
|
+
}), et = (e) => {
|
|
869
|
+
e.component("x-confirm-dlg", We), e.component("x-loading", Ne), e.component("x-message", Je), e.component("x-prompt-dlg", Qe), e.component("x-wait-dlg", Pe);
|
|
792
870
|
};
|
|
793
|
-
function
|
|
794
|
-
const e =
|
|
871
|
+
function wt() {
|
|
872
|
+
const e = P(), t = f(() => e.global.current.value.colors.primary), a = f(() => e.global.current.value.colors.secondary), l = f(() => e.current.value.dark ? "#2e2e2e" : "#bdbdbd"), o = f(() => e.current.value.dark ? "#272727" : "#eeeeee"), r = f(() => e.current.value.dark ? "#1e1e1e" : "#ffffff"), n = f(() => e.current.value.dark ? "#303030" : "#f6f6f6"), s = f(() => e.current.value.dark ? "#ffffff1f" : "#0000001f");
|
|
795
873
|
return {
|
|
796
|
-
primaryColor:
|
|
797
|
-
secondaryColor:
|
|
874
|
+
primaryColor: t,
|
|
875
|
+
secondaryColor: a,
|
|
798
876
|
backgroundColor0: l,
|
|
799
877
|
backgroundColor1: o,
|
|
800
878
|
backgroundColor2: r,
|
|
801
879
|
highlightColor: n,
|
|
802
|
-
borderColor:
|
|
880
|
+
borderColor: s
|
|
803
881
|
};
|
|
804
882
|
}
|
|
805
|
-
function
|
|
806
|
-
const e =
|
|
883
|
+
function yt() {
|
|
884
|
+
const e = Re(), t = re(), a = ue(), l = () => {
|
|
807
885
|
console.log("onPause");
|
|
808
|
-
},
|
|
886
|
+
}, o = () => {
|
|
809
887
|
console.log("onResume");
|
|
810
|
-
},
|
|
811
|
-
var
|
|
812
|
-
if (!
|
|
813
|
-
|
|
888
|
+
}, r = () => {
|
|
889
|
+
var u;
|
|
890
|
+
if (!a.isEmpty()) {
|
|
891
|
+
a.hasView("waitDlg") || a.popView();
|
|
814
892
|
return;
|
|
815
893
|
}
|
|
816
|
-
const
|
|
817
|
-
(
|
|
894
|
+
const s = G(e.path);
|
|
895
|
+
(s == null ? void 0 : s.level) === 0 ? (u = navigator == null ? void 0 : navigator.Backbutton) == null || u.goHome(
|
|
818
896
|
() => {
|
|
819
897
|
},
|
|
820
898
|
() => {
|
|
821
899
|
}
|
|
822
|
-
) :
|
|
823
|
-
},
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
t.locale = f;
|
|
827
|
-
}, s = (f) => {
|
|
828
|
-
t.permissionObjects = f[0], t.permissionChecksum = f[1];
|
|
829
|
-
}, v = (f) => {
|
|
830
|
-
t.lastAppPath = f;
|
|
831
|
-
}, C = (f) => {
|
|
832
|
-
if (f.key === "Escape") {
|
|
833
|
-
n();
|
|
900
|
+
) : t.back();
|
|
901
|
+
}, n = (s) => {
|
|
902
|
+
if (s.key === "Escape") {
|
|
903
|
+
r();
|
|
834
904
|
return;
|
|
835
905
|
}
|
|
836
906
|
};
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
}),
|
|
840
|
-
|
|
907
|
+
A(() => {
|
|
908
|
+
c.on("pause", l), c.on("resume", o), c.on("backbutton", r), window.addEventListener("keydown", n);
|
|
909
|
+
}), T(() => {
|
|
910
|
+
c.off("pause", l), c.off("resume", o), c.off("backbutton", r), window.removeEventListener("keydown", n);
|
|
841
911
|
});
|
|
842
912
|
}
|
|
843
|
-
function
|
|
844
|
-
const e =
|
|
845
|
-
function a
|
|
846
|
-
const o = e.permissionObjects[
|
|
847
|
-
return o ? l ? !(!
|
|
913
|
+
function xt() {
|
|
914
|
+
const e = C();
|
|
915
|
+
function t(a, l) {
|
|
916
|
+
const o = e.permissionObjects[a];
|
|
917
|
+
return o ? l ? !(!le(o.includes, l) || le(o.excludes, l)) : !0 : !1;
|
|
848
918
|
}
|
|
849
|
-
return { verifyPermission:
|
|
919
|
+
return { verifyPermission: t };
|
|
850
920
|
}
|
|
851
|
-
function
|
|
852
|
-
const e =
|
|
853
|
-
return { dark:
|
|
921
|
+
function bt() {
|
|
922
|
+
const e = P(), t = Se(), a = f(() => e.current.value.dark), l = f(() => !!window.cordova), o = f(() => t.width.value <= 1280 ? t.width.value + "px" : t.width.value <= 1920 ? 1920 / 2.5 + "px" : 2560 / 2.5 + "px");
|
|
923
|
+
return { dark: a, sysBarAvail: l, compactWidth: o };
|
|
854
924
|
}
|
|
855
|
-
const
|
|
925
|
+
const kt = { install: et };
|
|
856
926
|
export {
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
927
|
+
it as GlobalState,
|
|
928
|
+
Ee as Permission,
|
|
929
|
+
Be as appAppear,
|
|
930
|
+
dt as closeWaitDlg,
|
|
931
|
+
ct as createAxios,
|
|
932
|
+
kt as default,
|
|
933
|
+
c as eventBus,
|
|
934
|
+
le as isExist,
|
|
935
|
+
G as matchRouteMeta,
|
|
936
|
+
ft as messageError,
|
|
937
|
+
gt as messageInfo,
|
|
938
|
+
vt as messageSuccess,
|
|
939
|
+
mt as messageWarning,
|
|
940
|
+
ht as onBeforeEach,
|
|
941
|
+
ut as openConfirmDlg,
|
|
942
|
+
pt as openPromptDlg,
|
|
943
|
+
_t as openWaitDlg,
|
|
944
|
+
X as routeTransName,
|
|
945
|
+
wt as useColor,
|
|
946
|
+
C as useGlobalStore,
|
|
947
|
+
yt as useMicroApp,
|
|
948
|
+
xt as usePermission,
|
|
949
|
+
bt as useSystem,
|
|
950
|
+
ue as useViewMgrStore,
|
|
951
|
+
te as useViewStack,
|
|
952
|
+
st as waitMs,
|
|
953
|
+
ee as waitUtil
|
|
883
954
|
};
|