Files
FinanceBuddy/Template/board/column_dropdown.php

18 lines
1.0 KiB
PHP

<?php if ($this->FinanceHelper->isEnabled($column['project_id']) && $this->user->hasProjectAccess('ProjectEditController', 'edit', $column['project_id'])): ?>
<?php /* Rendered here (outside the menu <ul>) by the only column-menu hook, then moved into the
column's real dropdown <ul> by Asset/js/relocate.js so it sits next to the native
entries. Hidden until relocated to avoid a flash in the header. */ ?>
<?php $hidden = $this->FinanceHelper->isTotalHidden($column['project_id'], $column['id']); ?>
<li class="financebuddy-menu-item" style="display: none;">
<?= $this->url->link(
$hidden
? '<i class="fa fa-eye fa-fw"></i> '.t('Show column total')
: '<i class="fa fa-eye-slash fa-fw"></i> '.t('Hide column total'),
'FinanceColumnController',
'toggleTotal',
array('plugin' => 'FinanceBuddy', 'project_id' => $column['project_id'], 'column_id' => $column['id']),
true
) ?>
</li>
<?php endif ?>