gds-plus-design-vue 1.2.4 → 1.2.5

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.
Files changed (89) hide show
  1. package/lib/{chartbi.5eded588.js → chartbi.b5b6fdab.js} +1 -1
  2. package/lib/{chartbi.c3bc6adb.mjs → chartbi.b6818e8e.mjs} +3 -2
  3. package/lib/gd-initial.js +14 -14
  4. package/lib/gd-initial.mjs +3614 -2814
  5. package/lib/{main.00e2ba37.mjs → main.4e325110.mjs} +3 -3
  6. package/lib/main.6713b76c.js +1 -0
  7. package/lib/{main.b4ad6d81.mjs → main.955f770e.mjs} +16 -13
  8. package/lib/main.a28f67df.js +1 -0
  9. package/lib/{main.7e1495ec.js → main.b4a303dc.js} +1 -1
  10. package/lib/{main.b25a9b4c.mjs → main.be62e9a4.mjs} +12 -34
  11. package/lib/{main.55fab1ce.mjs → main.c59fc1e8.mjs} +7 -7
  12. package/lib/{main.a27e1e54.js → main.f3ae0933.js} +1 -1
  13. package/lib/messages.1346558e.js +9 -0
  14. package/lib/{messages.bc3bc0e8.mjs → messages.7e418640.mjs} +1095 -1065
  15. package/lib/style.css +3 -3
  16. package/lib/{system.account.868f96f9.mjs → system.account.64fbdaeb.mjs} +2 -2
  17. package/lib/{system.account.e82580de.js → system.account.7c43a95e.js} +1 -1
  18. package/lib/system.config.93d6cb7d.js +1 -0
  19. package/lib/{system.config.71615d2b.mjs → system.config.f0d2d130.mjs} +7 -2
  20. package/lib/{system.datasource.523ae242.js → system.datasource.4bb39222.js} +1 -1
  21. package/lib/{system.datasource.009a1673.mjs → system.datasource.61ff56ec.mjs} +3 -3
  22. package/lib/{system.dict.0111a3bc.js → system.dict.5a2e60fe.js} +1 -1
  23. package/lib/{system.dict.8f562e89.mjs → system.dict.a817cf68.mjs} +2 -2
  24. package/lib/{system.duplicatechecking.1865e065.js → system.duplicatechecking.65b77e64.js} +1 -1
  25. package/lib/{system.duplicatechecking.f517abed.mjs → system.duplicatechecking.751664ba.mjs} +15 -11
  26. package/lib/{system.email.4c484530.mjs → system.email.2f53252e.mjs} +2 -2
  27. package/lib/{system.email.70351605.js → system.email.fec5ae26.js} +1 -1
  28. package/lib/{system.fieldsecurity.9f9f73df.mjs → system.fieldsecurity.6feb94c3.mjs} +1 -1
  29. package/lib/{system.fieldsecurity.d11088e3.js → system.fieldsecurity.920adca4.js} +1 -1
  30. package/lib/{system.file.96b3ce1e.mjs → system.file.1930d109.mjs} +11 -6
  31. package/lib/system.file.5a9a5e0e.js +1 -0
  32. package/lib/{system.log.80feb1c4.mjs → system.log.61d303bd.mjs} +64 -81
  33. package/lib/system.log.b309c0e0.js +1 -0
  34. package/lib/{system.machine.6e46b7a3.js → system.machine.9368e508.js} +1 -1
  35. package/lib/{system.machine.52e8a4f3.mjs → system.machine.ed69ec93.mjs} +1 -1
  36. package/lib/{system.notice.b4247147.mjs → system.notice.bd18554e.mjs} +13 -10
  37. package/lib/system.notice.ff62c06a.js +1 -0
  38. package/lib/{system.noticereceived.eef2cf6e.mjs → system.noticereceived.4dc360c0.mjs} +31 -29
  39. package/lib/system.noticereceived.9550818b.js +1 -0
  40. package/lib/{system.onlineuser.de5f62bf.mjs → system.onlineuser.08a15a71.mjs} +22 -15
  41. package/lib/system.onlineuser.6cf4fe24.js +1 -0
  42. package/lib/{system.org.d22168d6.js → system.org.0c67131d.js} +1 -1
  43. package/lib/{system.org.94393315.mjs → system.org.6e858bf3.mjs} +3 -3
  44. package/lib/{system.permissions.3c5c3573.js → system.permissions.af548a3b.js} +1 -1
  45. package/lib/{system.permissions.ccbe352d.mjs → system.permissions.cc5ac7ac.mjs} +3 -3
  46. package/lib/{system.plugin.5d47e679.js → system.plugin.83d03fb2.js} +1 -1
  47. package/lib/{system.plugin.8caa5d1f.mjs → system.plugin.a1f1c194.mjs} +2 -2
  48. package/lib/{system.pos.caaef4fc.js → system.pos.eae2051e.js} +1 -1
  49. package/lib/{system.pos.e4be69c4.mjs → system.pos.eb8fd7dd.mjs} +2 -2
  50. package/lib/{system.promptmanagement.e73f64a2.js → system.promptmanagement.04501417.js} +1 -1
  51. package/lib/{system.promptmanagement.1ad89863.mjs → system.promptmanagement.c84db7d5.mjs} +7 -7
  52. package/lib/{system.role.0323ddd5.mjs → system.role.d2195303.mjs} +49 -48
  53. package/lib/system.role.e623c50b.js +1 -0
  54. package/lib/{system.sumberrules.42965c1e.mjs → system.sumberrules.141dc00b.mjs} +2 -2
  55. package/lib/{system.sumberrules.2babdd81.js → system.sumberrules.a01e1805.js} +1 -1
  56. package/lib/system.team.0cebcde7.js +1 -0
  57. package/lib/{system.team.28168433.mjs → system.team.27a6d5d5.mjs} +289 -246
  58. package/lib/system.teammembers.b67f003f.js +1 -0
  59. package/lib/{system.teammembers.08f3ce38.mjs → system.teammembers.d73c659f.mjs} +78 -40
  60. package/lib/{system.timers.040b9bce.mjs → system.timers.4a3dd57d.mjs} +2 -2
  61. package/lib/{system.timers.310b3710.js → system.timers.b27fcb6d.js} +1 -1
  62. package/lib/{system.translation.a4396166.js → system.translation.d2c982ed.js} +1 -1
  63. package/lib/{system.translation.c0068d8f.mjs → system.translation.d9488c23.mjs} +7 -7
  64. package/lib/{system.user.20a5e7b4.js → system.user.0664c21c.js} +5 -5
  65. package/lib/{system.user.84e77277.mjs → system.user.6874aa87.mjs} +101 -69
  66. package/lib/{system.useraffiliation.fb961d98.mjs → system.useraffiliation.5e3e2bab.mjs} +3 -3
  67. package/lib/{system.useraffiliation.307e3cd7.js → system.useraffiliation.6b7a1612.js} +1 -1
  68. package/lib/{system.webresource.2d0ab7a6.mjs → system.webresource.204911b7.mjs} +16 -18
  69. package/lib/system.webresource.5de18052.js +1 -0
  70. package/lib/{system.welcome.aaac4a40.mjs → system.welcome.79e15015.mjs} +1 -1
  71. package/lib/{system.welcome.67d20fa4.js → system.welcome.ec7aa744.js} +1 -1
  72. package/locale/en_US.js +25 -3
  73. package/locale/id_ID.js +25 -3
  74. package/locale/vi_VN.js +1967 -1945
  75. package/locale/zh_CN.js +26 -4
  76. package/package.json +1 -1
  77. package/lib/main.9c85b10c.js +0 -1
  78. package/lib/main.a794f7cf.js +0 -1
  79. package/lib/messages.fa3d97b5.js +0 -9
  80. package/lib/system.config.6aae9ea6.js +0 -1
  81. package/lib/system.file.001a01bc.js +0 -1
  82. package/lib/system.log.f7afb251.js +0 -1
  83. package/lib/system.notice.365ddd35.js +0 -1
  84. package/lib/system.noticereceived.5545acf8.js +0 -1
  85. package/lib/system.onlineuser.fd9fdc66.js +0 -1
  86. package/lib/system.role.b5b55ddd.js +0 -1
  87. package/lib/system.team.a3527834.js +0 -1
  88. package/lib/system.teammembers.4b11e49b.js +0 -1
  89. package/lib/system.webresource.0382b6b1.js +0 -1
@@ -1,8 +1,8 @@
1
- import { s as w, b as $, d as K, c as T, e as C, f as R, h as m, i as S, j as L, g as I, k as x, l as D, m as N, n as P } from "./system.fieldsecurity.9f9f73df.mjs";
2
- import { m as h, n as u } from "./chartbi.c3bc6adb.mjs";
3
- import { t as b } from "./messages.bc3bc0e8.mjs";
4
- import { a as v, e as B, f as F } from "./system.notice.b4247147.mjs";
5
- import { S as A, b as M, d as E, p as O, e as z, f as y } from "./system.account.868f96f9.mjs";
1
+ import { s as w, b as $, d as K, c as C, e as T, f as R, h as m, i as S, j as L, g as I, k as x, l as P, m as D, n as N } from "./system.fieldsecurity.6feb94c3.mjs";
2
+ import { m as h, n as u } from "./chartbi.b6818e8e.mjs";
3
+ import { t as b } from "./messages.7e418640.mjs";
4
+ import { a as v, e as B, f as F } from "./system.notice.bd18554e.mjs";
5
+ import { S as A, b as M, d as E, p as O, e as z, f as y } from "./system.account.64fbdaeb.mjs";
6
6
  const j = {
7
7
  data() {
8
8
  return {
@@ -20,25 +20,25 @@ const j = {
20
20
  slotType: "name",
21
21
  align: "left",
22
22
  fixed: !0,
23
+ width: "200",
23
24
  renderHeader: (s, ...e) => this.renderHeader(s, ...e, {
24
25
  effectType: "input"
25
- }),
26
- showOverflowTooltip: !0
26
+ })
27
27
  },
28
28
  {
29
29
  transKey: "gd.org.code",
30
30
  prop: "code",
31
31
  label: "\u552F\u4E00\u7F16\u7801",
32
32
  align: "left",
33
+ width: "200",
33
34
  renderHeader: (s, ...e) => this.renderHeader(s, ...e, {
34
35
  effectType: "input"
35
- }),
36
- showOverflowTooltip: !0
36
+ })
37
37
  },
38
38
  {
39
39
  transKey: "gd.org.sort",
40
40
  prop: "sort",
41
- width: "200",
41
+ width: "120",
42
42
  label: "\u6392\u5E8F",
43
43
  align: "left"
44
44
  },
@@ -47,7 +47,7 @@ const j = {
47
47
  prop: "remark",
48
48
  label: "\u5907\u6CE8",
49
49
  align: "left",
50
- showOverflowTooltip: !0
50
+ width: "260"
51
51
  }
52
52
  ],
53
53
  formColumns: [{
@@ -612,7 +612,7 @@ const ie = {
612
612
  this.findParent(this.menuTreeData, n, l);
613
613
  let r = [], d = [];
614
614
  l.forEach((o) => {
615
- this.checkedKeys.filter((g) => o.menuIds.includes(g)).length === o.menuIds.length && o.menuIds.length > 0 && !o.checked ? r.push(o.id) : d.push(o.id);
615
+ this.checkedKeys.filter((f) => o.menuIds.includes(f)).length === o.menuIds.length && o.menuIds.length > 0 && !o.checked ? r.push(o.id) : d.push(o.id);
616
616
  }), r.forEach((o) => {
617
617
  this.changeItem(!0, [o], !1);
618
618
  }), d.forEach((o) => {
@@ -634,7 +634,7 @@ const ie = {
634
634
  this.confirmLoading = !0, Promise.all([this.getMenuTree(), this.expandedMenuKeys(), this.getMenuList()]).then(async (s) => {
635
635
  let e = [], t = [];
636
636
  const i = (r) => (r = r.filter((d, o) => {
637
- const c = this.checkedKeys.filter((f) => d.id === f)[0];
637
+ const c = this.checkedKeys.filter((g) => d.id === g)[0];
638
638
  return d.open = !0, d.checked = d.type === 1 ? !!c : !1, d.isIndeterminate = !1, d.menusType = d.type, e.push(d.id), t.push(d), d.children && d.children.length > 0 && (d.children = i(d.children)), !0;
639
639
  }), r);
640
640
  let n = this.menuAll.filter((r) => !!this.systemMenuAll.filter((o) => o.id === r.id)[0]);
@@ -642,7 +642,7 @@ const ie = {
642
642
  let a = [];
643
643
  t.forEach((r, d) => {
644
644
  const o = this.getMenuIds(r);
645
- t[d].menuIds = o.arr, t[d].menuBtnIds = o.btn, !(this.checkedKeys.filter((g) => o.arr.includes(g)).length === o.arr.length) && o.arr.length > 0 && a.push(r.id);
645
+ t[d].menuIds = o.arr, t[d].menuBtnIds = o.btn, !(this.checkedKeys.filter((f) => o.arr.includes(f)).length === o.arr.length) && o.arr.length > 0 && a.push(r.id);
646
646
  }), this.list = t;
647
647
  const l = this.checkedKeys.filter((r) => e.includes(r)).filter((r) => !a.includes(r)).filter((r, d, o) => o.indexOf(r) === d);
648
648
  this.checkedKeys = l, this.allClose = this.checkedKeys.length === e.length && e.length > 0, this.menuTreeData = [...n], this.handleItem(), this.confirmLoading = !1;
@@ -1141,15 +1141,15 @@ const ue = {
1141
1141
  }
1142
1142
  }
1143
1143
  };
1144
- var ge = function() {
1144
+ var fe = function() {
1145
1145
  var e = this, t = e._self._c;
1146
1146
  return t("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "modal-append-to-body": !0, "append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(i) {
1147
1147
  e.visible = i;
1148
1148
  }, closed: e.closed } }, [t("template", { slot: "title" }, [t("gd-modal-title", { attrs: { title: e.$i18nt("gd.user.userAuthorization", "\u6388\u6743\u7528\u6237"), fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen } })], 1), t("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [e.visible ? t("UserFormDate", { ref: "userForm", attrs: { height: e.height, openMode: "components", openSelecteKeys: e.selectedRowKeys }, on: { onSelectChange: e.onSelectChange } }) : e._e()], 1)], 2);
1149
- }, fe = [], pe = /* @__PURE__ */ u(
1149
+ }, ge = [], pe = /* @__PURE__ */ u(
1150
1150
  ue,
1151
- ge,
1152
1151
  fe,
1152
+ ge,
1153
1153
  !1,
1154
1154
  null,
1155
1155
  "46b57430",
@@ -1160,6 +1160,7 @@ const me = pe.exports;
1160
1160
  const ye = {
1161
1161
  data() {
1162
1162
  return {
1163
+ defaultKey: [],
1163
1164
  buttons: [
1164
1165
  {
1165
1166
  displayName: "\u786E\u5B9A",
@@ -1173,7 +1174,7 @@ const ye = {
1173
1174
  visible: !1,
1174
1175
  confirmLoading: !1,
1175
1176
  fullscreen: !1,
1176
- width: "80%",
1177
+ width: "90%",
1177
1178
  selectedPath: "/",
1178
1179
  pathDialogVisible: !1,
1179
1180
  tempSelectedPath: "",
@@ -1328,9 +1329,7 @@ const ye = {
1328
1329
  };
1329
1330
  }).map(({ list: t, ...i }) => i);
1330
1331
  this.confirmLoading = !0, K(e).then((t) => {
1331
- t.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(
1332
- this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + t.message
1333
- ), this.confirmLoading = !1;
1332
+ t.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + t.message), this.confirmLoading = !1;
1334
1333
  });
1335
1334
  },
1336
1335
  edit() {
@@ -1341,17 +1340,15 @@ const ye = {
1341
1340
  ...i
1342
1341
  };
1343
1342
  }).map(({ list: t, ...i }) => i);
1344
- console.log(e), this.confirmLoading = !0, T(e).then((t) => {
1345
- t.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(
1346
- this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + t.message
1347
- ), this.confirmLoading = !1;
1343
+ this.confirmLoading = !0, C(e).then((t) => {
1344
+ t.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + t.message), this.confirmLoading = !1;
1348
1345
  });
1349
1346
  },
1350
1347
  open(s) {
1351
1348
  this.record = s, this.visible = !0, this.getallTree(), this.getDetail(s);
1352
1349
  },
1353
1350
  getDetail(s) {
1354
- C({ roleId: s.id }).then((e) => {
1351
+ T({ roleId: s.id }).then((e) => {
1355
1352
  if (e.code == 200 && (this.currentPermissions = [], this.$refs.elTreeRef && this.$refs.elTreeRef.setCheckedKeys([]), e.data.length > 0)) {
1356
1353
  this.id = e.data[0].id, this.currentPermissions = [];
1357
1354
  const t = e.data.map((n) => {
@@ -1385,7 +1382,8 @@ const ye = {
1385
1382
  if (s.code == 200) {
1386
1383
  this.restaurants = JSON.parse(JSON.stringify(s.data));
1387
1384
  const e = this.buildTree(JSON.parse(JSON.stringify(s.data)));
1388
- this.folderTree = e, this.selectedPath = "/" + s.data[0].name;
1385
+ let t = [];
1386
+ e[0] && e[0].children && t.push(e[0].id), this.defaultKey = t, this.folderTree = e, console.log(t), this.selectedPath = "/" + s.data[0].name;
1389
1387
  }
1390
1388
  });
1391
1389
  },
@@ -1407,7 +1405,6 @@ const ye = {
1407
1405
  this.pathDialogVisible = !0, this.tempSelectedPath = this.selectedPath;
1408
1406
  },
1409
1407
  delList(s) {
1410
- console.log(s);
1411
1408
  let e = this;
1412
1409
  this.$confirm(this.$i18nt("gd.https.delContent", "\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"), this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
1413
1410
  confirmButtonText: this.$i18nt("gd.https.delOk", "\u786E\u5B9A\u5220\u9664"),
@@ -1428,13 +1425,17 @@ const ye = {
1428
1425
  }
1429
1426
  i.confirmButtonLoading = !0, i.cancelButtonLoading = !0, i.showCancelButton = !1, s.id === 0 ? e.$message.success(e.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")) : m({
1430
1427
  ids: s.id
1431
- }).then((a) => {
1432
- i.confirmButtonLoading = !1, i.cancelButtonLoading = !1, i.showCancelButton = !0, a.success ? e.$message.success(e.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")) : e.$message.error(e.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + a.message);
1433
- }), n(), e.currentPermissions = e.currentPermissions.filter((a) => a.sysdocobjectid !== s.sysdocobjectid), e.currentPermissions.length == 0 && e.cardList.forEach((a) => {
1434
- Array.isArray(a.list) && a.list.forEach((l) => {
1435
- l.value = "";
1428
+ }).then((l) => {
1429
+ i.confirmButtonLoading = !1, i.cancelButtonLoading = !1, i.showCancelButton = !0, l.success ? e.$message.success(e.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")) : e.$message.error(e.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + l.message);
1430
+ }), n();
1431
+ let a = 0;
1432
+ for (let l = 0; l < e.currentPermissions.length; l++)
1433
+ e.currentPermissions[l].sysdocobjectid === s.sysdocobjectid && (a = l);
1434
+ console.log(a), e.currentPermissions = e.currentPermissions.filter((l) => l.sysdocobjectid !== s.sysdocobjectid), e.currentPermissions.length == 0 && e.cardList.forEach((l) => {
1435
+ Array.isArray(l.list) && l.list.forEach((r) => {
1436
+ r.value = "";
1436
1437
  });
1437
- }), e.cancelNodeCheck(s.sysdocobjectid);
1438
+ }), e.currentPermissions.length > 0 && e.currentPermissions[a - 1] ? this.handlePermissionClick(e.currentPermissions[a - 1]) : e.currentPermissions.length > 0 && e.currentPermissions[a] && this.handlePermissionClick(e.currentPermissions[a]), e.cancelNodeCheck(s.sysdocobjectid);
1438
1439
  }
1439
1440
  });
1440
1441
  },
@@ -1605,32 +1606,32 @@ const ye = {
1605
1606
  };
1606
1607
  var be = function() {
1607
1608
  var e = this, t = e._self._c;
1608
- return t("div", [t("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "modal-append-to-body": !0, "append-to-body": !1, top: "30px", "show-close": !1 }, on: { "update:visible": function(i) {
1609
+ return t("div", [t("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "modal-append-to-body": !0, "append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(i) {
1609
1610
  e.visible = i;
1610
- }, closed: e.closed } }, [t("template", { slot: "title" }, [t("gd-modal-title", { attrs: { title: e.$i18nt("gd.user.documentAuthorization", "\u6388\u6743\u6587\u6863"), fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen } })], 1), t("div", { staticClass: "main-layout" }, [t("div", { staticClass: "directory-tree-section" }, [t("div", { staticClass: "section-header" }, [e._v(e._s(e.$i18nt("gd.user.selectDirectory", "\u9009\u62E9\u76EE\u5F55")))]), t("el-tree", { ref: "elTreeRef", attrs: { "check-strictly": "", data: e.folderTree, "node-key": "id", "show-checkbox": "", props: e.treeProps }, on: { "check-change": e.handleDirectoryCheck, "node-click": e.handleNodeClick } })], 1), t("div", { staticStyle: { width: "100%" } }, [t("div", { staticClass: "preview-card" }, [t("div", { staticClass: "card-header" }, [t("span", [e._v(e._s(e.$i18nt("gd.user.permissionPreview", "\u6743\u9650\u9884\u89C8")))])]), t("div", { staticClass: "permission-tags" }, e._l(e.currentPermissions, function(i) {
1611
+ }, closed: e.closed } }, [t("template", { slot: "title" }, [t("gd-modal-title", { attrs: { title: e.$i18nt("gd.user.documentAuthorization", "\u6388\u6743\u6587\u6863"), fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen } })], 1), t("div", { staticClass: "main-layout" }, [t("div", { staticClass: "directory-tree-section" }, [t("div", { staticClass: "section-header" }, [e._v(e._s(e.$i18nt("gd.user.selectDirectory", "\u9009\u62E9\u76EE\u5F55")))]), t("div", { staticClass: "tree-list" }, [t("el-tree", { ref: "elTreeRef", attrs: { "check-strictly": "", data: e.folderTree, "node-key": "id", "default-expanded-keys": e.defaultKey, "show-checkbox": "", props: e.treeProps }, on: { "check-change": e.handleDirectoryCheck, "node-click": e.handleNodeClick } })], 1)]), t("div", { staticClass: "directory-list" }, [t("div", { staticClass: "preview-card" }, [t("el-alert", { attrs: { title: e.$i18nt("gd.user.permissionPreview", "\u6743\u9650\u9884\u89C8"), type: "info", "show-icon": "", effect: "dark", closable: !1 } }), e.currentPermissions.length > 0 ? t("div", { staticClass: "permission-tags" }, e._l(e.currentPermissions, function(i) {
1611
1612
  return t("div", { key: i.sysdocobjectid, staticClass: "permission-tags-item", class: { checked: i.ischeck }, on: { click: function(n) {
1612
1613
  return e.handlePermissionClick(i);
1613
- } } }, [e._v(" " + e._s(i.name) + " "), t("div", { staticClass: "permission-tags-item-content" }, e._l(i.list, function(n, a) {
1614
- return t("div", { key: a }, [t("span", [e._v(e._s(n.name))]), n.value == "1" ? t("el-tag", [e._v(e._s(e.$i18nt("gd.user.allow", "\u5141\u8BB8")))]) : e._e(), n.value == "2" ? t("el-tag", { attrs: { type: "danger" } }, [e._v(e._s(e.$i18nt("gd.user.refuse", "\u62D2\u7EDD")))]) : e._e()], 1);
1614
+ } } }, [t("div", { staticClass: "item-name" }, [e._v(e._s(i.name))]), t("div", { staticClass: "permission-tags-item-content" }, e._l(i.list, function(n, a) {
1615
+ return t("div", { key: a }, [t("span", [e._v(e._s(n.name))]), n.value == "1" ? t("el-tag", { attrs: { type: "success", effect: "dark", size: "mini" } }, [e._v(e._s(e.$i18nt("gd.user.allow", "\u5141\u8BB8")))]) : e._e(), n.value == "2" ? t("el-tag", { attrs: { type: "danger", effect: "dark", size: "mini" } }, [e._v(e._s(e.$i18nt("gd.user.refuse", "\u62D2\u7EDD")))]) : e._e()], 1);
1615
1616
  }), 0), t("i", { staticClass: "el-icon-close del-btn", on: { click: function(n) {
1616
1617
  return e.delList(i);
1617
1618
  } } })]);
1618
- }), 0)]), t("div", [t("div", { staticClass: "permission-section" }, [t("h3", [e._v(e._s(e.$i18nt("gd.user.setOperationPermissions", "\u8BBE\u7F6E\u64CD\u4F5C\u6743\u9650")))]), e._l(e.cardList, function(i, n) {
1619
+ }), 0) : t("div", { staticClass: "empty" }, [t("div", { staticClass: "empty-item" }, [t("div", { staticClass: "empty-icon" }, [t("i", { staticClass: "el-icon-receiving" })]), t("div", { staticClass: "empty-title" }, [t("span", [e._v(e._s(e.$i18nt("gd.echarts.noData", "\u6682\u65E0\u6570\u636E\u5C55\u793A")))])])])])], 1), t("div", { staticClass: "permission-section" }, [t("el-alert", { attrs: { title: e.$i18nt("gd.user.setOperationPermissions", "\u8BBE\u7F6E\u64CD\u4F5C\u6743\u9650"), type: "info", "show-icon": "", effect: "dark", closable: !1 } }), t("div", { staticClass: "kuang" }, e._l(e.cardList, function(i, n) {
1619
1620
  return t("div", { key: n }, [t("div", { staticClass: "clearfix", attrs: { slot: "header" }, slot: "header" }, [t("h4", [e._v(e._s(e.$i18nt(i.transkey, i.name)))])]), t("div", { staticClass: "permission-list" }, [t("div", { staticClass: "permission-category" }, e._l(i.list, function(a, l) {
1620
- return t("el-card", { key: l, staticClass: "permission-item", attrs: { shadow: "hover" } }, [t("div", { staticClass: "perm-info" }, [t("i", { staticClass: "gd-icons active-color", class: a.icon, staticStyle: { "font-size": "14px", "margin-right": "10px" } }), t("div", { staticClass: "perm-name" }, [e._v(e._s(e.$i18nt(`Dynamics.${a.transkey}`, a.name)) + " ")])]), t("div", { staticClass: "perm-actions" }, [t("el-radio-group", { nativeOn: { click: function(r) {
1621
+ return t("el-card", { key: l, staticClass: "permission-item", attrs: { shadow: "hover" } }, [t("div", { staticClass: "perm-info" }, [t("i", { staticClass: "gd-icons", class: a.icon, staticStyle: { "font-size": "14px", "margin-right": "6px" } }), t("div", { staticClass: "perm-name" }, [e._v(e._s(e.$i18nt(`Dynamics.${a.transkey}`, a.name)))])]), t("div", { staticClass: "perm-actions" }, [t("el-radio-group", { nativeOn: { click: function(r) {
1621
1622
  return e.handleReadMetaDataChange(r, a);
1622
1623
  } }, model: { value: a.value, callback: function(r) {
1623
1624
  e.$set(a, "value", r);
1624
- }, expression: "items.value" } }, [t("el-radio", { attrs: { label: "1" } }, [e._v(e._s(e.$i18nt("gd.user.allow", "\u5141\u8BB8")))]), t("el-radio", { attrs: { label: "2" } }, [e._v(e._s(e.$i18nt("gd.user.refuse", "\u62D2\u7EDD")))])], 1)], 1)]);
1625
+ }, expression: "items.value" } }, [t("el-radio", { attrs: { label: "1" } }, [t("span", { staticStyle: { color: "rgb(82, 196, 26)" } }, [e._v(e._s(e.$i18nt("gd.user.allow", "\u5141\u8BB8")))])]), t("el-radio", { attrs: { label: "2" } }, [t("span", { staticStyle: { color: "red" } }, [e._v(e._s(e.$i18nt("gd.user.refuse", "\u62D2\u7EDD")))])])], 1)], 1)]);
1625
1626
  }), 1)])]);
1626
- })], 2)])])])], 2)], 1);
1627
+ }), 0)], 1)])])], 2)], 1);
1627
1628
  }, ve = [], _e = /* @__PURE__ */ u(
1628
1629
  ye,
1629
1630
  be,
1630
1631
  ve,
1631
1632
  !1,
1632
1633
  null,
1633
- "daca70b3",
1634
+ "b1dc77ce",
1634
1635
  null,
1635
1636
  null
1636
1637
  );
@@ -1703,7 +1704,7 @@ const we = {
1703
1704
  this.findParent(this.menuTreeData, n, l);
1704
1705
  let r = [], d = [];
1705
1706
  l.forEach((o) => {
1706
- this.checkedKeys.filter((g) => o.menuIds.includes(g)).length === o.menuIds.length && o.menuIds.length > 0 && !o.checked ? r.push(o.id) : d.push(o.id);
1707
+ this.checkedKeys.filter((f) => o.menuIds.includes(f)).length === o.menuIds.length && o.menuIds.length > 0 && !o.checked ? r.push(o.id) : d.push(o.id);
1707
1708
  }), r.forEach((o) => {
1708
1709
  this.changeItem(!0, [o], !1);
1709
1710
  }), d.forEach((o) => {
@@ -1786,7 +1787,7 @@ var $e = function() {
1786
1787
  }, closed: e.closed } }, [t("template", { slot: "title" }, [t("gd-modal-title", { attrs: { title: e.$i18nt("gd.user.dataRole", "\u6388\u6743\u6570\u636E"), buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen } })], 1), t("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticStyle: { "min-height": "400px" } }, [e.visible ? t("LayoutItem", { attrs: { record: e.menuTreeData, checkedKeys: e.checkedKeys }, on: { open: e.openItem, change: e.changeItem, checkedBtn: e.checkedItemBtn } }) : e._e()], 1), t("template", { slot: "footer" }, [t("div", { staticClass: "btoms" }, [t("el-checkbox", { attrs: { disabled: e.confirmLoading, indeterminate: e.isIndeterminate }, on: { change: e.changeAll }, model: { value: e.allClose, callback: function(i) {
1787
1788
  e.allClose = i;
1788
1789
  }, expression: "allClose" } }, [e._v(" " + e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")) + " ")])], 1)])], 2)], 1);
1789
- }, Ke = [], Te = /* @__PURE__ */ u(
1790
+ }, Ke = [], Ce = /* @__PURE__ */ u(
1790
1791
  we,
1791
1792
  $e,
1792
1793
  Ke,
@@ -1796,7 +1797,7 @@ var $e = function() {
1796
1797
  null,
1797
1798
  null
1798
1799
  );
1799
- const Ce = Te.exports;
1800
+ const Te = Ce.exports;
1800
1801
  const Re = {
1801
1802
  name: "GdRole",
1802
1803
  props: {
@@ -1828,7 +1829,7 @@ const Re = {
1828
1829
  isDoc: ""
1829
1830
  };
1830
1831
  },
1831
- components: { RoleGrant: Y, RoleMenu: le, RoleMenuViewForm: Ce, UserAuthorization: me, DocumentAuthorization: ke },
1832
+ components: { RoleGrant: Y, RoleMenu: le, RoleMenuViewForm: Te, UserAuthorization: me, DocumentAuthorization: ke },
1832
1833
  computed: {
1833
1834
  getTableButtons() {
1834
1835
  return this.tableButtons.filter((s) => s.functionName === "grantRoleAppMenu" ? !!this.appsId : s.functionName === "documentAuthorizationMenu" ? this.isDoc == 1 : !0);
@@ -1998,7 +1999,7 @@ const Re = {
1998
1999
  },
1999
2000
  sbumit({ data: s, record: e, btn: t }, i, n) {
2000
2001
  this.formLoading = !0;
2001
- let a = e ? this.transKey === "gd.https.copy" ? D : N : P;
2002
+ let a = e ? this.transKey === "gd.https.copy" ? P : D : N;
2002
2003
  const l = this.transKey !== "gd.https.edit" ? Object.assign(s, { sysappsid: window.$systemInfo.id }) : s;
2003
2004
  a(l).then((r) => {
2004
2005
  r.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), n(), this.refresh()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + r.message), this.formLoading = !1;
@@ -0,0 +1 @@
1
+ "use strict";const h=require("./system.fieldsecurity.920adca4.js"),c=require("./chartbi.b5b6fdab.js"),b=require("./messages.1346558e.js"),y=require("./system.notice.ff62c06a.js"),g=require("./system.account.7c43a95e.js"),k={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.user.roleName",prop:"name",label:"\u89D2\u8272\u540D\u79F0",type:"slot",slotType:"name",align:"left",fixed:!0,width:"200",renderHeader:(s,...e)=>this.renderHeader(s,...e,{effectType:"input"})},{transKey:"gd.org.code",prop:"code",label:"\u552F\u4E00\u7F16\u7801",align:"left",width:"200",renderHeader:(s,...e)=>this.renderHeader(s,...e,{effectType:"input"})},{transKey:"gd.org.sort",prop:"sort",width:"120",label:"\u6392\u5E8F",align:"left"},{transKey:"gd.org.remark",prop:"remark",label:"\u5907\u6CE8",align:"left",width:"260"}],formColumns:[{transKey:"gd.user.roleName",effectType:"input",prop:"name",label:"\u89D2\u8272\u540D\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.org.code",prop:"code",effectType:"input",label:"\u552F\u4E00\u7F16\u7801",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.org.sort",prop:"sort",effectType:"inputnumber",label:"\u6392\u5E8F",defaultValue:100,placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",type:"number"}]},{transKey:"gd.org.remark",effectType:"textarea",prop:"remark",label:"\u5907\u6CE8",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[],autosize:{minRows:4,maxRows:6}}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysRole:add"},{displayName:"\u590D\u5236\u89D2\u8272",functionName:"copy",show:!0,transKey:"gd.user.copyRole",icon:"el-icon-plus",name:"sysRole:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysRole:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysRole:delete"},{displayName:"\u6388\u6743\u7528\u6237",functionName:"userAuthorizationMenu",show:!0,transKey:"gd.user.userAuthorization",icon:"el-icon-user",name:"sysRole:userMenu"},{displayName:"\u6388\u6743\u6587\u6863",functionName:"documentAuthorizationMenu",show:!0,transKey:"gd.user.documentAuthorization",icon:"el-icon-document",name:"sysRole:documentMenu"},{displayName:"\u6388\u6743\u83DC\u5355",functionName:"grantRoleMenu",show:!0,transKey:"gd.user.menuRole",icon:"el-icon-monitor",name:"sysRole:grantMenu"},{displayName:"\u6388\u6743APP\u83DC\u5355",functionName:"grantRoleAppMenu",show:!0,transKey:"gd.user.menuRoleApp",icon:"el-icon-mobile-phone",name:"sysRole:grantMenu"},{displayName:"\u6388\u6743\u6570\u636E",functionName:"grantRoleGrant",show:!0,transKey:"gd.user.dataRole",icon:"el-icon-tickets",name:"sysRole:grantData"},{displayName:"\u6388\u6743\u89C6\u56FE/\u8868\u5355",functionName:"grantRoleVF",show:!0,transKey:"gd.user.menuRolevf",icon:"el-icon-setting",name:"sysRole:grantMenu"}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],tableQueries:[{transKey:"gd.user.roleName",prop:"name",label:"\u89D2\u8272\u540D\u79F0",effectType:"input",rules:[]},{transKey:"gd.org.code",prop:"code",label:"\u552F\u4E00\u7F16\u7801",effectType:"input",rules:[]}]}}};const w={data(){return{defaultProps:{children:"children",label:"title"},buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"800px",orgTreeData:[],checkedKeys:[]}},computed:{...c.mapGetters(["screenHeight","tableLists"])},methods:{handleSubmit(){const s=this.$refs.tree.getCheckedKeys();this.$emit("ok",Object.assign({...this.record},{checkedKeys:s})),this.closed()},getOrgData(){this.confirmLoading=!0,y.getOrgTree().then(s=>{s.success&&(this.orgTreeData=s.data,this.confirmLoading=!1)})},open(s){this.record=s,this.checkedKeys=s.checkedKeys,this.visible=!0,this.getOrgData()},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()}}};var $=function(){var e=this,t=e._self._c;return t("div",[t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"append-to-body":!0,"modal-append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.rangeRole","\u6388\u6743\u8303\u56F4"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?t("el-tree",{ref:"tree",attrs:{data:e.orgTreeData,"show-checkbox":"","node-key":"id","default-expand-all":"","default-checked-keys":e.checkedKeys,props:e.defaultProps}}):e._e()],1)],2)],1)},K=[],C=c.normalizeComponent(w,$,K,!1,null,"2b164094",null,null);const T=C.exports;const R={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"94%",loadData:[],submitData:{},loadSoData:s=>(this.confirmLoading=!0,new Promise((e,t)=>{this.confirmLoading=!1,e({pageNo:1,pageSize:500,totalRows:0,rows:this.loadData})})),columns:[{transKey:"gd.btn.entity",prop:"sysCodeGenName",label:"\u5B9E\u4F53",align:"left",type:"slot",slotType:"sysCodeGenName",width:120},{transKey:"gd.btn.query",prop:"getgrantd",label:"\u67E5\u8BE2",align:"left",type:"slot",slotType:"getgrantd",width:270,showTooltip:!1},{transKey:"gd.btn.add",prop:"addgrantd",label:"\u65B0\u589E",align:"left",type:"slot",slotType:"addgrantd",width:270,showTooltip:!1},{transKey:"gd.btn.edit",prop:"editgrantd",label:"\u7F16\u8F91",align:"left",type:"slot",slotType:"editgrantd",width:270,showTooltip:!1},{transKey:"gd.btn.del",prop:"delgrantd",label:"\u5220\u9664",align:"left",type:"slot",slotType:"delgrantd",width:270,showTooltip:!1},{transKey:"gd.relation.assignment",prop:"allocationgrantd",label:"\u5206\u6D3E",align:"left",type:"slot",slotType:"allocationgrantd",width:270,showTooltip:!1},{transKey:"gd.btn.share",prop:"sharegrantd",label:"\u5171\u4EAB",align:"left",type:"slot",slotType:"sharegrantd",width:270,showTooltip:!1}],currentList:{}}},components:{RoleScope:T},computed:{height(){return this.screenHeight-(this.fullscreen?120:310)},...c.mapGetters(["primaryColor","screenHeight","tableLists","tableSize","tablePageSize"])},methods:{handleSubmit(){this.confirmLoading=!0;let s=this.$refs.table.tableData;s.map(e=>(e.addgrant=e.addgrantd.length>0?e.addgrantd.join(","):null,e.delgrant=e.delgrantd.length>0?e.delgrantd.join(","):null,e.editgrant=e.editgrantd.length>0?e.editgrantd.join(","):null,e.getgrant=e.getgrantd.length>0?e.getgrantd.join(","):null,e.sharegrant=e.sharegrantd.length>0?e.sharegrantd.join(","):null,e.allocationgrant=e.allocationgrantd.length>0?e.allocationgrantd.join(","):null,e)),y.saveOrgDetail(Object.assign({...this.submitData},{grants:s})).then(e=>{this.confirmLoading=!1,e.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.closed()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+e.message)})},setRoleScop(s){this.confirmLoading=!0;const e=this.$refs.table.tableData;e[s.index][s.name]=[...s.checkedKeys].join(","),this.loadData=[...e],this.refresh(),this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F"))},openList(s,e,t){const i=this.$refs.table.tableData,n=`${s.prop.replace("grantd","")}custom`,a=i[t][n],l=a?a.split(",").map(Number):[];this.$refs.roleScope.open({index:t,item:s,checkedKeys:l,data:e,name:n})},getUserControlData(){this.confirmLoading=!0,y.getOrgDetail({roleId:this.record.id}).then(s=>{s.success?(s.data.grants.map(e=>(e.addgrantd=e.addgrant?e.addgrant.split(","):[],e.delgrantd=e.delgrant?e.delgrant.split(","):[],e.editgrantd=e.editgrant?e.editgrant.split(","):[],e.getgrantd=e.getgrant?e.getgrant.split(","):[],e.sharegrantd=e.sharegrant?e.sharegrant.split(","):[],e.allocationgrantd=e.allocationgrant?e.allocationgrant.split(","):[],e)),this.loadData=s.data.grants,this.submitData=s.data,this.$nextTick(()=>{setTimeout(()=>{this.refresh(),this.confirmLoading=!0},1e3),setTimeout(()=>{this.confirmLoading=!1},1200)})):(this.$message.error(s.message),this.confirmLoading=!1)})},open(s){this.record=s,this.visible=!0,this.getUserControlData()},closed(){this.fullscreen=!1,this.visible=!1},refresh(s=!0){this.$refs.table?this.$refs.table.refresh(s):console.log("err:\u89C6\u56FE\u672A\u52A0\u8F7D\uFF0C\u8BF7\u7B49\u5F85\u52A0\u8F7D\u5B8C\u6210\uFF01")},getDictionary(s){return this.$options.filters.dictData(s)},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()}}};var S=function(){var e=this,t=e._self._c;return t("div",[t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"append-to-body":!0,"modal-append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.dataRole","\u6388\u6743\u6570\u636E"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}],staticStyle:{"margin-top":"-12px"}},[e.visible?t("gd-tables",{ref:"table",attrs:{dataSource:e.loadSoData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.columns,height:e.height,filtering:!1,initialLoading:!1,showPagination:!1,rowKey:"sysCodeGenId",disabledRefresh:"",disabledColumnSettings:""},scopedSlots:e._u([e._l(e.columns,function(i){return{key:i.prop,fn:function({column:n,row:a,index:l}){return[i.prop==="sysCodeGenName"?t("div",[e._v(" "+e._s(e.$i18nt(`Dynamics.${a.transkey}`,a.syscodegenname))+" ")]):t("div",{staticClass:"grant-select"},[t("el-select",{staticStyle:{flex:"1"},attrs:{placeholder:e.$i18nt("gd.xlsxImport.mapFieldsTip","\u8BF7\u9009\u62E9\u6620\u5C04\u5B57\u6BB5"),filterable:"",clearable:"",multiple:""},model:{value:a[i.prop],callback:function(r){e.$set(a,i.prop,r)},expression:"row[item.prop]"}},[e._l(e.getDictionary("data_scope_type"),function(r){return[t("el-option",{attrs:{label:e.$i18nt(`Dynamics.${r.transkey}`,r.name),value:r.code}})]})],2),a[i.prop].includes("5")?t("el-button",{staticClass:"active-color flex-center",attrs:{type:"text"},on:{click:function(r){return e.openList(i,a,l)}}},[e._v(" "+e._s(e.$i18nt("gd.btn.view","\u67E5\u770B"))+" ")]):e._e()],1)]}}})],null,!0)}):e._e()],1)],2),t("RoleScope",{ref:"roleScope",on:{ok:e.setRoleScop}})],1)},L=[],I=c.normalizeComponent(R,S,L,!1,null,"39b91bb5",null,null);const x=I.exports;const D={name:"LayoutItem",props:{record:{type:Array,default:()=>[]},checkedKeys:{type:Array,default:()=>[]}},data(){return{}},computed:{fadeColord(){return this.fadeColor(this.primaryColor,.1)},menusType(){return this.record[0]?this.record[0].menusType:0},...c.mapGetters(["primaryColor"])},methods:{hasAll(s){return!(this.checkedKeys.filter(t=>s.menuBtnIds.includes(t)).length>=s.menuBtnIds.length)},checkedBtn(s,e){this.$emit("checkedBtn",s,e)},change(s,e){this.$emit("change",s,e)},open(s){this.$emit("open",s)},checked(s){return!!this.checkedKeys.filter(t=>t===s.id)[0]},fadeColor(s,e){let t=parseInt(s.substring(1,3),16),i=parseInt(s.substring(3,5),16),n=parseInt(s.substring(5,7),16);return`rgba(${t},${i},${n},${e})`}}};var P=function(){var e=this,t=e._self._c;return t("div",{style:{"--fadecolor":e.fadeColord}},[e._l(e.record,function(i){return[t("div",{staticClass:"list-item"},[e.menusType===0?t("i",{class:i.open?"el-icon-caret-bottom":"el-icon-caret-right",on:{click:function(n){return e.open(i)}}}):e._e(),e.menusType!==2?t("div",{staticClass:"item-name"},[t("el-checkbox",{attrs:{indeterminate:i.isIndeterminate},on:{change:function(n){return e.change(n,[i.id])}},model:{value:i.checked,callback:function(n){e.$set(i,"checked",n)},expression:"item.checked"}},[i.iconClass?t("i",{staticClass:"gd-icons",class:i.iconClass,staticStyle:{"font-size":"15px"}}):e._e(),e._v(" "+e._s(e.$i18nt(`Dynamics.${i.transkey}`,i.title))+" ")]),i.children&&i.children.length>0&&e.menusType===1?t("el-button",{staticStyle:{"margin-left":"12px",padding:"5px 15px"},attrs:{size:"mini"}},[e.hasAll(i)?t("span",{on:{click:function(n){return e.checkedBtn(i,1)}}},[e._v(" "+e._s(e.$i18nt("gd.btn.selectAll","\u5168\u9009"))+" ")]):t("span",{on:{click:function(n){return e.checkedBtn(i,0)}}},[e._v(" "+e._s(e.$i18nt("gd.btn.cancel","\u53D6\u6D88"))+" ")])]):e._e()],1):e._e(),t("div",{staticClass:"item-data"},[i.children&&i.children.length>0&&i.children[0].menusType===2?t("div",{staticClass:"item-data-list"},[e._l(i.children,function(n){return[t("div",{staticClass:"item-name item-named",on:{click:function(a){return e.change(!n.checked,[n.id])}}},[n.checked?t("i",{staticClass:"gd-icons gd-icon-quanxuan active-color"}):t("div",{staticClass:"item-named-kuang"}),t("div",{staticClass:"item-named-title",class:n.checked?"active-color":""},[e._v(" "+e._s(e.$i18nt(`Dynamics.${n.transkey}`,n.title))+" ")])])]})],2):e._e()])]),i.children&&i.children.length>0&&i.children[0].menusType!==2?t("div",{staticClass:"list-more"},[i.open?t("LayoutItem",{attrs:{record:i.children,checkedKeys:e.checkedKeys},on:{open:e.open,change:e.change,checkedBtn:e.checkedBtn}}):e._e()],1):e._e()]})],2)},N=[],B=c.normalizeComponent(D,P,N,!1,null,"53cbc9f1",null,null);const v=B.exports;const F={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"94%",menuTreeData:[],checkedKeys:[],list:[],allClose:!1,menuAll:[],systemMenuAll:[],allCheckedKeys:[],appsId:""}},computed:{isIndeterminate(){return this.allClose?!1:this.checkedKeys.length>0},...c.mapGetters(["screenHeight","tableLists"])},components:{LayoutItem:v},methods:{handleSubmit(){this.confirmLoading=!0,h.sysRoleGrantMenu({id:this.record.id,grantmenuidlist:this.checkedKeys}).then(s=>{s.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok"),this.closed()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+s.message),this.confirmLoading=!1})},checkedItemBtn(s,e){let t=[...this.checkedKeys].filter(i=>!s.menuBtnIds.includes(i));e===1&&(t=t.concat(s.menuBtnIds)),this.checkedKeys=[...t],this.handleItem()},openItem(s){let e=[...this.menuTreeData];const t=i=>(i=i.filter((n,a)=>(n.id===s.id&&(n.open=!n.open),n.children&&n.children.length>0&&(n.children=t(n.children)),!0)),i);t(e),this.menuTreeData=[...e]},changeItem(s,e,t=!0){let i=[...this.checkedKeys];this.checkedKeys.filter(o=>e.includes(o))[0];const n=this.list.filter(o=>e.includes(o.id))[0],a=t&&n?n.menuIds:[];if(s?i=this.checkedKeys.concat(e).concat(a):i=this.checkedKeys.filter(o=>!e.includes(o)).filter(o=>!a.includes(o)),this.checkedKeys=[...i],this.handleItem(),n.menusType===2)return;let l=[];this.findParent(this.menuTreeData,n,l);let r=[],d=[];l.forEach(o=>{this.checkedKeys.filter(f=>o.menuIds.includes(f)).length===o.menuIds.length&&o.menuIds.length>0&&!o.checked?r.push(o.id):d.push(o.id)}),r.forEach(o=>{this.changeItem(!0,[o],!1)}),d.forEach(o=>{this.changeItem(!1,[o],!1)})},handleItem(){let s=[...this.menuTreeData];const e=t=>(t=t.filter((i,n)=>{const a=this.checkedKeys.filter(l=>i.menuIds.includes(l));return this.checkedKeys.includes(i.id)?(i.checked=!0,i.isIndeterminate=!1):(i.checked=!1,i.isIndeterminate=a.length>0&&i.menuIds.length>0),i.children&&i.children.length>0&&(i.children=e(i.children)),!0}),t);e(s),this.menuTreeData=[...s],this.allClose=this.checkedKeys.length===this.allCheckedKeys.length&&this.allCheckedKeys.length>0},changeAll(s){s?this.checkedKeys=[...this.allCheckedKeys]:this.checkedKeys=[],this.handleItem()},init(){this.confirmLoading=!0,Promise.all([this.getMenuTree(),this.expandedMenuKeys(),this.getMenuList()]).then(async s=>{let e=[],t=[];const i=r=>(r=r.filter((d,o)=>{const u=this.checkedKeys.filter(p=>d.id===p)[0];return d.open=!0,d.checked=d.type===1?!!u:!1,d.isIndeterminate=!1,d.menusType=d.type,e.push(d.id),t.push(d),d.children&&d.children.length>0&&(d.children=i(d.children)),!0}),r);let n=this.menuAll.filter(r=>!!this.systemMenuAll.filter(o=>o.id===r.id)[0]);await i(n),this.allCheckedKeys=e;let a=[];t.forEach((r,d)=>{const o=this.getMenuIds(r);t[d].menuIds=o.arr,t[d].menuBtnIds=o.btn,!(this.checkedKeys.filter(f=>o.arr.includes(f)).length===o.arr.length)&&o.arr.length>0&&a.push(r.id)}),this.list=t;const l=this.checkedKeys.filter(r=>e.includes(r)).filter(r=>!a.includes(r)).filter((r,d,o)=>o.indexOf(r)===d);this.checkedKeys=l,this.allClose=this.checkedKeys.length===e.length&&e.length>0,this.menuTreeData=[...n],this.handleItem(),this.confirmLoading=!1})},open(s,e){this.record=s,this.appsId=e||window.$systemInfo.id,this.visible=!0,this.init()},getMenuTree(){return g.SysMenuTreeForGrant({roleId:this.record.id}).then(s=>(s.code===200&&(this.menuAll=s.data),s))},expandedMenuKeys(){return h.sysRoleOwnMenu({id:this.record.id}).then(s=>(s.code===200&&(this.checkedKeys=s.data),s))},getMenuList(){let s={AppsId:this.appsId};return g.sysMenuListByAppsId(s).then(e=>(e.code===200&&(this.systemMenuAll=e.data),e))},getMenuIds(s){let e=[],t=[];const i=n=>(n=n.filter((a,l)=>(a.menusType!==2?e.push(a.id):t.push(a.id),a.children&&a.children.length>0&&(a.children=i(a.children)),!0)),n);return s.children&&i(s.children),{arr:e,btn:t}},findParent(s,e,t){for(let i of s)if(i.id===e.parentId||i.children&&i.children.length>0&&this.findParent(i.children,e,t))return t.unshift(i),!0;return!1},closed(){this.fullscreen=!1,this.visible=!1,this.menuTreeData=[],this.checkedKeys=[]},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()}}};var A=function(){var e=this,t=e._self._c;return t("div",[t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"append-to-body":!0,"modal-append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.dataRole","\u6388\u6743\u6570\u636E"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}],staticStyle:{"min-height":"400px"}},[e.visible?t("LayoutItem",{attrs:{record:e.menuTreeData,checkedKeys:e.checkedKeys},on:{open:e.openItem,change:e.changeItem,checkedBtn:e.checkedItemBtn}}):e._e()],1),t("template",{slot:"footer"},[t("div",{staticClass:"btoms"},[t("el-checkbox",{attrs:{disabled:e.confirmLoading,indeterminate:e.isIndeterminate},on:{change:e.changeAll},model:{value:e.allClose,callback:function(i){e.allClose=i},expression:"allClose"}},[e._v(" "+e._s(e.$i18nt("gd.btn.selectAll","\u5168\u9009"))+" ")])],1)])],2)],1)},M=[],E=c.normalizeComponent(F,A,M,!1,null,"d82ecaae",null,null);const O=E.exports;const z={name:"GdUserRole",props:{height:{type:Number,default:100},openSelecteKeys:{type:Array,default:()=>[]},openMode:{type:String,default:"page"}},mixins:[b.tablesFilter],data(){return{transKey:"gd.btn.add",formLoading:!1,currentNode:null,loading:!0,orgTree:[],selectedRowKeys:[],selectedRows:[],queryParam:{},defaultProps:{children:"children",label:"title",value:"value"},defaultExpandedKeys:"",loadData:s=>g.getUserManage({roleId:this.openSelecteKeys[0]}).then(e=>(this.getRowId(e.data),{pageNo:1,pageSize:1e3,totalRows:0,rows:e.data})),disableBtn:[],fileList:[],needLoad:!1,infoData:{},isSendEmail:"",isSendEmailed:"",tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.user.name",prop:"name",label:"\u59D3\u540D",type:"slot",slotType:"name",align:"left",showOverflowTooltip:!0},{transKey:"gd.user.nickname",prop:"nickname",label:"\u6635\u79F0",align:"left",type:"slot",slotType:"nickname",showOverflowTooltip:!0},{transKey:"gd.user.sex",prop:"sex",label:"\u6027\u522B",align:"left",type:"slot",slotType:"sex",showOverflowTooltip:!0},{transKey:"gd.user.organization",prop:"orgname",label:"\u6240\u5C5E\u673A\u6784",align:"left",type:"slot",slotType:"orgname",showOverflowTooltip:!0},{transKey:"gd.user.status",prop:"status",label:"\u72B6\u6001",align:"left",type:"slot",slotType:"status",showOverflowTooltip:!0}],formColumnsuser:[{transKey:"gd.user.account",effectType:"input",prop:"account",label:"\u8D26\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",min:2}]},{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.sex",prop:"gender",effectType:"radio",label:"\u6027\u522B",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",dictTypeCode:"gender",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.birthday",prop:"birthday",effectType:"date",label:"\u751F\u65E5",placeholder:"\u8BF7\u8F93\u5165",valueFormat:"yyyy-MM-dd",placeholderTransKey:"gd.placeholder.select",rules:[]},{transKey:"gd.user.phone",effectType:"input",prop:"phone",label:"\u624B\u673A\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.email",effectType:"input",prop:"email",label:"\u90AE\u7BB1",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"},{type:"email",message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u90AE\u7BB1\u53F7!",transKey:"gd.account.emailTip"}]},{transKey:"gd.user.nickname",prop:"nickname",effectType:"input",label:"\u6635\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.user.tel",prop:"tel",effectType:"input",label:"\u7535\u8BDD",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.org.displayName",prop:"orgid",effectType:"selectTree",label:"\u6240\u5C5E\u673A\u6784",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",treeOptions:[],rules:[{required:!0,message:"\u8BF7\u9009\u62E9",transKey:"gd.placeholder.select",trigger:"change"}]},{transKey:"gd.user.PSDNeverExpire",prop:"psdneverexpire",effectType:"switch",label:"\u5BC6\u7801\u6C38\u4E0D\u8FC7\u671F",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysRole:add"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysRole:delete"}],disabledRowId:[],sysCodeGenName:"sys_user"}},components:{},computed:{initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getQueryParam(){let s=new Map;for(let e in this.queryParam)s.set(e==="statecodes"?"searchctatus":e,this.queryParam[e]);return Object.fromEntries(s)},getFormColumns(){return this.formColumnsuser.filter(e=>(e.prop==="orgid"&&(e.treeOptions=[...this.orgTree]),!0))},getTableButtons(){return this.tableButtons.filter(s=>(s.show=!this.disableBtn.includes(s.displayName),!0))},getHeight(){return this.height},styled(){return`height:${this.height+76}px`},...c.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{getRowId(s){let e=[];s.filter(t=>!this.disabledRowId.includes(t.id)).forEach(t=>{e.push(t.id)}),this.disabledRowId=this.disabledRowId.concat(e)},saveQueries(s){this.queryParam={...s},this.refresh()},refresh(){this.$refs.table.refresh()},getOrgTree(){y.getOrgTree({}).then(s=>{if(s.code===200){const e=t=>(t=t.filter((i,n)=>(i.value=String(i.value),i.children&&i.children.length>0&&(i.children=e(i.children)),!0)),t);this.orgTree=e(s.data)}this.loading=!1})},handleNodeClick(s){this.queryParam.orgId===s.id?(delete this.queryParam.orgId,this.$nextTick(()=>{setTimeout(()=>{this.$refs.tree.setCurrentKey(null)},0)})):this.queryParam=Object.assign({...this.queryParam},{orgId:s.id}),this.refresh()},handleOk(){this.$refs.table.refresh()},onSelectChange(s,e){this.selectedRowKeys=s,this.selectedRows=e},doEvent(s){let e=s.item.functionName;this[e]&&this[e]()},lookupSeled(s){if(s.fkData.length===0){this.$refs.engineSearch.closed();return}this.$refs.engineSearch.confirmLoading=!0,g.postbindUsersToRole({roleId:this.openSelecteKeys[0],userIdList:s.data}).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$refs.engineSearch.closed(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+e.message),this.$refs.engineSearch.confirmLoading=!1})},add(){this.$refs.engineSearch.open({fkEntityName:this.sysCodeGenName,val:[],effectType:"participants",isRelevance:!0})},del(){let s=this;if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(e,t,i)=>{if(e!=="confirm"){i();return}t.confirmButtonLoading=!0,t.cancelButtonLoading=!0,t.showCancelButton=!1,g.postunbindUsersFromRole({roleId:s.openSelecteKeys[0],userIdList:s.selectedRowKeys}).then(n=>{n.success?(s.$message.success(s.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")),s.disabledRowId=s.disabledRowId.filter(a=>!s.selectedRows.filter(r=>r.id===a)[0]),t.confirmButtonLoading=!1,t.cancelButtonLoading=!1,t.showCancelButton=!0,i(),s.refresh()):s.$message.error(s.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+n.message)})}})}},created(){}};var j=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view",staticStyle:{display:"flex",background:"rgb(245, 245, 245)"}},[t("div",{staticClass:"page-view-list"},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,showPagination:!1,selectedRowKeys:e.selectedRowKeys,height:e.height,initialLoading:!1},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorr"},[t("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"name",fn:function({column:i,row:n}){return[t("span",{staticClass:"active-color",staticStyle:{cursor:"pointer"}},[e._v(" "+e._s(n.name)+" ")])]}},{key:"nickname",fn:function({column:i,row:n}){return[t("span",{staticStyle:{cursor:"pointer"}},[e._v(" "+e._s(n.nickname)+" ")])]}},{key:"orgname",fn:function({column:i,row:n}){return[t("span",{staticStyle:{cursor:"pointer"}},[e._v(" "+e._s(n.orgname)+" ")])]}},{key:"sex",fn:function({column:i,row:n}){return[t("span",[e._v(" "+e._s(e._f("dictType")("gender",n.gender))+" ")])]}},{key:"status",fn:function({column:i,row:n}){return[t("span",[e._v(" "+e._s(e._f("dictType")("state_code",n.statecodes))+" ")])]}}])}),t("gd-search",{ref:"engineSearch",attrs:{appendToBody:!0,disabledRowId:e.disabledRowId},on:{lookupSeled:e.lookupSeled}})],1)])},q=[],G=c.normalizeComponent(z,j,q,!1,null,"e9dd56ab",null,null);const _=G.exports;const V={data(){return{buttons:[],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedRowKeys:[]}},components:{UserFormDate:_},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...c.mapGetters(["screenHeight"])},methods:{handleSubmit(){this.closed(),this.$emit("ok")},open(s){this.record=s,this.visible=!0,this.selectedRowKeys=[s.id],this.$nextTick(()=>{setTimeout(()=>{this.$refs.userForm.refresh()},0)})},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},onSelectChange(s){this.selectedRowKeys=s},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()}}};var H=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.userAuthorization","\u6388\u6743\u7528\u6237"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?t("UserFormDate",{ref:"userForm",attrs:{height:e.height,openMode:"components",openSelecteKeys:e.selectedRowKeys},on:{onSelectChange:e.onSelectChange}}):e._e()],1)],2)},U=[],J=c.normalizeComponent(V,H,U,!1,null,"46b57430",null,null);const Q=J.exports;const W={data(){return{defaultKey:[],buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedPath:"/",pathDialogVisible:!1,tempSelectedPath:"",folderTree:[],treeProps:{label:"name",children:"children"},permissions:{ReadMetaData:"allow",ManagePrem:"deny"},cardList:[{name:"\u901A\u7528\u6743\u9650",transkey:"gd.user.generalPermissions",id:"1",list:[{value:"",name:"\u67E5\u770B",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_readmetadata_Name",code:"readmetadata",icon:"el-icon-view"},{value:"",name:"\u91CD\u547D\u540D",code:"rename",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_rename_Name",icon:"el-icon-edit"},{value:"",name:"\u5220\u9664",code:"delete",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_delete_Name",icon:"el-icon-delete-solid"},{value:"",name:"\u7BA1\u7406\u6743\u9650",code:"manageprem",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_manageprem_Name",icon:"el-icon-user-solid"},{value:"",name:"\u79FB\u52A8",code:"move",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_move_Name",icon:"el-icon-rank"}]},{name:"\u6587\u4EF6\u5939\u7279\u6B8A\u6743\u9650",transkey:"gd.user.folderSpecialPermissions",id:"2",list:[{value:"",name:"\u521B\u5EFA\u6587\u4EF6",code:"createfile",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_createfile_Name",icon:"el-icon-document-add"},{value:"",name:"\u521B\u5EFA\u5B50\u6587\u4EF6\u5939",code:"createsubfolder",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_createsubfolder_Name",icon:"el-icon-folder-add"}]},{name:"\u6587\u4EF6\u7279\u6B8A\u6743\u9650",transkey:"gd.user.fileSpecialPermissions",id:"3",list:[{value:"",name:"\u4E0B\u8F7D",code:"download",transkey:"Sys_Tables_sys_doc_role_premissions_Fields_download_Name",icon:"el-icon-download"}]}],restaurants:[],objectId:"0",currentPermissions:[],id:""}},components:{UserFormDate:_},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...c.mapGetters(["screenHeight"])},methods:{querySearch(s,e){},createFilter(s){return e=>e.name.toLowerCase().indexOf(s.toLowerCase())===0},handleSelect(s){console.log(s)},keyuprefresh(){},buildTree(s){const e=s.find(a=>a.parentid===null);if(!e)throw new Error("No root node found (parentid: null)");const t={};s.forEach(a=>{t[a.id]={name:a.name,id:a.id,children:[]}}),s.forEach(a=>{if(a.parentid===null)return;const l=t[a.parentid];l?l.children.some(r=>r.id===a.id)||l.children.push(t[a.id]):t[e.id].children.push(t[a.id])});function i(a){a.children&&a.children.length>0&&(a.children.sort((l,r)=>l.name.localeCompare(r.name)),a.children.forEach(l=>i(l)))}const n={name:e.name,id:e.id,children:t[e.id].children};return i(n),[n]},handleSubmit(){this.id!=""?this.edit():this.add()},add(){const e=this.currentPermissions.map(t=>{const i=t.list.reduce((n,a)=>(n[a.code]=a.value,n),{});return{...t,...i}}).map(({list:t,...i})=>i);this.confirmLoading=!0,h.docObjectsRolesGrantDocsPermission(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok"),this.closed()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+t.message),this.confirmLoading=!1})},edit(){const e=this.currentPermissions.map(t=>{const i=t.list.reduce((n,a)=>(n[a.code]=a.value,n),{});return{...t,...i}}).map(({list:t,...i})=>i);this.confirmLoading=!0,h.docObjectsRolesBatchEdit(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok"),this.closed()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+t.message),this.confirmLoading=!1})},open(s){this.record=s,this.visible=!0,this.getallTree(),this.getDetail(s)},getDetail(s){h.sysDocObjectsRolesGetByRoleId({roleId:s.id}).then(e=>{if(e.code==200&&(this.currentPermissions=[],this.$refs.elTreeRef&&this.$refs.elTreeRef.setCheckedKeys([]),e.data.length>0)){this.id=e.data[0].id,this.currentPermissions=[];const t=e.data.map(n=>{const a=[{name:"\u67E5\u770B",code:"readmetadata",value:n.readmetadata},{name:"\u91CD\u547D\u540D",code:"rename",value:n.rename},{name:"\u5220\u9664",code:"delete",value:n.delete},{name:"\u7BA1\u7406\u6743\u9650",code:"manageprem",value:n.manageprem},{name:"\u79FB\u52A8",code:"move",value:n.move},{name:"\u521B\u5EFA\u6587\u4EF6",code:"createfile",value:n.createfile},{name:"\u521B\u5EFA\u5B50\u6587\u4EF6\u5939",code:"createsubfolder",value:n.createsubfolder},{name:"\u4E0B\u8F7D",code:"download",value:n.download}];return{id:n.id,name:n.name,ischeck:!1,sysdocobjectid:n.sysdocobjectid,sysroleid:n.sysroleid,list:a}});this.currentPermissions=t,this.handlePermissionClick(this.currentPermissions[0]);const i=t.map(n=>n.sysdocobjectid);this.$refs.elTreeRef&&this.$refs.elTreeRef.setCheckedKeys(i)}})},getallTree(){h.sysDocObjectsAllDocList().then(s=>{if(s.code==200){this.restaurants=JSON.parse(JSON.stringify(s.data));const e=this.buildTree(JSON.parse(JSON.stringify(s.data)));let t=[];e[0]&&e[0].children&&t.push(e[0].id),this.defaultKey=t,this.folderTree=e,console.log(t),this.selectedPath="/"+s.data[0].name}})},closed(){this.cardList.forEach(s=>{Array.isArray(s.list)&&s.list.forEach(e=>{e.value=""})}),this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()},openPathDialog(){this.pathDialogVisible=!0,this.tempSelectedPath=this.selectedPath},delList(s){let e=this;this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,i,n)=>{if(t!=="confirm"){n();return}i.confirmButtonLoading=!0,i.cancelButtonLoading=!0,i.showCancelButton=!1,s.id===0?e.$message.success(e.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):h.docObjectsRolesDel({ids:s.id}).then(l=>{i.confirmButtonLoading=!1,i.cancelButtonLoading=!1,i.showCancelButton=!0,l.success?e.$message.success(e.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):e.$message.error(e.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+l.message)}),n();let a=0;for(let l=0;l<e.currentPermissions.length;l++)e.currentPermissions[l].sysdocobjectid===s.sysdocobjectid&&(a=l);console.log(a),e.currentPermissions=e.currentPermissions.filter(l=>l.sysdocobjectid!==s.sysdocobjectid),e.currentPermissions.length==0&&e.cardList.forEach(l=>{Array.isArray(l.list)&&l.list.forEach(r=>{r.value=""})}),e.currentPermissions.length>0&&e.currentPermissions[a-1]?this.handlePermissionClick(e.currentPermissions[a-1]):e.currentPermissions.length>0&&e.currentPermissions[a]&&this.handlePermissionClick(e.currentPermissions[a]),e.cancelNodeCheck(s.sysdocobjectid)}})},cancelNodeCheck(s){const e=this.$refs.elTreeRef;e&&e.setChecked(s,!1)},handlecheck(s){console.log(s)},handleDirectoryCheck(s,e){let t=s.name;if(e){const a=this.restaurants.find(r=>r.id===s.id);let l=a?a.parentid:"";(l!=""||l==0)&&this.restaurants.forEach(r=>{r.id==l&&(t=r.name+"/"+s.name)})}const i=s.id,n=JSON.parse(JSON.stringify(this.currentPermissions)).filter(a=>a.sysdocobjectid===s.id);if(e&&n.length===0){const a={sysdocobjectid:i,sysroleid:this.record.id,name:t,ischeck:!0,id:0,list:[{name:"\u67E5\u770B",code:"readmetadata",value:""},{name:"\u91CD\u547D\u540D",code:"rename",value:""},{name:"\u5220\u9664",code:"delete",value:""},{name:"\u7BA1\u7406\u6743\u9650",code:"manageprem",value:""},{name:"\u79FB\u52A8",code:"move",value:""},{name:"\u521B\u5EFA\u6587\u4EF6",code:"createfile",value:""},{name:"\u521B\u5EFA\u5B50\u6587\u4EF6\u5939",code:"createsubfolder",value:""},{name:"\u4E0B\u8F7D",code:"download",value:""}]};this.currentPermissions.push(a),this.currentPermissions.forEach(l=>{l.ischeck=!1,l.sysdocobjectid===i&&(l.ischeck=!0)}),this.cardList.forEach(l=>{Array.isArray(l.list)&&l.list.forEach(r=>{r.value=""})})}else if(!e&&n.length>0&&this.currentPermissions.length>0){let a=this;this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(l,r,d)=>{if(l!=="confirm"){d(),setTimeout(()=>{this.$nextTick(()=>{this.$refs.elTreeRef.setChecked(s.id,!0)})});return}r.confirmButtonLoading=!0,r.cancelButtonLoading=!0,r.showCancelButton=!1,n[0].id===0?a.$message.success(a.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):h.docObjectsRolesDel({ids:n[0].id}).then(o=>{r.confirmButtonLoading=!1,r.cancelButtonLoading=!1,r.showCancelButton=!0,o.success?a.$message.success(a.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):a.$message.error(a.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+o.message)}),d(),this.nextclickdel(i)}})}},nextclickdel(s){this.currentPermissions=this.currentPermissions.filter(t=>t.sysdocobjectid!==s),this.currentPermissions.forEach(t=>{t.ischeck=!1}),this.currentPermissions[this.currentPermissions.length-1].ischeck=!0;const e={};this.currentPermissions[this.currentPermissions.length-1].list.forEach(t=>{e[t.name]=t.value}),this.cardList.forEach(t=>{Array.isArray(t.list)&&t.list.forEach(i=>{i.value=""})}),this.cardList.forEach(t=>{Array.isArray(t.list)&&t.list.forEach(i=>{const n=e[i.name];n!==void 0&&n!==""&&n!==null&&(i.value=n.toString())})})},handleNodeClick(s,e){this.objectId=s.id;let t=[],i=e;for(;i;)t.unshift(i.data.name),i=i.parent;this.tempSelectedPath=""+t.join("/")},handlePermissionClick(s){this.currentPermissions.forEach(t=>{t.ischeck=!1}),s.ischeck=!0;const e={};s.list.forEach(t=>{e[t.name]=t.value}),this.cardList.forEach(t=>{Array.isArray(t.list)&&t.list.forEach(i=>{i.value=""})}),this.cardList.forEach(t=>{Array.isArray(t.list)&&t.list.forEach(i=>{const n=e[i.name];n!=null&&(i.value=n.toString())})})},confirmPath(){this.selectedPath=this.tempSelectedPath,this.pathDialogVisible=!1},handleReadMetaDataChange(s,e){s.target.tagName==="INPUT"&&s.target.type==="radio"&&(e.value===""?e.value=s.target.value:e.value=null,setTimeout(()=>{if(this.currentPermissions.length>0){const t=this.currentPermissions.find(i=>i.ischeck);if(t){const i=t.list.find(n=>n.name===e.name);i&&(i.value=e.value)}}},10))}}};var X=function(){var e=this,t=e._self._c;return t("div",[t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.documentAuthorization","\u6388\u6743\u6587\u6863"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{staticClass:"main-layout"},[t("div",{staticClass:"directory-tree-section"},[t("div",{staticClass:"section-header"},[e._v(e._s(e.$i18nt("gd.user.selectDirectory","\u9009\u62E9\u76EE\u5F55")))]),t("div",{staticClass:"tree-list"},[t("el-tree",{ref:"elTreeRef",attrs:{"check-strictly":"",data:e.folderTree,"node-key":"id","default-expanded-keys":e.defaultKey,"show-checkbox":"",props:e.treeProps},on:{"check-change":e.handleDirectoryCheck,"node-click":e.handleNodeClick}})],1)]),t("div",{staticClass:"directory-list"},[t("div",{staticClass:"preview-card"},[t("el-alert",{attrs:{title:e.$i18nt("gd.user.permissionPreview","\u6743\u9650\u9884\u89C8"),type:"info","show-icon":"",effect:"dark",closable:!1}}),e.currentPermissions.length>0?t("div",{staticClass:"permission-tags"},e._l(e.currentPermissions,function(i){return t("div",{key:i.sysdocobjectid,staticClass:"permission-tags-item",class:{checked:i.ischeck},on:{click:function(n){return e.handlePermissionClick(i)}}},[t("div",{staticClass:"item-name"},[e._v(e._s(i.name))]),t("div",{staticClass:"permission-tags-item-content"},e._l(i.list,function(n,a){return t("div",{key:a},[t("span",[e._v(e._s(n.name))]),n.value=="1"?t("el-tag",{attrs:{type:"success",effect:"dark",size:"mini"}},[e._v(e._s(e.$i18nt("gd.user.allow","\u5141\u8BB8")))]):e._e(),n.value=="2"?t("el-tag",{attrs:{type:"danger",effect:"dark",size:"mini"}},[e._v(e._s(e.$i18nt("gd.user.refuse","\u62D2\u7EDD")))]):e._e()],1)}),0),t("i",{staticClass:"el-icon-close del-btn",on:{click:function(n){return e.delList(i)}}})])}),0):t("div",{staticClass:"empty"},[t("div",{staticClass:"empty-item"},[t("div",{staticClass:"empty-icon"},[t("i",{staticClass:"el-icon-receiving"})]),t("div",{staticClass:"empty-title"},[t("span",[e._v(e._s(e.$i18nt("gd.echarts.noData","\u6682\u65E0\u6570\u636E\u5C55\u793A")))])])])])],1),t("div",{staticClass:"permission-section"},[t("el-alert",{attrs:{title:e.$i18nt("gd.user.setOperationPermissions","\u8BBE\u7F6E\u64CD\u4F5C\u6743\u9650"),type:"info","show-icon":"",effect:"dark",closable:!1}}),t("div",{staticClass:"kuang"},e._l(e.cardList,function(i,n){return t("div",{key:n},[t("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[t("h4",[e._v(e._s(e.$i18nt(i.transkey,i.name)))])]),t("div",{staticClass:"permission-list"},[t("div",{staticClass:"permission-category"},e._l(i.list,function(a,l){return t("el-card",{key:l,staticClass:"permission-item",attrs:{shadow:"hover"}},[t("div",{staticClass:"perm-info"},[t("i",{staticClass:"gd-icons",class:a.icon,staticStyle:{"font-size":"14px","margin-right":"6px"}}),t("div",{staticClass:"perm-name"},[e._v(e._s(e.$i18nt(`Dynamics.${a.transkey}`,a.name)))])]),t("div",{staticClass:"perm-actions"},[t("el-radio-group",{nativeOn:{click:function(r){return e.handleReadMetaDataChange(r,a)}},model:{value:a.value,callback:function(r){e.$set(a,"value",r)},expression:"items.value"}},[t("el-radio",{attrs:{label:"1"}},[t("span",{staticStyle:{color:"rgb(82, 196, 26)"}},[e._v(e._s(e.$i18nt("gd.user.allow","\u5141\u8BB8")))])]),t("el-radio",{attrs:{label:"2"}},[t("span",{staticStyle:{color:"red"}},[e._v(e._s(e.$i18nt("gd.user.refuse","\u62D2\u7EDD")))])])],1)],1)])}),1)])])}),0)],1)])])],2)],1)},Y=[],Z=c.normalizeComponent(W,X,Y,!1,null,"b1dc77ce",null,null);const ee=Z.exports;const te={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"94%",menuTreeData:[],menuTreeDatad:[],checkedKeys:[],list:[],allClose:!1,menuAll:[],systemMenuAll:[],allCheckedKeys:[]}},computed:{isIndeterminate(){return this.allClose?!1:this.checkedKeys.length>0},...c.mapGetters(["screenHeight","tableLists"])},components:{LayoutItem:v},methods:{async handleSubmit(){const s=e=>(e=e.filter((t,i)=>{const n=this.checkedKeys.filter(a=>t.id===a)[0];return t.type=n?1:0,t.formlist&&t.formlist.length>0&&(t.formlist=s(t.formlist)),t.viewlist&&t.viewlist.length>0&&(t.viewlist=s(t.viewlist)),t.btnlist&&t.btnlist.length>0&&(t.btnlist=s(t.btnlist)),!0}),e);this.confirmLoading=!0,await s(this.menuAll),h.sysRoleRoleBindViewOnBtn({roleid:this.record.id,list:this.menuAll}).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok"),this.closed()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+e.message),this.confirmLoading=!1})},checkedItemBtn(s,e){let t=[...this.checkedKeys].filter(i=>!s.menuBtnIds.includes(i));e===1&&(t=t.concat(s.menuBtnIds)),this.checkedKeys=[...t],this.handleItem()},openItem(s){let e=[...this.menuTreeData];const t=i=>(i=i.filter((n,a)=>(n.id===s.id&&(n.open=!n.open),n.children&&n.children.length>0&&(n.children=t(n.children)),!0)),i);t(e),this.menuTreeData=[...e]},changeItem(s,e,t=!0){let i=[...this.checkedKeys];this.checkedKeys.filter(o=>e.includes(o))[0];const n=this.list.filter(o=>e.includes(o.id))[0],a=t&&n?n.menuIds:[];if(s?i=this.checkedKeys.concat(e).concat(a):i=this.checkedKeys.filter(o=>!e.includes(o)).filter(o=>!a.includes(o)),this.checkedKeys=[...i],this.handleItem(),n.menusType===2)return;let l=[];this.findParent(this.menuTreeData,n,l);let r=[],d=[];l.forEach(o=>{this.checkedKeys.filter(f=>o.menuIds.includes(f)).length===o.menuIds.length&&o.menuIds.length>0&&!o.checked?r.push(o.id):d.push(o.id)}),r.forEach(o=>{this.changeItem(!0,[o],!1)}),d.forEach(o=>{this.changeItem(!1,[o],!1)})},handleItem(){let s=[...this.menuTreeData];const e=t=>(t=t.filter((i,n)=>{const a=this.checkedKeys.filter(l=>i.menuIds.includes(l));return this.checkedKeys.includes(i.id)?(i.checked=!0,i.isIndeterminate=!1):(i.checked=!1,i.isIndeterminate=a.length>0&&i.menuIds.length>0),i.children&&i.children.length>0&&(i.children=e(i.children)),!0}),t);e(s),this.menuTreeData=[...s],this.allClose=this.checkedKeys.length===this.allCheckedKeys.length&&this.allCheckedKeys.length>0},changeAll(s){s?this.checkedKeys=[...this.allCheckedKeys]:this.checkedKeys=[],this.handleItem()},init(){this.confirmLoading=!0,Promise.all([this.getList()]).then(async s=>{this.confirmLoading=!1;let e=JSON.parse(JSON.stringify(this.menuTreeDatad)),t=[];const i=a=>(a=a.filter((l,r)=>{const d=this.checkedKeys.filter(o=>l.id===o)[0];return l.open=!0,l.checked=l.menusType===1?!!d:!1,l.isIndeterminate=!1,t.push(l),l.children&&l.children.length>0&&(l.children=i(l.children)),!0}),a);await i(e);let n=[];t.forEach((a,l)=>{const r=this.getMenuIds(a);t[l].menuIds=r.arr,t[l].menuBtnIds=r.btn,!(this.checkedKeys.filter(u=>r.arr.includes(u)).length===r.arr.length)&&r.arr.length>0&&n.push(a.id)}),this.list=t,this.allClose=this.checkedKeys.length===this.allCheckedKeys.length&&this.allCheckedKeys.length>0,this.menuTreeData=[...e],this.handleItem(),console.log(this.menuAll,"123")})},getList(){return h.sysRoleViewOnBtnList({roleId:this.record.id}).then(s=>{if(s.code===200){let e=[],t=[];const i=(a,l)=>(a=a.filter((r,d)=>{r.parentId=l,r.open=!0,r.checked=!1,r.isIndeterminate=!1,r.transkey=r.transkey?r.transkey:null,r.title=r.name,r.menusType=r.formlist&&r.viewlist?0:r.btnlist?1:2,t.push(r.id),r.type===1&&e.push(r.id);let o=[];return r.viewlist&&r.viewlist.length>0&&(r.viewlist.map(u=>(u.iconClass="gd-icon-shitumoshi",u)),o=o.concat(r.viewlist)),r.formlist&&r.formlist.length>0&&(r.formlist.map(u=>(u.iconClass="gd-icon-biaodanmoshi",u)),o=o.concat(r.formlist)),r.btnlist&&r.btnlist.length>0&&(o=o.concat(r.btnlist)),o.length>0&&(r.children=i(o,r.id)),!0}),a);this.menuAll=s.data.list;let n=JSON.parse(JSON.stringify(this.menuAll));i(n,0),this.checkedKeys=e,this.allCheckedKeys=t,this.menuTreeDatad=[...n]}return s})},getMenuIds(s){let e=[],t=[];const i=n=>(n=n.filter((a,l)=>(a.menusType!==2?e.push(a.id):t.push(a.id),a.children&&a.children.length>0&&(a.children=i(a.children)),!0)),n);return s.children&&i(s.children),{arr:e,btn:t}},findParent(s,e,t){for(let i of s)if(i.id===e.parentId||i.children&&i.children.length>0&&this.findParent(i.children,e,t))return t.unshift(i),!0;return!1},open(s){this.record=s,this.visible=!0,this.init()},closed(){this.fullscreen=!1,this.visible=!1,this.menuTreeData=[],this.checkedKeys=[]},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(s){const e=s.item.functionName;this[e]&&this[e]()}}};var se=function(){var e=this,t=e._self._c;return t("div",[t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"append-to-body":!0,"modal-append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.dataRole","\u6388\u6743\u6570\u636E"),buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}],staticStyle:{"min-height":"400px"}},[e.visible?t("LayoutItem",{attrs:{record:e.menuTreeData,checkedKeys:e.checkedKeys},on:{open:e.openItem,change:e.changeItem,checkedBtn:e.checkedItemBtn}}):e._e()],1),t("template",{slot:"footer"},[t("div",{staticClass:"btoms"},[t("el-checkbox",{attrs:{disabled:e.confirmLoading,indeterminate:e.isIndeterminate},on:{change:e.changeAll},model:{value:e.allClose,callback:function(i){e.allClose=i},expression:"allClose"}},[e._v(" "+e._s(e.$i18nt("gd.btn.selectAll","\u5168\u9009"))+" ")])],1)])],2)],1)},ie=[],ne=c.normalizeComponent(te,se,ie,!1,null,"e6593396",null,null);const ae=ne.exports;const re={name:"GdRole",props:{height:{type:Number,default:100},openMode:{type:String,default:"page"},openSelecteKeys:{type:Array,default:()=>[]}},mixins:[b.tablesFilter,k],data(){return{appsId:"",transKey:"gd.btn.add",formLoading:!1,loading:!0,selectedRowKeys:[],selectedRows:[],queryParam:{},allRowData:[],loadData:s=>(this.selectedKeep&&(this.selectedRowKeys=[...this.openSelecteKeys]),h.getRolePage(Object.assign(s,this.queryParam,{sysAppsId:window.$systemInfo.id})).then(e=>(this.allRowData=e.data,e.data))),isDoc:""}},components:{RoleGrant:x,RoleMenu:O,RoleMenuViewForm:ae,UserAuthorization:Q,DocumentAuthorization:ee},computed:{getTableButtons(){return this.tableButtons.filter(s=>s.functionName==="grantRoleAppMenu"?!!this.appsId:s.functionName==="documentAuthorizationMenu"?this.isDoc==1:!0)},initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getFormColumns(){return this.formColumns.filter(s=>(s.prop==="code"&&(s.disabled=this.transKey!=="gd.btn.add"),!(this.transKey==="gd.https.copy"&&s.prop==="code")))},getHeight(){return this.height},...c.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{getConfigInfo(){let s={code:"GDS_Enable_Doc_Premissions"};g.getConfigInfoByCode(s).then(e=>{e.code===200&&(this.isDoc=e.data.value)})},getAppId(){g.getConfigInfoByCode({code:"App_Id"}).then(s=>{s.code===200&&(this.appsId=s.data?s.data.value:"")})},documentAuthorizationMenu(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.documentAuthorization.open(this.selectedRows[0])},userAuthorizationMenu(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.userAuthorization.open(this.selectedRows[0])},grantRoleMenu(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.roleMenu.open(this.selectedRows[0])},grantRoleAppMenu(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.roleMenu.open(this.selectedRows[0],this.appsId)},grantRoleGrant(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.roleGrant.open(this.selectedRows[0])},grantRoleVF(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.roleMenuViewForm.open(this.selectedRows[0])},saveQueries(s){this.queryParam={...s},this.refresh()},refresh(){this.$refs.table.refresh()},editForm(s){this.transKey="gd.btn.edit",this.$refs.editForm.open(s)},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(s,e,t)=>{this.delHand(s,e,t)}})},delHand(s,e,t){if(s!=="confirm"){t();return}let i=[];this.selectedRows.forEach(n=>{let a=h.sysRoleDelete(n).then(l=>l);i.push(a)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(i).then(n=>{const a=n.filter(l=>!l.success);a.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+a[0].message),t(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(){this.transKey="gd.btn.add",this.$refs.editForm.open(null)},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},copy(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.transKey="gd.https.copy",this.$refs.editForm.open(Object.assign({...this.selectedRows[0]},{roleId:this.selectedRows[0].id}))},sbumit({data:s,record:e,btn:t},i,n){this.formLoading=!0;let a=e?this.transKey==="gd.https.copy"?h.sysRoleCopyRole:h.sysRoleEdit:h.sysRoleAddV2;const l=this.transKey!=="gd.https.edit"?Object.assign(s,{sysappsid:window.$systemInfo.id}):s;a(l).then(r=>{r.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),n(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+r.message),this.formLoading=!1})},onSelectChange(s,e){this.selectedRowKeys=s,this.selectedRows=e,this.$emit("onSelectChange",s,e,this.allRowData)},doEvent(s){let e=s.item.functionName;this[e]&&this[e]()}},created(){this.getAppId(),this.getConfigInfo()}};var le=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view"},[t("div",{staticClass:"page-view-list",staticStyle:{padding:"0px"}},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0,selectedKeep:e.selectedKeep,initialLoading:e.initialLoading},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"name",fn:function({column:i,row:n}){return[t("gd-tooltip",{attrs:{rowKey:"name",row:n,highlight:""},on:{click:e.editForm}})]}},{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorl"},[t("el-input",{staticClass:"table-operator-input",attrs:{placeholder:e.$i18nt("gd.user.roleName","\u89D2\u8272\u540D"),clearable:""},nativeOn:{keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.refresh.apply(null,arguments)}},model:{value:e.queryParam.name,callback:function(i){e.$set(e.queryParam,"name",i)},expression:"queryParam.name"}}),t("div",{staticClass:"table-operator-search",on:{click:e.refresh}},[t("i",{staticClass:"el-input__icon el-icon-search"})])],1),t("div",{staticClass:"gd-table-operatorr"},[e.openMode==="page"?t("gd-btn-list",{attrs:{sysViewButtons:e.getTableButtons},on:{functionName:e.doEvent}}):e._e()],1)])]},proxy:!0},{key:"filtering",fn:function({colse:i,visible:n}){return[t("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.getHeight,queryParam:e.queryParam,colse:i,visible:n},on:{save:e.saveQueries}})]}}])})],1),t("gd-edit-form",{ref:"editForm",attrs:{formItemWidth:"90%",loading:e.formLoading,transKey:e.transKey,buttons:e.formButtons,columns:e.getFormColumns,labelPosition:e.labelPosition,formMode:e.formMode},on:{sbumit:e.sbumit}}),t("RoleGrant",{ref:"roleGrant",on:{ok:e.refresh}}),t("RoleMenu",{ref:"roleMenu",on:{ok:e.refresh}}),t("RoleMenuViewForm",{ref:"roleMenuViewForm",on:{ok:e.refresh}}),t("UserAuthorization",{ref:"userAuthorization",on:{ok:e.refresh}}),t("DocumentAuthorization",{ref:"documentAuthorization",on:{ok:e.refresh}})],1)},oe=[],de=c.normalizeComponent(re,le,oe,!1,null,"00f39bc6",null,null);const m=de.exports;m.install=function(s){s.component(m.name,m)};exports.GDpackage=m;
@@ -1,5 +1,5 @@
1
- import { n as o, m as d } from "./chartbi.c3bc6adb.mjs";
2
- import { f as c, t as u } from "./messages.bc3bc0e8.mjs";
1
+ import { n as o, m as d } from "./chartbi.b6818e8e.mjs";
2
+ import { f as c, t as u } from "./messages.7e418640.mjs";
3
3
  function p(a) {
4
4
  return window.axios({
5
5
  url: "/SysNumberRules/page",
@@ -1 +1 @@
1
- "use strict";const o=require("./chartbi.5eded588.js"),d=require("./messages.fa3d97b5.js");function c(a){return window.axios({url:"/SysNumberRules/page",method:"get",params:a})}function u(a){return window.axios({url:"/sysNumberRules/add",method:"post",data:a})}function p(a){return window.axios({url:"/sysNumberRules/edit",method:"post",data:a})}function m(a){return window.axios({url:"/sysNumberRules/delete",method:"post",data:a})}const g={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.msg.sendRecord.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",fixed:!0,showOverflowTooltip:!0},{transKey:"gd.process.tableSort",prop:"sysCodeGenId",label:"\u8868\u540D\u79F0",type:"slot",slotType:"sysCodeGenId",align:"left"},{transKey:"gd.process.tableSort",prop:"columnid",label:"\u5B57\u6BB5",type:"slot",slotType:"columnid",align:"left"},{transKey:"gd.process.tableSort",prop:"nextseqno",label:"\u4E0B\u4E00\u6D41\u6C34\u53F7",align:"left"},{transKey:"gd.flow.state",prop:"statecodes",label:"\u72B6\u6001",type:"slot",slotType:"statecodes",align:"left"}],formColumns:[{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.msg.sendRecord.msgTemplate",effectType:"selectFkMultiple",prop:"syscodegenid",label:"\u7F16\u53F7\u8868",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",fkEntityName:"sys_code_gen",disabled:!1,multiple:!1,rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysSumberrules:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysSumberrules:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysSumberrules:delete"}],tableQueries:[{transKey:"gd.org.name",prop:"name",label:"\u540D\u79F0",effectType:"input",rules:[]}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}]}}};const f={props:{modalAppendToBody:{type:Boolean,default:!0},appendToBody:{type:Boolean,default:!0}},data(){return{confirmLoading:!1,visible:!1,fullScreen:!1,title:"",width:"50%",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],rules:{name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}],prefixtype:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}],nextseqno:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}]},ruleFormData:{id:"",name:"",prefixtype:"",prefix:"",dateformat:"",seqtype:"",seqrange:"",seqlength:void 0,postfixtype:"",postfix:"",nextseqno:"",separatorch:"",syscodegenid:"",columnid:""},dataList:[],columnList:[],disabled:!0,type:1}},methods:{lookup(){this.disabled},open(a){this.visible=!0,this.fullScreen=!1,this.title=a?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.type=a?2:1,a&&this.getSetData(a)},getSetData(a){let e={id:a.id,name:a.name,prefixtype:a.prefixtype.toString(),prefix:a.prefix,dateformat:a.dateformat||a.dateformat==0?a.dateformat.toString():"",seqtype:a.seqtype||a.seqtype==0?a.seqtype.toString():"",seqrange:a.seqrange?a.seqrange.toString():"",seqlength:a.seqlength,postfixtype:a.postfixtype||a.postfixtype==0?a.postfixtype.toString():"",postfix:a.postfix,nextseqno:a.nextseqno?a.nextseqno.toString():"",separatorch:a.separatorch||a.separatorch==0?a.separatorch.toString():"",syscodegenid:a.syscodegen?a.syscodegenid:"",columnid:a.syscodegenconfig?a.columnid:""};this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData=e},0)}),this.getFkDada(a)},getFkDada(a){let e=[];if(a.syscodegenid){let t=this.searchData({id:a.syscodegenid,fkEntityName:"sys_code_gen"},"syscodegenid");e.push(t)}if(a.columnid){let t=this.searchData({id:a.columnid,fkEntityName:"sys_code_gen_config"},"columnid");e.push(t)}Promise.all(e).then(t=>{t.forEach(s=>{s.prop=="syscodegenid"&&(this.dataList=s.res.data?s.res.data:[]),s.prop=="columnid"&&(this.columnList=s.res.data?s.res.data:[])})})},searchData(a,e){return d.baseFkList(a).then(t=>({res:t,data:a,prop:e}))},handleSubmit(){this.$refs.ruleForm.validate(a=>{if(a){let e={...this.ruleFormData};this.type==1?this.add(e):this.edit(e)}})},add(a){this.confirmLoading=!0,delete a.id,u(a).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.addSucc","\u65B0\u589E\u6210\u529F")),this.$emit("ok"),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.addFail","\u65B0\u589E\u5931\u8D25: ")+e.message)}).finally(e=>{this.confirmLoading=!1})},edit(a){this.confirmLoading=!0,p(a).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.editSucc","\u7F16\u8F91\u6210\u529F")),this.$emit("ok"),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.editFail","\u7F16\u8F91\u5931\u8D25: ")+e.message)}).finally(e=>{this.confirmLoading=!1})},getDictionary(a){return this.$options.filters.dictData(a)},toggleFullscreen(){this.fullScreen=!this.fullScreen},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.$refs.ruleForm.resetFields(),this.ruleFormData={name:"",prefixtype:"",prefix:"",dateformat:"",seqtype:"",seqrange:"",seqlength:void 0,postfixtype:"",postfix:"",nextseqno:"",separatorch:"",syscodegenid:"",columnid:""}},doEvent(a){let e=a.item.functionName;this[e]&&this[e]()}}};var h=function(){var e=this,t=e._self._c;return t("el-dialog",{class:e.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:e.width,visible:e.visible,fullscreen:e.fullScreen,footer:null,top:"80px","modal-append-to-body":e.modalAppendToBody,"append-to-body":e.appendToBody,"close-on-click-modal":!1,"show-close":!1},on:{"update:visible":function(s){e.visible=s},closed:e.handleCancel}},[t("gd-modal-title",{attrs:{slot:"title",title:e.title,fullscreen:e.fullScreen,buttons:e.sysViewButtons,confirmLoading:e.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen},slot:"title"}),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[t("div",{class:e.fullScreen?"modal-bodyq":"modal-body"},[t("el-form",{ref:"ruleForm",attrs:{rules:e.rules,model:e.ruleFormData,"label-width":"100px"},nativeOn:{submit:function(s){s.preventDefault()}}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.name","\u540D\u79F0"),prop:"name"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.name,callback:function(s){e.$set(e.ruleFormData,"name",s)},expression:"ruleFormData.name"}})],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.prefixType","\u524D\u7F00\u7C7B\u578B"),prop:"prefixtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.prefixtype,callback:function(s){e.$set(e.ruleFormData,"prefixtype",s)},expression:"ruleFormData.prefixtype"}},e._l(e.getDictionary("prefix_type"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.prefix","\u524D\u7F00"),prop:"prefix"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.prefix,callback:function(s){e.$set(e.ruleFormData,"prefix",s)},expression:"ruleFormData.prefix"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.dateFormat","\u65E5\u671F\u683C\u5F0F"),prop:"dateformat"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.dateformat,callback:function(s){e.$set(e.ruleFormData,"dateformat",s)},expression:"ruleFormData.dateformat"}},e._l(e.getDictionary("dateformat"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqType","\u6D41\u6C34\u53F7\u7C7B\u578B"),prop:"seqtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.seqtype,callback:function(s){e.$set(e.ruleFormData,"seqtype",s)},expression:"ruleFormData.seqtype"}},e._l(e.getDictionary("seqtype"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqRange","\u6D41\u6C34\u53F7\u8303\u56F4"),prop:"seqrange"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.seqrange,callback:function(s){e.$set(e.ruleFormData,"seqrange",s)},expression:"ruleFormData.seqrange"}},e._l(e.getDictionary("seqrange"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqLength","\u6D41\u6C34\u53F7\u957F\u5EA6"),prop:"seqlength"}},[t("el-input-number",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.input"),"controls-position":"right",min:0,max:10},model:{value:e.ruleFormData.seqlength,callback:function(s){e.$set(e.ruleFormData,"seqlength",s)},expression:"ruleFormData.seqlength"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.postfixType","\u540E\u7F00\u7C7B\u578B"),prop:"postfixtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.postfixtype,callback:function(s){e.$set(e.ruleFormData,"postfixtype",s)},expression:"ruleFormData.postfixtype"}},e._l(e.getDictionary("postfix_type"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.postfix","\u540E\u7F00"),prop:"postfix"}},[t("el-input",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.input")},model:{value:e.ruleFormData.postfix,callback:function(s){e.$set(e.ruleFormData,"postfix",s)},expression:"ruleFormData.postfix"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.nextSeqNo","\u4E0B\u4E00\u6D41\u6C34\u53F7"),prop:"nextseqno"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.nextseqno,callback:function(s){e.$set(e.ruleFormData,"nextseqno",s)},expression:"ruleFormData.nextseqno"}})],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.separatorCh","\u5206\u9694\u7B26"),prop:"separatorch"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.separatorch,callback:function(s){e.$set(e.ruleFormData,"separatorch",s)},expression:"ruleFormData.separatorch"}},e._l(e.getDictionary("separator"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.sysCodeGenId","\u7F16\u53F7\u8868"),prop:"syscodegenid"}},[t("div",{staticClass:"cao_about"},[t("el-select",{staticClass:"cao_input",attrs:{placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),"reserve-keyword":"",filterable:"",remote:"",clearable:"","collapse-tags":!0,disabled:e.disabled},model:{value:e.ruleFormData.syscodegenid,callback:function(s){e.$set(e.ruleFormData,"syscodegenid",s)},expression:"ruleFormData.syscodegenid"}},e._l(e.dataList,function(s){return t("el-option",{key:s.id,attrs:{label:s.name,value:s.id}})}),1),t("div",{staticClass:"cao_setting"},[t("i",{staticClass:"el-input__icon el-icon-search cao_setting-disabled",on:{click:function(s){return e.lookup("syscodegenid",e.ruleFormData.syscodegenid)}}})])],1)])],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.columnId","\u7F16\u53F7\u5B57\u6BB5"),prop:"columnid"}},[t("div",{staticClass:"cao_about"},[t("el-select",{staticClass:"cao_input",attrs:{placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),"reserve-keyword":"",filterable:"",remote:"",clearable:"","collapse-tags":!0,disabled:e.disabled},model:{value:e.ruleFormData.columnid,callback:function(s){e.$set(e.ruleFormData,"columnid",s)},expression:"ruleFormData.columnid"}},e._l(e.columnList,function(s){return t("el-option",{key:s.id,attrs:{label:s.name,value:s.id}})}),1),t("div",{staticClass:"cao_setting"},[t("i",{staticClass:"el-input__icon el-icon-search cao_setting-disabled",on:{click:function(s){return e.lookup("columnid",e.ruleFormData.columnid)}}})])],1)])],1)],1)],1),t("el-divider"),t("div",{staticClass:"remarks_title"},[e._v(" "+e._s(e.$i18nt("gd.numberingRules.remarks","\u793A\u4F8B:{\u56FA\u5B9A\u524D\u7F00/ \u968F\u673A\u524D\u7F00}{ \u5E74\u6708\u65E5 }{ \u6D41\u6C34\u53F7, \u6D41\u6C34\u53F7\u7C7B\u578B(\u4E3B/ \u5B50, \u5B9E\u4F53 /), \u6D41\u6C34\u53F7\u8303\u56F4(\u5168\u5C40 / \u65E5\u671F\u5185)}{ \u56FA\u5B9A\u540E\u7F00 / \u968F\u673A\u540E\u7F00 } Acc202206130001zzz"))+" ")])],1)])],1)},y=[],b=o.normalizeComponent(f,h,y,!1,null,"c510bf8e",null,null);const $=b.exports;const _={name:"GdSumberrules",mixins:[d.tablesFilter,g],props:{height:{type:Number,default:100}},data(){return{formLoading:!1,transKey:"gd.btn.add",selectedRowKeys:[],selectedRows:[],queryParam:{},loadData:a=>c(this.getQueryParam).then(e=>({pageNo:1,pageSize:100,totalRows:0,rows:e.map(s=>{let l=this.tableLists.filter(r=>r.id===s.syscodegenid)[0];return Object.assign(s,{syscodegen:l})})}))}},computed:{getQueryParam(){let a=new Map;for(let e in this.queryParam)this.queryParam[e]!==""&&a.set(e,this.queryParam[e]);return Object.fromEntries(a)},getHeight(){return this.height},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode","tableLists"])},components:{editForm:$},methods:{saveQueries(a){this.queryParam={...a},this.refresh()},refresh(){this.$refs.table.refresh()},editForm(a){this.transKey="gd.btn.edit",this.$refs.editForm.open(a)},add(){this.$refs.editForm.open()},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},handleOk(){this.refresh()},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(a,e,t)=>{this.delHand(a,e,t)}})},delHand(a,e,t){if(a!=="confirm"){t();return}let s=[];this.selectedRows.forEach(l=>{let r=m(l).then(i=>i);s.push(r)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(s).then(l=>{const r=l.filter(i=>!i.success);r.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+r[0].message),t(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},onSelectChange(a,e){this.selectedRowKeys=a,this.selectedRows=e},doEvent(a){let e=a.item.functionName;this[e]&&this[e]()},dictSwitch(a,e){let t=this.$options.filters.dictData(e).filter(s=>s.code==a)[0];return t!=null&&t.colour?t.colour:null}}};var x=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view"},[t("div",{staticClass:"page-view-list",staticStyle:{padding:"0px"}},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0,showPagination:!1},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorr"},[t("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"name",fn:function({column:s,row:l}){return[t("gd-tooltip",{attrs:{rowKey:"name",row:l,highlight:""},on:{click:e.editForm}})]}},{key:"sysCodeGenId",fn:function({column:s,row:l}){return[l.syscodegen?t("span",[e._v(" "+e._s(e.$i18nt(`Dynamics.${l.syscodegen.transkey}`,l.syscodegen.busname))+" ")]):e._e()]}},{key:"columnid",fn:function({column:s,row:l}){return[l.syscodegenconfig?t("span",[e._v(" "+e._s(e.$i18nt(`Dynamics.${l.syscodegenconfig.transkey}`,l.syscodegenconfig.name))+" ")]):e._e()]}},{key:"statecodes",fn:function(s){return[e.dictSwitch(s.row.statecodes,"state_code")?t("el-tag",{staticStyle:{"border-color":"transparent"},attrs:{effect:"dark",color:e.dictSwitch(s.row.statecodes,"state_code")}},[e._v(" "+e._s(e._f("dictType")("state_code",s.row.statecodes))+" ")]):t("span",[e._v(e._s(e._f("dictType")("state_code",s.row.statecodes)))])]}},{key:"filtering",fn:function({colse:s,visible:l}){return[t("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.height,queryParam:e.queryParam,colse:s,visible:l},on:{save:e.saveQueries}})]}}])})],1),t("editForm",{ref:"editForm",attrs:{openPermissions:!0},on:{ok:e.handleOk}})],1)},v=[],w=o.normalizeComponent(_,x,v,!1,null,"4481d39a",null,null);const n=w.exports;n.install=function(a){a.component(n.name,n)};exports.GDpackage=n;
1
+ "use strict";const o=require("./chartbi.b5b6fdab.js"),d=require("./messages.1346558e.js");function c(a){return window.axios({url:"/SysNumberRules/page",method:"get",params:a})}function u(a){return window.axios({url:"/sysNumberRules/add",method:"post",data:a})}function p(a){return window.axios({url:"/sysNumberRules/edit",method:"post",data:a})}function m(a){return window.axios({url:"/sysNumberRules/delete",method:"post",data:a})}const g={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.msg.sendRecord.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",fixed:!0,showOverflowTooltip:!0},{transKey:"gd.process.tableSort",prop:"sysCodeGenId",label:"\u8868\u540D\u79F0",type:"slot",slotType:"sysCodeGenId",align:"left"},{transKey:"gd.process.tableSort",prop:"columnid",label:"\u5B57\u6BB5",type:"slot",slotType:"columnid",align:"left"},{transKey:"gd.process.tableSort",prop:"nextseqno",label:"\u4E0B\u4E00\u6D41\u6C34\u53F7",align:"left"},{transKey:"gd.flow.state",prop:"statecodes",label:"\u72B6\u6001",type:"slot",slotType:"statecodes",align:"left"}],formColumns:[{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.msg.sendRecord.msgTemplate",effectType:"selectFkMultiple",prop:"syscodegenid",label:"\u7F16\u53F7\u8868",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",fkEntityName:"sys_code_gen",disabled:!1,multiple:!1,rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysSumberrules:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysSumberrules:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysSumberrules:delete"}],tableQueries:[{transKey:"gd.org.name",prop:"name",label:"\u540D\u79F0",effectType:"input",rules:[]}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}]}}};const f={props:{modalAppendToBody:{type:Boolean,default:!0},appendToBody:{type:Boolean,default:!0}},data(){return{confirmLoading:!1,visible:!1,fullScreen:!1,title:"",width:"50%",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],rules:{name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}],prefixtype:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}],nextseqno:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}]},ruleFormData:{id:"",name:"",prefixtype:"",prefix:"",dateformat:"",seqtype:"",seqrange:"",seqlength:void 0,postfixtype:"",postfix:"",nextseqno:"",separatorch:"",syscodegenid:"",columnid:""},dataList:[],columnList:[],disabled:!0,type:1}},methods:{lookup(){this.disabled},open(a){this.visible=!0,this.fullScreen=!1,this.title=a?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.type=a?2:1,a&&this.getSetData(a)},getSetData(a){let e={id:a.id,name:a.name,prefixtype:a.prefixtype.toString(),prefix:a.prefix,dateformat:a.dateformat||a.dateformat==0?a.dateformat.toString():"",seqtype:a.seqtype||a.seqtype==0?a.seqtype.toString():"",seqrange:a.seqrange?a.seqrange.toString():"",seqlength:a.seqlength,postfixtype:a.postfixtype||a.postfixtype==0?a.postfixtype.toString():"",postfix:a.postfix,nextseqno:a.nextseqno?a.nextseqno.toString():"",separatorch:a.separatorch||a.separatorch==0?a.separatorch.toString():"",syscodegenid:a.syscodegen?a.syscodegenid:"",columnid:a.syscodegenconfig?a.columnid:""};this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData=e},0)}),this.getFkDada(a)},getFkDada(a){let e=[];if(a.syscodegenid){let t=this.searchData({id:a.syscodegenid,fkEntityName:"sys_code_gen"},"syscodegenid");e.push(t)}if(a.columnid){let t=this.searchData({id:a.columnid,fkEntityName:"sys_code_gen_config"},"columnid");e.push(t)}Promise.all(e).then(t=>{t.forEach(s=>{s.prop=="syscodegenid"&&(this.dataList=s.res.data?s.res.data:[]),s.prop=="columnid"&&(this.columnList=s.res.data?s.res.data:[])})})},searchData(a,e){return d.baseFkList(a).then(t=>({res:t,data:a,prop:e}))},handleSubmit(){this.$refs.ruleForm.validate(a=>{if(a){let e={...this.ruleFormData};this.type==1?this.add(e):this.edit(e)}})},add(a){this.confirmLoading=!0,delete a.id,u(a).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.addSucc","\u65B0\u589E\u6210\u529F")),this.$emit("ok"),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.addFail","\u65B0\u589E\u5931\u8D25: ")+e.message)}).finally(e=>{this.confirmLoading=!1})},edit(a){this.confirmLoading=!0,p(a).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.editSucc","\u7F16\u8F91\u6210\u529F")),this.$emit("ok"),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.editFail","\u7F16\u8F91\u5931\u8D25: ")+e.message)}).finally(e=>{this.confirmLoading=!1})},getDictionary(a){return this.$options.filters.dictData(a)},toggleFullscreen(){this.fullScreen=!this.fullScreen},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.$refs.ruleForm.resetFields(),this.ruleFormData={name:"",prefixtype:"",prefix:"",dateformat:"",seqtype:"",seqrange:"",seqlength:void 0,postfixtype:"",postfix:"",nextseqno:"",separatorch:"",syscodegenid:"",columnid:""}},doEvent(a){let e=a.item.functionName;this[e]&&this[e]()}}};var h=function(){var e=this,t=e._self._c;return t("el-dialog",{class:e.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:e.width,visible:e.visible,fullscreen:e.fullScreen,footer:null,top:"80px","modal-append-to-body":e.modalAppendToBody,"append-to-body":e.appendToBody,"close-on-click-modal":!1,"show-close":!1},on:{"update:visible":function(s){e.visible=s},closed:e.handleCancel}},[t("gd-modal-title",{attrs:{slot:"title",title:e.title,fullscreen:e.fullScreen,buttons:e.sysViewButtons,confirmLoading:e.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen},slot:"title"}),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[t("div",{class:e.fullScreen?"modal-bodyq":"modal-body"},[t("el-form",{ref:"ruleForm",attrs:{rules:e.rules,model:e.ruleFormData,"label-width":"100px"},nativeOn:{submit:function(s){s.preventDefault()}}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.name","\u540D\u79F0"),prop:"name"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.name,callback:function(s){e.$set(e.ruleFormData,"name",s)},expression:"ruleFormData.name"}})],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.prefixType","\u524D\u7F00\u7C7B\u578B"),prop:"prefixtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.prefixtype,callback:function(s){e.$set(e.ruleFormData,"prefixtype",s)},expression:"ruleFormData.prefixtype"}},e._l(e.getDictionary("prefix_type"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.prefix","\u524D\u7F00"),prop:"prefix"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.prefix,callback:function(s){e.$set(e.ruleFormData,"prefix",s)},expression:"ruleFormData.prefix"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.dateFormat","\u65E5\u671F\u683C\u5F0F"),prop:"dateformat"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.dateformat,callback:function(s){e.$set(e.ruleFormData,"dateformat",s)},expression:"ruleFormData.dateformat"}},e._l(e.getDictionary("dateformat"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqType","\u6D41\u6C34\u53F7\u7C7B\u578B"),prop:"seqtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.seqtype,callback:function(s){e.$set(e.ruleFormData,"seqtype",s)},expression:"ruleFormData.seqtype"}},e._l(e.getDictionary("seqtype"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqRange","\u6D41\u6C34\u53F7\u8303\u56F4"),prop:"seqrange"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.seqrange,callback:function(s){e.$set(e.ruleFormData,"seqrange",s)},expression:"ruleFormData.seqrange"}},e._l(e.getDictionary("seqrange"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.seqLength","\u6D41\u6C34\u53F7\u957F\u5EA6"),prop:"seqlength"}},[t("el-input-number",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.input"),"controls-position":"right",min:0,max:10},model:{value:e.ruleFormData.seqlength,callback:function(s){e.$set(e.ruleFormData,"seqlength",s)},expression:"ruleFormData.seqlength"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.postfixType","\u540E\u7F00\u7C7B\u578B"),prop:"postfixtype"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.postfixtype,callback:function(s){e.$set(e.ruleFormData,"postfixtype",s)},expression:"ruleFormData.postfixtype"}},e._l(e.getDictionary("postfix_type"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.postfix","\u540E\u7F00"),prop:"postfix"}},[t("el-input",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.input")},model:{value:e.ruleFormData.postfix,callback:function(s){e.$set(e.ruleFormData,"postfix",s)},expression:"ruleFormData.postfix"}})],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.nextSeqNo","\u4E0B\u4E00\u6D41\u6C34\u53F7"),prop:"nextseqno"}},[t("el-input",{attrs:{placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.nextseqno,callback:function(s){e.$set(e.ruleFormData,"nextseqno",s)},expression:"ruleFormData.nextseqno"}})],1)],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.separatorCh","\u5206\u9694\u7B26"),prop:"separatorch"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:e.$i18nt("gd.placeholder.select"),clearable:""},model:{value:e.ruleFormData.separatorch,callback:function(s){e.$set(e.ruleFormData,"separatorch",s)},expression:"ruleFormData.separatorch"}},e._l(e.getDictionary("separator"),function(s,l){return t("el-option",{key:l,attrs:{value:s.code,label:e.$i18nt(`Dynamics.${s.transkey}`,s.name)}})}),1)],1)],1)],1),t("el-row",{attrs:{gutter:24}},[t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.sysCodeGenId","\u7F16\u53F7\u8868"),prop:"syscodegenid"}},[t("div",{staticClass:"cao_about"},[t("el-select",{staticClass:"cao_input",attrs:{placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),"reserve-keyword":"",filterable:"",remote:"",clearable:"","collapse-tags":!0,disabled:e.disabled},model:{value:e.ruleFormData.syscodegenid,callback:function(s){e.$set(e.ruleFormData,"syscodegenid",s)},expression:"ruleFormData.syscodegenid"}},e._l(e.dataList,function(s){return t("el-option",{key:s.id,attrs:{label:s.name,value:s.id}})}),1),t("div",{staticClass:"cao_setting"},[t("i",{staticClass:"el-input__icon el-icon-search cao_setting-disabled",on:{click:function(s){return e.lookup("syscodegenid",e.ruleFormData.syscodegenid)}}})])],1)])],1),t("el-col",{attrs:{span:12}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.numberingRules.columnId","\u7F16\u53F7\u5B57\u6BB5"),prop:"columnid"}},[t("div",{staticClass:"cao_about"},[t("el-select",{staticClass:"cao_input",attrs:{placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),"reserve-keyword":"",filterable:"",remote:"",clearable:"","collapse-tags":!0,disabled:e.disabled},model:{value:e.ruleFormData.columnid,callback:function(s){e.$set(e.ruleFormData,"columnid",s)},expression:"ruleFormData.columnid"}},e._l(e.columnList,function(s){return t("el-option",{key:s.id,attrs:{label:s.name,value:s.id}})}),1),t("div",{staticClass:"cao_setting"},[t("i",{staticClass:"el-input__icon el-icon-search cao_setting-disabled",on:{click:function(s){return e.lookup("columnid",e.ruleFormData.columnid)}}})])],1)])],1)],1)],1),t("el-divider"),t("div",{staticClass:"remarks_title"},[e._v(" "+e._s(e.$i18nt("gd.numberingRules.remarks","\u793A\u4F8B:{\u56FA\u5B9A\u524D\u7F00/ \u968F\u673A\u524D\u7F00}{ \u5E74\u6708\u65E5 }{ \u6D41\u6C34\u53F7, \u6D41\u6C34\u53F7\u7C7B\u578B(\u4E3B/ \u5B50, \u5B9E\u4F53 /), \u6D41\u6C34\u53F7\u8303\u56F4(\u5168\u5C40 / \u65E5\u671F\u5185)}{ \u56FA\u5B9A\u540E\u7F00 / \u968F\u673A\u540E\u7F00 } Acc202206130001zzz"))+" ")])],1)])],1)},y=[],b=o.normalizeComponent(f,h,y,!1,null,"c510bf8e",null,null);const $=b.exports;const _={name:"GdSumberrules",mixins:[d.tablesFilter,g],props:{height:{type:Number,default:100}},data(){return{formLoading:!1,transKey:"gd.btn.add",selectedRowKeys:[],selectedRows:[],queryParam:{},loadData:a=>c(this.getQueryParam).then(e=>({pageNo:1,pageSize:100,totalRows:0,rows:e.map(s=>{let l=this.tableLists.filter(r=>r.id===s.syscodegenid)[0];return Object.assign(s,{syscodegen:l})})}))}},computed:{getQueryParam(){let a=new Map;for(let e in this.queryParam)this.queryParam[e]!==""&&a.set(e,this.queryParam[e]);return Object.fromEntries(a)},getHeight(){return this.height},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode","tableLists"])},components:{editForm:$},methods:{saveQueries(a){this.queryParam={...a},this.refresh()},refresh(){this.$refs.table.refresh()},editForm(a){this.transKey="gd.btn.edit",this.$refs.editForm.open(a)},add(){this.$refs.editForm.open()},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},handleOk(){this.refresh()},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(a,e,t)=>{this.delHand(a,e,t)}})},delHand(a,e,t){if(a!=="confirm"){t();return}let s=[];this.selectedRows.forEach(l=>{let r=m(l).then(i=>i);s.push(r)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(s).then(l=>{const r=l.filter(i=>!i.success);r.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+r[0].message),t(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},onSelectChange(a,e){this.selectedRowKeys=a,this.selectedRows=e},doEvent(a){let e=a.item.functionName;this[e]&&this[e]()},dictSwitch(a,e){let t=this.$options.filters.dictData(e).filter(s=>s.code==a)[0];return t!=null&&t.colour?t.colour:null}}};var x=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view"},[t("div",{staticClass:"page-view-list",staticStyle:{padding:"0px"}},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0,showPagination:!1},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorr"},[t("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"name",fn:function({column:s,row:l}){return[t("gd-tooltip",{attrs:{rowKey:"name",row:l,highlight:""},on:{click:e.editForm}})]}},{key:"sysCodeGenId",fn:function({column:s,row:l}){return[l.syscodegen?t("span",[e._v(" "+e._s(e.$i18nt(`Dynamics.${l.syscodegen.transkey}`,l.syscodegen.busname))+" ")]):e._e()]}},{key:"columnid",fn:function({column:s,row:l}){return[l.syscodegenconfig?t("span",[e._v(" "+e._s(e.$i18nt(`Dynamics.${l.syscodegenconfig.transkey}`,l.syscodegenconfig.name))+" ")]):e._e()]}},{key:"statecodes",fn:function(s){return[e.dictSwitch(s.row.statecodes,"state_code")?t("el-tag",{staticStyle:{"border-color":"transparent"},attrs:{effect:"dark",color:e.dictSwitch(s.row.statecodes,"state_code")}},[e._v(" "+e._s(e._f("dictType")("state_code",s.row.statecodes))+" ")]):t("span",[e._v(e._s(e._f("dictType")("state_code",s.row.statecodes)))])]}},{key:"filtering",fn:function({colse:s,visible:l}){return[t("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.height,queryParam:e.queryParam,colse:s,visible:l},on:{save:e.saveQueries}})]}}])})],1),t("editForm",{ref:"editForm",attrs:{openPermissions:!0},on:{ok:e.handleOk}})],1)},v=[],w=o.normalizeComponent(_,x,v,!1,null,"4481d39a",null,null);const n=w.exports;n.install=function(a){a.component(n.name,n)};exports.GDpackage=n;