@witlink/usercenter 1.0.0
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/README.md +155 -0
- package/dist/404.e6ab6ba0.mjs +10 -0
- package/dist/Card.71482621.mjs +1078 -0
- package/dist/DictEx.754c617b.mjs +156 -0
- package/dist/FooterToolBar.2546fb1f.mjs +33 -0
- package/dist/RegionSelect.5272534b.mjs +71 -0
- package/dist/Standard.64ae6a8d.mjs +113 -0
- package/dist/WebClient.0ac67ce0.mjs +153 -0
- package/dist/assets/FooterToolBar.d4297046.css +1 -0
- package/dist/assets/Standard.badeec91.css +1 -0
- package/dist/assets/WebClient.2a3e464e.css +1 -0
- package/dist/assets/index.01a0fb63.css +1 -0
- package/dist/assets/index.19e5ba4c.css +1 -0
- package/dist/assets/index.2164de3b.css +1 -0
- package/dist/assets/index.269f5360.css +1 -0
- package/dist/assets/index.28bdbdc3.css +1 -0
- package/dist/assets/index.3150518d.css +1 -0
- package/dist/assets/index.3a0797c4.css +1 -0
- package/dist/assets/index.53c37fa8.css +1 -0
- package/dist/assets/index.7c8e2d8f.css +1 -0
- package/dist/assets/index.b965b94b.css +1 -0
- package/dist/assets/index.fb7724ee.css +1 -0
- package/dist/index.003313e6.mjs +69436 -0
- package/dist/index.05ef920d.mjs +1129 -0
- package/dist/index.1953dbda.mjs +498 -0
- package/dist/index.1af0e30d.mjs +10 -0
- package/dist/index.2242d1a7.mjs +125 -0
- package/dist/index.2291c8e2.mjs +125 -0
- package/dist/index.3c2af165.mjs +761 -0
- package/dist/index.919ac6b4.mjs +7431 -0
- package/dist/index.941a34c0.mjs +874 -0
- package/dist/index.96479524.mjs +754 -0
- package/dist/index.9803c44f.mjs +125 -0
- package/dist/index.a000e9cf.mjs +1445 -0
- package/dist/index.b3eb7c5d.mjs +10 -0
- package/dist/index.c9138cba.mjs +1104 -0
- package/dist/index.ceea88a4.mjs +1073 -0
- package/dist/index.da7dd593.mjs +10 -0
- package/dist/index.e271ee9d.mjs +643 -0
- package/dist/index.e7802e27.mjs +786 -0
- package/dist/index.ef2e93a1.mjs +386 -0
- package/dist/index.f701b909.mjs +142 -0
- package/dist/index.f9becca6.mjs +6 -0
- package/dist/index.fa4bb855.mjs +7645 -0
- package/dist/index.html +1 -0
- package/dist/use-dict-by-type.c90c1d31.mjs +24 -0
- package/dist/usercenter.umd.js +6237 -0
- package/package.json +26 -0
- package/version.md +2 -0
|
@@ -0,0 +1,786 @@
|
|
|
1
|
+
import { C as j, D as Q, I as ue, b as ie, bu as me, F as de, S as he, aP as pe, _ as J, aT as fe, aU as ve, aV as ge, bz as ke, B as ye, E as be, G as Ce, a$ as we, aY as Ie, H as $e, aZ as Se, L as Ae, M as De, N as xe, bA as Ne } from "./index.003313e6.mjs";
|
|
2
|
+
import { defineComponent as H, ref as r, openBlock as m, createBlock as P, withCtx as o, createVNode as e, mergeProps as oe, onMounted as ee, createElementBlock as x, normalizeClass as Fe, createElementVNode as G, toDisplayString as M, nextTick as Re, watch as Le, createTextVNode as z, createCommentVNode as L, Fragment as ne, renderList as Oe, computed as se, unref as V, reactive as Ue, withDirectives as re, vShow as ce } from "vue";
|
|
3
|
+
import { C as _e, a as Te, S as Ee } from "./index.fa4bb855.mjs";
|
|
4
|
+
import { D as Me } from "./DictEx.754c617b.mjs";
|
|
5
|
+
import { C as te } from "./Card.71482621.mjs";
|
|
6
|
+
import { F as Pe } from "./FooterToolBar.2546fb1f.mjs";
|
|
7
|
+
import { _ as ae, a as le } from "./index.f9becca6.mjs";
|
|
8
|
+
import './assets/index.7c8e2d8f.css';function Be(c) {
|
|
9
|
+
return j({
|
|
10
|
+
url: "/api/sys/role/search-list",
|
|
11
|
+
method: "get",
|
|
12
|
+
params: c
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
function Ve(c) {
|
|
16
|
+
return j({
|
|
17
|
+
url: "/api/sys/role/switch",
|
|
18
|
+
method: "post",
|
|
19
|
+
params: c
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
function je(c) {
|
|
23
|
+
return j({
|
|
24
|
+
url: "/api/sys/role/detail",
|
|
25
|
+
method: "get",
|
|
26
|
+
params: c
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
function ze(c) {
|
|
30
|
+
return j({
|
|
31
|
+
url: "/api/member/myapp/public-search-list",
|
|
32
|
+
method: "get",
|
|
33
|
+
params: c
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
function qe(c) {
|
|
37
|
+
return j({
|
|
38
|
+
url: "/api/sys/role/detail-role",
|
|
39
|
+
method: "get",
|
|
40
|
+
params: c
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
function Ge(c) {
|
|
44
|
+
return j({
|
|
45
|
+
url: "/api/sys/role/update",
|
|
46
|
+
method: "post",
|
|
47
|
+
data: c
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
function Je(c) {
|
|
51
|
+
return j({
|
|
52
|
+
url: "/api/sys/role/insert",
|
|
53
|
+
method: "post",
|
|
54
|
+
params: c
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
const He = /* @__PURE__ */ H({
|
|
58
|
+
__name: "RoleAddModal",
|
|
59
|
+
emits: ["ok", "cancel"],
|
|
60
|
+
setup(c, { emit: O }) {
|
|
61
|
+
const { t: h } = Q(), $ = O, i = r(), d = r(!0), y = r(!0), f = r(!1), v = r({
|
|
62
|
+
roleName: "",
|
|
63
|
+
remark: ""
|
|
64
|
+
}), g = r({
|
|
65
|
+
labelCol: { lg: { span: 7 }, sm: { span: 7 } },
|
|
66
|
+
wrapperCol: { lg: { span: 14 }, sm: { span: 14 } }
|
|
67
|
+
}), p = (t, l) => l == "" ? Promise.reject(h("role.role_name_msg1")) : Promise.resolve();
|
|
68
|
+
function C() {
|
|
69
|
+
$("cancel");
|
|
70
|
+
}
|
|
71
|
+
const a = () => {
|
|
72
|
+
i.value.validate().then(async () => {
|
|
73
|
+
f.value = !0;
|
|
74
|
+
const { result: t } = await Je({
|
|
75
|
+
...v.value
|
|
76
|
+
});
|
|
77
|
+
f.value = !1, t && ($("ok", t), y.value = !1);
|
|
78
|
+
});
|
|
79
|
+
};
|
|
80
|
+
return (t, l) => {
|
|
81
|
+
const u = ue, _ = ie, S = me, s = de, w = he, b = pe;
|
|
82
|
+
return m(), P(b, {
|
|
83
|
+
open: y.value,
|
|
84
|
+
"onUpdate:open": l[2] || (l[2] = (N) => y.value = N),
|
|
85
|
+
width: 560,
|
|
86
|
+
onOk: a,
|
|
87
|
+
onCancel: C,
|
|
88
|
+
title: t.$t("role.add_msg"),
|
|
89
|
+
style: { top: "250px" },
|
|
90
|
+
destroyOnClose: d.value
|
|
91
|
+
}, {
|
|
92
|
+
default: o(() => [
|
|
93
|
+
e(w, { spinning: f.value }, {
|
|
94
|
+
default: o(() => [
|
|
95
|
+
e(s, {
|
|
96
|
+
model: v.value,
|
|
97
|
+
ref_key: "formRef",
|
|
98
|
+
ref: i
|
|
99
|
+
}, {
|
|
100
|
+
default: o(() => [
|
|
101
|
+
e(_, oe({
|
|
102
|
+
label: t.$t("role.role_name")
|
|
103
|
+
}, g.value, {
|
|
104
|
+
name: "roleName",
|
|
105
|
+
rules: [
|
|
106
|
+
{
|
|
107
|
+
required: !0,
|
|
108
|
+
message: t.$t("role.role_name_msg1"),
|
|
109
|
+
validator: p
|
|
110
|
+
}
|
|
111
|
+
]
|
|
112
|
+
}), {
|
|
113
|
+
default: o(() => [
|
|
114
|
+
e(u, {
|
|
115
|
+
placeholder: t.$t("role.role_name_placeholder"),
|
|
116
|
+
value: v.value.roleName,
|
|
117
|
+
"onUpdate:value": l[0] || (l[0] = (N) => v.value.roleName = N)
|
|
118
|
+
}, null, 8, ["placeholder", "value"])
|
|
119
|
+
]),
|
|
120
|
+
_: 1
|
|
121
|
+
}, 16, ["label", "rules"]),
|
|
122
|
+
e(_, oe({
|
|
123
|
+
label: t.$t("role.remark")
|
|
124
|
+
}, g.value, { name: "remark" }), {
|
|
125
|
+
default: o(() => [
|
|
126
|
+
e(S, {
|
|
127
|
+
placeholder: t.$t("role.remark_placeholder"),
|
|
128
|
+
rows: 4,
|
|
129
|
+
value: v.value.remark,
|
|
130
|
+
"onUpdate:value": l[1] || (l[1] = (N) => v.value.remark = N)
|
|
131
|
+
}, null, 8, ["placeholder", "value"])
|
|
132
|
+
]),
|
|
133
|
+
_: 1
|
|
134
|
+
}, 16, ["label"])
|
|
135
|
+
]),
|
|
136
|
+
_: 1
|
|
137
|
+
}, 8, ["model"])
|
|
138
|
+
]),
|
|
139
|
+
_: 1
|
|
140
|
+
}, 8, ["spinning"])
|
|
141
|
+
]),
|
|
142
|
+
_: 1
|
|
143
|
+
}, 8, ["open", "title", "destroyOnClose"]);
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
}), Ke = /* @__PURE__ */ J(He, [["__file", "D:/inhe-code/witlink-platform-usercenter-web/witlink-platform-usercenter1/src/views/sys/role/RoleAddModal.vue"]]), Ye = { class: "name" }, Ze = /* @__PURE__ */ H({
|
|
147
|
+
__name: "AuthList",
|
|
148
|
+
props: {
|
|
149
|
+
roleId: {
|
|
150
|
+
type: Number,
|
|
151
|
+
default: null
|
|
152
|
+
},
|
|
153
|
+
selectItem: {
|
|
154
|
+
type: Number,
|
|
155
|
+
default: null
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
emits: ["select", "checkChange"],
|
|
159
|
+
setup(c, { emit: O }) {
|
|
160
|
+
const h = O, $ = c, i = r([]), d = r(!1), y = (g, p) => {
|
|
161
|
+
d.value = !d.value, p.authFlag = g.target.checked ? 0 : 1, h("checkChange", p);
|
|
162
|
+
}, f = (g, p, C) => {
|
|
163
|
+
h("select", g, C, d.value, p);
|
|
164
|
+
}, v = async () => {
|
|
165
|
+
const { result: g } = await ze({
|
|
166
|
+
roleId: $.roleId
|
|
167
|
+
});
|
|
168
|
+
d.value = !1, i.value = g, i.value.length > 0 && Re(() => {
|
|
169
|
+
f(i.value[0], 0, "init");
|
|
170
|
+
});
|
|
171
|
+
};
|
|
172
|
+
return ee(() => {
|
|
173
|
+
v();
|
|
174
|
+
}), (g, p) => {
|
|
175
|
+
const C = te, a = _e, t = fe, l = ve;
|
|
176
|
+
return m(), x("div", null, [
|
|
177
|
+
e(l, {
|
|
178
|
+
size: "small",
|
|
179
|
+
split: !1,
|
|
180
|
+
"data-source": i.value
|
|
181
|
+
}, {
|
|
182
|
+
renderItem: o(({ item: u, index: _ }) => [
|
|
183
|
+
e(t, { type: "inner" }, {
|
|
184
|
+
default: o(() => [
|
|
185
|
+
e(C, {
|
|
186
|
+
hoverable: !0,
|
|
187
|
+
bordered: !1,
|
|
188
|
+
class: Fe(["a-card", c.selectItem == _ ? "active" : ""]),
|
|
189
|
+
onClick: (S) => f(u, _, "manual")
|
|
190
|
+
}, {
|
|
191
|
+
default: o(() => [
|
|
192
|
+
G("div", Ye, M(u.sysOrgDeploy.deployName), 1)
|
|
193
|
+
]),
|
|
194
|
+
_: 2
|
|
195
|
+
}, 1032, ["onClick", "class"]),
|
|
196
|
+
e(a, {
|
|
197
|
+
style: { "margin-right": "0px" },
|
|
198
|
+
checked: u.authFlag == 0,
|
|
199
|
+
disabled: c.selectItem != _,
|
|
200
|
+
onChange: (S) => y(S, u)
|
|
201
|
+
}, null, 8, ["checked", "disabled", "onChange"])
|
|
202
|
+
]),
|
|
203
|
+
_: 2
|
|
204
|
+
}, 1024)
|
|
205
|
+
]),
|
|
206
|
+
_: 1
|
|
207
|
+
}, 8, ["data-source"])
|
|
208
|
+
]);
|
|
209
|
+
};
|
|
210
|
+
}
|
|
211
|
+
});
|
|
212
|
+
const Qe = /* @__PURE__ */ J(Ze, [["__scopeId", "data-v-debbabd6"], ["__file", "D:/inhe-code/witlink-platform-usercenter-web/witlink-platform-usercenter1/src/components/AuthList/AuthList.vue"]]), We = { key: 0 }, Xe = { key: 1 }, et = /* @__PURE__ */ H({
|
|
213
|
+
__name: "ActDetail",
|
|
214
|
+
props: {
|
|
215
|
+
params: {
|
|
216
|
+
type: Array,
|
|
217
|
+
default: null
|
|
218
|
+
},
|
|
219
|
+
mode: {
|
|
220
|
+
type: String,
|
|
221
|
+
default: ""
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
setup(c, { expose: O }) {
|
|
225
|
+
const { t: h } = Q(), $ = c, i = r([]), d = [
|
|
226
|
+
20,
|
|
227
|
+
102
|
|
228
|
+
], y = r(!1), f = (a) => $.mode === "view" ? a.checkedAll || a.indeterminate : !0, v = (a) => {
|
|
229
|
+
a.indeterminate = !!a.selects.length && a.selects.length < a.options.length, a.checkedAll = a.selects.length === a.options.length;
|
|
230
|
+
}, g = (a, t) => {
|
|
231
|
+
Object.assign(t, {
|
|
232
|
+
selects: a.target.checked ? t.options.map((l) => l.value) : [],
|
|
233
|
+
indeterminate: !1,
|
|
234
|
+
checkedAll: a.target.checked
|
|
235
|
+
});
|
|
236
|
+
}, p = (a) => {
|
|
237
|
+
const t = a.target.checked;
|
|
238
|
+
i.value.forEach((l) => {
|
|
239
|
+
l.selects = t ? l.options.map((u) => u.value) : [], l.checkedAll = t, l.indeterminate = l.selects.length > 0;
|
|
240
|
+
}), i.value = i.value.slice(0);
|
|
241
|
+
};
|
|
242
|
+
return O({
|
|
243
|
+
getDetail: () => {
|
|
244
|
+
const a = [];
|
|
245
|
+
return i.value.forEach((t) => {
|
|
246
|
+
t.selects.length > 0 && a.push({
|
|
247
|
+
id: t.id,
|
|
248
|
+
actions: t.selects.join(",")
|
|
249
|
+
});
|
|
250
|
+
}), a;
|
|
251
|
+
}
|
|
252
|
+
}), Le(
|
|
253
|
+
() => $.params,
|
|
254
|
+
(a) => {
|
|
255
|
+
const t = [];
|
|
256
|
+
if (Array.isArray(a) && a.length == 0 || a == null) {
|
|
257
|
+
i.value = t;
|
|
258
|
+
return;
|
|
259
|
+
}
|
|
260
|
+
a.forEach((l) => {
|
|
261
|
+
const u = [];
|
|
262
|
+
let _ = [];
|
|
263
|
+
for (let s = 0; s < l.actions.length; s++) {
|
|
264
|
+
const w = l.actions[s], b = h("button._" + w.id);
|
|
265
|
+
u.push({
|
|
266
|
+
value: w.id,
|
|
267
|
+
label: b == "" ? w.id : b
|
|
268
|
+
}), w.checked && _.push(w.id);
|
|
269
|
+
}
|
|
270
|
+
const S = l.name;
|
|
271
|
+
d.includes(Number(l.id)) && l.actions.every((s) => !s.checked) && (_ = l.actions.map((s) => s.id)), t.push({
|
|
272
|
+
id: l.id,
|
|
273
|
+
name: S == "" ? l.id : S,
|
|
274
|
+
options: u,
|
|
275
|
+
selects: _,
|
|
276
|
+
checkedAll: u.length === _.length,
|
|
277
|
+
indeterminate: !!_.length && _.length < u.length
|
|
278
|
+
});
|
|
279
|
+
}), i.value = t;
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
deep: !0
|
|
283
|
+
}
|
|
284
|
+
), (a, t) => {
|
|
285
|
+
const l = _e, u = ae, _ = le, S = Te;
|
|
286
|
+
return m(), x("div", null, [
|
|
287
|
+
i.value.length > 0 ? (m(), x("div", We, [
|
|
288
|
+
c.mode !== "view" ? (m(), P(_, {
|
|
289
|
+
key: 0,
|
|
290
|
+
gutter: 16
|
|
291
|
+
}, {
|
|
292
|
+
default: o(() => [
|
|
293
|
+
e(u, {
|
|
294
|
+
offset: 4,
|
|
295
|
+
span: 20,
|
|
296
|
+
class: "col"
|
|
297
|
+
}, {
|
|
298
|
+
default: o(() => [
|
|
299
|
+
e(l, {
|
|
300
|
+
checked: y.value,
|
|
301
|
+
"onUpdate:checked": t[0] || (t[0] = (s) => y.value = s),
|
|
302
|
+
onChange: p
|
|
303
|
+
}, {
|
|
304
|
+
default: o(() => [
|
|
305
|
+
z(M(a.$t("role.operation")), 1)
|
|
306
|
+
]),
|
|
307
|
+
_: 1
|
|
308
|
+
}, 8, ["checked"])
|
|
309
|
+
]),
|
|
310
|
+
_: 1
|
|
311
|
+
})
|
|
312
|
+
]),
|
|
313
|
+
_: 1
|
|
314
|
+
})) : L("v-if", !0),
|
|
315
|
+
(m(!0), x(ne, null, Oe(i.value, (s, w) => (m(), x(ne, null, [
|
|
316
|
+
f(s) ? (m(), P(_, {
|
|
317
|
+
gutter: 16,
|
|
318
|
+
key: w
|
|
319
|
+
}, {
|
|
320
|
+
default: o(() => [
|
|
321
|
+
e(u, {
|
|
322
|
+
span: 4,
|
|
323
|
+
class: "col"
|
|
324
|
+
}, {
|
|
325
|
+
default: o(() => [
|
|
326
|
+
z(M(s.name) + "\uFF1A ", 1)
|
|
327
|
+
]),
|
|
328
|
+
_: 2
|
|
329
|
+
}, 1024),
|
|
330
|
+
e(u, {
|
|
331
|
+
span: 20,
|
|
332
|
+
class: "col"
|
|
333
|
+
}, {
|
|
334
|
+
default: o(() => [
|
|
335
|
+
s.options.length > 0 ? (m(), P(l, {
|
|
336
|
+
key: 0,
|
|
337
|
+
style: { "margin-right": "18px" },
|
|
338
|
+
indeterminate: s.indeterminate,
|
|
339
|
+
checked: s.checkedAll,
|
|
340
|
+
"onUpdate:checked": (b) => s.checkedAll = b,
|
|
341
|
+
onChange: (b) => g(b, s)
|
|
342
|
+
}, {
|
|
343
|
+
default: o(() => [
|
|
344
|
+
z(M(a.$t("role.operation")), 1)
|
|
345
|
+
]),
|
|
346
|
+
_: 2
|
|
347
|
+
}, 1032, ["indeterminate", "checked", "onUpdate:checked", "onChange"])) : L("v-if", !0),
|
|
348
|
+
e(S, {
|
|
349
|
+
options: s.options,
|
|
350
|
+
value: s.selects,
|
|
351
|
+
"onUpdate:value": (b) => s.selects = b,
|
|
352
|
+
onChange: (b) => v(s)
|
|
353
|
+
}, null, 8, ["options", "value", "onUpdate:value", "onChange"])
|
|
354
|
+
]),
|
|
355
|
+
_: 2
|
|
356
|
+
}, 1024)
|
|
357
|
+
]),
|
|
358
|
+
_: 2
|
|
359
|
+
}, 1024)) : L("v-if", !0)
|
|
360
|
+
], 64))), 256))
|
|
361
|
+
])) : (m(), x("div", Xe, M(a.$t("actDetail.text")), 1))
|
|
362
|
+
]);
|
|
363
|
+
};
|
|
364
|
+
}
|
|
365
|
+
});
|
|
366
|
+
const tt = /* @__PURE__ */ J(et, [["__scopeId", "data-v-96c1fdf2"], ["__file", "D:/inhe-code/witlink-platform-usercenter-web/witlink-platform-usercenter1/src/views/sys/role/ActDetail.vue"]]), at = { class: "role-detail-wrap" }, lt = /* @__PURE__ */ H({
|
|
367
|
+
__name: "RoleDetail",
|
|
368
|
+
props: {
|
|
369
|
+
params: {
|
|
370
|
+
type: Object,
|
|
371
|
+
default: null
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
emits: ["cancel", "ok"],
|
|
375
|
+
setup(c, { emit: O }) {
|
|
376
|
+
const { t: h } = Q(), $ = ge(), i = O, d = c, y = r(), f = r(), v = r(), g = r({
|
|
377
|
+
roleId: "",
|
|
378
|
+
roleName: "",
|
|
379
|
+
remark: ""
|
|
380
|
+
}), p = r({
|
|
381
|
+
roleName: "",
|
|
382
|
+
remark: ""
|
|
383
|
+
}), C = r({
|
|
384
|
+
authId: "",
|
|
385
|
+
authFlag: ""
|
|
386
|
+
}), a = r([]), t = r("[]"), l = r(0), u = r(!1), _ = r("\u6743\u9650\u4FEE\u6539\u672A\u4FDD\u5B58\uFF0C\u8BF7\u5148\u63D0\u4EA4\u4FDD\u5B58\u518D\u5207\u6362\u5E73\u53F0"), S = se(() => $.langId), s = se(() => d.params.opType === "2" ? "edit" : d.params.opType === "3" ? "view" : ""), w = () => {
|
|
387
|
+
const n = f.value.getDetail();
|
|
388
|
+
v.value.validate().then(async () => {
|
|
389
|
+
const k = {
|
|
390
|
+
roleId: g.value.roleId,
|
|
391
|
+
authId: C.value.authId,
|
|
392
|
+
authFlag: C.value.authFlag,
|
|
393
|
+
roleName: p.value.roleName,
|
|
394
|
+
remark: p.value.remark,
|
|
395
|
+
detail: n
|
|
396
|
+
}, { result: R } = await Ge(k);
|
|
397
|
+
R && (t.value = JSON.stringify(n), y.value.platFlag = !1, i("ok"), ke.success({
|
|
398
|
+
message: h("common.msg3"),
|
|
399
|
+
description: h("common.msg4")
|
|
400
|
+
}));
|
|
401
|
+
});
|
|
402
|
+
}, b = () => {
|
|
403
|
+
i("cancel");
|
|
404
|
+
}, N = () => {
|
|
405
|
+
u.value = !1;
|
|
406
|
+
}, K = (n) => {
|
|
407
|
+
C.value.authFlag = n.authFlag;
|
|
408
|
+
}, Y = () => {
|
|
409
|
+
u.value = !0;
|
|
410
|
+
}, I = (n) => {
|
|
411
|
+
const k = [];
|
|
412
|
+
n == null || n.forEach((R) => {
|
|
413
|
+
const A = [];
|
|
414
|
+
R.actions.forEach((U) => {
|
|
415
|
+
U.checked && A.push(U.id);
|
|
416
|
+
}), A.length > 0 && k.push({
|
|
417
|
+
id: R.id,
|
|
418
|
+
actions: A.join(",")
|
|
419
|
+
});
|
|
420
|
+
}), t.value = JSON.stringify(k);
|
|
421
|
+
}, F = async (n, k, R, A) => {
|
|
422
|
+
const U = f.value.getDetail();
|
|
423
|
+
k === "init" || d.params.opType === "3" || t.value === JSON.stringify(U) && R == !1 ? (C.value.authId = n.authId, C.value.authFlag = n.authFlag, qe({
|
|
424
|
+
roleId: g.value.roleId,
|
|
425
|
+
authId: n.authId,
|
|
426
|
+
isoCode: S.value
|
|
427
|
+
}).then((D) => {
|
|
428
|
+
a.value = D == null ? void 0 : D.result, I((D == null ? void 0 : D.result) || []), l.value = A;
|
|
429
|
+
})) : Y();
|
|
430
|
+
}, q = async (n) => {
|
|
431
|
+
const { result: k } = await je({ roleId: n });
|
|
432
|
+
return k;
|
|
433
|
+
}, W = async () => {
|
|
434
|
+
if (!d.params || !d.params.roleId)
|
|
435
|
+
return;
|
|
436
|
+
const n = await q(d.params.roleId);
|
|
437
|
+
p.value.roleName = n.roleName, p.value.remark = n.remark, g.value = n;
|
|
438
|
+
};
|
|
439
|
+
return ee(() => {
|
|
440
|
+
W();
|
|
441
|
+
}), (n, k) => {
|
|
442
|
+
const R = pe, A = te, U = ae, D = ue, Z = ie, X = de, T = le, B = ye;
|
|
443
|
+
return m(), x("div", at, [
|
|
444
|
+
e(T, {
|
|
445
|
+
gutter: 16,
|
|
446
|
+
class: "role-detail-content"
|
|
447
|
+
}, {
|
|
448
|
+
default: o(() => [
|
|
449
|
+
e(U, {
|
|
450
|
+
span: 4,
|
|
451
|
+
class: "left"
|
|
452
|
+
}, {
|
|
453
|
+
default: o(() => [
|
|
454
|
+
e(A, {
|
|
455
|
+
title: n.$t("role.svr_list"),
|
|
456
|
+
bordered: !1
|
|
457
|
+
}, {
|
|
458
|
+
cover: o(() => [
|
|
459
|
+
e(V(Qe), {
|
|
460
|
+
ref_key: "authListRef",
|
|
461
|
+
ref: y,
|
|
462
|
+
roleId: d.params.roleId,
|
|
463
|
+
selectItem: l.value,
|
|
464
|
+
onCheckChange: K,
|
|
465
|
+
onSelect: F
|
|
466
|
+
}, null, 8, ["roleId", "selectItem"]),
|
|
467
|
+
e(R, {
|
|
468
|
+
title: "\u63D0\u793A",
|
|
469
|
+
open: u.value,
|
|
470
|
+
"onUpdate:open": k[0] || (k[0] = (E) => u.value = E),
|
|
471
|
+
onCancel: N,
|
|
472
|
+
onOk: N
|
|
473
|
+
}, {
|
|
474
|
+
default: o(() => [
|
|
475
|
+
G("p", null, M(_.value), 1)
|
|
476
|
+
]),
|
|
477
|
+
_: 1
|
|
478
|
+
}, 8, ["open"])
|
|
479
|
+
]),
|
|
480
|
+
_: 1
|
|
481
|
+
}, 8, ["title"])
|
|
482
|
+
]),
|
|
483
|
+
_: 1
|
|
484
|
+
}),
|
|
485
|
+
e(U, {
|
|
486
|
+
span: 20,
|
|
487
|
+
class: "right-box"
|
|
488
|
+
}, {
|
|
489
|
+
default: o(() => [
|
|
490
|
+
e(A, {
|
|
491
|
+
bordered: !1,
|
|
492
|
+
title: n.$t("role.role_info")
|
|
493
|
+
}, {
|
|
494
|
+
default: o(() => [
|
|
495
|
+
e(X, {
|
|
496
|
+
ref_key: "formRef",
|
|
497
|
+
ref: v,
|
|
498
|
+
model: p.value,
|
|
499
|
+
layout: "inline"
|
|
500
|
+
}, {
|
|
501
|
+
default: o(() => [
|
|
502
|
+
e(Z, {
|
|
503
|
+
label: n.$t("role.role_name"),
|
|
504
|
+
name: "roleName",
|
|
505
|
+
rules: [{ required: !0, message: n.$t("role.role_name_msg1") }]
|
|
506
|
+
}, {
|
|
507
|
+
default: o(() => [
|
|
508
|
+
e(D, {
|
|
509
|
+
placeholder: n.$t("role.role_name_placeholder"),
|
|
510
|
+
value: p.value.roleName,
|
|
511
|
+
"onUpdate:value": k[1] || (k[1] = (E) => p.value.roleName = E)
|
|
512
|
+
}, null, 8, ["placeholder", "value"])
|
|
513
|
+
]),
|
|
514
|
+
_: 1
|
|
515
|
+
}, 8, ["label", "rules"]),
|
|
516
|
+
e(Z, {
|
|
517
|
+
label: n.$t("role.remark"),
|
|
518
|
+
name: "remark",
|
|
519
|
+
rules: [{ message: n.$t("role.remark_msg1") }]
|
|
520
|
+
}, {
|
|
521
|
+
default: o(() => [
|
|
522
|
+
e(D, {
|
|
523
|
+
placeholder: n.$t("role.remark_placeholder"),
|
|
524
|
+
value: p.value.remark,
|
|
525
|
+
"onUpdate:value": k[2] || (k[2] = (E) => p.value.remark = E)
|
|
526
|
+
}, null, 8, ["placeholder", "value"])
|
|
527
|
+
]),
|
|
528
|
+
_: 1
|
|
529
|
+
}, 8, ["label", "rules"])
|
|
530
|
+
]),
|
|
531
|
+
_: 1
|
|
532
|
+
}, 8, ["model"])
|
|
533
|
+
]),
|
|
534
|
+
_: 1
|
|
535
|
+
}, 8, ["title"]),
|
|
536
|
+
e(A, {
|
|
537
|
+
class: "card",
|
|
538
|
+
bordered: !1,
|
|
539
|
+
title: n.$t("role.role_detail"),
|
|
540
|
+
style: { "padding-bottom": "30px" }
|
|
541
|
+
}, {
|
|
542
|
+
default: o(() => [
|
|
543
|
+
e(V(tt), {
|
|
544
|
+
ref_key: "actDetailRef",
|
|
545
|
+
ref: f,
|
|
546
|
+
params: a.value,
|
|
547
|
+
mode: s.value
|
|
548
|
+
}, null, 8, ["params", "mode"])
|
|
549
|
+
]),
|
|
550
|
+
_: 1
|
|
551
|
+
}, 8, ["title"])
|
|
552
|
+
]),
|
|
553
|
+
_: 1
|
|
554
|
+
})
|
|
555
|
+
]),
|
|
556
|
+
_: 1
|
|
557
|
+
}),
|
|
558
|
+
e(V(Pe), null, {
|
|
559
|
+
default: o(() => [
|
|
560
|
+
e(B, {
|
|
561
|
+
onClick: b,
|
|
562
|
+
style: { "margin-right": "20px" }
|
|
563
|
+
}, {
|
|
564
|
+
default: o(() => [
|
|
565
|
+
z(M(n.$t("common.btn_cancel")), 1)
|
|
566
|
+
]),
|
|
567
|
+
_: 1
|
|
568
|
+
}),
|
|
569
|
+
c.params.opType == "2" ? (m(), P(B, {
|
|
570
|
+
key: 0,
|
|
571
|
+
onClick: w,
|
|
572
|
+
type: "primary"
|
|
573
|
+
}, {
|
|
574
|
+
default: o(() => [
|
|
575
|
+
z(M(n.$t("common.btn_ok")), 1)
|
|
576
|
+
]),
|
|
577
|
+
_: 1
|
|
578
|
+
})) : L("v-if", !0)
|
|
579
|
+
]),
|
|
580
|
+
_: 1
|
|
581
|
+
})
|
|
582
|
+
]);
|
|
583
|
+
};
|
|
584
|
+
}
|
|
585
|
+
});
|
|
586
|
+
const ot = /* @__PURE__ */ J(lt, [["__scopeId", "data-v-41930af1"], ["__file", "D:/inhe-code/witlink-platform-usercenter-web/witlink-platform-usercenter1/src/views/sys/role/RoleDetail.vue"]]), nt = { bordered: !1 }, st = { style: { margin: "10px 0 16px" } }, rt = {
|
|
587
|
+
class: "table-page-search-wrapper",
|
|
588
|
+
style: { "margin-bottom": "16px" }
|
|
589
|
+
}, ct = { key: 1 }, ut = { key: 2 }, it = { key: 3 }, dt = /* @__PURE__ */ H({
|
|
590
|
+
name: "Function6",
|
|
591
|
+
__name: "index",
|
|
592
|
+
setup(c, { expose: O }) {
|
|
593
|
+
var K, Y;
|
|
594
|
+
const { t: h } = Q(), $ = r(), i = r(), d = r(!1), y = r(!1), f = r({
|
|
595
|
+
roleName: ""
|
|
596
|
+
}), v = r({}), g = Ue([
|
|
597
|
+
{
|
|
598
|
+
title: h("device.index1"),
|
|
599
|
+
width: "50px",
|
|
600
|
+
align: "center",
|
|
601
|
+
key: "index1"
|
|
602
|
+
},
|
|
603
|
+
{
|
|
604
|
+
title: h("personal_center.role"),
|
|
605
|
+
dataIndex: "roleName",
|
|
606
|
+
width: "150px",
|
|
607
|
+
align: "center",
|
|
608
|
+
key: "roleName"
|
|
609
|
+
},
|
|
610
|
+
{
|
|
611
|
+
title: h("role.remark"),
|
|
612
|
+
dataIndex: "remark",
|
|
613
|
+
width: "150px",
|
|
614
|
+
align: "center",
|
|
615
|
+
key: "remark"
|
|
616
|
+
},
|
|
617
|
+
{
|
|
618
|
+
title: h("role.uoperator"),
|
|
619
|
+
dataIndex: "uoperator",
|
|
620
|
+
width: "150px",
|
|
621
|
+
align: "center",
|
|
622
|
+
key: "uoperator"
|
|
623
|
+
},
|
|
624
|
+
{
|
|
625
|
+
title: h("role.udate"),
|
|
626
|
+
dataIndex: "udate",
|
|
627
|
+
width: "160px",
|
|
628
|
+
align: "center",
|
|
629
|
+
key: "udate"
|
|
630
|
+
},
|
|
631
|
+
{
|
|
632
|
+
title: h("role.role_status"),
|
|
633
|
+
dataIndex: "roleStatus",
|
|
634
|
+
width: "150px",
|
|
635
|
+
align: "center",
|
|
636
|
+
key: "roleStatus"
|
|
637
|
+
},
|
|
638
|
+
{
|
|
639
|
+
title: h("role.action"),
|
|
640
|
+
align: "center",
|
|
641
|
+
key: "action"
|
|
642
|
+
}
|
|
643
|
+
]), p = (K = i.value) == null ? void 0 : K.getLabel(0), C = (Y = i.value) == null ? void 0 : Y.getLabel(1), a = () => {
|
|
644
|
+
$.value.refresh();
|
|
645
|
+
}, t = (I) => {
|
|
646
|
+
we.emit("change", {
|
|
647
|
+
title: "role.title" + I,
|
|
648
|
+
description: "role.description" + I
|
|
649
|
+
});
|
|
650
|
+
}, l = () => {
|
|
651
|
+
t("1"), y.value = !0;
|
|
652
|
+
}, u = async (I, F) => {
|
|
653
|
+
await Ve({
|
|
654
|
+
roleId: F.roleId,
|
|
655
|
+
roleStatus: I ? "0" : "1"
|
|
656
|
+
}), a();
|
|
657
|
+
}, _ = (I) => {
|
|
658
|
+
t("2"), v.value = { opType: "2", roleId: I.roleId }, d.value = !0;
|
|
659
|
+
}, S = (I) => {
|
|
660
|
+
t("3"), v.value = { opType: "3", roleId: I.roleId }, d.value = !0;
|
|
661
|
+
}, s = () => {
|
|
662
|
+
$.value.refresh();
|
|
663
|
+
}, w = () => {
|
|
664
|
+
t("0"), d.value = !1, y.value = !1;
|
|
665
|
+
}, b = () => {
|
|
666
|
+
f.value = {
|
|
667
|
+
roleName: ""
|
|
668
|
+
};
|
|
669
|
+
}, N = async (I) => {
|
|
670
|
+
const F = Object.assign(I, f.value), { result: q } = await Be(F);
|
|
671
|
+
return q;
|
|
672
|
+
};
|
|
673
|
+
return O({
|
|
674
|
+
onSearch: a,
|
|
675
|
+
onSwitch: u,
|
|
676
|
+
onReset: b
|
|
677
|
+
}), ee(() => {
|
|
678
|
+
t("0");
|
|
679
|
+
}), (I, F) => {
|
|
680
|
+
const q = Ie, W = $e, n = ae, k = le, R = Se, A = Ae, U = De, D = xe, Z = Ne, X = te;
|
|
681
|
+
return m(), x("div", null, [
|
|
682
|
+
re(e(X, null, {
|
|
683
|
+
default: o(() => [
|
|
684
|
+
G("div", nt, [
|
|
685
|
+
G("div", st, [
|
|
686
|
+
e(q, {
|
|
687
|
+
placeholder: I.$t("role.nameInput"),
|
|
688
|
+
ref: "inputSearch",
|
|
689
|
+
value: f.value.roleName,
|
|
690
|
+
"onUpdate:value": F[0] || (F[0] = (T) => f.value.roleName = T),
|
|
691
|
+
onSearch: a,
|
|
692
|
+
allowClear: "",
|
|
693
|
+
style: { width: "350px", "margin-right": "16px" }
|
|
694
|
+
}, null, 8, ["placeholder", "value"])
|
|
695
|
+
]),
|
|
696
|
+
G("div", rt, [
|
|
697
|
+
e(k, null, {
|
|
698
|
+
default: o(() => [
|
|
699
|
+
e(n, { md: 18 }, {
|
|
700
|
+
default: o(() => [
|
|
701
|
+
e(W, { onClick: l }),
|
|
702
|
+
F[1] || (F[1] = z("\xA0 "))
|
|
703
|
+
]),
|
|
704
|
+
_: 1
|
|
705
|
+
})
|
|
706
|
+
]),
|
|
707
|
+
_: 1
|
|
708
|
+
})
|
|
709
|
+
]),
|
|
710
|
+
e(Ee, {
|
|
711
|
+
ref_key: "tableRef",
|
|
712
|
+
ref: $,
|
|
713
|
+
data: N,
|
|
714
|
+
columns: g,
|
|
715
|
+
rowKey: "roleId"
|
|
716
|
+
}, {
|
|
717
|
+
bodyCell: o(({ record: T, column: B }) => [
|
|
718
|
+
B.key === "index1" ? (m(), P(V(be), {
|
|
719
|
+
key: 0,
|
|
720
|
+
class: "icon",
|
|
721
|
+
style: { fontSize: "25px", color: "#1890ff" }
|
|
722
|
+
}, {
|
|
723
|
+
component: o(() => [
|
|
724
|
+
e(V(Ce))
|
|
725
|
+
]),
|
|
726
|
+
_: 1
|
|
727
|
+
})) : L("v-if", !0),
|
|
728
|
+
B.key === "udate" ? (m(), x("span", ct, [
|
|
729
|
+
e(R, {
|
|
730
|
+
defaultValue: T.udate
|
|
731
|
+
}, null, 8, ["defaultValue"])
|
|
732
|
+
])) : L("v-if", !0),
|
|
733
|
+
B.key === "roleStatus" ? (m(), x("span", ut, [
|
|
734
|
+
e(A, {
|
|
735
|
+
defaultChecked: T.roleStatus == 0,
|
|
736
|
+
checkedChildren: V(p),
|
|
737
|
+
unCheckedChildren: V(C),
|
|
738
|
+
onChange: (E) => u(E, T)
|
|
739
|
+
}, null, 8, ["defaultChecked", "checkedChildren", "unCheckedChildren", "onChange"])
|
|
740
|
+
])) : L("v-if", !0),
|
|
741
|
+
B.key === "action" ? (m(), x("span", it, [
|
|
742
|
+
e(U, {
|
|
743
|
+
onClick: (E) => _(T),
|
|
744
|
+
type: "a"
|
|
745
|
+
}, null, 8, ["onClick"]),
|
|
746
|
+
e(D, { type: "vertical" }),
|
|
747
|
+
e(Z, {
|
|
748
|
+
onClick: (E) => S(T),
|
|
749
|
+
type: "a"
|
|
750
|
+
}, null, 8, ["onClick"])
|
|
751
|
+
])) : L("v-if", !0)
|
|
752
|
+
]),
|
|
753
|
+
_: 1
|
|
754
|
+
}, 8, ["columns"])
|
|
755
|
+
])
|
|
756
|
+
]),
|
|
757
|
+
_: 1
|
|
758
|
+
}, 512), [
|
|
759
|
+
[ce, !d.value]
|
|
760
|
+
]),
|
|
761
|
+
y.value ? (m(), P(Ke, {
|
|
762
|
+
key: 0,
|
|
763
|
+
onOk: s,
|
|
764
|
+
onCancel: w
|
|
765
|
+
})) : L("v-if", !0),
|
|
766
|
+
d.value ? (m(), P(ot, {
|
|
767
|
+
key: 1,
|
|
768
|
+
onOk: s,
|
|
769
|
+
onCancel: w,
|
|
770
|
+
params: v.value
|
|
771
|
+
}, null, 8, ["params"])) : L("v-if", !0),
|
|
772
|
+
re(e(Me, {
|
|
773
|
+
type: "CMS_STATUS",
|
|
774
|
+
ref_key: "dictRoleStatusRef",
|
|
775
|
+
ref: i
|
|
776
|
+
}, null, 512), [
|
|
777
|
+
[ce, !1]
|
|
778
|
+
])
|
|
779
|
+
]);
|
|
780
|
+
};
|
|
781
|
+
}
|
|
782
|
+
});
|
|
783
|
+
const kt = /* @__PURE__ */ J(dt, [["__scopeId", "data-v-79d9b716"], ["__file", "D:/inhe-code/witlink-platform-usercenter-web/witlink-platform-usercenter1/src/views/sys/role/index.vue"]]);
|
|
784
|
+
export {
|
|
785
|
+
kt as default
|
|
786
|
+
};
|