@utogether/udp-core 2.0.0-beta.25 → 2.0.0-beta.27
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-gdcH0-Bo.js +65 -0
- package/dist/404-Se2SF97M.js +65 -0
- package/dist/500-B6j9AqLo.js +67 -0
- package/dist/AuthorityInfo-CQ8ydZvr.js +4 -0
- package/dist/AuthorityInfo.vue_vue_type_style_index_0_lang-C4NRvS8p.js +100 -0
- package/dist/AuthorityPanel-lVnZ5bce.js +4 -0
- package/dist/AuthorityPanel.vue_vue_type_style_index_0_lang-nsfhDlvV.js +113 -0
- package/dist/Company-BzSVBSC4.js +25 -0
- package/dist/CompanyPanel-DBjZB4aJ.js +204 -0
- package/dist/DataSet-iBHzs75s.js +147 -0
- package/dist/Department-BkgseHo8.js +25 -0
- package/dist/DepartmentPanel-Sen93_2M.js +249 -0
- package/dist/DesignPanel-pqDcwaFC.js +4 -0
- package/dist/DesignPanel.vue_vue_type_style_index_0_lang-BjtYyEw7.js +1013 -0
- package/dist/DictView-CJLG4LlE.js +110 -0
- package/dist/InvOrganization-D0Jq1IAa.js +74 -0
- package/dist/Org-CO_1WT39.js +39 -0
- package/dist/Preview-DLI4Bwel.js +48 -0
- package/dist/ReportDefine-Cw46OnJ_.js +10 -0
- package/dist/ReportDesign-D4sHTXT7.js +165 -0
- package/dist/ReportQuery-DtOCvQSN.js +74 -0
- package/dist/ReportQueryFrom-QjL-ETPq.js +4 -0
- package/dist/ReportQueryFrom.vue_vue_type_style_index_0_lang-Dj9ne87n.js +177 -0
- package/dist/ReportTemplate-BxAgc_Aj.js +161 -0
- package/dist/Role-Df77BBD-.js +25 -0
- package/dist/RoleAssign-BrunouML.js +26 -0
- package/dist/RolePanel-DSVwqhiD.js +4 -0
- package/dist/RolePanel-HLA7XBlN.js +4 -0
- package/dist/RolePanel.vue_vue_type_script_setup_true_lang-CKlbqRa5.js +132 -0
- package/dist/RolePanel.vue_vue_type_script_setup_true_lang-CN0rUxKz.js +152 -0
- package/dist/ScrollPanel.vue_vue_type_style_index_0_lang-D_FeSXKv.js +99 -0
- package/dist/Staff-BeL1xcRf.js +26 -0
- package/dist/StaffInfo-CIfnltyX.js +4 -0
- package/dist/StaffInfo.vue_vue_type_script_setup_true_lang-DbLFwWfG.js +107 -0
- package/dist/StaffPanel-BV2CHWac.js +4 -0
- package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-CvT-Vp2G.js +153 -0
- package/dist/SysUser-DPfNvthk.js +15 -0
- package/dist/SysUserPanel-CoLKYlQE.js +4 -0
- package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-lcO3Cjbq.js +353 -0
- package/dist/SystemMenu-sdj1dRDA.js +156 -0
- package/dist/UserInfo-CTX4hhFl.js +4 -0
- package/dist/UserInfo.vue_vue_type_style_index_0_lang-ClhCd_8z.js +160 -0
- package/dist/await-to-js.es5-Bv3Eu4mi.js +10 -0
- package/dist/childView-BDmWwJO5.js +4 -0
- package/dist/childView-Dx3ACtHa.js +4 -0
- package/dist/childView.vue_vue_type_style_index_0_lang-CfKq_0FN.js +183 -0
- package/dist/childView.vue_vue_type_style_index_0_lang-DxZNtkhd.js +143 -0
- package/dist/code-rule-cvN4gYC_.js +148 -0
- package/dist/core.es.js +24 -6
- package/dist/cron-task-B0TkxFdp.js +135 -0
- package/dist/flow-task-PoDnE_kE.js +10 -0
- package/dist/frameView-5cy5BSgS.js +43 -0
- package/dist/img/minicolors.png +0 -0
- package/dist/index-C5WRTwvI.js +3006 -0
- package/dist/layout-home-DrARg-3o.js +232 -0
- package/dist/layoutView-25v_ngk5.js +3191 -0
- package/dist/log-in-Bmz5Uhbt.js +116 -0
- package/dist/log-out-B-8m3oNj.js +130 -0
- package/dist/login-Cmp2RvvW.js +217 -0
- package/dist/login-log-CVvRgZSu.js +70 -0
- package/dist/lov-view-BATtzw2X.js +99 -0
- package/dist/menuInfo-BIvrE7nm.js +4 -0
- package/dist/menuInfo.vue_vue_type_style_index_0_lang-B6USomit.js +360 -0
- package/dist/pda-app-CzHVyeEa.js +707 -0
- package/dist/redirect-DTz8GSnv.js +15 -0
- package/dist/resource-Y5lGB38n.js +97 -0
- package/dist/su-welcome-CXA6OzBw.js +878 -0
- package/dist/sys-config-CqO03LeC.js +385 -0
- package/dist/udp-core.css +1 -2
- package/dist/useNav-C-rCgubt.js +84 -0
- package/dist/utogether-MlnyYtNS.js +4 -0
- package/dist/wecom-push-B75FLee5.js +70 -0
- package/index.ts +3 -2
- package/package.json +1 -1
- package/src/App.vue +79 -73
- package/src/api/index.ts +1 -1
- package/src/components/SuQrcode/src/index.tsx +231 -236
- package/src/components/udp/grid/index.vue +9 -11
- package/src/components/udp/utils.ts +420 -414
- package/src/layout/components/lay-panel/index.vue +2 -6
- package/src/layout/components/lay-search/components/SearchModal.vue +7 -3
- package/src/main.ts +111 -110
- package/src/router/index.ts +156 -187
- package/src/router/utils.ts +2 -3
- package/src/store/modules/system.ts +7 -0
- package/src/style/vxetable.scss +372 -364
- package/src/utils/authority/index.ts +46 -29
- package/src/utils/udp/http/index.ts +115 -64
- package/src/utils/udp/http/types.d.ts +15 -14
- package/src/views/login/login-view.vue +280 -301
- package/src/views/organization/department/DepartmentPanel.vue +3 -4
- package/src/views/system/sys/sys-config.vue +344 -344
- package/src/views/uhome/components/home-todo.vue +179 -178
- package/src/views/ulogin/login.vue +8 -41
- package/tsconfig.json +2 -3
- package/types/global.d.ts +234 -234
- package/vite.config.ts +2 -1
- package/dist/403-QwBKrRZE.js +0 -72
- package/dist/404-Cr7MbzNV.js +0 -72
- package/dist/500-B7kCOeIA.js +0 -77
- package/dist/AuthorityInfo-Dwml2K4S.js +0 -91
- package/dist/AuthorityPanel-DzPhsPpa.js +0 -98
- package/dist/Company-BhOlvl7Q.js +0 -21
- package/dist/CompanyPanel-ByhY5-Sq.js +0 -199
- package/dist/DataSet-CuGZcKC-.js +0 -141
- package/dist/Department-QvngN63N.js +0 -21
- package/dist/DepartmentPanel-BCXqC39J.js +0 -2
- package/dist/DepartmentPanel-DntGycxr.js +0 -242
- package/dist/DesignPanel-BMN4DZ0R.js +0 -1196
- package/dist/DictView-ERFqZ5VD.js +0 -100
- package/dist/File-WJXjGYxr.js +0 -89
- package/dist/InvOrganization-BwMmD8Ua.js +0 -76
- package/dist/Org-HgnOWubi.js +0 -76
- package/dist/Preview-CVZdnHB1.js +0 -45
- package/dist/ReIcon-DecitXmg.js +0 -413
- package/dist/ReportDefine-BgLM-Rjk.js +0 -10
- package/dist/ReportDesign-CjfTyyy_.js +0 -158
- package/dist/ReportQuery-CP-E0Puv.js +0 -101
- package/dist/ReportQueryFrom-D7SPPAps.js +0 -198
- package/dist/ReportTemplate-DE25zc1f.js +0 -162
- package/dist/Role-K7v_ZhFE.js +0 -21
- package/dist/RoleAssign-C16fjLaX.js +0 -22
- package/dist/RolePanel-CV-xPlYJ.js +0 -176
- package/dist/RolePanel-DPCe9k8f.js +0 -131
- package/dist/ScrollPanel-DW30pGz1.js +0 -88
- package/dist/Staff-w2ly4qd0.js +0 -22
- package/dist/StaffInfo-DPDRpz6F.js +0 -149
- package/dist/StaffPanel-DI1eTTp9.js +0 -143
- package/dist/SysUser-BMTX1cJM.js +0 -12
- package/dist/SysUserPanel-xwZdVjdp.js +0 -365
- package/dist/SystemMenu-TXhiQZVm.js +0 -154
- package/dist/UserInfo-JQqw8FMT.js +0 -194
- package/dist/_plugin-vue_export-helper-C6QCLu9I.js +0 -8
- package/dist/api-BFNxcxSN.js +0 -30
- package/dist/authority-Bi6BGB5B.js +0 -20
- package/dist/await-to-js.es5-DkWYmPXW.js +0 -10
- package/dist/childView-Bk8OD9bV.js +0 -181
- package/dist/childView-CyrcwshT.js +0 -184
- package/dist/code-rule-QFrhqFrW.js +0 -151
- package/dist/contant-Q77dU_V3.js +0 -4
- package/dist/cron-task-BpUDKEAU.js +0 -131
- package/dist/flow-task-DAc2NrDU.js +0 -11
- package/dist/frameView-Di0zJZUR.js +0 -39
- package/dist/layout-home-BVp7vYLR.js +0 -239
- package/dist/layoutView-DFUjrqAS.js +0 -2662
- package/dist/log-in-BrNB0mLz.js +0 -117
- package/dist/log-out-dYfqvzy6.js +0 -111
- package/dist/login-BdCDnuXL.js +0 -233
- package/dist/login-log-CJak-ANA.js +0 -79
- package/dist/lov-view-DkmG4K57.js +0 -95
- package/dist/menuInfo-kp2wNYOp.js +0 -346
- package/dist/mitt-CQgI7DYU.js +0 -27
- package/dist/pda-app-CA7YI37u.js +0 -589
- package/dist/redirect-N0k4tImU.js +0 -16
- package/dist/resource-CfQTHFcs.js +0 -94
- package/dist/router-CeluSGiD.js +0 -1531
- package/dist/su-welcome-JeiovGpe.js +0 -799
- package/dist/sys-config-Ddb3vBpK.js +0 -316
- package/dist/udp-core-Dhm-BlAs.js +0 -2032
- package/dist/useDataThemeChange-BCy8JBG7.js +0 -226
- package/dist/useNav-DY8FkltH.js +0 -106
- package/dist/utogether-l7JXs4Lv.js +0 -4
- package/dist/water-mark-WDQZ9YqB.js +0 -119
- package/dist/wecom-push-kWkAVRCj.js +0 -77
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { defineComponent as P, ref as k, inject as v, watch as E, nextTick as N, resolveComponent as p, openBlock as h, createElementBlock as D, withModifiers as O, createElementVNode as n, toDisplayString as C, createBlock as g, createCommentVNode as y, createVNode as x, withCtx as S, normalizeClass as V } from "vue";
|
|
2
|
+
import { n as j } from "./index-C5WRTwvI.js";
|
|
3
|
+
const M = { class: "u-panel-header" }, $ = { class: "u-panel-content system-scrollbar" }, K = /* @__PURE__ */ P({
|
|
4
|
+
__name: "ScrollPanel",
|
|
5
|
+
props: {
|
|
6
|
+
title: {},
|
|
7
|
+
url: {},
|
|
8
|
+
showAllButton: { type: Boolean, default: !1 },
|
|
9
|
+
initLoadAll: { type: Boolean, default: !1 },
|
|
10
|
+
treeOtions: { default: () => ({
|
|
11
|
+
children: "children",
|
|
12
|
+
label: "label"
|
|
13
|
+
}) },
|
|
14
|
+
defaultParams: { default: () => ({}) }
|
|
15
|
+
},
|
|
16
|
+
setup(a, { expose: b }) {
|
|
17
|
+
const c = a, s = k([]), r = k(null), o = v("active"), u = v("scrollPanelChange"), B = v("treeList");
|
|
18
|
+
E(
|
|
19
|
+
() => u.value,
|
|
20
|
+
() => {
|
|
21
|
+
u.value && d();
|
|
22
|
+
}
|
|
23
|
+
);
|
|
24
|
+
const d = async (l = {}) => {
|
|
25
|
+
const t = Object.assign(l, c.defaultParams), e = await j().get(c.url, t);
|
|
26
|
+
s.value = e.list || e, B.value = e.list || e, c.initLoadAll ? o.value = {} : o.value = e.list ? e.list[0] : e[0], N(() => {
|
|
27
|
+
r.value && r?.value.setCurrentKey(o.value?.id || "");
|
|
28
|
+
}), u.value = !1;
|
|
29
|
+
}, w = (l) => {
|
|
30
|
+
o.value = l;
|
|
31
|
+
}, _ = () => {
|
|
32
|
+
o.value = {};
|
|
33
|
+
}, f = (l, t) => {
|
|
34
|
+
l.forEach((e) => {
|
|
35
|
+
r.value.store.nodesMap[e.id].expanded = t, e.children?.length && f(e.children, t);
|
|
36
|
+
});
|
|
37
|
+
}, m = () => {
|
|
38
|
+
d();
|
|
39
|
+
};
|
|
40
|
+
return b({
|
|
41
|
+
onRefresh: m
|
|
42
|
+
}), d(), (l, t) => {
|
|
43
|
+
const e = p("ut-button"), A = p("vxe-button"), L = p("el-tree");
|
|
44
|
+
return h(), D("div", {
|
|
45
|
+
class: "u-scroll-panel",
|
|
46
|
+
onClick: O(_, ["prevent"])
|
|
47
|
+
}, [
|
|
48
|
+
n("div", M, [
|
|
49
|
+
n("h2", null, C(a.title), 1),
|
|
50
|
+
a.showAllButton ? (h(), g(e, {
|
|
51
|
+
key: 0,
|
|
52
|
+
content: "BtnExpand",
|
|
53
|
+
onClick: t[0] || (t[0] = (i) => f(s.value, !0))
|
|
54
|
+
})) : y("", !0),
|
|
55
|
+
a.showAllButton ? (h(), g(e, {
|
|
56
|
+
key: 1,
|
|
57
|
+
status: "warning",
|
|
58
|
+
content: "BtnCollapse",
|
|
59
|
+
onClick: t[1] || (t[1] = (i) => f(s.value, !1))
|
|
60
|
+
})) : y("", !0),
|
|
61
|
+
x(A, {
|
|
62
|
+
icon: "vxe-icon-refresh",
|
|
63
|
+
onClick: m
|
|
64
|
+
})
|
|
65
|
+
]),
|
|
66
|
+
n("div", $, [
|
|
67
|
+
x(L, {
|
|
68
|
+
ref_key: "tree",
|
|
69
|
+
ref: r,
|
|
70
|
+
data: s.value,
|
|
71
|
+
props: a.treeOtions,
|
|
72
|
+
"expand-on-click-node": !1,
|
|
73
|
+
style: { "background-color": "#fff" },
|
|
74
|
+
class: "u-tree-panel",
|
|
75
|
+
"node-key": "id",
|
|
76
|
+
"highlight-current": "",
|
|
77
|
+
onNodeClick: w
|
|
78
|
+
}, {
|
|
79
|
+
default: S(({ node: i }) => [
|
|
80
|
+
n("span", {
|
|
81
|
+
class: V(["prefix", { "is-leaf": i.isLeaf }])
|
|
82
|
+
}, [...t[2] || (t[2] = [
|
|
83
|
+
n("i", {
|
|
84
|
+
class: "ri-folder-2-fill ri-lg mr-1",
|
|
85
|
+
style: { color: "#fadb14" }
|
|
86
|
+
}, null, -1)
|
|
87
|
+
])], 2),
|
|
88
|
+
n("span", null, C(i.label), 1)
|
|
89
|
+
]),
|
|
90
|
+
_: 1
|
|
91
|
+
}, 8, ["data", "props"])
|
|
92
|
+
])
|
|
93
|
+
]);
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
});
|
|
97
|
+
export {
|
|
98
|
+
K as _
|
|
99
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { defineComponent as l, ref as e, provide as t, openBlock as i, createElementBlock as _, createElementVNode as n, createVNode as o } from "vue";
|
|
2
|
+
import { _ as d } from "./ScrollPanel.vue_vue_type_style_index_0_lang-D_FeSXKv.js";
|
|
3
|
+
import { _ as f } from "./StaffPanel.vue_vue_type_script_setup_true_lang-CvT-Vp2G.js";
|
|
4
|
+
import { _ as m } from "./index-C5WRTwvI.js";
|
|
5
|
+
const p = { class: "u-content-panel" }, u = { class: "u-left-panel" }, h = { class: "content" }, v = { name: "StaffPanel" }, C = /* @__PURE__ */ l({
|
|
6
|
+
...v,
|
|
7
|
+
setup(N) {
|
|
8
|
+
const a = e(!1), s = e([]), c = e({});
|
|
9
|
+
return t("scrollPanelChange", a), t("active", c), t("treeList", s), (r, P) => (i(), _("div", p, [
|
|
10
|
+
n("div", u, [
|
|
11
|
+
o(d, {
|
|
12
|
+
title: r.$t("department"),
|
|
13
|
+
"init-load-all": !0,
|
|
14
|
+
"tree-otions": { children: "children", label: "deptName" },
|
|
15
|
+
url: "/uums/department/treeDepartment"
|
|
16
|
+
}, null, 8, ["title"])
|
|
17
|
+
]),
|
|
18
|
+
n("div", h, [
|
|
19
|
+
o(f)
|
|
20
|
+
])
|
|
21
|
+
]));
|
|
22
|
+
}
|
|
23
|
+
}), B = /* @__PURE__ */ m(C, [["__scopeId", "data-v-1cfe93f2"]]);
|
|
24
|
+
export {
|
|
25
|
+
B as default
|
|
26
|
+
};
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { defineComponent as b, ref as l, onMounted as D, resolveComponent as o, openBlock as E, createElementBlock as k, createVNode as n, withCtx as c } from "vue";
|
|
2
|
+
import { useRender as x } from "@utogether/utils";
|
|
3
|
+
import { n as f } from "./index-C5WRTwvI.js";
|
|
4
|
+
const F = { class: "config" }, B = /* @__PURE__ */ b({
|
|
5
|
+
__name: "StaffInfo",
|
|
6
|
+
props: {
|
|
7
|
+
show: { type: Boolean, default: !0 },
|
|
8
|
+
record: { default: () => ({}) },
|
|
9
|
+
dataStatus: { default: "detail" }
|
|
10
|
+
},
|
|
11
|
+
emits: ["onClose"],
|
|
12
|
+
setup(d, { emit: _ }) {
|
|
13
|
+
const a = d, t = x(), r = l({}), m = l(null), s = l(!1), v = { userName: "userName", userId: "id" }, y = { disabled: a.dataStatus !== "add" }, R = [
|
|
14
|
+
{
|
|
15
|
+
field: "employeeCode",
|
|
16
|
+
required: !0,
|
|
17
|
+
span: 8,
|
|
18
|
+
itemRender: t.renderInput({ props: y })
|
|
19
|
+
},
|
|
20
|
+
{ field: "employeeName", required: !0, span: 8, itemRender: t.renderInput() },
|
|
21
|
+
{ field: "gender", span: 8, itemRender: t.renderDict("SU.GENDER") },
|
|
22
|
+
{
|
|
23
|
+
field: "deptName",
|
|
24
|
+
required: !0,
|
|
25
|
+
span: 8,
|
|
26
|
+
itemRender: t.renderLov({ code: "SU.DEPARTMENT", field: "deptName" }, w)
|
|
27
|
+
},
|
|
28
|
+
{ field: "email", span: 8, itemRender: t.renderInput() },
|
|
29
|
+
{ field: "identity", span: 8, itemRender: t.renderInput() },
|
|
30
|
+
{ field: "employeeDate", span: 8, itemRender: t.renderDate() },
|
|
31
|
+
{ field: "solarDay", span: 8, itemRender: t.renderDate() },
|
|
32
|
+
{ field: "phone", span: 8, itemRender: t.renderInput() },
|
|
33
|
+
{ field: "mobile", span: 8, itemRender: t.renderInput() },
|
|
34
|
+
{
|
|
35
|
+
field: "userName",
|
|
36
|
+
title: "message.releateUser",
|
|
37
|
+
span: 8,
|
|
38
|
+
itemRender: t.renderSysUser({ mapField: v })
|
|
39
|
+
}
|
|
40
|
+
];
|
|
41
|
+
function w(e) {
|
|
42
|
+
e.row.deptName = e.item?.deptName || e.row.deptName, e.row.deptCode = e.item?.deptCode || e.row.deptCode, e.row.departmentId = e.item?.id || e.row.departmentId;
|
|
43
|
+
}
|
|
44
|
+
const N = _, g = () => {
|
|
45
|
+
m.value.validateForm(async (e) => {
|
|
46
|
+
if (!e) {
|
|
47
|
+
const { dataStatus: u } = a;
|
|
48
|
+
s.value = !0, u === "add" ? await f().post("/uums/employee", r.value) : await f().put("/uums/employee", r.value), s.value = !1, i();
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
function i() {
|
|
53
|
+
N("onClose");
|
|
54
|
+
}
|
|
55
|
+
return D(() => {
|
|
56
|
+
r.value = a.record;
|
|
57
|
+
}), (e, u) => {
|
|
58
|
+
const C = o("ut-form"), I = o("el-divider"), p = o("ut-button"), S = o("el-row"), h = o("el-drawer");
|
|
59
|
+
return E(), k("div", F, [
|
|
60
|
+
n(h, {
|
|
61
|
+
"model-value": d.show,
|
|
62
|
+
"before-close": i,
|
|
63
|
+
direction: "rtl",
|
|
64
|
+
title: e.$t("message.title.employeeInfo"),
|
|
65
|
+
"destroy-on-close": "",
|
|
66
|
+
size: "66%"
|
|
67
|
+
}, {
|
|
68
|
+
default: c(() => [
|
|
69
|
+
n(C, {
|
|
70
|
+
ref_key: "suFormRef",
|
|
71
|
+
ref: m,
|
|
72
|
+
record: r.value,
|
|
73
|
+
loading: s.value,
|
|
74
|
+
items: R,
|
|
75
|
+
"data-status": d.dataStatus
|
|
76
|
+
}, null, 8, ["record", "loading", "data-status"]),
|
|
77
|
+
n(I),
|
|
78
|
+
n(S, {
|
|
79
|
+
type: "flex",
|
|
80
|
+
justify: "end",
|
|
81
|
+
style: { "padding-right": "22px" }
|
|
82
|
+
}, {
|
|
83
|
+
default: c(() => [
|
|
84
|
+
n(p, {
|
|
85
|
+
content: "cancel",
|
|
86
|
+
icon: "ri-close-fill",
|
|
87
|
+
onTap: i
|
|
88
|
+
}),
|
|
89
|
+
n(p, {
|
|
90
|
+
content: "confirm",
|
|
91
|
+
icon: "ri-save-3-fill",
|
|
92
|
+
status: "u-cyan",
|
|
93
|
+
onTap: g
|
|
94
|
+
})
|
|
95
|
+
]),
|
|
96
|
+
_: 1
|
|
97
|
+
})
|
|
98
|
+
]),
|
|
99
|
+
_: 1
|
|
100
|
+
}, 8, ["model-value", "title"])
|
|
101
|
+
]);
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
export {
|
|
106
|
+
B as _
|
|
107
|
+
};
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { defineComponent as C, ref as N, inject as B, reactive as D, watch as V, nextTick as L, resolveComponent as c, openBlock as i, createElementBlock as U, createVNode as s, createBlock as M, createCommentVNode as I, Fragment as A } from "vue";
|
|
2
|
+
import { useI18n as P } from "vue-i18n";
|
|
3
|
+
import { clone as R } from "xe-utils";
|
|
4
|
+
import { warnMessage as T } from "@utogether/utils";
|
|
5
|
+
import { _ as Y } from "./StaffInfo.vue_vue_type_script_setup_true_lang-DbLFwWfG.js";
|
|
6
|
+
import { n as d } from "./index-C5WRTwvI.js";
|
|
7
|
+
import { VxeUI as O } from "vxe-pc-ui";
|
|
8
|
+
import { t as l } from "./await-to-js.es5-Bv3Eu4mi.js";
|
|
9
|
+
const j = {
|
|
10
|
+
class: "page-content"
|
|
11
|
+
}, u = "/uums/employee", W = /* @__PURE__ */ C({
|
|
12
|
+
__name: "StaffPanel",
|
|
13
|
+
setup(q) {
|
|
14
|
+
const a = N(null), {
|
|
15
|
+
t: m
|
|
16
|
+
} = P(), o = B("active"), t = D({
|
|
17
|
+
record: {},
|
|
18
|
+
showModelView: !1,
|
|
19
|
+
fetchExtParam: {}
|
|
20
|
+
});
|
|
21
|
+
V(() => o.value, (e) => {
|
|
22
|
+
t.fetchExtParam = {
|
|
23
|
+
departmentId: e?.id
|
|
24
|
+
}, L(() => {
|
|
25
|
+
a.value.refreshData();
|
|
26
|
+
});
|
|
27
|
+
});
|
|
28
|
+
const f = [{
|
|
29
|
+
code: "sync",
|
|
30
|
+
auth: "wechat",
|
|
31
|
+
status: "success",
|
|
32
|
+
icon: "ri-refresh-line"
|
|
33
|
+
}, {
|
|
34
|
+
code: "sync",
|
|
35
|
+
auth: "dingding",
|
|
36
|
+
status: "success",
|
|
37
|
+
icon: "ri-refresh-line"
|
|
38
|
+
}, {
|
|
39
|
+
code: "sync",
|
|
40
|
+
auth: "OA",
|
|
41
|
+
status: "success",
|
|
42
|
+
icon: "ri-refresh-line"
|
|
43
|
+
}, {
|
|
44
|
+
code: "bindUser",
|
|
45
|
+
auth: "bind",
|
|
46
|
+
status: "warning",
|
|
47
|
+
icon: "ri-bring-to-front"
|
|
48
|
+
}, {
|
|
49
|
+
code: "del",
|
|
50
|
+
auth: "/"
|
|
51
|
+
}], p = [{
|
|
52
|
+
field: "employeeCode"
|
|
53
|
+
}, {
|
|
54
|
+
field: "employeeName"
|
|
55
|
+
}], h = [{
|
|
56
|
+
type: "checkbox",
|
|
57
|
+
width: 50,
|
|
58
|
+
align: "center"
|
|
59
|
+
}, {
|
|
60
|
+
field: "employeeCode"
|
|
61
|
+
}, {
|
|
62
|
+
field: "employeeName",
|
|
63
|
+
width: 150
|
|
64
|
+
}, {
|
|
65
|
+
field: "gender",
|
|
66
|
+
width: 100,
|
|
67
|
+
formatter: ["formatDict", "SU.GENDER"]
|
|
68
|
+
}, {
|
|
69
|
+
field: "enabled",
|
|
70
|
+
width: 100,
|
|
71
|
+
formatter: ["formatDict", "SU.ENABLE"]
|
|
72
|
+
}, {
|
|
73
|
+
field: "operate",
|
|
74
|
+
width: 150,
|
|
75
|
+
fixed: "right",
|
|
76
|
+
slots: {
|
|
77
|
+
default: ({
|
|
78
|
+
row: e
|
|
79
|
+
}) => {
|
|
80
|
+
const n = ["1", "Y"].includes(e.enabled) ? "disabled" : "enable", r = ["1", "Y"].includes(e.enabled) ? "ri-stop-circle-fill" : "ri-play-circle-fill", S = ["1", "Y"].includes(e.enabled) ? "warning" : "success";
|
|
81
|
+
return [s(A, null, [s(c("ut-button"), {
|
|
82
|
+
icon: "ri-edit-box-line",
|
|
83
|
+
content: "edit",
|
|
84
|
+
onTap: () => b(e)
|
|
85
|
+
}, null), s(c("ut-button"), {
|
|
86
|
+
icon: r,
|
|
87
|
+
content: n,
|
|
88
|
+
status: S,
|
|
89
|
+
onTap: () => v(e)
|
|
90
|
+
}, null)])];
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}], g = {
|
|
94
|
+
toolbarButtonClick({
|
|
95
|
+
code: e
|
|
96
|
+
}) {
|
|
97
|
+
e === "add" && y();
|
|
98
|
+
}
|
|
99
|
+
}, y = () => {
|
|
100
|
+
if (!o.value?.deptName)
|
|
101
|
+
return T("请先选择部门");
|
|
102
|
+
t.dataStatus = "add", t.record = {}, t.record.departmentId = o.value?.id, t.record.deptName = o.value.deptName, t.record.enabled = "1", t.showModelView = !0;
|
|
103
|
+
}, b = (e) => {
|
|
104
|
+
t.dataStatus = "update", t.record = e, t.showModelView = !0;
|
|
105
|
+
}, v = async (e) => {
|
|
106
|
+
const n = R(e, !0);
|
|
107
|
+
a.value.showLoading(), n.enabled = n.enabled === "1" ? "0" : "1", await d().put(u, n), a.value.hiddenLoading(), a.value.refreshData();
|
|
108
|
+
}, w = async () => {
|
|
109
|
+
if (await O.modal.confirm(m("message.tip.confirmSync")) !== "confirm") return;
|
|
110
|
+
a.value.showLoading();
|
|
111
|
+
const [n] = await l(d().post("/uums/employee/syncEwEmp", {}));
|
|
112
|
+
a.value.hiddenLoading(), !n && a.value.refreshData();
|
|
113
|
+
}, _ = async () => {
|
|
114
|
+
const e = a.value.getSelectRecords();
|
|
115
|
+
if (!e.length) return;
|
|
116
|
+
a.value.showLoading();
|
|
117
|
+
const [n] = await l(d().post("/uums/employee/bindUser", e));
|
|
118
|
+
a.value.hiddenLoading(), !n && a.value.refreshData();
|
|
119
|
+
}, k = (e) => {
|
|
120
|
+
e === "sync" && w(), e === "bindUser" && _();
|
|
121
|
+
}, x = {
|
|
122
|
+
querySuccess: (e) => {
|
|
123
|
+
}
|
|
124
|
+
}, E = () => {
|
|
125
|
+
t.showModelView = !1, a.value.refreshData();
|
|
126
|
+
};
|
|
127
|
+
return (e, n) => {
|
|
128
|
+
const r = c("ut-grid");
|
|
129
|
+
return i(), U("div", j, [s(r, {
|
|
130
|
+
ref_key: "xgrid",
|
|
131
|
+
ref: a,
|
|
132
|
+
items: p,
|
|
133
|
+
columns: h,
|
|
134
|
+
"default-params": t.fetchExtParam,
|
|
135
|
+
events: g,
|
|
136
|
+
"auto-load": !1,
|
|
137
|
+
buttons: f,
|
|
138
|
+
url: u,
|
|
139
|
+
callback: x,
|
|
140
|
+
mode: "form",
|
|
141
|
+
onButtonClick: k
|
|
142
|
+
}, null, 8, ["default-params"]), t.showModelView ? (i(), M(Y, {
|
|
143
|
+
key: 0,
|
|
144
|
+
record: t.record,
|
|
145
|
+
"data-status": t.dataStatus,
|
|
146
|
+
onOnClose: E
|
|
147
|
+
}, null, 8, ["record", "data-status"])) : I("", !0)]);
|
|
148
|
+
};
|
|
149
|
+
}
|
|
150
|
+
});
|
|
151
|
+
export {
|
|
152
|
+
W as _
|
|
153
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { defineComponent as t, ref as o, provide as s, openBlock as r, createElementBlock as c, createVNode as _ } from "vue";
|
|
2
|
+
import { _ as n } from "./SysUserPanel.vue_vue_type_script_setup_true_lang-lcO3Cjbq.js";
|
|
3
|
+
import { _ as a } from "./index-C5WRTwvI.js";
|
|
4
|
+
const p = { class: "u-content-panel1" }, i = /* @__PURE__ */ t({
|
|
5
|
+
__name: "SysUser",
|
|
6
|
+
setup(m) {
|
|
7
|
+
const e = o([]);
|
|
8
|
+
return s("treeList", e), (f, d) => (r(), c("div", p, [
|
|
9
|
+
_(n)
|
|
10
|
+
]));
|
|
11
|
+
}
|
|
12
|
+
}), x = /* @__PURE__ */ a(i, [["__scopeId", "data-v-8708bc91"]]);
|
|
13
|
+
export {
|
|
14
|
+
x as default
|
|
15
|
+
};
|