Hide Add Credit button in Client Top Head Dropdown also hide credits in client listing if no credit balance
This commit is contained in:
@@ -566,10 +566,12 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
|
|||||||
<span class="text-secondary">Paid</span>
|
<span class="text-secondary">Paid</span>
|
||||||
<span><?php echo numfmt_format_currency($currency_format, $amount_paid, $session_company_currency); ?></span>
|
<span><?php echo numfmt_format_currency($currency_format, $amount_paid, $session_company_currency); ?></span>
|
||||||
</div>
|
</div>
|
||||||
|
<?php if ($credit_balance > 0) { ?>
|
||||||
<div class="d-flex justify-content-between">
|
<div class="d-flex justify-content-between">
|
||||||
<span class="text-secondary">Credit</span>
|
<span class="text-secondary">Credit</span>
|
||||||
<span class="text-success"><?php echo numfmt_format_currency($currency_format, $credit_balance, $session_company_currency); ?></span>
|
<span class="text-success"><?php echo numfmt_format_currency($currency_format, $credit_balance, $session_company_currency); ?></span>
|
||||||
</div>
|
</div>
|
||||||
|
<?php } ?>
|
||||||
<div class="d-flex justify-content-between">
|
<div class="d-flex justify-content-between">
|
||||||
<span class="text-secondary">Monthly</span>
|
<span class="text-secondary">Monthly</span>
|
||||||
<span><?php echo numfmt_format_currency($currency_format, $recurring_monthly, $session_company_currency); ?></span>
|
<span><?php echo numfmt_format_currency($currency_format, $recurring_monthly, $session_company_currency); ?></span>
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
|
<?php $show_add_credit = 0; // Remove once credits is added hides the button ?>
|
||||||
|
|
||||||
<div class="card d-print-none">
|
<div class="card d-print-none">
|
||||||
<div class="card-header pb-1 pt-2 px-3">
|
<div class="card-header pb-1 pt-2 px-3">
|
||||||
<div class="card-title">
|
<div class="card-title">
|
||||||
@@ -16,10 +18,12 @@
|
|||||||
<i class="fas fa-fw fa-edit mr-2"></i>Edit Client
|
<i class="fas fa-fw fa-edit mr-2"></i>Edit Client
|
||||||
</a>
|
</a>
|
||||||
<?php if (lookupUserPermission("module_billing") >= 2) { ?>
|
<?php if (lookupUserPermission("module_billing") >= 2) { ?>
|
||||||
|
<?php if ($show_add_credit) { ?>
|
||||||
<div class="dropdown-divider"></div>
|
<div class="dropdown-divider"></div>
|
||||||
<a class="dropdown-item" href="#" data-toggle="modal" data-target="#addCreditModal">
|
<a class="dropdown-item" href="#" data-toggle="modal" data-target="#addCreditModal">
|
||||||
<i class="fas fa-fw fa-wallet mr-2"></i>Add Credit
|
<i class="fas fa-fw fa-wallet mr-2"></i>Add Credit
|
||||||
</a>
|
</a>
|
||||||
|
<?php } ?>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
<?php if (lookupUserPermission("module_client") >= 3) { ?>
|
<?php if (lookupUserPermission("module_client") >= 3) { ?>
|
||||||
<div class="dropdown-divider"></div>
|
<div class="dropdown-divider"></div>
|
||||||
|
|||||||
Reference in New Issue
Block a user