diff options
author | Frederic Guillot <fred@kanboard.net> | 2015-05-31 17:57:02 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2015-05-31 17:57:02 -0400 |
commit | 599b6624dde8cb1c1f6416ee0af530402089da4d (patch) | |
tree | 2cc995b09a4b2e67de276389fb28b0040d484296 /app/Template/project | |
parent | 380aacd3f586089ae5c1e69841c0e0cb99478dcd (diff) |
Improve project navigation
Diffstat (limited to 'app/Template/project')
-rw-r--r-- | app/Template/project/activity.php | 28 | ||||
-rw-r--r-- | app/Template/project/dropdown.php | 41 | ||||
-rw-r--r-- | app/Template/project/layout.php | 14 | ||||
-rw-r--r-- | app/Template/project/search.php | 42 | ||||
-rw-r--r-- | app/Template/project/show.php | 1 | ||||
-rw-r--r-- | app/Template/project/sidebar.php | 27 | ||||
-rw-r--r-- | app/Template/project/tasks.php | 33 |
7 files changed, 57 insertions, 129 deletions
diff --git a/app/Template/project/activity.php b/app/Template/project/activity.php deleted file mode 100644 index 1c5dcb75..00000000 --- a/app/Template/project/activity.php +++ /dev/null @@ -1,28 +0,0 @@ -<section id="main"> - <div class="page-header"> - <ul> - <li> - <i class="fa fa-table fa-fw"></i> - <?= $this->url->link(t('Back to the board'), 'board', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-calendar fa-fw"></i> - <?= $this->url->link(t('Calendar'), 'calendar', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-search fa-fw"></i> - <?= $this->url->link(t('Search'), 'project', 'search', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-check-square-o fa-fw"></i> - <?= $this->url->link(t('Completed tasks'), 'project', 'tasks', array('project_id' => $project['id'])) ?> - </li> - <?php if ($project['is_public']): ?> - <li><i class="fa fa-rss-square fa-fw"></i><?= $this->url->link(t('RSS feed'), 'project', 'feed', array('token' => $project['token']), false, '', '', true) ?></li> - <?php endif ?> - </ul> - </div> - <section> - <?= $this->render('event/events', array('events' => $events)) ?> - </section> -</section>
\ No newline at end of file diff --git a/app/Template/project/dropdown.php b/app/Template/project/dropdown.php new file mode 100644 index 00000000..2e2650a7 --- /dev/null +++ b/app/Template/project/dropdown.php @@ -0,0 +1,41 @@ +<li> + <i class="fa fa-search fa-fw"></i> + <?= $this->url->link(t('Search'), 'projectinfo', 'search', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-check-square-o fa-fw"></i> + <?= $this->url->link(t('Completed tasks'), 'projectinfo', 'tasks', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-dashboard fa-fw"></i> + <?= $this->url->link(t('Activity'), 'projectinfo', 'activity', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-calendar fa-fw"></i> + <?= $this->url->link(t('Calendar'), 'calendar', 'show', array('project_id' => $project['id'])) ?> +</li> + +<?php if ($project['is_public']): ?> +<li> + <i class="fa fa-share-alt fa-fw"></i> <?= $this->url->link(t('Public link'), 'board', 'readonly', array('token' => $project['token']), false, '', '', true) ?> +</li> +<?php endif ?> + +<?php if ($this->user->isManager($project['id'])): ?> +<li> + <i class="fa fa-line-chart fa-fw"></i> + <?= $this->url->link(t('Analytics'), 'analytic', 'tasks', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-pie-chart fa-fw"></i> + <?= $this->url->link(t('Budget'), 'budget', 'index', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-download fa-fw"></i> + <?= $this->url->link(t('Exports'), 'export', 'tasks', array('project_id' => $project['id'])) ?> +</li> +<li> + <i class="fa fa-cog fa-fw"></i> + <?= $this->url->link(t('Settings'), 'project', 'show', array('project_id' => $project['id'])) ?> +</li> +<?php endif ?> diff --git a/app/Template/project/layout.php b/app/Template/project/layout.php index f5409500..7bb3d478 100644 --- a/app/Template/project/layout.php +++ b/app/Template/project/layout.php @@ -2,6 +2,16 @@ <div class="page-header"> <ul> <li> + <span class="dropdown"> + <span> + <i class="fa fa-caret-down"></i> <a href="#" class="dropdown-menu"><?= t('Actions') ?></a> + <ul> + <?= $this->render('project/dropdown', array('project' => $project)) ?> + </ul> + </span> + </span> + </li> + <li> <i class="fa fa-table fa-fw"></i> <?= $this->url->link(t('Back to the board'), 'board', 'show', array('project_id' => $project['id'])) ?> </li> @@ -11,9 +21,9 @@ </li> </ul> </div> - <section class="sidebar-container" id="project-section"> + <section class="sidebar-container"> - <?= $this->render('project/sidebar', array('project' => $project)) ?> + <?= $this->render($sidebar_template, array('project' => $project)) ?> <div class="sidebar-content"> <?= $project_content_for_layout ?> diff --git a/app/Template/project/search.php b/app/Template/project/search.php deleted file mode 100644 index a8e387c6..00000000 --- a/app/Template/project/search.php +++ /dev/null @@ -1,42 +0,0 @@ -<section id="main"> - <div class="page-header"> - <ul> - <li> - <i class="fa fa-table fa-fw"></i> - <?= $this->url->link(t('Back to the board'), 'board', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-calendar fa-fw"></i> - <?= $this->url->link(t('Calendar'), 'calendar', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-check-square-o fa-fw"></i> - <?= $this->url->link(t('Completed tasks'), 'project', 'tasks', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-dashboard fa-fw"></i> - <?= $this->url->link(t('Activity'), 'project', 'activity', array('project_id' => $project['id'])) ?> - </li> - </ul> - </div> - <section> - <form method="get" action="?" autocomplete="off"> - <?= $this->form->hidden('controller', $values) ?> - <?= $this->form->hidden('action', $values) ?> - <?= $this->form->hidden('project_id', $values) ?> - <?= $this->form->text('search', $values, array(), array('autofocus', 'required', 'placeholder="'.t('Search').'"'), 'form-input-large') ?> - <input type="submit" value="<?= t('Search') ?>" class="btn btn-blue"/> - </form> - - <?php if (! empty($values['search']) && $paginator->isEmpty()): ?> - <p class="alert"><?= t('Nothing found.') ?></p> - <?php elseif (! $paginator->isEmpty()): ?> - <?= $this->render('task/table', array( - 'paginator' => $paginator, - 'categories' => $categories, - 'columns' => $columns, - )) ?> - <?php endif ?> - - </section> -</section>
\ No newline at end of file diff --git a/app/Template/project/show.php b/app/Template/project/show.php index 9ffbd5bc..4869d8a4 100644 --- a/app/Template/project/show.php +++ b/app/Template/project/show.php @@ -11,6 +11,7 @@ <?php if ($project['is_public']): ?> <li><i class="fa fa-share-alt"></i> <?= $this->url->link(t('Public link'), 'board', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li> <li><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'project', 'feed', array('token' => $project['token']), false, '', '', true) ?></li> + <li><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ical', 'project', array('token' => $project['token'])) ?></li> <?php else: ?> <li><?= t('Public access disabled') ?></li> <?php endif ?> diff --git a/app/Template/project/sidebar.php b/app/Template/project/sidebar.php index 5c7ea715..a58c4604 100644 --- a/app/Template/project/sidebar.php +++ b/app/Template/project/sidebar.php @@ -19,14 +19,14 @@ <?= $this->url->link(t('Edit board'), 'column', 'index', array('project_id' => $project['id'])) ?> </li> <li> - <?= $this->url->link(t('Category management'), 'category', 'index', array('project_id' => $project['id'])) ?> + <?= $this->url->link(t('Swimlanes'), 'swimlane', 'index', array('project_id' => $project['id'])) ?> </li> <li> - <?= $this->url->link(t('Swimlanes'), 'swimlane', 'index', array('project_id' => $project['id'])) ?> + <?= $this->url->link(t('Categories'), 'category', 'index', array('project_id' => $project['id'])) ?> </li> <?php if ($this->user->isAdmin() || $project['is_private'] == 0): ?> <li> - <?= $this->url->link(t('User management'), 'project', 'users', array('project_id' => $project['id'])) ?> + <?= $this->url->link(t('Users'), 'project', 'users', array('project_id' => $project['id'])) ?> </li> <?php endif ?> <li> @@ -36,9 +36,6 @@ <?= $this->url->link(t('Duplicate'), 'project', 'duplicate', array('project_id' => $project['id'])) ?> </li> <li> - <?= $this->url->link(t('Budget'), 'budget', 'index', array('project_id' => $project['id'])) ?> - </li> - <li> <?php if ($project['is_active']): ?> <?= $this->url->link(t('Disable'), 'project', 'disable', array('project_id' => $project['id']), true) ?> <?php else: ?> @@ -52,22 +49,4 @@ <?php endif ?> <?php endif ?> </ul> - - <?php if ($this->user->isManager($project['id'])): ?> - <h2><?= t('Exports') ?></h2> - <ul> - <li> - <?= $this->url->link(t('Tasks'), 'export', 'tasks', array('project_id' => $project['id'])) ?> - </li> - <li> - <?= $this->url->link(t('Subtasks'), 'export', 'subtasks', array('project_id' => $project['id'])) ?> - </li> - <li> - <?= $this->url->link(t('Task transitions'), 'export', 'transitions', array('project_id' => $project['id'])) ?> - </li> - <li> - <?= $this->url->link(t('Daily project summary'), 'export', 'summary', array('project_id' => $project['id'])) ?> - </li> - </ul> - <?php endif ?> </div> diff --git a/app/Template/project/tasks.php b/app/Template/project/tasks.php deleted file mode 100644 index 06f28061..00000000 --- a/app/Template/project/tasks.php +++ /dev/null @@ -1,33 +0,0 @@ -<section id="main"> - <div class="page-header"> - <ul> - <li> - <i class="fa fa-table fa-fw"></i> - <?= $this->url->link(t('Back to the board'), 'board', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-calendar fa-fw"></i> - <?= $this->url->link(t('Calendar'), 'calendar', 'show', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-search fa-fw"></i> - <?= $this->url->link(t('Search'), 'project', 'search', array('project_id' => $project['id'])) ?> - </li> - <li> - <i class="fa fa-dashboard fa-fw"></i> - <?= $this->url->link(t('Activity'), 'project', 'activity', array('project_id' => $project['id'])) ?> - </li> - </ul> - </div> - <section> - <?php if ($paginator->isEmpty()): ?> - <p class="alert"><?= t('No task') ?></p> - <?php else: ?> - <?= $this->render('task/table', array( - 'paginator' => $paginator, - 'categories' => $categories, - 'columns' => $columns, - )) ?> - <?php endif ?> - </section> -</section>
\ No newline at end of file |