ss-component-new 1.3.782 → 1.3.783

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,24 +1,24 @@
1
- import { createElementBlock as N, openBlock as L, createElementVNode as i, renderSlot as D, defineComponent as X, ref as f, resolveComponent as b, createVNode as t, withCtx as l, unref as j, reactive as se, computed as Z, onMounted as fe, createBlock as ee, resolveDirective as ye, createCommentVNode as le, withDirectives as he, normalizeClass as re, toDisplayString as S, Transition as Ce, watch as Q, Fragment as Te, createTextVNode as P, onBeforeUnmount as we } from "vue";
2
- import { _ as H } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
- import { b as ie, p as W, s as ne, u as ke, a as Ue, l as Le, e as $e, v as Ve } from "./index-Bw3sTXPI.js";
1
+ import { createElementBlock as x, openBlock as $, createElementVNode as i, renderSlot as D, defineComponent as J, ref as f, resolveComponent as b, createVNode as t, withCtx as a, unref as H, reactive as ne, computed as W, onMounted as ve, createBlock as ee, resolveDirective as ye, createCommentVNode as se, withDirectives as he, normalizeClass as ce, toDisplayString as N, Transition as Ce, watch as X, Fragment as Te, createTextVNode as j, onBeforeUnmount as we } from "vue";
2
+ import { _ as K } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
+ import { b as re, p as G, s as ie, u as ke, a as Ue, l as Le, e as $e, v as Ve } from "./index-Bw3sTXPI.js";
4
4
  import { _ as te } from "./index.vue_vue_type_script_setup_true_lang-DRzriV-s.js";
5
- import { c as Ae, a as qe, f as Ie, b as ce, E as ue } from "./request-1RPa2bBn.js";
5
+ import { c as Ae, a as qe, f as Ie, b as ue, E as de } from "./request-1RPa2bBn.js";
6
6
  import "./JSEncrypt-B36c1iN5.js";
7
7
  import { u as Fe } from "./index-UB_oCdlo.js";
8
8
  import { useRouter as xe } from "vue-router";
9
9
  import { l as Re } from "./index-DAJxL40d.js";
10
10
  const Ne = {}, Se = { class: "left-wrap" }, De = { class: "left-bg" };
11
- function Ee(h, T) {
12
- return L(), N("div", Se, [
11
+ function Ee(C, w) {
12
+ return $(), x("div", Se, [
13
13
  i("div", De, [
14
- D(h.$slots, "img", {}, void 0, !0)
14
+ D(C.$slots, "img", {}, void 0, !0)
15
15
  ])
16
16
  ]);
17
17
  }
18
- const Me = /* @__PURE__ */ H(Ne, [["render", Ee], ["__scopeId", "data-v-9b7ee6c9"]]), oe = {
18
+ const Me = /* @__PURE__ */ K(Ne, [["render", Ee], ["__scopeId", "data-v-9b7ee6c9"]]), oe = {
19
19
  ACCOUNT: "account",
20
20
  FACE: "face"
21
- }, Oe = { class: "right-wrap" }, Be = { class: "tab-content" }, Pe = { class: "tab-tips" }, je = { class: "tab-content" }, He = { class: "tab-tips" }, Ke = /* @__PURE__ */ X({
21
+ }, Oe = { class: "right-wrap" }, Be = { class: "tab-content" }, Pe = { class: "tab-tips" }, je = { class: "tab-content" }, He = { class: "tab-tips" }, Ke = /* @__PURE__ */ J({
22
22
  __name: "index",
23
23
  props: {
24
24
  tabList: {
@@ -31,38 +31,38 @@ const Me = /* @__PURE__ */ H(Ne, [["render", Ee], ["__scopeId", "data-v-9b7ee6c9
31
31
  }
32
32
  },
33
33
  emits: ["clickLogin", "handleTabChange"],
34
- setup(h, { emit: T }) {
35
- const p = f(oe.ACCOUNT), d = T, C = () => {
34
+ setup(C, { emit: w }) {
35
+ const p = f(oe.ACCOUNT), d = w, T = () => {
36
36
  d("clickLogin", p.value);
37
37
  }, e = (v) => {
38
38
  d("handleTabChange", v);
39
39
  };
40
- return (v, w) => {
41
- const m = b("el-button"), k = b("el-tab-pane"), $ = b("el-tabs");
42
- return L(), N("div", Oe, [
43
- t($, {
40
+ return (v, k) => {
41
+ const m = b("el-button"), U = b("el-tab-pane"), V = b("el-tabs");
42
+ return $(), x("div", Oe, [
43
+ t(V, {
44
44
  modelValue: p.value,
45
- "onUpdate:modelValue": w[0] || (w[0] = (y) => p.value = y),
45
+ "onUpdate:modelValue": k[0] || (k[0] = (h) => p.value = h),
46
46
  class: "right-tabs",
47
47
  onTabChange: e
48
48
  }, {
49
- default: l(() => [
50
- t(k, {
51
- name: j(oe).ACCOUNT
49
+ default: a(() => [
50
+ t(U, {
51
+ name: H(oe).ACCOUNT
52
52
  }, {
53
- label: l(() => [
53
+ label: a(() => [
54
54
  D(v.$slots, "tabLabel1", {}, void 0, !0)
55
55
  ]),
56
- default: l(() => [
56
+ default: a(() => [
57
57
  i("div", Be, [
58
58
  D(v.$slots, "tabContent1", {}, void 0, !0)
59
59
  ]),
60
60
  i("div", {
61
61
  class: "tab-button special",
62
- onClick: C
62
+ onClick: T
63
63
  }, [
64
- t(m, { loading: h.loading }, {
65
- default: l(() => [
64
+ t(m, { loading: C.loading }, {
65
+ default: a(() => [
66
66
  D(v.$slots, "tabButton1", {}, void 0, !0)
67
67
  ]),
68
68
  _: 3
@@ -74,13 +74,13 @@ const Me = /* @__PURE__ */ H(Ne, [["render", Ee], ["__scopeId", "data-v-9b7ee6c9
74
74
  ]),
75
75
  _: 3
76
76
  }, 8, ["name"]),
77
- t(k, {
78
- name: j(oe).FACE
77
+ t(U, {
78
+ name: H(oe).FACE
79
79
  }, {
80
- label: l(() => [
80
+ label: a(() => [
81
81
  D(v.$slots, "tabLabel2", {}, void 0, !0)
82
82
  ]),
83
- default: l(() => [
83
+ default: a(() => [
84
84
  i("div", je, [
85
85
  D(v.$slots, "tabContent2", {}, void 0, !0)
86
86
  ]),
@@ -96,15 +96,15 @@ const Me = /* @__PURE__ */ H(Ne, [["render", Ee], ["__scopeId", "data-v-9b7ee6c9
96
96
  ]);
97
97
  };
98
98
  }
99
- }), ze = /* @__PURE__ */ H(Ke, [["__scopeId", "data-v-8b1962f0"]]), Qe = /^[a-z][a-z0-9+.-]*:\/\//i, de = (h) => Qe.test(h);
100
- function We(h) {
101
- de(h) || (h = `http://${h}`);
99
+ }), ze = /* @__PURE__ */ K(Ke, [["__scopeId", "data-v-8b1962f0"]]), Qe = /^[a-z][a-z0-9+.-]*:\/\//i, pe = (C) => Qe.test(C);
100
+ function We(C) {
101
+ pe(C) || (C = `http://${C}`);
102
102
  try {
103
- const T = new URL(h);
103
+ const w = new URL(C);
104
104
  return {
105
- host: T.hostname,
105
+ host: w.hostname,
106
106
  // 域名:example.com
107
- port: T.port || null
107
+ port: w.port || null
108
108
  // 端口:8080(默认端口返回空字符串,转为 null)
109
109
  };
110
110
  } catch {
@@ -117,76 +117,76 @@ function We(h) {
117
117
  const Xe = () => ({ initUrlInfo: () => ({
118
118
  host: null,
119
119
  port: null
120
- }), hasProtocol: de, generateUrl: (p) => {
121
- const { host: d, port: C } = p;
120
+ }), hasProtocol: pe, generateUrl: (p) => {
121
+ const { host: d, port: T } = p;
122
122
  if (!d)
123
123
  return null;
124
124
  let e = `${d}`;
125
- return de(d) || (e = `http://${e}`), C && (e = `${e}:${C}`), e;
126
- } }), Ge = { class: "body-wrapper" }, Je = { class: "api-form-wrapper" }, Ye = { class: "edit-footer" }, Ze = { class: "footer-right" }, et = /* @__PURE__ */ X({
125
+ return pe(d) || (e = `http://${e}`), T && (e = `${e}:${T}`), e;
126
+ } }), Ge = { class: "body-wrapper" }, Je = { class: "api-form-wrapper" }, Ye = { class: "edit-footer" }, Ze = { class: "footer-right" }, et = /* @__PURE__ */ J({
127
127
  __name: "index",
128
128
  emits: ["updateApiUrl"],
129
- setup(h, { expose: T, emit: p }) {
130
- const d = p, C = ie(W), { systemUrl: e } = ne(C), { initUrlInfo: v, generateUrl: w } = Xe(), m = f(v()), k = f(), $ = se({
129
+ setup(C, { expose: w, emit: p }) {
130
+ const d = p, T = re(G), { systemUrl: e } = ie(T), { initUrlInfo: v, generateUrl: k } = Xe(), m = f(v()), U = f(), V = ne({
131
131
  host: [
132
132
  { required: !0, message: "请输入职位名称", trigger: "blur" }
133
133
  ]
134
- }), y = Z(() => e.value || "http://222.92.178.198:63002"), V = () => {
135
- m.value = We(y.value);
134
+ }), h = W(() => e.value || "http://222.92.178.198:63002"), A = () => {
135
+ m.value = We(h.value);
136
136
  };
137
- fe(() => {
138
- V();
137
+ ve(() => {
138
+ A();
139
139
  });
140
- const a = f(!1), o = () => {
141
- V(), a.value = !0;
140
+ const l = f(!1), o = () => {
141
+ A(), l.value = !0;
142
142
  }, r = () => {
143
- a.value = !1;
144
- }, c = () => {
143
+ l.value = !1;
144
+ }, u = () => {
145
145
  r();
146
146
  }, g = async () => {
147
- var u;
148
- await ((u = k.value) == null ? void 0 : u.validate());
149
- const U = w(m.value);
150
- d("updateApiUrl", U), c();
147
+ var c;
148
+ await ((c = U.value) == null ? void 0 : c.validate());
149
+ const y = k(m.value);
150
+ d("updateApiUrl", y), u();
151
151
  };
152
- return T({
152
+ return w({
153
153
  openDialog: o,
154
- handleClose: c
155
- }), (U, u) => {
156
- const I = b("el-input"), R = b("el-form-item"), E = b("el-col"), O = b("el-row"), n = b("el-form"), A = b("el-dialog");
157
- return L(), ee(A, {
154
+ handleClose: u
155
+ }), (y, c) => {
156
+ const q = b("el-input"), R = b("el-form-item"), S = b("el-col"), B = b("el-row"), E = b("el-form"), n = b("el-dialog");
157
+ return $(), ee(n, {
158
158
  class: "api-form-dialog",
159
- modelValue: a.value,
160
- "onUpdate:modelValue": u[2] || (u[2] = (F) => a.value = F),
161
- "before-close": c,
159
+ modelValue: l.value,
160
+ "onUpdate:modelValue": c[2] || (c[2] = (L) => l.value = L),
161
+ "before-close": u,
162
162
  "destroy-on-close": "",
163
163
  "show-close": !1
164
164
  }, {
165
- header: l(() => u[3] || (u[3] = [])),
166
- default: l(() => [
165
+ header: a(() => c[3] || (c[3] = [])),
166
+ default: a(() => [
167
167
  i("div", Ge, [
168
168
  i("div", Je, [
169
- t(n, {
169
+ t(E, {
170
170
  class: "api-edit-form",
171
171
  ref_key: "apiFormRef",
172
- ref: k,
172
+ ref: U,
173
173
  model: m.value,
174
- rules: $
174
+ rules: V
175
175
  }, {
176
- default: l(() => [
177
- t(O, { gutter: 20 }, {
178
- default: l(() => [
179
- t(E, { span: 12 }, {
180
- default: l(() => [
176
+ default: a(() => [
177
+ t(B, { gutter: 20 }, {
178
+ default: a(() => [
179
+ t(S, { span: 12 }, {
180
+ default: a(() => [
181
181
  t(R, {
182
182
  prop: "host",
183
183
  label: "主机名",
184
184
  "label-position": "top"
185
185
  }, {
186
- default: l(() => [
187
- t(I, {
186
+ default: a(() => [
187
+ t(q, {
188
188
  modelValue: m.value.host,
189
- "onUpdate:modelValue": u[0] || (u[0] = (F) => m.value.host = F),
189
+ "onUpdate:modelValue": c[0] || (c[0] = (L) => m.value.host = L),
190
190
  "aria-label": "主机名",
191
191
  placeholder: "主机名"
192
192
  }, null, 8, ["modelValue"])
@@ -196,17 +196,17 @@ const Xe = () => ({ initUrlInfo: () => ({
196
196
  ]),
197
197
  _: 1
198
198
  }),
199
- t(E, { span: 12 }, {
200
- default: l(() => [
199
+ t(S, { span: 12 }, {
200
+ default: a(() => [
201
201
  t(R, {
202
202
  prop: "port",
203
203
  label: "端口",
204
204
  "label-position": "top"
205
205
  }, {
206
- default: l(() => [
207
- t(I, {
206
+ default: a(() => [
207
+ t(q, {
208
208
  modelValue: m.value.port,
209
- "onUpdate:modelValue": u[1] || (u[1] = (F) => m.value.port = F),
209
+ "onUpdate:modelValue": c[1] || (c[1] = (L) => m.value.port = L),
210
210
  "aria-label": "端口",
211
211
  placeholder: "端口"
212
212
  }, null, 8, ["modelValue"])
@@ -225,14 +225,14 @@ const Xe = () => ({ initUrlInfo: () => ({
225
225
  ])
226
226
  ])
227
227
  ]),
228
- footer: l(() => [
228
+ footer: a(() => [
229
229
  i("div", Ye, [
230
- u[4] || (u[4] = i("div", { class: "footer-left" }, null, -1)),
230
+ c[4] || (c[4] = i("div", { class: "footer-left" }, null, -1)),
231
231
  i("div", Ze, [
232
232
  t(te, {
233
233
  class: "cancel",
234
234
  emptyColor: !0,
235
- onClickTrigger: c,
235
+ onClickTrigger: u,
236
236
  modelValue: "取消",
237
237
  buttonType: "info"
238
238
  }),
@@ -250,7 +250,7 @@ const Xe = () => ({ initUrlInfo: () => ({
250
250
  }, 8, ["modelValue"]);
251
251
  };
252
252
  }
253
- }), tt = /* @__PURE__ */ H(et, [["__scopeId", "data-v-20c1098b"]]), ot = { class: "dialog-header" }, at = { class: "dialog-subtitle" }, lt = {
253
+ }), tt = /* @__PURE__ */ K(et, [["__scopeId", "data-v-20c1098b"]]), ot = { class: "dialog-header" }, at = { class: "dialog-subtitle" }, lt = {
254
254
  key: 0,
255
255
  class: "restart-panel"
256
256
  }, st = { class: "restart-title" }, nt = { class: "restart-subtitle" }, it = {
@@ -259,10 +259,10 @@ const Xe = () => ({ initUrlInfo: () => ({
259
259
  }, rt = { class: "db-type-selector" }, ct = { key: "sqlite" }, ut = { key: "pgsql" }, dt = {
260
260
  key: 0,
261
261
  class: "dialog-footer"
262
- }, pt = 6e4, me = 2e3, mt = /* @__PURE__ */ X({
262
+ }, pt = 6e4, fe = 2e3, mt = /* @__PURE__ */ J({
263
263
  __name: "index",
264
- setup(h, { expose: T }) {
265
- const p = ie(W), { systemUrl: d } = ne(p), C = Z(() => d.value || "http://222.92.178.198:63002"), e = se({
264
+ setup(C, { expose: w }) {
265
+ const p = re(G), { systemUrl: d } = ie(p), T = W(() => d.value || "http://222.92.178.198:63002"), e = ne({
266
266
  databaseType: "sqlite",
267
267
  sqliteDir: "sqlite-data",
268
268
  user: "",
@@ -270,154 +270,154 @@ const Xe = () => ({ initUrlInfo: () => ({
270
270
  database: "",
271
271
  password: "",
272
272
  port: "5432"
273
- }), v = Z(() => e.databaseType === "sqlite" ? {
273
+ }), v = W(() => e.databaseType === "sqlite" ? {
274
274
  sqliteDir: [{ required: !0, message: "请输入数据库目录", trigger: "blur" }]
275
275
  } : {
276
276
  host: [{ required: !0, message: "请输入主机地址", trigger: "blur" }],
277
277
  port: [{ required: !0, message: "请输入端口号", trigger: "blur" }],
278
278
  database: [{ required: !0, message: "请输入数据库名", trigger: "blur" }],
279
279
  user: [{ required: !0, message: "请输入用户名", trigger: "blur" }]
280
- }), w = f(null), m = f(!1), k = f(!1), $ = f(!1), y = f(!1), V = f(0), a = f("running"), o = f(1);
280
+ }), k = f(null), m = f(!1), U = f(!1), V = f(!1), h = f(!1), A = f(0), l = f("running"), o = f(1);
281
281
  let r = null;
282
- const c = Z(() => a.value === "success" ? "重启成功!" : a.value === "timeout" ? "连接超时" : "正在应用配置并等待服务重新启动中..."), g = Z(() => a.value === "success" ? "服务已恢复,配置已生效" : a.value === "timeout" ? "超过最大等待时间,请手动检查服务状态" : "请稍后" + ".".repeat(o.value));
283
- let U = null, u = null;
284
- const I = () => {
282
+ const u = W(() => l.value === "success" ? "重启成功!" : l.value === "timeout" ? "连接超时" : "正在应用配置并等待服务重新启动中..."), g = W(() => l.value === "success" ? "服务已恢复,配置已生效" : l.value === "timeout" ? "超过最大等待时间,请手动检查服务状态" : "请稍后" + ".".repeat(o.value));
283
+ let y = null, c = null;
284
+ const q = () => {
285
285
  r && (clearInterval(r), r = null);
286
286
  }, R = () => {
287
- U && (clearInterval(U), U = null), u && (clearInterval(u), u = null), I();
288
- }, E = () => {
289
- V.value = 0;
287
+ y && (clearInterval(y), y = null), c && (clearInterval(c), c = null), q();
288
+ }, S = () => {
289
+ A.value = 0;
290
290
  let _ = 0;
291
- U = setInterval(() => {
291
+ y = setInterval(() => {
292
292
  _ += 100;
293
293
  const s = 90 * (1 - Math.exp(-_ / 8e3));
294
- V.value = Math.min(parseFloat(s.toFixed(1)), 90);
294
+ A.value = Math.min(parseFloat(s.toFixed(1)), 90);
295
295
  }, 100);
296
- }, O = () => {
296
+ }, B = () => {
297
297
  o.value = 1, r = setInterval(() => {
298
298
  o.value = o.value >= 3 ? 1 : o.value + 1;
299
299
  }, 500);
300
- }, n = () => {
301
- I();
300
+ }, E = () => {
301
+ q();
302
302
  const _ = setInterval(() => {
303
- V.value = Math.min(V.value + 3, 100), V.value >= 100 && (clearInterval(_), a.value = "success");
303
+ A.value = Math.min(A.value + 3, 100), A.value >= 100 && (clearInterval(_), l.value = "success");
304
304
  }, 30);
305
- }, A = () => {
305
+ }, n = () => {
306
306
  let _ = 0;
307
- u = setInterval(async () => {
308
- if (_ += me, _ >= pt) {
309
- R(), a.value = "timeout";
307
+ c = setInterval(async () => {
308
+ if (_ += fe, _ >= pt) {
309
+ R(), l.value = "timeout";
310
310
  return;
311
311
  }
312
312
  try {
313
- const { data: s } = await ce.get(C.value + "/platform/config/db", { timeout: 3e3 });
314
- (s == null ? void 0 : s.code) === 200 && (R(), n());
313
+ const { data: s } = await ue.get(T.value + "/platform/config/db", { timeout: 3e3 });
314
+ (s == null ? void 0 : s.code) === 200 && (R(), E());
315
315
  } catch {
316
316
  }
317
- }, me);
318
- }, F = async () => {
317
+ }, fe);
318
+ }, L = async () => {
319
319
  try {
320
- k.value = !0;
321
- const { data: _ } = await ce.get(C.value + "/platform/config/db");
320
+ U.value = !0;
321
+ const { data: _ } = await ue.get(T.value + "/platform/config/db");
322
322
  if ((_ == null ? void 0 : _.code) === 200 && (_ != null && _.data)) {
323
323
  const s = _.data;
324
324
  e.databaseType = s.databaseType === "pgsql" ? "pgsql" : "sqlite", e.sqliteDir = s.sqliteDir || "sqlite-data", e.user = s.user || "", e.host = s.host || "", e.database = s.database || "", e.password = s.password || "", e.port = String(s.port || 5432);
325
325
  }
326
326
  } catch {
327
327
  } finally {
328
- k.value = !1;
328
+ U.value = !1;
329
329
  }
330
- }, B = () => {
331
- y.value = !1, a.value = "running", V.value = 0, o.value = 1, m.value = !0, F();
332
- }, G = () => {
330
+ }, P = () => {
331
+ h.value = !1, l.value = "running", A.value = 0, o.value = 1, m.value = !0, L();
332
+ }, M = () => {
333
333
  R(), m.value = !1;
334
- }, J = () => G(), Y = (_) => {
335
- y.value || _();
336
- }, ve = async () => {
337
- var _, s, K;
338
- await ((_ = w.value) == null ? void 0 : _.validate());
334
+ }, Y = () => M(), ae = (_) => {
335
+ h.value || _();
336
+ }, Z = async () => {
337
+ var _, s, z;
338
+ await ((_ = k.value) == null ? void 0 : _.validate());
339
339
  try {
340
- $.value = !0;
341
- const x = { databaseType: e.databaseType };
342
- e.databaseType === "sqlite" ? x.sqliteDir = e.sqliteDir.trim() : (x.user = e.user.trim(), x.host = e.host.trim(), x.database = e.database.trim(), x.password = e.password, x.port = Number(e.port)), await ce.post(C.value + "/platform/config/db", x), y.value = !0, a.value = "running", E(), O(), setTimeout(A, 1e3);
343
- } catch (x) {
344
- const M = ((K = (s = x == null ? void 0 : x.response) == null ? void 0 : s.data) == null ? void 0 : K.message) || "保存失败,请重试";
345
- ue.error(M);
340
+ V.value = !0;
341
+ const F = { databaseType: e.databaseType };
342
+ e.databaseType === "sqlite" ? F.sqliteDir = e.sqliteDir.trim() : (F.user = e.user.trim(), F.host = e.host.trim(), F.database = e.database.trim(), F.password = e.password, F.port = Number(e.port)), await ue.post(T.value + "/platform/config/db", F), h.value = !0, l.value = "running", S(), B(), setTimeout(n, 1e3);
343
+ } catch (F) {
344
+ const O = ((z = (s = F == null ? void 0 : F.response) == null ? void 0 : s.data) == null ? void 0 : z.message) || "保存失败,请重试";
345
+ de.error(O);
346
346
  } finally {
347
- $.value = !1;
347
+ V.value = !1;
348
348
  }
349
349
  };
350
- return T({ openDialog: B, handleClose: J }), (_, s) => {
351
- const K = b("el-icon"), x = b("el-progress"), M = b("el-input"), z = b("el-form-item"), ae = b("el-col"), pe = b("el-row"), ge = b("el-form"), _e = b("el-dialog"), be = ye("loading");
352
- return L(), ee(_e, {
350
+ return w({ openDialog: P, handleClose: Y }), (_, s) => {
351
+ const z = b("el-icon"), F = b("el-progress"), O = b("el-input"), Q = b("el-form-item"), le = b("el-col"), me = b("el-row"), ge = b("el-form"), _e = b("el-dialog"), be = ye("loading");
352
+ return $(), ee(_e, {
353
353
  class: "db-config-dialog",
354
354
  modelValue: m.value,
355
- "onUpdate:modelValue": s[8] || (s[8] = (q) => m.value = q),
356
- "before-close": Y,
357
- "close-on-click-modal": !y.value,
358
- "close-on-press-escape": !y.value,
355
+ "onUpdate:modelValue": s[8] || (s[8] = (I) => m.value = I),
356
+ "before-close": ae,
357
+ "close-on-click-modal": !h.value,
358
+ "close-on-press-escape": !h.value,
359
359
  "destroy-on-close": "",
360
360
  "show-close": !1,
361
361
  width: "480px"
362
362
  }, {
363
- header: l(() => [
363
+ header: a(() => [
364
364
  i("div", ot, [
365
365
  s[9] || (s[9] = i("span", { class: "dialog-title" }, "数据库配置", -1)),
366
- i("span", at, S(y.value ? "" : "修改后服务将自动重启"), 1)
366
+ i("span", at, N(h.value ? "" : "修改后服务将自动重启"), 1)
367
367
  ])
368
368
  ]),
369
- default: l(() => [
370
- y.value ? (L(), N("div", lt, [
371
- a.value !== "running" ? (L(), N("div", {
369
+ default: a(() => [
370
+ h.value ? ($(), x("div", lt, [
371
+ l.value !== "running" ? ($(), x("div", {
372
372
  key: 0,
373
- class: re(["restart-icon-wrap", { success: a.value === "success", error: a.value === "timeout" }])
373
+ class: ce(["restart-icon-wrap", { success: l.value === "success", error: l.value === "timeout" }])
374
374
  }, [
375
- a.value === "success" ? (L(), ee(K, {
375
+ l.value === "success" ? ($(), ee(z, {
376
376
  key: 0,
377
377
  class: "restart-icon"
378
378
  }, {
379
- default: l(() => [
380
- t(j(Ae))
379
+ default: a(() => [
380
+ t(H(Ae))
381
381
  ]),
382
382
  _: 1
383
- })) : (L(), ee(K, {
383
+ })) : ($(), ee(z, {
384
384
  key: 1,
385
385
  class: "restart-icon"
386
386
  }, {
387
- default: l(() => [
388
- t(j(qe))
387
+ default: a(() => [
388
+ t(H(qe))
389
389
  ]),
390
390
  _: 1
391
391
  }))
392
- ], 2)) : le("", !0),
393
- i("div", st, S(c.value), 1),
394
- i("div", nt, S(g.value), 1),
395
- t(x, {
392
+ ], 2)) : se("", !0),
393
+ i("div", st, N(u.value), 1),
394
+ i("div", nt, N(g.value), 1),
395
+ t(F, {
396
396
  class: "restart-progress",
397
- percentage: Math.round(V.value),
398
- status: a.value === "success" ? "success" : a.value === "timeout" ? "exception" : "",
397
+ percentage: Math.round(A.value),
398
+ status: l.value === "success" ? "success" : l.value === "timeout" ? "exception" : "",
399
399
  "stroke-width": 10
400
400
  }, null, 8, ["percentage", "status"]),
401
- a.value === "success" || a.value === "timeout" ? (L(), ee(te, {
401
+ l.value === "success" || l.value === "timeout" ? ($(), ee(te, {
402
402
  key: 1,
403
403
  class: "restart-close-btn",
404
404
  emptyColor: !0,
405
- onClickTrigger: G,
406
- modelValue: a.value === "success" ? "确定" : "关闭",
407
- buttonType: a.value === "success" ? "primary" : "info"
408
- }, null, 8, ["modelValue", "buttonType"])) : le("", !0)
409
- ])) : he((L(), N("div", it, [
405
+ onClickTrigger: M,
406
+ modelValue: l.value === "success" ? "确定" : "关闭",
407
+ buttonType: l.value === "success" ? "primary" : "info"
408
+ }, null, 8, ["modelValue", "buttonType"])) : se("", !0)
409
+ ])) : he(($(), x("div", it, [
410
410
  i("div", rt, [
411
411
  i("div", {
412
- class: re(["db-type-card", { active: e.databaseType === "sqlite" }]),
413
- onClick: s[0] || (s[0] = (q) => e.databaseType = "sqlite")
412
+ class: ce(["db-type-card", { active: e.databaseType === "sqlite" }]),
413
+ onClick: s[0] || (s[0] = (I) => e.databaseType = "sqlite")
414
414
  }, s[10] || (s[10] = [
415
415
  i("span", { class: "db-label" }, "SQLite", -1),
416
416
  i("span", { class: "db-desc" }, "本地文件数据库", -1)
417
417
  ]), 2),
418
418
  i("div", {
419
- class: re(["db-type-card", { active: e.databaseType === "pgsql" }]),
420
- onClick: s[1] || (s[1] = (q) => e.databaseType = "pgsql")
419
+ class: ce(["db-type-card", { active: e.databaseType === "pgsql" }]),
420
+ onClick: s[1] || (s[1] = (I) => e.databaseType = "pgsql")
421
421
  }, s[11] || (s[11] = [
422
422
  i("span", { class: "db-label" }, "PostgreSQL", -1),
423
423
  i("span", { class: "db-desc" }, "远程关系型数据库", -1)
@@ -425,34 +425,34 @@ const Xe = () => ({ initUrlInfo: () => ({
425
425
  ]),
426
426
  t(ge, {
427
427
  ref_key: "formRef",
428
- ref: w,
428
+ ref: k,
429
429
  model: e,
430
430
  rules: v.value,
431
431
  "label-position": "top",
432
432
  class: "config-form"
433
433
  }, {
434
- default: l(() => [
434
+ default: a(() => [
435
435
  t(Ce, {
436
436
  name: "fade-slide",
437
437
  mode: "out-in"
438
438
  }, {
439
- default: l(() => [
440
- e.databaseType === "sqlite" ? (L(), N("div", ct, [
441
- t(z, {
439
+ default: a(() => [
440
+ e.databaseType === "sqlite" ? ($(), x("div", ct, [
441
+ t(Q, {
442
442
  label: "数据库目录",
443
443
  prop: "sqliteDir"
444
444
  }, {
445
- default: l(() => [
446
- t(M, {
445
+ default: a(() => [
446
+ t(O, {
447
447
  modelValue: e.sqliteDir,
448
- "onUpdate:modelValue": s[2] || (s[2] = (q) => e.sqliteDir = q),
448
+ "onUpdate:modelValue": s[2] || (s[2] = (I) => e.sqliteDir = I),
449
449
  placeholder: "例如:sqlite-data",
450
450
  clearable: ""
451
451
  }, {
452
- prefix: l(() => [
453
- t(K, null, {
454
- default: l(() => [
455
- t(j(Ie))
452
+ prefix: a(() => [
453
+ t(z, null, {
454
+ default: a(() => [
455
+ t(H(Ie))
456
456
  ]),
457
457
  _: 1
458
458
  })
@@ -464,19 +464,19 @@ const Xe = () => ({ initUrlInfo: () => ({
464
464
  _: 1,
465
465
  __: [12]
466
466
  })
467
- ])) : (L(), N("div", ut, [
468
- t(pe, { gutter: 16 }, {
469
- default: l(() => [
470
- t(ae, { span: 16 }, {
471
- default: l(() => [
472
- t(z, {
467
+ ])) : ($(), x("div", ut, [
468
+ t(me, { gutter: 16 }, {
469
+ default: a(() => [
470
+ t(le, { span: 16 }, {
471
+ default: a(() => [
472
+ t(Q, {
473
473
  label: "主机地址",
474
474
  prop: "host"
475
475
  }, {
476
- default: l(() => [
477
- t(M, {
476
+ default: a(() => [
477
+ t(O, {
478
478
  modelValue: e.host,
479
- "onUpdate:modelValue": s[3] || (s[3] = (q) => e.host = q),
479
+ "onUpdate:modelValue": s[3] || (s[3] = (I) => e.host = I),
480
480
  placeholder: "127.0.0.1",
481
481
  clearable: ""
482
482
  }, null, 8, ["modelValue"])
@@ -486,16 +486,16 @@ const Xe = () => ({ initUrlInfo: () => ({
486
486
  ]),
487
487
  _: 1
488
488
  }),
489
- t(ae, { span: 8 }, {
490
- default: l(() => [
491
- t(z, {
489
+ t(le, { span: 8 }, {
490
+ default: a(() => [
491
+ t(Q, {
492
492
  label: "端口",
493
493
  prop: "port"
494
494
  }, {
495
- default: l(() => [
496
- t(M, {
495
+ default: a(() => [
496
+ t(O, {
497
497
  modelValue: e.port,
498
- "onUpdate:modelValue": s[4] || (s[4] = (q) => e.port = q),
498
+ "onUpdate:modelValue": s[4] || (s[4] = (I) => e.port = I),
499
499
  placeholder: "5432",
500
500
  clearable: ""
501
501
  }, null, 8, ["modelValue"])
@@ -508,32 +508,32 @@ const Xe = () => ({ initUrlInfo: () => ({
508
508
  ]),
509
509
  _: 1
510
510
  }),
511
- t(z, {
511
+ t(Q, {
512
512
  label: "数据库名",
513
513
  prop: "database"
514
514
  }, {
515
- default: l(() => [
516
- t(M, {
515
+ default: a(() => [
516
+ t(O, {
517
517
  modelValue: e.database,
518
- "onUpdate:modelValue": s[5] || (s[5] = (q) => e.database = q),
518
+ "onUpdate:modelValue": s[5] || (s[5] = (I) => e.database = I),
519
519
  placeholder: "new_insofworks_admin",
520
520
  clearable: ""
521
521
  }, null, 8, ["modelValue"])
522
522
  ]),
523
523
  _: 1
524
524
  }),
525
- t(pe, { gutter: 16 }, {
526
- default: l(() => [
527
- t(ae, { span: 12 }, {
528
- default: l(() => [
529
- t(z, {
525
+ t(me, { gutter: 16 }, {
526
+ default: a(() => [
527
+ t(le, { span: 12 }, {
528
+ default: a(() => [
529
+ t(Q, {
530
530
  label: "用户名",
531
531
  prop: "user"
532
532
  }, {
533
- default: l(() => [
534
- t(M, {
533
+ default: a(() => [
534
+ t(O, {
535
535
  modelValue: e.user,
536
- "onUpdate:modelValue": s[6] || (s[6] = (q) => e.user = q),
536
+ "onUpdate:modelValue": s[6] || (s[6] = (I) => e.user = I),
537
537
  placeholder: "postgres",
538
538
  clearable: ""
539
539
  }, null, 8, ["modelValue"])
@@ -543,16 +543,16 @@ const Xe = () => ({ initUrlInfo: () => ({
543
543
  ]),
544
544
  _: 1
545
545
  }),
546
- t(ae, { span: 12 }, {
547
- default: l(() => [
548
- t(z, {
546
+ t(le, { span: 12 }, {
547
+ default: a(() => [
548
+ t(Q, {
549
549
  label: "密码",
550
550
  prop: "password"
551
551
  }, {
552
- default: l(() => [
553
- t(M, {
552
+ default: a(() => [
553
+ t(O, {
554
554
  modelValue: e.password,
555
- "onUpdate:modelValue": s[7] || (s[7] = (q) => e.password = q),
555
+ "onUpdate:modelValue": s[7] || (s[7] = (I) => e.password = I),
556
556
  type: "password",
557
557
  "show-password": "",
558
558
  clearable: ""
@@ -574,21 +574,21 @@ const Xe = () => ({ initUrlInfo: () => ({
574
574
  _: 1
575
575
  }, 8, ["model", "rules"])
576
576
  ])), [
577
- [be, k.value]
577
+ [be, U.value]
578
578
  ])
579
579
  ]),
580
- footer: l(() => [
581
- y.value ? le("", !0) : (L(), N("div", dt, [
580
+ footer: a(() => [
581
+ h.value ? se("", !0) : ($(), x("div", dt, [
582
582
  t(te, {
583
583
  emptyColor: !0,
584
- onClickTrigger: J,
584
+ onClickTrigger: Y,
585
585
  modelValue: "取消",
586
586
  buttonType: "info"
587
587
  }),
588
588
  t(te, {
589
589
  emptyColor: !0,
590
- loading: $.value,
591
- onClickTrigger: ve,
590
+ loading: V.value,
591
+ onClickTrigger: Z,
592
592
  modelValue: "保存并重启",
593
593
  buttonType: "primary"
594
594
  }, null, 8, ["loading"])
@@ -598,7 +598,7 @@ const Xe = () => ({ initUrlInfo: () => ({
598
598
  }, 8, ["modelValue", "close-on-click-modal", "close-on-press-escape"]);
599
599
  };
600
600
  }
601
- }), ft = /* @__PURE__ */ H(mt, [["__scopeId", "data-v-01b4eb9b"]]), vt = { class: "account-wrap" }, gt = { class: "extra-operate" }, _t = /* @__PURE__ */ X({
601
+ }), ft = /* @__PURE__ */ K(mt, [["__scopeId", "data-v-01b4eb9b"]]), vt = { class: "account-wrap" }, gt = { class: "extra-operate" }, _t = /* @__PURE__ */ J({
602
602
  __name: "index",
603
603
  props: {
604
604
  activeTabName: {
@@ -615,67 +615,67 @@ const Xe = () => ({ initUrlInfo: () => ({
615
615
  }
616
616
  },
617
617
  emits: ["handleLoginFormChange", "updateApiUrl"],
618
- setup(h, { emit: T }) {
619
- const p = h, d = se({
618
+ setup(C, { emit: w }) {
619
+ const p = C, d = ne({
620
620
  account: "",
621
621
  password: ""
622
- }), C = se({
622
+ }), T = ne({
623
623
  account: [
624
624
  { required: !0, message: "请输入账号", trigger: "blur" }
625
625
  ],
626
626
  password: [
627
627
  { required: !0, message: "请输入密码", trigger: "blur" }
628
628
  ]
629
- }), e = f(null), v = f(!1), w = T;
630
- Q(() => p.isClickLogin, (a) => {
629
+ }), e = f(null), v = f(!1), k = w;
630
+ X(() => p.isClickLogin, (l) => {
631
631
  var o;
632
- a && (p == null ? void 0 : p.activeTabName) === "account" && ((o = e.value) == null || o.validate((r) => {
633
- var c;
632
+ l && (p == null ? void 0 : p.activeTabName) === "account" && ((o = e.value) == null || o.validate((r) => {
633
+ var u;
634
634
  for (let g in d)
635
- d.hasOwnProperty(g) && (d[g] = (c = d[g]) == null ? void 0 : c.trim());
636
- w("handleLoginFormChange", r, r ? d : null);
635
+ d.hasOwnProperty(g) && (d[g] = (u = d[g]) == null ? void 0 : u.trim());
636
+ k("handleLoginFormChange", r, r ? d : null);
637
637
  }));
638
638
  }, {
639
639
  immediate: !0
640
- }), Q(() => p.activeTabName, (a) => {
640
+ }), X(() => p.activeTabName, (l) => {
641
641
  var o;
642
- a === "account" && !v.value && ((o = e.value) == null || o.resetFields());
643
- }), Q(() => p.loginContent, (a) => {
644
- a != null && a.account && !v.value && (d.account = a.account, v.value = !0);
642
+ l === "account" && !v.value && ((o = e.value) == null || o.resetFields());
643
+ }), X(() => p.loginContent, (l) => {
644
+ l != null && l.account && !v.value && (d.account = l.account, v.value = !0);
645
645
  }, { immediate: !0 });
646
- const m = f(), k = () => {
647
- var a, o;
648
- (o = (a = m.value) == null ? void 0 : a.openDialog) == null || o.call(a);
649
- }, $ = (a) => {
650
- w("updateApiUrl", a);
651
- }, y = f(), V = () => {
652
- var a, o;
653
- (o = (a = y.value) == null ? void 0 : a.openDialog) == null || o.call(a);
646
+ const m = f(), U = () => {
647
+ var l, o;
648
+ (o = (l = m.value) == null ? void 0 : l.openDialog) == null || o.call(l);
649
+ }, V = (l) => {
650
+ k("updateApiUrl", l);
651
+ }, h = f(), A = () => {
652
+ var l, o;
653
+ (o = (l = h.value) == null ? void 0 : l.openDialog) == null || o.call(l);
654
654
  };
655
- return (a, o) => {
656
- const r = b("svg-icon"), c = b("el-input"), g = b("el-form-item"), U = b("el-form"), u = b("el-link");
657
- return L(), N(Te, null, [
655
+ return (l, o) => {
656
+ const r = b("svg-icon"), u = b("el-input"), g = b("el-form-item"), y = b("el-form"), c = b("el-link");
657
+ return $(), x(Te, null, [
658
658
  i("div", vt, [
659
- t(U, {
659
+ t(y, {
660
660
  model: d,
661
- rules: C,
661
+ rules: T,
662
662
  ref_key: "formRef",
663
663
  ref: e
664
664
  }, {
665
- default: l(() => [
665
+ default: a(() => [
666
666
  t(g, {
667
667
  label: "",
668
668
  prop: "account"
669
669
  }, {
670
- default: l(() => [
671
- t(c, {
670
+ default: a(() => [
671
+ t(u, {
672
672
  class: "account-input",
673
673
  modelValue: d.account,
674
- "onUpdate:modelValue": o[0] || (o[0] = (I) => d.account = I),
674
+ "onUpdate:modelValue": o[0] || (o[0] = (q) => d.account = q),
675
675
  placeholder: "请输入账号",
676
676
  clearable: ""
677
677
  }, {
678
- prefix: l(() => [
678
+ prefix: a(() => [
679
679
  t(r, {
680
680
  name: "account",
681
681
  style: { width: "15px", height: "15px" }
@@ -690,17 +690,17 @@ const Xe = () => ({ initUrlInfo: () => ({
690
690
  label: "",
691
691
  prop: "password"
692
692
  }, {
693
- default: l(() => [
694
- t(c, {
693
+ default: a(() => [
694
+ t(u, {
695
695
  class: "account-input",
696
696
  modelValue: d.password,
697
- "onUpdate:modelValue": o[1] || (o[1] = (I) => d.password = I),
697
+ "onUpdate:modelValue": o[1] || (o[1] = (q) => d.password = q),
698
698
  type: "password",
699
699
  placeholder: "请输入密码",
700
700
  "show-password": "",
701
701
  clearable: ""
702
702
  }, {
703
- prefix: l(() => [
703
+ prefix: a(() => [
704
704
  t(r, {
705
705
  name: "password",
706
706
  style: { width: "15px", height: "15px" }
@@ -715,24 +715,24 @@ const Xe = () => ({ initUrlInfo: () => ({
715
715
  _: 1
716
716
  }, 8, ["model", "rules"]),
717
717
  i("div", gt, [
718
- t(u, {
718
+ t(c, {
719
719
  class: "api-button",
720
720
  type: "primary",
721
- onClick: k
721
+ onClick: U
722
722
  }, {
723
- default: l(() => o[2] || (o[2] = [
724
- P("接口地址")
723
+ default: a(() => o[2] || (o[2] = [
724
+ j("接口地址")
725
725
  ])),
726
726
  _: 1,
727
727
  __: [2]
728
728
  }),
729
- t(u, {
729
+ t(c, {
730
730
  class: "db-button",
731
731
  type: "primary",
732
- onClick: V
732
+ onClick: A
733
733
  }, {
734
- default: l(() => o[3] || (o[3] = [
735
- P("数据库配置")
734
+ default: a(() => o[3] || (o[3] = [
735
+ j("数据库配置")
736
736
  ])),
737
737
  _: 1,
738
738
  __: [3]
@@ -742,16 +742,16 @@ const Xe = () => ({ initUrlInfo: () => ({
742
742
  t(tt, {
743
743
  ref_key: "apiFormDialogRef",
744
744
  ref: m,
745
- onUpdateApiUrl: $
745
+ onUpdateApiUrl: V
746
746
  }, null, 512),
747
747
  t(ft, {
748
748
  ref_key: "dbConfigDialogRef",
749
- ref: y
749
+ ref: h
750
750
  }, null, 512)
751
751
  ], 64);
752
752
  };
753
753
  }
754
- }), bt = /* @__PURE__ */ H(_t, [["__scopeId", "data-v-d1e15373"]]), yt = { class: "account-wrap" }, ht = { class: "video-wrap" }, Ct = /* @__PURE__ */ X({
754
+ }), bt = /* @__PURE__ */ K(_t, [["__scopeId", "data-v-d1e15373"]]), yt = { class: "account-wrap" }, ht = { class: "video-wrap" }, Ct = /* @__PURE__ */ J({
755
755
  __name: "index",
756
756
  props: {
757
757
  systemKey: { default: "" },
@@ -759,37 +759,37 @@ const Xe = () => ({ initUrlInfo: () => ({
759
759
  isClickLogin: { type: Boolean, default: !1 }
760
760
  },
761
761
  emits: ["handleLoginFormChange"],
762
- setup(h, { emit: T }) {
763
- const p = h, d = T;
764
- ie(W);
765
- const { initVerify: C } = Fe(), e = f(null), v = f(null);
766
- let w = !1, m = null;
767
- const k = async (o) => {
762
+ setup(C, { emit: w }) {
763
+ const p = C, d = w;
764
+ re(G);
765
+ const { initVerify: T } = Fe(), e = f(null), v = f(null);
766
+ let k = !1, m = null;
767
+ const U = async (o) => {
768
768
  if (!o)
769
769
  return;
770
- const r = await C(o), { data: c } = r || {}, { account: g, password: U } = (c == null ? void 0 : c.data) || {}, u = c == null ? void 0 : c.msg;
770
+ const r = await T(o), { data: u } = r || {}, { account: g, password: y } = (u == null ? void 0 : u.data) || {}, c = u == null ? void 0 : u.msg;
771
771
  if (!g) {
772
- ue.warning(u || "识别失败,请重新识别!");
772
+ de.warning(c || "识别失败,请重新识别!");
773
773
  return;
774
774
  }
775
775
  d("handleLoginFormChange", !0, {
776
776
  account: g,
777
- password: U
777
+ password: y
778
778
  });
779
- }, $ = () => {
779
+ }, V = () => {
780
780
  if (!v.value || !e.value)
781
781
  return;
782
- const o = v.value, r = o.getContext("2d"), c = e.value;
782
+ const o = v.value, r = o.getContext("2d"), u = e.value;
783
783
  o.width = 200, o.height = 200;
784
- const g = c.videoWidth || 640, U = c.videoHeight || 480, u = Math.min(200 / g, 200 / U), I = g * u, R = U * u, E = (200 - I) / 2, O = (200 - R) / 2;
785
- r == null || r.drawImage(c, 0, 0, g, U, E, O, I, R), o.toBlob((n) => {
786
- if (n) {
787
- const A = new File([n], "face.png", { type: "image/png" });
788
- k(A);
784
+ const g = u.videoWidth || 640, y = u.videoHeight || 480, c = Math.min(200 / g, 200 / y), q = g * c, R = y * c, S = (200 - q) / 2, B = (200 - R) / 2;
785
+ r == null || r.drawImage(u, 0, 0, g, y, S, B, q, R), o.toBlob((E) => {
786
+ if (E) {
787
+ const n = new File([E], "face.png", { type: "image/png" });
788
+ U(n);
789
789
  }
790
790
  }, "image/png");
791
- }, y = async () => {
792
- if (!e.value || w)
791
+ }, h = async () => {
792
+ if (!e.value || k)
793
793
  return;
794
794
  const o = e.value;
795
795
  try {
@@ -799,33 +799,33 @@ const Xe = () => ({ initUrlInfo: () => ({
799
799
  audio: !1
800
800
  }), o) {
801
801
  const r = o;
802
- r.srcObject = m, w = !0;
802
+ r.srcObject = m, k = !0;
803
803
  }
804
804
  } catch {
805
- ue.warning("摄像头启动失败");
805
+ de.warning("摄像头启动失败");
806
806
  }
807
807
  };
808
- function V(o) {
808
+ function A(o) {
809
809
  if (o && (o.getTracks().forEach((r) => r.stop()), e.value)) {
810
810
  const r = e.value;
811
811
  r.srcObject = null;
812
812
  }
813
813
  }
814
- const a = () => {
815
- V(m), w = !1;
814
+ const l = () => {
815
+ A(m), k = !1;
816
816
  };
817
- return Q(() => p.activeTabName, (o) => {
817
+ return X(() => p.activeTabName, (o) => {
818
818
  if (o !== oe.FACE) {
819
- a();
819
+ l();
820
820
  return;
821
821
  }
822
- if (o === oe.FACE && !w) {
823
- y();
822
+ if (o === oe.FACE && !k) {
823
+ h();
824
824
  return;
825
825
  }
826
826
  }), we(() => {
827
- a();
828
- }), (o, r) => (L(), N("div", yt, [
827
+ l();
828
+ }), (o, r) => ($(), x("div", yt, [
829
829
  i("div", ht, [
830
830
  i("video", {
831
831
  class: "face-video",
@@ -839,7 +839,7 @@ const Xe = () => ({ initUrlInfo: () => ({
839
839
  D(o.$slots, "default", {}, () => [
840
840
  i("button", {
841
841
  class: "face-screenshot",
842
- onClick: $
842
+ onClick: V
843
843
  }, "人脸识别")
844
844
  ], !0),
845
845
  i("canvas", {
@@ -849,30 +849,30 @@ const Xe = () => ({ initUrlInfo: () => ({
849
849
  }, null, 512)
850
850
  ]));
851
851
  }
852
- }), Tt = /* @__PURE__ */ H(Ct, [["__scopeId", "data-v-b64bc91c"]]), wt = { class: "login-wrap" }, kt = { class: "login-body" }, Ut = { class: "login-body-item left" }, Lt = { class: "title" }, $t = { class: "first-level" }, Vt = {
852
+ }), Tt = /* @__PURE__ */ K(Ct, [["__scopeId", "data-v-b64bc91c"]]), wt = { class: "login-wrap" }, kt = { class: "login-body" }, Ut = { class: "login-body-item left" }, Lt = { class: "title" }, $t = { class: "first-level" }, Vt = {
853
853
  key: 0,
854
854
  class: "logo"
855
- }, At = ["src"], qt = { class: "english-name" }, It = { class: "login-body-item right" }, Ft = /* @__PURE__ */ X({
855
+ }, At = ["src"], qt = { class: "english-name" }, It = { class: "login-body-item right" }, Ft = /* @__PURE__ */ J({
856
856
  __name: "index",
857
857
  props: {
858
858
  oldSystemKey: {},
859
859
  loginContent: {}
860
860
  },
861
861
  emits: ["change", "projectLogin", "updateApiUrl", "systemContent"],
862
- setup(h, { emit: T }) {
863
- const p = h, d = xe(), C = T, e = ke(W), v = Ue(W), { refreshLogin: w } = ne(v), m = ie(W), { systemInfo: k, loginUserInfo: $ } = ne(m), y = f(""), V = async (n) => {
864
- const A = await $e({
862
+ setup(C, { emit: w }) {
863
+ const p = C, d = xe(), T = w, e = ke(G), v = Ue(G), { refreshLogin: k } = ie(v), m = re(G), { systemInfo: U, loginUserInfo: V } = ie(m), h = f(""), A = W(() => ({ account: h.value })), l = async (n) => {
864
+ const L = await $e({
865
865
  url: n
866
866
  });
867
- return URL.createObjectURL(A == null ? void 0 : A.data);
868
- }, a = f("");
869
- Q(() => {
867
+ return URL.createObjectURL(L == null ? void 0 : L.data);
868
+ }, o = f("");
869
+ X(() => {
870
870
  var n;
871
- return (n = k.value) == null ? void 0 : n.logo;
871
+ return (n = U.value) == null ? void 0 : n.logo;
872
872
  }, async (n) => {
873
- n ? a.value = await V(n) : a.value = Le;
873
+ n ? o.value = await l(n) : o.value = Le;
874
874
  }, { immediate: !0 });
875
- const o = f({
875
+ const r = f({
876
876
  // sysCTitle: 'INSOFWORKS',
877
877
  sysCTitle: "",
878
878
  sysETitle: "",
@@ -895,64 +895,64 @@ const Xe = () => ({ initUrlInfo: () => ({
895
895
  tips: "温馨提示:建议使用谷歌、Microsoft Edge,版本79.0.1072.62及以上浏览器,360浏览器请使用极速模式"
896
896
  }
897
897
  ]
898
- }), r = f("account"), c = f(!1), g = f(!1), U = () => {
899
- c.value = !0;
900
- }, u = (n, A) => {
901
- c.value = !1, n && R(A);
902
- }, I = async () => (sessionStorage.setItem("loginToken", "111"), !0);
903
- fe(async () => {
898
+ }), u = f("account"), g = f(!1), y = f(!1), c = () => {
899
+ g.value = !0;
900
+ }, q = (n, L) => {
901
+ g.value = !1, n && S(L);
902
+ }, R = async () => (sessionStorage.setItem("loginToken", "111"), !0);
903
+ ve(async () => {
904
904
  const n = localStorage.getItem("lastLoginAccount");
905
- n && (y.value = n), await I();
905
+ n && (h.value = n), await R();
906
906
  });
907
- const R = async (n) => {
908
- var F, B, G, J;
909
- if (g.value = !0, await Re(n)) {
910
- n != null && n.account && localStorage.setItem("lastLoginAccount", n.account), C("projectLogin", n);
911
- let Y = await Ve();
912
- C("systemContent", Y == null ? void 0 : Y.allMenuContents), d.push("/"), m.setLogRecordAsync({
907
+ const S = async (n) => {
908
+ var P, M, Y, ae;
909
+ if (y.value = !0, await Re(n)) {
910
+ n != null && n.account && localStorage.setItem("lastLoginAccount", n.account), T("projectLogin", n);
911
+ let Z = await Ve();
912
+ T("systemContent", Z == null ? void 0 : Z.allMenuContents), d.push("/"), m.setLogRecordAsync({
913
913
  type: "登录",
914
914
  data: {
915
- account: ((F = $.value) == null ? void 0 : F.account) ?? ((B = $.value) == null ? void 0 : B.账号),
916
- userName: ((G = $.value) == null ? void 0 : G.姓名) || ((J = $.value) == null ? void 0 : J.userName) || "未知"
915
+ account: ((P = V.value) == null ? void 0 : P.account) ?? ((M = V.value) == null ? void 0 : M.账号),
916
+ userName: ((Y = V.value) == null ? void 0 : Y.姓名) || ((ae = V.value) == null ? void 0 : ae.userName) || "未知"
917
917
  }
918
918
  }, "/login", "login"), e.setHasClickEditComp(!1);
919
919
  } else
920
- g.value = !1;
921
- g.value = !1;
920
+ y.value = !1;
921
+ y.value = !1;
922
922
  };
923
- Q(
923
+ X(
924
924
  () => p == null ? void 0 : p.loginContent,
925
925
  () => {
926
926
  let n = p == null ? void 0 : p.loginContent;
927
- n != null && n.account && (n != null && n.password) && !w.value && R(n);
927
+ n != null && n.account && (n != null && n.password) && !k.value && S(n);
928
928
  },
929
929
  { deep: !0, immediate: !0 }
930
930
  );
931
- const E = (n) => {
932
- r.value = n, c.value = !1, g.value = !1;
933
- }, O = (n) => {
934
- C("updateApiUrl", n);
931
+ const B = (n) => {
932
+ u.value = n, g.value = !1, y.value = !1;
933
+ }, E = (n) => {
934
+ T("updateApiUrl", n);
935
935
  };
936
- return (n, A) => (L(), N("div", wt, [
936
+ return (n, L) => ($(), x("div", wt, [
937
937
  i("div", kt, [
938
938
  i("div", Ut, [
939
939
  t(Me, { class: "login-left-bg" }, {
940
- img: l(() => {
941
- var F, B;
940
+ img: a(() => {
941
+ var P, M;
942
942
  return [
943
943
  i("div", Lt, [
944
944
  i("div", $t, [
945
- a.value ? (L(), N("div", Vt, [
945
+ o.value ? ($(), x("div", Vt, [
946
946
  i("img", {
947
- src: a.value,
947
+ src: o.value,
948
948
  alt: ""
949
949
  }, null, 8, At)
950
- ])) : le("", !0),
951
- i("div", qt, S(((F = j(k)) == null ? void 0 : F.EnglishName) || "Insofworks"), 1)
950
+ ])) : se("", !0),
951
+ i("div", qt, N(((P = H(U)) == null ? void 0 : P.EnglishName) || "Insofworks"), 1)
952
952
  ]),
953
- i("div", null, S(((B = j(k)) == null ? void 0 : B.chineseName) || "工业软件建模与开发系统"), 1)
953
+ i("div", null, N(((M = H(U)) == null ? void 0 : M.chineseName) || "工业软件建模与开发系统"), 1)
954
954
  ]),
955
- A[0] || (A[0] = i("div", { class: "divide-line" }, null, -1))
955
+ L[0] || (L[0] = i("div", { class: "divide-line" }, null, -1))
956
956
  ];
957
957
  }),
958
958
  _: 1
@@ -960,41 +960,41 @@ const Xe = () => ({ initUrlInfo: () => ({
960
960
  ]),
961
961
  i("div", It, [
962
962
  t(ze, {
963
- loading: g.value,
964
- onClickLogin: U,
965
- onHandleTabChange: E
963
+ loading: y.value,
964
+ onClickLogin: c,
965
+ onHandleTabChange: B
966
966
  }, {
967
- title: l(() => [
968
- P(S(o.value.loginTitle), 1)
967
+ title: a(() => [
968
+ j(N(r.value.loginTitle), 1)
969
969
  ]),
970
- tabLabel1: l(() => [
971
- P(S(o.value.tabs[0].name), 1)
970
+ tabLabel1: a(() => [
971
+ j(N(r.value.tabs[0].name), 1)
972
972
  ]),
973
- tabContent1: l(() => [
973
+ tabContent1: a(() => [
974
974
  t(bt, {
975
- activeTabName: r.value,
976
- isClickLogin: c.value,
977
- loginContent: { account: y.value },
978
- onHandleLoginFormChange: u,
979
- onUpdateApiUrl: O
975
+ activeTabName: u.value,
976
+ isClickLogin: g.value,
977
+ loginContent: A.value,
978
+ onHandleLoginFormChange: q,
979
+ onUpdateApiUrl: E
980
980
  }, null, 8, ["activeTabName", "isClickLogin", "loginContent"])
981
981
  ]),
982
- tabButton1: l(() => [
983
- P(S(o.value.tabs[0].btnLabel), 1)
982
+ tabButton1: a(() => [
983
+ j(N(r.value.tabs[0].btnLabel), 1)
984
984
  ]),
985
- tabLabel2: l(() => [
986
- P(S(o.value.tabs[1].name), 1)
985
+ tabLabel2: a(() => [
986
+ j(N(r.value.tabs[1].name), 1)
987
987
  ]),
988
- tabContent2: l(() => [
988
+ tabContent2: a(() => [
989
989
  t(Tt, {
990
990
  systemKey: n.oldSystemKey,
991
- activeTabName: r.value,
992
- isClickLogin: c.value,
993
- onHandleLoginFormChange: u
991
+ activeTabName: u.value,
992
+ isClickLogin: g.value,
993
+ onHandleLoginFormChange: q
994
994
  }, null, 8, ["systemKey", "activeTabName", "isClickLogin"])
995
995
  ]),
996
- tabButton2: l(() => [
997
- P(S(o.value.tabs[1].btnLabel), 1)
996
+ tabButton2: a(() => [
997
+ j(N(r.value.tabs[1].btnLabel), 1)
998
998
  ]),
999
999
  _: 1
1000
1000
  }, 8, ["loading"])
@@ -1002,7 +1002,7 @@ const Xe = () => ({ initUrlInfo: () => ({
1002
1002
  ])
1003
1003
  ]));
1004
1004
  }
1005
- }), Pt = /* @__PURE__ */ H(Ft, [["__scopeId", "data-v-db90b1ee"]]);
1005
+ }), Pt = /* @__PURE__ */ K(Ft, [["__scopeId", "data-v-3cff58f1"]]);
1006
1006
  export {
1007
1007
  Pt as default
1008
1008
  };