@voplus/morpho-csp 2.0.8 → 2.0.9
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/es/modules/corporate/company/controller-register/components/ControllerProperties/index.d.ts +27 -0
- package/es/modules/corporate/company/controller-register/components/ControllerProperties/index.js +87 -0
- package/es/modules/corporate/company/controller-register/components/ControllerProperties/index.js.map +1 -0
- package/es/modules/corporate/company/controller-register/components/ControllerPropertiesView/index.js +6 -18
- package/es/modules/corporate/company/controller-register/components/ControllerPropertiesView/index.js.map +1 -1
- package/es/modules/corporate/company/identity/components/IdentifyProperties/index.d.ts +16 -0
- package/es/modules/corporate/company/identity/components/IdentifyProperties/index.js +65 -0
- package/es/modules/corporate/company/identity/components/IdentifyProperties/index.js.map +1 -0
- package/es/modules/corporate/company/identity/components/IdentifyProperties/index.less +37 -0
- package/es/modules/corporate/company/identity/components/IdentifyQuickViewDialog/index.d.ts +10 -0
- package/es/modules/corporate/company/identity/components/IdentifyQuickViewDialog/index.js +19 -0
- package/es/modules/corporate/company/identity/components/IdentifyQuickViewDialog/index.js.map +1 -0
- package/es/modules/corporate/company/identity/components/IdentifyQuickViewDialog/index.less +42 -0
- package/es/modules/corporate/company/identity/components/NewIdentityDialog/index.less +67 -55
- package/es/modules/corporate/company/identity/components/NewLegalContactDialog/index.less +72 -59
- package/es/modules/corporate/company/identity/components/SelectLegalContactDialog/index.less +66 -54
- package/es/modules/corporate/company/identity/controls/IdentifyMenu/index.d.ts +16 -0
- package/es/modules/corporate/company/identity/controls/IdentifyMenu/index.js +27 -0
- package/es/modules/corporate/company/identity/controls/IdentifyMenu/index.js.map +1 -0
- package/es/modules/corporate/company/identity/controls/IdentifyMenu/index.less +34 -0
- package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.d.ts +27 -0
- package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.js +51 -0
- package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.js.map +1 -0
- package/es/modules/corporate/company/member-register/components/CompanyMemberPropertiesView/index.js +10 -19
- package/es/modules/corporate/company/member-register/components/CompanyMemberPropertiesView/index.js.map +1 -1
- package/es/modules/corporate/company/officer-register/components/OfficerProperties/index.d.ts +27 -0
- package/es/modules/corporate/company/officer-register/components/OfficerProperties/index.js +71 -0
- package/es/modules/corporate/company/officer-register/components/OfficerProperties/index.js.map +1 -0
- package/es/modules/corporate/company/officer-register/components/OfficerPropertiesView/index.js +8 -20
- package/es/modules/corporate/company/officer-register/components/OfficerPropertiesView/index.js.map +1 -1
- package/es/modules/corporate/filing-record/components/FilingRecordQuickView/index.less +68 -56
- package/es/modules/corporate/share-certificate/pages/ShareCertificateClientView/index.less +1 -1
- package/package.json +1 -1
|
@@ -1,59 +1,72 @@
|
|
|
1
|
-
@import "~@voplus/morpho-theme/styles/index.less";
|
|
2
|
-
|
|
3
|
-
:global {
|
|
4
|
-
.select-legal-contact-dialog {
|
|
5
|
-
.ant-modal-body {
|
|
6
|
-
padding: 20px 0;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
padding
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
|
|
1
|
+
@import "~@voplus/morpho-theme/styles/index.less";
|
|
2
|
+
|
|
3
|
+
:global {
|
|
4
|
+
.select-legal-contact-dialog {
|
|
5
|
+
.ant-modal-body {
|
|
6
|
+
padding: 20px 0 !important;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
h3,
|
|
10
|
+
h4 {
|
|
11
|
+
margin-bottom: 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.select-legal-contact_title {
|
|
15
|
+
padding: 0 20px 15px 20px;
|
|
16
|
+
color: rgba(0, 0, 0, 0.85);
|
|
17
|
+
font-weight: 500;
|
|
18
|
+
font-size: 16px;
|
|
19
|
+
line-height: 17px;
|
|
20
|
+
border-bottom: 1px solid #f0f0f0;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.select-legal-contact_content {
|
|
24
|
+
padding: 15px 20px;
|
|
25
|
+
|
|
26
|
+
&.page5 {
|
|
27
|
+
padding: 15px 30px;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.ant-radio-group {
|
|
31
|
+
display: block;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.full-name-displayed {
|
|
35
|
+
padding: 10px 0;
|
|
36
|
+
border-bottom: 1px solid #f0f0f0;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.full-name {
|
|
40
|
+
padding-bottom: 8px;
|
|
41
|
+
color: rgba(0, 0, 0, 0.85);
|
|
42
|
+
font-weight: 500;
|
|
43
|
+
font-size: 16px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.padding-top-15 {
|
|
47
|
+
padding-top: 15px;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.sub-title {
|
|
51
|
+
color: @heading-subtitle-color;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.ant-tabs .ant-tabs-tabpane {
|
|
56
|
+
padding: 0 20px;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.ant-form .ant-form-item {
|
|
60
|
+
margin-bottom: 20px;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.select-legal-contact_footer {
|
|
64
|
+
padding: 0 20px;
|
|
65
|
+
text-align: right;
|
|
66
|
+
|
|
67
|
+
& .ant-btn {
|
|
68
|
+
margin-left: 10px;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
package/es/modules/corporate/company/identity/components/SelectLegalContactDialog/index.less
CHANGED
|
@@ -1,54 +1,66 @@
|
|
|
1
|
-
:global {
|
|
2
|
-
.select-legal-contact-dialog {
|
|
3
|
-
.ant-modal-body {
|
|
4
|
-
padding: 20px 0;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
1
|
+
:global {
|
|
2
|
+
.select-legal-contact-dialog {
|
|
3
|
+
.ant-modal-body {
|
|
4
|
+
padding: 20px 0 !important;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
h3,
|
|
8
|
+
h4 {
|
|
9
|
+
margin-bottom: 0;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.select-legal-contact_title {
|
|
13
|
+
padding: 0 20px 15px 20px;
|
|
14
|
+
color: rgba(0, 0, 0, 0.85);
|
|
15
|
+
font-weight: 500;
|
|
16
|
+
font-size: 16px;
|
|
17
|
+
line-height: 17px;
|
|
18
|
+
border-bottom: 1px solid #f0f0f0;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.select-legal-contact_content {
|
|
22
|
+
padding: 15px 20px;
|
|
23
|
+
|
|
24
|
+
&.page5 {
|
|
25
|
+
padding: 15px 30px;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.ant-radio-group {
|
|
29
|
+
display: block;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.full-name-displayed {
|
|
33
|
+
padding: 10px 0;
|
|
34
|
+
border-bottom: 1px solid #f0f0f0;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.full-name {
|
|
38
|
+
padding-bottom: 8px;
|
|
39
|
+
color: rgba(0, 0, 0, 0.85);
|
|
40
|
+
font-weight: 500;
|
|
41
|
+
font-size: 16px;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.padding-top-15 {
|
|
45
|
+
padding-top: 15px;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.ant-tabs .ant-tabs-tabpane {
|
|
50
|
+
padding: 0 20px;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.ant-form .ant-form-item {
|
|
54
|
+
margin-bottom: 20px;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.select-legal-contact_footer {
|
|
58
|
+
padding: 0 20px;
|
|
59
|
+
text-align: right;
|
|
60
|
+
|
|
61
|
+
& .ant-btn {
|
|
62
|
+
margin-left: 10px;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import "./index.less";
|
|
3
|
+
declare const IdentityMenu: {
|
|
4
|
+
(props: {
|
|
5
|
+
id: string;
|
|
6
|
+
className?: string;
|
|
7
|
+
closeAside?: boolean;
|
|
8
|
+
size: "small" | "middle" | "large" | undefined;
|
|
9
|
+
icon?: React.ReactNode;
|
|
10
|
+
}): JSX.Element;
|
|
11
|
+
defaultProps: {
|
|
12
|
+
size: string;
|
|
13
|
+
icon: JSX.Element;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
export default IdentityMenu;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React, { useMemo } from "react";
|
|
2
|
+
import { Button, Dropdown } from "antd";
|
|
3
|
+
import { faCircleEllipsis } from "@fortawesome/pro-light-svg-icons";
|
|
4
|
+
import { Access, Paste, PasteLinks, PasteShortcut, Delete, } from "@voplus/morpho-document/es/controls/DocumentMenu/items";
|
|
5
|
+
import { useIdentityStore } from "../../../../../../data/identity";
|
|
6
|
+
import { observe } from "@voplus/morpho-ui";
|
|
7
|
+
import { FontAwesomeIcon as FAIcon } from "@fortawesome/react-fontawesome";
|
|
8
|
+
import "./index.less";
|
|
9
|
+
import { DocumentMenuContext, DocumentMenuState } from "@voplus/morpho-document-core";
|
|
10
|
+
const IdentityMenu = (props) => {
|
|
11
|
+
const context = useMemo(() => new DocumentMenuState(props.id), [props.id]);
|
|
12
|
+
const store = useIdentityStore();
|
|
13
|
+
return observe(() => (React.createElement(DocumentMenuContext.Provider, { value: context },
|
|
14
|
+
React.createElement(Dropdown, { placement: "bottomRight", overlay: React.createElement("div", { className: "identity-menu" },
|
|
15
|
+
React.createElement(Access, null),
|
|
16
|
+
React.createElement(Paste, null),
|
|
17
|
+
React.createElement(PasteLinks, null),
|
|
18
|
+
React.createElement(PasteShortcut, null),
|
|
19
|
+
React.createElement(Delete, { action: () => store.delete(props.id) })) },
|
|
20
|
+
React.createElement(Button, { size: props.size, type: "link" }, props.icon)))));
|
|
21
|
+
};
|
|
22
|
+
IdentityMenu.defaultProps = {
|
|
23
|
+
size: "small",
|
|
24
|
+
icon: React.createElement(FAIcon, { icon: faCircleEllipsis }),
|
|
25
|
+
};
|
|
26
|
+
export default IdentityMenu;
|
|
27
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/modules/corporate/company/identity/controls/IdentifyMenu/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AACxC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EACN,MAAM,EACN,KAAK,EACL,UAAU,EACV,aAAa,EACb,MAAM,GACN,MAAM,wDAAwD,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,cAAc,CAAC;AACtB,OAAO,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAEtF,MAAM,YAAY,GAAG,CAAC,KAMrB,EAAE,EAAE;IACJ,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,iBAAiB,CAAC,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,CAAC;IAE3E,MAAM,KAAK,GAAG,gBAAgB,EAAE,CAAC;IAEjC,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,mBAAmB,CAAC,QAAQ,IAAC,KAAK,EAAE,OAAO;QAC3C,oBAAC,QAAQ,IACR,SAAS,EAAC,aAAa,EACvB,OAAO,EACN,6BAAK,SAAS,EAAC,eAAe;gBAC7B,oBAAC,MAAM,OAAG;gBACV,oBAAC,KAAK,OAAG;gBACT,oBAAC,UAAU,OAAG;gBACd,oBAAC,aAAa,OAAG;gBACjB,oBAAC,MAAM,IAAC,MAAM,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,GAAI,CAC3C;YAGP,oBAAC,MAAM,IAAC,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,IAAI,EAAC,MAAM,IACnC,KAAK,CAAC,IAAI,CACH,CACC,CACmB,CAC/B,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,YAAY,CAAC,YAAY,GAAG;IAC3B,IAAI,EAAE,OAAO;IACb,IAAI,EAAE,oBAAC,MAAM,IAAC,IAAI,EAAE,gBAAgB,GAAI;CACxC,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
:global {
|
|
2
|
+
.identity-menu {
|
|
3
|
+
list-style-type: none;
|
|
4
|
+
background-color: #fff;
|
|
5
|
+
background-clip: padding-box;
|
|
6
|
+
outline: none;
|
|
7
|
+
border-radius: 8px !important;
|
|
8
|
+
box-shadow: 0px 3px 6px rgba(119, 119, 119, 0.14) !important;
|
|
9
|
+
padding: 4px 8px !important;
|
|
10
|
+
|
|
11
|
+
.ant-btn {
|
|
12
|
+
display: block;
|
|
13
|
+
width: 100%;
|
|
14
|
+
padding: 0 12px;
|
|
15
|
+
height: 34px;
|
|
16
|
+
color: #666;
|
|
17
|
+
text-align: left;
|
|
18
|
+
|
|
19
|
+
&[disabled] {
|
|
20
|
+
color: rgba(0, 0, 0, 0.25);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
&:hover {
|
|
24
|
+
background-color: #94cdff !important;
|
|
25
|
+
box-shadow: 0px 3px 6px rgba(99, 99, 99, 0.16) !important;
|
|
26
|
+
border-radius: 8px !important;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
> span {
|
|
30
|
+
margin-left: 10px;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare type CompanyMemberPropertiesName = "Representative" | "Status";
|
|
3
|
+
declare const CompanyMemberProperties: {
|
|
4
|
+
(props: {
|
|
5
|
+
id: string;
|
|
6
|
+
allowEdit?: boolean;
|
|
7
|
+
companyMemberTitle?: string;
|
|
8
|
+
orgContactTitle?: string;
|
|
9
|
+
companyMemberProperties?: {
|
|
10
|
+
name: CompanyMemberPropertiesName;
|
|
11
|
+
visible?: boolean;
|
|
12
|
+
}[];
|
|
13
|
+
orgContactProperties?: {
|
|
14
|
+
name: "Phone" | "Address" | "E-mail" | "DingId" | "Site" | "Birthday" | "Gender";
|
|
15
|
+
visible?: boolean;
|
|
16
|
+
}[];
|
|
17
|
+
onReloadMenu?: () => void;
|
|
18
|
+
}): JSX.Element;
|
|
19
|
+
defaultProps: {
|
|
20
|
+
companyMemberTitle: string;
|
|
21
|
+
orgContactTitle: string;
|
|
22
|
+
companyMemberProperties: {
|
|
23
|
+
name: string;
|
|
24
|
+
}[];
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
export default CompanyMemberProperties;
|
package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.js
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { observe } from "@voplus/morpho-ui";
|
|
3
|
+
import { useMember, useMemberStore } from "../../../../../../data/member";
|
|
4
|
+
import { Form, Row, Col } from "antd";
|
|
5
|
+
import { Scrollbars } from "react-custom-scrollbars";
|
|
6
|
+
import PropertiesSection from "@voplus/morpho-ui/es/controls/PropertiesSection";
|
|
7
|
+
import ContactProperties from "@voplus/morpho-org/es/components/ContactProperties";
|
|
8
|
+
import MetionList from "@voplus/morpho-org/es/controls/MetionList";
|
|
9
|
+
import MemberStatusLabel from "../../controls/MemberStatusLabel";
|
|
10
|
+
import IdentifyProperties from "../../../identity/components/IdentifyProperties";
|
|
11
|
+
const CompanyMemberProperties = (props) => {
|
|
12
|
+
const { id, allowEdit, companyMemberTitle, orgContactTitle, companyMemberProperties, orgContactProperties, } = props;
|
|
13
|
+
const member = useMember(id);
|
|
14
|
+
const store = useMemberStore();
|
|
15
|
+
const filterPro = companyMemberProperties === null || companyMemberProperties === void 0 ? void 0 : companyMemberProperties.filter((i) => (i === null || i === void 0 ? void 0 : i.visible) !== false);
|
|
16
|
+
return observe(() => {
|
|
17
|
+
var _a, _b;
|
|
18
|
+
return (React.createElement("div", { className: "properties-list" },
|
|
19
|
+
React.createElement(Scrollbars, { autoHide: true },
|
|
20
|
+
React.createElement(PropertiesSection, { title: companyMemberTitle, properties: React.createElement(Form, { labelAlign: "left", labelCol: { span: 10 }, scrollToFirstError: true }, filterPro === null || filterPro === void 0 ? void 0 : filterPro.map((i) => (React.createElement(React.Fragment, { key: i.name }, renderProp(i))))) }),
|
|
21
|
+
React.createElement(Row, null,
|
|
22
|
+
React.createElement(Col, { span: 10 }, "Identity:"),
|
|
23
|
+
React.createElement(Col, { span: 14 },
|
|
24
|
+
React.createElement(IdentifyProperties, { identityId: (_a = member.identity) === null || _a === void 0 ? void 0 : _a.id, concatId: member.contact.id, memberId: id, allowEdit: allowEdit }))),
|
|
25
|
+
React.createElement(ContactProperties, { fromLabelRequired: true, id: (_b = member === null || member === void 0 ? void 0 : member.contact) === null || _b === void 0 ? void 0 : _b.id, labelCol: 10, wrapperCol: 14, title: orgContactTitle, customProperties: orgContactProperties }))));
|
|
26
|
+
});
|
|
27
|
+
function renderProp(item) {
|
|
28
|
+
switch (item.name) {
|
|
29
|
+
case "Representative":
|
|
30
|
+
return (React.createElement(Form.Item, { label: "Representative" },
|
|
31
|
+
React.createElement(MetionList, { isEmptyData: true, canEdit: allowEdit, contacts: member.representative ? [member.representative] : [], onChange: (list) => {
|
|
32
|
+
store.edit(id, {
|
|
33
|
+
data: { RepresentativeId: list.length ? list[0].id : "" },
|
|
34
|
+
error: "message",
|
|
35
|
+
});
|
|
36
|
+
} })));
|
|
37
|
+
case "Status":
|
|
38
|
+
return (React.createElement(Form.Item, { label: "Status" },
|
|
39
|
+
React.createElement(MemberStatusLabel, { editable: true, status: member.status, onChange: (status) => {
|
|
40
|
+
store.edit(id, { data: { Status: status }, error: "message" });
|
|
41
|
+
} })));
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
CompanyMemberProperties.defaultProps = {
|
|
46
|
+
companyMemberTitle: "Member Properties",
|
|
47
|
+
orgContactTitle: "Contact Properties",
|
|
48
|
+
companyMemberProperties: [{ name: "Representative" }, { name: "Status" }],
|
|
49
|
+
};
|
|
50
|
+
export default CompanyMemberProperties;
|
|
51
|
+
//# sourceMappingURL=index.js.map
|
package/es/modules/corporate/company/member-register/components/CompanyMemberProperties/index.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/modules/corporate/company/member-register/components/CompanyMemberProperties/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,iBAAiB,MAAM,iDAAiD,CAAC;AAChF,OAAO,iBAAiB,MAAM,oDAAoD,CAAC;AACnF,OAAO,UAAU,MAAM,2CAA2C,CAAC;AACnE,OAAO,iBAAiB,MAAM,kCAAkC,CAAC;AACjE,OAAO,kBAAkB,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AE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;wBAChE,CAAC,GACA,CACS,CACZ,CAAC;SACH;IACF,CAAC;AACF,CAAC,CAAC;AAEF,uBAAuB,CAAC,YAAY,GAAG;IACtC,kBAAkB,EAAE,mBAAmB;IACvC,eAAe,EAAE,oBAAoB;IACrC,uBAAuB,EAAE,CAAC,EAAE,IAAI,EAAE,gBAAgB,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;CACzE,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
|
package/es/modules/corporate/company/member-register/components/CompanyMemberPropertiesView/index.js
CHANGED
|
@@ -1,42 +1,33 @@
|
|
|
1
1
|
import React, { useMemo } from "react";
|
|
2
2
|
import { ViewContext, ViewContextData, } from "@voplus/morpho-document-core/es/data/context/ViewContext";
|
|
3
3
|
import { useMember, useMemberStore } from "../../../../../../data/member";
|
|
4
|
+
import { Open } from "@voplus/morpho-document/es/controls/ToolBar/buttons";
|
|
5
|
+
import { Tabs } from "antd";
|
|
6
|
+
import { observe } from "@voplus/morpho-ui";
|
|
4
7
|
import ActivityLog from "@voplus/morpho-org/es/components/ActivityLog/ActivityLog2";
|
|
5
8
|
import CompanyMemberMenu from "../../../controls/CompanyRegisterMenu";
|
|
6
|
-
import
|
|
7
|
-
import Details from "../Details";
|
|
9
|
+
import CompanyMemberProperties from "../CompanyMemberProperties";
|
|
8
10
|
import DocumentList from "@voplus/morpho-document/es/components/DocumentList";
|
|
9
|
-
import IdentifyDetail from "../../../identity/components/IdentifyDetail";
|
|
10
11
|
import MemberShareTransactions from "../MemberShareTransactions";
|
|
11
|
-
import { Open } from "@voplus/morpho-document/es/controls/ToolBar/buttons";
|
|
12
|
-
import { Tabs } from "antd";
|
|
13
12
|
import ToolBar from "@voplus/morpho-document/es/controls/ToolBar/ToolBar2";
|
|
14
13
|
import UnitAvatar from "@voplus/morpho-org/es/components/UnitAvatar";
|
|
15
|
-
import { observe } from "@voplus/morpho-ui";
|
|
16
14
|
import styles from "./index.less";
|
|
17
15
|
const CompanyMemberPropertiesView = (props) => {
|
|
18
|
-
var _a;
|
|
19
16
|
const { id, allowEdit, toolbar, documentTab } = props;
|
|
20
17
|
const member = useMember(id, { reload: true });
|
|
21
18
|
const store = useMemberStore();
|
|
22
19
|
const view = useMemo(() => new ViewContextData("QuickView"), []);
|
|
23
20
|
const items = [
|
|
24
|
-
{
|
|
21
|
+
{
|
|
22
|
+
key: "Details",
|
|
23
|
+
label: "Details",
|
|
24
|
+
children: React.createElement(CompanyMemberProperties, { id: id, allowEdit: allowEdit }),
|
|
25
|
+
},
|
|
25
26
|
{
|
|
26
27
|
key: "Shares",
|
|
27
28
|
label: "Shares",
|
|
28
29
|
children: React.createElement(MemberShareTransactions, { id: id }),
|
|
29
30
|
},
|
|
30
|
-
{
|
|
31
|
-
key: "Contact",
|
|
32
|
-
label: "Contact Details",
|
|
33
|
-
children: React.createElement(ContactInformation, { id: member.contact.id, allowEdit: allowEdit }),
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
key: "Identify",
|
|
37
|
-
label: "Identify Details",
|
|
38
|
-
children: (React.createElement(IdentifyDetail, { identityId: (_a = member.identity) === null || _a === void 0 ? void 0 : _a.id, concatId: member.contact.id, memberId: id, allowEdit: allowEdit })),
|
|
39
|
-
},
|
|
40
31
|
];
|
|
41
32
|
if (documentTab)
|
|
42
33
|
items.push({
|
|
@@ -60,7 +51,7 @@ const CompanyMemberPropertiesView = (props) => {
|
|
|
60
51
|
toolbar !== false && (React.createElement(ToolBar, { showMenu: false },
|
|
61
52
|
React.createElement(Open, { url: `/member/${id}` }),
|
|
62
53
|
React.createElement(CompanyMemberMenu, { id: id, unitId: member.contact.id, store: store, closeAside: true })))),
|
|
63
|
-
React.createElement(Tabs, { defaultActiveKey: "
|
|
54
|
+
React.createElement(Tabs, { defaultActiveKey: "Details", items: items }))));
|
|
64
55
|
});
|
|
65
56
|
};
|
|
66
57
|
CompanyMemberPropertiesView.defaultProps = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/modules/corporate/company/member-register/components/CompanyMemberPropertiesView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EACN,WAAW,EACX,eAAe,GACf,MAAM,0DAA0D,CAAC;AAClE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/modules/corporate/company/member-register/components/CompanyMemberPropertiesView/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EACN,WAAW,EACX,eAAe,GACf,MAAM,0DAA0D,CAAC;AAClE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,MAAM,qDAAqD,CAAC;AAC3E,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,OAAO,WAAW,MAAM,2DAA2D,CAAC;AACpF,OAAO,iBAAiB,MAAM,uCAAuC,CAAC;AACtE,OAAO,uBAAuB,MAAM,4BAA4B,CAAC;AACjE,OAAO,YAAY,MAAM,oDAAoD,CAAC;AAC9E,OAAO,uBAAuB,MAAM,4BAA4B,CAAC;AACjE,OAAO,OAAO,MAAM,sDAAsD,CAAC;AAC3E,OAAO,UAAU,MAAM,6CAA6C,CAAC;AACrE,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,2BAA2B,GAAG,CAAC,KAMpC,EAAE,EAAE;IACJ,MAAM,EAAE,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,WAAW,EAAE,GAAG,KAAK,CAAC;IAEtD,MAAM,MA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AC,oBAAoB,IACjC,MAAA,MAAA,MAAM,CAAC,QAAQ,0CAAE,QAAQ,mCAAI,MAAM,CAAC,OAAO,CAAC,IAAI,CAC5C;oBACN,0CAAiB;oBAChB,OAAO,KAAK,KAAK,IAAI,CACrB,oBAAC,OAAO,IAAC,QAAQ,EAAE,KAAK;wBACvB,oBAAC,IAAI,IAAC,GAAG,EAAE,WAAW,EAAE,EAAE,GAAI;wBAC9B,oBAAC,iBAAiB,IAAC,EAAE,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,CAAC,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,SAAG,CACxE,CACV,CACI;gBAEN,oBAAC,IAAI,IAAC,gBAAgB,EAAC,SAAS,EAAC,KAAK,EAAE,KAAK,GAAI,CAC5C,CACgB,CACvB,CAAA;KAAA,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,2BAA2B,CAAC,YAAY,GAAG;IAC1C,WAAW,EAAE,IAAI;CACjB,CAAC;AAEF,eAAe,2BAA2B,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare type OfficerPropertiesName = "Status" | "Appointment Date" | "Cease Date" | "Email" | "Phone";
|
|
3
|
+
declare const OfficerProperties: {
|
|
4
|
+
(props: {
|
|
5
|
+
id: string;
|
|
6
|
+
allowEdit?: boolean;
|
|
7
|
+
officerTitle?: string;
|
|
8
|
+
orgContactTitle?: string;
|
|
9
|
+
officerProperties?: {
|
|
10
|
+
name: OfficerPropertiesName;
|
|
11
|
+
visible?: boolean;
|
|
12
|
+
}[];
|
|
13
|
+
orgContactProperties?: {
|
|
14
|
+
name: "Phone" | "Address" | "E-mail" | "DingId" | "Site" | "Birthday" | "Gender";
|
|
15
|
+
visible?: boolean;
|
|
16
|
+
}[];
|
|
17
|
+
onReloadMenu?: () => void;
|
|
18
|
+
}): JSX.Element;
|
|
19
|
+
defaultProps: {
|
|
20
|
+
officerTitle: string;
|
|
21
|
+
orgContactTitle: string;
|
|
22
|
+
officerProperties: {
|
|
23
|
+
name: string;
|
|
24
|
+
}[];
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
export default OfficerProperties;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { observe, InlineEdit } from "@voplus/morpho-ui";
|
|
3
|
+
import { useOfficer, useOfficerStore, } from "../../../../../../data/officer";
|
|
4
|
+
import { Form, Row, Col, Badge } from "antd";
|
|
5
|
+
import { Scrollbars } from "react-custom-scrollbars";
|
|
6
|
+
import PropertiesSection from "@voplus/morpho-ui/es/controls/PropertiesSection";
|
|
7
|
+
import ContactProperties from "@voplus/morpho-org/es/components/ContactProperties";
|
|
8
|
+
import IdentifyProperties from "../../../identity/components/IdentifyProperties";
|
|
9
|
+
import DateInputEditor from "@voplus/morpho-ui/es/controls/InlineEdit/editors/DateInputEditor";
|
|
10
|
+
import dayjs from "dayjs";
|
|
11
|
+
const OfficerProperties = (props) => {
|
|
12
|
+
const { id, allowEdit, officerTitle, orgContactTitle, officerProperties, orgContactProperties } = props;
|
|
13
|
+
const officer = useOfficer(id);
|
|
14
|
+
const store = useOfficerStore();
|
|
15
|
+
const filterPro = officerProperties === null || officerProperties === void 0 ? void 0 : officerProperties.filter((i) => (i === null || i === void 0 ? void 0 : i.visible) !== false);
|
|
16
|
+
return observe(() => {
|
|
17
|
+
var _a, _b;
|
|
18
|
+
return (React.createElement("div", { className: "properties-list" },
|
|
19
|
+
React.createElement(Scrollbars, { autoHide: true },
|
|
20
|
+
React.createElement(PropertiesSection, { title: officerTitle, properties: React.createElement(Form, { labelAlign: "left", labelCol: { span: 10 }, scrollToFirstError: true }, filterPro === null || filterPro === void 0 ? void 0 : filterPro.map((i) => (React.createElement(React.Fragment, { key: i.name }, renderProp(i))))) }),
|
|
21
|
+
React.createElement(Row, null,
|
|
22
|
+
React.createElement(Col, { span: 10 }, "Identity:"),
|
|
23
|
+
React.createElement(Col, { span: 14 },
|
|
24
|
+
React.createElement(IdentifyProperties, { identityId: (_a = officer.identity) === null || _a === void 0 ? void 0 : _a.id, concatId: officer.contact.id, officerId: id, allowEdit: allowEdit }))),
|
|
25
|
+
React.createElement(ContactProperties, { fromLabelRequired: true, id: (_b = officer === null || officer === void 0 ? void 0 : officer.contact) === null || _b === void 0 ? void 0 : _b.id, labelCol: 10, wrapperCol: 14, title: orgContactTitle, customProperties: orgContactProperties }))));
|
|
26
|
+
});
|
|
27
|
+
function renderProp(item) {
|
|
28
|
+
switch (item.name) {
|
|
29
|
+
case "Status":
|
|
30
|
+
return (officer.status && (React.createElement(Form.Item, { label: "Status" }, officer.status === "Present" ? (React.createElement(Badge, { status: "success", text: "Present" })) : (React.createElement(Badge, { status: "error", text: "Past" })))));
|
|
31
|
+
case "Appointment Date":
|
|
32
|
+
return (React.createElement(Form.Item, { label: "Appointment Date" },
|
|
33
|
+
React.createElement(InlineEdit, { defaultValue: dayjs((officer === null || officer === void 0 ? void 0 : officer.appointment) !== "" ? officer === null || officer === void 0 ? void 0 : officer.appointment : undefined), content: (v) => (officer === null || officer === void 0 ? void 0 : officer.appointment) ? (React.createElement("span", null, dayjs(officer === null || officer === void 0 ? void 0 : officer.appointment).format("YYYY-MM-DD"))) : (React.createElement("span", { className: "add-info-style" }, allowEdit ? "Add Appointment Date" : "No Appointment Date")), editor: DateInputEditor, editable: allowEdit, onSave: (date) => {
|
|
34
|
+
if ((officer === null || officer === void 0 ? void 0 : officer.appointment) && dayjs(date).isSame(officer === null || officer === void 0 ? void 0 : officer.appointment, "day"))
|
|
35
|
+
return;
|
|
36
|
+
edit({
|
|
37
|
+
Appointment: (date !== null ? dayjs(date).format("YYYY-MM-DD") : ""),
|
|
38
|
+
});
|
|
39
|
+
} })));
|
|
40
|
+
case "Cease Date":
|
|
41
|
+
return (React.createElement(Form.Item, { label: "Cease Date" },
|
|
42
|
+
React.createElement(InlineEdit, { defaultValue: dayjs((officer === null || officer === void 0 ? void 0 : officer.cease) !== "" ? officer === null || officer === void 0 ? void 0 : officer.cease : undefined), content: (v) => (officer === null || officer === void 0 ? void 0 : officer.cease) ? (React.createElement("span", null, dayjs(officer === null || officer === void 0 ? void 0 : officer.cease).format("YYYY-MM-DD"))) : (React.createElement("span", { className: "add-info-style" }, allowEdit ? "Add Cease Date" : "No Cease Date")), editor: DateInputEditor, editable: allowEdit, onSave: (date) => {
|
|
43
|
+
if ((officer === null || officer === void 0 ? void 0 : officer.cease) && dayjs(date).isSame(officer === null || officer === void 0 ? void 0 : officer.cease, "day"))
|
|
44
|
+
return;
|
|
45
|
+
edit({ Cease: (date !== null ? dayjs(date).format("YYYY-MM-DD") : "") });
|
|
46
|
+
} })));
|
|
47
|
+
case "Email":
|
|
48
|
+
return (React.createElement(Form.Item, { label: "Email" },
|
|
49
|
+
React.createElement(InlineEdit, { defaultValue: officer.email, content: (v) => officer.email ? (React.createElement("span", null, officer.email)) : (React.createElement("span", { className: "add-info-style" }, "Add Email")), onSave: (value) => store.edit(id, { data: { Email: value }, error: "message" }) })));
|
|
50
|
+
case "Phone":
|
|
51
|
+
return (React.createElement(Form.Item, { label: "Phone" },
|
|
52
|
+
React.createElement(InlineEdit, { defaultValue: officer.phone, content: (v) => officer.phone ? (React.createElement("span", null, officer.phone)) : (React.createElement("span", { className: "add-info-style" }, "Add Phone")), onSave: (value) => store.edit(id, { data: { Phone: value }, error: "message" }) })));
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
async function edit(data) {
|
|
56
|
+
await store.edit(id, { data, error: "message" });
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
OfficerProperties.defaultProps = {
|
|
60
|
+
officerTitle: "Officer Properties",
|
|
61
|
+
orgContactTitle: "Contact Properties",
|
|
62
|
+
officerProperties: [
|
|
63
|
+
{ name: "Status" },
|
|
64
|
+
{ name: "Appointment Date" },
|
|
65
|
+
{ name: "Cease Date" },
|
|
66
|
+
{ name: "Email" },
|
|
67
|
+
{ name: "Phone" },
|
|
68
|
+
],
|
|
69
|
+
};
|
|
70
|
+
export default OfficerProperties;
|
|
71
|
+
//# sourceMappingURL=index.js.map
|
package/es/modules/corporate/company/officer-register/components/OfficerProperties/index.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/modules/corporate/company/officer-register/components/OfficerProperties/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAEN,UAAU,EACV,eAAe,GACf,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,MAAM,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,iBAAiB,MAAM,iDAAiD,CAAC;AAChF,OAAO,iBAAiB,MAAM,oDAAoD,CAAC;AACnF,OAAO,kBAAkB,MAAM,iDAAiD,CAAC;AACjF,OAAO,eAAe,MAAM,kEAAkE,CAAC;AAC/F,OAAO,KAAK,MAAM,OAAO,CAAC;AAS1B,MAAM,iBAAiB,GAAG,CAAC,KAc1B,EAAE,EAAE;IACJ,MAAM,EAAE,EAAE,EAAE,SAAS,EAAE,YAAY,EAAE,eAAe,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,GAC9F,KAAK,CAAC;IAEP,MAAM,OAAO,GAAG,UAAU,CAAC,EAAE,CAAC,CAAC;IAC/B,MAAM,KAAK,GAAG,eAAe,EAAE,CAAC;IAEhC,MAAM,SAAS,GAAG,iBAAiB,aAAjB,iBAAiB,uBAAjB,iBAAiB,CAAE,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAA,CAAC,aAAD,CAAC,uBAAD,CAAC,CAAE,OAAO,MAAK,KAAK,CAAC,CAAC;IAEzE,OAAO,OAAO,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