Skip to content
This repository was archived by the owner on Oct 4, 2023. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions booking.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
* Display a booking tab listing booking belong to that contact.
*/
function booking_civicrm_tabset($tabsetName, &$tabs, $context) {
if ($tabsetName === 'civicrm/contact/view' && !empty($context['contact_id'])) {
if ($tabsetName === 'civicrm/contact/view') {
$cid = $context['contact_id'];
$count = CRM_Booking_BAO_Booking::getBookingContactCount($cid); //TODO Count number of booking and show on the tab
$count = CRM_Booking_BAO_Booking::getBookingContactCount($cid);
$tab = [
'id' => 'booking',
'count' => $count,
Expand Down