@utogether/udp-core 1.0.1-beta.9 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (168) hide show
  1. package/build/plugins.ts +37 -39
  2. package/dist/{403-BOzKHdlm.js → 403-B1rIjAAu.js} +6 -6
  3. package/dist/{404-uwgt4Nll.js → 404-mBqc2y4t.js} +4 -4
  4. package/dist/{500-4HBf6V9m.js → 500-BoI45Zdh.js} +2 -2
  5. package/dist/{AuthorityInfo-DvbIh1vT.js → AuthorityInfo-B08NBIIn.js} +1 -1
  6. package/dist/{AuthorityInfo.vue_vue_type_style_index_0_lang-BlCPvwXU.js → AuthorityInfo.vue_vue_type_style_index_0_lang-BLP1SaiH.js} +3 -3
  7. package/dist/{Company-D7Q9BFmr.js → Company-JGGyWEWH.js} +3 -3
  8. package/dist/{CompanyPanel-C0-PJlrt.js → CompanyPanel-BQ_cCmDx.js} +7 -7
  9. package/dist/{Department-h2hlXACv.js → Department-z2iO6hwM.js} +10 -10
  10. package/dist/{DepartmentPanel-B6hDEQpG.js → DepartmentPanel-BtQe7zwU.js} +108 -78
  11. package/dist/{DesignPanel-cS58-1v9.js → DesignPanel-7mhtVWas.js} +1 -1
  12. package/dist/{DesignPanel.vue_vue_type_style_index_0_lang-LdvLC8VU.js → DesignPanel.vue_vue_type_style_index_0_lang-4EsHemj_.js} +6 -6
  13. package/dist/{DictView-T3TmpBa8.js → DictView-CjchV2Yk.js} +15 -16
  14. package/dist/InvOrganization-Pn1O_XP0.js +74 -0
  15. package/dist/{Org-CnCBDGKF.js → Org-BqytV_vi.js} +1 -1
  16. package/dist/{Preview-BaktKXB1.js → Preview-CLpUUMay.js} +2 -2
  17. package/dist/{ReportDefine-5Rb0PO9A.js → ReportDefine-Cz1KtEUF.js} +1 -1
  18. package/dist/{ReportDesign-DYdkVREA.js → ReportDesign-BaORYud4.js} +13 -13
  19. package/dist/{ReportQuery-BwhzIXMt.js → ReportQuery-CPCPXiXz.js} +1 -1
  20. package/dist/{ReportQueryFrom-PHtWwlOe.js → ReportQueryFrom-C_AcrfkJ.js} +1 -1
  21. package/dist/{ReportQueryFrom.vue_vue_type_style_index_0_lang-BE5yZNPM.js → ReportQueryFrom.vue_vue_type_style_index_0_lang-Bm67ejay.js} +1 -1
  22. package/dist/{ReportTemplate-DaadVXIi.js → ReportTemplate-CFiNMz79.js} +11 -11
  23. package/dist/{Role-Dtg3nAmG.js → Role-B-XDoJd5.js} +3 -3
  24. package/dist/{RoleAssign-DEGtLssH.js → RoleAssign-BolW8YVs.js} +8 -8
  25. package/dist/{RolePanel-DpUzfE_o.js → RolePanel-2kfs5tw9.js} +1 -1
  26. package/dist/{RolePanel-CT7BTPmy.js → RolePanel-HilSuYns.js} +1 -1
  27. package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-Xyo0YEI0.js → RolePanel.vue_vue_type_script_setup_true_lang-CE4gApUY.js} +7 -7
  28. package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-Dg2A6DJu.js → RolePanel.vue_vue_type_script_setup_true_lang-DPzgfAyV.js} +13 -13
  29. package/dist/{ScrollPanel.vue_vue_type_style_index_0_lang-CyutzDZS.js → ScrollPanel.vue_vue_type_style_index_0_lang-CCTH4RkH.js} +4 -4
  30. package/dist/{Staff-_NlAGkrh.js → Staff-BTk3whFC.js} +3 -3
  31. package/dist/{StaffInfo-DVgUvVgd.js → StaffInfo-d3AuSzlA.js} +1 -1
  32. package/dist/{StaffInfo.vue_vue_type_script_setup_true_lang-C8hmlFgX.js → StaffInfo.vue_vue_type_script_setup_true_lang-eOL4VlfE.js} +5 -5
  33. package/dist/{StaffPanel-DKNZE3IE.js → StaffPanel-DV-D4jjz.js} +1 -1
  34. package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-4sFq3CEo.js +135 -0
  35. package/dist/{SysUser-kQUf7XKz.js → SysUser-BnjYytws.js} +2 -2
  36. package/dist/{SysUserPanel-C191uX3U.js → SysUserPanel-CBoyD-Qi.js} +1 -1
  37. package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-PrTlTZR-.js +341 -0
  38. package/dist/{SystemMenu-DwuSvHnj.js → SystemMenu-kYB_ZaUt.js} +36 -36
  39. package/dist/{UserInfo-DIsInFld.js → UserInfo-4dx97VBL.js} +1 -1
  40. package/dist/{UserInfo.vue_vue_type_style_index_0_lang-CnvGdbej.js → UserInfo.vue_vue_type_style_index_0_lang-BpbC_ZDm.js} +10 -10
  41. package/dist/{childView-3Bs2UBEw.js → childView-CHPNfTEb.js} +1 -1
  42. package/dist/{childView-BawyULD7.js → childView-CKA_JgVZ.js} +1 -1
  43. package/dist/{childView.vue_vue_type_style_index_0_lang-YpWF-p2F.js → childView.vue_vue_type_style_index_0_lang-Bym2fQRd.js} +7 -7
  44. package/dist/childView.vue_vue_type_style_index_0_lang-W7bCtXeu.js +177 -0
  45. package/dist/{code-rule-DVaYcn8S.js → code-rule-CbxuZg0-.js} +40 -38
  46. package/dist/core.es.js +18 -12
  47. package/dist/{cron-task-xuzP-BpE.js → cron-task-nTOpqQYf.js} +7 -7
  48. package/dist/flow-task-B07st2aD.js +10 -0
  49. package/dist/{frameView-Cudt06qS.js → frameView-Z1tPUyCh.js} +1 -1
  50. package/dist/index-C3q8HoJM.js +4650 -0
  51. package/dist/{layoutView-BlFTV2jX.js → layoutView--MGA9zUB.js} +1766 -1760
  52. package/dist/{log-in-e7D5Ss1P.js → log-in-CSYJDA6m.js} +36 -29
  53. package/dist/log-out-DiwGCg7p.js +130 -0
  54. package/dist/login-C6Y0ajDp.js +251 -0
  55. package/dist/{login-log-kqKzKTto.js → login-log-C0V-_l3F.js} +5 -3
  56. package/dist/{lov-view-B2HaxyMs.js → lov-view-Cmv7wZZ9.js} +6 -6
  57. package/dist/{menuInfo-BxCTJ1VW.js → menuInfo-UeutJpOa.js} +1 -1
  58. package/dist/{menuInfo.vue_vue_type_style_index_0_lang-CLOPNeUW.js → menuInfo.vue_vue_type_style_index_0_lang-CWX4Mu67.js} +118 -98
  59. package/dist/{pda-app-DPsAFNiw.js → pda-app-B6w99SJo.js} +10 -10
  60. package/dist/{resource-Dibb7t8u.js → resource-BybJvUv0.js} +4 -4
  61. package/dist/{su-welcome-DejR0KkM.js → su-welcome-C1bmxHoY.js} +119 -121
  62. package/dist/sys-config-BnmIDnCj.js +370 -0
  63. package/dist/udp-core.css +1 -9
  64. package/dist/utogether-MlnyYtNS.js +4 -0
  65. package/index.ts +49 -40
  66. package/package.json +18 -18
  67. package/src/App.vue +65 -65
  68. package/src/api/http.ts +1 -4
  69. package/src/api/index.ts +4 -2
  70. package/src/api/user.ts +2 -2
  71. package/src/components/SuCharts/src/UserInfo.vue +78 -78
  72. package/src/components/SuScrollTree/ScrollPanel.vue +1 -6
  73. package/src/components/udp/content/index.vue +88 -0
  74. package/src/components/udp/{form.vue → form/form.vue} +13 -16
  75. package/src/components/udp/{grid.vue → grid/index.vue} +56 -27
  76. package/src/components/udp/index.ts +4 -9
  77. package/src/components/udp/ut-stamp-badge/index.vue +271 -0
  78. package/src/components/udp/utils.ts +66 -105
  79. package/src/layout/components/lay-navbar/index.vue +8 -6
  80. package/src/layout/components/lay-panel/index.vue +150 -150
  81. package/src/layout/components/lay-search/index.vue +25 -25
  82. package/src/layout/components/lay-select-org/index.vue +4 -9
  83. package/src/layout/components/lay-setting/index.vue +503 -510
  84. package/src/layout/components/lay-sidebar/horizontal.vue +8 -6
  85. package/src/layout/components/lay-sidebar/mixNav.vue +260 -258
  86. package/src/layout/components/lay-sidebar/sidebar-logo.vue +101 -98
  87. package/src/layout/components/lay-tag/index.vue +24 -51
  88. package/src/layout/hooks/useDataThemeChange.ts +1 -1
  89. package/src/layout/hooks/useNav.ts +176 -173
  90. package/src/layout/hooks/useTag.ts +227 -233
  91. package/src/layout/types.ts +93 -92
  92. package/src/main.ts +115 -119
  93. package/src/plugins/i18n/en.ts +302 -302
  94. package/src/plugins/i18n/module/u-workflow.ts +1 -1
  95. package/src/plugins/i18n/zh.ts +21 -6
  96. package/src/plugins/vxe-table/index.ts +116 -53
  97. package/src/plugins/vxe-table/render.tsx +945 -956
  98. package/src/router/index.ts +17 -17
  99. package/src/router/modules/flow.ts +35 -0
  100. package/src/router/modules/home.ts +32 -32
  101. package/src/router/modules/remaining.ts +58 -58
  102. package/src/router/utils.ts +420 -377
  103. package/src/store/modules/app.ts +2 -4
  104. package/src/store/modules/epTheme.ts +48 -49
  105. package/src/store/modules/multiTags.ts +15 -14
  106. package/src/store/modules/permission.ts +25 -15
  107. package/src/store/modules/system.ts +1 -3
  108. package/src/style/button.scss +85 -85
  109. package/src/style/login.css +1 -1
  110. package/src/style/vxetable.scss +61 -2
  111. package/src/utils/dataFormat/index.ts +223 -223
  112. package/src/utils/index.ts +3 -1
  113. package/src/utils/lifecycle.ts +39 -20
  114. package/src/utils/propTypes.ts +1 -6
  115. package/src/utils/storage/index.ts +2 -2
  116. package/src/utils/udp/http/index.ts +24 -11
  117. package/src/utils/udp/http/types.d.ts +3 -10
  118. package/src/views/login/login-view.vue +4 -18
  119. package/src/views/organization/company/CompanyPanel.vue +259 -259
  120. package/src/views/organization/department/Department.vue +58 -58
  121. package/src/views/organization/department/DepartmentPanel.vue +303 -283
  122. package/src/views/organization/inv-org/InvOrganization.vue +22 -7
  123. package/src/views/organization/staff/StaffInfo.vue +127 -133
  124. package/src/views/organization/staff/StaffPanel.vue +162 -145
  125. package/src/views/system/cron/cron-task.vue +2 -12
  126. package/src/views/system/menu/SystemMenu.vue +185 -183
  127. package/src/views/system/menu/menuInfo.vue +384 -363
  128. package/src/views/system/role/UserInfo.vue +195 -195
  129. package/src/views/system/role-assign/RoleAssign.vue +57 -57
  130. package/src/views/system/role-assign/RolePanel.vue +139 -139
  131. package/src/views/system/sys/sys-config.vue +69 -20
  132. package/src/views/system/sysUser/SysUserPanel.vue +97 -28
  133. package/src/views/uapp/pda/pda-app.vue +208 -208
  134. package/src/views/udev/coderule/code-rule.vue +132 -121
  135. package/src/views/udev/dict/DictView.vue +2 -2
  136. package/src/views/udev/dict/childView.vue +183 -222
  137. package/src/views/udev/lov/childView.vue +1 -7
  138. package/src/views/udev/lov/lov-view.vue +91 -91
  139. package/src/views/uhome/components/menu-favorite.vue +314 -331
  140. package/src/views/uhome/su-welcome.vue +319 -339
  141. package/src/views/ulogin/login.vue +325 -321
  142. package/src/views/upms/interface/log-in.vue +100 -106
  143. package/src/views/upms/interface/log-out.vue +104 -107
  144. package/src/views/upms/user/login-log.vue +54 -60
  145. package/src/views/urpt/design/DesignPanel.vue +507 -507
  146. package/src/views/urpt/design/Preview.vue +1 -0
  147. package/src/views/urpt/design/ReportDesign.vue +2 -4
  148. package/src/views/utask/flow-task.vue +18 -0
  149. package/types/global.d.ts +231 -236
  150. package/dist/InvOrganization-BVuOhzbt.js +0 -66
  151. package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-BOOO6Cek.js +0 -111
  152. package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-SwNbAEvW.js +0 -294
  153. package/dist/childView.vue_vue_type_style_index_0_lang-DWIFCX3X.js +0 -187
  154. package/dist/index-CKnq5xIa.js +0 -2623
  155. package/dist/log-out--RRncZhN.js +0 -120
  156. package/dist/login-CpKykfdf.js +0 -253
  157. package/dist/sys-config-DiySRWns.js +0 -277
  158. package/dist/utogether-Dct_14Zk.js +0 -182
  159. package/src/components/udp/count-down.vue +0 -536
  160. package/src/components/udp/flip-down/FlipCard/flip-card.vue +0 -251
  161. package/src/components/udp/flip-down/FlipCard/interfaces.ts +0 -4
  162. package/src/components/udp/flip-down/FlipClock/flip-clock.vue +0 -113
  163. package/src/components/udp/form-upload.vue +0 -482
  164. package/src/components/udp/lov.vue +0 -388
  165. package/src/components/udp/modal-form.vue +0 -189
  166. package/src/components/udp/modal-grid.vue +0 -288
  167. package/src/components/udp/upload.vue +0 -423
  168. package/src/utils/udp/useRender.ts +0 -431
@@ -1,111 +0,0 @@
1
- import { defineComponent as b, ref as g, inject as w, reactive as x, watch as y, nextTick as E, resolveComponent as l, createElementBlock as N, openBlock as c, createVNode as d, createBlock as k, createCommentVNode as C, Fragment as S } from "vue";
2
- import { clone as D } from "xe-utils";
3
- import { warnMessage as M } from "@utogether/utils";
4
- import { _ as B } from "./StaffInfo.vue_vue_type_script_setup_true_lang-C8hmlFgX.js";
5
- import { q as P } from "./index-CKnq5xIa.js";
6
- const A = {
7
- class: "page-content"
8
- }, s = "/uums/employee", j = /* @__PURE__ */ b({
9
- __name: "StaffPanel",
10
- setup(I) {
11
- const o = g(null), n = w("active"), t = x({
12
- record: {},
13
- showModelView: !1,
14
- fetchExtParam: {}
15
- });
16
- y(() => n.value, (e) => {
17
- t.fetchExtParam = {
18
- departmentId: e == null ? void 0 : e.id
19
- }, E(() => {
20
- o.value.refreshData();
21
- });
22
- });
23
- const i = [{
24
- field: "employeeCode"
25
- }, {
26
- field: "employeeName"
27
- }], u = [{
28
- type: "checkbox",
29
- width: 50,
30
- align: "center"
31
- }, {
32
- field: "employeeCode"
33
- }, {
34
- field: "employeeName",
35
- width: 150
36
- }, {
37
- field: "gender",
38
- width: 100,
39
- formatter: ["formatDict", "SU.GENDER"]
40
- }, {
41
- field: "enabled",
42
- width: 100,
43
- formatter: ["formatDict", "SU.ENABLE"]
44
- }, {
45
- field: "operate",
46
- width: 150,
47
- fixed: "right",
48
- slots: {
49
- default: ({
50
- row: e
51
- }) => {
52
- const a = ["1", "Y"].includes(e.enabled) ? "disabled" : "enable", r = ["1", "Y"].includes(e.enabled) ? "ri-stop-circle-fill" : "ri-play-circle-fill", v = ["1", "Y"].includes(e.enabled) ? "warning" : "success";
53
- return [d(S, null, [d(l("ut-button"), {
54
- icon: "ri-edit-box-line",
55
- content: "edit",
56
- onTap: () => p(e)
57
- }, null), d(l("ut-button"), {
58
- icon: r,
59
- content: a,
60
- status: v,
61
- onTap: () => h(e)
62
- }, null)])];
63
- }
64
- }
65
- }], m = {
66
- toolbarButtonClick({
67
- code: e
68
- }) {
69
- e === "add" && f();
70
- }
71
- }, f = () => {
72
- var e, a;
73
- if (!((e = n.value) != null && e.deptName))
74
- return M("请先选择部门");
75
- t.dataStatus = "add", t.record = {}, t.record.departmentId = (a = n.value) == null ? void 0 : a.id, t.record.deptName = n.value.deptName, t.record.enabled = "1", t.showModelView = !0;
76
- }, p = (e) => {
77
- t.dataStatus = "update", t.record = e, t.showModelView = !0;
78
- }, h = async (e) => {
79
- const a = D(e, !0);
80
- o.value.showLoading(), a.enabled = a.enabled === "1" ? "0" : "1", await P().put(s, a), o.value.hiddenLoading(), o.value.refreshData();
81
- }, _ = () => {
82
- t.showModelView = !1, o.value.refreshData();
83
- };
84
- return (e, a) => {
85
- const r = l("ut-grid");
86
- return c(), N("div", A, [d(r, {
87
- ref_key: "xgrid",
88
- ref: o,
89
- items: i,
90
- columns: u,
91
- "default-params": t.fetchExtParam,
92
- events: m,
93
- "auto-load": !1,
94
- buttons: [{
95
- code: "del",
96
- auth: "/"
97
- }],
98
- url: s,
99
- mode: "form"
100
- }, null, 8, ["default-params"]), t.showModelView ? (c(), k(B, {
101
- key: 0,
102
- record: t.record,
103
- "data-status": t.dataStatus,
104
- onOnClose: _
105
- }, null, 8, ["record", "data-status"])) : C("", !0)]);
106
- };
107
- }
108
- });
109
- export {
110
- j as _
111
- };
@@ -1,294 +0,0 @@
1
- import { defineComponent as z, reactive as G, ref as h, inject as H, createVNode as s, Fragment as U, resolveComponent as l, onMounted as Q, createElementBlock as $, openBlock as v, withCtx as i, createBlock as k, createCommentVNode as J, renderList as K, unref as O } from "vue";
2
- import { useI18n as W } from "vue-i18n";
3
- import { t as q } from "./await-to-js.es5-BtRbN2QH.js";
4
- import { useRender as X, warnMessage as Z, delay as ee, errorMessage as te } from "@utogether/utils";
5
- import { VxeUI as se } from "vxe-pc-ui";
6
- import { isEmpty as ae } from "xe-utils";
7
- import { q as le } from "./index-CKnq5xIa.js";
8
- const re = {
9
- class: "page"
10
- }, u = "/uums/user", fe = /* @__PURE__ */ z({
11
- __name: "SysUserPanel",
12
- setup(oe) {
13
- const t = G({
14
- record: {},
15
- listQuery: {},
16
- dataList: [],
17
- roleList: [],
18
- submitLoading: !1,
19
- showModelView: !1,
20
- showUserRole: !1,
21
- showAuth: !1,
22
- dataStatus: ""
23
- }), d = le(), {
24
- t: r
25
- } = W(), L = {
26
- userName: [{
27
- required: !0,
28
- message: `${r("message.required")}${r("message.userCode")}`
29
- }],
30
- name: [{
31
- required: !0,
32
- message: `${r("message.required")}${r("message.userName")}`
33
- }],
34
- unitId: [{
35
- required: !0,
36
- message: `${r("message.required")}${r("message.unitName")}`
37
- }],
38
- userPwd: [{
39
- required: !0,
40
- message: `${r("message.required")}${r("message.userPwd")}`
41
- }]
42
- }, c = X(), w = h({}), C = H("treeList"), m = h(!1), _ = h(null), I = [{
43
- field: "name",
44
- title: "message.udp.userName"
45
- }, {
46
- field: "userName",
47
- title: "message.udp.userCode"
48
- }], y = [{
49
- type: "checkbox",
50
- width: 40,
51
- align: "center"
52
- }, {
53
- field: "userName",
54
- title: "message.udp.userCode",
55
- required: !0,
56
- editRender: c.renderInput()
57
- }, {
58
- field: "name",
59
- title: "message.udp.userName",
60
- required: !0,
61
- editRender: c.renderInput()
62
- }, {
63
- field: "type",
64
- title: "message.udp.userType",
65
- formatter: ["formatDict", "SU.USER.TYPE"],
66
- editRender: c.renderDict("SU.USER.TYPE")
67
- }, {
68
- field: "userPwd",
69
- required: !0,
70
- width: 150,
71
- editRender: c.renderInput(),
72
- formatter: () => "*******"
73
- }, {
74
- field: "enabled",
75
- width: 80,
76
- cellRender: c.renderEnabled(P)
77
- }, {
78
- field: "operate",
79
- width: 240,
80
- fixed: "right",
81
- slots: {
82
- default: ({
83
- row: e
84
- }) => e.id ? [s(U, null, [s(l("ut-button"), {
85
- icon: "ri-user-fill",
86
- content: "role",
87
- onTap: () => S(e)
88
- }, null), s(l("ut-button"), {
89
- icon: "ri-lock-fill",
90
- content: "auth",
91
- status: "success",
92
- onTap: () => E(e)
93
- }, null), s(l("ut-button"), {
94
- icon: "ri-lock-fill",
95
- content: "passwordReset",
96
- status: "warning",
97
- onTap: () => A(e)
98
- }, null)])] : null
99
- }
100
- }];
101
- async function P({
102
- row: e
103
- }) {
104
- await q(d.put(u, [e])), _.value.refreshData();
105
- }
106
- const S = async (e) => {
107
- var o;
108
- t.roleList = [], t.showUserRole = !0, m.value = !0;
109
- const a = await d.get(u + "/getUserRole", {
110
- userName: e.userName
111
- });
112
- m.value = !1, t.roleList = (o = a[0]) == null ? void 0 : o.sysRoles;
113
- }, A = async (e) => {
114
- await d.put(u + "/resetPwd", e), await se.modal.alert(r("message.tip.initPassword"));
115
- }, E = async (e) => {
116
- var g;
117
- t.roleList = [], t.showAuth = !0, m.value = !0, t.record = e;
118
- const [a, o] = await q(d.get(u + "/getUserRole", {
119
- userName: e.userName
120
- }));
121
- m.value = !1, a || (ae(o) ? Z(r("message.tip.emptyAuth")) : t.roleList = (g = o[0]) == null ? void 0 : g.sysMenuExts);
122
- }, M = {
123
- editActived({
124
- row: e
125
- }) {
126
- y[1].editRender.props.disabled = !!e.id, y[4].editRender.props.disabled = !!e.id;
127
- }
128
- }, R = h(null), D = () => {
129
- R.value.validate(async (e) => {
130
- if (!e) {
131
- const {
132
- record: a,
133
- dataStatus: o
134
- } = t;
135
- o === "add" ? await d.post(u, a) : await d.put(u, a), V();
136
- }
137
- });
138
- }, V = () => {
139
- t.showModelView = !1;
140
- }, T = () => {
141
- d.get("/uums/unit", {
142
- pageSize: 10
143
- }).then(async (e) => {
144
- w.value = {
145
- unitId: e[0].id,
146
- enabled: "1"
147
- }, await ee(100), _.value.refreshData();
148
- }).catch(() => {
149
- te("获取租户失败,刷新后重试");
150
- });
151
- };
152
- return Q(() => {
153
- T();
154
- }), (e, a) => {
155
- const o = l("ut-grid"), g = l("vxe-option"), B = l("vxe-select"), p = l("vxe-form-item"), x = l("ut-button"), F = l("vxe-form"), b = l("vxe-modal"), N = l("vxe-column"), Y = l("vxe-table"), j = l("el-tree-v2");
156
- return v(), $("div", re, [s(o, {
157
- ref_key: "xgrid",
158
- ref: _,
159
- columns: y,
160
- items: I,
161
- url: u,
162
- "auto-load": !1,
163
- "default-params": w.value,
164
- "default-value": w.value,
165
- events: M
166
- }, null, 8, ["default-params", "default-value"]), s(b, {
167
- modelValue: t.showModelView,
168
- "onUpdate:modelValue": a[0] || (a[0] = (n) => t.showModelView = n),
169
- title: "用户信息",
170
- width: "300"
171
- }, {
172
- default: i(() => [s(F, {
173
- ref_key: "xForm",
174
- ref: R,
175
- data: t.record,
176
- rules: L,
177
- "title-align": "right"
178
- }, {
179
- default: i(() => [s(p, {
180
- title: e.$t("message.unitName"),
181
- field: "unitId",
182
- span: "24"
183
- }, {
184
- default: i(({
185
- data: n
186
- }) => [s(B, {
187
- modelValue: n.unitId,
188
- "onUpdate:modelValue": (f) => n.unitId = f
189
- }, {
190
- default: i(() => [(v(!0), $(U, null, K(O(C), (f) => (v(), k(g, {
191
- key: f.id,
192
- value: f.id,
193
- label: f.unitName
194
- }, null, 8, ["value", "label"]))), 128))]),
195
- _: 2
196
- }, 1032, ["modelValue", "onUpdate:modelValue"])]),
197
- _: 1
198
- }, 8, ["title"]), s(p, {
199
- title: e.$t("message.userCode"),
200
- "item-render": {
201
- name: "input",
202
- attrs: {
203
- disabled: t.dataStatus === "update"
204
- }
205
- },
206
- field: "userName",
207
- span: "24"
208
- }, null, 8, ["title", "item-render"]), s(p, {
209
- title: e.$t("message.userName"),
210
- field: "name",
211
- span: "24",
212
- "item-render": {
213
- name: "input"
214
- }
215
- }, null, 8, ["title"]), t.dataStatus === "add" ? (v(), k(p, {
216
- key: 0,
217
- title: e.$t("message.userPwd"),
218
- "item-render": {
219
- name: "input"
220
- },
221
- field: "userPwd",
222
- span: "24"
223
- }, null, 8, ["title"])) : J("", !0), s(p, {
224
- align: "right",
225
- span: "24"
226
- }, {
227
- default: i(() => [s(x, {
228
- content: "cancel",
229
- icon: "ri-close-fill",
230
- onClick: V
231
- }), s(x, {
232
- content: "confirm",
233
- icon: "ri-save-3-fill",
234
- status: "u-cyan",
235
- onClick: D
236
- })]),
237
- _: 1
238
- })]),
239
- _: 1
240
- }, 8, ["data"])]),
241
- _: 1
242
- }, 8, ["modelValue"]), s(b, {
243
- modelValue: t.showUserRole,
244
- "onUpdate:modelValue": a[1] || (a[1] = (n) => t.showUserRole = n),
245
- loading: m.value,
246
- title: e.$t("message.title.roleInfo"),
247
- width: "600"
248
- }, {
249
- default: i(() => [s(Y, {
250
- height: "300",
251
- data: t.roleList,
252
- border: ""
253
- }, {
254
- default: i(() => [s(N, {
255
- type: "seq",
256
- width: "60"
257
- }), s(N, {
258
- field: "roleName",
259
- title: e.$t("message.udp.roleName")
260
- }, null, 8, ["title"]), s(N, {
261
- field: "roleDesc",
262
- title: e.$t("message.udp.roleDesc")
263
- }, null, 8, ["title"])]),
264
- _: 1
265
- }, 8, ["data"])]),
266
- _: 1
267
- }, 8, ["modelValue", "loading", "title"]), s(b, {
268
- modelValue: t.showAuth,
269
- "onUpdate:modelValue": a[2] || (a[2] = (n) => t.showAuth = n),
270
- loading: m.value,
271
- title: e.$t("message.title.authority", {
272
- role: t.record.name || "88888"
273
- }),
274
- height: "620",
275
- width: "560"
276
- }, {
277
- default: i(() => [s(j, {
278
- ref: "xTree",
279
- data: t.roleList,
280
- props: {
281
- children: "children",
282
- label: "menuName"
283
- },
284
- height: 560,
285
- "node-key": "id"
286
- }, null, 8, ["data"])]),
287
- _: 1
288
- }, 8, ["modelValue", "loading", "title"])]);
289
- };
290
- }
291
- });
292
- export {
293
- fe as _
294
- };
@@ -1,187 +0,0 @@
1
- import { defineComponent as U, ref as u, onMounted as F, resolveComponent as n, createElementBlock as j, openBlock as N, createVNode as t, withCtx as d, createElementVNode as w, createBlock as G, createCommentVNode as K, createTextVNode as P, toDisplayString as $ } from "vue";
2
- import { useI18n as Q } from "vue-i18n";
3
- import { t as I } from "./await-to-js.es5-BtRbN2QH.js";
4
- import { VxeUI as W } from "vxe-pc-ui";
5
- import { useRender as X, successMessage as k } from "@utogether/utils";
6
- import { q as b, e as S } from "./index-CKnq5xIa.js";
7
- const Y = { class: "u-dict-config_wrapper" }, Z = { style: { margin: "10px" } }, _ = "/upfm/v1/lov", de = /* @__PURE__ */ U({
8
- __name: "childView",
9
- props: {
10
- record: { default: () => ({}) },
11
- show: { type: Boolean, default: !1 }
12
- },
13
- emits: ["onClose"],
14
- setup(V, { emit: D }) {
15
- const v = V, T = X(), { t: q } = Q(), h = u([]), m = u(!1), s = u(!1), a = u({}), p = u({}), i = u("add"), O = [
16
- { field: "dictCode", title: "message.udp.dictCode", required: !0 },
17
- { field: "dictName", title: "message.udp.dictName", required: !0 },
18
- { field: "dictDesc", title: "message.remark" },
19
- {
20
- field: "enabled",
21
- itemRender: T.renderSwitch({ openValue: "1", closeValue: "0", defaultValue: "1" })
22
- // itemRender: renderHook.renderDict({ code: 'SU.ENABLE', defaultValue: '1' })
23
- // formatter: ['formatDict', 'SU.ENABLE']
24
- }
25
- ], R = () => {
26
- s.value = !0, i.value = "add", a.value = {
27
- dictCode: "",
28
- dictName: "",
29
- dictDesc: "",
30
- enabled: "1"
31
- }, p.value = v.record;
32
- }, x = (e) => {
33
- s.value = !0, i.value = "child", a.value = {
34
- dictCode: "",
35
- dictName: "",
36
- dictDesc: "",
37
- enabled: "1"
38
- }, p.value = JSON.parse(JSON.stringify(e));
39
- }, B = async (e) => {
40
- await W.modal.confirm(q("message.deleteRecord")) === "confirm" && (await b().delete(_, [e]), k(), f());
41
- }, J = async (e) => {
42
- s.value = !0, i.value = "edit", p.value = v.record, a.value = JSON.parse(JSON.stringify(e));
43
- }, z = async () => {
44
- const e = {
45
- ...a.value,
46
- orgId: S().getOrgId,
47
- organizationId: S().getOrganizationId,
48
- parentId: a.value.parentId || p.value.id
49
- };
50
- let o = "post";
51
- ["add", "child"].includes(i.value) ? o = "post" : o = "put", m.value = !0;
52
- const [r, y] = await I(b()[o](_, [e]));
53
- m.value = !1, r || (i.value === "edit" ? s.value = !1 : a.value = { enabled: "1" }, k(), f());
54
- }, f = async () => {
55
- const e = {
56
- parentId: v.record.id
57
- };
58
- m.value = !0;
59
- const [o, r] = await I(b().get(_ + "/children", e));
60
- m.value = !1, o || (h.value = r.list);
61
- }, A = D;
62
- function E() {
63
- A("onClose");
64
- }
65
- return F(() => {
66
- f();
67
- }), (e, o) => {
68
- const r = n("vxe-button"), y = n("vxe-toolbar"), c = n("vxe-table-column"), g = n("ut-button"), M = n("vxe-table"), H = n("ut-modal-form"), L = n("el-drawer");
69
- return N(), j("div", Y, [
70
- t(L, {
71
- "model-value": e.show,
72
- "before-close": E,
73
- title: e.$t("message.title.dictList", { name: e.record.dictName }),
74
- direction: "rtl",
75
- "destroy-on-close": "",
76
- size: "76%"
77
- }, {
78
- default: d(() => [
79
- w("div", Z, [
80
- t(y, null, {
81
- buttons: d(() => [
82
- t(r, {
83
- status: "primary",
84
- icon: "vxe-icon-add",
85
- onClick: R
86
- }, {
87
- default: d(() => [
88
- P($(e.$t("message.btn.add")), 1)
89
- ]),
90
- _: 1
91
- })
92
- ]),
93
- tools: d(() => [
94
- t(r, {
95
- icon: "vxe-icon-refresh",
96
- onClick: f
97
- })
98
- ]),
99
- _: 1
100
- }),
101
- t(M, {
102
- border: "",
103
- "row-id": "id",
104
- data: h.value,
105
- loading: m.value,
106
- "tree-config": { childrenField: "children", expandAll: !0 }
107
- }, {
108
- default: d(() => [
109
- t(c, {
110
- type: "seq",
111
- width: "130",
112
- title: e.$t("message.seqNo"),
113
- "tree-node": ""
114
- }, null, 8, ["title"]),
115
- t(c, {
116
- field: "dictCode",
117
- title: e.$t("message.udp.dictCode")
118
- }, null, 8, ["title"]),
119
- t(c, {
120
- field: "dictName",
121
- title: e.$t("message.udp.dictName")
122
- }, null, 8, ["title"]),
123
- t(c, {
124
- field: "dictDesc",
125
- title: e.$t("message.remark")
126
- }, null, 8, ["title"]),
127
- t(c, {
128
- field: "enabled",
129
- title: e.$t("message.enabled"),
130
- width: "100"
131
- }, {
132
- default: d(({ row: l }) => [
133
- w("span", null, $(l.enabled === "1" ? e.$t("message.enabled") : e.$t("message.disabled")), 1)
134
- ]),
135
- _: 1
136
- }, 8, ["title"]),
137
- t(c, {
138
- field: "",
139
- title: e.$t("message.operate"),
140
- width: "200"
141
- }, {
142
- default: d(({ row: l }) => [
143
- t(g, {
144
- status: "primary",
145
- content: "edit",
146
- onTap: (C) => J(l)
147
- }, null, 8, ["onTap"]),
148
- t(g, {
149
- status: "warning",
150
- content: "delete",
151
- onTap: (C) => B(l)
152
- }, null, 8, ["onTap"]),
153
- t(g, {
154
- status: "success",
155
- content: "add",
156
- disabled: l.enabled !== "1",
157
- onTap: (C) => x(l)
158
- }, null, 8, ["disabled", "onTap"])
159
- ]),
160
- _: 1
161
- }, 8, ["title"])
162
- ]),
163
- _: 1
164
- }, 8, ["data", "loading"])
165
- ]),
166
- s.value ? (N(), G(H, {
167
- key: 0,
168
- ref: "xmodal",
169
- record: a.value,
170
- items: O,
171
- width: "400",
172
- height: "280",
173
- "data-status": i.value,
174
- title: e.$t("message.title.dictInfo", { name: e.record.dictName }),
175
- onClose: o[0] || (o[0] = (l) => s.value = !1),
176
- onConfirm: z
177
- }, null, 8, ["record", "data-status", "title"])) : K("", !0)
178
- ]),
179
- _: 1
180
- }, 8, ["model-value", "title"])
181
- ]);
182
- };
183
- }
184
- });
185
- export {
186
- de as _
187
- };