Hide tasks invoice line item table if module is disabled

This commit is contained in:
Hillel Coren 2017-06-29 17:39:10 +03:00
parent 13c83c5d11
commit 7f8f1b414b
2 changed files with 5 additions and 1 deletions

View File

@ -1593,6 +1593,7 @@ class Account extends Eloquent
return true;
}
// note: single & checks bitmask match
return $this->enabled_modules & static::$modules[$entityType];
}

View File

@ -254,7 +254,10 @@
<table class="table invoice-table">
@include('invoices.edit_table', ['isTasks' => false])
@include('invoices.edit_table', ['isTasks' => true])
@if ($account->isModuleEnabled(ENTITY_TASK))
@include('invoices.edit_table', ['isTasks' => true])
@endif
<tfoot>
<tr>