gds-plus-design-vue 1.2.22 → 1.2.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/{chartbi.06e48153.js → chartbi.4d631d1d.js} +23 -23
- package/lib/{chartbi.cdd1e365.mjs → chartbi.c86c8ff2.mjs} +2657 -2613
- package/lib/gd-initial.js +5 -5
- package/lib/gd-initial.mjs +390 -232
- package/lib/{main.d091d06d.js → main.2014b77a.js} +1 -1
- package/lib/{main.b2d0a309.mjs → main.27200b43.mjs} +6 -6
- package/lib/{main.4c447fc3.js → main.538e1aff.js} +1 -1
- package/lib/{main.86fe06d4.mjs → main.9a4f9e09.mjs} +3 -3
- package/lib/{main.2415a49a.js → main.da8bd29f.js} +1 -1
- package/lib/{main.2cddfbbd.mjs → main.ee5f3daf.mjs} +3 -3
- package/lib/{messages.2fff74f3.js → messages.54648af6.js} +1 -1
- package/lib/{messages.d8abe18d.mjs → messages.62e2426e.mjs} +1 -1
- package/lib/style.css +3 -3
- package/lib/{system.account.8ea53681.js → system.account.832443e8.js} +1 -1
- package/lib/{system.account.9bc40d08.mjs → system.account.aa056ada.mjs} +19 -19
- package/lib/{system.config.8223d495.mjs → system.config.9253357c.mjs} +2 -2
- package/lib/{system.config.c6e30213.js → system.config.93a222d5.js} +1 -1
- package/lib/{system.datasource.fd6a4e76.js → system.datasource.8f40d2e6.js} +1 -1
- package/lib/{system.datasource.57233650.mjs → system.datasource.da7e97d1.mjs} +2 -2
- package/lib/{system.dict.a24f33b0.js → system.dict.39f53cf9.js} +1 -1
- package/lib/{system.dict.8f95218b.mjs → system.dict.747e4db6.mjs} +2 -2
- package/lib/{system.duplicatechecking.6b706948.mjs → system.duplicatechecking.268bf989.mjs} +2 -2
- package/lib/{system.duplicatechecking.39293985.js → system.duplicatechecking.6a4dba4e.js} +1 -1
- package/lib/{system.email.dae988be.mjs → system.email.041f366e.mjs} +2 -2
- package/lib/{system.email.a2d9a307.js → system.email.7ae73064.js} +1 -1
- package/lib/{system.fieldsecurity.02627a7a.mjs → system.fieldsecurity.7c1593b0.mjs} +1 -1
- package/lib/{system.fieldsecurity.a0cec24d.js → system.fieldsecurity.f882362b.js} +1 -1
- package/lib/{system.file.d695ab37.js → system.file.41836e4c.js} +1 -1
- package/lib/{system.file.0fa095a9.mjs → system.file.bd9c9546.mjs} +2 -2
- package/lib/{system.log.acb64505.mjs → system.log.0dda088d.mjs} +2 -2
- package/lib/{system.log.c07ae5db.js → system.log.a06c8c42.js} +1 -1
- package/lib/{system.machine.fc392d7f.mjs → system.machine.0c361abd.mjs} +1 -1
- package/lib/{system.machine.7fa3e3d1.js → system.machine.b5babd8e.js} +1 -1
- package/lib/{system.notice.5ae50bd4.mjs → system.notice.1a9da14d.mjs} +3 -3
- package/lib/{system.notice.f18578ae.js → system.notice.77dfc124.js} +1 -1
- package/lib/{system.noticereceived.1aa70b65.mjs → system.noticereceived.1c854d3d.mjs} +3 -3
- package/lib/{system.noticereceived.bfa98a9b.js → system.noticereceived.7497229c.js} +1 -1
- package/lib/{system.onlineuser.3d848a32.mjs → system.onlineuser.282f8120.mjs} +2 -2
- package/lib/{system.onlineuser.1c428d05.js → system.onlineuser.8eeb1b1d.js} +1 -1
- package/lib/{system.org.fcf96d1e.mjs → system.org.ba717f25.mjs} +2 -2
- package/lib/{system.org.5bb36f9c.js → system.org.c8cec1b4.js} +1 -1
- package/lib/{system.permissions.23f5b097.mjs → system.permissions.d5a1323e.mjs} +3 -3
- package/lib/{system.permissions.a1a9505c.js → system.permissions.f4747ced.js} +1 -1
- package/lib/{system.plugin.b6de4673.js → system.plugin.d500edad.js} +1 -1
- package/lib/{system.plugin.e37f9dbc.mjs → system.plugin.d85546b7.mjs} +2 -2
- package/lib/{system.pos.1a01fc97.mjs → system.pos.29c397e7.mjs} +2 -2
- package/lib/{system.pos.a4fb19b0.js → system.pos.c0e9bf01.js} +1 -1
- package/lib/{system.promptmanagement.36a65c51.mjs → system.promptmanagement.527849d6.mjs} +2 -2
- package/lib/{system.promptmanagement.290958b1.js → system.promptmanagement.c36e5abc.js} +1 -1
- package/lib/system.role.0d318838.js +1 -0
- package/lib/{system.role.68de93ef.mjs → system.role.b69662b9.mjs} +406 -354
- package/lib/{system.sumberrules.cdef9308.mjs → system.sumberrules.3cd2376a.mjs} +2 -2
- package/lib/{system.sumberrules.dd6299e8.js → system.sumberrules.9efc0cf3.js} +1 -1
- package/lib/{system.team.ee652fe4.mjs → system.team.05a6c1ed.mjs} +2 -2
- package/lib/{system.team.53d64006.js → system.team.6456d380.js} +1 -1
- package/lib/{system.teammembers.26a2ba81.mjs → system.teammembers.b0d89c0c.mjs} +3 -3
- package/lib/{system.teammembers.4a3dc336.js → system.teammembers.fbbd86f6.js} +1 -1
- package/lib/{system.timers.4efa8a7d.mjs → system.timers.831b962b.mjs} +2 -2
- package/lib/{system.timers.b9424204.js → system.timers.ea5b502a.js} +1 -1
- package/lib/{system.translation.21d2fd8b.js → system.translation.5bd000d3.js} +1 -1
- package/lib/{system.translation.0a9399b4.mjs → system.translation.8946f466.mjs} +3 -3
- package/lib/{system.user.d48a08db.js → system.user.56b95931.js} +1 -1
- package/lib/{system.user.4fcfdf99.mjs → system.user.b8311265.mjs} +5 -5
- package/lib/{system.useraffiliation.fb002239.mjs → system.useraffiliation.33f089c6.mjs} +3 -3
- package/lib/{system.useraffiliation.a59ce45b.js → system.useraffiliation.b3d193ce.js} +1 -1
- package/lib/{system.webresource.3366cc29.js → system.webresource.3c05b01c.js} +1 -1
- package/lib/{system.webresource.4df01c92.mjs → system.webresource.885d9370.mjs} +3 -3
- package/lib/{system.welcome.472f099b.js → system.welcome.0c8e19c0.js} +1 -1
- package/lib/{system.welcome.120f4b50.mjs → system.welcome.36994c20.mjs} +1 -1
- package/locale/en_US.js +49 -4
- package/locale/id_ID.js +49 -4
- package/locale/vi_VN.js +1972 -1927
- package/locale/zh_CN.js +48 -3
- package/package.json +1 -1
- package/lib/system.role.88100f66.js +0 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { s as
|
|
2
|
-
import { m as
|
|
3
|
-
import { t as
|
|
4
|
-
import { g as
|
|
5
|
-
import { S, b as
|
|
6
|
-
const
|
|
1
|
+
import { s as K, a as $, b as T, c as C, g as I, d as R, e as S, f as L, h as x } from "./system.fieldsecurity.7c1593b0.mjs";
|
|
2
|
+
import { m as g, n as p, u as f } from "./chartbi.c86c8ff2.mjs";
|
|
3
|
+
import { t as v } from "./messages.62e2426e.mjs";
|
|
4
|
+
import { g as _, s as D, a as N } from "./system.org.ba717f25.mjs";
|
|
5
|
+
import { S as B, b as F, g as M, d as A, p as O, e as P, f as E } from "./system.account.aa056ada.mjs";
|
|
6
|
+
const z = {
|
|
7
7
|
data() {
|
|
8
8
|
return {
|
|
9
9
|
tableColumns: [
|
|
@@ -20,7 +20,7 @@ const M = {
|
|
|
20
20
|
slotType: "name",
|
|
21
21
|
align: "left",
|
|
22
22
|
fixed: !0,
|
|
23
|
-
renderHeader: (
|
|
23
|
+
renderHeader: (s, ...e) => this.renderHeader(s, ...e, {
|
|
24
24
|
effectType: "input"
|
|
25
25
|
}),
|
|
26
26
|
showOverflowTooltip: !0
|
|
@@ -30,7 +30,7 @@ const M = {
|
|
|
30
30
|
prop: "code",
|
|
31
31
|
label: "\u552F\u4E00\u7F16\u7801",
|
|
32
32
|
align: "left",
|
|
33
|
-
renderHeader: (
|
|
33
|
+
renderHeader: (s, ...e) => this.renderHeader(s, ...e, {
|
|
34
34
|
effectType: "input"
|
|
35
35
|
}),
|
|
36
36
|
showOverflowTooltip: !0
|
|
@@ -204,7 +204,7 @@ const M = {
|
|
|
204
204
|
};
|
|
205
205
|
}
|
|
206
206
|
};
|
|
207
|
-
const
|
|
207
|
+
const q = {
|
|
208
208
|
data() {
|
|
209
209
|
return {
|
|
210
210
|
defaultProps: {
|
|
@@ -230,28 +230,28 @@ const A = {
|
|
|
230
230
|
};
|
|
231
231
|
},
|
|
232
232
|
computed: {
|
|
233
|
-
...
|
|
233
|
+
...g(["screenHeight", "tableLists"])
|
|
234
234
|
},
|
|
235
235
|
methods: {
|
|
236
236
|
handleSubmit() {
|
|
237
|
-
const
|
|
237
|
+
const s = this.$refs.tree.getCheckedKeys();
|
|
238
238
|
this.$emit(
|
|
239
239
|
"ok",
|
|
240
240
|
Object.assign(
|
|
241
241
|
{ ...this.record },
|
|
242
242
|
{
|
|
243
|
-
checkedKeys:
|
|
243
|
+
checkedKeys: s
|
|
244
244
|
}
|
|
245
245
|
)
|
|
246
246
|
), this.closed();
|
|
247
247
|
},
|
|
248
248
|
getOrgData() {
|
|
249
|
-
this.confirmLoading = !0,
|
|
250
|
-
|
|
249
|
+
this.confirmLoading = !0, _().then((s) => {
|
|
250
|
+
s.success && (this.orgTreeData = s.data, this.confirmLoading = !1);
|
|
251
251
|
});
|
|
252
252
|
},
|
|
253
|
-
open(
|
|
254
|
-
this.record =
|
|
253
|
+
open(s) {
|
|
254
|
+
this.record = s, this.checkedKeys = s.checkedKeys, this.visible = !0, this.getOrgData();
|
|
255
255
|
},
|
|
256
256
|
closed() {
|
|
257
257
|
this.fullscreen = !1, this.visible = !1;
|
|
@@ -259,29 +259,29 @@ const A = {
|
|
|
259
259
|
toggleFullscreen() {
|
|
260
260
|
this.fullscreen = !this.fullscreen;
|
|
261
261
|
},
|
|
262
|
-
doEvent(
|
|
263
|
-
const e =
|
|
262
|
+
doEvent(s) {
|
|
263
|
+
const e = s.item.functionName;
|
|
264
264
|
this[e] && this[e]();
|
|
265
265
|
}
|
|
266
266
|
}
|
|
267
267
|
};
|
|
268
|
-
var
|
|
269
|
-
var e = this,
|
|
270
|
-
return
|
|
268
|
+
var G = function() {
|
|
269
|
+
var e = this, t = e._self._c;
|
|
270
|
+
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(n) {
|
|
271
271
|
e.visible = n;
|
|
272
|
-
}, closed: e.closed } }, [
|
|
273
|
-
},
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
272
|
+
}, 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);
|
|
273
|
+
}, j = [], H = /* @__PURE__ */ p(
|
|
274
|
+
q,
|
|
275
|
+
G,
|
|
276
|
+
j,
|
|
277
277
|
!1,
|
|
278
278
|
null,
|
|
279
279
|
"2b164094",
|
|
280
280
|
null,
|
|
281
281
|
null
|
|
282
282
|
);
|
|
283
|
-
const
|
|
284
|
-
const
|
|
283
|
+
const V = H.exports;
|
|
284
|
+
const U = {
|
|
285
285
|
data() {
|
|
286
286
|
return {
|
|
287
287
|
buttons: [
|
|
@@ -300,7 +300,7 @@ const q = {
|
|
|
300
300
|
width: "94%",
|
|
301
301
|
loadData: [],
|
|
302
302
|
submitData: {},
|
|
303
|
-
loadSoData: (
|
|
303
|
+
loadSoData: (s) => (this.confirmLoading = !0, new Promise((e, t) => {
|
|
304
304
|
this.confirmLoading = !1, e({ pageNo: 1, pageSize: 500, totalRows: 0, rows: this.loadData });
|
|
305
305
|
})),
|
|
306
306
|
columns: [
|
|
@@ -377,96 +377,96 @@ const q = {
|
|
|
377
377
|
currentList: {}
|
|
378
378
|
};
|
|
379
379
|
},
|
|
380
|
-
components: { RoleScope:
|
|
380
|
+
components: { RoleScope: V },
|
|
381
381
|
computed: {
|
|
382
382
|
height() {
|
|
383
383
|
return this.screenHeight - (this.fullscreen ? 120 : 310);
|
|
384
384
|
},
|
|
385
|
-
...
|
|
385
|
+
...g(["primaryColor", "screenHeight", "tableLists", "tableSize", "tablePageSize"])
|
|
386
386
|
},
|
|
387
387
|
methods: {
|
|
388
388
|
handleSubmit() {
|
|
389
389
|
this.confirmLoading = !0;
|
|
390
|
-
let
|
|
391
|
-
|
|
390
|
+
let s = this.$refs.table.tableData;
|
|
391
|
+
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)), D(
|
|
392
392
|
Object.assign(
|
|
393
393
|
{ ...this.submitData },
|
|
394
394
|
{
|
|
395
|
-
grants:
|
|
395
|
+
grants: s
|
|
396
396
|
}
|
|
397
397
|
)
|
|
398
398
|
).then((e) => {
|
|
399
399
|
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);
|
|
400
400
|
});
|
|
401
401
|
},
|
|
402
|
-
setRoleScop(
|
|
402
|
+
setRoleScop(s) {
|
|
403
403
|
this.confirmLoading = !0;
|
|
404
404
|
const e = this.$refs.table.tableData;
|
|
405
|
-
e[
|
|
405
|
+
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"));
|
|
406
406
|
},
|
|
407
|
-
openList(
|
|
408
|
-
const n = this.$refs.table.tableData, i = `${
|
|
409
|
-
this.$refs.roleScope.open({ index:
|
|
407
|
+
openList(s, e, t) {
|
|
408
|
+
const n = this.$refs.table.tableData, i = `${s.prop.replace("grantd", "")}custom`, a = n[t][i], o = a ? a.split(",").map(Number) : [];
|
|
409
|
+
this.$refs.roleScope.open({ index: t, item: s, checkedKeys: o, data: e, name: i });
|
|
410
410
|
},
|
|
411
411
|
getUserControlData() {
|
|
412
|
-
this.confirmLoading = !0,
|
|
413
|
-
|
|
412
|
+
this.confirmLoading = !0, N({ roleId: this.record.id }).then((s) => {
|
|
413
|
+
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(() => {
|
|
414
414
|
setTimeout(() => {
|
|
415
415
|
this.refresh(), this.confirmLoading = !0;
|
|
416
416
|
}, 1e3), setTimeout(() => {
|
|
417
417
|
this.confirmLoading = !1;
|
|
418
418
|
}, 1200);
|
|
419
|
-
})) : (this.$message.error(
|
|
419
|
+
})) : (this.$message.error(s.message), this.confirmLoading = !1);
|
|
420
420
|
});
|
|
421
421
|
},
|
|
422
|
-
open(
|
|
423
|
-
this.record =
|
|
422
|
+
open(s) {
|
|
423
|
+
this.record = s, this.visible = !0, this.getUserControlData();
|
|
424
424
|
},
|
|
425
425
|
closed() {
|
|
426
426
|
this.fullscreen = !1, this.visible = !1;
|
|
427
427
|
},
|
|
428
|
-
refresh(
|
|
429
|
-
this.$refs.table ? this.$refs.table.refresh(
|
|
428
|
+
refresh(s = !0) {
|
|
429
|
+
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");
|
|
430
430
|
},
|
|
431
|
-
getDictionary(
|
|
432
|
-
return this.$options.filters.dictData(
|
|
431
|
+
getDictionary(s) {
|
|
432
|
+
return this.$options.filters.dictData(s);
|
|
433
433
|
},
|
|
434
434
|
toggleFullscreen() {
|
|
435
435
|
this.fullscreen = !this.fullscreen;
|
|
436
436
|
},
|
|
437
|
-
doEvent(
|
|
438
|
-
const e =
|
|
437
|
+
doEvent(s) {
|
|
438
|
+
const e = s.item.functionName;
|
|
439
439
|
this[e] && this[e]();
|
|
440
440
|
}
|
|
441
441
|
}
|
|
442
442
|
};
|
|
443
|
-
var
|
|
444
|
-
var e = this,
|
|
445
|
-
return
|
|
443
|
+
var Q = function() {
|
|
444
|
+
var e = this, t = e._self._c;
|
|
445
|
+
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(n) {
|
|
446
446
|
e.visible = n;
|
|
447
|
-
}, closed: e.closed } }, [
|
|
448
|
-
return { key: n.prop, fn: function({ column: i, row:
|
|
449
|
-
return [n.prop === "sysCodeGenName" ?
|
|
450
|
-
e.$set(
|
|
451
|
-
}, expression: "row[item.prop]" } }, [e._l(e.getDictionary("data_scope_type"), function(
|
|
452
|
-
return [
|
|
453
|
-
})], 2),
|
|
454
|
-
return e.openList(n,
|
|
447
|
+
}, 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(n) {
|
|
448
|
+
return { key: n.prop, fn: function({ column: i, row: a, index: o }) {
|
|
449
|
+
return [n.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[n.prop], callback: function(r) {
|
|
450
|
+
e.$set(a, n.prop, r);
|
|
451
|
+
}, expression: "row[item.prop]" } }, [e._l(e.getDictionary("data_scope_type"), function(r) {
|
|
452
|
+
return [t("el-option", { attrs: { label: e.$i18nt(`Dynamics.${r.transkey}`, r.name), value: r.code } })];
|
|
453
|
+
})], 2), a[n.prop].includes("5") ? t("el-button", { staticClass: "active-color flex-center", attrs: { type: "text" }, on: { click: function(r) {
|
|
454
|
+
return e.openList(n, a, o);
|
|
455
455
|
} } }, [e._v(" " + e._s(e.$i18nt("gd.btn.view", "\u67E5\u770B")) + " ")]) : e._e()], 1)];
|
|
456
456
|
} };
|
|
457
|
-
})], null, !0) }) : e._e()], 1)], 2),
|
|
458
|
-
},
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
457
|
+
})], null, !0) }) : e._e()], 1)], 2), t("RoleScope", { ref: "roleScope", on: { ok: e.setRoleScop } })], 1);
|
|
458
|
+
}, J = [], W = /* @__PURE__ */ p(
|
|
459
|
+
U,
|
|
460
|
+
Q,
|
|
461
|
+
J,
|
|
462
462
|
!1,
|
|
463
463
|
null,
|
|
464
464
|
"39b91bb5",
|
|
465
465
|
null,
|
|
466
466
|
null
|
|
467
467
|
);
|
|
468
|
-
const
|
|
469
|
-
const
|
|
468
|
+
const X = W.exports;
|
|
469
|
+
const Y = {
|
|
470
470
|
name: "LayoutItem",
|
|
471
471
|
props: {
|
|
472
472
|
record: {
|
|
@@ -488,61 +488,61 @@ const U = {
|
|
|
488
488
|
menusType() {
|
|
489
489
|
return this.record[0] ? this.record[0].menusType : 0;
|
|
490
490
|
},
|
|
491
|
-
...
|
|
491
|
+
...g(["primaryColor"])
|
|
492
492
|
},
|
|
493
493
|
methods: {
|
|
494
|
-
hasAll(
|
|
495
|
-
return !(this.checkedKeys.filter((
|
|
494
|
+
hasAll(s) {
|
|
495
|
+
return !(this.checkedKeys.filter((t) => s.menuBtnIds.includes(t)).length >= s.menuBtnIds.length);
|
|
496
496
|
},
|
|
497
|
-
checkedBtn(
|
|
498
|
-
this.$emit("checkedBtn",
|
|
497
|
+
checkedBtn(s, e) {
|
|
498
|
+
this.$emit("checkedBtn", s, e);
|
|
499
499
|
},
|
|
500
|
-
change(
|
|
501
|
-
this.$emit("change",
|
|
500
|
+
change(s, e) {
|
|
501
|
+
this.$emit("change", s, e);
|
|
502
502
|
},
|
|
503
|
-
open(
|
|
504
|
-
this.$emit("open",
|
|
503
|
+
open(s) {
|
|
504
|
+
this.$emit("open", s);
|
|
505
505
|
},
|
|
506
|
-
checked(
|
|
507
|
-
return !!this.checkedKeys.filter((
|
|
506
|
+
checked(s) {
|
|
507
|
+
return !!this.checkedKeys.filter((t) => t === s.id)[0];
|
|
508
508
|
},
|
|
509
|
-
fadeColor(
|
|
510
|
-
let
|
|
511
|
-
return `rgba(${
|
|
509
|
+
fadeColor(s, e) {
|
|
510
|
+
let t = parseInt(s.substring(1, 3), 16), n = parseInt(s.substring(3, 5), 16), i = parseInt(s.substring(5, 7), 16);
|
|
511
|
+
return `rgba(${t},${n},${i},${e})`;
|
|
512
512
|
}
|
|
513
513
|
}
|
|
514
514
|
};
|
|
515
|
-
var
|
|
516
|
-
var e = this,
|
|
517
|
-
return
|
|
518
|
-
return [
|
|
515
|
+
var Z = function() {
|
|
516
|
+
var e = this, t = e._self._c;
|
|
517
|
+
return t("div", { style: { "--fadecolor": e.fadeColord } }, [e._l(e.record, function(n) {
|
|
518
|
+
return [t("div", { staticClass: "list-item" }, [n.menusType !== 1 && n.children && n.children.length > 0 ? t("i", { class: n.open ? "el-icon-caret-bottom" : "el-icon-caret-right", on: { click: function(i) {
|
|
519
519
|
return e.open(n);
|
|
520
|
-
} } }) : e._e(), e.menusType !== 2 ?
|
|
520
|
+
} } }) : e._e(), e.menusType !== 2 ? t("div", { staticClass: "item-name" }, [t("el-checkbox", { attrs: { indeterminate: n.isIndeterminate }, on: { change: function(i) {
|
|
521
521
|
return e.change(i, [n.id]);
|
|
522
522
|
} }, model: { value: n.checked, callback: function(i) {
|
|
523
523
|
e.$set(n, "checked", i);
|
|
524
|
-
}, expression: "item.checked" } }, [n.iconClass ?
|
|
524
|
+
}, expression: "item.checked" } }, [n.iconClass ? t("i", { staticClass: "gd-icons", class: n.iconClass, staticStyle: { "font-size": "15px" } }) : e._e(), e._v(" " + e._s(e.$i18nt(`Dynamics.${n.transkey}`, n.title)) + " ")]), n.children && n.children.length > 0 && e.menusType === 1 ? t("el-button", { staticStyle: { "margin-left": "12px", padding: "5px 15px" }, attrs: { size: "mini" } }, [e.hasAll(n) ? t("span", { on: { click: function(i) {
|
|
525
525
|
return e.checkedBtn(n, 1);
|
|
526
|
-
} } }, [e._v(" " + e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")) + " ")]) :
|
|
526
|
+
} } }, [e._v(" " + e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")) + " ")]) : t("span", { on: { click: function(i) {
|
|
527
527
|
return e.checkedBtn(n, 0);
|
|
528
|
-
} } }, [e._v(" " + e._s(e.$i18nt("gd.btn.cancel", "\u53D6\u6D88")) + " ")])]) : e._e()], 1) : e._e(),
|
|
529
|
-
return [
|
|
528
|
+
} } }, [e._v(" " + e._s(e.$i18nt("gd.btn.cancel", "\u53D6\u6D88")) + " ")])]) : e._e()], 1) : e._e(), t("div", { staticClass: "item-data" }, [n.children && n.children.length > 0 && n.children[0].menusType === 2 ? t("div", { staticClass: "item-data-list" }, [e._l(n.children, function(i) {
|
|
529
|
+
return [t("div", { staticClass: "item-name item-named", on: { click: function(a) {
|
|
530
530
|
return e.change(!i.checked, [i.id]);
|
|
531
|
-
} } }, [i.checked ?
|
|
532
|
-
})], 2) : e._e()])]), n.children && n.children.length > 0 && n.children[0].menusType !== 2 ?
|
|
531
|
+
} } }, [i.checked ? t("i", { staticClass: "gd-icons gd-icon-quanxuan active-color" }) : t("div", { staticClass: "item-named-kuang" }), t("div", { staticClass: "item-named-title", class: i.checked ? "active-color" : "" }, [e._v(" " + e._s(e.$i18nt(`Dynamics.${i.transkey}`, i.title)) + " ")])])];
|
|
532
|
+
})], 2) : e._e()])]), n.children && n.children.length > 0 && n.children[0].menusType !== 2 ? t("div", { staticClass: "list-more" }, [n.open ? t("LayoutItem", { attrs: { record: n.children, checkedKeys: e.checkedKeys }, on: { open: e.open, change: e.change, checkedBtn: e.checkedBtn } }) : e._e()], 1) : e._e()];
|
|
533
533
|
})], 2);
|
|
534
|
-
},
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
534
|
+
}, ee = [], te = /* @__PURE__ */ p(
|
|
535
|
+
Y,
|
|
536
|
+
Z,
|
|
537
|
+
ee,
|
|
538
538
|
!1,
|
|
539
539
|
null,
|
|
540
|
-
"
|
|
540
|
+
"c10ba764",
|
|
541
541
|
null,
|
|
542
542
|
null
|
|
543
543
|
);
|
|
544
|
-
const
|
|
545
|
-
const
|
|
544
|
+
const w = te.exports;
|
|
545
|
+
const se = {
|
|
546
546
|
data() {
|
|
547
547
|
return {
|
|
548
548
|
buttons: [
|
|
@@ -566,104 +566,144 @@ const X = {
|
|
|
566
566
|
menuAll: [],
|
|
567
567
|
systemMenuAll: [],
|
|
568
568
|
allCheckedKeys: [],
|
|
569
|
-
appsId: ""
|
|
569
|
+
appsId: "",
|
|
570
|
+
appList: []
|
|
570
571
|
};
|
|
571
572
|
},
|
|
572
573
|
computed: {
|
|
574
|
+
customClass() {
|
|
575
|
+
return `role_${f(12)}`;
|
|
576
|
+
},
|
|
573
577
|
isIndeterminate() {
|
|
574
578
|
return this.allClose ? !1 : this.checkedKeys.length > 0;
|
|
575
579
|
},
|
|
576
|
-
|
|
580
|
+
fadeColord() {
|
|
581
|
+
return this.fadeColor(this.primaryColor, 0.1);
|
|
582
|
+
},
|
|
583
|
+
...g(["screenHeight", "tableLists", "primaryColor"])
|
|
577
584
|
},
|
|
578
|
-
components: { LayoutItem:
|
|
585
|
+
components: { LayoutItem: w },
|
|
579
586
|
methods: {
|
|
587
|
+
elScrollIntoView(s) {
|
|
588
|
+
this.$nextTick(() => {
|
|
589
|
+
setTimeout(() => {
|
|
590
|
+
const e = document.querySelector(`.${this.customClass} .${s}`);
|
|
591
|
+
e && e.scrollIntoView({ behavior: "smooth" });
|
|
592
|
+
}, 100);
|
|
593
|
+
});
|
|
594
|
+
},
|
|
595
|
+
appOpen(s, e) {
|
|
596
|
+
let t = [...this.menuTreeData];
|
|
597
|
+
t[s].open = !t[s].open, this.menuTreeData = [...t];
|
|
598
|
+
},
|
|
580
599
|
handleSubmit() {
|
|
581
|
-
this.confirmLoading = !0,
|
|
600
|
+
this.confirmLoading = !0, K({
|
|
582
601
|
id: this.record.id,
|
|
583
602
|
grantmenuidlist: this.checkedKeys
|
|
584
|
-
}).then((
|
|
585
|
-
|
|
603
|
+
}).then((s) => {
|
|
604
|
+
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;
|
|
586
605
|
});
|
|
587
606
|
},
|
|
588
|
-
checkedItemBtn(
|
|
589
|
-
let
|
|
590
|
-
e === 1 && (
|
|
607
|
+
checkedItemBtn(s, e) {
|
|
608
|
+
let t = [...this.checkedKeys].filter((n) => !s.menuBtnIds.includes(n));
|
|
609
|
+
e === 1 && (t = t.concat(s.menuBtnIds)), this.checkedKeys = [...t], this.handleItem();
|
|
591
610
|
},
|
|
592
|
-
openItem(
|
|
611
|
+
openItem(s) {
|
|
593
612
|
let e = [...this.menuTreeData];
|
|
594
|
-
const
|
|
595
|
-
|
|
613
|
+
const t = (n) => (n = n.filter((i, a) => (i.id === s.id && (i.open = !i.open), i.children && i.children.length > 0 && (i.children = t(i.children)), !0)), n);
|
|
614
|
+
t(e), this.menuTreeData = [...e];
|
|
596
615
|
},
|
|
597
|
-
changeItem(
|
|
616
|
+
changeItem(s, e, t = !0) {
|
|
598
617
|
let n = [...this.checkedKeys];
|
|
599
618
|
this.checkedKeys.filter((l) => e.includes(l))[0];
|
|
600
|
-
const i = this.list.filter((l) => e.includes(l.id))[0],
|
|
601
|
-
if (
|
|
619
|
+
const i = this.list.filter((l) => e.includes(l.id))[0], a = t && i ? i.menuIds : [];
|
|
620
|
+
if (s ? n = this.checkedKeys.concat(e).concat(a) : n = this.checkedKeys.filter((l) => !e.includes(l)).filter((l) => !a.includes(l)), this.checkedKeys = [...n], this.handleItem(), i.menusType === 2)
|
|
602
621
|
return;
|
|
603
622
|
let o = [];
|
|
604
623
|
this.findParent(this.menuTreeData, i, o);
|
|
605
|
-
let
|
|
624
|
+
let r = [], u = [];
|
|
606
625
|
o.forEach((l) => {
|
|
607
|
-
this.checkedKeys.filter((
|
|
608
|
-
}),
|
|
626
|
+
this.checkedKeys.filter((h) => l.menuIds.includes(h)).length === l.menuIds.length && l.menuIds.length > 0 && !l.checked ? r.push(l.id) : u.push(l.id);
|
|
627
|
+
}), r.forEach((l) => {
|
|
609
628
|
this.changeItem(!0, [l], !1);
|
|
610
|
-
}),
|
|
629
|
+
}), u.forEach((l) => {
|
|
611
630
|
this.changeItem(!1, [l], !1);
|
|
612
631
|
});
|
|
613
632
|
},
|
|
614
633
|
handleItem() {
|
|
615
|
-
let
|
|
616
|
-
const e = (
|
|
617
|
-
const
|
|
618
|
-
return this.checkedKeys.includes(n.id) ? (n.checked = !0, n.isIndeterminate = !1) : (n.checked = !1, n.isIndeterminate =
|
|
619
|
-
}),
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
634
|
+
let s = [...this.menuTreeData];
|
|
635
|
+
const e = (t) => (t = t.filter((n, i) => {
|
|
636
|
+
const a = this.checkedKeys.filter((o) => n.menuIds.includes(o));
|
|
637
|
+
return this.checkedKeys.includes(n.id) ? (n.checked = !0, n.isIndeterminate = !1) : (n.checked = !1, n.isIndeterminate = a.length > 0 && n.menuIds.length > 0), n.children && n.children.length > 0 && (n.children = e(n.children)), !0;
|
|
638
|
+
}), t);
|
|
639
|
+
s.forEach((t) => {
|
|
640
|
+
e(t.children);
|
|
641
|
+
}), this.menuTreeData = [...s], this.allClose = this.checkedKeys.length === this.allCheckedKeys.length && this.allCheckedKeys.length > 0;
|
|
642
|
+
},
|
|
643
|
+
changeAll(s) {
|
|
644
|
+
s ? this.checkedKeys = [...this.allCheckedKeys] : this.checkedKeys = [], this.handleItem();
|
|
624
645
|
},
|
|
625
646
|
init() {
|
|
626
|
-
this.confirmLoading = !0, Promise.all([this.getMenuTree(), this.expandedMenuKeys(), this.getMenuList()]).then(async (
|
|
627
|
-
let e = [],
|
|
628
|
-
const n = (
|
|
629
|
-
const
|
|
630
|
-
return
|
|
631
|
-
}),
|
|
632
|
-
let i = this.menuAll.filter((
|
|
647
|
+
this.confirmLoading = !0, Promise.all([this.getMenuTree(), this.expandedMenuKeys(), this.getMenuList(), this.getAppListByAppsId()]).then(async (s) => {
|
|
648
|
+
let e = [], t = [];
|
|
649
|
+
const n = (d) => (d = d.filter((c, h) => {
|
|
650
|
+
const y = this.checkedKeys.filter((b) => c.id === b)[0];
|
|
651
|
+
return c.open = !0, c.checked = c.type === 1 ? !!y : !1, c.isIndeterminate = !1, c.menusType = c.type, e.push(c.id), t.push(c), c.children && c.children.length > 0 && (c.children = n(c.children)), !0;
|
|
652
|
+
}), d);
|
|
653
|
+
let i = this.menuAll.filter((d) => {
|
|
654
|
+
const c = this.systemMenuAll.filter((h) => h.id === d.id)[0];
|
|
655
|
+
return c && (d.application = c.application), !!c;
|
|
656
|
+
});
|
|
633
657
|
await n(i), this.allCheckedKeys = e;
|
|
634
|
-
let
|
|
635
|
-
|
|
636
|
-
const
|
|
637
|
-
|
|
638
|
-
}), this.list =
|
|
639
|
-
const o = this.checkedKeys.filter((
|
|
640
|
-
this.checkedKeys = o, this.allClose = this.checkedKeys.length === e.length && e.length > 0
|
|
658
|
+
let a = [];
|
|
659
|
+
t.forEach((d, c) => {
|
|
660
|
+
const h = this.getMenuIds(d);
|
|
661
|
+
t[c].menuIds = h.arr, t[c].menuBtnIds = h.btn, !(this.checkedKeys.filter((k) => h.arr.includes(k)).length === h.arr.length) && h.arr.length > 0 && a.push(d.id);
|
|
662
|
+
}), this.list = t;
|
|
663
|
+
const o = this.checkedKeys.filter((d) => e.includes(d)).filter((d) => !a.includes(d)).filter((d, c, h) => h.indexOf(d) === c);
|
|
664
|
+
this.checkedKeys = o, this.allClose = this.checkedKeys.length === e.length && e.length > 0;
|
|
665
|
+
let r = [], u = this.appList.filter((d) => {
|
|
666
|
+
const c = i.filter((h) => h.application === d.code);
|
|
667
|
+
return c.length > 0 ? (r = r.concat([...c]), d.children = [...c], d.open = !0, d.uuid = `${f(12)}`, !0) : !1;
|
|
668
|
+
});
|
|
669
|
+
const l = i.filter((d) => !r.filter((h) => h.id === d.id));
|
|
670
|
+
l.length > 0 && u.push({
|
|
671
|
+
name: "\u7A7A\u767D",
|
|
672
|
+
transkey: "gd.echarts.none",
|
|
673
|
+
children: l,
|
|
674
|
+
activeShow: !0,
|
|
675
|
+
open: !0,
|
|
676
|
+
uuid: `${f(12)}`
|
|
677
|
+
}), this.menuTreeData = [...u], this.handleItem(), this.confirmLoading = !1;
|
|
641
678
|
});
|
|
642
679
|
},
|
|
643
|
-
open(
|
|
644
|
-
this.record =
|
|
680
|
+
open(s, e) {
|
|
681
|
+
this.record = s, this.appsId = e || window.$systemInfo.id, this.visible = !0, this.init();
|
|
645
682
|
},
|
|
646
683
|
getMenuTree() {
|
|
647
|
-
return
|
|
684
|
+
return B({ roleId: this.record.id }).then((s) => (s.code === 200 && (this.menuAll = s.data), s));
|
|
648
685
|
},
|
|
649
686
|
expandedMenuKeys() {
|
|
650
|
-
return
|
|
687
|
+
return $({
|
|
651
688
|
id: this.record.id
|
|
652
|
-
}).then((
|
|
689
|
+
}).then((s) => (s.code === 200 && (this.checkedKeys = s.data), s));
|
|
653
690
|
},
|
|
654
691
|
getMenuList() {
|
|
655
|
-
let
|
|
656
|
-
return
|
|
657
|
-
},
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
692
|
+
let s = { AppsId: this.appsId };
|
|
693
|
+
return F(s).then((e) => (e.code === 200 && (this.systemMenuAll = e.data), e));
|
|
694
|
+
},
|
|
695
|
+
getAppListByAppsId() {
|
|
696
|
+
return M({ appsId: this.appsId }).then((s) => (s.code === 200 && (this.appList = s.data), s));
|
|
697
|
+
},
|
|
698
|
+
getMenuIds(s) {
|
|
699
|
+
let e = [], t = [];
|
|
700
|
+
const n = (i) => (i = i.filter((a, o) => (a.menusType !== 2 ? e.push(a.id) : t.push(a.id), a.children && a.children.length > 0 && (a.children = n(a.children)), !0)), i);
|
|
701
|
+
return s.children && n(s.children), { arr: e, btn: t };
|
|
702
|
+
},
|
|
703
|
+
findParent(s, e, t) {
|
|
704
|
+
for (let n of s)
|
|
705
|
+
if (n.id === e.parentId || n.children && n.children.length > 0 && this.findParent(n.children, e, t))
|
|
706
|
+
return t.unshift(n), !0;
|
|
667
707
|
return !1;
|
|
668
708
|
},
|
|
669
709
|
closed() {
|
|
@@ -672,31 +712,43 @@ const X = {
|
|
|
672
712
|
toggleFullscreen() {
|
|
673
713
|
this.fullscreen = !this.fullscreen;
|
|
674
714
|
},
|
|
675
|
-
|
|
676
|
-
|
|
715
|
+
fadeColor(s, e) {
|
|
716
|
+
let t = parseInt(s.substring(1, 3), 16), n = parseInt(s.substring(3, 5), 16), i = parseInt(s.substring(5, 7), 16);
|
|
717
|
+
return `rgba(${t},${n},${i},${e})`;
|
|
718
|
+
},
|
|
719
|
+
doEvent(s) {
|
|
720
|
+
const e = s.item.functionName;
|
|
677
721
|
this[e] && this[e]();
|
|
678
722
|
}
|
|
679
723
|
}
|
|
680
724
|
};
|
|
681
|
-
var
|
|
682
|
-
var e = this,
|
|
683
|
-
return
|
|
725
|
+
var ne = function() {
|
|
726
|
+
var e = this, t = e._self._c;
|
|
727
|
+
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, "custom-class": e.customClass }, on: { "update:visible": function(n) {
|
|
684
728
|
e.visible = n;
|
|
685
|
-
}, closed: e.closed } }, [
|
|
729
|
+
}, 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, btnFlex: "width:auto" }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, scopedSlots: e._u([{ key: "operator", fn: function() {
|
|
730
|
+
return [t("el-dropdown", { attrs: { placement: "bottom" }, on: { command: e.elScrollIntoView } }, [t("el-button", { staticStyle: { margin: "0 1px 0 0", padding: "6px 8px", "font-size": "13px" }, attrs: { type: "primary" } }, [t("i", { staticClass: "gd-icons gd-icon-dingwei1", staticStyle: { "font-size": "14px" } }), e._v(" " + e._s(e.$i18nt("gd.web.location", "\u5B9A\u4F4D")) + " "), t("i", { staticClass: "el-icon-arrow-down" })]), t("el-dropdown-menu", { style: { "--dilute": e.fadeColord, minWidth: "120px" }, attrs: { slot: "dropdown" }, slot: "dropdown" }, e._l(e.menuTreeData, function(n) {
|
|
731
|
+
return t("el-dropdown-item", { key: n.uuid, attrs: { command: n.uuid } }, [t("i", { staticClass: "gd-icons el-icon-right", staticStyle: { "font-size": "14px" } }), n.activeShow ? t("span", [e._v(e._s(e.$i18nt(n.transkey, n.name)))]) : t("span", [e._v(e._s(e.$i18nt(`Dynamics.${n.transkey}`, n.name)))])]);
|
|
732
|
+
}), 1)], 1)];
|
|
733
|
+
}, proxy: !0 }]) })], 1), t("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticStyle: { "min-height": "400px" } }, [t("div", { staticClass: "app-list" }, [e._l(e.menuTreeData, function(n, i) {
|
|
734
|
+
return [i != 0 ? t("el-divider") : e._e(), t("div", { staticClass: "app-list-item", class: n.uuid }, [t("div", { staticClass: "app-list-name" }, [n.children && n.children.length > 0 ? t("i", { class: n.open ? "el-icon-caret-bottom" : "el-icon-caret-right", on: { click: function(a) {
|
|
735
|
+
return e.appOpen(i, n);
|
|
736
|
+
} } }) : e._e(), e._v(" " + e._s(n.name) + " ")]), n.open ? t("div", { staticStyle: { "padding-left": "20px" } }, [e.visible ? t("LayoutItem", { attrs: { record: n.children, checkedKeys: e.checkedKeys }, on: { open: e.openItem, change: e.changeItem, checkedBtn: e.checkedItemBtn } }) : e._e()], 1) : e._e()])];
|
|
737
|
+
})], 2)]), 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(n) {
|
|
686
738
|
e.allClose = n;
|
|
687
739
|
}, expression: "allClose" } }, [e._v(" " + e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")) + " ")])], 1)])], 2)], 1);
|
|
688
|
-
},
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
740
|
+
}, ie = [], ae = /* @__PURE__ */ p(
|
|
741
|
+
se,
|
|
742
|
+
ne,
|
|
743
|
+
ie,
|
|
692
744
|
!1,
|
|
693
745
|
null,
|
|
694
|
-
"
|
|
746
|
+
"1e20ac45",
|
|
695
747
|
null,
|
|
696
748
|
null
|
|
697
749
|
);
|
|
698
|
-
const
|
|
699
|
-
const
|
|
750
|
+
const re = ae.exports;
|
|
751
|
+
const le = {
|
|
700
752
|
name: "GdUserRole",
|
|
701
753
|
props: {
|
|
702
754
|
height: {
|
|
@@ -712,7 +764,7 @@ const se = {
|
|
|
712
764
|
default: "page"
|
|
713
765
|
}
|
|
714
766
|
},
|
|
715
|
-
mixins: [
|
|
767
|
+
mixins: [v],
|
|
716
768
|
data() {
|
|
717
769
|
return {
|
|
718
770
|
transKey: "gd.btn.add",
|
|
@@ -729,7 +781,7 @@ const se = {
|
|
|
729
781
|
value: "value"
|
|
730
782
|
},
|
|
731
783
|
defaultExpandedKeys: "",
|
|
732
|
-
loadData: (
|
|
784
|
+
loadData: (s) => A({ roleId: this.openSelecteKeys[0] }).then((e) => (this.getRowId(e.data), { pageNo: 1, pageSize: 1e3, totalRows: 0, rows: e.data })),
|
|
733
785
|
disableBtn: [],
|
|
734
786
|
fileList: [],
|
|
735
787
|
needLoad: !1,
|
|
@@ -939,16 +991,16 @@ const se = {
|
|
|
939
991
|
return this.openMode !== "page";
|
|
940
992
|
},
|
|
941
993
|
getQueryParam() {
|
|
942
|
-
let
|
|
994
|
+
let s = /* @__PURE__ */ new Map();
|
|
943
995
|
for (let e in this.queryParam)
|
|
944
|
-
|
|
945
|
-
return Object.fromEntries(
|
|
996
|
+
s.set(e === "statecodes" ? "searchctatus" : e, this.queryParam[e]);
|
|
997
|
+
return Object.fromEntries(s);
|
|
946
998
|
},
|
|
947
999
|
getFormColumns() {
|
|
948
1000
|
return this.formColumnsuser.filter((e) => (e.prop === "orgid" && (e.treeOptions = [...this.orgTree]), !0));
|
|
949
1001
|
},
|
|
950
1002
|
getTableButtons() {
|
|
951
|
-
return this.tableButtons.filter((
|
|
1003
|
+
return this.tableButtons.filter((s) => (s.show = !this.disableBtn.includes(s.displayName), !0));
|
|
952
1004
|
},
|
|
953
1005
|
getHeight() {
|
|
954
1006
|
return this.height;
|
|
@@ -956,34 +1008,34 @@ const se = {
|
|
|
956
1008
|
styled() {
|
|
957
1009
|
return `height:${this.height + 76}px`;
|
|
958
1010
|
},
|
|
959
|
-
...
|
|
1011
|
+
...g(["tablePageSize", "tableSize", "labelPosition", "formMode"])
|
|
960
1012
|
},
|
|
961
1013
|
methods: {
|
|
962
|
-
getRowId(
|
|
1014
|
+
getRowId(s) {
|
|
963
1015
|
let e = [];
|
|
964
|
-
|
|
965
|
-
e.push(
|
|
1016
|
+
s.filter((t) => !this.disabledRowId.includes(t.id)).forEach((t) => {
|
|
1017
|
+
e.push(t.id);
|
|
966
1018
|
}), this.disabledRowId = this.disabledRowId.concat(e);
|
|
967
1019
|
},
|
|
968
|
-
saveQueries(
|
|
1020
|
+
saveQueries(s) {
|
|
969
1021
|
this.queryParam = {
|
|
970
|
-
...
|
|
1022
|
+
...s
|
|
971
1023
|
}, this.refresh();
|
|
972
1024
|
},
|
|
973
1025
|
refresh() {
|
|
974
1026
|
this.$refs.table.refresh();
|
|
975
1027
|
},
|
|
976
1028
|
getOrgTree() {
|
|
977
|
-
|
|
978
|
-
if (
|
|
979
|
-
const e = (
|
|
980
|
-
this.orgTree = e(
|
|
1029
|
+
_({}).then((s) => {
|
|
1030
|
+
if (s.code === 200) {
|
|
1031
|
+
const e = (t) => (t = t.filter((n, i) => (n.value = String(n.value), n.children && n.children.length > 0 && (n.children = e(n.children)), !0)), t);
|
|
1032
|
+
this.orgTree = e(s.data);
|
|
981
1033
|
}
|
|
982
1034
|
this.loading = !1;
|
|
983
1035
|
});
|
|
984
1036
|
},
|
|
985
|
-
handleNodeClick(
|
|
986
|
-
this.queryParam.orgId ===
|
|
1037
|
+
handleNodeClick(s) {
|
|
1038
|
+
this.queryParam.orgId === s.id ? (delete this.queryParam.orgId, this.$nextTick(() => {
|
|
987
1039
|
setTimeout(() => {
|
|
988
1040
|
this.$refs.tree.setCurrentKey(null);
|
|
989
1041
|
}, 0);
|
|
@@ -992,28 +1044,28 @@ const se = {
|
|
|
992
1044
|
...this.queryParam
|
|
993
1045
|
},
|
|
994
1046
|
{
|
|
995
|
-
orgId:
|
|
1047
|
+
orgId: s.id
|
|
996
1048
|
}
|
|
997
1049
|
), this.refresh();
|
|
998
1050
|
},
|
|
999
1051
|
handleOk() {
|
|
1000
1052
|
this.$refs.table.refresh();
|
|
1001
1053
|
},
|
|
1002
|
-
onSelectChange(
|
|
1003
|
-
this.selectedRowKeys =
|
|
1054
|
+
onSelectChange(s, e) {
|
|
1055
|
+
this.selectedRowKeys = s, this.selectedRows = e;
|
|
1004
1056
|
},
|
|
1005
|
-
doEvent(
|
|
1006
|
-
let e =
|
|
1057
|
+
doEvent(s) {
|
|
1058
|
+
let e = s.item.functionName;
|
|
1007
1059
|
this[e] && this[e]();
|
|
1008
1060
|
},
|
|
1009
|
-
lookupSeled(
|
|
1010
|
-
if (
|
|
1061
|
+
lookupSeled(s) {
|
|
1062
|
+
if (s.fkData.length === 0) {
|
|
1011
1063
|
this.$refs.engineSearch.closed();
|
|
1012
1064
|
return;
|
|
1013
1065
|
}
|
|
1014
|
-
this.$refs.engineSearch.confirmLoading = !0,
|
|
1066
|
+
this.$refs.engineSearch.confirmLoading = !0, O({
|
|
1015
1067
|
roleId: this.openSelecteKeys[0],
|
|
1016
|
-
userIdList:
|
|
1068
|
+
userIdList: s.data
|
|
1017
1069
|
}).then((e) => {
|
|
1018
1070
|
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;
|
|
1019
1071
|
});
|
|
@@ -1027,7 +1079,7 @@ const se = {
|
|
|
1027
1079
|
});
|
|
1028
1080
|
},
|
|
1029
1081
|
del() {
|
|
1030
|
-
let
|
|
1082
|
+
let s = this;
|
|
1031
1083
|
if (this.selectedRowKeys.length === 0) {
|
|
1032
1084
|
this.$message.warning(this.$i18nt("gd.https.delTip", "\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));
|
|
1033
1085
|
return;
|
|
@@ -1044,16 +1096,16 @@ const se = {
|
|
|
1044
1096
|
customClass: "custom-alert",
|
|
1045
1097
|
callback: () => {
|
|
1046
1098
|
},
|
|
1047
|
-
beforeClose: (e,
|
|
1099
|
+
beforeClose: (e, t, n) => {
|
|
1048
1100
|
if (e !== "confirm") {
|
|
1049
1101
|
n();
|
|
1050
1102
|
return;
|
|
1051
1103
|
}
|
|
1052
|
-
|
|
1053
|
-
roleId:
|
|
1054
|
-
userIdList:
|
|
1104
|
+
t.confirmButtonLoading = !0, t.cancelButtonLoading = !0, t.showCancelButton = !1, P({
|
|
1105
|
+
roleId: s.openSelecteKeys[0],
|
|
1106
|
+
userIdList: s.selectedRowKeys
|
|
1055
1107
|
}).then((i) => {
|
|
1056
|
-
i.success ? (
|
|
1108
|
+
i.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, n(), s.refresh()) : s.$message.error(s.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + i.message);
|
|
1057
1109
|
});
|
|
1058
1110
|
}
|
|
1059
1111
|
});
|
|
@@ -1062,33 +1114,33 @@ const se = {
|
|
|
1062
1114
|
created() {
|
|
1063
1115
|
}
|
|
1064
1116
|
};
|
|
1065
|
-
var
|
|
1066
|
-
var e = this,
|
|
1067
|
-
return
|
|
1068
|
-
return [
|
|
1117
|
+
var oe = function() {
|
|
1118
|
+
var e = this, t = e._self._c;
|
|
1119
|
+
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() {
|
|
1120
|
+
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)])];
|
|
1069
1121
|
}, proxy: !0 }, { key: "name", fn: function({ column: n, row: i }) {
|
|
1070
|
-
return [
|
|
1122
|
+
return [t("span", { staticClass: "active-color", staticStyle: { cursor: "pointer" } }, [e._v(" " + e._s(i.name) + " ")])];
|
|
1071
1123
|
} }, { key: "nickname", fn: function({ column: n, row: i }) {
|
|
1072
|
-
return [
|
|
1124
|
+
return [t("span", { staticStyle: { cursor: "pointer" } }, [e._v(" " + e._s(i.nickname) + " ")])];
|
|
1073
1125
|
} }, { key: "orgname", fn: function({ column: n, row: i }) {
|
|
1074
|
-
return [
|
|
1126
|
+
return [t("span", { staticStyle: { cursor: "pointer" } }, [e._v(" " + e._s(i.orgname) + " ")])];
|
|
1075
1127
|
} }, { key: "sex", fn: function({ column: n, row: i }) {
|
|
1076
|
-
return [
|
|
1128
|
+
return [t("span", [e._v(" " + e._s(e._f("dictType")("gender", i.gender)) + " ")])];
|
|
1077
1129
|
} }, { key: "status", fn: function({ column: n, row: i }) {
|
|
1078
|
-
return [
|
|
1079
|
-
} }]) }),
|
|
1080
|
-
},
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1130
|
+
return [t("span", [e._v(" " + e._s(e._f("dictType")("state_code", i.statecodes)) + " ")])];
|
|
1131
|
+
} }]) }), t("gd-search", { ref: "engineSearch", attrs: { appendToBody: !0, disabledRowId: e.disabledRowId }, on: { lookupSeled: e.lookupSeled } })], 1)]);
|
|
1132
|
+
}, de = [], ce = /* @__PURE__ */ p(
|
|
1133
|
+
le,
|
|
1134
|
+
oe,
|
|
1135
|
+
de,
|
|
1084
1136
|
!1,
|
|
1085
1137
|
null,
|
|
1086
1138
|
"e9dd56ab",
|
|
1087
1139
|
null,
|
|
1088
1140
|
null
|
|
1089
1141
|
);
|
|
1090
|
-
const
|
|
1091
|
-
const
|
|
1142
|
+
const he = ce.exports;
|
|
1143
|
+
const ue = {
|
|
1092
1144
|
data() {
|
|
1093
1145
|
return {
|
|
1094
1146
|
buttons: [],
|
|
@@ -1100,19 +1152,19 @@ const le = {
|
|
|
1100
1152
|
selectedRowKeys: []
|
|
1101
1153
|
};
|
|
1102
1154
|
},
|
|
1103
|
-
components: { UserFormDate:
|
|
1155
|
+
components: { UserFormDate: he },
|
|
1104
1156
|
computed: {
|
|
1105
1157
|
height() {
|
|
1106
1158
|
return this.screenHeight - (this.fullscreen ? 160 : 340);
|
|
1107
1159
|
},
|
|
1108
|
-
...
|
|
1160
|
+
...g(["screenHeight"])
|
|
1109
1161
|
},
|
|
1110
1162
|
methods: {
|
|
1111
1163
|
handleSubmit() {
|
|
1112
1164
|
this.closed(), this.$emit("ok");
|
|
1113
1165
|
},
|
|
1114
|
-
open(
|
|
1115
|
-
this.record =
|
|
1166
|
+
open(s) {
|
|
1167
|
+
this.record = s, this.visible = !0, this.selectedRowKeys = [s.id], this.$nextTick(() => {
|
|
1116
1168
|
setTimeout(() => {
|
|
1117
1169
|
this.$refs.userForm.refresh();
|
|
1118
1170
|
}, 0);
|
|
@@ -1124,32 +1176,32 @@ const le = {
|
|
|
1124
1176
|
toggleFullscreen() {
|
|
1125
1177
|
this.fullscreen = !this.fullscreen;
|
|
1126
1178
|
},
|
|
1127
|
-
onSelectChange(
|
|
1128
|
-
this.selectedRowKeys =
|
|
1179
|
+
onSelectChange(s) {
|
|
1180
|
+
this.selectedRowKeys = s;
|
|
1129
1181
|
},
|
|
1130
|
-
doEvent(
|
|
1131
|
-
const e =
|
|
1182
|
+
doEvent(s) {
|
|
1183
|
+
const e = s.item.functionName;
|
|
1132
1184
|
this[e] && this[e]();
|
|
1133
1185
|
}
|
|
1134
1186
|
}
|
|
1135
1187
|
};
|
|
1136
|
-
var
|
|
1137
|
-
var e = this,
|
|
1138
|
-
return
|
|
1188
|
+
var ge = function() {
|
|
1189
|
+
var e = this, t = e._self._c;
|
|
1190
|
+
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(n) {
|
|
1139
1191
|
e.visible = n;
|
|
1140
|
-
}, closed: e.closed } }, [
|
|
1141
|
-
},
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1192
|
+
}, 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);
|
|
1193
|
+
}, pe = [], fe = /* @__PURE__ */ p(
|
|
1194
|
+
ue,
|
|
1195
|
+
ge,
|
|
1196
|
+
pe,
|
|
1145
1197
|
!1,
|
|
1146
1198
|
null,
|
|
1147
1199
|
"46b57430",
|
|
1148
1200
|
null,
|
|
1149
1201
|
null
|
|
1150
1202
|
);
|
|
1151
|
-
const
|
|
1152
|
-
const
|
|
1203
|
+
const me = fe.exports;
|
|
1204
|
+
const ye = {
|
|
1153
1205
|
data() {
|
|
1154
1206
|
return {
|
|
1155
1207
|
buttons: [
|
|
@@ -1180,16 +1232,16 @@ const ue = {
|
|
|
1180
1232
|
isIndeterminate() {
|
|
1181
1233
|
return this.allClose ? !1 : this.checkedKeys.length > 0;
|
|
1182
1234
|
},
|
|
1183
|
-
...
|
|
1235
|
+
...g(["screenHeight", "tableLists"])
|
|
1184
1236
|
},
|
|
1185
|
-
components: { LayoutItem:
|
|
1237
|
+
components: { LayoutItem: w },
|
|
1186
1238
|
methods: {
|
|
1187
1239
|
async handleSubmit() {
|
|
1188
|
-
const
|
|
1189
|
-
const i = this.checkedKeys.filter((
|
|
1190
|
-
return
|
|
1240
|
+
const s = (e) => (e = e.filter((t, n) => {
|
|
1241
|
+
const i = this.checkedKeys.filter((a) => t.id === a)[0];
|
|
1242
|
+
return t.type = i ? 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;
|
|
1191
1243
|
}), e);
|
|
1192
|
-
this.confirmLoading = !0, await
|
|
1244
|
+
this.confirmLoading = !0, await s(this.menuAll), T({
|
|
1193
1245
|
roleid: this.record.id,
|
|
1194
1246
|
list: this.menuAll
|
|
1195
1247
|
}).then((e) => {
|
|
@@ -1198,88 +1250,88 @@ const ue = {
|
|
|
1198
1250
|
), this.confirmLoading = !1;
|
|
1199
1251
|
});
|
|
1200
1252
|
},
|
|
1201
|
-
checkedItemBtn(
|
|
1202
|
-
let
|
|
1203
|
-
e === 1 && (
|
|
1253
|
+
checkedItemBtn(s, e) {
|
|
1254
|
+
let t = [...this.checkedKeys].filter((n) => !s.menuBtnIds.includes(n));
|
|
1255
|
+
e === 1 && (t = t.concat(s.menuBtnIds)), this.checkedKeys = [...t], this.handleItem();
|
|
1204
1256
|
},
|
|
1205
|
-
openItem(
|
|
1257
|
+
openItem(s) {
|
|
1206
1258
|
let e = [...this.menuTreeData];
|
|
1207
|
-
const
|
|
1208
|
-
|
|
1259
|
+
const t = (n) => (n = n.filter((i, a) => (i.id === s.id && (i.open = !i.open), i.children && i.children.length > 0 && (i.children = t(i.children)), !0)), n);
|
|
1260
|
+
t(e), this.menuTreeData = [...e];
|
|
1209
1261
|
},
|
|
1210
|
-
changeItem(
|
|
1262
|
+
changeItem(s, e, t = !0) {
|
|
1211
1263
|
let n = [...this.checkedKeys];
|
|
1212
1264
|
this.checkedKeys.filter((l) => e.includes(l))[0];
|
|
1213
|
-
const i = this.list.filter((l) => e.includes(l.id))[0],
|
|
1214
|
-
if (
|
|
1265
|
+
const i = this.list.filter((l) => e.includes(l.id))[0], a = t && i ? i.menuIds : [];
|
|
1266
|
+
if (s ? n = this.checkedKeys.concat(e).concat(a) : n = this.checkedKeys.filter((l) => !e.includes(l)).filter((l) => !a.includes(l)), this.checkedKeys = [...n], this.handleItem(), i.menusType === 2)
|
|
1215
1267
|
return;
|
|
1216
1268
|
let o = [];
|
|
1217
1269
|
this.findParent(this.menuTreeData, i, o);
|
|
1218
|
-
let
|
|
1270
|
+
let r = [], u = [];
|
|
1219
1271
|
o.forEach((l) => {
|
|
1220
|
-
this.checkedKeys.filter((
|
|
1221
|
-
}),
|
|
1272
|
+
this.checkedKeys.filter((h) => l.menuIds.includes(h)).length === l.menuIds.length && l.menuIds.length > 0 && !l.checked ? r.push(l.id) : u.push(l.id);
|
|
1273
|
+
}), r.forEach((l) => {
|
|
1222
1274
|
this.changeItem(!0, [l], !1);
|
|
1223
|
-
}),
|
|
1275
|
+
}), u.forEach((l) => {
|
|
1224
1276
|
this.changeItem(!1, [l], !1);
|
|
1225
1277
|
});
|
|
1226
1278
|
},
|
|
1227
1279
|
handleItem() {
|
|
1228
|
-
let
|
|
1229
|
-
const e = (
|
|
1230
|
-
const
|
|
1231
|
-
return this.checkedKeys.includes(n.id) ? (n.checked = !0, n.isIndeterminate = !1) : (n.checked = !1, n.isIndeterminate =
|
|
1232
|
-
}),
|
|
1233
|
-
e(
|
|
1280
|
+
let s = [...this.menuTreeData];
|
|
1281
|
+
const e = (t) => (t = t.filter((n, i) => {
|
|
1282
|
+
const a = this.checkedKeys.filter((o) => n.menuIds.includes(o));
|
|
1283
|
+
return this.checkedKeys.includes(n.id) ? (n.checked = !0, n.isIndeterminate = !1) : (n.checked = !1, n.isIndeterminate = a.length > 0 && n.menuIds.length > 0), n.children && n.children.length > 0 && (n.children = e(n.children)), !0;
|
|
1284
|
+
}), t);
|
|
1285
|
+
e(s), this.menuTreeData = [...s], this.allClose = this.checkedKeys.length === this.allCheckedKeys.length && this.allCheckedKeys.length > 0;
|
|
1234
1286
|
},
|
|
1235
|
-
changeAll(
|
|
1236
|
-
|
|
1287
|
+
changeAll(s) {
|
|
1288
|
+
s ? this.checkedKeys = [...this.allCheckedKeys] : this.checkedKeys = [], this.handleItem();
|
|
1237
1289
|
},
|
|
1238
1290
|
init() {
|
|
1239
|
-
this.confirmLoading = !0, Promise.all([this.getList()]).then(async (
|
|
1291
|
+
this.confirmLoading = !0, Promise.all([this.getList()]).then(async (s) => {
|
|
1240
1292
|
this.confirmLoading = !1;
|
|
1241
|
-
let e = JSON.parse(JSON.stringify(this.menuTreeDatad)),
|
|
1242
|
-
const n = (
|
|
1243
|
-
const
|
|
1244
|
-
return o.open = !0, o.checked = o.menusType === 1 ? !!
|
|
1245
|
-
}),
|
|
1293
|
+
let e = JSON.parse(JSON.stringify(this.menuTreeDatad)), t = [];
|
|
1294
|
+
const n = (a) => (a = a.filter((o, r) => {
|
|
1295
|
+
const u = this.checkedKeys.filter((l) => o.id === l)[0];
|
|
1296
|
+
return o.open = !0, o.checked = o.menusType === 1 ? !!u : !1, o.isIndeterminate = !1, t.push(o), o.children && o.children.length > 0 && (o.children = n(o.children)), !0;
|
|
1297
|
+
}), a);
|
|
1246
1298
|
await n(e);
|
|
1247
1299
|
let i = [];
|
|
1248
|
-
|
|
1249
|
-
const
|
|
1250
|
-
|
|
1251
|
-
}), this.list =
|
|
1300
|
+
t.forEach((a, o) => {
|
|
1301
|
+
const r = this.getMenuIds(a);
|
|
1302
|
+
t[o].menuIds = r.arr, t[o].menuBtnIds = r.btn, !(this.checkedKeys.filter((d) => r.arr.includes(d)).length === r.arr.length) && r.arr.length > 0 && i.push(a.id);
|
|
1303
|
+
}), 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");
|
|
1252
1304
|
});
|
|
1253
1305
|
},
|
|
1254
1306
|
getList() {
|
|
1255
|
-
return
|
|
1256
|
-
if (
|
|
1257
|
-
let e = [],
|
|
1258
|
-
const n = (
|
|
1259
|
-
|
|
1307
|
+
return C({ roleId: this.record.id }).then((s) => {
|
|
1308
|
+
if (s.code === 200) {
|
|
1309
|
+
let e = [], t = [];
|
|
1310
|
+
const n = (a, o) => (a = a.filter((r, u) => {
|
|
1311
|
+
r.parentId = o, 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);
|
|
1260
1312
|
let l = [];
|
|
1261
|
-
return
|
|
1262
|
-
}),
|
|
1263
|
-
this.menuAll =
|
|
1313
|
+
return r.viewlist && r.viewlist.length > 0 && (r.viewlist.map((d) => (d.iconClass = "gd-icon-shitumoshi", d)), l = l.concat(r.viewlist)), r.formlist && r.formlist.length > 0 && (r.formlist.map((d) => (d.iconClass = "gd-icon-biaodanmoshi", d)), l = l.concat(r.formlist)), r.btnlist && r.btnlist.length > 0 && (l = l.concat(r.btnlist)), l.length > 0 && (r.children = n(l, r.id)), !0;
|
|
1314
|
+
}), a);
|
|
1315
|
+
this.menuAll = s.data.list;
|
|
1264
1316
|
let i = JSON.parse(JSON.stringify(this.menuAll));
|
|
1265
|
-
n(i, 0), this.checkedKeys = e, this.allCheckedKeys =
|
|
1317
|
+
n(i, 0), this.checkedKeys = e, this.allCheckedKeys = t, this.menuTreeDatad = [...i];
|
|
1266
1318
|
}
|
|
1267
|
-
return
|
|
1319
|
+
return s;
|
|
1268
1320
|
});
|
|
1269
1321
|
},
|
|
1270
|
-
getMenuIds(
|
|
1271
|
-
let e = [],
|
|
1272
|
-
const n = (i) => (i = i.filter((
|
|
1273
|
-
return
|
|
1322
|
+
getMenuIds(s) {
|
|
1323
|
+
let e = [], t = [];
|
|
1324
|
+
const n = (i) => (i = i.filter((a, o) => (a.menusType !== 2 ? e.push(a.id) : t.push(a.id), a.children && a.children.length > 0 && (a.children = n(a.children)), !0)), i);
|
|
1325
|
+
return s.children && n(s.children), { arr: e, btn: t };
|
|
1274
1326
|
},
|
|
1275
|
-
findParent(
|
|
1276
|
-
for (let n of
|
|
1277
|
-
if (n.id === e.parentId || n.children && n.children.length > 0 && this.findParent(n.children, e,
|
|
1278
|
-
return
|
|
1327
|
+
findParent(s, e, t) {
|
|
1328
|
+
for (let n of s)
|
|
1329
|
+
if (n.id === e.parentId || n.children && n.children.length > 0 && this.findParent(n.children, e, t))
|
|
1330
|
+
return t.unshift(n), !0;
|
|
1279
1331
|
return !1;
|
|
1280
1332
|
},
|
|
1281
|
-
open(
|
|
1282
|
-
this.record =
|
|
1333
|
+
open(s) {
|
|
1334
|
+
this.record = s, this.visible = !0, this.init();
|
|
1283
1335
|
},
|
|
1284
1336
|
closed() {
|
|
1285
1337
|
this.fullscreen = !1, this.visible = !1, this.menuTreeData = [], this.checkedKeys = [];
|
|
@@ -1287,31 +1339,31 @@ const ue = {
|
|
|
1287
1339
|
toggleFullscreen() {
|
|
1288
1340
|
this.fullscreen = !this.fullscreen;
|
|
1289
1341
|
},
|
|
1290
|
-
doEvent(
|
|
1291
|
-
const e =
|
|
1342
|
+
doEvent(s) {
|
|
1343
|
+
const e = s.item.functionName;
|
|
1292
1344
|
this[e] && this[e]();
|
|
1293
1345
|
}
|
|
1294
1346
|
}
|
|
1295
1347
|
};
|
|
1296
|
-
var
|
|
1297
|
-
var e = this,
|
|
1298
|
-
return
|
|
1348
|
+
var be = function() {
|
|
1349
|
+
var e = this, t = e._self._c;
|
|
1350
|
+
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(n) {
|
|
1299
1351
|
e.visible = n;
|
|
1300
|
-
}, closed: e.closed } }, [
|
|
1352
|
+
}, 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(n) {
|
|
1301
1353
|
e.allClose = n;
|
|
1302
1354
|
}, expression: "allClose" } }, [e._v(" " + e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")) + " ")])], 1)])], 2)], 1);
|
|
1303
|
-
},
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1355
|
+
}, ve = [], _e = /* @__PURE__ */ p(
|
|
1356
|
+
ye,
|
|
1357
|
+
be,
|
|
1358
|
+
ve,
|
|
1307
1359
|
!1,
|
|
1308
1360
|
null,
|
|
1309
1361
|
"e6593396",
|
|
1310
1362
|
null,
|
|
1311
1363
|
null
|
|
1312
1364
|
);
|
|
1313
|
-
const
|
|
1314
|
-
const
|
|
1365
|
+
const we = _e.exports;
|
|
1366
|
+
const ke = {
|
|
1315
1367
|
name: "GdRole",
|
|
1316
1368
|
props: {
|
|
1317
1369
|
height: {
|
|
@@ -1327,7 +1379,7 @@ const ye = {
|
|
|
1327
1379
|
default: () => []
|
|
1328
1380
|
}
|
|
1329
1381
|
},
|
|
1330
|
-
mixins: [
|
|
1382
|
+
mixins: [v, z],
|
|
1331
1383
|
data() {
|
|
1332
1384
|
return {
|
|
1333
1385
|
appsId: "",
|
|
@@ -1338,13 +1390,13 @@ const ye = {
|
|
|
1338
1390
|
selectedRows: [],
|
|
1339
1391
|
queryParam: {},
|
|
1340
1392
|
allRowData: [],
|
|
1341
|
-
loadData: (
|
|
1393
|
+
loadData: (s) => (this.selectedKeep && (this.selectedRowKeys = [...this.openSelecteKeys]), I(Object.assign(s, this.queryParam, { sysAppsId: window.$systemInfo.id })).then((e) => (this.allRowData = e.data, e.data)))
|
|
1342
1394
|
};
|
|
1343
1395
|
},
|
|
1344
|
-
components: { RoleGrant:
|
|
1396
|
+
components: { RoleGrant: X, RoleMenu: re, RoleMenuViewForm: we, UserAuthorization: me },
|
|
1345
1397
|
computed: {
|
|
1346
1398
|
getTableButtons() {
|
|
1347
|
-
return this.tableButtons.filter((
|
|
1399
|
+
return this.tableButtons.filter((s) => s.functionName === "grantRoleAppMenu" ? !!this.appsId : !0);
|
|
1348
1400
|
},
|
|
1349
1401
|
initialLoading() {
|
|
1350
1402
|
return this.openMode === "page";
|
|
@@ -1353,17 +1405,17 @@ const ye = {
|
|
|
1353
1405
|
return this.openMode !== "page";
|
|
1354
1406
|
},
|
|
1355
1407
|
getFormColumns() {
|
|
1356
|
-
return this.formColumns.filter((
|
|
1408
|
+
return this.formColumns.filter((s) => (s.prop === "code" && (s.disabled = this.transKey !== "gd.btn.add"), !(this.transKey === "gd.https.copy" && s.prop === "code")));
|
|
1357
1409
|
},
|
|
1358
1410
|
getHeight() {
|
|
1359
1411
|
return this.height;
|
|
1360
1412
|
},
|
|
1361
|
-
...
|
|
1413
|
+
...g(["tablePageSize", "tableSize", "labelPosition", "formMode"])
|
|
1362
1414
|
},
|
|
1363
1415
|
methods: {
|
|
1364
1416
|
getAppId() {
|
|
1365
|
-
|
|
1366
|
-
|
|
1417
|
+
E({ code: "App_Id" }).then((s) => {
|
|
1418
|
+
s.code === 200 && (this.appsId = s.data ? s.data.value : "");
|
|
1367
1419
|
});
|
|
1368
1420
|
},
|
|
1369
1421
|
userAuthorizationMenu() {
|
|
@@ -1421,14 +1473,14 @@ const ye = {
|
|
|
1421
1473
|
}
|
|
1422
1474
|
this.$refs.roleMenuViewForm.open(this.selectedRows[0]);
|
|
1423
1475
|
},
|
|
1424
|
-
saveQueries(
|
|
1425
|
-
this.queryParam = { ...
|
|
1476
|
+
saveQueries(s) {
|
|
1477
|
+
this.queryParam = { ...s }, this.refresh();
|
|
1426
1478
|
},
|
|
1427
1479
|
refresh() {
|
|
1428
1480
|
this.$refs.table.refresh();
|
|
1429
1481
|
},
|
|
1430
|
-
editForm(
|
|
1431
|
-
this.transKey = "gd.btn.edit", this.$refs.editForm.open(
|
|
1482
|
+
editForm(s) {
|
|
1483
|
+
this.transKey = "gd.btn.edit", this.$refs.editForm.open(s);
|
|
1432
1484
|
},
|
|
1433
1485
|
del() {
|
|
1434
1486
|
if (this.selectedRowKeys.length === 0) {
|
|
@@ -1447,23 +1499,23 @@ const ye = {
|
|
|
1447
1499
|
customClass: "custom-alert",
|
|
1448
1500
|
callback: () => {
|
|
1449
1501
|
},
|
|
1450
|
-
beforeClose: (
|
|
1451
|
-
this.delHand(
|
|
1502
|
+
beforeClose: (s, e, t) => {
|
|
1503
|
+
this.delHand(s, e, t);
|
|
1452
1504
|
}
|
|
1453
1505
|
});
|
|
1454
1506
|
},
|
|
1455
|
-
delHand(
|
|
1456
|
-
if (
|
|
1457
|
-
|
|
1507
|
+
delHand(s, e, t) {
|
|
1508
|
+
if (s !== "confirm") {
|
|
1509
|
+
t();
|
|
1458
1510
|
return;
|
|
1459
1511
|
}
|
|
1460
1512
|
let n = [];
|
|
1461
1513
|
this.selectedRows.forEach((i) => {
|
|
1462
|
-
let
|
|
1463
|
-
n.push(
|
|
1514
|
+
let a = R(i).then((o) => o);
|
|
1515
|
+
n.push(a);
|
|
1464
1516
|
}), e.confirmButtonLoading = !0, e.cancelButtonLoading = !0, e.showCancelButton = !1, Promise.all(n).then((i) => {
|
|
1465
|
-
const
|
|
1466
|
-
|
|
1517
|
+
const a = i.filter((o) => !o.success);
|
|
1518
|
+
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;
|
|
1467
1519
|
});
|
|
1468
1520
|
},
|
|
1469
1521
|
add() {
|
|
@@ -1491,19 +1543,19 @@ const ye = {
|
|
|
1491
1543
|
}
|
|
1492
1544
|
this.transKey = "gd.https.copy", this.$refs.editForm.open(Object.assign({ ...this.selectedRows[0] }, { roleId: this.selectedRows[0].id }));
|
|
1493
1545
|
},
|
|
1494
|
-
sbumit({ data:
|
|
1546
|
+
sbumit({ data: s, record: e, btn: t }, n, i) {
|
|
1495
1547
|
this.formLoading = !0;
|
|
1496
|
-
let
|
|
1497
|
-
const o = this.transKey !== "gd.https.edit" ? Object.assign(
|
|
1498
|
-
|
|
1499
|
-
|
|
1548
|
+
let a = e ? this.transKey === "gd.https.copy" ? S : L : x;
|
|
1549
|
+
const o = this.transKey !== "gd.https.edit" ? Object.assign(s, { sysappsid: window.$systemInfo.id }) : s;
|
|
1550
|
+
a(o).then((r) => {
|
|
1551
|
+
r.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), i(), this.refresh()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + r.message), this.formLoading = !1;
|
|
1500
1552
|
});
|
|
1501
1553
|
},
|
|
1502
|
-
onSelectChange(
|
|
1503
|
-
this.selectedRowKeys =
|
|
1554
|
+
onSelectChange(s, e) {
|
|
1555
|
+
this.selectedRowKeys = s, this.selectedRows = e, this.$emit("onSelectChange", s, e, this.allRowData);
|
|
1504
1556
|
},
|
|
1505
|
-
doEvent(
|
|
1506
|
-
let e =
|
|
1557
|
+
doEvent(s) {
|
|
1558
|
+
let e = s.item.functionName;
|
|
1507
1559
|
this[e] && this[e]();
|
|
1508
1560
|
}
|
|
1509
1561
|
},
|
|
@@ -1511,33 +1563,33 @@ const ye = {
|
|
|
1511
1563
|
this.getAppId();
|
|
1512
1564
|
}
|
|
1513
1565
|
};
|
|
1514
|
-
var
|
|
1515
|
-
var e = this,
|
|
1516
|
-
return
|
|
1517
|
-
return [
|
|
1566
|
+
var Ke = function() {
|
|
1567
|
+
var e = this, t = e._self._c;
|
|
1568
|
+
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: n, row: i }) {
|
|
1569
|
+
return [t("gd-tooltip", { attrs: { rowKey: "name", row: i, highlight: "" }, on: { click: e.editForm } })];
|
|
1518
1570
|
} }, { key: "operator", fn: function() {
|
|
1519
|
-
return [
|
|
1571
|
+
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(n) {
|
|
1520
1572
|
return !n.type.indexOf("key") && e._k(n.keyCode, "enter", 13, n.key, "Enter") ? null : e.refresh.apply(null, arguments);
|
|
1521
1573
|
} }, model: { value: e.queryParam.name, callback: function(n) {
|
|
1522
1574
|
e.$set(e.queryParam, "name", n);
|
|
1523
|
-
}, expression: "queryParam.name" } }),
|
|
1575
|
+
}, 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)])];
|
|
1524
1576
|
}, proxy: !0 }, { key: "filtering", fn: function({ colse: n, visible: i }) {
|
|
1525
|
-
return [
|
|
1526
|
-
} }]) })], 1),
|
|
1527
|
-
},
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1577
|
+
return [t("gd-table-queries-field", { attrs: { columns: e.tableQueries, height: e.getHeight, queryParam: e.queryParam, colse: n, visible: i }, on: { save: e.saveQueries } })];
|
|
1578
|
+
} }]) })], 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 } })], 1);
|
|
1579
|
+
}, $e = [], Te = /* @__PURE__ */ p(
|
|
1580
|
+
ke,
|
|
1581
|
+
Ke,
|
|
1582
|
+
$e,
|
|
1531
1583
|
!1,
|
|
1532
1584
|
null,
|
|
1533
1585
|
"005c52d9",
|
|
1534
1586
|
null,
|
|
1535
1587
|
null
|
|
1536
1588
|
);
|
|
1537
|
-
const
|
|
1538
|
-
|
|
1539
|
-
|
|
1589
|
+
const m = Te.exports;
|
|
1590
|
+
m.install = function(s) {
|
|
1591
|
+
s.component(m.name, m);
|
|
1540
1592
|
};
|
|
1541
1593
|
export {
|
|
1542
|
-
|
|
1594
|
+
m as G
|
|
1543
1595
|
};
|