jmash-core 0.0.39 → 0.0.41
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/dist/{401-CdhEu4T4.mjs → 401-CJFCHgSZ.mjs} +2 -2
- package/dist/{404-DkL9XgVz.mjs → 404-CIMxkP9D.mjs} +1 -1
- package/dist/{BarChart-BAUAF2EM.mjs → BarChart-DU09mkLm.mjs} +2 -2
- package/dist/{PieChart-DawdhjgV.mjs → PieChart-CoqFm60I.mjs} +1 -1
- package/dist/{PieChart.vue_vue_type_script_setup_true_lang-BNpfYKP_.mjs → PieChart.vue_vue_type_script_setup_true_lang-sfYOFNKO.mjs} +2 -2
- package/dist/{RadarChart-Cmy4Kx6_.mjs → RadarChart-0WISsxpt.mjs} +1 -1
- package/dist/{RadarChart.vue_vue_type_script_setup_true_lang-DSbItcHQ.mjs → RadarChart.vue_vue_type_script_setup_true_lang-BIOHXswr.mjs} +2 -2
- package/dist/{el-card-C34Q0Uym.mjs → el-card-DTXS4SWb.mjs} +1 -1
- package/dist/{el-col-B52VUKzg.mjs → el-col-C1oER81S.mjs} +1 -1
- package/dist/{el-form-item-B4UdYQRs.mjs → el-form-item-CJcAbcqr.mjs} +76 -76
- package/dist/{index-C8YRqnUz.mjs → index-BAk-5oG9.mjs} +1 -1
- package/dist/{index-C80YQc_W.mjs → index-BwIx8FCt.mjs} +32 -32
- package/dist/{index-uMvRmAE4.mjs → index-C195Pa7c.mjs} +9761 -11328
- package/dist/{index-C8BZXM0g.mjs → index-DB4OW-7Q.mjs} +982 -946
- package/dist/{index-Bo7YJt82.mjs → index-ORr19rEl.mjs} +48 -48
- package/dist/index.mjs +40 -37
- package/dist/index.vue_vue_type_script_setup_true_lang-fPrQh0lj.mjs +720 -0
- package/dist/{picture-BWU-5yjz.mjs → picture-Cpgh-vo-.mjs} +106 -106
- package/dist/{position-C-x4QW6J.mjs → position-M0AZIV5D.mjs} +1 -1
- package/dist/profile-DBegP-cF.mjs +4904 -0
- package/dist/{runAs-TvH5stYU.mjs → runAs-xhA9mf-i.mjs} +1 -1
- package/dist/runAs.vue_vue_type_script_setup_true_lang-DLfQ0lsg.mjs +610 -0
- package/dist/style.css +1 -1
- package/dist/{types-D2erVkDs.mjs → types-FkPgztcJ.mjs} +4 -3
- package/dist/{updatePwd-B2_g0SZo.mjs → updatePwd-D1EnTbTY.mjs} +1 -1
- package/dist/{updatePwd.vue_vue_type_script_setup_true_lang-BizfnzzV.mjs → updatePwd.vue_vue_type_script_setup_true_lang-DkH3J5K0.mjs} +20 -20
- package/dts/src/api/auth/index.d.ts +27 -2
- package/dts/src/api/auth/types.d.ts +42 -34
- package/dts/src/api/index.d.ts +7 -1
- package/dts/src/api/types.d.ts +10 -0
- package/dts/src/index.d.ts +9 -8
- package/dts/src/lang/package/zh-cn.d.ts +2 -0
- package/dts/src/router/index.d.ts +5 -3
- package/dts/src/utils/request.d.ts +2 -0
- package/package.json +1 -1
- package/dist/edit-BLaPAzUL.mjs +0 -4
- package/dist/edit-BXuyxZh9.mjs +0 -4
- package/dist/edit-CFf0s07O.mjs +0 -823
- package/dist/edit-DZ9hTXeR.mjs +0 -4
- package/dist/edit-DlrFLzTL.mjs +0 -4
- package/dist/edit-EdaB9SSf.mjs +0 -4
- package/dist/edit-Kne2PwwU.mjs +0 -459
- package/dist/edit-jg9l_Reg.mjs +0 -4
- package/dist/edit.vue_vue_type_script_setup_true_lang-4rHDZXXI.mjs +0 -216
- package/dist/edit.vue_vue_type_script_setup_true_lang-BC1zWgeA.mjs +0 -593
- package/dist/edit.vue_vue_type_script_setup_true_lang-BckjVLbr.mjs +0 -136
- package/dist/edit.vue_vue_type_script_setup_true_lang-Bd_6zzD7.mjs +0 -157
- package/dist/edit.vue_vue_type_script_setup_true_lang-BmDTKxvL.mjs +0 -280
- package/dist/edit.vue_vue_type_script_setup_true_lang-BwDzJpxL.mjs +0 -226
- package/dist/el-checkbox-group-l0sNRNKZ.mjs +0 -1
- package/dist/el-date-picker-ZuZ7Icew.mjs +0 -3345
- package/dist/el-divider-B2Q7h8Ue.mjs +0 -45
- package/dist/el-dropdown-item-CF7AWJJk.mjs +0 -671
- package/dist/el-tree-select-B2n1iK36.mjs +0 -1313
- package/dist/index-BBtOEuTE.mjs +0 -280
- package/dist/index-BYBALKYQ.mjs +0 -74
- package/dist/index-BZ0HWESU.mjs +0 -949
- package/dist/index-BoC2W_nt.mjs +0 -280
- package/dist/index-CLxvt-Vt.mjs +0 -292
- package/dist/index-CoJe3ek6.mjs +0 -280
- package/dist/index-CtCbUL0r.mjs +0 -471
- package/dist/index-D-Ce5smQ.mjs +0 -505
- package/dist/index-DDBu5r9o.mjs +0 -93
- package/dist/index-DFRe9_oD.mjs +0 -480
- package/dist/index-DHMuTZ7a.mjs +0 -246
- package/dist/index-DqfVM012.mjs +0 -502
- package/dist/index-Niej8SwP.mjs +0 -134
- package/dist/index-Orr0L_H3.mjs +0 -63
- package/dist/index-wDuQo7A0.mjs +0 -501
- package/dist/index.vue_vue_type_script_setup_true_lang-DIcVpe9M.mjs +0 -55
- package/dist/moment-CMYwqyVT.mjs +0 -2579
- package/dist/profile-VVxA40z5.mjs +0 -262
- package/dist/runAs.vue_vue_type_script_setup_true_lang-BHqTCD_Q.mjs +0 -114
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
import { $ as q, X as b, s as R, t as $, al as w } from "./index-uMvRmAE4.mjs";
|
|
2
|
-
import { E as D, a as F } from "./el-form-item-B4UdYQRs.mjs";
|
|
3
|
-
import { defineComponent as k, ref as S, reactive as y, toRef as U, openBlock as j, createBlock as B, unref as l, withCtx as a, createElementVNode as M, createVNode as s, createTextVNode as E, toDisplayString as V } from "vue";
|
|
4
|
-
import { useI18n as O } from "vue-i18n";
|
|
5
|
-
import { c as A, e as T, a as X } from "./index-BYBALKYQ.mjs";
|
|
6
|
-
const x = { class: "dialog-footer" }, Q = /* @__PURE__ */ k({
|
|
7
|
-
__name: "edit",
|
|
8
|
-
props: {
|
|
9
|
-
formData: {
|
|
10
|
-
type: Object,
|
|
11
|
-
default: () => {
|
|
12
|
-
}
|
|
13
|
-
},
|
|
14
|
-
dialog: {
|
|
15
|
-
type: Object,
|
|
16
|
-
default: () => {
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
emits: ["dialogEvent", "refresh"],
|
|
21
|
-
setup(C, { emit: h }) {
|
|
22
|
-
var g;
|
|
23
|
-
const { t: i } = O(), f = S();
|
|
24
|
-
let o = y({
|
|
25
|
-
tenant: q().user.tenant,
|
|
26
|
-
requestId: Math.random() * 10 + "",
|
|
27
|
-
permCode: "",
|
|
28
|
-
permName: "",
|
|
29
|
-
updateMask: "permCode,permName"
|
|
30
|
-
});
|
|
31
|
-
const v = y({
|
|
32
|
-
permCode: [{ required: !0, validator: (r, t, e) => {
|
|
33
|
-
t === "" ? e(new Error(i("sysPerm.codeRequired"))) : o.permId ? e() : A(t).then(({ data: n }) => {
|
|
34
|
-
n === !0 ? e(new Error("该编码已存在")) : e();
|
|
35
|
-
});
|
|
36
|
-
}, trigger: "blur" }],
|
|
37
|
-
permName: [
|
|
38
|
-
{ required: !0, message: i("sysPerm.nameRequired"), trigger: "blur" }
|
|
39
|
-
]
|
|
40
|
-
}), u = C, p = U(u, "dialog"), m = h, N = async () => {
|
|
41
|
-
var r;
|
|
42
|
-
await ((r = f.value) == null ? void 0 : r.validate((t) => {
|
|
43
|
-
t && (o.permId ? T(o).then((e) => {
|
|
44
|
-
console.log(e), e.status === 200 && (b({
|
|
45
|
-
message: i("common.submitSuccess"),
|
|
46
|
-
type: "success"
|
|
47
|
-
}), m("dialogEvent", !1), m("refresh", e.status === 200));
|
|
48
|
-
}) : X(o).then((e) => {
|
|
49
|
-
console.log(e), e.status === 200 && (b({
|
|
50
|
-
message: i("common.submitSuccess"),
|
|
51
|
-
type: "success"
|
|
52
|
-
}), m("dialogEvent", !1), m("refresh", e.status === 200));
|
|
53
|
-
}));
|
|
54
|
-
}));
|
|
55
|
-
};
|
|
56
|
-
function c() {
|
|
57
|
-
m("dialogEvent", !1);
|
|
58
|
-
}
|
|
59
|
-
return (g = u.formData) != null && g.permId && (o = Object.assign(o, u.formData)), (r, t) => {
|
|
60
|
-
const e = R, n = D, P = F, _ = $, I = w;
|
|
61
|
-
return j(), B(I, {
|
|
62
|
-
modelValue: l(p).visible,
|
|
63
|
-
"onUpdate:modelValue": t[2] || (t[2] = (d) => l(p).visible = d),
|
|
64
|
-
title: l(p).title,
|
|
65
|
-
width: "600px",
|
|
66
|
-
onClose: c
|
|
67
|
-
}, {
|
|
68
|
-
footer: a(() => [
|
|
69
|
-
M("div", x, [
|
|
70
|
-
s(_, { onClick: c }, {
|
|
71
|
-
default: a(() => [
|
|
72
|
-
E(V(r.$t("common.cancel")), 1)
|
|
73
|
-
]),
|
|
74
|
-
_: 1
|
|
75
|
-
}),
|
|
76
|
-
s(_, {
|
|
77
|
-
type: "primary",
|
|
78
|
-
onClick: N
|
|
79
|
-
}, {
|
|
80
|
-
default: a(() => [
|
|
81
|
-
E(V(r.$t("common.confirm")), 1)
|
|
82
|
-
]),
|
|
83
|
-
_: 1
|
|
84
|
-
})
|
|
85
|
-
])
|
|
86
|
-
]),
|
|
87
|
-
default: a(() => [
|
|
88
|
-
s(P, {
|
|
89
|
-
ref_key: "permissionFormRef",
|
|
90
|
-
ref: f,
|
|
91
|
-
model: l(o),
|
|
92
|
-
"label-width": "160px",
|
|
93
|
-
rules: l(v)
|
|
94
|
-
}, {
|
|
95
|
-
default: a(() => [
|
|
96
|
-
s(n, {
|
|
97
|
-
label: r.$t("sysPerm.code"),
|
|
98
|
-
prop: "permCode"
|
|
99
|
-
}, {
|
|
100
|
-
default: a(() => [
|
|
101
|
-
s(e, {
|
|
102
|
-
modelValue: l(o).permCode,
|
|
103
|
-
"onUpdate:modelValue": t[0] || (t[0] = (d) => l(o).permCode = d),
|
|
104
|
-
placeholder: r.$t("sysPerm.codeRequired"),
|
|
105
|
-
disabled: !!l(o).permId,
|
|
106
|
-
clearable: ""
|
|
107
|
-
}, null, 8, ["modelValue", "placeholder", "disabled"])
|
|
108
|
-
]),
|
|
109
|
-
_: 1
|
|
110
|
-
}, 8, ["label"]),
|
|
111
|
-
s(n, {
|
|
112
|
-
label: r.$t("sysPerm.name"),
|
|
113
|
-
prop: "permName"
|
|
114
|
-
}, {
|
|
115
|
-
default: a(() => [
|
|
116
|
-
s(e, {
|
|
117
|
-
modelValue: l(o).permName,
|
|
118
|
-
"onUpdate:modelValue": t[1] || (t[1] = (d) => l(o).permName = d),
|
|
119
|
-
placeholder: r.$t("sysPerm.nameRequired"),
|
|
120
|
-
clearable: ""
|
|
121
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
122
|
-
]),
|
|
123
|
-
_: 1
|
|
124
|
-
}, 8, ["label"])
|
|
125
|
-
]),
|
|
126
|
-
_: 1
|
|
127
|
-
}, 8, ["model", "rules"])
|
|
128
|
-
]),
|
|
129
|
-
_: 1
|
|
130
|
-
}, 8, ["modelValue", "title"]);
|
|
131
|
-
};
|
|
132
|
-
}
|
|
133
|
-
});
|
|
134
|
-
export {
|
|
135
|
-
Q as _
|
|
136
|
-
};
|
|
@@ -1,157 +0,0 @@
|
|
|
1
|
-
import { $ as R, s as $, t as q, al as w } from "./index-uMvRmAE4.mjs";
|
|
2
|
-
import { E as D, a as F } from "./el-form-item-B4UdYQRs.mjs";
|
|
3
|
-
import { defineComponent as U, toRef as k, ref as S, reactive as y, openBlock as j, createBlock as B, withCtx as a, createElementVNode as O, createVNode as d, createTextVNode as V, toDisplayString as _, unref as s } from "vue";
|
|
4
|
-
import { ElMessage as E } from "element-plus";
|
|
5
|
-
import { useI18n as z } from "vue-i18n";
|
|
6
|
-
import { e as A, f as T, h as G } from "./index-DDBu5r9o.mjs";
|
|
7
|
-
const H = { class: "dialog-footer" }, Y = /* @__PURE__ */ U({
|
|
8
|
-
__name: "edit",
|
|
9
|
-
props: {
|
|
10
|
-
formData: {
|
|
11
|
-
type: Object,
|
|
12
|
-
default: () => {
|
|
13
|
-
}
|
|
14
|
-
},
|
|
15
|
-
dialog: {
|
|
16
|
-
type: Object,
|
|
17
|
-
default: () => {
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
},
|
|
21
|
-
emits: ["dialogEvent", "refresh"],
|
|
22
|
-
setup(M, { emit: v }) {
|
|
23
|
-
var g;
|
|
24
|
-
const { t: i } = z(), n = M, p = k(n, "dialog"), f = S();
|
|
25
|
-
let o = y({
|
|
26
|
-
tenant: R().user.tenant,
|
|
27
|
-
moduleId: "",
|
|
28
|
-
moduleCode: "",
|
|
29
|
-
moduleName: "",
|
|
30
|
-
description: "",
|
|
31
|
-
updateMask: "moduleCode,moduleName,description",
|
|
32
|
-
requestId: Math.random() * 10 + ""
|
|
33
|
-
});
|
|
34
|
-
const C = y({
|
|
35
|
-
moduleCode: [
|
|
36
|
-
{ required: !0, validator: (t, l, e) => {
|
|
37
|
-
l === "" ? e(new Error(i("sysModule.codeRequired"))) : o.moduleId ? e() : A(l).then(({ data: m }) => {
|
|
38
|
-
m === !0 ? e(new Error("该编码已存在")) : e();
|
|
39
|
-
});
|
|
40
|
-
}, trigger: "blur" }
|
|
41
|
-
],
|
|
42
|
-
moduleName: [
|
|
43
|
-
{ required: !0, message: i("sysModule.nameRequired"), trigger: "blur" }
|
|
44
|
-
]
|
|
45
|
-
}), u = v, h = async () => {
|
|
46
|
-
var t;
|
|
47
|
-
await ((t = f.value) == null ? void 0 : t.validate((l) => {
|
|
48
|
-
l && (o.moduleId ? T(o).then((e) => {
|
|
49
|
-
console.log(e), e.status === 200 && (E({
|
|
50
|
-
message: i("common.submitSuccess"),
|
|
51
|
-
type: "success"
|
|
52
|
-
}), u("dialogEvent", !1), u("refresh", e.status === 200));
|
|
53
|
-
}) : G(o).then((e) => {
|
|
54
|
-
console.log(e), e.status === 200 && (E({
|
|
55
|
-
message: i("common.submitSuccess"),
|
|
56
|
-
type: "success"
|
|
57
|
-
}), u("dialogEvent", !1), u("refresh", e.status === 200));
|
|
58
|
-
}));
|
|
59
|
-
}));
|
|
60
|
-
};
|
|
61
|
-
function c() {
|
|
62
|
-
u("dialogEvent", !1);
|
|
63
|
-
}
|
|
64
|
-
return (g = n.formData) != null && g.moduleId && (o = Object.assign(o, n.formData)), (t, l) => {
|
|
65
|
-
const e = $, m = D, I = F, b = q, N = w;
|
|
66
|
-
return j(), B(N, {
|
|
67
|
-
modelValue: p.value.visible,
|
|
68
|
-
"onUpdate:modelValue": l[3] || (l[3] = (r) => p.value.visible = r),
|
|
69
|
-
title: p.value.title,
|
|
70
|
-
width: "600px",
|
|
71
|
-
onClose: c
|
|
72
|
-
}, {
|
|
73
|
-
footer: a(() => [
|
|
74
|
-
O("div", H, [
|
|
75
|
-
d(b, { onClick: c }, {
|
|
76
|
-
default: a(() => [
|
|
77
|
-
V(_(t.$t("common.cancel")), 1)
|
|
78
|
-
]),
|
|
79
|
-
_: 1
|
|
80
|
-
}),
|
|
81
|
-
d(b, {
|
|
82
|
-
type: "primary",
|
|
83
|
-
onClick: h
|
|
84
|
-
}, {
|
|
85
|
-
default: a(() => [
|
|
86
|
-
V(_(t.$t("common.confirm")), 1)
|
|
87
|
-
]),
|
|
88
|
-
_: 1
|
|
89
|
-
})
|
|
90
|
-
])
|
|
91
|
-
]),
|
|
92
|
-
default: a(() => [
|
|
93
|
-
d(I, {
|
|
94
|
-
ref_key: "moduleFormRef",
|
|
95
|
-
ref: f,
|
|
96
|
-
model: s(o),
|
|
97
|
-
rules: C,
|
|
98
|
-
"label-width": "160px"
|
|
99
|
-
}, {
|
|
100
|
-
default: a(() => [
|
|
101
|
-
d(m, {
|
|
102
|
-
label: t.$t("sysModule.code"),
|
|
103
|
-
prop: "moduleCode"
|
|
104
|
-
}, {
|
|
105
|
-
default: a(() => [
|
|
106
|
-
d(e, {
|
|
107
|
-
modelValue: s(o).moduleCode,
|
|
108
|
-
"onUpdate:modelValue": l[0] || (l[0] = (r) => s(o).moduleCode = r),
|
|
109
|
-
placeholder: t.$t("sysModule.codeRequired"),
|
|
110
|
-
disabled: !!s(o).moduleId,
|
|
111
|
-
clearable: ""
|
|
112
|
-
}, null, 8, ["modelValue", "placeholder", "disabled"])
|
|
113
|
-
]),
|
|
114
|
-
_: 1
|
|
115
|
-
}, 8, ["label"]),
|
|
116
|
-
d(m, {
|
|
117
|
-
label: t.$t("sysModule.name"),
|
|
118
|
-
prop: "moduleName"
|
|
119
|
-
}, {
|
|
120
|
-
default: a(() => [
|
|
121
|
-
d(e, {
|
|
122
|
-
modelValue: s(o).moduleName,
|
|
123
|
-
"onUpdate:modelValue": l[1] || (l[1] = (r) => s(o).moduleName = r),
|
|
124
|
-
placeholder: t.$t("sysModule.nameRequired"),
|
|
125
|
-
clearable: ""
|
|
126
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
127
|
-
]),
|
|
128
|
-
_: 1
|
|
129
|
-
}, 8, ["label"]),
|
|
130
|
-
d(m, {
|
|
131
|
-
label: t.$t("sysModule.description"),
|
|
132
|
-
prop: "description"
|
|
133
|
-
}, {
|
|
134
|
-
default: a(() => [
|
|
135
|
-
d(e, {
|
|
136
|
-
modelValue: s(o).description,
|
|
137
|
-
"onUpdate:modelValue": l[2] || (l[2] = (r) => s(o).description = r),
|
|
138
|
-
type: "textarea",
|
|
139
|
-
autosize: { minRows: 2 },
|
|
140
|
-
placeholder: t.$t("sysModule.descriptionRequired"),
|
|
141
|
-
clearable: ""
|
|
142
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
143
|
-
]),
|
|
144
|
-
_: 1
|
|
145
|
-
}, 8, ["label"])
|
|
146
|
-
]),
|
|
147
|
-
_: 1
|
|
148
|
-
}, 8, ["model", "rules"])
|
|
149
|
-
]),
|
|
150
|
-
_: 1
|
|
151
|
-
}, 8, ["modelValue", "title"]);
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
});
|
|
155
|
-
export {
|
|
156
|
-
Y as _
|
|
157
|
-
};
|
|
@@ -1,280 +0,0 @@
|
|
|
1
|
-
import { $ as U, b0 as Y, X as F, s as Z, as as ee, at as oe, b1 as le, b2 as te, b3 as ae, b4 as re, t as se, al as ne } from "./index-uMvRmAE4.mjs";
|
|
2
|
-
import "./el-checkbox-group-l0sNRNKZ.mjs";
|
|
3
|
-
import { E as de, a as me } from "./el-form-item-B4UdYQRs.mjs";
|
|
4
|
-
import { defineComponent as ue, ref as m, reactive as j, toRef as ie, openBlock as f, createBlock as E, unref as a, withCtx as n, createElementVNode as pe, createVNode as s, createTextVNode as g, toDisplayString as b, createElementBlock as x, Fragment as A, renderList as B, isRef as ce } from "vue";
|
|
5
|
-
import { useI18n as fe } from "vue-i18n";
|
|
6
|
-
import { p as be } from "./index-BYBALKYQ.mjs";
|
|
7
|
-
import { m as he } from "./index-DDBu5r9o.mjs";
|
|
8
|
-
import { e as ge, a as _e } from "./index-Orr0L_H3.mjs";
|
|
9
|
-
const ye = { class: "dialog-footer" }, Re = /* @__PURE__ */ ue({
|
|
10
|
-
__name: "edit",
|
|
11
|
-
props: {
|
|
12
|
-
formData: {
|
|
13
|
-
type: Object,
|
|
14
|
-
default: () => {
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
dialog: {
|
|
18
|
-
type: Object,
|
|
19
|
-
default: () => {
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
emits: ["dialogEvent", "refresh"],
|
|
24
|
-
setup(S, { emit: T }) {
|
|
25
|
-
var R;
|
|
26
|
-
const { t: u } = fe(), v = m();
|
|
27
|
-
let l = j({
|
|
28
|
-
tenant: U().user.tenant,
|
|
29
|
-
requestId: Math.random() * 10 + "",
|
|
30
|
-
roleType: "job",
|
|
31
|
-
updateMask: "roleCode,roleName,description",
|
|
32
|
-
roleId: "",
|
|
33
|
-
roleCode: "",
|
|
34
|
-
roleName: "",
|
|
35
|
-
description: "",
|
|
36
|
-
permCodes: []
|
|
37
|
-
});
|
|
38
|
-
const M = j({
|
|
39
|
-
roleCode: [{ required: !0, validator: (e, o, t) => {
|
|
40
|
-
if (o === "")
|
|
41
|
-
t(new Error(u("sysJob.codeRequired")));
|
|
42
|
-
else {
|
|
43
|
-
const d = {
|
|
44
|
-
tenant: U().user.tenant,
|
|
45
|
-
roleCode: o,
|
|
46
|
-
addFlag: !l.roleId,
|
|
47
|
-
roleId: l.roleId
|
|
48
|
-
};
|
|
49
|
-
Y(d).then(({ data: V }) => {
|
|
50
|
-
V === !0 ? t(new Error(u("sysRole.codeExist"))) : t();
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
}, trigger: "blur" }],
|
|
54
|
-
roleName: [
|
|
55
|
-
{ required: !0, message: u("sysJob.nameRequired"), trigger: "blur" }
|
|
56
|
-
]
|
|
57
|
-
});
|
|
58
|
-
let k = m([]);
|
|
59
|
-
const h = m(!1), _ = m(!1), w = m();
|
|
60
|
-
let i = m([]);
|
|
61
|
-
const p = T, y = S, C = ie(y, "dialog"), O = async () => {
|
|
62
|
-
var e;
|
|
63
|
-
await ((e = v.value) == null ? void 0 : e.validate((o) => {
|
|
64
|
-
o && (l.roleId ? ge(l).then((t) => {
|
|
65
|
-
console.log(t), t.status === 200 && (F({
|
|
66
|
-
message: u("common.submitSuccess"),
|
|
67
|
-
type: "success"
|
|
68
|
-
}), p("dialogEvent", !1), p("refresh", t.status === 200));
|
|
69
|
-
}) : _e(l).then((t) => {
|
|
70
|
-
console.log(t), t.status === 200 && (F({
|
|
71
|
-
message: u("common.submitSuccess"),
|
|
72
|
-
type: "success"
|
|
73
|
-
}), p("dialogEvent", !1), p("refresh", t.status === 200));
|
|
74
|
-
}));
|
|
75
|
-
}));
|
|
76
|
-
};
|
|
77
|
-
function I() {
|
|
78
|
-
p("dialogEvent", !1);
|
|
79
|
-
}
|
|
80
|
-
function N() {
|
|
81
|
-
be(l.moduleId).then(({ data: e }) => {
|
|
82
|
-
w.value = e.results, J(e.results);
|
|
83
|
-
});
|
|
84
|
-
}
|
|
85
|
-
function L() {
|
|
86
|
-
he().then(({ data: e }) => {
|
|
87
|
-
k.value = e.results;
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
function z(e) {
|
|
91
|
-
console.log(e), N();
|
|
92
|
-
}
|
|
93
|
-
function J(e) {
|
|
94
|
-
for (let o = 0; o < e.length; o++) {
|
|
95
|
-
for (let t = 0; t < e[o].perms.length; t++)
|
|
96
|
-
i.value.push(e[o].perms[t].permCode);
|
|
97
|
-
J(e[o].children);
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
function P(e) {
|
|
101
|
-
console.log(e, i.value), l.permCodes = e ? i.value : [], _.value = !1;
|
|
102
|
-
}
|
|
103
|
-
function G(e) {
|
|
104
|
-
console.log(e), l.permCodes = e, console.log(l.permCodes);
|
|
105
|
-
const o = e.length;
|
|
106
|
-
h.value = o === i.value.length, _.value = o > 0 && o < i.value.length;
|
|
107
|
-
}
|
|
108
|
-
return N(), L(), (R = y.formData) != null && R.roleId && (l = Object.assign(l, y.formData)), (e, o) => {
|
|
109
|
-
const t = Z, d = de, V = ee, X = oe, $ = le, q = te, H = ae, K = re, Q = me, D = se, W = ne;
|
|
110
|
-
return f(), E(W, {
|
|
111
|
-
title: a(C).title,
|
|
112
|
-
modelValue: a(C).visible,
|
|
113
|
-
"onUpdate:modelValue": o[6] || (o[6] = (r) => a(C).visible = r),
|
|
114
|
-
width: "800px",
|
|
115
|
-
onClose: I
|
|
116
|
-
}, {
|
|
117
|
-
footer: n(() => [
|
|
118
|
-
pe("div", ye, [
|
|
119
|
-
s(D, { onClick: I }, {
|
|
120
|
-
default: n(() => [
|
|
121
|
-
g(b(e.$t("common.cancel")), 1)
|
|
122
|
-
]),
|
|
123
|
-
_: 1
|
|
124
|
-
}),
|
|
125
|
-
s(D, {
|
|
126
|
-
type: "primary",
|
|
127
|
-
onClick: O
|
|
128
|
-
}, {
|
|
129
|
-
default: n(() => [
|
|
130
|
-
g(b(e.$t("common.confirm")), 1)
|
|
131
|
-
]),
|
|
132
|
-
_: 1
|
|
133
|
-
})
|
|
134
|
-
])
|
|
135
|
-
]),
|
|
136
|
-
default: n(() => [
|
|
137
|
-
s(Q, {
|
|
138
|
-
ref_key: "jobFormRef",
|
|
139
|
-
ref: v,
|
|
140
|
-
model: a(l),
|
|
141
|
-
rules: a(M),
|
|
142
|
-
"label-width": "160px"
|
|
143
|
-
}, {
|
|
144
|
-
default: n(() => [
|
|
145
|
-
s(d, {
|
|
146
|
-
label: e.$t("sysJob.code"),
|
|
147
|
-
prop: "roleCode"
|
|
148
|
-
}, {
|
|
149
|
-
default: n(() => [
|
|
150
|
-
s(t, {
|
|
151
|
-
modelValue: a(l).roleCode,
|
|
152
|
-
"onUpdate:modelValue": o[0] || (o[0] = (r) => a(l).roleCode = r),
|
|
153
|
-
placeholder: e.$t("sysJob.codeRequired"),
|
|
154
|
-
clearable: "",
|
|
155
|
-
maxlength: "30",
|
|
156
|
-
"show-word-limit": ""
|
|
157
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
158
|
-
]),
|
|
159
|
-
_: 1
|
|
160
|
-
}, 8, ["label"]),
|
|
161
|
-
s(d, {
|
|
162
|
-
label: e.$t("sysJob.name"),
|
|
163
|
-
prop: "roleName"
|
|
164
|
-
}, {
|
|
165
|
-
default: n(() => [
|
|
166
|
-
s(t, {
|
|
167
|
-
modelValue: a(l).roleName,
|
|
168
|
-
"onUpdate:modelValue": o[1] || (o[1] = (r) => a(l).roleName = r),
|
|
169
|
-
placeholder: e.$t("sysJob.nameRequired"),
|
|
170
|
-
clearable: "",
|
|
171
|
-
maxlength: "30",
|
|
172
|
-
"show-word-limit": ""
|
|
173
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
174
|
-
]),
|
|
175
|
-
_: 1
|
|
176
|
-
}, 8, ["label"]),
|
|
177
|
-
s(d, {
|
|
178
|
-
label: e.$t("sysJob.operatePerm"),
|
|
179
|
-
prop: "permCodes"
|
|
180
|
-
}, {
|
|
181
|
-
default: n(() => [
|
|
182
|
-
s(X, {
|
|
183
|
-
modelValue: a(l).moduleId,
|
|
184
|
-
"onUpdate:modelValue": o[2] || (o[2] = (r) => a(l).moduleId = r),
|
|
185
|
-
clearable: "",
|
|
186
|
-
placeholder: e.$t("sysJob.moduleRequired"),
|
|
187
|
-
style: { width: "100%" },
|
|
188
|
-
onChange: z
|
|
189
|
-
}, {
|
|
190
|
-
default: n(() => [
|
|
191
|
-
(f(!0), x(A, null, B(a(k), (r) => (f(), E(V, {
|
|
192
|
-
key: r.moduleId,
|
|
193
|
-
label: r.moduleName,
|
|
194
|
-
value: r.moduleId
|
|
195
|
-
}, null, 8, ["label", "value"]))), 128))
|
|
196
|
-
]),
|
|
197
|
-
_: 1
|
|
198
|
-
}, 8, ["modelValue", "placeholder"]),
|
|
199
|
-
s($, {
|
|
200
|
-
modelValue: a(h),
|
|
201
|
-
"onUpdate:modelValue": o[3] || (o[3] = (r) => ce(h) ? h.value = r : null),
|
|
202
|
-
indeterminate: a(_),
|
|
203
|
-
onChange: P
|
|
204
|
-
}, {
|
|
205
|
-
default: n(() => [
|
|
206
|
-
g(b(e.$t("sysJob.checkAll")) + "/" + b(e.$t("sysJob.checkNoAll")), 1)
|
|
207
|
-
]),
|
|
208
|
-
_: 1
|
|
209
|
-
}, 8, ["modelValue", "indeterminate"]),
|
|
210
|
-
s(K, {
|
|
211
|
-
data: a(w),
|
|
212
|
-
"row-key": "resourceId",
|
|
213
|
-
border: "",
|
|
214
|
-
"show-header": !1,
|
|
215
|
-
"tree-props": { children: "children", hasChildren: "hasChildren" }
|
|
216
|
-
}, {
|
|
217
|
-
default: n(() => [
|
|
218
|
-
s(q, {
|
|
219
|
-
prop: "resourceName",
|
|
220
|
-
width: "180"
|
|
221
|
-
}),
|
|
222
|
-
s(q, { prop: "resourceName" }, {
|
|
223
|
-
default: n((r) => [
|
|
224
|
-
s(H, {
|
|
225
|
-
modelValue: a(l).permCodes,
|
|
226
|
-
"onUpdate:modelValue": o[4] || (o[4] = (c) => a(l).permCodes = c),
|
|
227
|
-
onChange: G
|
|
228
|
-
}, {
|
|
229
|
-
default: n(() => [
|
|
230
|
-
(f(!0), x(A, null, B(r.row.perms, (c) => (f(), E($, {
|
|
231
|
-
label: c.permCode,
|
|
232
|
-
key: c.permId
|
|
233
|
-
}, {
|
|
234
|
-
default: n(() => [
|
|
235
|
-
g(b(c.permName), 1)
|
|
236
|
-
]),
|
|
237
|
-
_: 2
|
|
238
|
-
}, 1032, ["label"]))), 128))
|
|
239
|
-
]),
|
|
240
|
-
_: 2
|
|
241
|
-
}, 1032, ["modelValue"])
|
|
242
|
-
]),
|
|
243
|
-
_: 1
|
|
244
|
-
})
|
|
245
|
-
]),
|
|
246
|
-
_: 1
|
|
247
|
-
}, 8, ["data"])
|
|
248
|
-
]),
|
|
249
|
-
_: 1
|
|
250
|
-
}, 8, ["label"]),
|
|
251
|
-
s(d, {
|
|
252
|
-
label: e.$t("sysJob.description"),
|
|
253
|
-
prop: "description"
|
|
254
|
-
}, {
|
|
255
|
-
default: n(() => [
|
|
256
|
-
s(t, {
|
|
257
|
-
modelValue: a(l).description,
|
|
258
|
-
"onUpdate:modelValue": o[5] || (o[5] = (r) => a(l).description = r),
|
|
259
|
-
type: "textarea",
|
|
260
|
-
autosize: { minRows: 2 },
|
|
261
|
-
maxlength: "200",
|
|
262
|
-
"show-word-limit": "",
|
|
263
|
-
placeholder: e.$t("sysJob.descriptionRequired"),
|
|
264
|
-
clearable: ""
|
|
265
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
266
|
-
]),
|
|
267
|
-
_: 1
|
|
268
|
-
}, 8, ["label"])
|
|
269
|
-
]),
|
|
270
|
-
_: 1
|
|
271
|
-
}, 8, ["model", "rules"])
|
|
272
|
-
]),
|
|
273
|
-
_: 1
|
|
274
|
-
}, 8, ["title", "modelValue"]);
|
|
275
|
-
};
|
|
276
|
-
}
|
|
277
|
-
});
|
|
278
|
-
export {
|
|
279
|
-
Re as _
|
|
280
|
-
};
|