@baishuyun/ui-business 5.0.4 → 5.1.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.
- package/dist/BubbleChart/{BubbleChart-CPhXmstL.js → BubbleChart-BPIsaE-C.js} +1 -1
- package/dist/BubbleChart/index.js +2 -2
- package/dist/ConfigProvider/{ConfigProvider-CISBH3A8.js → ConfigProvider-C0c1mKeR.js} +1 -1
- package/dist/ConfigProvider/index.js +2 -2
- package/dist/DeptsMemberSelector/Department-CkzkA99U.js +252 -0
- package/dist/DeptsMemberSelector/DeptsMemberSelector-pLcrkrr2.js +1058 -0
- package/dist/DeptsMemberSelector/DeptsUser-C7_gkn3k.js +366 -0
- package/dist/DeptsMemberSelector/ExtraConcactPanel-BRkvxzbe.js +934 -0
- package/dist/DeptsMemberSelector/Member-CXVybdp_.js +64 -0
- package/dist/DeptsMemberSelector/OrganizationPanel-BAhvhgOL.js +374 -0
- package/dist/DeptsMemberSelector/RelationShipDepts-DadyalUU.js +55 -0
- package/dist/DeptsMemberSelector/RelationShipList-BVTUyw1-.js +52 -0
- package/dist/{DeptsMember/TabGroup-B_VIf1lS.js → DeptsMemberSelector/TabGroup-DjfuvblW.js} +1 -1
- package/dist/DeptsMemberSelector/index.d.ts +6 -0
- package/dist/DeptsMemberSelector/index.js +18 -0
- package/dist/DeptsMemberSelector/services/contact/selector.service-cz8fZZaA.js +340 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/Department/index.d.ts +2 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/Department/index.js +8 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/DeptsUser/index.d.ts +2 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/DeptsUser/index.js +11 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/Member/index.d.ts +2 -0
- package/dist/DeptsMemberSelector/subcomponents/Entity/Member/index.js +8 -0
- package/dist/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.d.ts +4 -0
- package/dist/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.js +6 -0
- package/dist/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/index.d.ts +4 -0
- package/dist/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/index.js +4 -0
- package/dist/DeptsMemberSelector/useDeptsMemberSelector-xc9GWJaL.js +123 -0
- package/dist/DeptsMemberSelector/utils/index.d.ts +2 -0
- package/dist/{DeptsMember → DeptsMemberSelector}/utils/index.js +18 -10
- package/dist/Scatterplot/{Scatterplot-DTKhmdTE.js → Scatterplot-C1XSsAKR.js} +1 -1
- package/dist/Scatterplot/index.js +2 -2
- package/dist/components/{DeptsMember/DeptsMember.d.ts → DeptsMemberSelector/DeptsMemberSelector.d.ts} +1 -1
- package/dist/components/DeptsMemberSelector/DeptsMemberSelector.type.d.ts +1 -0
- package/dist/components/DeptsMemberSelector/context/DeptsMemberContext.d.ts +27 -0
- package/dist/components/DeptsMemberSelector/hooks/useDeptRelyLimit.d.ts +12 -0
- package/dist/components/DeptsMemberSelector/hooks/useDeptsMemberSelector.d.ts +19 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/index.d.ts +2 -2
- package/dist/components/{DeptsMember → DeptsMemberSelector}/reducers/deptsMemberReducer.d.ts +1 -1
- package/dist/components/DeptsMemberSelector/subcomponents/Entity/Department/DepartmentSearch/useDepartmentSearchData.d.ts +18 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Department/GroupList/GroupList.d.ts +1 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Entity/Member/MemberSearch/useMemberSearchData.d.ts +17 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/ExtraConcactPanel/useExtraContactPanelData.d.ts +18 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/MemberPanel/useMemberPanelData.d.ts +24 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.d.ts +2 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/index.d.ts +6 -2
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberRelationShipPanel/RelationShipMember/RelationShipMember.d.ts +3 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/types.d.ts +17 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/MemberRelationShipPanel/useMemberRelationShipPanelData.d.ts +42 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/OrganizationPanel/ExternalOrganization/ExternalOrganization.d.ts +2 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/OrganizationPanel/InternalOrganization/InternalOrganization.d.ts +1 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/OrganizationPanel/useDepartmentExpandState.d.ts +14 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/OrganizationPanel/useOrganizationPanelData.d.ts +36 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/OrganizationPanel/utils/departmentExpandState.d.ts +30 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/OrganizationPanel/utils/filterTreeByType.d.ts +2 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/PositionPanel/usePositionPanelData.d.ts +16 -0
- package/dist/components/DeptsMemberSelector/subcomponents/Panels/RolePanel/useRolePanelData.d.ts +18 -0
- package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionTabs/useSelectorType.d.ts +1 -1
- package/dist/components/DeptsMemberSelector/types/context.d.ts +36 -0
- package/dist/components/DeptsMemberSelector/types/selector.d.ts +164 -0
- package/dist/components/DeptsMemberSelector/utils/departmentPanelRequestGuard.d.ts +16 -0
- package/dist/components/DeptsMemberSelector/utils/departmentPanelVisibility.d.ts +11 -0
- package/dist/components/DeptsMemberSelector/utils/memberPanelRequestGuard.d.ts +3 -0
- package/dist/components/DeptsMemberSelector/utils/relyLimit.d.ts +15 -0
- package/dist/components/DeptsMemberSelector/utils/requestContext.d.ts +18 -0
- package/dist/components/DeptsMemberSelector/utils/selectorRequestInput.d.ts +12 -0
- package/dist/components/DeptsMemberSelector/utils/widgetDepartmentRange.d.ts +7 -0
- package/dist/components/DeptsMemberSelector/utils/widgetPanelVisibility.d.ts +4 -0
- package/dist/components/DeptsMemberSelector/utils/widgetRequestLimits.d.ts +19 -0
- package/dist/components/index.d.ts +1 -1
- package/dist/index.css +1 -1
- package/dist/index.js +15 -15
- package/dist/lang/en-US.json.d.ts +2 -1
- package/dist/lang/zh-CN.json.d.ts +2 -1
- package/dist/services/apiService.d.ts +3 -0
- package/dist/services/contact/path.d.ts +4 -0
- package/dist/services/contact/selector.service.d.ts +149 -0
- package/dist/services/contact/unwrap.d.ts +2 -0
- package/dist/vendors/lodash-es.js +431 -37
- package/dist/vendors/services/contact/path.js +17 -0
- package/dist/vendors/simplebar-react.js +1 -1
- package/dist/vendors/useLocale.js +5 -3
- package/package.json +11 -5
- package/dist/DeptsMember/Department-BYVAaPYd.js +0 -186
- package/dist/DeptsMember/DeptsMember-D_xv-Zy7.js +0 -801
- package/dist/DeptsMember/DeptsUser-CQrRRJxk.js +0 -277
- package/dist/DeptsMember/ExtraConcactPanel-Cioew3V3.js +0 -736
- package/dist/DeptsMember/Member-BIBX5jKD.js +0 -47
- package/dist/DeptsMember/OrganizationPanel-BLIXOm6z.js +0 -235
- package/dist/DeptsMember/RelationShipDepts-wcYjFbhx.js +0 -78
- package/dist/DeptsMember/RelationShipList-CRdCr4NL.js +0 -73
- package/dist/DeptsMember/index.d.ts +0 -6
- package/dist/DeptsMember/index.js +0 -18
- package/dist/DeptsMember/subcomponents/Entity/Department/index.d.ts +0 -2
- package/dist/DeptsMember/subcomponents/Entity/Department/index.js +0 -8
- package/dist/DeptsMember/subcomponents/Entity/DeptsUser/index.d.ts +0 -2
- package/dist/DeptsMember/subcomponents/Entity/DeptsUser/index.js +0 -11
- package/dist/DeptsMember/subcomponents/Entity/Member/index.d.ts +0 -2
- package/dist/DeptsMember/subcomponents/Entity/Member/index.js +0 -8
- package/dist/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.d.ts +0 -4
- package/dist/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.js +0 -6
- package/dist/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/index.d.ts +0 -4
- package/dist/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/index.js +0 -4
- package/dist/DeptsMember/useDeptsMemberSelector-DP5L8bhi.js +0 -15
- package/dist/DeptsMember/utils/index.d.ts +0 -2
- package/dist/components/DeptsMember/DeptsMember.type.d.ts +0 -48
- package/dist/components/DeptsMember/context/DeptsMemberContext.d.ts +0 -45
- package/dist/components/DeptsMember/hooks/useDeptsMemberSelector.d.ts +0 -12
- package/dist/services/data/department.service.d.ts +0 -12
- package/dist/services/data/member.service.d.ts +0 -19
- package/dist/services/data/member_limit.service.d.ts +0 -5
- package/dist/services/data/outsider.service.d.ts +0 -11
- package/dist/services/ncorp/department.service.d.ts +0 -11
- package/dist/services/ncorp/relation.service.d.ts +0 -4
- package/dist/vendors/services/corp/outsider.service.js +0 -5
- package/dist/vendors/services/data/department.service.js +0 -5
- package/dist/vendors/services/data/member.service.js +0 -5
- package/dist/vendors/services/data/member_limit.service.js +0 -5
- package/dist/vendors/services/data/outsider.service.js +0 -5
- package/dist/vendors/services/ncorp/department.service.js +0 -5
- package/dist/vendors/services/ncorp/relation.service.js +0 -5
- /package/dist/BubbleChart/{AutoGridEChart-uinZMdOR.js → AutoGridEChart-B2a7zGgi.js} +0 -0
- /package/dist/ConfigProvider/{configContext-B0kvcW4s.js → configContext-kYu9qTM2.js} +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Department/DepartmentSearch/DepartmentSearch.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Department/index.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/DeptsUser/index.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Member/MemberSearch/MemberSearch.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Member/MemerList/MemberList.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Entity/Member/index.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/CurrentUserDeptsPanel/CurrentUserDeptsPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/CurrentUserPanel/CurrentUserPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/ExtraConcactPanel/ExtraConcactPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/ExtraContactGroupPanel/ExtraContactGroupPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberPanel/AllMemeberCheck/AllMemeberCheck.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberPanel/ExternalMember/ExternalMember.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberPanel/InternalMemeber/InternalMemeber.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberPanel/MemberPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/MemberRelationShipPanel/MemberRelationShip.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/OrganizationPanel/OrganizationPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/OtherPanel/OtherPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/PositionPanel/PositionPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/Panels/RolePanel/RolePanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionArea/PreviewSelectedItems/PreviewSelectedItems.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionArea/SelectionArea.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionTabs/SelectionTabList/SelectionTabList.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionTabs/SelectionTabPanel/SelectionTabPanel.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/SelectionTabs/SelectionTabs.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/TabGroup/TabGroup.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/subcomponents/TagIcon/TagIcon.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/utils/constants.d.ts +0 -0
- /package/dist/components/{DeptsMember → DeptsMemberSelector}/utils/index.d.ts +0 -0
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./useDeptsMemberSelector-DP5L8bhi.js";
|
|
2
|
-
import { t } from "../vendors/useLocale.js";
|
|
3
|
-
import { a as n, i as r, n as i, r as a, t as o } from "./ExtraConcactPanel-Cioew3V3.js";
|
|
4
|
-
import { useMemo as s } from "react";
|
|
5
|
-
import { jsx as c } from "react/jsx-runtime";
|
|
6
|
-
//#region src/components/DeptsMember/subcomponents/Panels/CurrentUserPanel/CurrentUserPanel.module.scss
|
|
7
|
-
var l = { "current-user-panel": "_current-user-panel_184e6_1" }, u = () => {
|
|
8
|
-
let { currentUser: t } = e();
|
|
9
|
-
return /* @__PURE__ */ c("div", {
|
|
10
|
-
className: l["current-user-panel"],
|
|
11
|
-
children: /* @__PURE__ */ c(n, {
|
|
12
|
-
list: t ? [t] : [],
|
|
13
|
-
showCheckAll: !1
|
|
14
|
-
})
|
|
15
|
-
});
|
|
16
|
-
}, d = () => {
|
|
17
|
-
let { t: e } = t();
|
|
18
|
-
return s(() => [
|
|
19
|
-
{
|
|
20
|
-
label: e("member.title"),
|
|
21
|
-
key: "member",
|
|
22
|
-
view: /* @__PURE__ */ c(r, {})
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
label: e("role.title"),
|
|
26
|
-
key: "role",
|
|
27
|
-
view: /* @__PURE__ */ c(i, {})
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
label: e("position.title"),
|
|
31
|
-
key: "job",
|
|
32
|
-
view: /* @__PURE__ */ c(a, {})
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
label: e("externalContact.title"),
|
|
36
|
-
key: "externalContact",
|
|
37
|
-
view: /* @__PURE__ */ c(o, {})
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
label: e("currentUser.title"),
|
|
41
|
-
key: "currentUser",
|
|
42
|
-
view: /* @__PURE__ */ c(u, {})
|
|
43
|
-
}
|
|
44
|
-
], [e]);
|
|
45
|
-
};
|
|
46
|
-
//#endregion
|
|
47
|
-
export { d as t };
|
|
@@ -1,235 +0,0 @@
|
|
|
1
|
-
import { t as e } from "../vendors/simplebar-react.js";
|
|
2
|
-
import { t } from "../vendors/clsx.js";
|
|
3
|
-
import { t as n } from "./useDeptsMemberSelector-DP5L8bhi.js";
|
|
4
|
-
import { n as r, r as i, t as a } from "./TabGroup-B_VIf1lS.js";
|
|
5
|
-
import { t as o } from "../vendors/useLocale.js";
|
|
6
|
-
import { buildDeptTree as s, buildTree as c, findNodeInTree as l } from "./utils/index.js";
|
|
7
|
-
import { t as u } from "../vendors/services/data/member.service.js";
|
|
8
|
-
import { useCallback as d, useMemo as f, useState as p } from "react";
|
|
9
|
-
import { Spin as m } from "antd";
|
|
10
|
-
import { Icon as h, Tree as g } from "@baishuyun/ui-base";
|
|
11
|
-
import { useRequest as _ } from "ahooks";
|
|
12
|
-
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
13
|
-
//#region src/components/DeptsMember/subcomponents/Panels/OrganizationPanel/InternalOrganization/InternalOrganization.tsx
|
|
14
|
-
var b = (r) => {
|
|
15
|
-
let { type: a, containerHeight: s, value: c } = n(), { t: l } = o(), u = c?.map((e) => e._id) || [], d = r.data?.map((e) => e._id);
|
|
16
|
-
return /* @__PURE__ */ y(e, {
|
|
17
|
-
style: {
|
|
18
|
-
height: s - 8,
|
|
19
|
-
padding: "4px"
|
|
20
|
-
},
|
|
21
|
-
className: "internal-container",
|
|
22
|
-
classNames: { contentEl: "internal-container-content-el" },
|
|
23
|
-
children: [r.data.length > 0 && /* @__PURE__ */ v(g, {
|
|
24
|
-
parentCheckable: !0,
|
|
25
|
-
checkType: a === i.DEPARMENT ? "radio" : "checkbox",
|
|
26
|
-
data: r.data,
|
|
27
|
-
fieldNames: {
|
|
28
|
-
title: "name",
|
|
29
|
-
value: "_id",
|
|
30
|
-
children: "children"
|
|
31
|
-
},
|
|
32
|
-
selectedKeys: u,
|
|
33
|
-
onSelect: r.onSelect,
|
|
34
|
-
onDeSelect: r.onDeselect,
|
|
35
|
-
defaultExpandedKeys: d,
|
|
36
|
-
icon: () => /* @__PURE__ */ v(h, {
|
|
37
|
-
name: "dept-one",
|
|
38
|
-
className: "internal-container__icon"
|
|
39
|
-
}),
|
|
40
|
-
switcherIcon: (e) => /* @__PURE__ */ v(h, {
|
|
41
|
-
name: "xiangxiazhankai-11",
|
|
42
|
-
className: t("internal-container__arrow-icon", { "rotate-90": e })
|
|
43
|
-
})
|
|
44
|
-
}), r.data.length === 0 && !r.loading && /* @__PURE__ */ v("div", {
|
|
45
|
-
className: "internal-container__empty",
|
|
46
|
-
children: /* @__PURE__ */ v("span", { children: l("department.noAvailable") })
|
|
47
|
-
})]
|
|
48
|
-
});
|
|
49
|
-
}, x = {
|
|
50
|
-
"external-organization": "_external-organization_cz9md_1",
|
|
51
|
-
"external-organization__content": "_external-organization__content_cz9md_5",
|
|
52
|
-
"external-organization__scroll-content": "_external-organization__scroll-content_cz9md_8",
|
|
53
|
-
"external-organization__tree-icon": "_external-organization__tree-icon_cz9md_11",
|
|
54
|
-
"external-organization__switcher-icon": "_external-organization__switcher-icon_cz9md_14",
|
|
55
|
-
"external-organization__switcher-icon--expanded": "_external-organization__switcher-icon--expanded_cz9md_19",
|
|
56
|
-
"external-organization__empty": "_external-organization__empty_cz9md_22"
|
|
57
|
-
}, S = /* @__PURE__ */ function(e) {
|
|
58
|
-
return e.DOCK_PERSON_GROUP = "dockcorp", e.DOCK_DEPARTMENT = "dockcorpdept", e;
|
|
59
|
-
}(S || {}), C = (r) => {
|
|
60
|
-
let { type: s, containerHeight: c, value: l } = n(), { t: u } = o(), [d, f] = p(S.DOCK_PERSON_GROUP), m = l?.map((e) => e._id) || [], _ = [{
|
|
61
|
-
label: u("department.externalContactGroup"),
|
|
62
|
-
value: S.DOCK_PERSON_GROUP
|
|
63
|
-
}, {
|
|
64
|
-
label: u("department.externalContactDepartment"),
|
|
65
|
-
value: S.DOCK_DEPARTMENT
|
|
66
|
-
}], b = (e, t) => {
|
|
67
|
-
let n = [];
|
|
68
|
-
for (let r of e) if (r.type === t) if (t === "dockcorpdept") n.push({
|
|
69
|
-
...r,
|
|
70
|
-
children: r.children
|
|
71
|
-
});
|
|
72
|
-
else {
|
|
73
|
-
let e = r.children ? b(r.children, t) : [];
|
|
74
|
-
n.push({
|
|
75
|
-
...r,
|
|
76
|
-
children: e.length > 0 ? e : void 0
|
|
77
|
-
});
|
|
78
|
-
}
|
|
79
|
-
else {
|
|
80
|
-
let e = r.children ? b(r.children, t) : [];
|
|
81
|
-
e.length > 0 && n.push({
|
|
82
|
-
...r,
|
|
83
|
-
children: e
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
return n;
|
|
87
|
-
}, C = b(r.data, d), w = C?.map((e) => e._id);
|
|
88
|
-
return /* @__PURE__ */ y("div", {
|
|
89
|
-
className: x["external-organization"],
|
|
90
|
-
children: [/* @__PURE__ */ v(a, {
|
|
91
|
-
tabs: _,
|
|
92
|
-
value: d,
|
|
93
|
-
onChange: f
|
|
94
|
-
}), /* @__PURE__ */ v("div", {
|
|
95
|
-
className: x["external-organization__content"],
|
|
96
|
-
children: /* @__PURE__ */ y(e, {
|
|
97
|
-
style: {
|
|
98
|
-
height: c - 42,
|
|
99
|
-
padding: "4px"
|
|
100
|
-
},
|
|
101
|
-
classNames: { contentEl: x["external-organization__scroll-content"] },
|
|
102
|
-
children: [C.length > 0 && /* @__PURE__ */ v(g, {
|
|
103
|
-
parentCheckable: !0,
|
|
104
|
-
checkType: s === i.DEPARMENT ? "radio" : "checkbox",
|
|
105
|
-
data: C,
|
|
106
|
-
fieldNames: {
|
|
107
|
-
title: "name",
|
|
108
|
-
value: "_id",
|
|
109
|
-
children: "children"
|
|
110
|
-
},
|
|
111
|
-
selectedKeys: m,
|
|
112
|
-
onSelect: r.onSelect,
|
|
113
|
-
onDeSelect: r.onDeselect,
|
|
114
|
-
defaultExpandedKeys: w,
|
|
115
|
-
icon: () => /* @__PURE__ */ v(h, {
|
|
116
|
-
name: "dept-one",
|
|
117
|
-
className: x["external-organization__tree-icon"],
|
|
118
|
-
size: 16
|
|
119
|
-
}),
|
|
120
|
-
switcherIcon: (e) => /* @__PURE__ */ v(h, {
|
|
121
|
-
name: "xiangxiazhankai-11",
|
|
122
|
-
className: t(x["external-organization__switcher-icon"], { [x["external-organization__switcher-icon--expanded"]]: e })
|
|
123
|
-
})
|
|
124
|
-
}), C.length === 0 && !r.loading && /* @__PURE__ */ v("div", {
|
|
125
|
-
className: x["external-organization__empty"],
|
|
126
|
-
children: /* @__PURE__ */ v("span", { children: u("department.noAvailable") })
|
|
127
|
-
})]
|
|
128
|
-
})
|
|
129
|
-
})]
|
|
130
|
-
});
|
|
131
|
-
}, w = {
|
|
132
|
-
"organization-panel": "_organization-panel_1dfed_1",
|
|
133
|
-
"organization-panel__menu": "_organization-panel__menu_1dfed_6",
|
|
134
|
-
"organization-panel__menu-list": "_organization-panel__menu-list_1dfed_10",
|
|
135
|
-
"organization-panel__menu-item": "_organization-panel__menu-item_1dfed_14",
|
|
136
|
-
"organization-panel__menu-item--active": "_organization-panel__menu-item--active_1dfed_25",
|
|
137
|
-
"organization-panel__content": "_organization-panel__content_1dfed_32",
|
|
138
|
-
"organization-panel__content--borderless": "_organization-panel__content--borderless_1dfed_37"
|
|
139
|
-
}, T = /* @__PURE__ */ function(e) {
|
|
140
|
-
return e[e.INTERNAL = 0] = "INTERNAL", e[e.EXTERNAL = 1] = "EXTERNAL", e;
|
|
141
|
-
}(T || {}), E = () => {
|
|
142
|
-
let { type: e, dispatch: a } = n(), { t: h } = o(), [g] = p([{
|
|
143
|
-
key: T.INTERNAL,
|
|
144
|
-
label: h("department.internal"),
|
|
145
|
-
visible: !0
|
|
146
|
-
}, {
|
|
147
|
-
key: T.EXTERNAL,
|
|
148
|
-
label: h("department.external"),
|
|
149
|
-
visible: !0
|
|
150
|
-
}]), [x, S] = p(T.INTERNAL), { data: E, loading: D } = _(() => u({
|
|
151
|
-
departmentLimit: [],
|
|
152
|
-
hasDeptDock: x === T.EXTERNAL
|
|
153
|
-
}), { refreshDeps: [x] }), O = f(() => {
|
|
154
|
-
let e = E?.departments || [];
|
|
155
|
-
return e.length > 0 ? s(e) : [];
|
|
156
|
-
}, [E]), k = f(() => {
|
|
157
|
-
let e = E?.label_corp_list || [];
|
|
158
|
-
if (!e.length) return [];
|
|
159
|
-
let t = e.filter((t) => t.type === "dockcorp" || t.type === "dockdept" ? !0 : t.parentId === 0 ? !1 : e.some((e) => e.parentId === t.departmentId)), n = t.map((e) => ({
|
|
160
|
-
...e,
|
|
161
|
-
checkable: e.type !== "dockcorpdept" && e.type !== "label",
|
|
162
|
-
icon: /* @__PURE__ */ v(r, {
|
|
163
|
-
type: e.type,
|
|
164
|
-
size: 16
|
|
165
|
-
})
|
|
166
|
-
}));
|
|
167
|
-
return t.length > 0 ? c(n, {
|
|
168
|
-
parentId: "parentId",
|
|
169
|
-
children: "children",
|
|
170
|
-
value: "_id",
|
|
171
|
-
title: "name"
|
|
172
|
-
}) : [];
|
|
173
|
-
}, [E]), A = {
|
|
174
|
-
[T.INTERNAL]: O,
|
|
175
|
-
[T.EXTERNAL]: k
|
|
176
|
-
}, j = d((e) => {
|
|
177
|
-
let t = x === T.EXTERNAL ? E?.label_corp_list : E?.departments;
|
|
178
|
-
if (!t) return;
|
|
179
|
-
let n = t.find((t) => t._id === e);
|
|
180
|
-
n && a({
|
|
181
|
-
type: "insertOnly",
|
|
182
|
-
payload: { ...n }
|
|
183
|
-
});
|
|
184
|
-
}, [
|
|
185
|
-
a,
|
|
186
|
-
E,
|
|
187
|
-
x
|
|
188
|
-
]), M = d((e, t) => {
|
|
189
|
-
a({
|
|
190
|
-
type: "addOne",
|
|
191
|
-
payload: { ...t }
|
|
192
|
-
});
|
|
193
|
-
}, [a]), N = (e) => {
|
|
194
|
-
let t = l(e, A[x], {
|
|
195
|
-
children: "children",
|
|
196
|
-
value: "_id"
|
|
197
|
-
});
|
|
198
|
-
t && a({
|
|
199
|
-
type: "deleteOne",
|
|
200
|
-
payload: t._id
|
|
201
|
-
});
|
|
202
|
-
}, P = i.DEPARMENT === e ? j : M, F = E?.label_corp_count || 0;
|
|
203
|
-
return /* @__PURE__ */ y("div", {
|
|
204
|
-
className: w["organization-panel"],
|
|
205
|
-
children: [F > 0 && /* @__PURE__ */ v("aside", {
|
|
206
|
-
className: w["organization-panel__menu"],
|
|
207
|
-
children: /* @__PURE__ */ v("ul", {
|
|
208
|
-
className: w["organization-panel__menu-list"],
|
|
209
|
-
children: g.filter((e) => e.visible).map((e) => /* @__PURE__ */ v("li", {
|
|
210
|
-
onClick: () => S(e.key),
|
|
211
|
-
className: t(w["organization-panel__menu-item"], { [w["organization-panel__menu-item--active"]]: x === e.key }),
|
|
212
|
-
children: e.label
|
|
213
|
-
}, e.key))
|
|
214
|
-
})
|
|
215
|
-
}), /* @__PURE__ */ v("section", {
|
|
216
|
-
className: t(w["organization-panel__content"], { [w["organization-panel__content--borderless"]]: F === 0 }),
|
|
217
|
-
children: /* @__PURE__ */ y(m, {
|
|
218
|
-
spinning: D,
|
|
219
|
-
children: [T.INTERNAL === x && /* @__PURE__ */ v(b, {
|
|
220
|
-
onSelect: P,
|
|
221
|
-
onDeselect: N,
|
|
222
|
-
loading: !0,
|
|
223
|
-
data: A[x]
|
|
224
|
-
}), T.EXTERNAL === x && /* @__PURE__ */ v(C, {
|
|
225
|
-
data: A[x],
|
|
226
|
-
onSelect: P,
|
|
227
|
-
onDeselect: N,
|
|
228
|
-
loading: !0
|
|
229
|
-
})]
|
|
230
|
-
})
|
|
231
|
-
})]
|
|
232
|
-
});
|
|
233
|
-
};
|
|
234
|
-
//#endregion
|
|
235
|
-
export { E as t };
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
import { t as e } from "../vendors/simplebar-react.js";
|
|
2
|
-
import { t } from "../vendors/clsx.js";
|
|
3
|
-
import { t as n } from "./useDeptsMemberSelector-DP5L8bhi.js";
|
|
4
|
-
import { t as r } from "../vendors/useLocale.js";
|
|
5
|
-
import { buildDeptTree as i } from "./utils/index.js";
|
|
6
|
-
import { t as a } from "../vendors/services/ncorp/department.service.js";
|
|
7
|
-
import { useMemo as o } from "react";
|
|
8
|
-
import { Spin as s } from "antd";
|
|
9
|
-
import { Icon as c, Tree as l } from "@baishuyun/ui-base";
|
|
10
|
-
import { useRequest as u } from "ahooks";
|
|
11
|
-
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
12
|
-
//#region src/utils/recordSelectedNode.ts
|
|
13
|
-
function p(e, t) {
|
|
14
|
-
let n = "bsy_dept_member";
|
|
15
|
-
try {
|
|
16
|
-
let r = sessionStorage.getItem(n), i = r ? JSON.parse(r) : [];
|
|
17
|
-
if (i.some((t) => t._id === e)) return;
|
|
18
|
-
let a = t.find((t) => t._id === e);
|
|
19
|
-
if (!a) {
|
|
20
|
-
console.warn(`未找到 id 为 ${e} 的节点信息`);
|
|
21
|
-
return;
|
|
22
|
-
}
|
|
23
|
-
i.push(a), sessionStorage.setItem(n, JSON.stringify(i));
|
|
24
|
-
} catch (e) {
|
|
25
|
-
console.error("记录选中节点时发生错误:", e);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
//#endregion
|
|
29
|
-
//#region src/components/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/RelationShipDepts.module.scss
|
|
30
|
-
var m = {
|
|
31
|
-
"relation-ship-depts__icon": "_relation-ship-depts__icon_b3fo8_1",
|
|
32
|
-
"relation-ship-depts__arrow-icon": "_relation-ship-depts__arrow-icon_b3fo8_5",
|
|
33
|
-
"rotate-90": "_rotate-90_b3fo8_10",
|
|
34
|
-
"relation-ship-depts__empty": "_relation-ship-depts__empty_b3fo8_13"
|
|
35
|
-
}, h = (h) => {
|
|
36
|
-
let { containerHeight: g } = n(), { t: _ } = r(), { data: v, loading: y } = u(() => a({ hasDock: !0 }), { onSuccess: (e) => {
|
|
37
|
-
e.departments && h.onSelect(e.departments[0]._id, e.departments[0]);
|
|
38
|
-
} }), b = v?.departments || [], x = o(() => v?.departments?.length ? i(v.departments) : [], [v?.departments]), S = x?.map((e) => e._id);
|
|
39
|
-
return /* @__PURE__ */ d(s, {
|
|
40
|
-
spinning: y,
|
|
41
|
-
children: /* @__PURE__ */ f(e, {
|
|
42
|
-
className: m["relation-ship-depts"],
|
|
43
|
-
style: { height: g - 8 },
|
|
44
|
-
scrollableNodeProps: { style: {
|
|
45
|
-
overflowX: "auto",
|
|
46
|
-
overflowY: "auto"
|
|
47
|
-
} },
|
|
48
|
-
children: [x.length > 0 && /* @__PURE__ */ d(l, {
|
|
49
|
-
parentCheckable: !0,
|
|
50
|
-
data: x,
|
|
51
|
-
fieldNames: {
|
|
52
|
-
title: "name",
|
|
53
|
-
value: "_id",
|
|
54
|
-
children: "children"
|
|
55
|
-
},
|
|
56
|
-
selectedKeys: h.value ? [h.value] : [],
|
|
57
|
-
onSelect: (e, t) => {
|
|
58
|
-
p(e, b), h.onSelect(e, t);
|
|
59
|
-
},
|
|
60
|
-
defaultExpandedKeys: S,
|
|
61
|
-
icon: () => /* @__PURE__ */ d(c, {
|
|
62
|
-
name: "dept-one",
|
|
63
|
-
className: m["relation-ship-depts__icon"]
|
|
64
|
-
}),
|
|
65
|
-
switcherIcon: (e) => /* @__PURE__ */ d(c, {
|
|
66
|
-
name: "xiangxiazhankai-11",
|
|
67
|
-
className: t(m["relation-ship-depts__arrow-icon"], { [m["rotate-90"]]: e })
|
|
68
|
-
})
|
|
69
|
-
}), b.length === 0 && !y && /* @__PURE__ */ d("div", {
|
|
70
|
-
className: m["relation-ship-depts__empty"],
|
|
71
|
-
style: { height: g - 8 + "px" },
|
|
72
|
-
children: /* @__PURE__ */ d("span", { children: _("department.noAvailable") })
|
|
73
|
-
})]
|
|
74
|
-
})
|
|
75
|
-
});
|
|
76
|
-
};
|
|
77
|
-
//#endregion
|
|
78
|
-
export { p as n, h as t };
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { t as e } from "../vendors/simplebar-react.js";
|
|
2
|
-
import { t } from "../vendors/clsx.js";
|
|
3
|
-
import { t as n } from "./useDeptsMemberSelector-DP5L8bhi.js";
|
|
4
|
-
import { t as r } from "../vendors/services/ncorp/relation.service.js";
|
|
5
|
-
import { Spin as i } from "antd";
|
|
6
|
-
import { Checkbox as a } from "@baishuyun/ui-base";
|
|
7
|
-
import { useRequest as o } from "ahooks";
|
|
8
|
-
import { jsx as s } from "react/jsx-runtime";
|
|
9
|
-
//#region src/components/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipList/RelationShipList.module.scss
|
|
10
|
-
var c = {
|
|
11
|
-
"relation-ship-list__option": "_relation-ship-list__option_zlr78_1",
|
|
12
|
-
"relation-ship-list__option--checkbox": "_relation-ship-list__option--checkbox_zlr78_9",
|
|
13
|
-
"relation-ship-list__name": "_relation-ship-list__name_zlr78_12",
|
|
14
|
-
"relation-ship-list__checkbox-row": "_relation-ship-list__checkbox-row_zlr78_19",
|
|
15
|
-
"relation-ship-list__checkbox": "_relation-ship-list__checkbox_zlr78_19",
|
|
16
|
-
"relation-ship-list__group": "_relation-ship-list__group_zlr78_30"
|
|
17
|
-
}, l = ({ from: l, fromId: u }) => {
|
|
18
|
-
let { data: d, loading: f } = o(() => r({}), {
|
|
19
|
-
ready: !!(l && u),
|
|
20
|
-
refreshDeps: [l]
|
|
21
|
-
}), p = (d?.list || []).map((e) => ({
|
|
22
|
-
_id: `${u}-${l}-${e._id}`,
|
|
23
|
-
name: e.name
|
|
24
|
-
})), { value: m, dispatch: h, containerHeight: g } = n(), _ = m?.map((e) => e._id) || [];
|
|
25
|
-
return /* @__PURE__ */ s(i, {
|
|
26
|
-
spinning: f,
|
|
27
|
-
children: /* @__PURE__ */ s(e, {
|
|
28
|
-
style: { height: g - 8 },
|
|
29
|
-
children: /* @__PURE__ */ s("div", {
|
|
30
|
-
className: c["relation-ship-list"],
|
|
31
|
-
children: /* @__PURE__ */ s("ul", {
|
|
32
|
-
className: c["relation-ship-list__list"],
|
|
33
|
-
children: /* @__PURE__ */ s(a.Group, {
|
|
34
|
-
value: _,
|
|
35
|
-
onChange: (e) => {
|
|
36
|
-
let t = [], n = [];
|
|
37
|
-
for (let r = 0; r < p.length; r++) {
|
|
38
|
-
let i = p[r];
|
|
39
|
-
e.includes(i._id) ? t.push(i) : n.push(i);
|
|
40
|
-
}
|
|
41
|
-
h({
|
|
42
|
-
type: "deleteAndInsert",
|
|
43
|
-
payload: {
|
|
44
|
-
oldIds: n.map((e) => e._id),
|
|
45
|
-
newItems: t
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
},
|
|
49
|
-
className: c["relation-ship-list__group"],
|
|
50
|
-
children: p.map((e) => /* @__PURE__ */ s("li", {
|
|
51
|
-
className: t(c["relation-ship-list__option"], c["relation-ship-list__option--checkbox"]),
|
|
52
|
-
children: /* @__PURE__ */ s(a, {
|
|
53
|
-
labelPosition: "left",
|
|
54
|
-
value: e._id,
|
|
55
|
-
className: c["relation-ship-list__checkbox"],
|
|
56
|
-
children: /* @__PURE__ */ s("div", {
|
|
57
|
-
className: c["relation-ship-list__checkbox-row"],
|
|
58
|
-
title: e.name,
|
|
59
|
-
children: /* @__PURE__ */ s("span", {
|
|
60
|
-
className: c["relation-ship-list__name"],
|
|
61
|
-
children: e.name
|
|
62
|
-
})
|
|
63
|
-
})
|
|
64
|
-
})
|
|
65
|
-
}, e._id))
|
|
66
|
-
})
|
|
67
|
-
})
|
|
68
|
-
})
|
|
69
|
-
})
|
|
70
|
-
});
|
|
71
|
-
};
|
|
72
|
-
//#endregion
|
|
73
|
-
export { l as t };
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import "../vendors/simplebar-react.js";
|
|
2
|
-
import "./useDeptsMemberSelector-DP5L8bhi.js";
|
|
3
|
-
import { r as e } from "./TabGroup-B_VIf1lS.js";
|
|
4
|
-
import { t } from "./DeptsMember-D_xv-Zy7.js";
|
|
5
|
-
import "../vendors/useLocale.js";
|
|
6
|
-
import "../ConfigProvider/configContext-B0kvcW4s.js";
|
|
7
|
-
import { getColorByName as n } from "./utils/index.js";
|
|
8
|
-
import "./RelationShipDepts-wcYjFbhx.js";
|
|
9
|
-
import "./OrganizationPanel-BLIXOm6z.js";
|
|
10
|
-
import "./ExtraConcactPanel-Cioew3V3.js";
|
|
11
|
-
import "./DeptsUser-CQrRRJxk.js";
|
|
12
|
-
import "./RelationShipList-CRdCr4NL.js";
|
|
13
|
-
import "./Member-BIBX5jKD.js";
|
|
14
|
-
import "./Department-BYVAaPYd.js";
|
|
15
|
-
//#region src/components/DeptsMember/index.ts
|
|
16
|
-
var r = t;
|
|
17
|
-
//#endregion
|
|
18
|
-
export { e as Entity, r as default, n as getColorByName };
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import "../../../../vendors/simplebar-react.js";
|
|
2
|
-
import "../../../useDeptsMemberSelector-DP5L8bhi.js";
|
|
3
|
-
import "../../../TabGroup-B_VIf1lS.js";
|
|
4
|
-
import "../../../../vendors/useLocale.js";
|
|
5
|
-
import "../../../../ConfigProvider/configContext-B0kvcW4s.js";
|
|
6
|
-
import "../../../OrganizationPanel-BLIXOm6z.js";
|
|
7
|
-
import { t as e } from "../../../Department-BYVAaPYd.js";
|
|
8
|
-
export { e as useDepartmentTabItems };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import "../../../../vendors/simplebar-react.js";
|
|
2
|
-
import "../../../useDeptsMemberSelector-DP5L8bhi.js";
|
|
3
|
-
import "../../../TabGroup-B_VIf1lS.js";
|
|
4
|
-
import "../../../../vendors/useLocale.js";
|
|
5
|
-
import "../../../../ConfigProvider/configContext-B0kvcW4s.js";
|
|
6
|
-
import "../../../RelationShipDepts-wcYjFbhx.js";
|
|
7
|
-
import "../../../OrganizationPanel-BLIXOm6z.js";
|
|
8
|
-
import "../../../ExtraConcactPanel-Cioew3V3.js";
|
|
9
|
-
import { t as e } from "../../../DeptsUser-CQrRRJxk.js";
|
|
10
|
-
import "../../../RelationShipList-CRdCr4NL.js";
|
|
11
|
-
export { e as useDeptUserTabItems };
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import "../../../../vendors/simplebar-react.js";
|
|
2
|
-
import "../../../useDeptsMemberSelector-DP5L8bhi.js";
|
|
3
|
-
import "../../../TabGroup-B_VIf1lS.js";
|
|
4
|
-
import "../../../../vendors/useLocale.js";
|
|
5
|
-
import "../../../../ConfigProvider/configContext-B0kvcW4s.js";
|
|
6
|
-
import "../../../ExtraConcactPanel-Cioew3V3.js";
|
|
7
|
-
import { t as e } from "../../../Member-BIBX5jKD.js";
|
|
8
|
-
export { e as useMemberTabItems };
|
package/dist/DeptsMember/subcomponents/Panels/MemberRelationShipPanel/RelationShipDepts/index.js
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import "../../../../../vendors/simplebar-react.js";
|
|
2
|
-
import "../../../../useDeptsMemberSelector-DP5L8bhi.js";
|
|
3
|
-
import "../../../../../vendors/useLocale.js";
|
|
4
|
-
import "../../../../../ConfigProvider/configContext-B0kvcW4s.js";
|
|
5
|
-
import { t as e } from "../../../../RelationShipDepts-wcYjFbhx.js";
|
|
6
|
-
export { e as default };
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { i as e } from "../vendors/lodash-es.js";
|
|
2
|
-
import { createContext as t, useContext as n } from "react";
|
|
3
|
-
//#region src/components/DeptsMember/context/DeptsMemberContext.ts
|
|
4
|
-
var r = t({
|
|
5
|
-
type: "user",
|
|
6
|
-
setValue: e,
|
|
7
|
-
dispatch: e,
|
|
8
|
-
containerHeight: 0,
|
|
9
|
-
auth: {
|
|
10
|
-
publicPermissionEnable: !1,
|
|
11
|
-
managerPermissionEnable: !1
|
|
12
|
-
}
|
|
13
|
-
}), i = () => n(r);
|
|
14
|
-
//#endregion
|
|
15
|
-
export { r as n, i as t };
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
type SelectorType = 'user' | 'usergroup' | 'dept' | 'deptgroup' | 'deptusers';
|
|
2
|
-
type EntitySelectorProps = {
|
|
3
|
-
/**
|
|
4
|
-
* 业务类型:部门单选 / 部门多选 / 成员 / 成员多选
|
|
5
|
-
* @default 'user'
|
|
6
|
-
*/
|
|
7
|
-
type?: SelectorType;
|
|
8
|
-
/**
|
|
9
|
-
* 选择器值
|
|
10
|
-
*/
|
|
11
|
-
value?: any[];
|
|
12
|
-
/**
|
|
13
|
-
* 默认值
|
|
14
|
-
*/
|
|
15
|
-
defaultValue?: any[];
|
|
16
|
-
/**
|
|
17
|
-
* @description 当前登录的系统用户信息(用 props 传递此数据)
|
|
18
|
-
*/
|
|
19
|
-
currentUser?: Record<string, unknown>;
|
|
20
|
-
/**
|
|
21
|
-
* 选择器值改变时的回调
|
|
22
|
-
*/
|
|
23
|
-
onChange?: (value: any[]) => void;
|
|
24
|
-
/**
|
|
25
|
-
* 取消按钮点击回调
|
|
26
|
-
*/
|
|
27
|
-
onCancel?: () => void;
|
|
28
|
-
/**
|
|
29
|
-
* 确认按钮点击回调
|
|
30
|
-
*/
|
|
31
|
-
onConfirm?: (value: any[]) => void;
|
|
32
|
-
/**
|
|
33
|
-
* @description 面板权限控制
|
|
34
|
-
*/
|
|
35
|
-
auth?: {
|
|
36
|
-
/**
|
|
37
|
-
* @description 是否开启公开权限控制
|
|
38
|
-
* @default: false
|
|
39
|
-
*/
|
|
40
|
-
publicPermissionEnable?: boolean;
|
|
41
|
-
/**
|
|
42
|
-
* @description 是否开启系统管理员权限控制
|
|
43
|
-
* @default: false
|
|
44
|
-
*/
|
|
45
|
-
managerPermissionEnable?: boolean;
|
|
46
|
-
};
|
|
47
|
-
};
|
|
48
|
-
export type { SelectorType, EntitySelectorProps };
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
type AddAction = {
|
|
2
|
-
type: 'addOne';
|
|
3
|
-
payload: { _id: string | number; [key: string]: any };
|
|
4
|
-
};
|
|
5
|
-
|
|
6
|
-
type AddManyAction = {
|
|
7
|
-
type: 'addMany';
|
|
8
|
-
payload: Array<{ _id: string | number; [key: string]: any }>;
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
type RemoveManyAction = {
|
|
12
|
-
type: 'removeMany';
|
|
13
|
-
payload: Array<string | number>;
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
type RemoveAllAction = {
|
|
17
|
-
type: 'removeAll';
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
type InsertOnlyAction = {
|
|
21
|
-
type: 'insertOnly';
|
|
22
|
-
payload: Record<string, any>;
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
type DeleteOneAction = {
|
|
26
|
-
type: 'deleteOne';
|
|
27
|
-
payload: string | number;
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
type DeleteAndInsertAction = {
|
|
31
|
-
type: 'deleteAndInsert';
|
|
32
|
-
payload: {
|
|
33
|
-
newItems: Array<{ _id: string | number; [key: string]: any }>;
|
|
34
|
-
oldIds: Array<string | number>;
|
|
35
|
-
};
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export type Action =
|
|
39
|
-
| AddAction
|
|
40
|
-
| AddManyAction
|
|
41
|
-
| RemoveManyAction
|
|
42
|
-
| RemoveAllAction
|
|
43
|
-
| InsertOnlyAction
|
|
44
|
-
| DeleteOneAction
|
|
45
|
-
| DeleteAndInsertAction;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export declare const useDeptsMemberSelector: () => {
|
|
2
|
-
type: import('..').SelectorType;
|
|
3
|
-
value?: any[];
|
|
4
|
-
setValue: (v: import('react').SetStateAction<any[]>, ...args: any[]) => void;
|
|
5
|
-
dispatch: (action: import('../context/DeptsMemberContext').Action) => void;
|
|
6
|
-
containerHeight: number;
|
|
7
|
-
currentUser?: Record<string, unknown>;
|
|
8
|
-
auth: {
|
|
9
|
-
publicPermissionEnable: boolean;
|
|
10
|
-
managerPermissionEnable: boolean;
|
|
11
|
-
};
|
|
12
|
-
};
|