diff --git a/src/components/Directory/ListViewDirectory.jsx b/src/components/Directory/ListViewDirectory.jsx index b3261563..2258fb5b 100644 --- a/src/components/Directory/ListViewDirectory.jsx +++ b/src/components/Directory/ListViewDirectory.jsx @@ -5,73 +5,69 @@ import { getEmailIcon,getPhoneIcon } from './DirectoryUtils'; const ListViewDirectory = ({IsActive, contact,setSelectedContact,setIsOpenModal,setOpen_contact,setIsOpenModalNote,IsDeleted}) => { return ( - - - { - if ( IsActive ) - { - setIsOpenModalNote(true) - setOpen_contact(contact) - } - }}> -
- + + { + if (IsActive) { + setIsOpenModalNote(true); + setOpen_contact(contact); + } + }}> +
+ + {contact?.name || ""} +
+ - {contact?.name || ""} -
+ +
+ {contact.contactEmails?.map((email, index) => ( + + + {email.emailAddress} + + ))} +
+ + +
+ {contact.contactPhones?.map((phone, index) => ( + + + {phone.phoneNumber} + + ))} +
+ - + + {contact.organization} + - {/* Emails */} - -
- {contact.contactEmails?.map((email, index) => ( - - - {email.emailAddress} - - ))} -
- + + + {contact?.contactCategory?.name} + + - -
- {contact.contactPhones?.map((phone, index) => ( - - - {phone.phoneNumber} - - ))} -
- + {IsActive && ( + + { + setSelectedContact(contact); + setIsOpenModal(true); + }}> + IsDeleted(contact.id)}> + + )} + - - {contact.organization} - - - -
- {contact?.contactCategory?.name } -
- - - {/* Actions */} - {IsActive && - - - { - setSelectedContact( contact ) - setIsOpenModal( true ) - }}> - IsDeleted( contact.id )}> - - } - ); };