mirror of
https://github.com/itflow-org/itflow
synced 2026-03-03 04:14:54 +00:00
Show Red Badge Count next to client domains if Domain is expired or expires within 5 days
This commit is contained in:
@@ -203,7 +203,7 @@
|
|||||||
|
|
||||||
<?php
|
<?php
|
||||||
if ($num_domains > 0) { ?>
|
if ($num_domains > 0) { ?>
|
||||||
<span class="right badge <?php if ($num_domains_expiring > 0) { ?> badge-warning text-dark<?php } ?> text-light"><?php echo $num_domains; ?></span>
|
<span class="right badge <?php if ($num_domains_expiring > 0) { ?> badge-warning text-dark<?php } ?> <?php if ($num_domains_expired > 0) { ?> badge-danger <?php } ?> text-white"><?php echo $num_domains; ?></span>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
</p>
|
</p>
|
||||||
</a>
|
</a>
|
||||||
|
|||||||
@@ -223,6 +223,20 @@ if (isset($_GET['client_id'])) {
|
|||||||
));
|
));
|
||||||
$num_domains_expiring = intval($row['num']);
|
$num_domains_expiring = intval($row['num']);
|
||||||
|
|
||||||
|
// Count Domains Expired or within 5 days
|
||||||
|
$row = mysqli_fetch_assoc(mysqli_query(
|
||||||
|
$mysqli,
|
||||||
|
"SELECT COUNT('domain_id') AS num FROM domains
|
||||||
|
WHERE domain_client_id = $client_id
|
||||||
|
AND domain_expire IS NOT NULL
|
||||||
|
AND (
|
||||||
|
domain_expire < CURRENT_DATE
|
||||||
|
OR domain_expire < CURRENT_DATE + INTERVAL 5 DAY
|
||||||
|
)
|
||||||
|
AND domain_archived_at IS NULL"
|
||||||
|
));
|
||||||
|
$num_domains_expired = intval($row['num']);
|
||||||
|
|
||||||
// Count Certificates Expiring within 30 Days
|
// Count Certificates Expiring within 30 Days
|
||||||
$row = mysqli_fetch_assoc(mysqli_query(
|
$row = mysqli_fetch_assoc(mysqli_query(
|
||||||
$mysqli,
|
$mysqli,
|
||||||
|
|||||||
Reference in New Issue
Block a user