diff options
Diffstat (limited to 'app')
45 files changed, 141 insertions, 184 deletions
diff --git a/app/Helper/ModalHelper.php b/app/Helper/ModalHelper.php index e6037a8c..b3241b9d 100644 --- a/app/Helper/ModalHelper.php +++ b/app/Helper/ModalHelper.php @@ -43,31 +43,36 @@ class ModalHelper extends Base public function large($icon, $label, $controller, $action, array $params = array()) { - $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-large" aria-hidden="true"></i> '.$label; + $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-large" aria-hidden="true"></i>'.$label; return $this->helper->url->link($html, $controller, $action, $params, false, 'js-modal-large'); } public function medium($icon, $label, $controller, $action, array $params = array()) { - $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-medium" aria-hidden="true"></i> '.$label; + $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-medium" aria-hidden="true"></i>'.$label; return $this->helper->url->link($html, $controller, $action, $params, false, 'js-modal-medium'); } public function small($icon, $label, $controller, $action, array $params = array()) { - $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-small" aria-hidden="true"></i> '.$label; + $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-small" aria-hidden="true"></i>'.$label; return $this->helper->url->link($html, $controller, $action, $params, false, 'js-modal-small'); } public function mediumButton($icon, $label, $controller, $action, array $params = array()) { - $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-medium" aria-hidden="true"></i> '.$label; + $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-medium" aria-hidden="true"></i>'.$label; return $this->helper->url->link($html, $controller, $action, $params, false, 'js-modal-medium btn'); } public function confirm($icon, $label, $controller, $action, array $params = array()) { - $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-confirm" aria-hidden="true"></i> '.$label; + $html = '<i class="fa fa-'.$icon.' fa-fw js-modal-confirm" aria-hidden="true"></i>'.$label; return $this->helper->url->link($html, $controller, $action, $params, false, 'js-modal-confirm'); } + + public function confirmLink($label, $controller, $action, array $params = array()) + { + return $this->helper->url->link($label, $controller, $action, $params, false, 'js-modal-confirm'); + } } diff --git a/app/Helper/UrlHelper.php b/app/Helper/UrlHelper.php index bfcf07e6..94412cf5 100644 --- a/app/Helper/UrlHelper.php +++ b/app/Helper/UrlHelper.php @@ -48,6 +48,29 @@ class UrlHelper extends Base } /** + * Link element with icon + * + * @access public + * @param string $icon Icon name + * @param string $label Link label + * @param string $controller Controller name + * @param string $action Action name + * @param array $params Url parameters + * @param boolean $csrf Add a CSRF token + * @param string $class CSS class attribute + * @param string $title Link title + * @param boolean $newTab Open the link in a new tab + * @param string $anchor Link Anchor + * @param bool $absolute + * @return string + */ + public function icon($icon, $label, $controller, $action, array $params = array(), $csrf = false, $class = '', $title = '', $newTab = false, $anchor = '', $absolute = false) + { + $html = '<i class="fa fa-fw fa-'.$icon.'" aria-hidden="true"></i>'.$label; + return $this->helper->url->link($html, $controller, $action, $params, $csrf, $class, $title, $newTab, $anchor, $absolute); + } + + /** * Link element * * @access public @@ -58,14 +81,14 @@ class UrlHelper extends Base * @param boolean $csrf Add a CSRF token * @param string $class CSS class attribute * @param string $title Link title - * @param boolean $new_tab Open the link in a new tab + * @param boolean $newTab Open the link in a new tab * @param string $anchor Link Anchor * @param bool $absolute * @return string */ - public function link($label, $controller, $action, array $params = array(), $csrf = false, $class = '', $title = '', $new_tab = false, $anchor = '', $absolute = false) + public function link($label, $controller, $action, array $params = array(), $csrf = false, $class = '', $title = '', $newTab = false, $anchor = '', $absolute = false) { - return '<a href="'.$this->href($controller, $action, $params, $csrf, $anchor, $absolute).'" class="'.$class.'" title=\''.$title.'\' '.($new_tab ? 'target="_blank"' : '').'>'.$label.'</a>'; + return '<a href="'.$this->href($controller, $action, $params, $csrf, $anchor, $absolute).'" class="'.$class.'" title=\''.$title.'\' '.($newTab ? 'target="_blank"' : '').'>'.$label.'</a>'; } /** diff --git a/app/Template/activity/project.php b/app/Template/activity/project.php index e8e62777..6d1e4a2e 100644 --- a/app/Template/activity/project.php +++ b/app/Template/activity/project.php @@ -2,10 +2,10 @@ <?= $this->projectHeader->render($project, 'ActivityController', $this->app->getRouterAction()) ?> <?php if ($project['is_public']): ?> - <div class="menu-inline pull-right"> + <div class="menu-inline"> <ul> - <li><i class="fa fa-rss-square fa-fw"></i><?= $this->url->link(t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> - <li><i class="fa fa-calendar fa-fw"></i><?= $this->url->link(t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> + <li><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> + <li><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> </ul> </div> <?php endif ?> diff --git a/app/Template/board/tooltip_files.php b/app/Template/board/tooltip_files.php index a372b1a0..5cb72741 100644 --- a/app/Template/board/tooltip_files.php +++ b/app/Template/board/tooltip_files.php @@ -9,7 +9,7 @@ </tr> <tr> <td> - <i class="fa fa-download fa-fw"></i><?= $this->url->link(t('download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> + <?= $this->url->icon('download', t('download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> <?php if ($file['is_image'] == 1): ?> <?= $this->modal->large('eye', t('open file'), 'FileViewerController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> <?php endif ?> diff --git a/app/Template/comments/show.php b/app/Template/comments/show.php index dfc13821..3edf7076 100644 --- a/app/Template/comments/show.php +++ b/app/Template/comments/show.php @@ -6,8 +6,7 @@ <?php if (!isset($is_public) || !$is_public): ?> <div class="comment-sorting"> <small> - <i class="fa fa-sort"></i> - <?= $this->url->link(t('change sorting'), 'CommentController', 'toggleSorting', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('sort', t('change sorting'), 'CommentController', 'toggleSorting', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </small> </div> <?php endif ?> diff --git a/app/Template/dashboard/layout.php b/app/Template/dashboard/layout.php index d5a2695c..15ab8a1a 100644 --- a/app/Template/dashboard/layout.php +++ b/app/Template/dashboard/layout.php @@ -12,12 +12,10 @@ </li> <?php endif ?> <li> - <i class="fa fa-search fa-fw"></i> - <?= $this->url->link(t('Search'), 'SearchController', 'index') ?> + <?= $this->url->icon('search', t('Search'), 'SearchController', 'index') ?> </li> <li> - <i class="fa fa-folder fa-fw"></i> - <?= $this->url->link(t('Project management'), 'ProjectListController', 'show') ?> + <?= $this->url->icon('folder', t('Project management'), 'ProjectListController', 'show') ?> </li> </ul> </div> diff --git a/app/Template/dashboard/notifications.php b/app/Template/dashboard/notifications.php index 4fb59e24..81adb348 100644 --- a/app/Template/dashboard/notifications.php +++ b/app/Template/dashboard/notifications.php @@ -7,8 +7,7 @@ <?php else: ?> <ul> <li> - <i class="fa fa-check-square-o fa-fw"></i> - <?= $this->url->link(t('Mark all as read'), 'WebNotificationController', 'flush', array('user_id' => $user['id'])) ?> + <?= $this->url->icon('check-square-o', t('Mark all as read'), 'WebNotificationController', 'flush', array('user_id' => $user['id'])) ?> </li> </ul> </div> @@ -60,8 +59,7 @@ <?= $this->dt->datetime($notification['date_creation']) ?> </td> <td> - <i class="fa fa-check fa-fw"></i> - <?= $this->url->link(t('Mark as read'), 'WebNotificationController', 'remove', array('user_id' => $user['id'], 'notification_id' => $notification['id'])) ?> + <?= $this->url->icon('check', t('Mark as read'), 'WebNotificationController', 'remove', array('user_id' => $user['id'], 'notification_id' => $notification['id'])) ?> </td> </tr> <?php endforeach ?> diff --git a/app/Template/doc/show.php b/app/Template/doc/show.php index a8dbd762..879e45b6 100644 --- a/app/Template/doc/show.php +++ b/app/Template/doc/show.php @@ -2,8 +2,7 @@ <div class="page-header"> <ul> <li> - <i class="fa fa-life-ring fa-fw"></i> - <?= $this->url->link(t('Table of contents'), 'DocumentationController', 'show', array('file' => 'index')) ?> + <?= $this->url->icon('life-ring', t('Table of contents'), 'DocumentationController', 'show', array('file' => 'index')) ?> </li> </ul> </div> diff --git a/app/Template/group/index.php b/app/Template/group/index.php index 8001393b..fe3f398e 100644 --- a/app/Template/group/index.php +++ b/app/Template/group/index.php @@ -1,14 +1,14 @@ <section id="main"> <div class="page-header"> <ul> - <li><i class="fa fa-user fa-fw"></i><?= $this->url->link(t('All users'), 'UserListController', 'show') ?></li> + <li><?= $this->url->icon('user', t('All users'), 'UserListController', 'show') ?></li> <li><?= $this->modal->medium('user-plus', t('New group'), 'GroupCreationController', 'show') ?></li> </ul> </div> <?php if ($paginator->isEmpty()): ?> <p class="alert"><?= t('There is no group.') ?></p> <?php else: ?> - <table class="table-small table-fixed table-scrolling"> + <table class="table-fixed table-scrolling"> <tr> <th class="column-5"><?= $paginator->order(t('Id'), 'id') ?></th> <th class="column-20"><?= $paginator->order(t('External Id'), 'external_id') ?></th> @@ -31,7 +31,7 @@ <a href="#" class="dropdown-menu dropdown-menu-link-icon"><i class="fa fa-cog fa-fw"></i><i class="fa fa-caret-down"></i></a> <ul> <li><?= $this->modal->medium('plus', t('Add group member'), 'GroupListController', 'associate', array('group_id' => $group['id'])) ?></li> - <li><i class="fa fa-users fa-fw"></i> <?= $this->url->link(t('Members'), 'GroupListController', 'users', array('group_id' => $group['id'])) ?></li> + <li><?= $this->url->icon('users', t('Members'), 'GroupListController', 'users', array('group_id' => $group['id'])) ?></li> <li><?= $this->modal->medium('edit', t('Edit'), 'GroupModificationController', 'show', array('group_id' => $group['id'])) ?></li> <li><?= $this->modal->confirm('trash-o', t('Remove'), 'GroupListController', 'confirm', array('group_id' => $group['id'])) ?></li> </ul> diff --git a/app/Template/group/users.php b/app/Template/group/users.php index e9f2b361..ef179674 100644 --- a/app/Template/group/users.php +++ b/app/Template/group/users.php @@ -1,7 +1,7 @@ <section id="main"> <div class="page-header"> <ul> - <li><i class="fa fa-users fa-fw"></i><?= $this->url->link(t('View all groups'), 'GroupListController', 'index') ?></li> + <li><?= $this->url->icon('users', t('View all groups'), 'GroupListController', 'index') ?></li> <li><?= $this->modal->medium('plus', t('Add group member'), 'GroupListController', 'associate', array('group_id' => $group['id'])) ?></li> </ul> </div> diff --git a/app/Template/header/user_dropdown.php b/app/Template/header/user_dropdown.php index 49d08213..a74bdd52 100644 --- a/app/Template/header/user_dropdown.php +++ b/app/Template/header/user_dropdown.php @@ -3,46 +3,37 @@ <ul> <li class="no-hover"><strong><?= $this->text->e($this->user->getFullname()) ?></strong></li> <li> - <i class="fa fa-tachometer fa-fw"></i> - <?= $this->url->link(t('My dashboard'), 'DashboardController', 'show', array('user_id' => $this->user->getId())) ?> + <?= $this->url->icon('tachometer', t('My dashboard'), 'DashboardController', 'show', array('user_id' => $this->user->getId())) ?> </li> <li> - <i class="fa fa-home fa-fw"></i> - <?= $this->url->link(t('My profile'), 'UserViewController', 'show', array('user_id' => $this->user->getId())) ?> + <?= $this->url->icon('home', t('My profile'), 'UserViewController', 'show', array('user_id' => $this->user->getId())) ?> </li> <li> - <i class="fa fa-folder fa-fw"></i> - <?= $this->url->link(t('Projects management'), 'ProjectListController', 'show') ?> + <?= $this->url->icon('folder', t('Projects management'), 'ProjectListController', 'show') ?> </li> <?php if ($this->user->hasAccess('UserListController', 'show')): ?> <li> - <i class="fa fa-user fa-fw"></i> - <?= $this->url->link(t('Users management'), 'UserListController', 'show') ?> + <?= $this->url->icon('user', t('Users management'), 'UserListController', 'show') ?> </li> <li> - <i class="fa fa-group fa-fw"></i> - <?= $this->url->link(t('Groups management'), 'GroupListController', 'index') ?> + <?= $this->url->icon('group', t('Groups management'), 'GroupListController', 'index') ?> </li> <li> - <i class="fa fa-cubes" aria-hidden="true"></i> - <?= $this->url->link(t('Plugins'), 'PluginController', 'show') ?> + <?= $this->url->icon('cubes', t('Plugins'), 'PluginController', 'show') ?> </li> <li> - <i class="fa fa-cog fa-fw"></i> - <?= $this->url->link(t('Settings'), 'ConfigController', 'index') ?> + <?= $this->url->icon('cog', t('Settings'), 'ConfigController', 'index') ?> </li> <?php endif ?> <?= $this->hook->render('template:header:dropdown') ?> <li> - <i class="fa fa-life-ring fa-fw"></i> - <?= $this->url->link(t('Documentation'), 'DocumentationController', 'show') ?> + <?= $this->url->icon('life-ring', t('Documentation'), 'DocumentationController', 'show') ?> </li> <?php if (! DISABLE_LOGOUT): ?> <li> - <i class="fa fa-sign-out fa-fw"></i> - <?= $this->url->link(t('Logout'), 'AuthController', 'logout') ?> + <?= $this->url->icon('sign-out', t('Logout'), 'AuthController', 'logout') ?> </li> <?php endif ?> </ul> diff --git a/app/Template/link/edit.php b/app/Template/link/edit.php index cb4f29e2..4be56573 100644 --- a/app/Template/link/edit.php +++ b/app/Template/link/edit.php @@ -13,9 +13,5 @@ <?= $this->form->label(t('Opposite label'), 'opposite_id') ?> <?= $this->form->select('opposite_id', $labels, $values, $errors) ?> - <div class="form-actions"> - <button type="submit" class="btn btn-blue"><?= t('Save') ?></button> - <?= t('or') ?> - <?= $this->url->link(t('cancel'), 'LinkController', 'index') ?> - </div> + <?= $this->modal->submitButtons() ?> </form> diff --git a/app/Template/link/index.php b/app/Template/link/index.php index 70ead4a6..b0dcad1e 100644 --- a/app/Template/link/index.php +++ b/app/Template/link/index.php @@ -18,9 +18,9 @@ </td> <td> <ul> - <?= $this->url->link(t('Edit'), 'LinkController', 'edit', array('link_id' => $link['id'])) ?> + <?= $this->modal->medium('edit', t('Edit'), 'LinkController', 'edit', array('link_id' => $link['id'])) ?> <?= t('or') ?> - <?= $this->url->link(t('Remove'), 'LinkController', 'confirm', array('link_id' => $link['id'])) ?> + <?= $this->modal->confirm('trash-o', t('Remove'), 'LinkController', 'confirm', array('link_id' => $link['id'])) ?> </ul> </td> </tr> diff --git a/app/Template/plugin/directory.php b/app/Template/plugin/directory.php index b6c6734c..b2fffcb9 100644 --- a/app/Template/plugin/directory.php +++ b/app/Template/plugin/directory.php @@ -28,11 +28,9 @@ <td> <?php if ($is_configured): ?> <?php if (! isset($installed_plugins[$plugin['title']])): ?> - <i class="fa fa-cloud-download fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Install'), 'PluginController', 'install', array('archive_url' => urlencode($plugin['download'])), true) ?> + <?= $this->url->icon('cloud-download', t('Install'), 'PluginController', 'install', array('archive_url' => urlencode($plugin['download'])), true) ?> <?php elseif ($installed_plugins[$plugin['title']] < $plugin['version']): ?> - <i class="fa fa-refresh fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Update'), 'PluginController', 'update', array('archive_url' => urlencode($plugin['download'])), true) ?> + <?= $this->url->icon('refresh', t('Update'), 'PluginController', 'update', array('archive_url' => urlencode($plugin['download'])), true) ?> <?php else: ?> <i class="fa fa-check-circle-o" aria-hidden="true"></i> <?= t('Up to date') ?> diff --git a/app/Template/project/dropdown.php b/app/Template/project/dropdown.php index 5fbffde4..eaaa3546 100644 --- a/app/Template/project/dropdown.php +++ b/app/Template/project/dropdown.php @@ -2,33 +2,27 @@ <a href="#" class="dropdown-menu dashboard-table-link">#<?= $project['id'] ?></a> <ul> <li> - <i class="fa fa-th fa-fw"></i> - <?= $this->url->link(t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'])) ?> </li> <li> - <i class="fa fa-calendar fa-fw"></i> - <?= $this->url->link(t('Calendar'), 'CalendarController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('calendar', t('Calendar'), 'CalendarController', 'show', array('project_id' => $project['id'])) ?> </li> <li> - <i class="fa fa-list fa-fw"></i> - <?= $this->url->link(t('Listing'), 'TaskListController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('list', t('Listing'), 'TaskListController', 'show', array('project_id' => $project['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('TaskGanttController', 'show', $project['id'])): ?> <li> - <i class="fa fa-sliders fa-fw"></i> - <?= $this->url->link(t('Gantt'), 'TaskGanttController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('sliders', t('Gantt'), 'TaskGanttController', 'show', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <li> - <i class="fa fa-dashboard fa-fw"></i> - <?= $this->url->link(t('Activity'), 'ActivityController', 'project', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('dashboard', t('Activity'), 'ActivityController', 'project', array('project_id' => $project['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('AnalyticController', 'taskDistribution', $project['id'])): ?> <li> - <i class="fa fa-line-chart fa-fw"></i> - <?= $this->url->link(t('Analytics'), 'AnalyticController', 'taskDistribution', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('line-chart', t('Analytics'), 'AnalyticController', 'taskDistribution', array('project_id' => $project['id'])) ?> </li> <?php endif ?> @@ -36,8 +30,7 @@ <?php if ($this->user->hasProjectAccess('ProjectEditController', 'show', $project['id'])): ?> <li> - <i class="fa fa-cog fa-fw"></i> - <?= $this->url->link(t('Settings'), 'ProjectViewController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('cog', t('Settings'), 'ProjectViewController', 'show', array('project_id' => $project['id'])) ?> </li> <?php endif ?> </ul> diff --git a/app/Template/project/sidebar.php b/app/Template/project/sidebar.php index 507cde3e..812eb351 100644 --- a/app/Template/project/sidebar.php +++ b/app/Template/project/sidebar.php @@ -50,15 +50,15 @@ </li> <?php if ($project['is_active']): ?> <li> - <?= $this->modal->confirm('close', t('Disable'), 'ProjectStatusController', 'confirmDisable', array('project_id' => $project['id'])) ?> + <?= $this->modal->confirmLink(t('Disable'), 'ProjectStatusController', 'confirmDisable', array('project_id' => $project['id'])) ?> <?php else: ?> <li> - <?= $this->modal->confirm('check-square-o', t('Enable'), 'ProjectStatusController', 'confirmEnable', array('project_id' => $project['id'])) ?> + <?= $this->modal->confirmLink(t('Enable'), 'ProjectStatusController', 'confirmEnable', array('project_id' => $project['id'])) ?> <?php endif ?> </li> <?php if ($this->user->hasProjectAccess('ProjectStatusController', 'remove', $project['id'])): ?> <li> - <?= $this->modal->confirm('trash-o', t('Remove'), 'ProjectStatusController', 'confirmRemove', array('project_id' => $project['id'])) ?> + <?= $this->modal->confirmLink(t('Remove'), 'ProjectStatusController', 'confirmRemove', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <?php endif ?> diff --git a/app/Template/project_gantt/show.php b/app/Template/project_gantt/show.php index af22a6ed..74248d5d 100644 --- a/app/Template/project_gantt/show.php +++ b/app/Template/project_gantt/show.php @@ -2,10 +2,12 @@ <div class="page-header"> <ul> <li> - <i class="fa fa-folder fa-fw"></i><?= $this->url->link(t('Projects list'), 'ProjectListController', 'show') ?> + <?= $this->url->icon('folder', t('Projects list'), 'ProjectListController', 'show') ?> </li> <?php if ($this->user->hasAccess('ProjectUserOverviewController', 'managers')): ?> - <li><i class="fa fa-user fa-fw"></i><?= $this->url->link(t('Users overview'), 'ProjectUserOverviewController', 'managers') ?></li> + <li> + <?= $this->url->icon('user', t('Users overview'), 'ProjectUserOverviewController', 'managers') ?> + </li> <?php endif ?> </ul> </div> diff --git a/app/Template/project_header/dropdown.php b/app/Template/project_header/dropdown.php index 27d3fd3f..eac4fc57 100644 --- a/app/Template/project_header/dropdown.php +++ b/app/Template/project_header/dropdown.php @@ -4,12 +4,10 @@ <?php if ($board_view): ?> <li> <span class="filter-display-mode" <?= $this->board->isCollapsed($project['id']) ? '' : 'style="display: none;"' ?>> - <i class="fa fa-expand fa-fw"></i> - <?= $this->url->link(t('Expand tasks'), 'BoardAjaxController', 'expand', array('project_id' => $project['id']), false, 'board-display-mode', t('Keyboard shortcut: "%s"', 's')) ?> + <?= $this->url->icon('expand', t('Expand tasks'), 'BoardAjaxController', 'expand', array('project_id' => $project['id']), false, 'board-display-mode', t('Keyboard shortcut: "%s"', 's')) ?> </span> <span class="filter-display-mode" <?= $this->board->isCollapsed($project['id']) ? 'style="display: none;"' : '' ?>> - <i class="fa fa-compress fa-fw"></i> - <?= $this->url->link(t('Collapse tasks'), 'BoardAjaxController', 'collapse', array('project_id' => $project['id']), false, 'board-display-mode', t('Keyboard shortcut: "%s"', 's')) ?> + <?= $this->url->icon('compress', t('Collapse tasks'), 'BoardAjaxController', 'collapse', array('project_id' => $project['id']), false, 'board-display-mode', t('Keyboard shortcut: "%s"', 's')) ?> </span> </li> <li> @@ -29,21 +27,18 @@ <?php endif ?> <li> - <i class="fa fa-dashboard fa-fw"></i> - <?= $this->url->link(t('Activity'), 'ActivityController', 'project', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('dashboard', t('Activity'), 'ActivityController', 'project', array('project_id' => $project['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('CustomFilterController', 'index', $project['id'])): ?> <li> - <i class="fa fa-filter fa-fw"></i> - <?= $this->url->link(t('Custom filters'), 'CustomFilterController', 'index', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('filter', t('Custom filters'), 'CustomFilterController', 'index', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <?php if ($project['is_public']): ?> <li> - <i class="fa fa-share-alt fa-fw"></i> - <?= $this->url->link(t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?> + <?= $this->url->icon('share-alt', t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?> </li> <?php endif ?> @@ -51,35 +46,30 @@ <?php if ($this->user->hasProjectAccess('AnalyticController', 'taskDistribution', $project['id'])): ?> <li> - <i class="fa fa-line-chart fa-fw"></i> - <?= $this->url->link(t('Analytics'), 'AnalyticController', 'taskDistribution', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('line-chart', t('Analytics'), 'AnalyticController', 'taskDistribution', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <?php if ($this->user->hasProjectAccess('ExportController', 'tasks', $project['id'])): ?> <li> - <i class="fa fa-upload fa-fw"></i> - <?= $this->url->link(t('Exports'), 'ExportController', 'tasks', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('upload', t('Exports'), 'ExportController', 'tasks', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <?php if ($this->user->hasProjectAccess('TaskImportController', 'tasks', $project['id'])): ?> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Imports'), 'TaskImportController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('download', t('Imports'), 'TaskImportController', 'show', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <?php if ($this->user->hasProjectAccess('ProjectEditController', 'show', $project['id'])): ?> <li> - <i class="fa fa-cog fa-fw"></i> - <?= $this->url->link(t('Settings'), 'ProjectViewController', 'show', array('project_id' => $project['id'])) ?> + <?= $this->url->icon('cog', t('Settings'), 'ProjectViewController', 'show', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <li> - <i class="fa fa-folder fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Manage projects'), 'ProjectListController', 'show') ?> + <?= $this->url->icon('folder', t('Manage projects'), 'ProjectListController', 'show') ?> </li> </ul> </div> diff --git a/app/Template/project_header/views.php b/app/Template/project_header/views.php index f8a5b39b..0328a051 100644 --- a/app/Template/project_header/views.php +++ b/app/Template/project_header/views.php @@ -1,24 +1,19 @@ <ul class="views"> <li <?= $this->app->checkMenuSelection('ProjectOverviewController') ?>> - <i class="fa fa-eye fa-fw"></i> - <?= $this->url->link(t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> + <?= $this->url->icon('eye', t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> </li> <li <?= $this->app->checkMenuSelection('BoardViewController') ?>> - <i class="fa fa-th fa-fw"></i> - <?= $this->url->link(t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> + <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> </li> <li <?= $this->app->checkMenuSelection('CalendarController') ?>> - <i class="fa fa-calendar fa-fw"></i> - <?= $this->url->link(t('Calendar'), 'CalendarController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-calendar', t('Keyboard shortcut: "%s"', 'v c')) ?> + <?= $this->url->icon('calendar', t('Calendar'), 'CalendarController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-calendar', t('Keyboard shortcut: "%s"', 'v c')) ?> </li> <li <?= $this->app->checkMenuSelection('TaskListController') ?>> - <i class="fa fa-list fa-fw"></i> - <?= $this->url->link(t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> + <?= $this->url->icon('list', t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> </li> <?php if ($this->user->hasProjectAccess('TaskGanttController', 'show', $project['id'])): ?> <li <?= $this->app->checkMenuSelection('TaskGanttController') ?>> - <i class="fa fa-sliders fa-fw"></i> - <?= $this->url->link(t('Gantt'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-gantt', t('Keyboard shortcut: "%s"', 'v g')) ?> + <?= $this->url->icon('sliders', t('Gantt'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-gantt', t('Keyboard shortcut: "%s"', 'v g')) ?> </li> <?php endif ?> </ul> diff --git a/app/Template/project_list/show.php b/app/Template/project_list/show.php index f8f5862c..92101429 100644 --- a/app/Template/project_list/show.php +++ b/app/Template/project_list/show.php @@ -3,10 +3,10 @@ <ul> <?= $this->hook->render('template:project-list:menu:before') ?> <?php if ($this->user->hasAccess('ProjectUserOverviewController', 'managers')): ?> - <li><i class="fa fa-user fa-fw"></i><?= $this->url->link(t('Users overview'), 'ProjectUserOverviewController', 'managers') ?></li> + <li><?= $this->url->icon('user', t('Users overview'), 'ProjectUserOverviewController', 'managers') ?></li> <?php endif ?> <?php if ($this->user->hasAccess('ProjectGanttController', 'show')): ?> - <li><i class="fa fa-sliders fa-fw"></i><?= $this->url->link(t('Projects Gantt chart'), 'ProjectGanttController', 'show') ?></li> + <li><?= $this->url->icon('sliders', t('Projects Gantt chart'), 'ProjectGanttController', 'show') ?></li> <?php endif ?> <?= $this->hook->render('template:project-list:menu:after') ?> </ul> diff --git a/app/Template/project_overview/files.php b/app/Template/project_overview/files.php index 6518fafb..85de52f7 100644 --- a/app/Template/project_overview/files.php +++ b/app/Template/project_overview/files.php @@ -19,13 +19,11 @@ </li> <?php elseif ($this->file->getBrowserViewType($file['name']) !== null): ?> <li> - <i class="fa fa-eye fa-fw"></i> - <?= $this->url->link(t('View file'), 'FileViewerController', 'browser', array('project_id' => $project['id'], 'file_id' => $file['id']), false, '', '', true) ?> + <?= $this->url->icon('eye', t('View file'), 'FileViewerController', 'browser', array('project_id' => $project['id'], 'file_id' => $file['id']), false, '', '', true) ?> </li> <?php endif ?> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?> + <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('ProjectFileController', 'remove', $project['id'])): ?> <li> diff --git a/app/Template/project_overview/images.php b/app/Template/project_overview/images.php index cabfd0f6..7e7962e8 100644 --- a/app/Template/project_overview/images.php +++ b/app/Template/project_overview/images.php @@ -19,8 +19,7 @@ <a href="#" class="dropdown-menu dropdown-menu-link-text"><?= $this->text->e($file['name']) ?> <i class="fa fa-caret-down"></i></a> <ul> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?> + <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('ProjectFileController', 'remove', $project['id'])): ?> <li> diff --git a/app/Template/project_overview/information.php b/app/Template/project_overview/information.php index fdf0f753..eb94551e 100644 --- a/app/Template/project_overview/information.php +++ b/app/Template/project_overview/information.php @@ -29,9 +29,9 @@ <?php endif ?> <?php if ($project['is_public']): ?> - <li><i class="fa fa-share-alt"></i> <?= $this->url->link(t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li> - <li><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> - <li><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> + <li><?= $this->url->icon('share-alt', t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li> + <li><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> + <li><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> <?php endif ?> </ul> </div> diff --git a/app/Template/project_permission/groups.php b/app/Template/project_permission/groups.php index 582643a2..d3b52be0 100644 --- a/app/Template/project_permission/groups.php +++ b/app/Template/project_permission/groups.php @@ -25,8 +25,7 @@ )) ?> </td> <td> - <i class="fa fa-trash-o" aria-hidden="true"></i> - <?= $this->url->link(t('Remove'), 'ProjectPermissionController', 'removeGroup', array('project_id' => $project['id'], 'group_id' => $group['id']), true) ?> + <?= $this->url->icon('trash-o', t('Remove'), 'ProjectPermissionController', 'removeGroup', array('project_id' => $project['id'], 'group_id' => $group['id']), true) ?> </td> </tr> <?php endforeach ?> diff --git a/app/Template/project_permission/users.php b/app/Template/project_permission/users.php index 71cf1c4a..79d08552 100644 --- a/app/Template/project_permission/users.php +++ b/app/Template/project_permission/users.php @@ -21,8 +21,7 @@ )) ?> </td> <td> - <i class="fa fa-trash-o" aria-hidden="true"></i> - <?= $this->url->link(t('Remove'), 'ProjectPermissionController', 'removeUser', array('project_id' => $project['id'], 'user_id' => $user['id']), true) ?> + <?= $this->url->icon('trash-o', t('Remove'), 'ProjectPermissionController', 'removeUser', array('project_id' => $project['id'], 'user_id' => $user['id']), true) ?> </td> </tr> <?php endforeach ?> diff --git a/app/Template/project_user_overview/layout.php b/app/Template/project_user_overview/layout.php index 19b83436..5c739297 100644 --- a/app/Template/project_user_overview/layout.php +++ b/app/Template/project_user_overview/layout.php @@ -2,19 +2,16 @@ <div class="page-header"> <ul> <li> - <i class="fa fa-folder fa-fw"></i> - <?= $this->url->link(t('Projects list'), 'ProjectListController', 'show') ?> + <?= $this->url->icon('folder', t('Projects list'), 'ProjectListController', 'show') ?> </li> <?php if ($this->user->hasAccess('ProjectGanttController', 'show')): ?> <li> - <i class="fa fa-sliders fa-fw"></i> - <?= $this->url->link(t('Projects Gantt chart'), 'ProjectGanttController', 'show') ?> + <?= $this->url->icon('sliders', t('Projects Gantt chart'), 'ProjectGanttController', 'show') ?> </li> <?php endif ?> </ul> </div> <section class="sidebar-container"> - <?= $this->render($sidebar_template, array('users' => $users, 'filter' => $filter)) ?> <div class="sidebar-content"> diff --git a/app/Template/project_view/share.php b/app/Template/project_view/share.php index 409f37e6..29598c6e 100644 --- a/app/Template/project_view/share.php +++ b/app/Template/project_view/share.php @@ -6,9 +6,9 @@ <div class="listing"> <ul class="no-bullet"> - <li><strong><i class="fa fa-share-alt"></i> <?= $this->url->link(t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></strong></li> - <li><strong><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></strong></li> - <li><strong><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('share-alt', t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token']), false, '', '', true) ?></strong></li> </ul> </div> diff --git a/app/Template/project_view/show.php b/app/Template/project_view/show.php index afe60384..1795e9ef 100644 --- a/app/Template/project_view/show.php +++ b/app/Template/project_view/show.php @@ -13,9 +13,9 @@ <?php endif ?> <?php if ($project['is_public']): ?> - <li><i class="fa fa-share-alt"></i> <?= $this->url->link(t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li> - <li><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> - <li><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> + <li><?= $this->url->icon('share-alt', t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li> + <li><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li> + <li><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li> <?php else: ?> <li><?= t('Public access disabled') ?></li> <?php endif ?> diff --git a/app/Template/search/activity.php b/app/Template/search/activity.php index 1dfd9234..f1ee9200 100644 --- a/app/Template/search/activity.php +++ b/app/Template/search/activity.php @@ -2,8 +2,7 @@ <div class="page-header"> <ul> <li> - <i class="fa fa-search fa-fw"></i> - <?= $this->url->link(t('Search tasks'), 'SearchController', 'index') ?> + <?= $this->url->icon('search', t('Search tasks'), 'SearchController', 'index') ?> </li> </ul> </div> diff --git a/app/Template/search/index.php b/app/Template/search/index.php index c59a5c99..405c88cd 100644 --- a/app/Template/search/index.php +++ b/app/Template/search/index.php @@ -2,8 +2,7 @@ <div class="page-header"> <ul> <li> - <i class="fa fa-search fa-fw"></i> - <?= $this->url->link(t('Activity stream search'), 'SearchController', 'activity') ?> + <?= $this->url->icon('search', t('Activity stream search'), 'SearchController', 'activity') ?> </li> </ul> </div> diff --git a/app/Template/subtask/table.php b/app/Template/subtask/table.php index bea49aed..156e08c1 100644 --- a/app/Template/subtask/table.php +++ b/app/Template/subtask/table.php @@ -45,12 +45,10 @@ <?php if ($editable && $subtask['user_id'] == $this->user->getId()): ?> <li> <?php if ($subtask['is_timer_started']): ?> - <i class="fa fa-pause"></i> - <?= $this->url->link(t('Stop timer'), 'SubtaskStatusController', 'timer', array('timer' => 'stop', 'project_id' => $task['project_id'], 'task_id' => $subtask['task_id'], 'subtask_id' => $subtask['id']), false, 'subtask-toggle-timer') ?> + <?= $this->url->icon('pause', t('Stop timer'), 'SubtaskStatusController', 'timer', array('timer' => 'stop', 'project_id' => $task['project_id'], 'task_id' => $subtask['task_id'], 'subtask_id' => $subtask['id']), false, 'subtask-toggle-timer') ?> (<?= $this->dt->age($subtask['timer_start_date']) ?>) <?php else: ?> - <i class="fa fa-play-circle-o"></i> - <?= $this->url->link(t('Start timer'), 'SubtaskStatusController', 'timer', array('timer' => 'start', 'project_id' => $task['project_id'], 'task_id' => $subtask['task_id'], 'subtask_id' => $subtask['id']), false, 'subtask-toggle-timer') ?> + <?= $this->url->icon('play-circle-o', t('Start timer'), 'SubtaskStatusController', 'timer', array('timer' => 'start', 'project_id' => $task['project_id'], 'task_id' => $subtask['task_id'], 'subtask_id' => $subtask['id']), false, 'subtask-toggle-timer') ?> <?php endif ?> </li> <?php endif ?> diff --git a/app/Template/swimlane/table.php b/app/Template/swimlane/table.php index 4c9390e0..2d783a00 100644 --- a/app/Template/swimlane/table.php +++ b/app/Template/swimlane/table.php @@ -24,11 +24,9 @@ </li> <li> <?php if ($default_swimlane['show_default_swimlane'] == 1): ?> - <i class="fa fa-toggle-off fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Disable'), 'SwimlaneController', 'disableDefault', array('project_id' => $project['id']), true) ?> + <?= $this->url->icon('toggle-off', t('Disable'), 'SwimlaneController', 'disableDefault', array('project_id' => $project['id']), true) ?> <?php else: ?> - <i class="fa fa-toggle-on fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Enable'), 'SwimlaneController', 'enableDefault', array('project_id' => $project['id']), true) ?> + <?= $this->url->icon('toggle-on', t('Enable'), 'SwimlaneController', 'enableDefault', array('project_id' => $project['id']), true) ?> <?php endif ?> </li> </ul> @@ -61,11 +59,9 @@ </li> <li> <?php if ($swimlane['is_active']): ?> - <i class="fa fa-toggle-off fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Disable'), 'SwimlaneController', 'disable', array('project_id' => $project['id'], 'swimlane_id' => $swimlane['id']), true) ?> + <?= $this->url->icon('toggle-off', t('Disable'), 'SwimlaneController', 'disable', array('project_id' => $project['id'], 'swimlane_id' => $swimlane['id']), true) ?> <?php else: ?> - <i class="fa fa-toggle-on fa-fw" aria-hidden="true"></i> - <?= $this->url->link(t('Enable'), 'SwimlaneController', 'enable', array('project_id' => $project['id'], 'swimlane_id' => $swimlane['id']), true) ?> + <?= $this->url->icon('toggle-on', t('Enable'), 'SwimlaneController', 'enable', array('project_id' => $project['id'], 'swimlane_id' => $swimlane['id']), true) ?> <?php endif ?> </li> <li> diff --git a/app/Template/task/details.php b/app/Template/task/details.php index b616afe3..24099a3c 100644 --- a/app/Template/task/details.php +++ b/app/Template/task/details.php @@ -33,16 +33,14 @@ <?php if ($project['is_public']): ?> <li> <small> - <i class="fa fa-external-link fa-fw"></i> - <?= $this->url->link(t('Public link'), 'TaskViewController', 'readonly', array('task_id' => $task['id'], 'token' => $project['token']), false, '', '', true) ?> + <?= $this->url->icon('external-link', t('Public link'), 'TaskViewController', 'readonly', array('task_id' => $task['id'], 'token' => $project['token']), false, '', '', true) ?> </small> </li> <?php endif ?> <?php if ($project['is_public'] && !$editable): ?> <li> <small> - <i class="fa fa-th fa-fw"></i> - <?= $this->url->link(t('Back to the board'), 'BoardViewController', 'readonly', array('token' => $project['token'])) ?> + <?= $this->url->icon('th', t('Back to the board'), 'BoardViewController', 'readonly', array('token' => $project['token'])) ?> </small> </li> <?php endif ?> diff --git a/app/Template/task/dropdown.php b/app/Template/task/dropdown.php index bd424443..1daf8896 100644 --- a/app/Template/task/dropdown.php +++ b/app/Template/task/dropdown.php @@ -3,8 +3,7 @@ <ul> <?php if (array_key_exists('date_started', $task) && empty($task['date_started'])): ?> <li> - <i class="fa fa-play fa-fw"></i> - <?= $this->url->link(t('Set automatically the start date'), 'TaskModificationController', 'start', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('play', t('Set automatically the start date'), 'TaskModificationController', 'start', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <?php endif ?> <li> diff --git a/app/Template/task/sidebar.php b/app/Template/task/sidebar.php index 9735efcb..f8f1ebde 100644 --- a/app/Template/task/sidebar.php +++ b/app/Template/task/sidebar.php @@ -4,25 +4,20 @@ </div> <ul> <li <?= $this->app->checkMenuSelection('TaskViewController', 'show') ?>> - <i class="fa fa-newspaper-o fa-fw"></i> - <?= $this->url->link(t('Summary'), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('newspaper-o', t('Summary'), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <li <?= $this->app->checkMenuSelection('ActivityController', 'task') ?>> - <i class="fa fa-dashboard fa-fw"></i> - <?= $this->url->link(t('Activity stream'), 'ActivityController', 'task', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('dashboard', t('Activity stream'), 'ActivityController', 'task', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <li <?= $this->app->checkMenuSelection('TaskViewController', 'transitions') ?>> - <i class="fa fa-arrows-h fa-fw"></i> - <?= $this->url->link(t('Transitions'), 'TaskViewController', 'transitions', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('arrows-h', t('Transitions'), 'TaskViewController', 'transitions', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <li <?= $this->app->checkMenuSelection('TaskViewController', 'analytics') ?>> - <i class="fa fa-bar-chart fa-fw"></i> - <?= $this->url->link(t('Analytics'), 'TaskViewController', 'analytics', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('bar-chart', t('Analytics'), 'TaskViewController', 'analytics', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <?php if ($task['time_estimated'] > 0 || $task['time_spent'] > 0): ?> <li <?= $this->app->checkMenuSelection('TaskViewController', 'timetracking') ?>> - <i class="fa fa-clock-o fa-fw"></i> - <?= $this->url->link(t('Time tracking'), 'TaskViewController', 'timetracking', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?= $this->url->icon('clock-o', t('Time tracking'), 'TaskViewController', 'timetracking', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> </li> <?php endif ?> diff --git a/app/Template/task_file/files.php b/app/Template/task_file/files.php index ffebdb84..28633dc4 100644 --- a/app/Template/task_file/files.php +++ b/app/Template/task_file/files.php @@ -24,8 +24,7 @@ </li> <?php endif ?> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> + <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('TaskFileController', 'remove', $task['project_id'])): ?> <li> diff --git a/app/Template/task_file/images.php b/app/Template/task_file/images.php index e3599441..33a31ba8 100644 --- a/app/Template/task_file/images.php +++ b/app/Template/task_file/images.php @@ -19,8 +19,7 @@ <a href="#" class="dropdown-menu dropdown-menu-link-text"><?= $this->text->e($file['name']) ?> <i class="fa fa-caret-down"></i></a> <ul> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> + <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> </li> <?php if ($this->user->hasProjectAccess('TaskFileController', 'remove', $task['project_id'])): ?> <li> diff --git a/app/Template/task_gantt/show.php b/app/Template/task_gantt/show.php index ddc70a43..61a476b7 100644 --- a/app/Template/task_gantt/show.php +++ b/app/Template/task_gantt/show.php @@ -3,12 +3,10 @@ <div class="menu-inline"> <ul> <li <?= $sorting === 'board' ? 'class="active"' : '' ?>> - <i class="fa fa-sort-numeric-asc fa-fw"></i> - <?= $this->url->link(t('Sort by position'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'sorting' => 'board')) ?> + <?= $this->url->icon('sort-numeric-asc', t('Sort by position'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'sorting' => 'board')) ?> </li> <li <?= $sorting === 'date' ? 'class="active"' : '' ?>> - <i class="fa fa-sort-amount-asc fa-fw"></i> - <?= $this->url->link(t('Sort by date'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'sorting' => 'date')) ?> + <?= $this->url->icon('sort-amount-asc', t('Sort by date'), 'TaskGanttController', 'show', array('project_id' => $project['id'], 'sorting' => 'date')) ?> </li> <li> <?= $this->modal->large('plus', t('Add task'), 'TaskCreationController', 'show', array('project_id' => $project['id'])) ?> diff --git a/app/Template/task_import/show.php b/app/Template/task_import/show.php index cc6a7b3a..54264f30 100644 --- a/app/Template/task_import/show.php +++ b/app/Template/task_import/show.php @@ -31,4 +31,4 @@ <li><?= t('The due date must use the ISO format: YYYY-MM-DD') ?></li> </ul> </div> -<p><i class="fa fa-download fa-fw"></i><?= $this->url->link(t('Download CSV template'), 'TaskImportController', 'template', array('project_id' => $project['id'])) ?></p> +<p><?= $this->url->icon('download', t('Download CSV template'), 'TaskImportController', 'template', array('project_id' => $project['id'])) ?></p> diff --git a/app/Template/user_import/show.php b/app/Template/user_import/show.php index fb593bb6..9a8572c5 100644 --- a/app/Template/user_import/show.php +++ b/app/Template/user_import/show.php @@ -2,8 +2,7 @@ <h2><?= t('Import users from CSV file') ?></h2> <ul> <li> - <i class="fa fa-download fa-fw"></i> - <?= $this->url->link(t('Download CSV template'), 'UserImportController', 'template') ?> + <?= $this->url->icon('download', t('Download CSV template'), 'UserImportController', 'template') ?> </li> </ul> </div> diff --git a/app/Template/user_list/dropdown.php b/app/Template/user_list/dropdown.php index 44a78162..d18f20aa 100644 --- a/app/Template/user_list/dropdown.php +++ b/app/Template/user_list/dropdown.php @@ -2,8 +2,7 @@ <a href="#" class="dropdown-menu dropdown-menu-link-icon"><i class="fa fa-cog fa-fw"></i><i class="fa fa-caret-down"></i></a> <ul> <li> - <i class="fa fa-user fa-fw"></i> - <?= $this->url->link(t('View profile'), 'UserViewController', 'show', array('user_id' => $user['id'])) ?> + <?= $this->url->icon('user', t('View profile'), 'UserViewController', 'show', array('user_id' => $user['id'])) ?> </li> <?php if ($user['is_active'] == 1 && $this->user->hasAccess('UserStatusController', 'disable') && ! $this->user->isCurrentUser($user['id'])): ?> <li> diff --git a/app/Template/user_list/show.php b/app/Template/user_list/show.php index 92ea74e7..783a1df7 100644 --- a/app/Template/user_list/show.php +++ b/app/Template/user_list/show.php @@ -12,7 +12,7 @@ <?= $this->modal->medium('upload', t('Import'), 'UserImportController', 'show') ?> </li> <li> - <i class="fa fa-users fa-fw"></i><?= $this->url->link(t('View all groups'), 'GroupListController', 'index') ?> + <?= $this->url->icon('users', t('View all groups'), 'GroupListController', 'index') ?> </li> </ul> <?php endif ?> diff --git a/app/Template/user_view/layout.php b/app/Template/user_view/layout.php index 4f0eca94..c126ad89 100644 --- a/app/Template/user_view/layout.php +++ b/app/Template/user_view/layout.php @@ -3,7 +3,7 @@ <?php if ($this->user->hasAccess('UserCreationController', 'show')): ?> <ul> <li> - <i class="fa fa-user fa-fw"></i><?= $this->url->link(t('All users'), 'UserListController', 'show') ?> + <?= $this->url->icon('user', t('All users'), 'UserListController', 'show') ?> </li> <li> <?= $this->modal->medium('plus', t('New local user'), 'UserCreationController', 'show') ?> @@ -15,7 +15,7 @@ <?= $this->modal->medium('upload', t('Import'), 'UserImportController', 'show') ?> </li> <li> - <i class="fa fa-users fa-fw"></i><?= $this->url->link(t('View all groups'), 'GroupListController', 'index') ?> + <?= $this->url->icon('users', t('View all groups'), 'GroupListController', 'index') ?> </li> </ul> <?php endif ?> diff --git a/app/Template/user_view/share.php b/app/Template/user_view/share.php index 570b766e..614f058a 100644 --- a/app/Template/user_view/share.php +++ b/app/Template/user_view/share.php @@ -5,8 +5,8 @@ <?php if (! empty($user['token'])): ?> <div class="listing"> <ul class="no-bullet"> - <li><strong><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> - <li><strong><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> </ul> </div> <?= $this->url->link(t('Disable public access'), 'UserViewController', 'share', array('user_id' => $user['id'], 'switch' => 'disable'), true, 'btn btn-red') ?> diff --git a/app/Template/user_view/show.php b/app/Template/user_view/show.php index 2f5a73af..456f57ac 100644 --- a/app/Template/user_view/show.php +++ b/app/Template/user_view/show.php @@ -42,8 +42,8 @@ <div class="listing"> <ul class="no-bullet"> - <li><strong><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> - <li><strong><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> + <li><strong><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'user', array('token' => $user['token']), false, '', '', true) ?></strong></li> </ul> </div> <?php endif ?> |