@utogether/udp-core 1.0.4 → 2.0.0-beta.3
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/{403-DASI6Pwz.js → 403-CxOqlq0f.js} +3 -3
- package/dist/403-WCboRvzZ-ZAPgYStl.js +65 -0
- package/dist/404-2V0Qi-d7-DkNwQggp.js +65 -0
- package/dist/{404-YhBA92cb.js → 404-xdB6lFeQ.js} +1 -1
- package/dist/500-BYfzvixf-CGpEieyQ.js +67 -0
- package/dist/{500-ywbFF5MX.js → 500-C94bRK2S.js} +2 -2
- package/dist/AuthorityInfo-DBovfUjB-DpQwT9Q5.js +4 -0
- package/dist/{AuthorityInfo-tCSX2Fh7.js → AuthorityInfo-Dy3b_nFN.js} +1 -1
- package/dist/{AuthorityInfo.vue_vue_type_style_index_0_lang-Cwd6UT2i.js → AuthorityInfo.vue_vue_type_style_index_0_lang-Bh7IbcdY.js} +2 -2
- package/dist/AuthorityInfo.vue_vue_type_style_index_0_lang-D-l_Az3s-Cw7WmFxz.js +100 -0
- package/dist/AuthorityPanel-CRlAwbaI-G7pZXKdE.js +4 -0
- package/dist/{AuthorityPanel-BeBNiwqc.js → AuthorityPanel-CRlAwbaI.js} +1 -1
- package/dist/AuthorityPanel.vue_vue_type_style_index_0_lang-DxhZjp1S-CJvk3pW8.js +114 -0
- package/dist/{AuthorityPanel.vue_vue_type_style_index_0_lang-CIYmnP9-.js → AuthorityPanel.vue_vue_type_style_index_0_lang-DxhZjp1S.js} +31 -24
- package/dist/Company-B4vsXy2I-CkNCOqjJ.js +25 -0
- package/dist/{Company-l23MEzdM.js → Company-gKkfnhLt.js} +3 -3
- package/dist/{CompanyPanel-D_s0rh6h.js → CompanyPanel-BF5Pc35s.js} +7 -7
- package/dist/CompanyPanel-Czcx8Gyw-CvndXwB_.js +206 -0
- package/dist/DataSet-DT-rGICv-DaUfgbxk.js +147 -0
- package/dist/{Department-DSEvORLg.js → Department-D0I3QVZe.js} +3 -3
- package/dist/Department-D0dVUrGC-C6HJcYI1.js +25 -0
- package/dist/{DepartmentPanel-WN8nOgCV.js → DepartmentPanel-2LHODgc7.js} +22 -22
- package/dist/DepartmentPanel-e91Lxr1j-BS_A-ILd.js +254 -0
- package/dist/{DesignPanel-DirEGh9M.js → DesignPanel-CtF3cAAQ.js} +1 -1
- package/dist/DesignPanel-DdFl_ohi-uCwFxcl1.js +4 -0
- package/dist/DesignPanel.vue_vue_type_style_index_0_lang-BACPrfUI-cC7yL0uY.js +1013 -0
- package/dist/{DesignPanel.vue_vue_type_style_index_0_lang-D02hXSrN.js → DesignPanel.vue_vue_type_style_index_0_lang-BCYgwoVt.js} +3 -3
- package/dist/DictView-BzQLOf_P-DDicwdmM.js +111 -0
- package/dist/{DictView-DiIQdiek.js → DictView-H3V5hxg3.js} +17 -16
- package/dist/{InvOrganization-b7v3g9EJ.js → InvOrganization-BiGLnbqe.js} +2 -2
- package/dist/InvOrganization-atbhw0CI-BABbVt9V.js +74 -0
- package/dist/Org-BW1YHG-Q-Cow7JWlD.js +39 -0
- package/dist/{Org-BORfx1PL.js → Org-DQTCQHNY.js} +2 -2
- package/dist/Preview-DJtVsoq1-CCGidQjJ.js +48 -0
- package/dist/{Preview-DkRn_TSc.js → Preview-DXaiis29.js} +1 -1
- package/dist/{ReportDefine-Cd0QeaWA.js → ReportDefine-BLh4CiER.js} +1 -1
- package/dist/ReportDefine-CNx_ob99-6NQAHK-Q.js +10 -0
- package/dist/ReportDesign-FbQ6yTJS-C1pPAUSp.js +165 -0
- package/dist/{ReportDesign-4qNqyeEW.js → ReportDesign-Ni1YxrLC.js} +7 -7
- package/dist/ReportQuery-C5gz8Lgd-Eu2cQmda.js +75 -0
- package/dist/{ReportQuery-BJfTFpec.js → ReportQuery-C8G88_qF.js} +1 -1
- package/dist/ReportQueryFrom-C7scua5v-uHXWq8Gy.js +4 -0
- package/dist/{ReportQueryFrom-CB7sExZx.js → ReportQueryFrom-CuZKPtB4.js} +1 -1
- package/dist/{ReportQueryFrom.vue_vue_type_style_index_0_lang-CqO_2Ier.js → ReportQueryFrom.vue_vue_type_style_index_0_lang-BAn_siFW.js} +7 -7
- package/dist/ReportQueryFrom.vue_vue_type_style_index_0_lang-DCbz67Wa-vK6r2uCl.js +178 -0
- package/dist/ReportTemplate-BDANdIWv-D_IGjR1w.js +161 -0
- package/dist/{ReportTemplate-B69muSgT.js → ReportTemplate-DFnDXWmx.js} +8 -8
- package/dist/{Role-Bo4YrNDC.js → Role-BQ7hsfPn.js} +3 -3
- package/dist/Role-ByB0WbxW-5E8Mb148.js +25 -0
- package/dist/RoleAssign-DW6iC_0v-Bis61auk.js +26 -0
- package/dist/{RoleAssign-kOMYJ4s3.js → RoleAssign-UPCg2d4G.js} +3 -3
- package/dist/RolePanel-BM2MaQPU-CgcsbfaX.js +4 -0
- package/dist/{RolePanel-BSJmjyqc.js → RolePanel-C-mQ5XRq.js} +1 -1
- package/dist/RolePanel-ClQy8DBL-DARL4O-o.js +4 -0
- package/dist/{RolePanel-B1d4e6uk.js → RolePanel-CoSXOCZN.js} +1 -1
- package/dist/RolePanel.vue_vue_type_script_setup_true_lang-Bc_Ao_PU-DMmxr2iI.js +132 -0
- package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-DgQpfjaU.js → RolePanel.vue_vue_type_script_setup_true_lang-Bg-t2UhF.js} +7 -7
- package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-DCzX-ZP_.js → RolePanel.vue_vue_type_script_setup_true_lang-D-o7HYZ8.js} +8 -8
- package/dist/RolePanel.vue_vue_type_script_setup_true_lang-fthF1zkp-JsbQJoDy.js +154 -0
- package/dist/ScrollPanel.vue_vue_type_style_index_0_lang-ByWIwajm-BsBf2Vs3.js +100 -0
- package/dist/{ScrollPanel.vue_vue_type_style_index_0_lang-WNOYFxJ1.js → ScrollPanel.vue_vue_type_style_index_0_lang-CCsoxDfk.js} +1 -1
- package/dist/Staff-CuxzvhD9-D0KTcyRh.js +25 -0
- package/dist/{Staff-BFp3zNNR.js → Staff-D-CmvG1R.js} +3 -3
- package/dist/StaffInfo-CY7gUICu-EZUhUwIp.js +4 -0
- package/dist/{StaffInfo-DcU9_40C.js → StaffInfo-Idhvuc6e.js} +1 -1
- package/dist/StaffInfo.vue_vue_type_script_setup_true_lang-Dd8gtQz8-Dlkt-eCn.js +108 -0
- package/dist/{StaffInfo.vue_vue_type_script_setup_true_lang-CtfN2CAr.js → StaffInfo.vue_vue_type_script_setup_true_lang-MUGKjnHU.js} +1 -1
- package/dist/{StaffPanel-7exWkZd9.js → StaffPanel-CDDmAYE5.js} +1 -1
- package/dist/StaffPanel-CwqG0_xr-CrvzLJoc.js +4 -0
- package/dist/{StaffPanel.vue_vue_type_script_setup_true_lang-v5xOXKRS.js → StaffPanel.vue_vue_type_script_setup_true_lang-Bdilqbee.js} +42 -42
- package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-DCdBy8Hu-BXrueqi0.js +143 -0
- package/dist/SysUser-9Q2UJWhi-DprWXFlR.js +15 -0
- package/dist/{SysUser-B3uB_cp2.js → SysUser-a-j5bppr.js} +2 -2
- package/dist/{SysUserPanel-B0CLp5AO.js → SysUserPanel-6V232wwB.js} +1 -1
- package/dist/SysUserPanel-bJy69O7x-BJtBgFEs.js +4 -0
- package/dist/{SysUserPanel.vue_vue_type_script_setup_true_lang-Cwea_4dY.js → SysUserPanel.vue_vue_type_script_setup_true_lang-BOtHuMVy.js} +126 -111
- package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-DUPFqgz3-BSqRCMen.js +356 -0
- package/dist/{SystemMenu-a59l4hTk.js → SystemMenu-BnVeOSOQ.js} +50 -47
- package/dist/SystemMenu-DGOAolc1-CJSLHP8i.js +156 -0
- package/dist/UserInfo-CKoOHkAM-DDWp0I_U.js +4 -0
- package/dist/{UserInfo-D1IA2oLt.js → UserInfo-Cax9b2nw.js} +1 -1
- package/dist/UserInfo.vue_vue_type_style_index_0_lang-BaT53SSu-DsNaAomO.js +160 -0
- package/dist/{UserInfo.vue_vue_type_style_index_0_lang-DDVgYRD5.js → UserInfo.vue_vue_type_style_index_0_lang-D-cw11i9.js} +2 -2
- package/dist/await-to-js.es5-Bv3Eu4mi-UCggJjes.js +10 -0
- package/dist/await-to-js.es5-Bv3Eu4mi.js +10 -0
- package/dist/childView-0YZQ6GBn-CEqg7k5d.js +4 -0
- package/dist/{childView-6rCeLcsx.js → childView-DKG3eZo8.js} +1 -1
- package/dist/childView-DKkgi3yo-D47ft-vi.js +4 -0
- package/dist/{childView-JdrkroL5.js → childView-siumuBz0.js} +1 -1
- package/dist/childView.vue_vue_type_style_index_0_lang-ABMrGInv-ClOdE_sa.js +143 -0
- package/dist/{childView.vue_vue_type_style_index_0_lang-BfcnWnx9.js → childView.vue_vue_type_style_index_0_lang-CUfXDS1q.js} +28 -25
- package/dist/{childView.vue_vue_type_style_index_0_lang-B8x99f1B.js → childView.vue_vue_type_style_index_0_lang-CW3EbAmW.js} +8 -8
- package/dist/childView.vue_vue_type_style_index_0_lang-CaW106ve-CClTM8PK.js +180 -0
- package/dist/{code-rule-2lkPF547.js → code-rule-Dtoree6F.js} +2 -2
- package/dist/code-rule-wQyfgpNL-C4evD4Co.js +148 -0
- package/dist/core.es.js +10 -10
- package/dist/cron-task-C-kryDtd-C0NuGZCe.js +135 -0
- package/dist/{cron-task-DV1pGO1m.js → cron-task-GSRgA7S5.js} +2 -2
- package/dist/flow-task-B07st2aD-CgQvagSQ.js +10 -0
- package/dist/frameView-BOGA3ezf-QoSxzmSQ.js +44 -0
- package/dist/{frameView-C0bzSB8c.js → frameView-Cy6wxW0K.js} +1 -1
- package/dist/index-Dc7xWMiC.js +7265 -0
- package/dist/layout-home-3Dy4onl4.js +228 -0
- package/dist/layout-home-CYHksXN_-Basy-3IH.js +228 -0
- package/dist/layoutView-BaRvAbIa-xVgfqspc.js +3302 -0
- package/dist/{layoutView-CTV-E4Cj.js → layoutView-DMjNscJ-.js} +148 -149
- package/dist/log-in-Cx1dGik8-BVeEHeZ8.js +117 -0
- package/dist/{log-in-CoBP2x6u.js → log-in-VAG6Cvcx.js} +8 -8
- package/dist/log-out-COYdxrNC-ftopGZdE.js +130 -0
- package/dist/{log-out-KX8FiRVf.js → log-out-DZGaMCjC.js} +4 -4
- package/dist/{login-CtCoGWzD.js → login-CqVMdNHs.js} +126 -136
- package/dist/login-Dg9ofNS8-Bocp1XMA.js +241 -0
- package/dist/login-log-DJBGJVV0-AoOyj0jD.js +70 -0
- package/dist/lov-view-C0T5prk8-B2DBmn55.js +97 -0
- package/dist/{lov-view-Bm0JEzzg.js → lov-view-Cc68_28B.js} +7 -7
- package/dist/{menuInfo-D2qPoRwz.js → menuInfo-BIrIaJlH.js} +1 -1
- package/dist/menuInfo-BZJ_q7bz-Drho-_QC.js +4 -0
- package/dist/menuInfo.vue_vue_type_style_index_0_lang-BA8xjUo3-BCZ1wipf.js +363 -0
- package/dist/{menuInfo.vue_vue_type_style_index_0_lang-DoQjX9Ly.js → menuInfo.vue_vue_type_style_index_0_lang-DlE4w35X.js} +38 -36
- package/dist/{pda-app-SbcIclbH.js → pda-app-DnjphrRS.js} +9 -9
- package/dist/pda-app-m9hsppHo-B4xyja1o.js +710 -0
- package/dist/redirect-BqegffKC-CBCIuqmz.js +15 -0
- package/dist/resource-C6KEIXu--B_ddyecm.js +97 -0
- package/dist/{resource-Cdq1UKGI.js → resource-DISgPDM7.js} +4 -4
- package/dist/su-welcome-BjbuSrBZ.js +49424 -0
- package/dist/su-welcome-CYYy-dzr-D3RKPoB0.js +42089 -0
- package/dist/sys-config-DCjJGtht-DARDjlrt.js +370 -0
- package/dist/{sys-config-CCOf4xbj.js → sys-config-Yc9vh1t1.js} +13 -13
- package/dist/udp-core.css +1 -1
- package/dist/utogether-MlnyYtNS-CGgjFNPS.js +4 -0
- package/package.json +5 -2
- package/src/App.vue +37 -31
- package/src/components/udp/content/index.vue +88 -88
- package/src/components/udp/form-upload/form-upload.vue +492 -0
- package/src/components/udp/grid/index.vue +524 -524
- package/src/components/udp/index.ts +6 -5
- package/src/components/udp/ut-stamp-badge/index.vue +271 -271
- package/src/components/udp/utils.ts +408 -408
- package/src/layout/components/lay-content/index.vue +4 -11
- package/src/layout/components/lay-search/components/SearchModal.vue +181 -189
- package/src/layout/components/lay-setting/index.vue +503 -503
- package/src/layout/components/lay-sidebar/sidebar-logo.vue +101 -101
- package/src/layout/components/lay-tag/index.vue +598 -598
- package/src/layout/hooks/useNav.ts +176 -176
- package/src/layout/hooks/useTag.ts +227 -227
- package/src/layout/layoutView.vue +216 -215
- package/src/layout/types.ts +93 -93
- package/src/main.ts +111 -115
- package/src/plugins/i18n/zh.ts +17 -3
- package/src/plugins/vxe-table/index.ts +116 -116
- package/src/plugins/vxe-table/render.tsx +968 -950
- package/src/router/index.ts +187 -187
- package/src/router/modules/home.ts +32 -32
- package/src/router/utils.ts +420 -420
- package/src/store/modules/epTheme.ts +48 -48
- package/src/style/vxetable.scss +18 -2
- package/src/utils/dataFormat/index.ts +222 -222
- package/src/utils/lifecycle.ts +39 -39
- package/src/views/organization/department/DepartmentPanel.vue +303 -303
- package/src/views/organization/staff/StaffInfo.vue +127 -127
- package/src/views/organization/staff/StaffPanel.vue +3 -3
- package/src/views/system/layout/layout-home.vue +237 -0
- package/src/views/system/menu/AuthorityPanel.vue +10 -9
- package/src/views/system/menu/SystemMenu.vue +194 -185
- package/src/views/system/menu/menuInfo.vue +384 -384
- package/src/views/system/sysUser/SysUserPanel.vue +363 -347
- package/src/views/udev/coderule/code-rule.vue +132 -132
- package/src/views/udev/dict/DictView.vue +118 -118
- package/src/views/udev/dict/childView.vue +184 -183
- package/src/views/udev/lov/childView.vue +174 -174
- package/src/views/uhome/components/common-menu.vue +118 -0
- package/src/views/uhome/components/dynamic-component.vue +66 -0
- package/src/views/uhome/components/home-todo.vue +170 -0
- package/src/views/uhome/components/menu-favorite.vue +315 -315
- package/src/views/uhome/dynamic-card.vue +31 -0
- package/src/views/uhome/su-welcome.vue +48 -113
- package/src/views/ulogin/login.vue +336 -325
- package/src/views/upms/interface/log-in.vue +100 -100
- package/src/views/upms/interface/log-out.vue +104 -104
- package/src/views/upms/user/login-log.vue +54 -54
- package/types/global.d.ts +232 -231
- package/dist/await-to-js.es5-BtRbN2QH.js +0 -10
- package/dist/index-BbtbEMCH.js +0 -4649
- package/dist/su-welcome-BHDsjqqV.js +0 -524
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
import { defineComponent as ie, reactive as de, ref as v, inject as oe, createVNode as l, Fragment as k, resolveComponent as r, onMounted as ue, createElementBlock as S, openBlock as h, createBlock as P, createCommentVNode as q, withCtx as n, renderList as ne, unref as me } from "vue";
|
|
2
|
+
import { useI18n as ce } from "vue-i18n";
|
|
3
|
+
import { c as M } from "./await-to-js.es5-Bv3Eu4mi-UCggJjes.js";
|
|
4
|
+
import { useRender as fe, warnMessage as pe, getDictChildren as he, delay as ge, errorMessage as we } from "@utogether/utils";
|
|
5
|
+
import { VxeUI as y } from "vxe-pc-ui";
|
|
6
|
+
import { clone as V, isEmpty as ve } from "xe-utils";
|
|
7
|
+
import { W as ye } from "./su-welcome-BjbuSrBZ.js";
|
|
8
|
+
const Ne = {
|
|
9
|
+
class: "page"
|
|
10
|
+
}, o = "/uums/user", ke = /* @__PURE__ */ ie({
|
|
11
|
+
__name: "SysUserPanel",
|
|
12
|
+
setup(be) {
|
|
13
|
+
const t = de({
|
|
14
|
+
record: {},
|
|
15
|
+
listQuery: {},
|
|
16
|
+
dataList: [],
|
|
17
|
+
roleList: [],
|
|
18
|
+
items: [],
|
|
19
|
+
submitLoading: !1,
|
|
20
|
+
showModelView: !1,
|
|
21
|
+
showUserRole: !1,
|
|
22
|
+
showModal: !1,
|
|
23
|
+
showAuth: !1,
|
|
24
|
+
dataStatus: ""
|
|
25
|
+
}), u = ye(), {
|
|
26
|
+
t: s
|
|
27
|
+
} = ce(), L = {
|
|
28
|
+
userName: [{
|
|
29
|
+
required: !0,
|
|
30
|
+
message: `${s("message.required")}${s("message.userCode")}`
|
|
31
|
+
}],
|
|
32
|
+
name: [{
|
|
33
|
+
required: !0,
|
|
34
|
+
message: `${s("message.required")}${s("message.userName")}`
|
|
35
|
+
}],
|
|
36
|
+
unitId: [{
|
|
37
|
+
required: !0,
|
|
38
|
+
message: `${s("message.required")}${s("message.unitName")}`
|
|
39
|
+
}],
|
|
40
|
+
userPwd: [{
|
|
41
|
+
required: !0,
|
|
42
|
+
message: `${s("message.required")}${s("message.userPwd")}`
|
|
43
|
+
}]
|
|
44
|
+
}, _ = fe(), N = v({}), E = oe("treeList"), c = v(!1);
|
|
45
|
+
let g = "";
|
|
46
|
+
const D = [{
|
|
47
|
+
code: "resetPassword",
|
|
48
|
+
status: "warning",
|
|
49
|
+
icon: "ri-lock-line",
|
|
50
|
+
auth: "batch"
|
|
51
|
+
}], m = v(null), I = [{
|
|
52
|
+
field: "name",
|
|
53
|
+
title: "message.udp.userName"
|
|
54
|
+
}, {
|
|
55
|
+
field: "userName",
|
|
56
|
+
title: "message.udp.userCode"
|
|
57
|
+
}, {
|
|
58
|
+
field: "type",
|
|
59
|
+
title: "message.udp.userType",
|
|
60
|
+
code: "SU.USER.TYPE"
|
|
61
|
+
}], T = [{
|
|
62
|
+
type: "checkbox",
|
|
63
|
+
width: 40,
|
|
64
|
+
align: "center"
|
|
65
|
+
}, {
|
|
66
|
+
field: "userName",
|
|
67
|
+
title: "message.udp.userCode"
|
|
68
|
+
}, {
|
|
69
|
+
field: "name",
|
|
70
|
+
title: "message.udp.userName"
|
|
71
|
+
}, {
|
|
72
|
+
field: "type",
|
|
73
|
+
title: "message.udp.userType",
|
|
74
|
+
formatter: ["formatDict", "SU.USER.TYPE"]
|
|
75
|
+
}, {
|
|
76
|
+
field: "enabled",
|
|
77
|
+
width: 80,
|
|
78
|
+
cellRender: _.renderEnabled(O)
|
|
79
|
+
}, {
|
|
80
|
+
field: "operate",
|
|
81
|
+
width: 150,
|
|
82
|
+
fixed: "right",
|
|
83
|
+
slots: {
|
|
84
|
+
default: ({
|
|
85
|
+
row: e
|
|
86
|
+
}) => [l(k, null, [l(r("ut-button"), {
|
|
87
|
+
content: "edit",
|
|
88
|
+
icon: "ri-edit-line",
|
|
89
|
+
onTap: () => W(e)
|
|
90
|
+
}, null), l(r("ut-dropdown"), {
|
|
91
|
+
buttons: B(),
|
|
92
|
+
onCommand: (a) => A(e, a)
|
|
93
|
+
}, null)])]
|
|
94
|
+
}
|
|
95
|
+
}], A = (e, a) => {
|
|
96
|
+
a === "role" && Q(e), a === "auth" && J(e), a === "passwordReset" && G(e);
|
|
97
|
+
}, B = () => [{
|
|
98
|
+
code: "role",
|
|
99
|
+
icon: "ri-user-fill"
|
|
100
|
+
}, {
|
|
101
|
+
code: "auth",
|
|
102
|
+
icon: "ri-lock-fill"
|
|
103
|
+
}, {
|
|
104
|
+
code: "passwordReset",
|
|
105
|
+
icon: "ri-lock-password-line"
|
|
106
|
+
}], x = [{
|
|
107
|
+
field: "userName",
|
|
108
|
+
title: "message.udp.userCode",
|
|
109
|
+
required: !0,
|
|
110
|
+
disabled: !1
|
|
111
|
+
}, {
|
|
112
|
+
field: "name",
|
|
113
|
+
title: "message.udp.userName",
|
|
114
|
+
required: !0
|
|
115
|
+
}, {
|
|
116
|
+
field: "type",
|
|
117
|
+
required: !0,
|
|
118
|
+
title: "message.udp.userType",
|
|
119
|
+
code: "SU.USER.TYPE"
|
|
120
|
+
}, {
|
|
121
|
+
field: "userPwd",
|
|
122
|
+
required: !0,
|
|
123
|
+
visibleMethod: ({
|
|
124
|
+
data: e
|
|
125
|
+
}) => !e.id
|
|
126
|
+
}], F = () => {
|
|
127
|
+
t.record = {
|
|
128
|
+
userPwd: g,
|
|
129
|
+
...N.value,
|
|
130
|
+
type: "system"
|
|
131
|
+
}, t.items = V(x, !0), t.height = 280, t.showModal = !0;
|
|
132
|
+
}, W = (e) => {
|
|
133
|
+
t.record = V(e, !0), t.items = V(x, !0), t.items[0].disabled = !0, t.height = 240, t.showModal = !0;
|
|
134
|
+
}, Y = () => {
|
|
135
|
+
m.value.getInstance().commitProxy("delete");
|
|
136
|
+
}, j = (e) => [e], z = () => {
|
|
137
|
+
m.value.refreshData();
|
|
138
|
+
};
|
|
139
|
+
async function O({
|
|
140
|
+
row: e
|
|
141
|
+
}) {
|
|
142
|
+
await M(u.put(o, [e])), m.value.refreshData();
|
|
143
|
+
}
|
|
144
|
+
const Q = async (e) => {
|
|
145
|
+
var a;
|
|
146
|
+
t.roleList = [], t.showUserRole = !0, c.value = !0;
|
|
147
|
+
const i = await u.get(o + "/getUserRole", {
|
|
148
|
+
userName: e.userName
|
|
149
|
+
});
|
|
150
|
+
c.value = !1, t.roleList = (a = i[0]) == null ? void 0 : a.sysRoles;
|
|
151
|
+
}, G = async (e) => {
|
|
152
|
+
await y.modal.confirm(s("message.tip.confirmResetPassword")) === "confirm" && (await u.put(o + "/resetPwd", e), await y.modal.alert(s("message.tip.initPassword", {
|
|
153
|
+
code: g
|
|
154
|
+
})));
|
|
155
|
+
}, H = async () => {
|
|
156
|
+
const e = m.value.getSelectRecords();
|
|
157
|
+
if (!e.length || await y.modal.confirm(s("message.tip.confirmResetPassword")) !== "confirm") return;
|
|
158
|
+
const a = e.map((i) => ({
|
|
159
|
+
id: i.id
|
|
160
|
+
}));
|
|
161
|
+
await u.put(o + "/batchUpdatePwd", a), await y.modal.alert(s("message.tip.initPassword", {
|
|
162
|
+
code: g
|
|
163
|
+
})), m.value.refreshData();
|
|
164
|
+
}, J = async (e) => {
|
|
165
|
+
var a;
|
|
166
|
+
t.roleList = [], t.showAuth = !0, c.value = !0, t.record = e;
|
|
167
|
+
const [i, w] = await M(u.get(o + "/getUserRole", {
|
|
168
|
+
userName: e.userName
|
|
169
|
+
}));
|
|
170
|
+
c.value = !1, i || (ve(w) ? pe(s("message.tip.emptyAuth")) : t.roleList = (a = w[0]) == null ? void 0 : a.sysMenuExts);
|
|
171
|
+
}, R = v(null), K = () => {
|
|
172
|
+
R.value.validate(async (e) => {
|
|
173
|
+
if (!e) {
|
|
174
|
+
const {
|
|
175
|
+
record: a,
|
|
176
|
+
dataStatus: i
|
|
177
|
+
} = t;
|
|
178
|
+
i === "add" ? await u.post(o, a) : await u.put(o, a), C();
|
|
179
|
+
}
|
|
180
|
+
});
|
|
181
|
+
}, C = () => {
|
|
182
|
+
t.showModelView = !1;
|
|
183
|
+
}, X = (e) => {
|
|
184
|
+
e === "add" && F(), e === "del" && Y(), e === "resetPassword" && H();
|
|
185
|
+
}, Z = () => {
|
|
186
|
+
u.get("/uums/unit", {
|
|
187
|
+
pageSize: 10
|
|
188
|
+
}).then(async (e) => {
|
|
189
|
+
N.value = {
|
|
190
|
+
unitId: e[0].id,
|
|
191
|
+
enabled: "1"
|
|
192
|
+
}, await ge(100), m.value.refreshData();
|
|
193
|
+
}).catch(() => {
|
|
194
|
+
we("获取租户失败,刷新后重试");
|
|
195
|
+
});
|
|
196
|
+
}, ee = () => {
|
|
197
|
+
var e;
|
|
198
|
+
g = ((e = he("SU.DEFAULT_PASSWORD")) == null ? void 0 : e.find((a) => a.dictCode === "default")).dictName;
|
|
199
|
+
};
|
|
200
|
+
return ue(() => {
|
|
201
|
+
ee(), Z();
|
|
202
|
+
}), (e, a) => {
|
|
203
|
+
const i = r("ut-grid"), w = r("vxe-option"), te = r("vxe-select"), f = r("vxe-form-item"), $ = r("ut-button"), ae = r("vxe-form"), b = r("vxe-modal"), U = r("vxe-column"), le = r("vxe-table"), se = r("el-tree-v2"), re = r("ut-modal-form");
|
|
204
|
+
return h(), S("div", Ne, [l(i, {
|
|
205
|
+
ref_key: "xgrid",
|
|
206
|
+
ref: m,
|
|
207
|
+
columns: T,
|
|
208
|
+
items: I,
|
|
209
|
+
url: o,
|
|
210
|
+
"auto-load": !1,
|
|
211
|
+
"default-params": N.value,
|
|
212
|
+
buttons: D,
|
|
213
|
+
mode: "form",
|
|
214
|
+
onButtonClick: X
|
|
215
|
+
}, null, 8, ["default-params"]), l(b, {
|
|
216
|
+
modelValue: t.showModelView,
|
|
217
|
+
"onUpdate:modelValue": a[0] || (a[0] = (d) => t.showModelView = d),
|
|
218
|
+
title: "用户信息",
|
|
219
|
+
width: "300"
|
|
220
|
+
}, {
|
|
221
|
+
default: n(() => [l(ae, {
|
|
222
|
+
ref_key: "xForm",
|
|
223
|
+
ref: R,
|
|
224
|
+
data: t.record,
|
|
225
|
+
rules: L,
|
|
226
|
+
"title-align": "right"
|
|
227
|
+
}, {
|
|
228
|
+
default: n(() => [l(f, {
|
|
229
|
+
title: e.$t("message.unitName"),
|
|
230
|
+
field: "unitId",
|
|
231
|
+
span: "24"
|
|
232
|
+
}, {
|
|
233
|
+
default: n(({
|
|
234
|
+
data: d
|
|
235
|
+
}) => [l(te, {
|
|
236
|
+
modelValue: d.unitId,
|
|
237
|
+
"onUpdate:modelValue": (p) => d.unitId = p
|
|
238
|
+
}, {
|
|
239
|
+
default: n(() => [(h(!0), S(k, null, ne(me(E), (p) => (h(), P(w, {
|
|
240
|
+
key: p.id,
|
|
241
|
+
value: p.id,
|
|
242
|
+
label: p.unitName
|
|
243
|
+
}, null, 8, ["value", "label"]))), 128))]),
|
|
244
|
+
_: 2
|
|
245
|
+
}, 1032, ["modelValue", "onUpdate:modelValue"])]),
|
|
246
|
+
_: 1
|
|
247
|
+
}, 8, ["title"]), l(f, {
|
|
248
|
+
title: e.$t("message.userCode"),
|
|
249
|
+
"item-render": {
|
|
250
|
+
name: "input",
|
|
251
|
+
attrs: {
|
|
252
|
+
disabled: t.dataStatus === "update"
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
field: "userName",
|
|
256
|
+
span: "24"
|
|
257
|
+
}, null, 8, ["title", "item-render"]), l(f, {
|
|
258
|
+
title: e.$t("message.userName"),
|
|
259
|
+
field: "name",
|
|
260
|
+
span: "24",
|
|
261
|
+
"item-render": {
|
|
262
|
+
name: "input"
|
|
263
|
+
}
|
|
264
|
+
}, null, 8, ["title"]), t.dataStatus === "add" ? (h(), P(f, {
|
|
265
|
+
key: 0,
|
|
266
|
+
title: e.$t("message.userPwd"),
|
|
267
|
+
"item-render": {
|
|
268
|
+
name: "input"
|
|
269
|
+
},
|
|
270
|
+
field: "userPwd",
|
|
271
|
+
span: "24"
|
|
272
|
+
}, null, 8, ["title"])) : q("", !0), l(f, {
|
|
273
|
+
align: "right",
|
|
274
|
+
span: "24"
|
|
275
|
+
}, {
|
|
276
|
+
default: n(() => [l($, {
|
|
277
|
+
content: "cancel",
|
|
278
|
+
icon: "ri-close-fill",
|
|
279
|
+
onClick: C
|
|
280
|
+
}), l($, {
|
|
281
|
+
content: "confirm",
|
|
282
|
+
icon: "ri-save-3-fill",
|
|
283
|
+
status: "u-cyan",
|
|
284
|
+
onClick: K
|
|
285
|
+
})]),
|
|
286
|
+
_: 1
|
|
287
|
+
})]),
|
|
288
|
+
_: 1
|
|
289
|
+
}, 8, ["data"])]),
|
|
290
|
+
_: 1
|
|
291
|
+
}, 8, ["modelValue"]), l(b, {
|
|
292
|
+
modelValue: t.showUserRole,
|
|
293
|
+
"onUpdate:modelValue": a[1] || (a[1] = (d) => t.showUserRole = d),
|
|
294
|
+
loading: c.value,
|
|
295
|
+
title: e.$t("message.title.roleInfo"),
|
|
296
|
+
width: "600"
|
|
297
|
+
}, {
|
|
298
|
+
default: n(() => [l(le, {
|
|
299
|
+
height: "300",
|
|
300
|
+
data: t.roleList,
|
|
301
|
+
border: ""
|
|
302
|
+
}, {
|
|
303
|
+
default: n(() => [l(U, {
|
|
304
|
+
type: "seq",
|
|
305
|
+
width: "60"
|
|
306
|
+
}), l(U, {
|
|
307
|
+
field: "roleName",
|
|
308
|
+
title: e.$t("message.udp.roleName")
|
|
309
|
+
}, null, 8, ["title"]), l(U, {
|
|
310
|
+
field: "roleDesc",
|
|
311
|
+
title: e.$t("message.udp.roleDesc")
|
|
312
|
+
}, null, 8, ["title"])]),
|
|
313
|
+
_: 1
|
|
314
|
+
}, 8, ["data"])]),
|
|
315
|
+
_: 1
|
|
316
|
+
}, 8, ["modelValue", "loading", "title"]), l(b, {
|
|
317
|
+
modelValue: t.showAuth,
|
|
318
|
+
"onUpdate:modelValue": a[2] || (a[2] = (d) => t.showAuth = d),
|
|
319
|
+
loading: c.value,
|
|
320
|
+
title: e.$t("message.title.authority", {
|
|
321
|
+
role: t.record.name || "88888"
|
|
322
|
+
}),
|
|
323
|
+
height: "620",
|
|
324
|
+
width: "560"
|
|
325
|
+
}, {
|
|
326
|
+
default: n(() => [l(se, {
|
|
327
|
+
ref: "xTree",
|
|
328
|
+
data: t.roleList,
|
|
329
|
+
props: {
|
|
330
|
+
children: "children",
|
|
331
|
+
label: "menuName"
|
|
332
|
+
},
|
|
333
|
+
height: 560,
|
|
334
|
+
"node-key": "id"
|
|
335
|
+
}, null, 8, ["data"])]),
|
|
336
|
+
_: 1
|
|
337
|
+
}, 8, ["modelValue", "loading", "title"]), t.showModal ? (h(), P(re, {
|
|
338
|
+
key: 0,
|
|
339
|
+
record: t.record,
|
|
340
|
+
items: t.items,
|
|
341
|
+
width: 360,
|
|
342
|
+
height: t.height,
|
|
343
|
+
method: t.record.id ? "put" : "post",
|
|
344
|
+
"data-process-method": j,
|
|
345
|
+
title: e.$t("message.title.userInfo"),
|
|
346
|
+
"data-status": "update",
|
|
347
|
+
url: o,
|
|
348
|
+
onClose: a[3] || (a[3] = (d) => t.showModal = !1),
|
|
349
|
+
onConfirm: z
|
|
350
|
+
}, null, 8, ["record", "items", "height", "method", "title"])) : q("", !0)]);
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
});
|
|
354
|
+
export {
|
|
355
|
+
ke as x
|
|
356
|
+
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { defineComponent as k, reactive as S, ref as
|
|
2
|
-
import { useI18n as
|
|
3
|
-
import { _ as N } from "./menuInfo.vue_vue_type_style_index_0_lang-
|
|
4
|
-
import { _ as
|
|
5
|
-
import { clone as
|
|
6
|
-
import { t as
|
|
7
|
-
import { VxeUI as
|
|
8
|
-
import { useRender as
|
|
9
|
-
import {
|
|
10
|
-
const
|
|
1
|
+
import { defineComponent as k, reactive as S, ref as D, createVNode as o, resolveComponent as i, Fragment as h, createElementBlock as A, openBlock as E } from "vue";
|
|
2
|
+
import { useI18n as I } from "vue-i18n";
|
|
3
|
+
import { _ as N } from "./menuInfo.vue_vue_type_style_index_0_lang-DlE4w35X.js";
|
|
4
|
+
import { _ as P } from "./AuthorityPanel.vue_vue_type_style_index_0_lang-DxhZjp1S.js";
|
|
5
|
+
import { clone as f } from "xe-utils";
|
|
6
|
+
import { t as R } from "./await-to-js.es5-Bv3Eu4mi.js";
|
|
7
|
+
import { VxeUI as M } from "vxe-pc-ui";
|
|
8
|
+
import { useRender as U } from "@utogether/utils";
|
|
9
|
+
import { g as W } from "./index-Dc7xWMiC.js";
|
|
10
|
+
const B = {
|
|
11
11
|
class: "page-content"
|
|
12
|
-
},
|
|
12
|
+
}, L = {
|
|
13
13
|
name: "SystemMenu"
|
|
14
|
-
},
|
|
15
|
-
...
|
|
16
|
-
setup(
|
|
14
|
+
}, G = /* @__PURE__ */ k({
|
|
15
|
+
...L,
|
|
16
|
+
setup(z) {
|
|
17
17
|
const t = S({
|
|
18
18
|
record: {},
|
|
19
19
|
dataList: [],
|
|
@@ -26,8 +26,8 @@ const W = {
|
|
|
26
26
|
pageNum: 1
|
|
27
27
|
}
|
|
28
28
|
}), {
|
|
29
|
-
t:
|
|
30
|
-
} =
|
|
29
|
+
t: g
|
|
30
|
+
} = I(), C = U(), d = W(), a = D(null), s = "/uums/menu";
|
|
31
31
|
let l;
|
|
32
32
|
const y = [{
|
|
33
33
|
type: "checkbox",
|
|
@@ -57,7 +57,7 @@ const W = {
|
|
|
57
57
|
}, {
|
|
58
58
|
field: "enabled",
|
|
59
59
|
width: 80,
|
|
60
|
-
cellRender:
|
|
60
|
+
cellRender: C.renderEnabled(b)
|
|
61
61
|
}, {
|
|
62
62
|
field: "operate",
|
|
63
63
|
width: 140,
|
|
@@ -66,81 +66,84 @@ const W = {
|
|
|
66
66
|
default: ({
|
|
67
67
|
row: e
|
|
68
68
|
}) => {
|
|
69
|
-
const n = e.menuType,
|
|
69
|
+
const n = e.menuType, r = o(i("ut-button"), {
|
|
70
70
|
status: "u-cyan",
|
|
71
71
|
icon: "ri-add-fill",
|
|
72
72
|
content: "add",
|
|
73
73
|
onTap: () => u(e)
|
|
74
|
-
}, null),
|
|
74
|
+
}, null), m = o(i("ut-button"), {
|
|
75
75
|
icon: "ri-lock-fill",
|
|
76
76
|
content: "auth",
|
|
77
|
-
onTap: () =>
|
|
77
|
+
onTap: () => v(e)
|
|
78
78
|
}, null);
|
|
79
|
-
return [o(
|
|
79
|
+
return [o(h, null, [n ? null : o(h, null, [o(i("ut-button"), {
|
|
80
80
|
status: "success",
|
|
81
81
|
icon: "ri-edit-box-line",
|
|
82
82
|
content: "edit",
|
|
83
|
-
onTap: () =>
|
|
84
|
-
}, null), ["0", "5"].includes(e.menuCategory) ?
|
|
83
|
+
onTap: () => T(e)
|
|
84
|
+
}, null), ["0", "5"].includes(e.menuCategory) ? r : m])])];
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
|
-
}],
|
|
87
|
+
}], w = ({
|
|
88
88
|
code: e
|
|
89
89
|
}) => {
|
|
90
|
-
e === "add" && u(), e === "del" &&
|
|
91
|
-
},
|
|
90
|
+
e === "add" && u(), e === "del" && x();
|
|
91
|
+
}, _ = async ({
|
|
92
92
|
row: e
|
|
93
93
|
}) => {
|
|
94
|
-
const n = await d.get(
|
|
94
|
+
const n = await d.get(s, {
|
|
95
95
|
parentId: e.id
|
|
96
96
|
});
|
|
97
|
-
return new Promise((
|
|
98
|
-
|
|
97
|
+
return new Promise((r) => {
|
|
98
|
+
r(n.list);
|
|
99
99
|
});
|
|
100
100
|
}, u = (e) => {
|
|
101
101
|
t.showDrawer = !0, t.dataStatus = "add", t.record.dispalyCode = e == null ? void 0 : e.permissionCode, t.record.permissionCode = e == null ? void 0 : e.permissionCode, t.record.menuType = "0", t.record.showLink = "Y", t.record.isApprovalPage = "N", t.record.menuCategory = e ? "" : "0", t.record.parentId = e == null ? void 0 : e.id, t.record.hasChildren = e == null ? void 0 : e.hasChildren, t.record.children = t.record.children || [], l = e;
|
|
102
|
-
},
|
|
103
|
-
t.showDrawer = !0, t.dataStatus = "update", t.record =
|
|
102
|
+
}, T = (e) => {
|
|
103
|
+
t.showDrawer = !0, t.dataStatus = "update", t.record = f(e, !0), t.record.menuType = t.record.menuType.toString(), t.record.dispalyCode = e.permissionCode;
|
|
104
104
|
};
|
|
105
|
-
async function
|
|
105
|
+
async function b({
|
|
106
106
|
row: e
|
|
107
107
|
}) {
|
|
108
|
-
await d.put(
|
|
108
|
+
await d.put(s, [e]), a.value.refreshData();
|
|
109
109
|
}
|
|
110
|
-
const
|
|
111
|
-
const e = await
|
|
110
|
+
const x = async () => {
|
|
111
|
+
const e = await M.modal.confirm(g("message.delRecord")), n = a.value.getInstance().getCheckboxRecords();
|
|
112
112
|
if (e === "confirm") {
|
|
113
|
-
const [
|
|
113
|
+
const [r, m] = await R(d.delete(s, n));
|
|
114
|
+
if (r) return;
|
|
115
|
+
const p = a.value.getInstance().getTreeParentRow(n[0]);
|
|
116
|
+
p ? a.value.getInstance().reloadTreeExpand(p) : a.value.refreshData();
|
|
114
117
|
}
|
|
115
|
-
},
|
|
116
|
-
t.showAuthority = !0, t.dataStatus = "update", t.record =
|
|
118
|
+
}, v = (e) => {
|
|
119
|
+
t.showAuthority = !0, t.dataStatus = "update", t.record = f(e, !0), t.record.menuType = t.record.menuType.toString(), t.record.dispalyCode = e.permissionCode;
|
|
117
120
|
}, c = (e, n) => {
|
|
118
|
-
e === "submit" && (l || n) &&
|
|
121
|
+
e === "submit" && (l || n) && a.value.getInstance().reloadTreeExpand(l || n), t.record = {}, t.showDrawer = !1, t.showAuthority = !1;
|
|
119
122
|
};
|
|
120
123
|
return (e, n) => {
|
|
121
|
-
const
|
|
122
|
-
return
|
|
124
|
+
const r = i("ut-grid");
|
|
125
|
+
return E(), A("div", B, [o(r, {
|
|
123
126
|
ref_key: "xgrid",
|
|
124
|
-
ref:
|
|
127
|
+
ref: a,
|
|
125
128
|
"tree-config": {
|
|
126
129
|
childrenField: "children",
|
|
127
130
|
lazy: !0,
|
|
128
131
|
hasChild: "hasChildren",
|
|
129
|
-
loadMethod:
|
|
132
|
+
loadMethod: _,
|
|
130
133
|
iconOpen: "ri-checkbox-indeterminate-line ri-lg",
|
|
131
134
|
iconClose: "ri-add-box-line ri-lg"
|
|
132
135
|
},
|
|
133
136
|
columns: y,
|
|
134
|
-
url:
|
|
137
|
+
url: s,
|
|
135
138
|
stripe: !1,
|
|
136
139
|
mode: "form",
|
|
137
|
-
onToolbarButtonClick:
|
|
140
|
+
onToolbarButtonClick: w
|
|
138
141
|
}, null, 8, ["tree-config"]), o(N, {
|
|
139
142
|
show: t.showDrawer,
|
|
140
143
|
record: t.record,
|
|
141
144
|
"data-status": t.dataStatus,
|
|
142
145
|
onClose: c
|
|
143
|
-
}, null, 8, ["show", "record", "data-status"]), o(
|
|
146
|
+
}, null, 8, ["show", "record", "data-status"]), o(P, {
|
|
144
147
|
show: t.showAuthority,
|
|
145
148
|
record: t.record,
|
|
146
149
|
onClose: c
|
|
@@ -149,5 +152,5 @@ const W = {
|
|
|
149
152
|
}
|
|
150
153
|
});
|
|
151
154
|
export {
|
|
152
|
-
|
|
155
|
+
G as default
|
|
153
156
|
};
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import { defineComponent as k, reactive as D, ref as I, createVNode as o, resolveComponent as i, Fragment as h, createElementBlock as E, openBlock as N } from "vue";
|
|
2
|
+
import { useI18n as B } from "vue-i18n";
|
|
3
|
+
import { i as W } from "./menuInfo.vue_vue_type_style_index_0_lang-BA8xjUo3-BCZ1wipf.js";
|
|
4
|
+
import { B as R } from "./AuthorityPanel.vue_vue_type_style_index_0_lang-DxhZjp1S-CJvk3pW8.js";
|
|
5
|
+
import { clone as f } from "xe-utils";
|
|
6
|
+
import { c as A } from "./await-to-js.es5-Bv3Eu4mi-UCggJjes.js";
|
|
7
|
+
import { VxeUI as L } from "vxe-pc-ui";
|
|
8
|
+
import { useRender as P } from "@utogether/utils";
|
|
9
|
+
import { W as z } from "./su-welcome-BjbuSrBZ.js";
|
|
10
|
+
const M = {
|
|
11
|
+
class: "page-content"
|
|
12
|
+
}, U = {
|
|
13
|
+
name: "SystemMenu"
|
|
14
|
+
}, H = /* @__PURE__ */ k({
|
|
15
|
+
...U,
|
|
16
|
+
setup(F) {
|
|
17
|
+
const r = D({
|
|
18
|
+
record: {},
|
|
19
|
+
dataList: [],
|
|
20
|
+
submitLoading: !1,
|
|
21
|
+
showDrawer: !1,
|
|
22
|
+
dataStatus: "",
|
|
23
|
+
total: 0,
|
|
24
|
+
listQuery: {
|
|
25
|
+
pageSize: 10,
|
|
26
|
+
pageNum: 1
|
|
27
|
+
}
|
|
28
|
+
}), {
|
|
29
|
+
t: w
|
|
30
|
+
} = B(), g = P(), l = z(), n = I(null), a = "/uums/menu";
|
|
31
|
+
let s;
|
|
32
|
+
const y = [{
|
|
33
|
+
type: "checkbox",
|
|
34
|
+
width: 50,
|
|
35
|
+
align: "center"
|
|
36
|
+
}, {
|
|
37
|
+
field: "menuName",
|
|
38
|
+
minWidth: 220,
|
|
39
|
+
treeNode: !0
|
|
40
|
+
}, {
|
|
41
|
+
field: "menuNameEn",
|
|
42
|
+
minWidth: 180
|
|
43
|
+
}, {
|
|
44
|
+
field: "sort",
|
|
45
|
+
width: 70
|
|
46
|
+
}, {
|
|
47
|
+
field: "menuCode",
|
|
48
|
+
minWidth: 220
|
|
49
|
+
}, {
|
|
50
|
+
field: "permissionCode",
|
|
51
|
+
minWidth: 180
|
|
52
|
+
}, {
|
|
53
|
+
field: "menuCategory",
|
|
54
|
+
title: "message.menuType",
|
|
55
|
+
formatter: ["formatDict", "SU.MENU.TYPE"],
|
|
56
|
+
width: 100
|
|
57
|
+
}, {
|
|
58
|
+
field: "enabled",
|
|
59
|
+
width: 80,
|
|
60
|
+
cellRender: g.renderEnabled(b)
|
|
61
|
+
}, {
|
|
62
|
+
field: "operate",
|
|
63
|
+
width: 140,
|
|
64
|
+
fixed: "right",
|
|
65
|
+
slots: {
|
|
66
|
+
default: ({
|
|
67
|
+
row: e
|
|
68
|
+
}) => {
|
|
69
|
+
const t = e.menuType, d = o(i("ut-button"), {
|
|
70
|
+
status: "u-cyan",
|
|
71
|
+
icon: "ri-add-fill",
|
|
72
|
+
content: "add",
|
|
73
|
+
onTap: () => u(e)
|
|
74
|
+
}, null), m = o(i("ut-button"), {
|
|
75
|
+
icon: "ri-lock-fill",
|
|
76
|
+
content: "auth",
|
|
77
|
+
onTap: () => S(e)
|
|
78
|
+
}, null);
|
|
79
|
+
return [o(h, null, [t ? null : o(h, null, [o(i("ut-button"), {
|
|
80
|
+
status: "success",
|
|
81
|
+
icon: "ri-edit-box-line",
|
|
82
|
+
content: "edit",
|
|
83
|
+
onTap: () => v(e)
|
|
84
|
+
}, null), ["0", "5"].includes(e.menuCategory) ? d : m])])];
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}], C = ({
|
|
88
|
+
code: e
|
|
89
|
+
}) => {
|
|
90
|
+
e === "add" && u(), e === "del" && x();
|
|
91
|
+
}, T = async ({
|
|
92
|
+
row: e
|
|
93
|
+
}) => {
|
|
94
|
+
const t = await l.get(a, {
|
|
95
|
+
parentId: e.id
|
|
96
|
+
});
|
|
97
|
+
return new Promise((d) => {
|
|
98
|
+
d(t.list);
|
|
99
|
+
});
|
|
100
|
+
}, u = (e) => {
|
|
101
|
+
r.showDrawer = !0, r.dataStatus = "add", r.record.dispalyCode = e == null ? void 0 : e.permissionCode, r.record.permissionCode = e == null ? void 0 : e.permissionCode, r.record.menuType = "0", r.record.showLink = "Y", r.record.isApprovalPage = "N", r.record.menuCategory = e ? "" : "0", r.record.parentId = e == null ? void 0 : e.id, r.record.hasChildren = e == null ? void 0 : e.hasChildren, r.record.children = r.record.children || [], s = e;
|
|
102
|
+
}, v = (e) => {
|
|
103
|
+
r.showDrawer = !0, r.dataStatus = "update", r.record = f(e, !0), r.record.menuType = r.record.menuType.toString(), r.record.dispalyCode = e.permissionCode;
|
|
104
|
+
};
|
|
105
|
+
async function b({
|
|
106
|
+
row: e
|
|
107
|
+
}) {
|
|
108
|
+
await l.put(a, [e]), n.value.refreshData();
|
|
109
|
+
}
|
|
110
|
+
const x = async () => {
|
|
111
|
+
const e = await L.modal.confirm(w("message.delRecord")), t = n.value.getInstance().getCheckboxRecords();
|
|
112
|
+
if (e === "confirm") {
|
|
113
|
+
const [d, m] = await A(l.delete(a, t));
|
|
114
|
+
if (d) return;
|
|
115
|
+
const p = n.value.getInstance().getTreeParentRow(t[0]);
|
|
116
|
+
p ? n.value.getInstance().reloadTreeExpand(p) : n.value.refreshData();
|
|
117
|
+
}
|
|
118
|
+
}, S = (e) => {
|
|
119
|
+
r.showAuthority = !0, r.dataStatus = "update", r.record = f(e, !0), r.record.menuType = r.record.menuType.toString(), r.record.dispalyCode = e.permissionCode;
|
|
120
|
+
}, c = (e, t) => {
|
|
121
|
+
e === "submit" && (s || t) && n.value.getInstance().reloadTreeExpand(s || t), r.record = {}, r.showDrawer = !1, r.showAuthority = !1;
|
|
122
|
+
};
|
|
123
|
+
return (e, t) => {
|
|
124
|
+
const d = i("ut-grid");
|
|
125
|
+
return N(), E("div", M, [o(d, {
|
|
126
|
+
ref_key: "xgrid",
|
|
127
|
+
ref: n,
|
|
128
|
+
"tree-config": {
|
|
129
|
+
childrenField: "children",
|
|
130
|
+
lazy: !0,
|
|
131
|
+
hasChild: "hasChildren",
|
|
132
|
+
loadMethod: T,
|
|
133
|
+
iconOpen: "ri-checkbox-indeterminate-line ri-lg",
|
|
134
|
+
iconClose: "ri-add-box-line ri-lg"
|
|
135
|
+
},
|
|
136
|
+
columns: y,
|
|
137
|
+
url: a,
|
|
138
|
+
stripe: !1,
|
|
139
|
+
mode: "form",
|
|
140
|
+
onToolbarButtonClick: C
|
|
141
|
+
}, null, 8, ["tree-config"]), o(W, {
|
|
142
|
+
show: r.showDrawer,
|
|
143
|
+
record: r.record,
|
|
144
|
+
"data-status": r.dataStatus,
|
|
145
|
+
onClose: c
|
|
146
|
+
}, null, 8, ["show", "record", "data-status"]), o(R, {
|
|
147
|
+
show: r.showAuthority,
|
|
148
|
+
record: r.record,
|
|
149
|
+
onClose: c
|
|
150
|
+
}, null, 8, ["show", "record"])]);
|
|
151
|
+
};
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
export {
|
|
155
|
+
H as default
|
|
156
|
+
};
|