Add custom filters (refactoring of pull-request #1312)
This commit is contained in:
@@ -2,6 +2,10 @@
|
||||
<i class="fa fa-dashboard fa-fw"></i>
|
||||
<?= $this->url->link(t('Activity'), 'activity', 'project', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
<li>
|
||||
<i class="fa fa-filter fa-fw"></i>
|
||||
<?= $this->url->link(t('Custom filters'), 'customfilter', 'index', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
|
||||
<?php if ($project['is_public']): ?>
|
||||
<li>
|
||||
|
||||
@@ -86,5 +86,16 @@
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if (isset($custom_filters_list) && ! empty($custom_filters_list)): ?>
|
||||
<div class="dropdown filters">
|
||||
<i class="fa fa-caret-down"></i> <a href="#" class="dropdown-menu"><?= t('My filters') ?></a>
|
||||
<ul>
|
||||
<?php foreach ($custom_filters_list as $filter): ?>
|
||||
<li><a href="#" class="filter-helper" data-filter='<?= $this->e($filter['filter']) ?>'><?= $this->e($filter['name']) ?></a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -4,6 +4,9 @@
|
||||
<li <?= $this->app->getRouterAction() === 'show' ? 'class="active"' : '' ?>>
|
||||
<?= $this->url->link(t('Summary'), 'project', 'show', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
<li <?= $this->app->getRouterController() === 'customfilter' && $this->app->getRouterAction() === 'index' ? 'class="active"' : '' ?>>
|
||||
<?= $this->url->link(t('Custom filters'), 'customfilter', 'index', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
|
||||
<?php if ($this->user->isProjectManagementAllowed($project['id'])): ?>
|
||||
<li <?= $this->app->getRouterController() === 'project' && $this->app->getRouterAction() === 'share' ? 'class="active"' : '' ?>>
|
||||
|
||||
Reference in New Issue
Block a user