auto-vue-basic 0.0.76 → 0.0.77

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,15 +1,15 @@
1
- import { defineComponent as O, createElementBlock as B, openBlock as L, createElementVNode as N, toRef as ne, resolveComponent as s, createBlock as T, unref as e, isRef as P, withCtx as o, createVNode as l, normalizeClass as ve, toDisplayString as z, ref as I, Fragment as G, withKeys as ge, renderList as ae, isVNode as we, reactive as Ne, onMounted as Pe, watch as xe, nextTick as Be, createCommentVNode as je, createTextVNode as Z, onBeforeMount as Ke } from "vue";
1
+ import { defineComponent as O, createElementBlock as B, openBlock as C, createElementVNode as N, toRef as ne, resolveComponent as s, createBlock as T, unref as e, isRef as P, withCtx as o, createVNode as l, normalizeClass as ve, toDisplayString as z, ref as I, Fragment as G, withKeys as ge, renderList as ae, isVNode as we, reactive as Ne, onMounted as Pe, watch as xe, nextTick as Be, createCommentVNode as je, createTextVNode as Z, onBeforeMount as Ke } from "vue";
2
2
  import { ApiUtils as W, useLoading as E, useSelect as re, Translate as a, InlineRefreshButton as pe, useForm as J, FormDialog as ee, useCrudPage as F, DEFAULT_STATUS_KEY as Re, ModifyButton as le, DEFAULT_REMOVE_KEY as We, ProTable as me, DEFAULT_PAGE_KEY as he, SearchButton as oe, RefreshButton as K, OpenButton as j, useCacheStore as Ye, RequestButton as Q, BasicDrawer as ce, BasicRadioButton as De, RulesUtils as Ge, BasicAvatar as He, TimeUtils as $, ProTableList as de, AssetsUtils as Se, notification as Qe, DEFAULT_LIST_URL as Je, REQUEST_LOG_URL as Xe, ERROR_LOG_URL as Ze, SQL_LOG_URL as el } from "auto-vue-manual";
3
3
  const ll = {
4
4
  tops: "tops",
5
5
  rules: "rules"
6
- }, Y = W.routineApi("menu", "id", ll, {}, ["TOP_MENU_LIST", "MENU_LIST"]), Le = W.routineApi("rule", "key");
6
+ }, Y = W.routineApi("menu", "id", ll, {}, ["TOP_MENU_LIST", "MENU_LIST"]), Ce = W.routineApi("rule", "key");
7
7
  /*! Element Plus Icons Vue v2.3.2 */
8
8
  var al = /* @__PURE__ */ O({
9
9
  name: "Key",
10
10
  __name: "key",
11
11
  setup(x) {
12
- return (U, k) => (L(), B("svg", {
12
+ return (U, k) => (C(), B("svg", {
13
13
  xmlns: "http://www.w3.org/2000/svg",
14
14
  viewBox: "0 0 1024 1024"
15
15
  }, [
@@ -23,7 +23,7 @@ var al = /* @__PURE__ */ O({
23
23
  name: "Search",
24
24
  __name: "search",
25
25
  setup(x) {
26
- return (U, k) => (L(), B("svg", {
26
+ return (U, k) => (C(), B("svg", {
27
27
  xmlns: "http://www.w3.org/2000/svg",
28
28
  viewBox: "0 0 1024 1024"
29
29
  }, [
@@ -66,7 +66,7 @@ const rl = /* @__PURE__ */ O({
66
66
  });
67
67
  return (v, u) => {
68
68
  const f = s("el-space"), g = s("el-select-v2");
69
- return L(), T(g, {
69
+ return C(), T(g, {
70
70
  class: "w-full",
71
71
  modelValue: e(b),
72
72
  "onUpdate:modelValue": u[1] || (u[1] = (_) => P(b) ? b.value = _ : null),
@@ -169,7 +169,7 @@ const rl = /* @__PURE__ */ O({
169
169
  modify: g
170
170
  }), (w, t) => {
171
171
  const d = s("el-form-item"), r = s("el-col"), y = s("el-input-number"), m = s("el-row"), S = s("el-input"), M = s("el-switch"), q = s("el-form");
172
- return L(), T(e(ee), {
172
+ return C(), T(e(ee), {
173
173
  modelValue: e(c),
174
174
  "onUpdate:modelValue": t[17] || (t[17] = (R) => P(c) ? c.value = R : null),
175
175
  title: e(i)(),
@@ -502,7 +502,7 @@ const rl = /* @__PURE__ */ O({
502
502
  });
503
503
  return (v, u) => {
504
504
  const f = s("el-space"), g = s("el-select-v2");
505
- return L(), T(g, {
505
+ return C(), T(g, {
506
506
  class: "w-full",
507
507
  modelValue: e(b),
508
508
  "onUpdate:modelValue": u[1] || (u[1] = (_) => P(b) ? b.value = _ : null),
@@ -580,13 +580,13 @@ const rl = /* @__PURE__ */ O({
580
580
  trigger: "blur"
581
581
  }
582
582
  ]
583
- }, { modal: c, title: i, form: p, formData: n, requesting: v, executing: u, open: f, modify: g, submit: _, closed: A } = J(h, V, Le);
583
+ }, { modal: c, title: i, form: p, formData: n, requesting: v, executing: u, open: f, modify: g, submit: _, closed: A } = J(h, V, Ce);
584
584
  return U({
585
585
  open: f,
586
586
  modify: g
587
587
  }), (w, t) => {
588
588
  const d = s("el-form-item"), r = s("el-input-number"), y = s("el-input"), m = s("el-col"), S = s("el-row"), M = s("el-form");
589
- return L(), T(e(ee), {
589
+ return C(), T(e(ee), {
590
590
  modelValue: e(c),
591
591
  "onUpdate:modelValue": t[6] || (t[6] = (q) => P(c) ? c.value = q : null),
592
592
  title: e(i)("menu.rules"),
@@ -861,7 +861,7 @@ const Nl = /* @__PURE__ */ O({
861
861
  openFormModal: _,
862
862
  editFormModal: A
863
863
  } = F(), w = (t) => {
864
- Le[We]({
864
+ Ce[We]({
865
865
  key: t
866
866
  }).then(() => {
867
867
  k.value = "", n();
@@ -869,7 +869,7 @@ const Nl = /* @__PURE__ */ O({
869
869
  };
870
870
  return (t, d) => {
871
871
  const r = s("el-button"), y = s("el-input"), m = s("el-radio-button"), S = s("el-radio-group"), M = s("el-space"), q = s("el-page-header"), R = s("el-card");
872
- return L(), T(R, {
872
+ return C(), T(R, {
873
873
  class: "basic-card flex-full",
874
874
  "body-class": "flex-1",
875
875
  onClick: d[5] || (d[5] = () => k.value = "")
@@ -893,20 +893,20 @@ const Nl = /* @__PURE__ */ O({
893
893
  default: o(() => [l(y, {
894
894
  class: "basic-search-input",
895
895
  modelValue: e(i).keyword,
896
- "onUpdate:modelValue": d[0] || (d[0] = (C) => e(i).keyword = C),
896
+ "onUpdate:modelValue": d[0] || (d[0] = (L) => e(i).keyword = L),
897
897
  placeholder: e(a)("placeholder.keyword"),
898
898
  clearable: "",
899
- onKeyup: d[1] || (d[1] = ge((C) => e(p)(), ["enter"])),
900
- onClear: d[2] || (d[2] = (C) => e(p)())
899
+ onKeyup: d[1] || (d[1] = ge((L) => e(p)(), ["enter"])),
900
+ onClear: d[2] || (d[2] = (L) => e(p)())
901
901
  }, null, 8, ["modelValue", "placeholder"]), l(S, {
902
902
  modelValue: e(i).status,
903
- "onUpdate:modelValue": d[3] || (d[3] = (C) => e(i).status = C),
904
- onChange: d[4] || (d[4] = (C) => e(p)())
903
+ "onUpdate:modelValue": d[3] || (d[3] = (L) => e(i).status = L),
904
+ onChange: d[4] || (d[4] = (L) => e(p)())
905
905
  }, {
906
- default: o(() => [(L(), B(G, null, ae([0, 1, 2], (C) => l(m, {
907
- key: C,
908
- label: e(a)(`status.${C}`),
909
- value: C
906
+ default: o(() => [(C(), B(G, null, ae([0, 1, 2], (L) => l(m, {
907
+ key: L,
908
+ label: e(a)(`status.${L}`),
909
+ value: L
910
910
  }, null, 8, ["label", "value"])), 64))]),
911
911
  _: 1
912
912
  }, 8, ["modelValue"]), l(e(oe), {
@@ -1006,7 +1006,7 @@ const Nl = /* @__PURE__ */ O({
1006
1006
  cleanChecked: _
1007
1007
  }), (w, t) => {
1008
1008
  const d = s("el-checkbox"), r = s("el-space"), y = s("el-text"), m = s("el-divider"), S = s("el-checkbox-group");
1009
- return L(), B("div", il, [
1009
+ return C(), B("div", il, [
1010
1010
  l(r, { style: { "margin-bottom": "6px" } }, {
1011
1011
  default: o(() => [
1012
1012
  l(d, {
@@ -1036,7 +1036,7 @@ const Nl = /* @__PURE__ */ O({
1036
1036
  class: "rule-check-content"
1037
1037
  }, {
1038
1038
  default: o(() => [
1039
- (L(!0), B(G, null, ae(e(p), (M) => (L(), B("div", {
1039
+ (C(!0), B(G, null, ae(e(p), (M) => (C(), B("div", {
1040
1040
  key: M.id
1041
1041
  }, [
1042
1042
  l(r, {
@@ -1062,7 +1062,7 @@ const Nl = /* @__PURE__ */ O({
1062
1062
  _: 2
1063
1063
  }, 1032, ["model-value", "disabled", "indeterminate", "onChange"]),
1064
1064
  l(m, { direction: "vertical" }),
1065
- M.rules ? (L(), T(S, {
1065
+ M.rules ? (C(), T(S, {
1066
1066
  key: 0,
1067
1067
  modelValue: i.MenuList[M.id],
1068
1068
  "onUpdate:modelValue": (q) => i.MenuList[M.id] = q,
@@ -1071,7 +1071,7 @@ const Nl = /* @__PURE__ */ O({
1071
1071
  onChange: g
1072
1072
  }, {
1073
1073
  default: o(() => [
1074
- (L(!0), B(G, null, ae(M.rules, (q) => (L(), T(d, {
1074
+ (C(!0), B(G, null, ae(M.rules, (q) => (C(), T(d, {
1075
1075
  key: q.key,
1076
1076
  value: q.key
1077
1077
  }, {
@@ -1093,12 +1093,12 @@ const Nl = /* @__PURE__ */ O({
1093
1093
  ]);
1094
1094
  };
1095
1095
  }
1096
- }), Ce = (x, U) => {
1096
+ }), Le = (x, U) => {
1097
1097
  const k = x.__vccOpts || x;
1098
1098
  for (const [h, V] of U)
1099
1099
  k[h] = V;
1100
1100
  return k;
1101
- }, cl = /* @__PURE__ */ Ce(ml, [["__scopeId", "data-v-7adb5f76"]]), fl = /* @__PURE__ */ O({
1101
+ }, cl = /* @__PURE__ */ Le(ml, [["__scopeId", "data-v-7adb5f76"]]), fl = /* @__PURE__ */ O({
1102
1102
  __name: "RoleFormModal",
1103
1103
  emits: ["refresh"],
1104
1104
  setup(x, { expose: U, emit: k }) {
@@ -1134,9 +1134,9 @@ const Nl = /* @__PURE__ */ O({
1134
1134
  modify: _
1135
1135
  }), (d, r) => {
1136
1136
  const y = s("el-input"), m = s("el-form-item"), S = s("el-col"), M = s("el-input-number"), q = s("el-row"), R = s("el-form");
1137
- return L(), T(e(ee), {
1137
+ return C(), T(e(ee), {
1138
1138
  modelValue: e(i),
1139
- "onUpdate:modelValue": r[6] || (r[6] = (C) => P(i) ? i.value = C : null),
1139
+ "onUpdate:modelValue": r[6] || (r[6] = (L) => P(i) ? i.value = L : null),
1140
1140
  title: e(p)(),
1141
1141
  width: "1000px",
1142
1142
  executing: e(f),
@@ -1164,7 +1164,7 @@ const Nl = /* @__PURE__ */ O({
1164
1164
  default: o(() => [
1165
1165
  l(y, {
1166
1166
  modelValue: e(v).module,
1167
- "onUpdate:modelValue": r[0] || (r[0] = (C) => e(v).module = C),
1167
+ "onUpdate:modelValue": r[0] || (r[0] = (L) => e(v).module = L),
1168
1168
  placeholder: e(a)("placeholder.input")
1169
1169
  }, null, 8, ["modelValue", "placeholder"])
1170
1170
  ]),
@@ -1183,7 +1183,7 @@ const Nl = /* @__PURE__ */ O({
1183
1183
  l(M, {
1184
1184
  class: "w-full",
1185
1185
  modelValue: e(v).sort,
1186
- "onUpdate:modelValue": r[1] || (r[1] = (C) => e(v).sort = C),
1186
+ "onUpdate:modelValue": r[1] || (r[1] = (L) => e(v).sort = L),
1187
1187
  min: 0,
1188
1188
  placeholder: e(a)("placeholder.input")
1189
1189
  }, null, 8, ["modelValue", "placeholder"])
@@ -1203,7 +1203,7 @@ const Nl = /* @__PURE__ */ O({
1203
1203
  default: o(() => [
1204
1204
  l(y, {
1205
1205
  modelValue: e(v).name,
1206
- "onUpdate:modelValue": r[2] || (r[2] = (C) => e(v).name = C),
1206
+ "onUpdate:modelValue": r[2] || (r[2] = (L) => e(v).name = L),
1207
1207
  placeholder: e(a)("placeholder.input")
1208
1208
  }, null, 8, ["modelValue", "placeholder"])
1209
1209
  ]),
@@ -1216,7 +1216,7 @@ const Nl = /* @__PURE__ */ O({
1216
1216
  default: o(() => [
1217
1217
  l(y, {
1218
1218
  modelValue: e(v).en_name,
1219
- "onUpdate:modelValue": r[3] || (r[3] = (C) => e(v).en_name = C),
1219
+ "onUpdate:modelValue": r[3] || (r[3] = (L) => e(v).en_name = L),
1220
1220
  placeholder: e(a)("placeholder.input")
1221
1221
  }, null, 8, ["modelValue", "placeholder"])
1222
1222
  ]),
@@ -1229,7 +1229,7 @@ const Nl = /* @__PURE__ */ O({
1229
1229
  default: o(() => [
1230
1230
  l(y, {
1231
1231
  modelValue: e(v).remark,
1232
- "onUpdate:modelValue": r[4] || (r[4] = (C) => e(v).remark = C),
1232
+ "onUpdate:modelValue": r[4] || (r[4] = (L) => e(v).remark = L),
1233
1233
  placeholder: e(a)("placeholder.input")
1234
1234
  }, null, 8, ["modelValue", "placeholder"])
1235
1235
  ]),
@@ -1244,7 +1244,7 @@ const Nl = /* @__PURE__ */ O({
1244
1244
  ref_key: "rulesCheck",
1245
1245
  ref: V,
1246
1246
  modelValue: e(v).rules,
1247
- "onUpdate:modelValue": r[5] || (r[5] = (C) => e(v).rules = C),
1247
+ "onUpdate:modelValue": r[5] || (r[5] = (L) => e(v).rules = L),
1248
1248
  disabled: e(u) || e(f)
1249
1249
  }, null, 8, ["modelValue", "disabled"])
1250
1250
  ]),
@@ -1318,7 +1318,7 @@ const Nl = /* @__PURE__ */ O({
1318
1318
  } = F(U);
1319
1319
  return (f, g) => {
1320
1320
  const _ = s("el-input"), A = s("el-space"), w = s("el-page-header"), t = s("el-card");
1321
- return L(), T(t, {
1321
+ return C(), T(t, {
1322
1322
  class: "basic-card flex-full",
1323
1323
  "body-class": "flex-1"
1324
1324
  }, {
@@ -1383,7 +1383,7 @@ const Nl = /* @__PURE__ */ O({
1383
1383
  type: Boolean,
1384
1384
  default: !1
1385
1385
  },
1386
- "allow-create": {
1386
+ allowCreate: {
1387
1387
  type: Boolean,
1388
1388
  default: !1
1389
1389
  },
@@ -1412,7 +1412,7 @@ const Nl = /* @__PURE__ */ O({
1412
1412
  });
1413
1413
  return (v, u) => {
1414
1414
  const f = s("el-space"), g = s("el-select-v2");
1415
- return L(), T(g, {
1415
+ return C(), T(g, {
1416
1416
  class: "w-full",
1417
1417
  modelValue: e(b),
1418
1418
  "onUpdate:modelValue": u[1] || (u[1] = (_) => P(b) ? b.value = _ : null),
@@ -1421,7 +1421,7 @@ const Nl = /* @__PURE__ */ O({
1421
1421
  disabled: e(V),
1422
1422
  clearable: x.clearable,
1423
1423
  filterable: "",
1424
- "allow-create": v.allow - v.create,
1424
+ "allow-create": x.allowCreate,
1425
1425
  "default-first-option": "",
1426
1426
  placeholder: e(a)("placeholder.select"),
1427
1427
  filterOptions: e(n),
@@ -1502,7 +1502,7 @@ const Nl = /* @__PURE__ */ O({
1502
1502
  modify: w
1503
1503
  }), (r, y) => {
1504
1504
  const m = s("el-form-item"), S = s("el-input"), M = s("el-space"), q = s("el-form");
1505
- return L(), T(e(ee), {
1505
+ return C(), T(e(ee), {
1506
1506
  modelValue: e(n),
1507
1507
  "onUpdate:modelValue": y[3] || (y[3] = (R) => P(n) ? n.value = R : null),
1508
1508
  title: e(v)(),
@@ -1561,10 +1561,10 @@ const Nl = /* @__PURE__ */ O({
1561
1561
  style: { width: "100%" }
1562
1562
  }, {
1563
1563
  default: o(() => [
1564
- (L(!0), B(G, null, ae(c.value, (R) => (L(), B("div", { key: R }, [
1564
+ (C(!0), B(G, null, ae(c.value, (R) => (C(), B("div", { key: R }, [
1565
1565
  l(S, {
1566
1566
  modelValue: e(f).language[R],
1567
- "onUpdate:modelValue": (C) => e(f).language[R] = C,
1567
+ "onUpdate:modelValue": (L) => e(f).language[R] = L,
1568
1568
  placeholder: e(a)("i18n.placeholder.key")
1569
1569
  }, {
1570
1570
  prepend: o(() => [
@@ -1698,15 +1698,15 @@ const Te = /* @__PURE__ */ O({
1698
1698
  }), U({
1699
1699
  open: d
1700
1700
  }), (y, m) => {
1701
- const S = s("el-input"), M = s("el-radio-button"), q = s("el-radio-group"), R = s("el-space"), C = s("el-page-header");
1702
- return L(), T(e(ce), {
1701
+ const S = s("el-input"), M = s("el-radio-button"), q = s("el-radio-group"), R = s("el-space"), L = s("el-page-header");
1702
+ return C(), T(e(ce), {
1703
1703
  modelValue: h.value,
1704
1704
  "onUpdate:modelValue": m[7] || (m[7] = (D) => h.value = D),
1705
1705
  width: "880px",
1706
1706
  "show-close": !1,
1707
1707
  class: "basic-drawer"
1708
1708
  }, {
1709
- title: o(() => [l(C, {
1709
+ title: o(() => [l(L, {
1710
1710
  class: "basic-header"
1711
1711
  }, {
1712
1712
  title: o(() => [l(e(K), {
@@ -1740,7 +1740,7 @@ const Te = /* @__PURE__ */ O({
1740
1740
  "onUpdate:modelValue": m[4] || (m[4] = (D) => e(u).status = D),
1741
1741
  onChange: m[5] || (m[5] = (D) => e(f)())
1742
1742
  }, {
1743
- default: o(() => [(L(), B(G, null, ae([0, 1, 2], (D) => l(M, {
1743
+ default: o(() => [(C(), B(G, null, ae([0, 1, 2], (D) => l(M, {
1744
1744
  key: D,
1745
1745
  label: e(a)(`status.${D}`),
1746
1746
  value: D
@@ -1814,8 +1814,8 @@ const Te = /* @__PURE__ */ O({
1814
1814
  c.value = "600px";
1815
1815
  }
1816
1816
  function M(R) {
1817
- let C = R.module.toLowerCase() + "." + R.key.toLowerCase();
1818
- _.keys = C, _.values.push(C);
1817
+ let L = R.module.toLowerCase() + "." + R.key.toLowerCase();
1818
+ _.keys = L, _.values.push(L);
1819
1819
  for (const D in R.language)
1820
1820
  p.value[D] || (p.value[D] = []), p.value[D].push(R.language[D]);
1821
1821
  }
@@ -1830,11 +1830,11 @@ const Te = /* @__PURE__ */ O({
1830
1830
  }), U({
1831
1831
  open: t,
1832
1832
  modify: d
1833
- }), (R, C) => {
1833
+ }), (R, L) => {
1834
1834
  const D = s("el-page-header"), fe = s("el-form-item"), Fe = s("el-button"), Ue = s("el-input"), Ee = s("el-tag"), ze = s("el-space"), Ie = s("el-form");
1835
- return L(), T(e(ce), {
1835
+ return C(), T(e(ce), {
1836
1836
  modelValue: e(u),
1837
- "onUpdate:modelValue": C[3] || (C[3] = (X) => P(u) ? u.value = X : null),
1837
+ "onUpdate:modelValue": L[3] || (L[3] = (X) => P(u) ? u.value = X : null),
1838
1838
  width: c.value,
1839
1839
  "show-close": !1,
1840
1840
  class: "basic-drawer"
@@ -1876,7 +1876,7 @@ const Te = /* @__PURE__ */ O({
1876
1876
  default: o(() => [
1877
1877
  l(e(De), {
1878
1878
  modelValue: e(_).app,
1879
- "onUpdate:modelValue": C[0] || (C[0] = (X) => e(_).app = X),
1879
+ "onUpdate:modelValue": L[0] || (L[0] = (X) => e(_).app = X),
1880
1880
  "cache-key": "I18NAPPS",
1881
1881
  hidden: [0],
1882
1882
  url: e(te).urls.apps
@@ -1892,7 +1892,7 @@ const Te = /* @__PURE__ */ O({
1892
1892
  default: o(() => [
1893
1893
  l(Ue, {
1894
1894
  modelValue: e(_).keys,
1895
- "onUpdate:modelValue": C[1] || (C[1] = (X) => e(_).keys = X),
1895
+ "onUpdate:modelValue": L[1] || (L[1] = (X) => e(_).keys = X),
1896
1896
  placeholder: e(a)("i18n.placeholder.key")
1897
1897
  }, {
1898
1898
  append: o(() => [
@@ -1920,7 +1920,7 @@ const Te = /* @__PURE__ */ O({
1920
1920
  label: e(a)("i18n.values")
1921
1921
  }, {
1922
1922
  default: o(() => [
1923
- (L(!0), B(G, null, ae(p.value, (X, ye) => (L(), B("div", {
1923
+ (C(!0), B(G, null, ae(p.value, (X, ye) => (C(), B("div", {
1924
1924
  key: ye,
1925
1925
  class: "w-full"
1926
1926
  }, [
@@ -1950,7 +1950,7 @@ const Te = /* @__PURE__ */ O({
1950
1950
  default: o(() => [
1951
1951
  l(Ue, {
1952
1952
  modelValue: e(_).remark,
1953
- "onUpdate:modelValue": C[2] || (C[2] = (X) => e(_).remark = X),
1953
+ "onUpdate:modelValue": L[2] || (L[2] = (X) => e(_).remark = X),
1954
1954
  placeholder: e(a)("placeholder.input")
1955
1955
  }, null, 8, ["modelValue", "placeholder"])
1956
1956
  ]),
@@ -2085,8 +2085,8 @@ const Bl = /* @__PURE__ */ O({
2085
2085
  });
2086
2086
  }
2087
2087
  return (d, r) => {
2088
- const y = s("el-divider"), m = s("el-input"), S = s("el-radio-button"), M = s("el-radio-group"), q = s("el-space"), R = s("el-page-header"), C = s("el-card");
2089
- return L(), T(C, {
2088
+ const y = s("el-divider"), m = s("el-input"), S = s("el-radio-button"), M = s("el-radio-group"), q = s("el-space"), R = s("el-page-header"), L = s("el-card");
2089
+ return C(), T(L, {
2090
2090
  class: "basic-card flex-full",
2091
2091
  "body-class": "flex-1"
2092
2092
  }, {
@@ -2141,7 +2141,7 @@ const Bl = /* @__PURE__ */ O({
2141
2141
  "onUpdate:modelValue": r[5] || (r[5] = (D) => e(n).status = D),
2142
2142
  onChange: r[6] || (r[6] = (D) => e(v)())
2143
2143
  }, {
2144
- default: o(() => [(L(), B(G, null, ae([0, 1, 2], (D) => l(S, {
2144
+ default: o(() => [(C(), B(G, null, ae([0, 1, 2], (D) => l(S, {
2145
2145
  key: D,
2146
2146
  label: e(a)(`status.${D}`),
2147
2147
  value: D
@@ -2243,8 +2243,8 @@ const Bl = /* @__PURE__ */ O({
2243
2243
  open: u,
2244
2244
  modify: f
2245
2245
  }), (d, r) => {
2246
- const y = s("el-input"), m = s("el-form-item"), S = s("el-radio-button"), M = s("el-radio-group"), q = s("el-checkbox"), R = s("el-checkbox-group"), C = s("el-form");
2247
- return L(), T(e(ee), {
2246
+ const y = s("el-input"), m = s("el-form-item"), S = s("el-radio-button"), M = s("el-radio-group"), q = s("el-checkbox"), R = s("el-checkbox-group"), L = s("el-form");
2247
+ return C(), T(e(ee), {
2248
2248
  modelValue: e(b),
2249
2249
  "onUpdate:modelValue": r[7] || (r[7] = (D) => P(b) ? b.value = D : null),
2250
2250
  title: e(c)(),
@@ -2254,7 +2254,7 @@ const Bl = /* @__PURE__ */ O({
2254
2254
  onSubmit: e(g)
2255
2255
  }, {
2256
2256
  default: o(() => [
2257
- l(C, {
2257
+ l(L, {
2258
2258
  ref_key: "form",
2259
2259
  ref: i,
2260
2260
  model: e(p),
@@ -2358,7 +2358,7 @@ const Bl = /* @__PURE__ */ O({
2358
2358
  "onUpdate:modelValue": r[5] || (r[5] = (D) => e(p).roles = D)
2359
2359
  }, {
2360
2360
  default: o(() => [
2361
- (L(!0), B(G, null, ae(w.value, (D) => (L(), T(q, {
2361
+ (C(!0), B(G, null, ae(w.value, (D) => (C(), T(q, {
2362
2362
  key: D.key,
2363
2363
  value: D.key
2364
2364
  }, {
@@ -2466,7 +2466,7 @@ const Bl = /* @__PURE__ */ O({
2466
2466
  } = F(U);
2467
2467
  return (f, g) => {
2468
2468
  const _ = s("el-input"), A = s("el-space"), w = s("el-page-header"), t = s("el-card");
2469
- return L(), T(t, {
2469
+ return C(), T(t, {
2470
2470
  class: "basic-card flex-full",
2471
2471
  "body-class": "flex-1"
2472
2472
  }, {
@@ -2550,7 +2550,7 @@ const Bl = /* @__PURE__ */ O({
2550
2550
  refresh: p
2551
2551
  }), (v, u) => {
2552
2552
  const f = s("el-select-v2");
2553
- return L(), T(f, {
2553
+ return C(), T(f, {
2554
2554
  modelValue: e(c),
2555
2555
  "onUpdate:modelValue": u[0] || (u[0] = (g) => P(c) ? c.value = g : null),
2556
2556
  options: e(i),
@@ -2591,7 +2591,7 @@ const Bl = /* @__PURE__ */ O({
2591
2591
  modify: g
2592
2592
  }), (w, t) => {
2593
2593
  const d = s("el-form-item"), r = s("el-input"), y = s("el-form");
2594
- return L(), T(e(ee), {
2594
+ return C(), T(e(ee), {
2595
2595
  modelValue: e(c),
2596
2596
  "onUpdate:modelValue": t[7] || (t[7] = (m) => P(c) ? c.value = m : null),
2597
2597
  title: e(i)("config.site"),
@@ -2748,7 +2748,7 @@ const Bl = /* @__PURE__ */ O({
2748
2748
  refresh: p
2749
2749
  }), (v, u) => {
2750
2750
  const f = s("el-select-v2");
2751
- return L(), T(f, {
2751
+ return C(), T(f, {
2752
2752
  modelValue: e(c),
2753
2753
  "onUpdate:modelValue": u[0] || (u[0] = (g) => P(c) ? c.value = g : null),
2754
2754
  options: e(i),
@@ -2784,7 +2784,7 @@ const Bl = /* @__PURE__ */ O({
2784
2784
  modify: g
2785
2785
  }), (w, t) => {
2786
2786
  const d = s("el-form-item"), r = s("el-input"), y = s("el-date-picker"), m = s("el-form");
2787
- return L(), T(e(ee), {
2787
+ return C(), T(e(ee), {
2788
2788
  modelValue: e(c),
2789
2789
  "onUpdate:modelValue": t[4] || (t[4] = (S) => P(c) ? c.value = S : null),
2790
2790
  title: e(i)("config.domain"),
@@ -2915,7 +2915,7 @@ const Bl = /* @__PURE__ */ O({
2915
2915
  refresh: p
2916
2916
  }), (v, u) => {
2917
2917
  const f = s("el-select-v2");
2918
- return L(), T(f, {
2918
+ return C(), T(f, {
2919
2919
  modelValue: e(c),
2920
2920
  "onUpdate:modelValue": u[0] || (u[0] = (g) => P(c) ? c.value = g : null),
2921
2921
  options: e(i),
@@ -2959,7 +2959,7 @@ const Bl = /* @__PURE__ */ O({
2959
2959
  formData: n
2960
2960
  }), (w, t) => {
2961
2961
  const d = s("el-form-item"), r = s("el-radio-button"), y = s("el-radio-group"), m = s("el-input"), S = s("el-form");
2962
- return L(), T(e(ee), {
2962
+ return C(), T(e(ee), {
2963
2963
  modelValue: e(c),
2964
2964
  "onUpdate:modelValue": t[8] || (t[8] = (M) => P(c) ? c.value = M : null),
2965
2965
  title: e(i)("ssl.ssl"),
@@ -3133,7 +3133,7 @@ const Bl = /* @__PURE__ */ O({
3133
3133
  modify: g
3134
3134
  }), (w, t) => {
3135
3135
  const d = s("el-input"), r = s("el-form-item"), y = s("el-form");
3136
- return L(), T(e(ee), {
3136
+ return C(), T(e(ee), {
3137
3137
  modelValue: e(c),
3138
3138
  "onUpdate:modelValue": t[6] || (t[6] = (m) => P(c) ? c.value = m : null),
3139
3139
  title: e(i)("config.domain"),
@@ -3289,7 +3289,7 @@ const Bl = /* @__PURE__ */ O({
3289
3289
  }
3290
3290
  }), (u, f) => {
3291
3291
  const g = s("el-page-header");
3292
- return L(), T(e(ce), {
3292
+ return C(), T(e(ce), {
3293
3293
  modelValue: h.value,
3294
3294
  "onUpdate:modelValue": f[0] || (f[0] = (_) => h.value = _),
3295
3295
  width: "400px",
@@ -3402,7 +3402,7 @@ const Bl = /* @__PURE__ */ O({
3402
3402
  }
3403
3403
  }), (w, t) => {
3404
3404
  const d = s("el-space"), r = s("el-page-header");
3405
- return L(), T(e(ce), {
3405
+ return C(), T(e(ce), {
3406
3406
  modelValue: h.value,
3407
3407
  "onUpdate:modelValue": t[0] || (t[0] = (y) => h.value = y),
3408
3408
  width: "600px",
@@ -3558,7 +3558,7 @@ const Bl = /* @__PURE__ */ O({
3558
3558
  open: f
3559
3559
  }), (A, w) => {
3560
3560
  const t = s("el-page-header");
3561
- return L(), T(e(ce), {
3561
+ return C(), T(e(ce), {
3562
3562
  modelValue: b.value,
3563
3563
  "onUpdate:modelValue": w[0] || (w[0] = (d) => b.value = d),
3564
3564
  width: "1000px",
@@ -3595,7 +3595,7 @@ const Bl = /* @__PURE__ */ O({
3595
3595
  }, 8, ["modelValue"]);
3596
3596
  };
3597
3597
  }
3598
- }), Ae = W.routineApi("SSLLog", "id"), Ll = /* @__PURE__ */ O({
3598
+ }), Ae = W.routineApi("SSLLog", "id"), Cl = /* @__PURE__ */ O({
3599
3599
  __name: "SSLLogTableDrawer",
3600
3600
  props: {
3601
3601
  ssl: {
@@ -3649,7 +3649,7 @@ const Bl = /* @__PURE__ */ O({
3649
3649
  open: n
3650
3650
  }), (f, g) => {
3651
3651
  const _ = s("el-page-header");
3652
- return L(), T(e(ce), {
3652
+ return C(), T(e(ce), {
3653
3653
  modelValue: b.value,
3654
3654
  "onUpdate:modelValue": g[0] || (g[0] = (A) => b.value = A),
3655
3655
  width: "600px",
@@ -3695,7 +3695,7 @@ const Bl = /* @__PURE__ */ O({
3695
3695
  }, 8, ["modelValue"]);
3696
3696
  };
3697
3697
  }
3698
- }), Cl = /* @__PURE__ */ O({
3698
+ }), Ll = /* @__PURE__ */ O({
3699
3699
  __name: "index",
3700
3700
  setup(x) {
3701
3701
  const U = I(), {
@@ -3802,7 +3802,7 @@ const Bl = /* @__PURE__ */ O({
3802
3802
  };
3803
3803
  return (r, y) => {
3804
3804
  const m = s("el-space"), S = s("el-page-header"), M = s("el-card");
3805
- return L(), T(M, {
3805
+ return C(), T(M, {
3806
3806
  "body-style": {
3807
3807
  padding: "12px",
3808
3808
  height: "450px"
@@ -3855,7 +3855,7 @@ const Bl = /* @__PURE__ */ O({
3855
3855
  }, null, 512), l(Sl, {
3856
3856
  ref_key: "sslTableDrawerRef",
3857
3857
  ref: f
3858
- }, null, 512), l(Ll, {
3858
+ }, null, 512), l(Cl, {
3859
3859
  ref_key: "sslLogTableDrawerRef",
3860
3860
  ref: _
3861
3861
  }, null, 512)]),
@@ -3863,7 +3863,7 @@ const Bl = /* @__PURE__ */ O({
3863
3863
  });
3864
3864
  };
3865
3865
  }
3866
- }), ql = /* @__PURE__ */ Ce(Cl, [["__scopeId", "data-v-17c31592"]]), Tl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3866
+ }), ql = /* @__PURE__ */ Le(Ll, [["__scopeId", "data-v-17c31592"]]), Tl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3867
3867
  __proto__: null,
3868
3868
  default: ql
3869
3869
  }, Symbol.toStringTag, { value: "Module" })), Ol = {
@@ -3901,7 +3901,7 @@ const Bl = /* @__PURE__ */ O({
3901
3901
  } = F(U);
3902
3902
  return (p, n) => {
3903
3903
  const v = s("el-date-picker"), u = s("el-space"), f = s("el-page-header"), g = s("el-card");
3904
- return L(), T(g, {
3904
+ return C(), T(g, {
3905
3905
  class: "basic-card flex-full",
3906
3906
  "body-class": "flex-1"
3907
3907
  }, {
@@ -3979,7 +3979,7 @@ const Bl = /* @__PURE__ */ O({
3979
3979
  } = F(U);
3980
3980
  return (p, n) => {
3981
3981
  const v = s("el-date-picker"), u = s("el-space"), f = s("el-page-header"), g = s("el-card");
3982
- return L(), T(g, {
3982
+ return C(), T(g, {
3983
3983
  class: "basic-card flex-full",
3984
3984
  "body-class": "flex-1"
3985
3985
  }, {
@@ -4057,7 +4057,7 @@ const Bl = /* @__PURE__ */ O({
4057
4057
  } = F(U);
4058
4058
  return (p, n) => {
4059
4059
  const v = s("el-date-picker"), u = s("el-space"), f = s("el-page-header"), g = s("el-card");
4060
- return L(), T(g, {
4060
+ return C(), T(g, {
4061
4061
  class: "basic-card flex-full",
4062
4062
  "body-class": "flex-1"
4063
4063
  }, {
@@ -1 +1 @@
1
- (function(S,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("auto-vue-manual")):typeof define=="function"&&define.amd?define(["exports","vue","auto-vue-manual"],e):(S=typeof globalThis<"u"?globalThis:S||self,e(S.AutoVueBasic={},S.Vue,S["auto-vue-manual"]))})(this,(function(S,e,l){"use strict";const fe={tops:"tops",rules:"rules"},D=l.ApiUtils.routineApi("menu","id",fe,{},["TOP_MENU_LIST","MENU_LIST"]),W=l.ApiUtils.routineApi("rule","key");/*! Element Plus Icons Vue v2.3.2 */var ce=e.defineComponent({name:"Key",__name:"key",setup(x){return(k,C)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"M448 456.064V96a32 32 0 0 1 32-32.064L672 64a32 32 0 0 1 0 64H512v128h160a32 32 0 0 1 0 64H512v128a256 256 0 1 1-64 8.064M512 896a192 192 0 1 0 0-384 192 192 0 0 0 0 384"})]))}}),me=ce,_e=e.defineComponent({name:"Search",__name:"search",setup(x){return(k,C)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704"})]))}}),be=_e;const H=e.defineComponent({__name:"TopMenuSelect",props:{modelValue:{type:[Number,Array],required:!0},multiple:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(D),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"TOP_MENU_LIST",api:D,url:D.urls.tops,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),placeholder:e.unref(l.Translate)("placeholder.select"),filterable:"",filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(`icon iconfont ${c.icon}`)},null,2),e.createElementVNode("span",null,e.toDisplayString(c.translate),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","placeholder","filterOptions","onChange"])}}}),he=e.defineComponent({__name:"MenuFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,menu_id:0,module:"",sort:0,name:"",en_name:"",url:"",component:"",icon:"",remark:"",meta:{active:"",icon:"",title:"",affix:!1,full:!1,hide:!1,keep_alive:!1,link:!1}},m={sort:[{required:!0,type:"number",message:l.Translate("placeholder.input base.sort"),trigger:"blur"}],module:[{required:!0,message:l.Translate("placeholder.input menu.module"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}],url:[{required:!0,message:l.Translate("placeholder.input base.url"),trigger:"blur"}],component:[{required:!0,message:l.Translate("placeholder.input menu.component"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,D);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-col"),g=e.resolveComponent("el-input-number"),i=e.resolveComponent("el-row"),U=e.resolveComponent("el-input"),y=e.resolveComponent("el-switch"),A=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[17]||(r[17]=N=>e.isRef(p)?p.value=N:null),title:e.unref(d)(),width:"1000px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(A,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(i,{gutter:20},{default:e.withCtx(()=>[e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{gutter:10},{default:e.withCtx(()=>[e.createVNode(n,{span:14},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("base.parent"),prop:"menu_id"},{default:e.withCtx(()=>[e.createVNode(H,{modelValue:e.unref(t).menu_id,"onUpdate:modelValue":r[0]||(r[0]=N=>e.unref(t).menu_id=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:10},{default:e.withCtx(()=>[e.createVNode(o,{"label-width":"60px",label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(g,{class:"w-full",modelValue:e.unref(t).sort,"onUpdate:modelValue":r[1]||(r[1]=N=>e.unref(t).sort=N),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1}),e.createVNode(o,{label:e.unref(l.Translate)("menu.module"),prop:"module"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).module,"onUpdate:modelValue":r[2]||(r[2]=N=>e.unref(t).module=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[3]||(r[3]=N=>e.unref(t).name=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[4]||(r[4]=N=>e.unref(t).en_name=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("menu.component"),prop:"component"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).component,"onUpdate:modelValue":r[5]||(r[5]=N=>e.unref(t).component=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.url"),prop:"url"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).url,"onUpdate:modelValue":r[6]||(r[6]=N=>e.unref(t).url=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[7]||(r[7]=N=>e.unref(t).remark=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("base.icon"),prop:"icon"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).icon,"onUpdate:modelValue":r[8]||(r[8]=N=>e.unref(t).icon=N),placeholder:e.unref(l.Translate)("placeholder.input"),onInput:r[9]||(r[9]=N=>{e.unref(t).meta.icon=N})},{prepend:e.withCtx(()=>[e.createElementVNode("span",{class:e.normalizeClass("iconfont "+e.unref(t).icon)},null,2)]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.title"),prop:"meta.title"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).meta.title,"onUpdate:modelValue":r[10]||(r[10]=N=>e.unref(t).meta.title=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("menu.active"),prop:"meta.active"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).meta.active,"onUpdate:modelValue":r[11]||(r[11]=N=>e.unref(t).meta.active=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.link"),prop:"meta.link"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.link,"onUpdate:modelValue":r[12]||(r[12]=N=>e.unref(t).meta.link=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.keep_alive"),prop:"meta.keep_alive"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.keep_alive,"onUpdate:modelValue":r[13]||(r[13]=N=>e.unref(t).meta.keep_alive=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.hide"),prop:"meta.hide"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.hide,"onUpdate:modelValue":r[14]||(r[14]=N=>e.unref(t).meta.hide=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.full"),prop:"meta.full"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.full,"onUpdate:modelValue":r[15]||(r[15]=N=>e.unref(t).meta.full=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.affix"),prop:"meta.affix"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.affix,"onUpdate:modelValue":r[16]||(r[16]=N=>e.unref(t).meta.affix=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Q=e.defineComponent({__name:"MenuSelect",props:{modelValue:{type:[Number,Array],required:!0},multiple:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(D),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"MENU_LIST",api:D,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),placeholder:e.unref(l.Translate)("placeholder.select"),filterable:"",filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(`icon iconfont ${c.icon}`)},null,2),e.createElementVNode("span",null,e.toDisplayString(c.translate),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","placeholder","filterOptions","onChange"])}}}),ge=e.defineComponent({__name:"MenuRuleFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={key:"",menu_id:0,sort:0,name:"",en_name:"",urls:"",remark:""},m={menu_id:[{required:!0,type:"number",message:l.Translate("placeholder.select menu.Menu"),trigger:"blur"}],sort:[{required:!0,type:"number",message:l.Translate("placeholder.input base.sort"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}],urls:[{required:!0,message:l.Translate("placeholder.input menu.rules"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,W);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input-number"),g=e.resolveComponent("el-input"),i=e.resolveComponent("el-col"),U=e.resolveComponent("el-row"),y=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[6]||(r[6]=A=>e.isRef(p)?p.value=A:null),title:e.unref(d)("menu.rules"),width:"1000px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(y,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(U,{gutter:20},{default:e.withCtx(()=>[e.createVNode(i,{span:10},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.Menu"),prop:"menu_id"},{default:e.withCtx(()=>[e.createVNode(Q,{modelValue:e.unref(t).menu_id,"onUpdate:modelValue":r[0]||(r[0]=A=>e.unref(t).menu_id=A)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(n,{class:"w-full",modelValue:e.unref(t).sort,"onUpdate:modelValue":r[1]||(r[1]=A=>e.unref(t).sort=A),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[2]||(r[2]=A=>e.unref(t).name=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[3]||(r[3]=A=>e.unref(t).en_name=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[4]||(r[4]=A=>e.unref(t).remark=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(i,{span:14},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.rules"),prop:"urls"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).urls,"onUpdate:modelValue":r[5]||(r[5]=A=>e.unref(t).urls=A),type:"textarea",rows:11,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1})]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}});function J(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const X=e.defineComponent({__name:"index",setup(x){const k={keyword:"",status:0},C=e.ref(""),b=[{label:l.Translate("base.sort"),prop:"sort",width:60},{label:l.Translate("base.icon"),prop:"icon",width:60,render:({row:r})=>e.createVNode("span",{class:"iconfont "+r.icon,style:"font-size: 16px;"},null)},{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.parent"),prop:"parent",width:120,render:({row:r})=>{var o;return e.createVNode(e.Fragment,null,[(o=r.menu)==null?void 0:o.translate])}},{label:l.Translate("base.name"),prop:"translate",width:160},{label:l.Translate("base.url"),prop:"url",align:"left",width:200},{label:l.Translate("menu.component"),prop:"component",align:"left",width:200},{label:l.Translate("menu.rules"),prop:"rules",width:0,align:"left",render:({row:r})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>{var o;return[(o=r.rules)==null?void 0:o.map(n=>e.createVNode(e.resolveComponent("el-popover"),{visible:C.value===n.key,title:l.Translate("message.warning"),placement:"top-end",width:220},{reference:()=>e.createVNode(e.resolveComponent("el-tag"),{class:"cursor-pointer",closable:!0,key:n.key,onClick:()=>R({key:n.key}),onClose:()=>C.value=n.key},{default:()=>[n.translate]}),default:()=>{let g,i;return e.createVNode("div",null,[e.createVNode("p",null,null),e.createVNode("p",null,[`${l.Translate("base.confirm base.space base.delete base.space menu.rules")}: ${r.translate}-${n.translate} ?`]),e.createVNode("div",{style:"text-align: right; margin: 0"},[e.createVNode(e.resolveComponent("el-button"),{size:"small",text:!0,onClick:()=>C.value=""},J(g=l.Translate("base.cancel"))?g:{default:()=>[g]}),e.createVNode(e.resolveComponent("el-button"),{size:"small",type:"danger",onClick:()=>T(n.key)},J(i=l.Translate("base.confirm"))?i:{default:()=>[i]})])])}}))]}})},{label:l.Translate("base.status"),prop:"status",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:D.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{prop:"action",label:l.Translate("base.action"),width:60,align:"center",render:({row:r})=>e.createVNode(l.ModifyButton,{size:"default",onModify:()=>f({id:r.id})},null)}],{requesting:h}=l.useLoading(D),{tableRef:m,formModalRef:p,keyword:d,search:s,refresh:t,reset:w,openFormModal:a,editFormModal:f}=l.useCrudPage(k),{formModalRef:_,openFormModal:c,editFormModal:R}=l.useCrudPage(),T=r=>{W[l.DEFAULT_REMOVE_KEY]({key:r}).then(()=>{C.value="",t()})};return(r,o)=>{const n=e.resolveComponent("el-button"),g=e.resolveComponent("el-input"),i=e.resolveComponent("el-radio-button"),U=e.resolveComponent("el-radio-group"),y=e.resolveComponent("el-space"),A=e.resolveComponent("el-page-header"),N=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(N,{class:"basic-card flex-full","body-class":"flex-1",onClick:o[5]||(o[5]=()=>C.value="")},{header:e.withCtx(()=>[e.createVNode(A,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(h),onRefresh:e.unref(w)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(a)},null,8,["onOpen"]),e.createVNode(n,{circle:"",icon:e.unref(me),onClick:e.unref(c)},null,8,["icon","onClick"])]),content:e.withCtx(()=>[e.createVNode(y,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(g,{class:"basic-search-input",modelValue:e.unref(d).keyword,"onUpdate:modelValue":o[0]||(o[0]=B=>e.unref(d).keyword=B),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:o[1]||(o[1]=e.withKeys(B=>e.unref(s)(),["enter"])),onClear:o[2]||(o[2]=B=>e.unref(s)())},null,8,["modelValue","placeholder"]),e.createVNode(U,{modelValue:e.unref(d).status,"onUpdate:modelValue":o[3]||(o[3]=B=>e.unref(d).status=B),onChange:o[4]||(o[4]=B=>e.unref(s)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],B=>e.createVNode(i,{key:B,label:e.unref(l.Translate)(`status.${B}`),value:B},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(h),onSearch:e.unref(s)},null,8,["disabled","onSearch"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:m,size:"small",columns:b,url:e.unref(D).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(d),"auto-search":""},null,8,["url","search-param"]),e.createVNode(he,{ref_key:"formModalRef",ref:p,onRefresh:e.unref(t)},null,8,["onRefresh"]),e.createVNode(ge,{ref_key:"ruleFormModalRef",ref:_,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),Ce=Object.freeze(Object.defineProperty({__proto__:null,default:X},Symbol.toStringTag,{value:"Module"})),j=l.ApiUtils.routineApi("role","key"),we={class:"rule-check"},Te={style:{width:"80px","line-height":"36px"}},xe=e.defineComponent({__name:"RulesCheck",props:{modelValue:{type:Array,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(x,{expose:k,emit:C}){const{requesting:b}=l.useLoading(D),h=x,m=C,p=e.ref(!1),d=e.reactive({checkAll:!1,indeterminate:!1,MenuAll:{},MenuList:{},MenuIndeterminate:{}}),{options:s,refresh:t}=l.useSelect(e.toRef(h,"modelValue"),m,{key:"RULE_CHECK",api:D,url:D.urls.rules,isArray:!0},{autoRefresh:!1});function w(){s.value.forEach(T=>{var r;(r=T.rules)!=null&&r.length&&(d.MenuAll[T.id]=!1,d.MenuIndeterminate[T.id]=!1,d.MenuList[T.id]=[])})}function a(T){s.value.forEach(r=>{var o;(o=r.rules)!=null&&o.length&&(d.MenuList[r.id]=T?r.rules.map(n=>n.key):[])}),_()}function f(T,r){const o=s.value.find(n=>n.id===r);d.MenuList[r]=T&&o?o.rules.map(n=>n.key):[],_()}function _(){s.value.forEach(T=>{var n,g;const r=((n=T.rules)==null?void 0:n.length)||0,o=((g=d.MenuList[T.id])==null?void 0:g.length)||0;d.MenuAll[T.id]=o===r&&r>0,d.MenuIndeterminate[T.id]=o>0&&o<r}),d.checkAll=Object.values(d.MenuAll).every(Boolean),d.indeterminate=!d.checkAll&&Object.values(d.MenuList).some(T=>T.length>0),m("update:modelValue",Object.values(d.MenuList).flat())}function c(){d.checkAll=!1,d.indeterminate=!1,d.MenuAll={},d.MenuList={},d.MenuIndeterminate={},w(),m("update:modelValue",[]),p.value=!1}function R(T){var r;if(Array.isArray(s.value)&&s.value.length>0){for(let o of s.value)if(Array.isArray(o.rules)&&o.rules.length>0)for(let n of o.rules)T.some(g=>g===n.key)&&(d.MenuList[o.id]=(((r=d.MenuList)==null?void 0:r[o.id])||[]).concat([n.key]));_(),p.value=!0}}return e.onMounted(async()=>{var T;(T=s.value)!=null&&T.length||await t(),!p.value&&h.modelValue&&R(h.modelValue)}),e.watch(()=>h.modelValue,T=>{e.nextTick(()=>{var r;p.value||!((r=s.value)!=null&&r.length)||T&&T.length>0&&R(T)})},{deep:!0,immediate:!0}),k({generateOption:R,cleanChecked:c}),(T,r)=>{const o=e.resolveComponent("el-checkbox"),n=e.resolveComponent("el-space"),g=e.resolveComponent("el-text"),i=e.resolveComponent("el-divider"),U=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",we,[e.createVNode(n,{style:{"margin-bottom":"6px"}},{default:e.withCtx(()=>[e.createVNode(o,{"model-value":d.checkAll,indeterminate:d.indeterminate,id:"all",disabled:x.disabled,onChange:a},{default:e.withCtx(()=>[...r[1]||(r[1]=[e.createElementVNode("span",null,"全选",-1)])]),_:1},8,["model-value","indeterminate","disabled"]),e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),text:"",size:"small",onRefresh:r[0]||(r[0]=y=>e.unref(t)(!0))},null,8,["loading"])]),_:1}),e.createVNode(n,{direction:"vertical",alignment:"start",class:"rule-check-content"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(s),y=>(e.openBlock(),e.createElementBlock("div",{key:y.id},[e.createVNode(n,{direction:"horizontal",size:2},{default:e.withCtx(()=>[e.createVNode(o,{style:{"min-width":"150px"},"model-value":d.MenuAll[y.id],disabled:x.disabled||!y.rules||y.rules.length<=0,indeterminate:d.MenuIndeterminate[y.id],onChange:A=>f(A,y.id)},{default:e.withCtx(()=>[e.createVNode(g,{style:{"font-size":"15px"}},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(y.translate),1)]),_:2},1024)]),_:2},1032,["model-value","disabled","indeterminate","onChange"]),e.createVNode(i,{direction:"vertical"}),y.rules?(e.openBlock(),e.createBlock(U,{key:0,modelValue:d.MenuList[y.id],"onUpdate:modelValue":A=>d.MenuList[y.id]=A,disabled:x.disabled,style:{margin:"auto"},onChange:_},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.rules,A=>(e.openBlock(),e.createBlock(o,{key:A.key,value:A.key},{default:e.withCtx(()=>[e.createElementVNode("div",Te,e.toDisplayString(A.translate),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"])):e.createCommentVNode("",!0)]),_:2},1024)]))),128))]),_:1})])}}}),Z=(x,k)=>{const C=x.__vccOpts||x;for(const[b,h]of k)C[b]=h;return C},Ne=Z(xe,[["__scopeId","data-v-7adb5f76"]]),ke=e.defineComponent({__name:"RoleFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h=e.ref(),m={key:"",module:"",sort:0,name:"",en_name:"",remark:"",rules:[]},p={name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}]},{modal:d,title:s,form:t,formData:w,requesting:a,executing:f,open:_,modify:c,submit:R,closed:T}=l.useForm(b,m,j),r=()=>{var o;(o=h.value)==null||o.cleanChecked(),T()};return k({open:_,modify:c}),(o,n)=>{const g=e.resolveComponent("el-input"),i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-col"),y=e.resolveComponent("el-input-number"),A=e.resolveComponent("el-row"),N=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(d),"onUpdate:modelValue":n[6]||(n[6]=B=>e.isRef(d)?d.value=B:null),title:e.unref(s)(),width:"1000px",executing:e.unref(f),onClosed:r,onSubmit:e.unref(R)},{default:e.withCtx(()=>[e.createVNode(N,{ref_key:"form",ref:t,model:e.unref(w),"label-width":"auto",rules:p,disabled:e.unref(a)||e.unref(f)},{default:e.withCtx(()=>[e.createVNode(A,{gutter:20},{default:e.withCtx(()=>[e.createVNode(U,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.module"),prop:"module"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).module,"onUpdate:modelValue":n[0]||(n[0]=B=>e.unref(w).module=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(U,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(y,{class:"w-full",modelValue:e.unref(w).sort,"onUpdate:modelValue":n[1]||(n[1]=B=>e.unref(w).sort=B),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1}),e.createVNode(i,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).name,"onUpdate:modelValue":n[2]||(n[2]=B=>e.unref(w).name=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).en_name,"onUpdate:modelValue":n[3]||(n[3]=B=>e.unref(w).en_name=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).remark,"onUpdate:modelValue":n[4]||(n[4]=B=>e.unref(w).remark=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("menu.rules"),prop:"rules"},{default:e.withCtx(()=>[e.createVNode(Ne,{ref_key:"rulesCheck",ref:h,modelValue:e.unref(w).rules,"onUpdate:modelValue":n[5]||(n[5]=B=>e.unref(w).rules=B),disabled:e.unref(a)||e.unref(f)},null,8,["modelValue","disabled"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onSubmit"])}}}),u=e.defineComponent({__name:"index",setup(x){const k={keyword:""},C=[{label:l.Translate("base.sort"),prop:"sort",width:80},{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.name"),prop:"translate",width:120},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("time.created_at"),prop:"created_at",width:180},{prop:"action",label:l.Translate("base.action"),width:65,align:"center",render:({row:f})=>e.createVNode(l.ModifyButton,{size:"default",onModify:()=>a({key:f.key})},null)}],{requesting:b}=l.useLoading(j),{tableRef:h,formModalRef:m,keyword:p,search:d,reset:s,refresh:t,openFormModal:w,editFormModal:a}=l.useCrudPage(k);return(f,_)=>{const c=e.resolveComponent("el-input"),R=e.resolveComponent("el-space"),T=e.resolveComponent("el-page-header"),r=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(r,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(T,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(s)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(w)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(R,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(c,{class:"basic-search-input",modelValue:e.unref(p).keyword,"onUpdate:modelValue":_[0]||(_[0]=o=>e.unref(p).keyword=o),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:_[1]||(_[1]=e.withKeys(o=>e.unref(d)(),["enter"])),onClear:_[2]||(_[2]=o=>e.unref(d)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:_[3]||(_[3]=o=>e.unref(d)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:h,columns:C,url:e.unref(j).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(p),"auto-search":""},null,8,["url","search-param"]),e.createVNode(ke,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),ye=Object.freeze(Object.defineProperty({__proto__:null,default:u},Symbol.toStringTag,{value:"Module"})),L=l.ApiUtils.routineApi("I18N","uuid",{modules:"modules",languages:"languages"},{gen:"gen"},["I18N_MODULES"]),O=l.ApiUtils.routineApi("I18N_template","uuid",{apps:"apps"}),M=e.defineComponent({__name:"ModuleSelect",props:{modelValue:{type:String,default:void 0,required:!1},multiple:{type:Boolean,default:!1},"allow-create":{type:Boolean,default:!1},clearable:{type:Boolean,default:!1}},emits:["update:modelValue","update:value","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(L),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"I18N_MODULES",url:L.urls.modules,api:L,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),clearable:x.clearable,filterable:"","allow-create":w.allow-w.create,"default-first-option":"",placeholder:e.unref(l.Translate)("placeholder.select"),filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(c.value),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","clearable","allow-create","placeholder","filterOptions","onChange"])}}}),Re=e.defineComponent({__name:"I18N",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={uuid:"",key:"",module:"",language:{"zh-CN":"","en-US":""},remark:""},m={module:[{required:!0,message:l.Translate("language.placeholder.module"),trigger:"blur"}],key:[{required:!0,message:l.Translate("language.placeholder.key"),trigger:"blur"}],language:[{required:!0,message:l.Translate("language.placeholder.language"),trigger:"change"}],result:[{required:!0,message:l.Translate("language.placeholder.result"),trigger:"blur"}]},p=e.ref([]),d=l.useCacheStore();function s(){const n={isArray:!0,key:"I18N_LANGUAGES",url:L.urls.languages,params:{}};d.GET_CACHE({...n,force:!0}).then(g=>{p.value=g})}s();const{modal:t,title:w,form:a,formData:f,requesting:_,executing:c,open:R,modify:T,submit:r,closed:o}=l.useForm(b,h,L);return k({open:R,modify:T}),(n,g)=>{const i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-input"),y=e.resolveComponent("el-space"),A=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(t),"onUpdate:modelValue":g[3]||(g[3]=N=>e.isRef(t)?t.value=N:null),title:e.unref(w)(),width:"600px",executing:e.unref(c),onClosed:e.unref(o),onSubmit:e.unref(r)},{default:e.withCtx(()=>[e.createVNode(A,{ref_key:"form",ref:a,model:e.unref(f),"label-width":"auto",rules:m,disabled:e.unref(_)||e.unref(c)},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("i18n.module"),prop:"module",required:""},{default:e.withCtx(()=>[e.createVNode(M,{modelValue:e.unref(f).module,"onUpdate:modelValue":g[0]||(g[0]=N=>e.unref(f).module=N),"allow-create":""},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("i18n.key"),prop:"key",required:""},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(f).key,"onUpdate:modelValue":g[1]||(g[1]=N=>e.unref(f).key=N),placeholder:e.unref(l.Translate)("language.placeholder.key")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("i18n.language"),prop:"language",required:""},{default:e.withCtx(()=>[e.createVNode(y,{direction:"vertical",fill:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,N=>(e.openBlock(),e.createElementBlock("div",{key:N},[e.createVNode(U,{modelValue:e.unref(f).language[N],"onUpdate:modelValue":B=>e.unref(f).language[N]=B,placeholder:e.unref(l.Translate)("i18n.placeholder.key")},{prepend:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(N),1)]),_:2},1032,["modelValue","onUpdate:modelValue","placeholder"])]))),128))]),_:1})]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(f).remark,"onUpdate:modelValue":g[2]||(g[2]=N=>e.unref(f).remark=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}});function Ve(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const v=e.defineComponent({__name:"I18N",emits:["closed","choosed"],setup(x,{expose:k,emit:C}){const b=e.ref(!1),h=C,m={keyword:"",module:void 0,status:0},p=[{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.key"),prop:"key",width:200},{label:l.Translate("base.i18n"),align:"left",prop:"language",render:({row:g})=>{const U=Object.keys(g.language).filter(y=>!!g.language[y]).map(y=>`${y}: ${g.language[y]}`).join("; ");return e.createVNode(e.resolveComponent("el-space"),null,Ve(U)?U:{default:()=>[U]})}},{label:l.Translate("base.status"),prop:"checked",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:L.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{prop:"action",label:l.Translate("base.action"),width:120,align:"center",render:({row:g})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",onModify:()=>T({uuid:g.uuid})},null),e.createVNode(l.RequestButton,{size:"default",text:!0,type:"danger",loading:s.value,onClick:()=>r(g.uuid)},null)]})}],{requesting:d,executing:s}=l.useLoading(L),{tableRef:t,formModalRef:w,keyword:a,search:f,reset:_,refresh:c,openFormModal:R,editFormModal:T}=l.useCrudPage(m);function r(g){return L.remove({uuid:g}).finally(()=>{c()})}const o=()=>{b.value=!0};function n(g){h("choosed",g),b.value=!1}return e.watch(()=>b.value,g=>{g||h("closed")}),k({open:o}),(g,i)=>{const U=e.resolveComponent("el-input"),y=e.resolveComponent("el-radio-button"),A=e.resolveComponent("el-radio-group"),N=e.resolveComponent("el-space"),B=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":i[7]||(i[7]=V=>b.value=V),width:"880px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(B,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(d),onRefresh:e.unref(_)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(R)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(N,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(U,{style:{width:"160px"},modelValue:e.unref(a).keyword,"onUpdate:modelValue":i[0]||(i[0]=V=>e.unref(a).keyword=V),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:i[1]||(i[1]=e.withKeys(V=>e.unref(f)(),["enter"])),onClear:i[2]||(i[2]=V=>e.unref(f)())},null,8,["modelValue","placeholder"]),e.createVNode(M,{modelValue:e.unref(a).module,"onUpdate:modelValue":i[3]||(i[3]=V=>e.unref(a).module=V),clearable:!0,style:{width:"160px"}},null,8,["modelValue"]),e.createVNode(A,{modelValue:e.unref(a).status,"onUpdate:modelValue":i[4]||(i[4]=V=>e.unref(a).status=V),onChange:i[5]||(i[5]=V=>e.unref(f)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],V=>e.createVNode(y,{key:V,label:e.unref(l.Translate)(`status.${V}`),value:V},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(d),onSearch:i[6]||(i[6]=V=>e.unref(f)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:t,columns:p,url:e.unref(L).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(a),onRowDblclick:n,"auto-search":""},null,8,["url","search-param"]),e.createVNode(Re,{ref_key:"formModalRef",ref:w,onRefresh:e.unref(c)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),Ue=e.defineComponent({__name:"template",emits:["refresh"],setup(x,{expose:k,emit:C}){const{formModalRef:b,openFormModal:h}=l.useCrudPage(),m=C,p=e.ref("600px"),d=e.ref({"zh-CN":"primary","en-US":"success"}),s=e.ref({}),t={uuid:"",app:1,keys:"",values:[],remark:""},w={app:[{required:!0,message:l.Translate("i18n.placeholder.app"),trigger:"blur"}],keys:[{required:!0,message:l.Translate("i18n.placeholder.keys"),trigger:"blur"}],values:[{required:!0,message:l.Translate("i18n.placeholder.values"),trigger:"change"}]},{modal:a,title:f,form:_,formData:c,requesting:R,executing:T,open:r,modify:o,submit:n,closed:g}=l.useForm(m,t,O);function i(){p.value="1080px",h()}function U(){p.value="600px"}function y(N){let B=N.module.toLowerCase()+"."+N.key.toLowerCase();c.keys=B,c.values.push(B);for(const V in N.language)s.value[V]||(s.value[V]=[]),s.value[V].push(N.language[V])}function A(){p.value="600px",s.value={"zh-CN":[],"en-US":[]}}return e.watch(()=>a.value,N=>{N?A():g()}),k({open:r,modify:o}),(N,B)=>{const V=e.resolveComponent("el-page-header"),I=e.resolveComponent("el-form-item"),ve=e.resolveComponent("el-button"),pe=e.resolveComponent("el-input"),el=e.resolveComponent("el-tag"),ll=e.resolveComponent("el-space"),rl=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:e.unref(a),"onUpdate:modelValue":B[3]||(B[3]=E=>e.isRef(a)?a.value=E:null),width:p.value,"show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(V,{class:"basic-header"},{title:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(f)("i18n.template")),1)]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{circle:!1,size:"default",type:"primary",icon:"icon-save",plain:!1,loading:e.unref(T),onClick:e.unref(n)},null,8,["loading","onClick"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(rl,{ref_key:"form",ref:_,model:e.unref(c),"label-width":"auto",rules:w,disabled:e.unref(R)||e.unref(T)},{default:e.withCtx(()=>[e.createVNode(I,{label:e.unref(l.Translate)("i18n.app"),prop:"app",required:""},{default:e.withCtx(()=>[e.createVNode(e.unref(l.BasicRadioButton),{modelValue:e.unref(c).app,"onUpdate:modelValue":B[0]||(B[0]=E=>e.unref(c).app=E),"cache-key":"I18NAPPS",hidden:[0],url:e.unref(O).urls.apps},null,8,["modelValue","url"])]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.keys"),prop:"keys",required:""},{default:e.withCtx(()=>[e.createVNode(pe,{modelValue:e.unref(c).keys,"onUpdate:modelValue":B[1]||(B[1]=E=>e.unref(c).keys=E),placeholder:e.unref(l.Translate)("i18n.placeholder.key")},{append:e.withCtx(()=>[e.createVNode(ve,{icon:e.unref(be),onClick:i},null,8,["icon"])]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.values"),prop:"values",required:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(c).values.join(":")),1)]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.values")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(E,G)=>(e.openBlock(),e.createElementBlock("div",{key:G,class:"w-full"},[e.createVNode(ll,null,{default:e.withCtx(()=>[e.createVNode(el,{type:d.value[G],style:{"min-width":"80px"}},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(G),1)]),_:2},1032,["type"]),e.createElementVNode("span",null,e.toDisplayString(E.join("")),1)]),_:2},1024)]))),128))]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(pe,{modelValue:e.unref(c).remark,"onUpdate:modelValue":B[2]||(B[2]=E=>e.unref(c).remark=E),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"]),e.createVNode(v,{ref_key:"I18nTableDrawerRef",ref:b,onChoosed:y,onClosed:U},null,512)]),_:1},8,["modelValue","width"])}}}),Be=l.ApiUtils.routineApi("gateway","id",{gen:"gen_translation"});function Ae(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const ee=e.defineComponent({__name:"index",setup(x){const k={keyword:"",app:0,status:0},C=[{label:l.Translate("base.app"),prop:"app",width:120,render:({row:o})=>{let n;return e.createVNode(e.resolveComponent("el-tag"),{type:l.Translate("i18n.app.colors."+o.app),style:"min-width: 80px"},Ae(n=l.Translate("i18n.app."+o.app))?n:{default:()=>[n]})}},{label:l.Translate("i18n.keys"),prop:"keys",width:200},{label:l.Translate("i18n.values"),prop:"values",width:200},{label:l.Translate("base.status"),prop:"checked",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:O.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("time.created_at"),prop:"created_at",width:160},{label:l.Translate("time.updated_at"),prop:"updated_at",width:160},{prop:"action",label:l.Translate("base.action"),width:120,align:"center",render:({row:o})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",disabled:h.value,onModify:()=>c({uuid:o.uuid})},null),e.createVNode(l.RequestButton,{size:"default",text:!0,type:"danger",loading:h.value,onClick:()=>R(o.uuid)},null)]})}],{requesting:b,executing:h}=l.useLoading(O),{formModalRef:m,openFormModal:p}=l.useCrudPage(),{tableRef:d,formModalRef:s,keyword:t,search:w,reset:a,refresh:f,openFormModal:_,editFormModal:c}=l.useCrudPage(k);function R(o){return O.remove({uuid:o}).finally(()=>{f()})}function T(){return L.gen().finally(()=>{f()})}function r(){Be.gen().finally(()=>{f()})}return(o,n)=>{const g=e.resolveComponent("el-divider"),i=e.resolveComponent("el-input"),U=e.resolveComponent("el-radio-button"),y=e.resolveComponent("el-radio-group"),A=e.resolveComponent("el-space"),N=e.resolveComponent("el-page-header"),B=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(B,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(N,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(a)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_)},null,8,["onOpen"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{size:"default",type:"warning",icon:"icon-cloud-upload",plain:!1,loading:e.unref(h),onClick:T},null,8,["loading"]),e.createVNode(e.unref(l.RequestButton),{size:"default",type:"danger",icon:"icon-translate",plain:!1,loading:e.unref(h),onClick:r},null,8,["loading"]),e.createVNode(g,{direction:"vertical"}),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(p),icon:"icon-en-US"},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(A,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(i,{class:"basic-search-input",modelValue:e.unref(t).keyword,"onUpdate:modelValue":n[0]||(n[0]=V=>e.unref(t).keyword=V),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:n[1]||(n[1]=e.withKeys(V=>e.unref(w)(),["enter"])),onClear:n[2]||(n[2]=V=>e.unref(w)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.BasicRadioButton),{modelValue:e.unref(t).app,"onUpdate:modelValue":n[3]||(n[3]=V=>e.unref(t).app=V),"cache-key":"I18NAPPS",url:e.unref(O).urls.apps,onChange:n[4]||(n[4]=V=>e.unref(w)())},null,8,["modelValue","url"]),e.createVNode(y,{modelValue:e.unref(t).status,"onUpdate:modelValue":n[5]||(n[5]=V=>e.unref(t).status=V),onChange:n[6]||(n[6]=V=>e.unref(w)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],V=>e.createVNode(U,{key:V,label:e.unref(l.Translate)(`status.${V}`),value:V},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:n[7]||(n[7]=V=>e.unref(w)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:d,columns:C,url:e.unref(O).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(t),"auto-search":""},null,8,["url","search-param"]),e.createVNode(v,{ref_key:"I18nTableDrawerRef",ref:m,onRefresh:e.unref(f)},null,8,["onRefresh"]),e.createVNode(Ue,{ref_key:"formModalRef",ref:s,onRefresh:e.unref(f)},null,8,["onRefresh"])]),_:1})}}}),Se=Object.freeze(Object.defineProperty({__proto__:null,default:ee},Symbol.toStringTag,{value:"Module"})),K=l.ApiUtils.routineApi("admin","key"),De=e.defineComponent({__name:"AdminFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={key:"",username:"",password:"",phone:"",email:"",language:"zh-CN",remark:"",roles:[]},{modal:m,title:p,form:d,formData:s,requesting:t,executing:w,open:a,modify:f,submit:_,closed:c}=l.useForm(b,h,K),R={username:[{required:!0,message:l.Translate("placeholder.input base.username"),trigger:"blur"}],phone:[{required:!0,validator:l.RulesUtils.phoneRule,message:l.Translate("placeholder.input base.phone"),trigger:"blur"}],password:[{required:!1,message:l.Translate("placeholder.input base.password"),trigger:"blur"}],email:[{required:!0,message:l.Translate("placeholder.input base.email"),trigger:"blur"}],language:[{required:!0,message:l.Translate("placeholder.select base.language"),trigger:"change"}],roles:[{required:!0,type:"Array",message:l.Translate("placeholder.select menu.Role"),trigger:"change"}]},T=e.ref([]),r=async()=>{const o=await j.list();T.value=Array.isArray(o==null?void 0:o.data)?o.data:[]};return e.onBeforeMount(async()=>{await r()}),k({open:a,modify:f}),(o,n)=>{const g=e.resolveComponent("el-input"),i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-radio-button"),y=e.resolveComponent("el-radio-group"),A=e.resolveComponent("el-checkbox"),N=e.resolveComponent("el-checkbox-group"),B=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(m),"onUpdate:modelValue":n[7]||(n[7]=V=>e.isRef(m)?m.value=V:null),title:e.unref(p)(),width:"600px",executing:e.unref(w),onClosed:e.unref(c),onSubmit:e.unref(_)},{default:e.withCtx(()=>[e.createVNode(B,{ref_key:"form",ref:d,model:e.unref(s),"label-width":"auto",rules:R,disabled:e.unref(t)||e.unref(w)},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.username"),prop:"username"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).username,"onUpdate:modelValue":n[0]||(n[0]=V=>e.unref(s).username=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.phone"),prop:"phone"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).phone,"onUpdate:modelValue":n[1]||(n[1]=V=>e.unref(s).phone=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.password"),prop:"password",required:!e.unref(s).key},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).password,"onUpdate:modelValue":n[2]||(n[2]=V=>e.unref(s).password=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label","required"]),e.createVNode(i,{label:e.unref(l.Translate)("base.email"),prop:"email"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).email,"onUpdate:modelValue":n[3]||(n[3]=V=>e.unref(s).email=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.language"),prop:"language"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(s).language,"onUpdate:modelValue":n[4]||(n[4]=V=>e.unref(s).language=V)},{default:e.withCtx(()=>[e.createVNode(U,{value:"zh-CN"},{default:e.withCtx(()=>[...n[8]||(n[8]=[e.createTextVNode("zh-CN",-1)])]),_:1}),e.createVNode(U,{value:"en-US"},{default:e.withCtx(()=>[...n[9]||(n[9]=[e.createTextVNode("en-US",-1)])]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("menu.Role"),prop:"roles"},{default:e.withCtx(()=>[e.createVNode(N,{modelValue:e.unref(s).roles,"onUpdate:modelValue":n[5]||(n[5]=V=>e.unref(s).roles=V)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.value,V=>(e.openBlock(),e.createBlock(A,{key:V.key,value:V.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(V.translate),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).remark,"onUpdate:modelValue":n[6]||(n[6]=V=>e.unref(s).remark=V),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),le=e.defineComponent({__name:"index",setup(x){const k={keyword:""},C=[{label:l.Translate("base.avatar"),prop:"avatar",width:60,render:({row:f})=>e.createVNode(l.BasicAvatar,{src:f.avatar},null)},{label:l.Translate("base.user"),width:200,align:"left",render:({row:f})=>e.createVNode(e.resolveComponent("el-space"),{direction:"vertical",alignment:"start"},{default:()=>[e.createVNode("div",null,[f.username]),e.createVNode("div",null,[f.email])]})},{label:l.Translate("base.phone"),prop:"phone",width:140},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("base.login_at"),prop:"login_at",width:160},{label:l.Translate("time.created_at"),prop:"created_at",width:160},{label:l.Translate("time.updated_at"),prop:"updated_at",width:160},{prop:"action",label:l.Translate("base.action"),width:80,align:"center",render:({row:f})=>e.createVNode(l.ModifyButton,{onModify:()=>a({key:f.key})},null)}],{requesting:b}=l.useLoading(K),{tableRef:h,formModalRef:m,keyword:p,search:d,reset:s,refresh:t,openFormModal:w,editFormModal:a}=l.useCrudPage(k);return(f,_)=>{const c=e.resolveComponent("el-input"),R=e.resolveComponent("el-space"),T=e.resolveComponent("el-page-header"),r=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(r,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(T,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(s)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(w)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(R,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(c,{class:"basic-search-input",modelValue:e.unref(p).keyword,"onUpdate:modelValue":_[0]||(_[0]=o=>e.unref(p).keyword=o),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:_[1]||(_[1]=e.withKeys(o=>e.unref(d)(),["enter"])),onClear:_[2]||(_[2]=o=>e.unref(d)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:_[3]||(_[3]=o=>e.unref(d)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref(K).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(p),"auto-search":""},null,8,["url","search-param"]),e.createVNode(De,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),Le=Object.freeze(Object.defineProperty({__proto__:null,default:le},Symbol.toStringTag,{value:"Module"})),Ee={check:"check"},q=l.ApiUtils.routineApi("site","id",Ee),P=l.ApiUtils.routineApi("domain"),Y=e.defineComponent({__name:"DomainSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(P),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"DOMAIN_LIST",api:P,isArray:!0});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),Oe=e.defineComponent({__name:"SiteFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,domain_id:0,prefix:"",name:"",en_name:"",dns:"",git:"",status:1,remark:""},m={domain_id:[{required:!0,message:l.Translate("placeholder.input config.domain"),trigger:"blur"}],prefix:[{required:!0,message:l.Translate("placeholder.input base.prefix"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,q);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input"),g=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[7]||(r[7]=i=>e.isRef(p)?p.value=i:null),title:e.unref(d)("config.site"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(g,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"domain_id",label:e.unref(l.Translate)("config.domain")},{default:e.withCtx(()=>[e.createVNode(Y,{modelValue:e.unref(t).domain_id,"onUpdate:modelValue":r[0]||(r[0]=i=>e.unref(t).domain_id=i),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"prefix",label:e.unref(l.Translate)("config.prefix")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).prefix,"onUpdate:modelValue":r[1]||(r[1]=i=>e.unref(t).prefix=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[2]||(r[2]=i=>e.unref(t).name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"en_name",label:e.unref(l.Translate)("base.en_name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[3]||(r[3]=i=>e.unref(t).en_name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"dns",label:e.unref(l.Translate)("config.dns")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).dns,"onUpdate:modelValue":r[4]||(r[4]=i=>e.unref(t).dns=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"git",label:e.unref(l.Translate)("config.git")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).git,"onUpdate:modelValue":r[5]||(r[5]=i=>e.unref(t).git=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[6]||(r[6]=i=>e.unref(t).remark=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),z=l.ApiUtils.routineApi("domain_provider"),re=e.defineComponent({__name:"DomainProviderSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(z),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"DOMAIN_PROVIDER_LIST",api:z,isArray:!0});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain config.provider"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),qe=e.defineComponent({__name:"DomainFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,provider_id:0,name:"",expired_at:"",status:1,remark:""},m={provider_id:[{required:!0,message:l.Translate("placeholder.input config.domain config.provider"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,P);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input"),g=e.resolveComponent("el-date-picker"),i=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[4]||(r[4]=U=>e.isRef(p)?p.value=U:null),title:e.unref(d)("config.domain"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(i,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"provider_id",label:e.unref(l.Translate)("config.provider")},{default:e.withCtx(()=>[e.createVNode(re,{modelValue:e.unref(t).provider_id,"onUpdate:modelValue":r[0]||(r[0]=U=>e.unref(t).provider_id=U),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[1]||(r[1]=U=>e.unref(t).name=U),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"expired_at",required:"",label:e.unref(l.Translate)("time.expired_at")},{default:e.withCtx(()=>[e.createVNode(g,{type:"date",style:{width:"100%"},modelValue:e.unref(t).expired_at,"onUpdate:modelValue":r[2]||(r[2]=U=>e.unref(t).expired_at=U),disabled:e.unref(a),"value-format":e.unref(l.TimeUtils).DATE_VALUE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,placeholder:e.unref(l.Translate)("placeholder.select")},null,8,["modelValue","disabled","value-format","format","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[3]||(r[3]=U=>e.unref(t).remark=U),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Fe={gen:"gen"},F=l.ApiUtils.routineApi("SSL","id",Fe),te=e.defineComponent({__name:"SiteSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(q),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"SITE_LIST",api:q,isArray:!0},{formatOptions:w=>w.map(a=>{var f;return{...a,label:a.prefix+"."+((f=a.domain)==null?void 0:f.name),value:a.id}})});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),ne=e.defineComponent({__name:"SSLFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,domain_id:void 0,client:"Lego",site_id:void 0,name:"",path:"",email:"",encryption:"RSA2048",remark:""},m={domain_id:[{required:!0,message:l.Translate("placeholder.select config.domain "),trigger:"blur"}],client:[{required:!0,message:l.Translate("placeholder.select config.client "),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],path:[{required:!0,message:l.Translate("placeholder.input base.path"),trigger:"blur"}],email:[{required:!0,message:l.Translate("placeholder.input base.email"),trigger:"blur"}],encryption:[{required:!0,message:l.Translate("placeholder.input config.encryption"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,F);return k({open:f,modify:_,formData:t}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-radio-button"),g=e.resolveComponent("el-radio-group"),i=e.resolveComponent("el-input"),U=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[8]||(r[8]=y=>e.isRef(p)?p.value=y:null),title:e.unref(d)("ssl.ssl"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(U,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"domain_id",label:e.unref(l.Translate)("config.domain")},{default:e.withCtx(()=>[e.createVNode(Y,{modelValue:e.unref(t).domain_id,"onUpdate:modelValue":r[0]||(r[0]=y=>e.unref(t).domain_id=y),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"client",label:e.unref(l.Translate)("ssl.client")},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).client,"onUpdate:modelValue":r[1]||(r[1]=y=>e.unref(t).client=y)},{default:e.withCtx(()=>[e.createVNode(n,{label:"Lego",value:"Lego"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{prop:"site_id",label:e.unref(l.Translate)("config.site")},{default:e.withCtx(()=>[e.createVNode(te,{modelValue:e.unref(t).site_id,"onUpdate:modelValue":r[2]||(r[2]=y=>e.unref(t).site_id=y),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[3]||(r[3]=y=>e.unref(t).name=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"path",label:e.unref(l.Translate)("base.path")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).path,"onUpdate:modelValue":r[4]||(r[4]=y=>e.unref(t).path=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"email",label:e.unref(l.Translate)("base.email")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).email,"onUpdate:modelValue":r[5]||(r[5]=y=>e.unref(t).email=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"encryption",label:e.unref(l.Translate)("config.encryption")},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).encryption,"onUpdate:modelValue":r[6]||(r[6]=y=>e.unref(t).encryption=y)},{default:e.withCtx(()=>[e.createVNode(n,{label:"RSA2048",value:"RSA2048"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[7]||(r[7]=y=>e.unref(t).remark=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),$e=e.defineComponent({__name:"DomainProviderFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,name:"",en_name:"",key:"",secret:"",end_point:"",status:1,remark:""},m={name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"},key:{required:!0,message:l.Translate("placeholder.input base.key"),trigger:"blur"},secret:{required:!0,message:l.Translate("placeholder.input config.secret"),trigger:"blur"},end_point:{required:!0,message:l.Translate("placeholder.input config.endpoint"),trigger:"blur"}},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,z);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-input"),n=e.resolveComponent("el-form-item"),g=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[6]||(r[6]=i=>e.isRef(p)?p.value=i:null),title:e.unref(d)("config.domain"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(g,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(n,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[0]||(r[0]=i=>e.unref(t).name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"en_name",label:e.unref(l.Translate)("base.en_name")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[1]||(r[1]=i=>e.unref(t).en_name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"key",label:e.unref(l.Translate)("base.key")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).key,"onUpdate:modelValue":r[2]||(r[2]=i=>e.unref(t).key=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"secret",label:e.unref(l.Translate)("config.secret")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).secret,"onUpdate:modelValue":r[3]||(r[3]=i=>e.unref(t).secret=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"end_point",label:e.unref(l.Translate)("config.end_point")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).end_point,"onUpdate:modelValue":r[4]||(r[4]=i=>e.unref(t).end_point=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[5]||(r[5]=i=>e.unref(t).remark=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Pe=e.defineComponent({__name:"DomainProviderTableDrawer",setup(x,{expose:k}){const{requesting:C}=l.useLoading(z),b=e.ref(!1),{tableRef:h,formModalRef:m,refresh:p,openFormModal:d,editFormModal:s}=l.useCrudPage({}),t=[{prop:"name",label:l.Translate("base.name"),width:0,minWidth:140},{prop:"en_name",label:l.Translate("base.en_name"),width:120},{prop:"actions",label:l.Translate("base.action"),width:60,align:"center",render:({rowData:a})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>s({id:a.id})},null)]})}];return k({open:()=>{b.value=!0}}),(a,f)=>{const _=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":f[0]||(f[0]=c=>b.value=c),width:"400px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(_,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.domain config.provider")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(p),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(d)},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(z).urls.list,columns:t,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode($e,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(p)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),ze=e.defineComponent({__name:"DomainTableDrawer",setup(x,{expose:k}){const{requesting:C}=l.useLoading(P),b=e.ref(!1),{tableRef:h,formModalRef:m,refresh:p,openFormModal:d,editFormModal:s}=l.useCrudPage(),{formModalRef:t,openFormModal:w,editFormModal:a}=l.useCrudPage(),{formModalRef:f,openFormModal:_}=l.useCrudPage(),c=[{prop:"provider",label:l.Translate("config.domain config.provider"),width:120,cellRenderer:({rowData:T})=>e.createVNode(e.resolveComponent("el-text"),null,{default:()=>{var r;return[(r=T.provider)==null?void 0:r.name]}})},{prop:"name",label:l.Translate("base.name"),width:0,minWidth:120},{prop:"expired_text",label:l.Translate("time.expired_at"),width:160},{prop:"actions",label:l.Translate("base.action"),width:100,align:"center",render:({rowData:T})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>s({id:T.id})},null),e.createVNode(l.OpenButton,{icon:"icon-safetycertificate-f",type:"primary",size:"small",link:!0,onOpen:()=>{var r;T.ssl&&T.ssl.id?a({id:(r=T.ssl)==null?void 0:r.id}):(t.value.formData.domain_id=T.id,t.value.formData.site_id=0,w())}},null)]})}];return k({open:()=>{b.value=!0}}),(T,r)=>{const o=e.resolveComponent("el-space"),n=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":r[0]||(r[0]=g=>b.value=g),width:"600px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(n,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.domain")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(p),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(d)},null,8,["onOpen"])]),extra:e.withCtx(()=>[e.createVNode(o,{class:"w-full extra-tool",alignment:"center"},{default:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_),type:"danger"},null,8,["onOpen"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(P).urls.list,columns:c,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode(qe,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(p)},null,8,["onRefresh"]),e.createVNode(ne,{ref_key:"sslFormModalRef",ref:t,onRefresh:e.unref(p)},null,8,["onRefresh"]),e.createVNode(Pe,{ref_key:"providerTableDrawerRef",ref:f},null,512)]),_:1},8,["modelValue"])}}}),Ie=e.defineComponent({__name:"SSLTableDrawer",setup(x,{expose:k}){const{requesting:C,executing:b}=l.useLoading(F),h=e.ref(0),m=e.ref(!1),{tableRef:p,formModalRef:d,refresh:s,openFormModal:t,editFormModal:w}=l.useCrudPage(),a=[{prop:"client",label:l.Translate("ssl.client"),width:100},{prop:"encryption",label:l.Translate("ssl.encryption"),width:100},{prop:"name",label:l.Translate("base.name"),width:0,minWidth:120},{prop:"path",label:l.Translate("base.path"),width:120},{prop:"renewal_days",label:l.Translate("ssl.renewal_days"),width:100},{prop:"checked_at",label:l.Translate("ssl.checked_at"),width:160},{prop:"actions",label:l.Translate("base.action"),width:160,align:"center",render:({rowData:R})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",icon:"icon-edit",t:"",disabled:b.value,onModify:()=>w({id:R.id})},null),e.createVNode(l.RequestButton,{size:"default",icon:"icon-key",t:"",text:!0,disabled:b.value&&h.value!==R.id,loading:h.value==R.id,onClick:()=>_(R.id)},null),e.createVNode(l.RequestButton,{size:"default",icon:"icon-cloud-download",t:"",text:!0,disabled:b.value&&h.value!==R.id,loading:h.value==R.id,onClick:()=>c(R)},null)]})}],f=()=>{m.value=!0},_=R=>{F.gen({id:R}).then(T=>{console.warn("Res:",T)})};function c(R){const T=l.AssetsUtils.getDownloadUrl(R.path+".zip");fetch(T).then(r=>r.blob()).then(r=>{let o=URL.createObjectURL(r),n=document.createElement("a");n.style.display="none",n.href=o,n.download=R.name+".zip",n.click(),URL.revokeObjectURL(r)})}return k({open:f}),(R,T)=>{const r=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:m.value,"onUpdate:modelValue":T[0]||(T[0]=o=>m.value=o),width:"1000px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(r,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("ssl.ssl")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(s),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(t)},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:p,size:"default","row-key":"id",url:e.unref(F).urls.list,columns:a,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode(ne,{ref_key:"formModalRef",ref:d,onRefresh:e.unref(s)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),oe=l.ApiUtils.routineApi("SSLLog","id"),je=e.defineComponent({__name:"SSLLogTableDrawer",props:{ssl:{type:Object,default:()=>({})}},setup(x,{expose:k}){const C=x,{requesting:b,executing:h}=l.useLoading([oe,F]),m=e.ref(!1),{tableRef:p,refresh:d}=l.useCrudPage(),s=[{prop:"status_text",label:l.Translate("base.status"),width:100},{prop:"at",label:l.Translate("base.time"),width:180},{prop:"type_text",label:l.Translate("base.type"),width:80},{prop:"result",label:l.Translate("base.result"),width:0}],t=()=>{m.value=!0};function w(){F.gen({id:C.ssl.id}).then(f=>{console.warn("Res:",f)})}function a(){const f=l.AssetsUtils.getDownloadUrl(C.ssl.path+".zip");fetch(f).then(_=>_.blob()).then(_=>{let c=URL.createObjectURL(_),R=document.createElement("a");R.style.display="none",R.href=c,R.download=C.ssl.name+".zip",R.click(),URL.revokeObjectURL(_)})}return k({open:t}),(f,_)=>{const c=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:m.value,"onUpdate:modelValue":_[0]||(_[0]=R=>m.value=R),width:"600px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(c,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.ssl base.log")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(d),size:"default",loading:e.unref(b)},null,8,["onRefresh","loading"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{size:"default",type:"danger",icon:"icon-key",disabled:e.unref(h),loading:e.unref(h),onClick:w},null,8,["disabled","loading"]),e.createVNode(e.unref(l.RequestButton),{size:"default",type:"primary",icon:"icon-cloud-download",disabled:e.unref(h),loading:e.unref(h),onClick:a},null,8,["disabled","loading"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:p,size:"small","row-key":"id",url:e.unref(oe).urls.search,columns:s,loading:e.unref(b)},null,8,["url","loading"])]),_:1},8,["modelValue"])}}}),ae=Z(e.defineComponent({__name:"index",setup(x){const k=e.ref(),{requesting:C,executing:b}=l.useLoading(q),{tableRef:h,formModalRef:m,reset:p,refresh:d,openFormModal:s,editFormModal:t}=l.useCrudPage(),{formModalRef:w,openFormModal:a}=l.useCrudPage(),{formModalRef:f,openFormModal:_}=l.useCrudPage(),{formModalRef:c,openFormModal:R}=l.useCrudPage(),T=[{prop:"domain.name",label:l.Translate("config.domain"),width:129,type:"copy"},{prop:"name",label:l.Translate("base.name"),width:100},{prop:"dns",label:l.Translate("config.dns"),width:160,type:"copy"},{prop:"git",label:l.Translate("config.git"),width:300,type:"copy"},{prop:"expired_at",label:l.Translate("time.expired_at"),align:"center",width:140,cellRenderer:({rowData:n})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(e.resolveComponent("el-text"),null,{default:()=>{var g;return[(g=n.ssl)==null?void 0:g.renewal_days,e.createTextVNode(" 天")]}}),e.createVNode(e.resolveComponent("el-button"),{size:"small",type:"primary",text:!0,onClick:g=>{g.stopPropagation(),n.ssl&&n.ssl.id&&(k.value=n.ssl,R())}},{default:()=>[e.createVNode("span",{class:"icon iconfont icon-reloadtime"},null)]})]})},{prop:"remark",label:l.Translate("base.remark"),width:0,minWidth:160},{prop:"operation",label:l.Translate("base.action"),width:100,align:"center",cellRenderer:({rowData:n})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>t({id:n.id})},null),e.createVNode(l.RequestButton,{icon:"icon-securityscan",type:"primary",size:"small",link:!0,disabled:b.value,loading:r.value==n.id&&b.value,onClick:()=>o(n)},null)]})}],r=e.ref(0),o=n=>{r.value=n.id,q.check({id:n.id}).then(g=>{g.data&&(l.notification(g),d())}).finally(()=>{r.value=0})};return(n,g)=>{const i=e.resolveComponent("el-space"),U=e.resolveComponent("el-page-header"),y=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(y,{"body-style":{padding:"12px",height:"450px"},"body-class":"flex-1",class:"config-card"},{header:e.withCtx(()=>[e.createVNode(U,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.keys.sites")),1)]),content:e.withCtx(()=>[e.createVNode(i,{alignment:"center",style:{height:"32px"}},{default:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(C),onRefresh:e.unref(p)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(s)},null,8,["onOpen"])]),_:1})]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(a),icon:"icon-compass"},null,8,["onOpen"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_),icon:"icon-safetycertificate-f"},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(q).urls[e.unref(l.DEFAULT_LIST_URL)],"auto-search":"",columns:T},null,8,["url"]),e.createVNode(Oe,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(d)},null,8,["onRefresh"]),e.createVNode(ze,{ref_key:"domainTableDrawerRef",ref:w},null,512),e.createVNode(Ie,{ref_key:"sslTableDrawerRef",ref:f},null,512),e.createVNode(je,{ref_key:"sslLogTableDrawerRef",ref:c},null,512)]),_:1})}}}),[["__scopeId","data-v-17c31592"]]),Ke=Object.freeze(Object.defineProperty({__proto__:null,default:ae},Symbol.toStringTag,{value:"Module"})),Ye={request:"request",error:"error",sql:"SQL"},$=l.ApiUtils.routineApi("log","id",Ye),de=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentHour().format(l.TimeUtils.DATE_VALUE_FORMAT),l.TimeUtils.getCurrentHour(1).format(l.TimeUtils.DATE_VALUE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-datetimerange","value-format":e.unref(l.TimeUtils).DATE_VALUE_FORMAT,format:e.unref(l.TimeUtils).DATE_SHOW_FORMAT,type:"datetimerange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.request,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),Ge=Object.freeze(Object.defineProperty({__proto__:null,default:de},Symbol.toStringTag,{value:"Module"})),se=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentDate(-7).format(l.TimeUtils.DATE_FORMAT),l.TimeUtils.getCurrentDate(0).format(l.TimeUtils.DATE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-daterange","value-format":e.unref(l.TimeUtils).DATE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,type:"daterange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.error,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),We=Object.freeze(Object.defineProperty({__proto__:null,default:se},Symbol.toStringTag,{value:"Module"})),ie=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentDate(-7).format(l.TimeUtils.DATE_FORMAT),l.TimeUtils.getCurrentDate().format(l.TimeUtils.DATE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-daterange","value-format":e.unref(l.TimeUtils).DATE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,type:"daterange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.sql,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),He=Object.freeze(Object.defineProperty({__proto__:null,default:ie},Symbol.toStringTag,{value:"Module"})),Qe=()=>Promise.resolve().then(()=>Ge),Je=()=>Promise.resolve().then(()=>We),Xe=()=>Promise.resolve().then(()=>He),Ze=[{path:l.REQUEST_LOG_URL,name:"RequestLog",component:Qe,meta:{title:l.Translate("menu.RequestLog")}},{path:l.ERROR_LOG_URL,name:"ErrorLog",component:Je,meta:{title:l.Translate("menu.ErrorLog")}},{path:l.SQL_LOG_URL,name:"SqlLog",component:Xe,meta:{title:l.Translate("menu.SqlLog")}}],ue={install:x=>{Reflect.ownKeys(x._context.provides).some(k=>String(k)==="Symbol(pinia)")||console.warn("Pinia is not provided. Please install and provide Pinia in your app.",Reflect.ownKeys(x._context.provides))},version:"__VERSION__"},Me=Object.assign({"./views/admin/index.vue":()=>Promise.resolve().then(()=>Le),"./views/language/index.vue":()=>Promise.resolve().then(()=>Se),"./views/menu/index.vue":()=>Promise.resolve().then(()=>Ce),"./views/role/index.vue":()=>Promise.resolve().then(()=>ye),"./views/site/index.vue":()=>Promise.resolve().then(()=>Ke)});S.AdminsPage=le,S.DomainProviderSelect=re,S.DomainSelect=Y,S.ErrorLogsPage=se,S.LanguagesPage=ee,S.LogRoutes=Ze,S.MenuSelect=Q,S.MenusPage=X,S.RequestLogsPage=de,S.RolesPage=u,S.SQLLogsPage=ie,S.SitePage=ae,S.SiteSelect=te,S.TopMenuSelect=H,S.basicModules=Me,S.default=ue,Object.defineProperties(S,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
1
+ (function(S,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("auto-vue-manual")):typeof define=="function"&&define.amd?define(["exports","vue","auto-vue-manual"],e):(S=typeof globalThis<"u"?globalThis:S||self,e(S.AutoVueBasic={},S.Vue,S["auto-vue-manual"]))})(this,(function(S,e,l){"use strict";const fe={tops:"tops",rules:"rules"},D=l.ApiUtils.routineApi("menu","id",fe,{},["TOP_MENU_LIST","MENU_LIST"]),W=l.ApiUtils.routineApi("rule","key");/*! Element Plus Icons Vue v2.3.2 */var ce=e.defineComponent({name:"Key",__name:"key",setup(x){return(k,C)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"M448 456.064V96a32 32 0 0 1 32-32.064L672 64a32 32 0 0 1 0 64H512v128h160a32 32 0 0 1 0 64H512v128a256 256 0 1 1-64 8.064M512 896a192 192 0 1 0 0-384 192 192 0 0 0 0 384"})]))}}),me=ce,_e=e.defineComponent({name:"Search",__name:"search",setup(x){return(k,C)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704"})]))}}),be=_e;const H=e.defineComponent({__name:"TopMenuSelect",props:{modelValue:{type:[Number,Array],required:!0},multiple:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(D),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"TOP_MENU_LIST",api:D,url:D.urls.tops,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),placeholder:e.unref(l.Translate)("placeholder.select"),filterable:"",filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(`icon iconfont ${c.icon}`)},null,2),e.createElementVNode("span",null,e.toDisplayString(c.translate),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","placeholder","filterOptions","onChange"])}}}),he=e.defineComponent({__name:"MenuFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,menu_id:0,module:"",sort:0,name:"",en_name:"",url:"",component:"",icon:"",remark:"",meta:{active:"",icon:"",title:"",affix:!1,full:!1,hide:!1,keep_alive:!1,link:!1}},m={sort:[{required:!0,type:"number",message:l.Translate("placeholder.input base.sort"),trigger:"blur"}],module:[{required:!0,message:l.Translate("placeholder.input menu.module"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}],url:[{required:!0,message:l.Translate("placeholder.input base.url"),trigger:"blur"}],component:[{required:!0,message:l.Translate("placeholder.input menu.component"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,D);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-col"),g=e.resolveComponent("el-input-number"),i=e.resolveComponent("el-row"),U=e.resolveComponent("el-input"),y=e.resolveComponent("el-switch"),A=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[17]||(r[17]=N=>e.isRef(p)?p.value=N:null),title:e.unref(d)(),width:"1000px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(A,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(i,{gutter:20},{default:e.withCtx(()=>[e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{gutter:10},{default:e.withCtx(()=>[e.createVNode(n,{span:14},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("base.parent"),prop:"menu_id"},{default:e.withCtx(()=>[e.createVNode(H,{modelValue:e.unref(t).menu_id,"onUpdate:modelValue":r[0]||(r[0]=N=>e.unref(t).menu_id=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:10},{default:e.withCtx(()=>[e.createVNode(o,{"label-width":"60px",label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(g,{class:"w-full",modelValue:e.unref(t).sort,"onUpdate:modelValue":r[1]||(r[1]=N=>e.unref(t).sort=N),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1}),e.createVNode(o,{label:e.unref(l.Translate)("menu.module"),prop:"module"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).module,"onUpdate:modelValue":r[2]||(r[2]=N=>e.unref(t).module=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[3]||(r[3]=N=>e.unref(t).name=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[4]||(r[4]=N=>e.unref(t).en_name=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("menu.component"),prop:"component"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).component,"onUpdate:modelValue":r[5]||(r[5]=N=>e.unref(t).component=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.url"),prop:"url"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).url,"onUpdate:modelValue":r[6]||(r[6]=N=>e.unref(t).url=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[7]||(r[7]=N=>e.unref(t).remark=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("base.icon"),prop:"icon"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).icon,"onUpdate:modelValue":r[8]||(r[8]=N=>e.unref(t).icon=N),placeholder:e.unref(l.Translate)("placeholder.input"),onInput:r[9]||(r[9]=N=>{e.unref(t).meta.icon=N})},{prepend:e.withCtx(()=>[e.createElementVNode("span",{class:e.normalizeClass("iconfont "+e.unref(t).icon)},null,2)]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.title"),prop:"meta.title"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).meta.title,"onUpdate:modelValue":r[10]||(r[10]=N=>e.unref(t).meta.title=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("menu.active"),prop:"meta.active"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(t).meta.active,"onUpdate:modelValue":r[11]||(r[11]=N=>e.unref(t).meta.active=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.link"),prop:"meta.link"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.link,"onUpdate:modelValue":r[12]||(r[12]=N=>e.unref(t).meta.link=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.keep_alive"),prop:"meta.keep_alive"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.keep_alive,"onUpdate:modelValue":r[13]||(r[13]=N=>e.unref(t).meta.keep_alive=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.hide"),prop:"meta.hide"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.hide,"onUpdate:modelValue":r[14]||(r[14]=N=>e.unref(t).meta.hide=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.full"),prop:"meta.full"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.full,"onUpdate:modelValue":r[15]||(r[15]=N=>e.unref(t).meta.full=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),e.createVNode(n,{span:12},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.affix"),prop:"meta.affix"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(t).meta.affix,"onUpdate:modelValue":r[16]||(r[16]=N=>e.unref(t).meta.affix=N)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Q=e.defineComponent({__name:"MenuSelect",props:{modelValue:{type:[Number,Array],required:!0},multiple:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(D),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"MENU_LIST",api:D,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),placeholder:e.unref(l.Translate)("placeholder.select"),filterable:"",filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(`icon iconfont ${c.icon}`)},null,2),e.createElementVNode("span",null,e.toDisplayString(c.translate),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","placeholder","filterOptions","onChange"])}}}),ge=e.defineComponent({__name:"MenuRuleFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={key:"",menu_id:0,sort:0,name:"",en_name:"",urls:"",remark:""},m={menu_id:[{required:!0,type:"number",message:l.Translate("placeholder.select menu.Menu"),trigger:"blur"}],sort:[{required:!0,type:"number",message:l.Translate("placeholder.input base.sort"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}],urls:[{required:!0,message:l.Translate("placeholder.input menu.rules"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,W);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input-number"),g=e.resolveComponent("el-input"),i=e.resolveComponent("el-col"),U=e.resolveComponent("el-row"),y=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[6]||(r[6]=A=>e.isRef(p)?p.value=A:null),title:e.unref(d)("menu.rules"),width:"1000px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(y,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(U,{gutter:20},{default:e.withCtx(()=>[e.createVNode(i,{span:10},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.Menu"),prop:"menu_id"},{default:e.withCtx(()=>[e.createVNode(Q,{modelValue:e.unref(t).menu_id,"onUpdate:modelValue":r[0]||(r[0]=A=>e.unref(t).menu_id=A)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(n,{class:"w-full",modelValue:e.unref(t).sort,"onUpdate:modelValue":r[1]||(r[1]=A=>e.unref(t).sort=A),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[2]||(r[2]=A=>e.unref(t).name=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[3]||(r[3]=A=>e.unref(t).en_name=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[4]||(r[4]=A=>e.unref(t).remark=A),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(i,{span:14},{default:e.withCtx(()=>[e.createVNode(o,{label:e.unref(l.Translate)("menu.rules"),prop:"urls"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).urls,"onUpdate:modelValue":r[5]||(r[5]=A=>e.unref(t).urls=A),type:"textarea",rows:11,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1})]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}});function J(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const X=e.defineComponent({__name:"index",setup(x){const k={keyword:"",status:0},C=e.ref(""),b=[{label:l.Translate("base.sort"),prop:"sort",width:60},{label:l.Translate("base.icon"),prop:"icon",width:60,render:({row:r})=>e.createVNode("span",{class:"iconfont "+r.icon,style:"font-size: 16px;"},null)},{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.parent"),prop:"parent",width:120,render:({row:r})=>{var o;return e.createVNode(e.Fragment,null,[(o=r.menu)==null?void 0:o.translate])}},{label:l.Translate("base.name"),prop:"translate",width:160},{label:l.Translate("base.url"),prop:"url",align:"left",width:200},{label:l.Translate("menu.component"),prop:"component",align:"left",width:200},{label:l.Translate("menu.rules"),prop:"rules",width:0,align:"left",render:({row:r})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>{var o;return[(o=r.rules)==null?void 0:o.map(n=>e.createVNode(e.resolveComponent("el-popover"),{visible:C.value===n.key,title:l.Translate("message.warning"),placement:"top-end",width:220},{reference:()=>e.createVNode(e.resolveComponent("el-tag"),{class:"cursor-pointer",closable:!0,key:n.key,onClick:()=>R({key:n.key}),onClose:()=>C.value=n.key},{default:()=>[n.translate]}),default:()=>{let g,i;return e.createVNode("div",null,[e.createVNode("p",null,null),e.createVNode("p",null,[`${l.Translate("base.confirm base.space base.delete base.space menu.rules")}: ${r.translate}-${n.translate} ?`]),e.createVNode("div",{style:"text-align: right; margin: 0"},[e.createVNode(e.resolveComponent("el-button"),{size:"small",text:!0,onClick:()=>C.value=""},J(g=l.Translate("base.cancel"))?g:{default:()=>[g]}),e.createVNode(e.resolveComponent("el-button"),{size:"small",type:"danger",onClick:()=>T(n.key)},J(i=l.Translate("base.confirm"))?i:{default:()=>[i]})])])}}))]}})},{label:l.Translate("base.status"),prop:"status",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:D.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{prop:"action",label:l.Translate("base.action"),width:60,align:"center",render:({row:r})=>e.createVNode(l.ModifyButton,{size:"default",onModify:()=>f({id:r.id})},null)}],{requesting:h}=l.useLoading(D),{tableRef:m,formModalRef:p,keyword:d,search:s,refresh:t,reset:w,openFormModal:a,editFormModal:f}=l.useCrudPage(k),{formModalRef:_,openFormModal:c,editFormModal:R}=l.useCrudPage(),T=r=>{W[l.DEFAULT_REMOVE_KEY]({key:r}).then(()=>{C.value="",t()})};return(r,o)=>{const n=e.resolveComponent("el-button"),g=e.resolveComponent("el-input"),i=e.resolveComponent("el-radio-button"),U=e.resolveComponent("el-radio-group"),y=e.resolveComponent("el-space"),A=e.resolveComponent("el-page-header"),N=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(N,{class:"basic-card flex-full","body-class":"flex-1",onClick:o[5]||(o[5]=()=>C.value="")},{header:e.withCtx(()=>[e.createVNode(A,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(h),onRefresh:e.unref(w)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(a)},null,8,["onOpen"]),e.createVNode(n,{circle:"",icon:e.unref(me),onClick:e.unref(c)},null,8,["icon","onClick"])]),content:e.withCtx(()=>[e.createVNode(y,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(g,{class:"basic-search-input",modelValue:e.unref(d).keyword,"onUpdate:modelValue":o[0]||(o[0]=B=>e.unref(d).keyword=B),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:o[1]||(o[1]=e.withKeys(B=>e.unref(s)(),["enter"])),onClear:o[2]||(o[2]=B=>e.unref(s)())},null,8,["modelValue","placeholder"]),e.createVNode(U,{modelValue:e.unref(d).status,"onUpdate:modelValue":o[3]||(o[3]=B=>e.unref(d).status=B),onChange:o[4]||(o[4]=B=>e.unref(s)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],B=>e.createVNode(i,{key:B,label:e.unref(l.Translate)(`status.${B}`),value:B},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(h),onSearch:e.unref(s)},null,8,["disabled","onSearch"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:m,size:"small",columns:b,url:e.unref(D).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(d),"auto-search":""},null,8,["url","search-param"]),e.createVNode(he,{ref_key:"formModalRef",ref:p,onRefresh:e.unref(t)},null,8,["onRefresh"]),e.createVNode(ge,{ref_key:"ruleFormModalRef",ref:_,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),Ce=Object.freeze(Object.defineProperty({__proto__:null,default:X},Symbol.toStringTag,{value:"Module"})),j=l.ApiUtils.routineApi("role","key"),we={class:"rule-check"},Te={style:{width:"80px","line-height":"36px"}},xe=e.defineComponent({__name:"RulesCheck",props:{modelValue:{type:Array,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(x,{expose:k,emit:C}){const{requesting:b}=l.useLoading(D),h=x,m=C,p=e.ref(!1),d=e.reactive({checkAll:!1,indeterminate:!1,MenuAll:{},MenuList:{},MenuIndeterminate:{}}),{options:s,refresh:t}=l.useSelect(e.toRef(h,"modelValue"),m,{key:"RULE_CHECK",api:D,url:D.urls.rules,isArray:!0},{autoRefresh:!1});function w(){s.value.forEach(T=>{var r;(r=T.rules)!=null&&r.length&&(d.MenuAll[T.id]=!1,d.MenuIndeterminate[T.id]=!1,d.MenuList[T.id]=[])})}function a(T){s.value.forEach(r=>{var o;(o=r.rules)!=null&&o.length&&(d.MenuList[r.id]=T?r.rules.map(n=>n.key):[])}),_()}function f(T,r){const o=s.value.find(n=>n.id===r);d.MenuList[r]=T&&o?o.rules.map(n=>n.key):[],_()}function _(){s.value.forEach(T=>{var n,g;const r=((n=T.rules)==null?void 0:n.length)||0,o=((g=d.MenuList[T.id])==null?void 0:g.length)||0;d.MenuAll[T.id]=o===r&&r>0,d.MenuIndeterminate[T.id]=o>0&&o<r}),d.checkAll=Object.values(d.MenuAll).every(Boolean),d.indeterminate=!d.checkAll&&Object.values(d.MenuList).some(T=>T.length>0),m("update:modelValue",Object.values(d.MenuList).flat())}function c(){d.checkAll=!1,d.indeterminate=!1,d.MenuAll={},d.MenuList={},d.MenuIndeterminate={},w(),m("update:modelValue",[]),p.value=!1}function R(T){var r;if(Array.isArray(s.value)&&s.value.length>0){for(let o of s.value)if(Array.isArray(o.rules)&&o.rules.length>0)for(let n of o.rules)T.some(g=>g===n.key)&&(d.MenuList[o.id]=(((r=d.MenuList)==null?void 0:r[o.id])||[]).concat([n.key]));_(),p.value=!0}}return e.onMounted(async()=>{var T;(T=s.value)!=null&&T.length||await t(),!p.value&&h.modelValue&&R(h.modelValue)}),e.watch(()=>h.modelValue,T=>{e.nextTick(()=>{var r;p.value||!((r=s.value)!=null&&r.length)||T&&T.length>0&&R(T)})},{deep:!0,immediate:!0}),k({generateOption:R,cleanChecked:c}),(T,r)=>{const o=e.resolveComponent("el-checkbox"),n=e.resolveComponent("el-space"),g=e.resolveComponent("el-text"),i=e.resolveComponent("el-divider"),U=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",we,[e.createVNode(n,{style:{"margin-bottom":"6px"}},{default:e.withCtx(()=>[e.createVNode(o,{"model-value":d.checkAll,indeterminate:d.indeterminate,id:"all",disabled:x.disabled,onChange:a},{default:e.withCtx(()=>[...r[1]||(r[1]=[e.createElementVNode("span",null,"全选",-1)])]),_:1},8,["model-value","indeterminate","disabled"]),e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),text:"",size:"small",onRefresh:r[0]||(r[0]=y=>e.unref(t)(!0))},null,8,["loading"])]),_:1}),e.createVNode(n,{direction:"vertical",alignment:"start",class:"rule-check-content"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(s),y=>(e.openBlock(),e.createElementBlock("div",{key:y.id},[e.createVNode(n,{direction:"horizontal",size:2},{default:e.withCtx(()=>[e.createVNode(o,{style:{"min-width":"150px"},"model-value":d.MenuAll[y.id],disabled:x.disabled||!y.rules||y.rules.length<=0,indeterminate:d.MenuIndeterminate[y.id],onChange:A=>f(A,y.id)},{default:e.withCtx(()=>[e.createVNode(g,{style:{"font-size":"15px"}},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(y.translate),1)]),_:2},1024)]),_:2},1032,["model-value","disabled","indeterminate","onChange"]),e.createVNode(i,{direction:"vertical"}),y.rules?(e.openBlock(),e.createBlock(U,{key:0,modelValue:d.MenuList[y.id],"onUpdate:modelValue":A=>d.MenuList[y.id]=A,disabled:x.disabled,style:{margin:"auto"},onChange:_},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.rules,A=>(e.openBlock(),e.createBlock(o,{key:A.key,value:A.key},{default:e.withCtx(()=>[e.createElementVNode("div",Te,e.toDisplayString(A.translate),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"])):e.createCommentVNode("",!0)]),_:2},1024)]))),128))]),_:1})])}}}),Z=(x,k)=>{const C=x.__vccOpts||x;for(const[b,h]of k)C[b]=h;return C},Ne=Z(xe,[["__scopeId","data-v-7adb5f76"]]),ke=e.defineComponent({__name:"RoleFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h=e.ref(),m={key:"",module:"",sort:0,name:"",en_name:"",remark:"",rules:[]},p={name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}]},{modal:d,title:s,form:t,formData:w,requesting:a,executing:f,open:_,modify:c,submit:R,closed:T}=l.useForm(b,m,j),r=()=>{var o;(o=h.value)==null||o.cleanChecked(),T()};return k({open:_,modify:c}),(o,n)=>{const g=e.resolveComponent("el-input"),i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-col"),y=e.resolveComponent("el-input-number"),A=e.resolveComponent("el-row"),N=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(d),"onUpdate:modelValue":n[6]||(n[6]=B=>e.isRef(d)?d.value=B:null),title:e.unref(s)(),width:"1000px",executing:e.unref(f),onClosed:r,onSubmit:e.unref(R)},{default:e.withCtx(()=>[e.createVNode(N,{ref_key:"form",ref:t,model:e.unref(w),"label-width":"auto",rules:p,disabled:e.unref(a)||e.unref(f)},{default:e.withCtx(()=>[e.createVNode(A,{gutter:20},{default:e.withCtx(()=>[e.createVNode(U,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.module"),prop:"module"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).module,"onUpdate:modelValue":n[0]||(n[0]=B=>e.unref(w).module=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1}),e.createVNode(U,{span:12},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.sort"),prop:"sort"},{default:e.withCtx(()=>[e.createVNode(y,{class:"w-full",modelValue:e.unref(w).sort,"onUpdate:modelValue":n[1]||(n[1]=B=>e.unref(w).sort=B),min:0,placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1})]),_:1}),e.createVNode(i,{label:e.unref(l.Translate)("base.name"),prop:"name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).name,"onUpdate:modelValue":n[2]||(n[2]=B=>e.unref(w).name=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.en_name"),prop:"en_name"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).en_name,"onUpdate:modelValue":n[3]||(n[3]=B=>e.unref(w).en_name=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(w).remark,"onUpdate:modelValue":n[4]||(n[4]=B=>e.unref(w).remark=B),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("menu.rules"),prop:"rules"},{default:e.withCtx(()=>[e.createVNode(Ne,{ref_key:"rulesCheck",ref:h,modelValue:e.unref(w).rules,"onUpdate:modelValue":n[5]||(n[5]=B=>e.unref(w).rules=B),disabled:e.unref(a)||e.unref(f)},null,8,["modelValue","disabled"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onSubmit"])}}}),u=e.defineComponent({__name:"index",setup(x){const k={keyword:""},C=[{label:l.Translate("base.sort"),prop:"sort",width:80},{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.name"),prop:"translate",width:120},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("time.created_at"),prop:"created_at",width:180},{prop:"action",label:l.Translate("base.action"),width:65,align:"center",render:({row:f})=>e.createVNode(l.ModifyButton,{size:"default",onModify:()=>a({key:f.key})},null)}],{requesting:b}=l.useLoading(j),{tableRef:h,formModalRef:m,keyword:p,search:d,reset:s,refresh:t,openFormModal:w,editFormModal:a}=l.useCrudPage(k);return(f,_)=>{const c=e.resolveComponent("el-input"),R=e.resolveComponent("el-space"),T=e.resolveComponent("el-page-header"),r=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(r,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(T,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(s)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(w)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(R,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(c,{class:"basic-search-input",modelValue:e.unref(p).keyword,"onUpdate:modelValue":_[0]||(_[0]=o=>e.unref(p).keyword=o),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:_[1]||(_[1]=e.withKeys(o=>e.unref(d)(),["enter"])),onClear:_[2]||(_[2]=o=>e.unref(d)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:_[3]||(_[3]=o=>e.unref(d)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:h,columns:C,url:e.unref(j).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(p),"auto-search":""},null,8,["url","search-param"]),e.createVNode(ke,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),ye=Object.freeze(Object.defineProperty({__proto__:null,default:u},Symbol.toStringTag,{value:"Module"})),L=l.ApiUtils.routineApi("I18N","uuid",{modules:"modules",languages:"languages"},{gen:"gen"},["I18N_MODULES"]),O=l.ApiUtils.routineApi("I18N_template","uuid",{apps:"apps"}),M=e.defineComponent({__name:"ModuleSelect",props:{modelValue:{type:String,default:void 0,required:!1},multiple:{type:Boolean,default:!1},allowCreate:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1}},emits:["update:modelValue","update:value","change"],setup(x,{emit:k}){const C=k,b=x,{requesting:h}=l.useLoading(L),{value:m,options:p,change:d,refresh:s,filterOptions:t}=l.useSelect(e.toRef(b,"modelValue"),C,{key:"I18N_MODULES",url:L.urls.modules,api:L,isArray:!0});return(w,a)=>{const f=e.resolveComponent("el-space"),_=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(_,{class:"w-full",modelValue:e.unref(m),"onUpdate:modelValue":a[1]||(a[1]=c=>e.isRef(m)?m.value=c:null),options:e.unref(p),multiple:x.multiple,disabled:e.unref(h),clearable:x.clearable,filterable:"","allow-create":x.allowCreate,"default-first-option":"",placeholder:e.unref(l.Translate)("placeholder.select"),filterOptions:e.unref(t),onChange:e.unref(d)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(h),onRefresh:a[0]||(a[0]=c=>e.unref(s)(!0))},null,8,["loading"])]),default:e.withCtx(({item:c})=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(c.value),1)]),_:2},1024)]),_:1},8,["modelValue","options","multiple","disabled","clearable","allow-create","placeholder","filterOptions","onChange"])}}}),Re=e.defineComponent({__name:"I18N",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={uuid:"",key:"",module:"",language:{"zh-CN":"","en-US":""},remark:""},m={module:[{required:!0,message:l.Translate("language.placeholder.module"),trigger:"blur"}],key:[{required:!0,message:l.Translate("language.placeholder.key"),trigger:"blur"}],language:[{required:!0,message:l.Translate("language.placeholder.language"),trigger:"change"}],result:[{required:!0,message:l.Translate("language.placeholder.result"),trigger:"blur"}]},p=e.ref([]),d=l.useCacheStore();function s(){const n={isArray:!0,key:"I18N_LANGUAGES",url:L.urls.languages,params:{}};d.GET_CACHE({...n,force:!0}).then(g=>{p.value=g})}s();const{modal:t,title:w,form:a,formData:f,requesting:_,executing:c,open:R,modify:T,submit:r,closed:o}=l.useForm(b,h,L);return k({open:R,modify:T}),(n,g)=>{const i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-input"),y=e.resolveComponent("el-space"),A=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(t),"onUpdate:modelValue":g[3]||(g[3]=N=>e.isRef(t)?t.value=N:null),title:e.unref(w)(),width:"600px",executing:e.unref(c),onClosed:e.unref(o),onSubmit:e.unref(r)},{default:e.withCtx(()=>[e.createVNode(A,{ref_key:"form",ref:a,model:e.unref(f),"label-width":"auto",rules:m,disabled:e.unref(_)||e.unref(c)},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("i18n.module"),prop:"module",required:""},{default:e.withCtx(()=>[e.createVNode(M,{modelValue:e.unref(f).module,"onUpdate:modelValue":g[0]||(g[0]=N=>e.unref(f).module=N),"allow-create":""},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("i18n.key"),prop:"key",required:""},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(f).key,"onUpdate:modelValue":g[1]||(g[1]=N=>e.unref(f).key=N),placeholder:e.unref(l.Translate)("language.placeholder.key")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("i18n.language"),prop:"language",required:""},{default:e.withCtx(()=>[e.createVNode(y,{direction:"vertical",fill:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,N=>(e.openBlock(),e.createElementBlock("div",{key:N},[e.createVNode(U,{modelValue:e.unref(f).language[N],"onUpdate:modelValue":B=>e.unref(f).language[N]=B,placeholder:e.unref(l.Translate)("i18n.placeholder.key")},{prepend:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(N),1)]),_:2},1032,["modelValue","onUpdate:modelValue","placeholder"])]))),128))]),_:1})]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(U,{modelValue:e.unref(f).remark,"onUpdate:modelValue":g[2]||(g[2]=N=>e.unref(f).remark=N),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}});function Ve(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const v=e.defineComponent({__name:"I18N",emits:["closed","choosed"],setup(x,{expose:k,emit:C}){const b=e.ref(!1),h=C,m={keyword:"",module:void 0,status:0},p=[{label:l.Translate("base.module"),prop:"module",width:120},{label:l.Translate("base.key"),prop:"key",width:200},{label:l.Translate("base.i18n"),align:"left",prop:"language",render:({row:g})=>{const U=Object.keys(g.language).filter(y=>!!g.language[y]).map(y=>`${y}: ${g.language[y]}`).join("; ");return e.createVNode(e.resolveComponent("el-space"),null,Ve(U)?U:{default:()=>[U]})}},{label:l.Translate("base.status"),prop:"checked",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:L.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{prop:"action",label:l.Translate("base.action"),width:120,align:"center",render:({row:g})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",onModify:()=>T({uuid:g.uuid})},null),e.createVNode(l.RequestButton,{size:"default",text:!0,type:"danger",loading:s.value,onClick:()=>r(g.uuid)},null)]})}],{requesting:d,executing:s}=l.useLoading(L),{tableRef:t,formModalRef:w,keyword:a,search:f,reset:_,refresh:c,openFormModal:R,editFormModal:T}=l.useCrudPage(m);function r(g){return L.remove({uuid:g}).finally(()=>{c()})}const o=()=>{b.value=!0};function n(g){h("choosed",g),b.value=!1}return e.watch(()=>b.value,g=>{g||h("closed")}),k({open:o}),(g,i)=>{const U=e.resolveComponent("el-input"),y=e.resolveComponent("el-radio-button"),A=e.resolveComponent("el-radio-group"),N=e.resolveComponent("el-space"),B=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":i[7]||(i[7]=V=>b.value=V),width:"880px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(B,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(d),onRefresh:e.unref(_)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(R)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(N,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(U,{style:{width:"160px"},modelValue:e.unref(a).keyword,"onUpdate:modelValue":i[0]||(i[0]=V=>e.unref(a).keyword=V),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:i[1]||(i[1]=e.withKeys(V=>e.unref(f)(),["enter"])),onClear:i[2]||(i[2]=V=>e.unref(f)())},null,8,["modelValue","placeholder"]),e.createVNode(M,{modelValue:e.unref(a).module,"onUpdate:modelValue":i[3]||(i[3]=V=>e.unref(a).module=V),clearable:!0,style:{width:"160px"}},null,8,["modelValue"]),e.createVNode(A,{modelValue:e.unref(a).status,"onUpdate:modelValue":i[4]||(i[4]=V=>e.unref(a).status=V),onChange:i[5]||(i[5]=V=>e.unref(f)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],V=>e.createVNode(y,{key:V,label:e.unref(l.Translate)(`status.${V}`),value:V},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(d),onSearch:i[6]||(i[6]=V=>e.unref(f)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:t,columns:p,url:e.unref(L).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(a),onRowDblclick:n,"auto-search":""},null,8,["url","search-param"]),e.createVNode(Re,{ref_key:"formModalRef",ref:w,onRefresh:e.unref(c)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),Ue=e.defineComponent({__name:"template",emits:["refresh"],setup(x,{expose:k,emit:C}){const{formModalRef:b,openFormModal:h}=l.useCrudPage(),m=C,p=e.ref("600px"),d=e.ref({"zh-CN":"primary","en-US":"success"}),s=e.ref({}),t={uuid:"",app:1,keys:"",values:[],remark:""},w={app:[{required:!0,message:l.Translate("i18n.placeholder.app"),trigger:"blur"}],keys:[{required:!0,message:l.Translate("i18n.placeholder.keys"),trigger:"blur"}],values:[{required:!0,message:l.Translate("i18n.placeholder.values"),trigger:"change"}]},{modal:a,title:f,form:_,formData:c,requesting:R,executing:T,open:r,modify:o,submit:n,closed:g}=l.useForm(m,t,O);function i(){p.value="1080px",h()}function U(){p.value="600px"}function y(N){let B=N.module.toLowerCase()+"."+N.key.toLowerCase();c.keys=B,c.values.push(B);for(const V in N.language)s.value[V]||(s.value[V]=[]),s.value[V].push(N.language[V])}function A(){p.value="600px",s.value={"zh-CN":[],"en-US":[]}}return e.watch(()=>a.value,N=>{N?A():g()}),k({open:r,modify:o}),(N,B)=>{const V=e.resolveComponent("el-page-header"),I=e.resolveComponent("el-form-item"),ve=e.resolveComponent("el-button"),pe=e.resolveComponent("el-input"),el=e.resolveComponent("el-tag"),ll=e.resolveComponent("el-space"),rl=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:e.unref(a),"onUpdate:modelValue":B[3]||(B[3]=E=>e.isRef(a)?a.value=E:null),width:p.value,"show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(V,{class:"basic-header"},{title:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(f)("i18n.template")),1)]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{circle:!1,size:"default",type:"primary",icon:"icon-save",plain:!1,loading:e.unref(T),onClick:e.unref(n)},null,8,["loading","onClick"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(rl,{ref_key:"form",ref:_,model:e.unref(c),"label-width":"auto",rules:w,disabled:e.unref(R)||e.unref(T)},{default:e.withCtx(()=>[e.createVNode(I,{label:e.unref(l.Translate)("i18n.app"),prop:"app",required:""},{default:e.withCtx(()=>[e.createVNode(e.unref(l.BasicRadioButton),{modelValue:e.unref(c).app,"onUpdate:modelValue":B[0]||(B[0]=E=>e.unref(c).app=E),"cache-key":"I18NAPPS",hidden:[0],url:e.unref(O).urls.apps},null,8,["modelValue","url"])]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.keys"),prop:"keys",required:""},{default:e.withCtx(()=>[e.createVNode(pe,{modelValue:e.unref(c).keys,"onUpdate:modelValue":B[1]||(B[1]=E=>e.unref(c).keys=E),placeholder:e.unref(l.Translate)("i18n.placeholder.key")},{append:e.withCtx(()=>[e.createVNode(ve,{icon:e.unref(be),onClick:i},null,8,["icon"])]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.values"),prop:"values",required:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(c).values.join(":")),1)]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("i18n.values")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(E,G)=>(e.openBlock(),e.createElementBlock("div",{key:G,class:"w-full"},[e.createVNode(ll,null,{default:e.withCtx(()=>[e.createVNode(el,{type:d.value[G],style:{"min-width":"80px"}},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(G),1)]),_:2},1032,["type"]),e.createElementVNode("span",null,e.toDisplayString(E.join("")),1)]),_:2},1024)]))),128))]),_:1},8,["label"]),e.createVNode(I,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(pe,{modelValue:e.unref(c).remark,"onUpdate:modelValue":B[2]||(B[2]=E=>e.unref(c).remark=E),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"]),e.createVNode(v,{ref_key:"I18nTableDrawerRef",ref:b,onChoosed:y,onClosed:U},null,512)]),_:1},8,["modelValue","width"])}}}),Be=l.ApiUtils.routineApi("gateway","id",{gen:"gen_translation"});function Ae(x){return typeof x=="function"||Object.prototype.toString.call(x)==="[object Object]"&&!e.isVNode(x)}const ee=e.defineComponent({__name:"index",setup(x){const k={keyword:"",app:0,status:0},C=[{label:l.Translate("base.app"),prop:"app",width:120,render:({row:o})=>{let n;return e.createVNode(e.resolveComponent("el-tag"),{type:l.Translate("i18n.app.colors."+o.app),style:"min-width: 80px"},Ae(n=l.Translate("i18n.app."+o.app))?n:{default:()=>[n]})}},{label:l.Translate("i18n.keys"),prop:"keys",width:200},{label:l.Translate("i18n.values"),prop:"values",width:200},{label:l.Translate("base.status"),prop:"checked",width:80,type:"switch",props:{activeValue:1,inactiveValue:2,api:O.urls[l.DEFAULT_STATUS_KEY],refresh:!0}},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("time.created_at"),prop:"created_at",width:160},{label:l.Translate("time.updated_at"),prop:"updated_at",width:160},{prop:"action",label:l.Translate("base.action"),width:120,align:"center",render:({row:o})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",disabled:h.value,onModify:()=>c({uuid:o.uuid})},null),e.createVNode(l.RequestButton,{size:"default",text:!0,type:"danger",loading:h.value,onClick:()=>R(o.uuid)},null)]})}],{requesting:b,executing:h}=l.useLoading(O),{formModalRef:m,openFormModal:p}=l.useCrudPage(),{tableRef:d,formModalRef:s,keyword:t,search:w,reset:a,refresh:f,openFormModal:_,editFormModal:c}=l.useCrudPage(k);function R(o){return O.remove({uuid:o}).finally(()=>{f()})}function T(){return L.gen().finally(()=>{f()})}function r(){Be.gen().finally(()=>{f()})}return(o,n)=>{const g=e.resolveComponent("el-divider"),i=e.resolveComponent("el-input"),U=e.resolveComponent("el-radio-button"),y=e.resolveComponent("el-radio-group"),A=e.resolveComponent("el-space"),N=e.resolveComponent("el-page-header"),B=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(B,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(N,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(a)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_)},null,8,["onOpen"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{size:"default",type:"warning",icon:"icon-cloud-upload",plain:!1,loading:e.unref(h),onClick:T},null,8,["loading"]),e.createVNode(e.unref(l.RequestButton),{size:"default",type:"danger",icon:"icon-translate",plain:!1,loading:e.unref(h),onClick:r},null,8,["loading"]),e.createVNode(g,{direction:"vertical"}),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(p),icon:"icon-en-US"},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(A,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(i,{class:"basic-search-input",modelValue:e.unref(t).keyword,"onUpdate:modelValue":n[0]||(n[0]=V=>e.unref(t).keyword=V),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:n[1]||(n[1]=e.withKeys(V=>e.unref(w)(),["enter"])),onClear:n[2]||(n[2]=V=>e.unref(w)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.BasicRadioButton),{modelValue:e.unref(t).app,"onUpdate:modelValue":n[3]||(n[3]=V=>e.unref(t).app=V),"cache-key":"I18NAPPS",url:e.unref(O).urls.apps,onChange:n[4]||(n[4]=V=>e.unref(w)())},null,8,["modelValue","url"]),e.createVNode(y,{modelValue:e.unref(t).status,"onUpdate:modelValue":n[5]||(n[5]=V=>e.unref(t).status=V),onChange:n[6]||(n[6]=V=>e.unref(w)())},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList([0,1,2],V=>e.createVNode(U,{key:V,label:e.unref(l.Translate)(`status.${V}`),value:V},null,8,["label","value"])),64))]),_:1},8,["modelValue"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:n[7]||(n[7]=V=>e.unref(w)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:d,columns:C,url:e.unref(O).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(t),"auto-search":""},null,8,["url","search-param"]),e.createVNode(v,{ref_key:"I18nTableDrawerRef",ref:m,onRefresh:e.unref(f)},null,8,["onRefresh"]),e.createVNode(Ue,{ref_key:"formModalRef",ref:s,onRefresh:e.unref(f)},null,8,["onRefresh"])]),_:1})}}}),Se=Object.freeze(Object.defineProperty({__proto__:null,default:ee},Symbol.toStringTag,{value:"Module"})),K=l.ApiUtils.routineApi("admin","key"),De=e.defineComponent({__name:"AdminFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={key:"",username:"",password:"",phone:"",email:"",language:"zh-CN",remark:"",roles:[]},{modal:m,title:p,form:d,formData:s,requesting:t,executing:w,open:a,modify:f,submit:_,closed:c}=l.useForm(b,h,K),R={username:[{required:!0,message:l.Translate("placeholder.input base.username"),trigger:"blur"}],phone:[{required:!0,validator:l.RulesUtils.phoneRule,message:l.Translate("placeholder.input base.phone"),trigger:"blur"}],password:[{required:!1,message:l.Translate("placeholder.input base.password"),trigger:"blur"}],email:[{required:!0,message:l.Translate("placeholder.input base.email"),trigger:"blur"}],language:[{required:!0,message:l.Translate("placeholder.select base.language"),trigger:"change"}],roles:[{required:!0,type:"Array",message:l.Translate("placeholder.select menu.Role"),trigger:"change"}]},T=e.ref([]),r=async()=>{const o=await j.list();T.value=Array.isArray(o==null?void 0:o.data)?o.data:[]};return e.onBeforeMount(async()=>{await r()}),k({open:a,modify:f}),(o,n)=>{const g=e.resolveComponent("el-input"),i=e.resolveComponent("el-form-item"),U=e.resolveComponent("el-radio-button"),y=e.resolveComponent("el-radio-group"),A=e.resolveComponent("el-checkbox"),N=e.resolveComponent("el-checkbox-group"),B=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(m),"onUpdate:modelValue":n[7]||(n[7]=V=>e.isRef(m)?m.value=V:null),title:e.unref(p)(),width:"600px",executing:e.unref(w),onClosed:e.unref(c),onSubmit:e.unref(_)},{default:e.withCtx(()=>[e.createVNode(B,{ref_key:"form",ref:d,model:e.unref(s),"label-width":"auto",rules:R,disabled:e.unref(t)||e.unref(w)},{default:e.withCtx(()=>[e.createVNode(i,{label:e.unref(l.Translate)("base.username"),prop:"username"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).username,"onUpdate:modelValue":n[0]||(n[0]=V=>e.unref(s).username=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.phone"),prop:"phone"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).phone,"onUpdate:modelValue":n[1]||(n[1]=V=>e.unref(s).phone=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.password"),prop:"password",required:!e.unref(s).key},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).password,"onUpdate:modelValue":n[2]||(n[2]=V=>e.unref(s).password=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label","required"]),e.createVNode(i,{label:e.unref(l.Translate)("base.email"),prop:"email"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).email,"onUpdate:modelValue":n[3]||(n[3]=V=>e.unref(s).email=V),placeholder:e.unref(l.Translate)("placeholder.input"),autocomplete:"off"},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.language"),prop:"language"},{default:e.withCtx(()=>[e.createVNode(y,{modelValue:e.unref(s).language,"onUpdate:modelValue":n[4]||(n[4]=V=>e.unref(s).language=V)},{default:e.withCtx(()=>[e.createVNode(U,{value:"zh-CN"},{default:e.withCtx(()=>[...n[8]||(n[8]=[e.createTextVNode("zh-CN",-1)])]),_:1}),e.createVNode(U,{value:"en-US"},{default:e.withCtx(()=>[...n[9]||(n[9]=[e.createTextVNode("en-US",-1)])]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("menu.Role"),prop:"roles"},{default:e.withCtx(()=>[e.createVNode(N,{modelValue:e.unref(s).roles,"onUpdate:modelValue":n[5]||(n[5]=V=>e.unref(s).roles=V)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.value,V=>(e.openBlock(),e.createBlock(A,{key:V.key,value:V.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(V.translate),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i,{label:e.unref(l.Translate)("base.remark"),prop:"remark"},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(s).remark,"onUpdate:modelValue":n[6]||(n[6]=V=>e.unref(s).remark=V),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),le=e.defineComponent({__name:"index",setup(x){const k={keyword:""},C=[{label:l.Translate("base.avatar"),prop:"avatar",width:60,render:({row:f})=>e.createVNode(l.BasicAvatar,{src:f.avatar},null)},{label:l.Translate("base.user"),width:200,align:"left",render:({row:f})=>e.createVNode(e.resolveComponent("el-space"),{direction:"vertical",alignment:"start"},{default:()=>[e.createVNode("div",null,[f.username]),e.createVNode("div",null,[f.email])]})},{label:l.Translate("base.phone"),prop:"phone",width:140},{label:l.Translate("base.remark"),prop:"remark",width:0},{label:l.Translate("base.login_at"),prop:"login_at",width:160},{label:l.Translate("time.created_at"),prop:"created_at",width:160},{label:l.Translate("time.updated_at"),prop:"updated_at",width:160},{prop:"action",label:l.Translate("base.action"),width:80,align:"center",render:({row:f})=>e.createVNode(l.ModifyButton,{onModify:()=>a({key:f.key})},null)}],{requesting:b}=l.useLoading(K),{tableRef:h,formModalRef:m,keyword:p,search:d,reset:s,refresh:t,openFormModal:w,editFormModal:a}=l.useCrudPage(k);return(f,_)=>{const c=e.resolveComponent("el-input"),R=e.resolveComponent("el-space"),T=e.resolveComponent("el-page-header"),r=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(r,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(T,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(s)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(w)},null,8,["onOpen"])]),content:e.withCtx(()=>[e.createVNode(R,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(c,{class:"basic-search-input",modelValue:e.unref(p).keyword,"onUpdate:modelValue":_[0]||(_[0]=o=>e.unref(p).keyword=o),placeholder:e.unref(l.Translate)("placeholder.keyword"),clearable:"",onKeyup:_[1]||(_[1]=e.withKeys(o=>e.unref(d)(),["enter"])),onClear:_[2]||(_[2]=o=>e.unref(d)())},null,8,["modelValue","placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:_[3]||(_[3]=o=>e.unref(d)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref(K).urls[e.unref(l.DEFAULT_PAGE_KEY)],"search-param":e.unref(p),"auto-search":""},null,8,["url","search-param"]),e.createVNode(De,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(t)},null,8,["onRefresh"])]),_:1})}}}),Le=Object.freeze(Object.defineProperty({__proto__:null,default:le},Symbol.toStringTag,{value:"Module"})),Ee={check:"check"},q=l.ApiUtils.routineApi("site","id",Ee),P=l.ApiUtils.routineApi("domain"),Y=e.defineComponent({__name:"DomainSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(P),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"DOMAIN_LIST",api:P,isArray:!0});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),Oe=e.defineComponent({__name:"SiteFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,domain_id:0,prefix:"",name:"",en_name:"",dns:"",git:"",status:1,remark:""},m={domain_id:[{required:!0,message:l.Translate("placeholder.input config.domain"),trigger:"blur"}],prefix:[{required:!0,message:l.Translate("placeholder.input base.prefix"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:[{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,q);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input"),g=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[7]||(r[7]=i=>e.isRef(p)?p.value=i:null),title:e.unref(d)("config.site"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(g,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"domain_id",label:e.unref(l.Translate)("config.domain")},{default:e.withCtx(()=>[e.createVNode(Y,{modelValue:e.unref(t).domain_id,"onUpdate:modelValue":r[0]||(r[0]=i=>e.unref(t).domain_id=i),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"prefix",label:e.unref(l.Translate)("config.prefix")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).prefix,"onUpdate:modelValue":r[1]||(r[1]=i=>e.unref(t).prefix=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[2]||(r[2]=i=>e.unref(t).name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"en_name",label:e.unref(l.Translate)("base.en_name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[3]||(r[3]=i=>e.unref(t).en_name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"dns",label:e.unref(l.Translate)("config.dns")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).dns,"onUpdate:modelValue":r[4]||(r[4]=i=>e.unref(t).dns=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"git",label:e.unref(l.Translate)("config.git")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).git,"onUpdate:modelValue":r[5]||(r[5]=i=>e.unref(t).git=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[6]||(r[6]=i=>e.unref(t).remark=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),z=l.ApiUtils.routineApi("domain_provider"),re=e.defineComponent({__name:"DomainProviderSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(z),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"DOMAIN_PROVIDER_LIST",api:z,isArray:!0});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain config.provider"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),qe=e.defineComponent({__name:"DomainFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,provider_id:0,name:"",expired_at:"",status:1,remark:""},m={provider_id:[{required:!0,message:l.Translate("placeholder.input config.domain config.provider"),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,P);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-input"),g=e.resolveComponent("el-date-picker"),i=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[4]||(r[4]=U=>e.isRef(p)?p.value=U:null),title:e.unref(d)("config.domain"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(i,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"provider_id",label:e.unref(l.Translate)("config.provider")},{default:e.withCtx(()=>[e.createVNode(re,{modelValue:e.unref(t).provider_id,"onUpdate:modelValue":r[0]||(r[0]=U=>e.unref(t).provider_id=U),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[1]||(r[1]=U=>e.unref(t).name=U),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"expired_at",required:"",label:e.unref(l.Translate)("time.expired_at")},{default:e.withCtx(()=>[e.createVNode(g,{type:"date",style:{width:"100%"},modelValue:e.unref(t).expired_at,"onUpdate:modelValue":r[2]||(r[2]=U=>e.unref(t).expired_at=U),disabled:e.unref(a),"value-format":e.unref(l.TimeUtils).DATE_VALUE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,placeholder:e.unref(l.Translate)("placeholder.select")},null,8,["modelValue","disabled","value-format","format","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(n,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[3]||(r[3]=U=>e.unref(t).remark=U),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Fe={gen:"gen"},F=l.ApiUtils.routineApi("SSL","id",Fe),te=e.defineComponent({__name:"SiteSelect",props:{modelValue:{type:Number,required:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(x,{expose:k,emit:C}){const b=C,h=x,{requesting:m}=l.useLoading(q),{key:p,options:d,refresh:s,change:t}=l.useSelect(e.toRef(h,"modelValue"),b,{key:"SITE_LIST",api:q,isArray:!0},{formatOptions:w=>w.map(a=>{var f;return{...a,label:a.prefix+"."+((f=a.domain)==null?void 0:f.name),value:a.id}})});return k({refresh:s}),(w,a)=>{const f=e.resolveComponent("el-select-v2");return e.openBlock(),e.createBlock(f,{modelValue:e.unref(p),"onUpdate:modelValue":a[0]||(a[0]=_=>e.isRef(p)?p.value=_:null),options:e.unref(d),disabled:x.disabled||e.unref(m),placeholder:e.unref(l.Translate)("base.select config.domain"),onChange:e.unref(t)},{prefix:e.withCtx(()=>[e.createVNode(e.unref(l.InlineRefreshButton),{loading:e.unref(m),onRefresh:e.unref(s)},null,8,["loading","onRefresh"])]),_:1},8,["modelValue","options","disabled","placeholder","onChange"])}}}),ne=e.defineComponent({__name:"SSLFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,domain_id:void 0,client:"Lego",site_id:void 0,name:"",path:"",email:"",encryption:"RSA2048",remark:""},m={domain_id:[{required:!0,message:l.Translate("placeholder.select config.domain "),trigger:"blur"}],client:[{required:!0,message:l.Translate("placeholder.select config.client "),trigger:"blur"}],name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],path:[{required:!0,message:l.Translate("placeholder.input base.path"),trigger:"blur"}],email:[{required:!0,message:l.Translate("placeholder.input base.email"),trigger:"blur"}],encryption:[{required:!0,message:l.Translate("placeholder.input config.encryption"),trigger:"blur"}]},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,F);return k({open:f,modify:_,formData:t}),(T,r)=>{const o=e.resolveComponent("el-form-item"),n=e.resolveComponent("el-radio-button"),g=e.resolveComponent("el-radio-group"),i=e.resolveComponent("el-input"),U=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[8]||(r[8]=y=>e.isRef(p)?p.value=y:null),title:e.unref(d)("ssl.ssl"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(U,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(o,{prop:"domain_id",label:e.unref(l.Translate)("config.domain")},{default:e.withCtx(()=>[e.createVNode(Y,{modelValue:e.unref(t).domain_id,"onUpdate:modelValue":r[0]||(r[0]=y=>e.unref(t).domain_id=y),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"client",label:e.unref(l.Translate)("ssl.client")},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).client,"onUpdate:modelValue":r[1]||(r[1]=y=>e.unref(t).client=y)},{default:e.withCtx(()=>[e.createVNode(n,{label:"Lego",value:"Lego"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{prop:"site_id",label:e.unref(l.Translate)("config.site")},{default:e.withCtx(()=>[e.createVNode(te,{modelValue:e.unref(t).site_id,"onUpdate:modelValue":r[2]||(r[2]=y=>e.unref(t).site_id=y),disabled:e.unref(a)},null,8,["modelValue","disabled"])]),_:1},8,["label"]),e.createVNode(o,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[3]||(r[3]=y=>e.unref(t).name=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"path",label:e.unref(l.Translate)("base.path")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).path,"onUpdate:modelValue":r[4]||(r[4]=y=>e.unref(t).path=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"email",label:e.unref(l.Translate)("base.email")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).email,"onUpdate:modelValue":r[5]||(r[5]=y=>e.unref(t).email=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(o,{prop:"encryption",label:e.unref(l.Translate)("config.encryption")},{default:e.withCtx(()=>[e.createVNode(g,{modelValue:e.unref(t).encryption,"onUpdate:modelValue":r[6]||(r[6]=y=>e.unref(t).encryption=y)},{default:e.withCtx(()=>[e.createVNode(n,{label:"RSA2048",value:"RSA2048"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(o,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[7]||(r[7]=y=>e.unref(t).remark=y),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),$e=e.defineComponent({__name:"DomainProviderFormModal",emits:["refresh"],setup(x,{expose:k,emit:C}){const b=C,h={id:0,name:"",en_name:"",key:"",secret:"",end_point:"",status:1,remark:""},m={name:[{required:!0,message:l.Translate("placeholder.input base.name"),trigger:"blur"}],en_name:{required:!0,message:l.Translate("placeholder.input base.en_name"),trigger:"blur"},key:{required:!0,message:l.Translate("placeholder.input base.key"),trigger:"blur"},secret:{required:!0,message:l.Translate("placeholder.input config.secret"),trigger:"blur"},end_point:{required:!0,message:l.Translate("placeholder.input config.endpoint"),trigger:"blur"}},{modal:p,title:d,form:s,formData:t,requesting:w,executing:a,open:f,modify:_,submit:c,closed:R}=l.useForm(b,h,z);return k({open:f,modify:_}),(T,r)=>{const o=e.resolveComponent("el-input"),n=e.resolveComponent("el-form-item"),g=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(e.unref(l.FormDialog),{modelValue:e.unref(p),"onUpdate:modelValue":r[6]||(r[6]=i=>e.isRef(p)?p.value=i:null),title:e.unref(d)("config.domain"),width:"600px",executing:e.unref(a),onClosed:e.unref(R),onSubmit:e.unref(c)},{default:e.withCtx(()=>[e.createVNode(g,{ref_key:"form",ref:s,model:e.unref(t),"label-width":"auto",rules:m,disabled:e.unref(w)||e.unref(a)},{default:e.withCtx(()=>[e.createVNode(n,{prop:"name",label:e.unref(l.Translate)("base.name")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).name,"onUpdate:modelValue":r[0]||(r[0]=i=>e.unref(t).name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"en_name",label:e.unref(l.Translate)("base.en_name")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).en_name,"onUpdate:modelValue":r[1]||(r[1]=i=>e.unref(t).en_name=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"key",label:e.unref(l.Translate)("base.key")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).key,"onUpdate:modelValue":r[2]||(r[2]=i=>e.unref(t).key=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"secret",label:e.unref(l.Translate)("config.secret")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).secret,"onUpdate:modelValue":r[3]||(r[3]=i=>e.unref(t).secret=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"end_point",label:e.unref(l.Translate)("config.end_point")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).end_point,"onUpdate:modelValue":r[4]||(r[4]=i=>e.unref(t).end_point=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"]),e.createVNode(n,{prop:"remark",label:e.unref(l.Translate)("base.remark")},{default:e.withCtx(()=>[e.createVNode(o,{modelValue:e.unref(t).remark,"onUpdate:modelValue":r[5]||(r[5]=i=>e.unref(t).remark=i),disabled:e.unref(a),placeholder:e.unref(l.Translate)("placeholder.input")},null,8,["modelValue","disabled","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","disabled"])]),_:1},8,["modelValue","title","executing","onClosed","onSubmit"])}}}),Pe=e.defineComponent({__name:"DomainProviderTableDrawer",setup(x,{expose:k}){const{requesting:C}=l.useLoading(z),b=e.ref(!1),{tableRef:h,formModalRef:m,refresh:p,openFormModal:d,editFormModal:s}=l.useCrudPage({}),t=[{prop:"name",label:l.Translate("base.name"),width:0,minWidth:140},{prop:"en_name",label:l.Translate("base.en_name"),width:120},{prop:"actions",label:l.Translate("base.action"),width:60,align:"center",render:({rowData:a})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>s({id:a.id})},null)]})}];return k({open:()=>{b.value=!0}}),(a,f)=>{const _=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":f[0]||(f[0]=c=>b.value=c),width:"400px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(_,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.domain config.provider")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(p),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(d)},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(z).urls.list,columns:t,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode($e,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(p)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),ze=e.defineComponent({__name:"DomainTableDrawer",setup(x,{expose:k}){const{requesting:C}=l.useLoading(P),b=e.ref(!1),{tableRef:h,formModalRef:m,refresh:p,openFormModal:d,editFormModal:s}=l.useCrudPage(),{formModalRef:t,openFormModal:w,editFormModal:a}=l.useCrudPage(),{formModalRef:f,openFormModal:_}=l.useCrudPage(),c=[{prop:"provider",label:l.Translate("config.domain config.provider"),width:120,cellRenderer:({rowData:T})=>e.createVNode(e.resolveComponent("el-text"),null,{default:()=>{var r;return[(r=T.provider)==null?void 0:r.name]}})},{prop:"name",label:l.Translate("base.name"),width:0,minWidth:120},{prop:"expired_text",label:l.Translate("time.expired_at"),width:160},{prop:"actions",label:l.Translate("base.action"),width:100,align:"center",render:({rowData:T})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>s({id:T.id})},null),e.createVNode(l.OpenButton,{icon:"icon-safetycertificate-f",type:"primary",size:"small",link:!0,onOpen:()=>{var r;T.ssl&&T.ssl.id?a({id:(r=T.ssl)==null?void 0:r.id}):(t.value.formData.domain_id=T.id,t.value.formData.site_id=0,w())}},null)]})}];return k({open:()=>{b.value=!0}}),(T,r)=>{const o=e.resolveComponent("el-space"),n=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:b.value,"onUpdate:modelValue":r[0]||(r[0]=g=>b.value=g),width:"600px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(n,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.domain")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(p),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(d)},null,8,["onOpen"])]),extra:e.withCtx(()=>[e.createVNode(o,{class:"w-full extra-tool",alignment:"center"},{default:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_),type:"danger"},null,8,["onOpen"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(P).urls.list,columns:c,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode(qe,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(p)},null,8,["onRefresh"]),e.createVNode(ne,{ref_key:"sslFormModalRef",ref:t,onRefresh:e.unref(p)},null,8,["onRefresh"]),e.createVNode(Pe,{ref_key:"providerTableDrawerRef",ref:f},null,512)]),_:1},8,["modelValue"])}}}),Ie=e.defineComponent({__name:"SSLTableDrawer",setup(x,{expose:k}){const{requesting:C,executing:b}=l.useLoading(F),h=e.ref(0),m=e.ref(!1),{tableRef:p,formModalRef:d,refresh:s,openFormModal:t,editFormModal:w}=l.useCrudPage(),a=[{prop:"client",label:l.Translate("ssl.client"),width:100},{prop:"encryption",label:l.Translate("ssl.encryption"),width:100},{prop:"name",label:l.Translate("base.name"),width:0,minWidth:120},{prop:"path",label:l.Translate("base.path"),width:120},{prop:"renewal_days",label:l.Translate("ssl.renewal_days"),width:100},{prop:"checked_at",label:l.Translate("ssl.checked_at"),width:160},{prop:"actions",label:l.Translate("base.action"),width:160,align:"center",render:({rowData:R})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{size:"default",icon:"icon-edit",t:"",disabled:b.value,onModify:()=>w({id:R.id})},null),e.createVNode(l.RequestButton,{size:"default",icon:"icon-key",t:"",text:!0,disabled:b.value&&h.value!==R.id,loading:h.value==R.id,onClick:()=>_(R.id)},null),e.createVNode(l.RequestButton,{size:"default",icon:"icon-cloud-download",t:"",text:!0,disabled:b.value&&h.value!==R.id,loading:h.value==R.id,onClick:()=>c(R)},null)]})}],f=()=>{m.value=!0},_=R=>{F.gen({id:R}).then(T=>{console.warn("Res:",T)})};function c(R){const T=l.AssetsUtils.getDownloadUrl(R.path+".zip");fetch(T).then(r=>r.blob()).then(r=>{let o=URL.createObjectURL(r),n=document.createElement("a");n.style.display="none",n.href=o,n.download=R.name+".zip",n.click(),URL.revokeObjectURL(r)})}return k({open:f}),(R,T)=>{const r=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:m.value,"onUpdate:modelValue":T[0]||(T[0]=o=>m.value=o),width:"1000px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(r,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("ssl.ssl")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(s),size:"default",loading:e.unref(C)},null,8,["onRefresh","loading"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(t)},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:p,size:"default","row-key":"id",url:e.unref(F).urls.list,columns:a,loading:e.unref(C)},null,8,["url","loading"]),e.createVNode(ne,{ref_key:"formModalRef",ref:d,onRefresh:e.unref(s)},null,8,["onRefresh"])]),_:1},8,["modelValue"])}}}),oe=l.ApiUtils.routineApi("SSLLog","id"),je=e.defineComponent({__name:"SSLLogTableDrawer",props:{ssl:{type:Object,default:()=>({})}},setup(x,{expose:k}){const C=x,{requesting:b,executing:h}=l.useLoading([oe,F]),m=e.ref(!1),{tableRef:p,refresh:d}=l.useCrudPage(),s=[{prop:"status_text",label:l.Translate("base.status"),width:100},{prop:"at",label:l.Translate("base.time"),width:180},{prop:"type_text",label:l.Translate("base.type"),width:80},{prop:"result",label:l.Translate("base.result"),width:0}],t=()=>{m.value=!0};function w(){F.gen({id:C.ssl.id}).then(f=>{console.warn("Res:",f)})}function a(){const f=l.AssetsUtils.getDownloadUrl(C.ssl.path+".zip");fetch(f).then(_=>_.blob()).then(_=>{let c=URL.createObjectURL(_),R=document.createElement("a");R.style.display="none",R.href=c,R.download=C.ssl.name+".zip",R.click(),URL.revokeObjectURL(_)})}return k({open:t}),(f,_)=>{const c=e.resolveComponent("el-page-header");return e.openBlock(),e.createBlock(e.unref(l.BasicDrawer),{modelValue:m.value,"onUpdate:modelValue":_[0]||(_[0]=R=>m.value=R),width:"600px","show-close":!1,class:"basic-drawer"},{title:e.withCtx(()=>[e.createVNode(c,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.ssl base.log")),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{onRefresh:e.unref(d),size:"default",loading:e.unref(b)},null,8,["onRefresh","loading"])]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.RequestButton),{size:"default",type:"danger",icon:"icon-key",disabled:e.unref(h),loading:e.unref(h),onClick:w},null,8,["disabled","loading"]),e.createVNode(e.unref(l.RequestButton),{size:"default",type:"primary",icon:"icon-cloud-download",disabled:e.unref(h),loading:e.unref(h),onClick:a},null,8,["disabled","loading"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTable),{ref_key:"tableRef",ref:p,size:"small","row-key":"id",url:e.unref(oe).urls.search,columns:s,loading:e.unref(b)},null,8,["url","loading"])]),_:1},8,["modelValue"])}}}),ae=Z(e.defineComponent({__name:"index",setup(x){const k=e.ref(),{requesting:C,executing:b}=l.useLoading(q),{tableRef:h,formModalRef:m,reset:p,refresh:d,openFormModal:s,editFormModal:t}=l.useCrudPage(),{formModalRef:w,openFormModal:a}=l.useCrudPage(),{formModalRef:f,openFormModal:_}=l.useCrudPage(),{formModalRef:c,openFormModal:R}=l.useCrudPage(),T=[{prop:"domain.name",label:l.Translate("config.domain"),width:129,type:"copy"},{prop:"name",label:l.Translate("base.name"),width:100},{prop:"dns",label:l.Translate("config.dns"),width:160,type:"copy"},{prop:"git",label:l.Translate("config.git"),width:300,type:"copy"},{prop:"expired_at",label:l.Translate("time.expired_at"),align:"center",width:140,cellRenderer:({rowData:n})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(e.resolveComponent("el-text"),null,{default:()=>{var g;return[(g=n.ssl)==null?void 0:g.renewal_days,e.createTextVNode(" 天")]}}),e.createVNode(e.resolveComponent("el-button"),{size:"small",type:"primary",text:!0,onClick:g=>{g.stopPropagation(),n.ssl&&n.ssl.id&&(k.value=n.ssl,R())}},{default:()=>[e.createVNode("span",{class:"icon iconfont icon-reloadtime"},null)]})]})},{prop:"remark",label:l.Translate("base.remark"),width:0,minWidth:160},{prop:"operation",label:l.Translate("base.action"),width:100,align:"center",cellRenderer:({rowData:n})=>e.createVNode(e.resolveComponent("el-space"),null,{default:()=>[e.createVNode(l.ModifyButton,{icon:"icon-edit",t:"",onModify:()=>t({id:n.id})},null),e.createVNode(l.RequestButton,{icon:"icon-securityscan",type:"primary",size:"small",link:!0,disabled:b.value,loading:r.value==n.id&&b.value,onClick:()=>o(n)},null)]})}],r=e.ref(0),o=n=>{r.value=n.id,q.check({id:n.id}).then(g=>{g.data&&(l.notification(g),d())}).finally(()=>{r.value=0})};return(n,g)=>{const i=e.resolveComponent("el-space"),U=e.resolveComponent("el-page-header"),y=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(y,{"body-style":{padding:"12px",height:"450px"},"body-class":"flex-1",class:"config-card"},{header:e.withCtx(()=>[e.createVNode(U,{icon:""},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(e.unref(l.Translate)("config.keys.sites")),1)]),content:e.withCtx(()=>[e.createVNode(i,{alignment:"center",style:{height:"32px"}},{default:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(C),onRefresh:e.unref(p)},null,8,["loading","onRefresh"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(s)},null,8,["onOpen"])]),_:1})]),extra:e.withCtx(()=>[e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(a),icon:"icon-compass"},null,8,["onOpen"]),e.createVNode(e.unref(l.OpenButton),{onOpen:e.unref(_),icon:"icon-safetycertificate-f"},null,8,["onOpen"])]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small","row-key":"id",url:e.unref(q).urls[e.unref(l.DEFAULT_LIST_URL)],"auto-search":"",columns:T},null,8,["url"]),e.createVNode(Oe,{ref_key:"formModalRef",ref:m,onRefresh:e.unref(d)},null,8,["onRefresh"]),e.createVNode(ze,{ref_key:"domainTableDrawerRef",ref:w},null,512),e.createVNode(Ie,{ref_key:"sslTableDrawerRef",ref:f},null,512),e.createVNode(je,{ref_key:"sslLogTableDrawerRef",ref:c},null,512)]),_:1})}}}),[["__scopeId","data-v-17c31592"]]),Ke=Object.freeze(Object.defineProperty({__proto__:null,default:ae},Symbol.toStringTag,{value:"Module"})),Ye={request:"request",error:"error",sql:"SQL"},$=l.ApiUtils.routineApi("log","id",Ye),de=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentHour().format(l.TimeUtils.DATE_VALUE_FORMAT),l.TimeUtils.getCurrentHour(1).format(l.TimeUtils.DATE_VALUE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-datetimerange","value-format":e.unref(l.TimeUtils).DATE_VALUE_FORMAT,format:e.unref(l.TimeUtils).DATE_SHOW_FORMAT,type:"datetimerange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.request,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),Ge=Object.freeze(Object.defineProperty({__proto__:null,default:de},Symbol.toStringTag,{value:"Module"})),se=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentDate(-7).format(l.TimeUtils.DATE_FORMAT),l.TimeUtils.getCurrentDate(0).format(l.TimeUtils.DATE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-daterange","value-format":e.unref(l.TimeUtils).DATE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,type:"daterange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.error,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),We=Object.freeze(Object.defineProperty({__proto__:null,default:se},Symbol.toStringTag,{value:"Module"})),ie=e.defineComponent({__name:"index",setup(x){const k={dates:[l.TimeUtils.getCurrentDate(-7).format(l.TimeUtils.DATE_FORMAT),l.TimeUtils.getCurrentDate().format(l.TimeUtils.DATE_FORMAT)]},C=[{label:l.Translate("base.sort"),type:"index",width:60},{label:l.Translate("base.time"),prop:"time",width:180,render:({rowData:s})=>e.createVNode(e.Fragment,null,[l.TimeUtils.formatDate(s.time)])},{label:l.Translate("base.url"),prop:"url",align:"left",width:200}],{requesting:b}=l.useLoading($),{tableRef:h,keyword:m,search:p,reset:d}=l.useCrudPage(k);return(s,t)=>{const w=e.resolveComponent("el-date-picker"),a=e.resolveComponent("el-space"),f=e.resolveComponent("el-page-header"),_=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(_,{class:"basic-card flex-full","body-class":"flex-1"},{header:e.withCtx(()=>[e.createVNode(f,{class:"basic-header"},{title:e.withCtx(()=>[e.createVNode(e.unref(l.RefreshButton),{loading:e.unref(b),onRefresh:e.unref(d)},null,8,["loading","onRefresh"])]),content:e.withCtx(()=>[e.createVNode(a,{class:"search-bar"},{default:e.withCtx(()=>[e.createVNode(w,{modelValue:e.unref(m).dates,"onUpdate:modelValue":t[0]||(t[0]=c=>e.unref(m).dates=c),class:"basic-search-daterange","value-format":e.unref(l.TimeUtils).DATE_FORMAT,format:e.unref(l.TimeUtils).DATE_FORMAT,type:"daterange","range-separator":"-","start-placeholder":e.unref(l.Translate)("base.start_at"),"end-placeholder":e.unref(l.Translate)("base.end_at"),clearable:!1,onChange:t[1]||(t[1]=c=>e.unref(p)())},null,8,["modelValue","value-format","format","start-placeholder","end-placeholder"]),e.createVNode(e.unref(l.SearchButton),{disabled:e.unref(b),onSearch:t[2]||(t[2]=c=>e.unref(p)())},null,8,["disabled"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(l.ProTableList),{ref_key:"tableRef",ref:h,size:"small",columns:C,url:e.unref($).urls.sql,"search-param":e.unref(m),"auto-search":""},null,8,["url","search-param"])]),_:1})}}}),He=Object.freeze(Object.defineProperty({__proto__:null,default:ie},Symbol.toStringTag,{value:"Module"})),Qe=()=>Promise.resolve().then(()=>Ge),Je=()=>Promise.resolve().then(()=>We),Xe=()=>Promise.resolve().then(()=>He),Ze=[{path:l.REQUEST_LOG_URL,name:"RequestLog",component:Qe,meta:{title:l.Translate("menu.RequestLog")}},{path:l.ERROR_LOG_URL,name:"ErrorLog",component:Je,meta:{title:l.Translate("menu.ErrorLog")}},{path:l.SQL_LOG_URL,name:"SqlLog",component:Xe,meta:{title:l.Translate("menu.SqlLog")}}],ue={install:x=>{Reflect.ownKeys(x._context.provides).some(k=>String(k)==="Symbol(pinia)")||console.warn("Pinia is not provided. Please install and provide Pinia in your app.",Reflect.ownKeys(x._context.provides))},version:"__VERSION__"},Me=Object.assign({"./views/admin/index.vue":()=>Promise.resolve().then(()=>Le),"./views/language/index.vue":()=>Promise.resolve().then(()=>Se),"./views/menu/index.vue":()=>Promise.resolve().then(()=>Ce),"./views/role/index.vue":()=>Promise.resolve().then(()=>ye),"./views/site/index.vue":()=>Promise.resolve().then(()=>Ke)});S.AdminsPage=le,S.DomainProviderSelect=re,S.DomainSelect=Y,S.ErrorLogsPage=se,S.LanguagesPage=ee,S.LogRoutes=Ze,S.MenuSelect=Q,S.MenusPage=X,S.RequestLogsPage=de,S.RolesPage=u,S.SQLLogsPage=ie,S.SitePage=ae,S.SiteSelect=te,S.TopMenuSelect=H,S.basicModules=Me,S.default=ue,Object.defineProperties(S,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
@@ -24,7 +24,7 @@ export declare type I18N = {
24
24
  export declare type I18NTemplate = {
25
25
  uuid: string;
26
26
  app: number;
27
- keys: string[];
27
+ keys: string;
28
28
  values: string[];
29
29
  status?: Status;
30
30
  checked?: boolean;
@@ -9,7 +9,7 @@ declare const _default: DefineComponent<ExtractPropTypes<{
9
9
  type: BooleanConstructor;
10
10
  default: boolean;
11
11
  };
12
- 'allow-create': {
12
+ allowCreate: {
13
13
  type: BooleanConstructor;
14
14
  default: boolean;
15
15
  };
@@ -31,7 +31,7 @@ declare const _default: DefineComponent<ExtractPropTypes<{
31
31
  type: BooleanConstructor;
32
32
  default: boolean;
33
33
  };
34
- 'allow-create': {
34
+ allowCreate: {
35
35
  type: BooleanConstructor;
36
36
  default: boolean;
37
37
  };
@@ -47,6 +47,6 @@ declare const _default: DefineComponent<ExtractPropTypes<{
47
47
  modelValue: string | undefined;
48
48
  multiple: boolean;
49
49
  clearable: boolean;
50
- 'allow-create': boolean;
50
+ allowCreate: boolean;
51
51
  }, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
52
52
  export default _default;
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const __VERSION__ = "0.0.75'
1
+ export const __VERSION__ = "0.0.76'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auto-vue-basic",
3
- "version": "0.0.76",
3
+ "version": "0.0.77",
4
4
  "type": "module",
5
5
  "main": "./dist/auto-vue-basic.umd.js",
6
6
  "module": "./dist/auto-vue-basic.es.js",