diff --git a/products/ASC.People/Client/src/components/pages/Profile/Section/Body/index.js b/products/ASC.People/Client/src/components/pages/Profile/Section/Body/index.js index f8b8fc53cf..e5deee5dc5 100644 --- a/products/ASC.People/Client/src/components/pages/Profile/Section/Body/index.js +++ b/products/ASC.People/Client/src/components/pages/Profile/Section/Body/index.js @@ -125,7 +125,15 @@ const createContacts = (contacts) => { const SectionBodyContent = (props) => { const { profile, history, isSelf, settings } = props; + //console.log(profile, settings); const contacts = profile.contacts && getContacts(profile.contacts); + const role = getUserRole(profile); + const workFrom = getFormattedDate(profile.workFrom); + const birthDay = getFormattedDate(profile.birthday); + const formatedSex = capitalizeFirstLetter(profile.sex); + const formatedDepartments = getFormattedDepartments(profile.department); + const socialContacts = contacts && createContacts(contacts.social); + const infoContacts = contacts && createContacts(contacts.contact); const onEmailClick = useCallback( () => window.open('mailto:' + profile.email), @@ -147,17 +155,10 @@ const SectionBodyContent = (props) => { [history, settings.homepage, profile.userName] ); - console.log(profile); - return (
- +
@@ -176,15 +177,20 @@ const SectionBodyContent = (props) => {
{profile.isVisitor ? "Guest" : "Employee"} - {profile.email}{profile.activationStatus === 2 && ' (Pending)'} - {getFormattedDepartments(profile.department)} + + + {profile.email} + + {profile.activationStatus === 2 && ' (Pending)'} + + {formatedDepartments} {profile.title} {profile.mobilePhone} - {capitalizeFirstLetter(profile.sex)} - {getFormattedDate(profile.workFrom)} - {getFormattedDate(profile.birthday)} + {formatedSex} + {workFrom} + {birthDay} {profile.location} - {isSelf && {profile.cultureName}} + {isSelf && {profile.cultureName || settings.currentCulture}} {isSelf &&
@@ -223,7 +229,7 @@ const SectionBodyContent = (props) => {
- {createContacts(contacts.contact)} + {infoContacts}
@@ -232,7 +238,7 @@ const SectionBodyContent = (props) => {
- {createContacts(contacts.social)} + {socialContacts}