mirror of https://github.com/itflow-org/itflow
Show number of services in nav bar
This commit is contained in:
parent
5c33a18b80
commit
f48ae8c804
|
|
@ -99,6 +99,9 @@ if(isset($_GET['client_id'])){
|
|||
|
||||
$row = mysqli_fetch_assoc(mysqli_query($mysqli,"SELECT COUNT('ticket_id') AS num FROM tickets WHERE ticket_archived_at IS NULL AND ticket_status = 'Open' AND ticket_client_id = $client_id"));
|
||||
$num_open_tickets = $row['num'];
|
||||
|
||||
$row = mysqli_fetch_assoc(mysqli_query($mysqli,"SELECT COUNT('service_id') AS num FROM services WHERE service_client_id = $client_id"));
|
||||
$num_services = $row['num'];
|
||||
|
||||
$row = mysqli_fetch_assoc(mysqli_query($mysqli,"SELECT COUNT('vendor_id') AS num FROM vendors WHERE vendor_archived_at IS NULL AND vendor_client_id = $client_id"));
|
||||
$num_vendors = $row['num'];
|
||||
|
|
|
|||
|
|
@ -147,8 +147,8 @@
|
|||
<p>
|
||||
Services
|
||||
<?php
|
||||
if($num_assets > 0){ ?>
|
||||
<span class="right badge badge-light">3<?php //echo $num_assets; ?></span>
|
||||
if($num_services > 0){ ?>
|
||||
<span class="right badge badge-light"><?php echo $num_services; ?></span>
|
||||
<?php } ?>
|
||||
</p>
|
||||
</a>
|
||||
|
|
|
|||
Loading…
Reference in New Issue