@@ -21,6 +21,7 @@ import LoadingOrErrorPage from '@condo/domains/common/components/containers/Load
2121import { DeleteButtonWithConfirmModal } from '@condo/domains/common/components/DeleteButtonWithConfirmModal'
2222import { FieldPairRow as BaseFieldPairRow , FieldPairRowProps } from '@condo/domains/common/components/FieldPairRow'
2323import { FrontLayerContainer } from '@condo/domains/common/components/FrontLayerContainer'
24+ import { LabelWithInfo } from '@condo/domains/common/components/LabelWithInfo'
2425import { TicketCardList } from '@condo/domains/common/components/TicketCard/TicketCardList'
2526import { PageComponentType } from '@condo/domains/common/types'
2627import { ContactsReadPermissionRequired } from '@condo/domains/contact/components/PageAccess'
@@ -49,11 +50,7 @@ export const ContactPageContent = ({ contact, isContactEditable, softDeleteActio
4950} ) => {
5051 const intl = useIntl ( )
5152
52- const {
53- loading : customValuesLoading ,
54- error : customValuesError ,
55- customValues,
56- } = useCustomValues ( {
53+ const { customValues } = useCustomValues ( {
5754 modelName : CustomFieldModelNameType . Contact ,
5855 objectId : contact ?. id || '' ,
5956 skip : ! contact ?. id ,
@@ -68,6 +65,8 @@ export const ContactPageContent = ({ contact, isContactEditable, softDeleteActio
6865 const ConfirmDeleteTitle = intl . formatMessage ( { id : 'contact.ConfirmDeleteTitle' } )
6966 const ConfirmDeleteMessage = intl . formatMessage ( { id : 'contact.ConfirmDeleteMessage' } )
7067 const ContactRoleTitle = intl . formatMessage ( { id : 'ContactRole' } )
68+ const NoteLabel = intl . formatMessage ( { id : 'Note' } )
69+ const NoteVisibilityHint = intl . formatMessage ( { id : 'contact.note.visibility.hint' } )
7170 const VerifiedMessage = intl . formatMessage ( { id : 'pages.condo.contact.Verified' } )
7271 const HasResident = intl . formatMessage ( { id : 'pages.condo.contact.HasResident' } )
7372 const ResidentRegistred = intl . formatMessage ( { id : 'pages.condo.contact.ResidentRegistered' } )
@@ -83,6 +82,7 @@ export const ContactPageContent = ({ contact, isContactEditable, softDeleteActio
8382 const unitSuffix = useMemo ( ( ) => contactUnitName ? `${ UnitTypeMessage . toLowerCase ( ) } ${ contactUnitName } ` : '' , [ UnitTypeMessage , contactUnitName ] )
8483 const contactAddress = useMemo ( ( ) => `${ contact ?. property ?. address ?? DeletedMessage } ${ unitSuffix } ` , [ contact , DeletedMessage , unitSuffix ] )
8584 const contactRoleName = useMemo ( ( ) => contact ?. role ?. name ?? '—' , [ contact ] )
85+ const contactNote = useMemo ( ( ) => contact ?. note ?. trim ( ) || '—' , [ contact ] )
8686 const isVerified = useMemo ( ( ) => contact ?. isVerified , [ contact ] )
8787 const hasResident = useMemo ( ( ) => contact ?. hasResident , [ contact ] )
8888 const phonePrefix = useMemo ( ( ) => organizationPhonePrefix ?? '' , [ organizationPhonePrefix ] )
@@ -124,6 +124,18 @@ export const ContactPageContent = ({ contact, isContactEditable, softDeleteActio
124124 fieldTitle = { ContactRoleTitle }
125125 fieldValue = { contactRoleName }
126126 />
127+ < >
128+ < Col { ...CONTACT_FIELD_PAIR_PROPS . titleColProps } >
129+ < Typography . Text type = 'secondary' >
130+ < LabelWithInfo title = { NoteVisibilityHint } message = { NoteLabel } />
131+ </ Typography . Text >
132+ </ Col >
133+ < Col { ...CONTACT_FIELD_PAIR_PROPS . valueColProps } >
134+ < Typography . Text >
135+ { contactNote }
136+ </ Typography . Text >
137+ </ Col >
138+ </ >
127139 < >
128140 < Col span = { 8 } >
129141 < Typography . Text type = 'secondary' >
0 commit comments