diff --git a/client_contact_details.php b/client_contact_details.php index 97d44331..2685a3a3 100644 --- a/client_contact_details.php +++ b/client_contact_details.php @@ -98,6 +98,16 @@ if (isset($_GET['contact_id'])) { $sql_related_notes = mysqli_query($mysqli, "SELECT * FROM contact_notes LEFT JOIN users ON contact_note_created_by = user_id WHERE contact_note_contact_id = $contact_id AND contact_note_archived_at IS NULL ORDER BY contact_note_created_at DESC"); $note_count = mysqli_num_rows($sql_related_notes); + // Linked Services + $sql_linked_services = mysqli_query($mysqli, "SELECT * FROM service_contacts, services + WHERE service_contacts.contact_id = $contact_id + AND service_contacts.service_id = services.service_id + ORDER BY service_name ASC" + ); + $service_count = mysqli_num_rows($sql_linked_services); + + $linked_services = array(); + // Linked Documents $sql_linked_documents = mysqli_query($mysqli, "SELECT * FROM contact_documents, documents LEFT JOIN users ON document_created_by = user_id @@ -240,7 +250,7 @@ if (isset($_GET['contact_id'])) { Credential
- + Service @@ -696,6 +706,64 @@ if (isset($_GET['contact_id'])) { +