summaryrefslogtreecommitdiff
path: root/app/Template
diff options
context:
space:
mode:
authorChristopher Geelen <christopher.geelen@vinotion.nl>2016-07-27 13:58:23 +0200
committerChristopher Geelen <christopher.geelen@vinotion.nl>2016-07-27 13:58:23 +0200
commit24745182724ca69092554eb5946e31584420f68a (patch)
tree386cdf7a8d7bf7ad2d80d938333bafbaf0fedcbc /app/Template
parent160c0b885eb4f1a1a1baa2b6b9fc6d99fdb80d0c (diff)
parent9649f7ba82ba7fe6a470abfe9f65e214cc68fa34 (diff)
Merge remote-tracking branch 'upstream/master'
Conflicts: app/Job/NotificationJob.php
Diffstat (limited to 'app/Template')
-rw-r--r--app/Template/analytic/compare_hours.php2
-rw-r--r--app/Template/analytic/sidebar.php1
-rw-r--r--app/Template/board/table_column.php1
-rw-r--r--app/Template/board/table_tasks.php3
-rw-r--r--app/Template/config/about.php2
-rw-r--r--app/Template/config/sidebar.php1
-rw-r--r--app/Template/dashboard/projects.php4
-rw-r--r--app/Template/dashboard/sidebar.php1
-rw-r--r--app/Template/dashboard/subtasks.php4
-rw-r--r--app/Template/dashboard/tasks.php8
-rw-r--r--app/Template/event/comment_delete.php11
-rw-r--r--app/Template/event/comment_update.php3
-rw-r--r--app/Template/event/subtask_delete.php15
-rw-r--r--app/Template/event/task_assignee_change.php2
-rw-r--r--app/Template/event/task_internal_link_create_update.php16
-rw-r--r--app/Template/event/task_internal_link_delete.php16
-rw-r--r--app/Template/export/sidebar.php1
-rw-r--r--app/Template/export/subtasks.php4
-rw-r--r--app/Template/export/summary.php4
-rw-r--r--app/Template/export/tasks.php4
-rw-r--r--app/Template/feed/project.php27
-rw-r--r--app/Template/feed/user.php27
-rw-r--r--app/Template/header.php3
-rw-r--r--app/Template/notification/comment_delete.php7
-rw-r--r--app/Template/notification/subtask_delete.php11
-rw-r--r--app/Template/notification/task_file_create.php2
-rw-r--r--app/Template/notification/task_internal_link_create_update.php11
-rw-r--r--app/Template/notification/task_internal_link_delete.php11
-rw-r--r--app/Template/plugin/sidebar.php1
-rw-r--r--app/Template/project/sidebar.php1
-rw-r--r--app/Template/project_creation/create.php2
-rw-r--r--app/Template/project_header/dropdown.php8
-rw-r--r--app/Template/project_user_overview/sidebar.php2
-rw-r--r--app/Template/project_view/duplicate.php2
-rw-r--r--app/Template/task/show.php12
-rw-r--r--app/Template/task/sidebar.php8
-rw-r--r--app/Template/task_import/sidebar.php1
-rw-r--r--app/Template/user_modification/show.php8
-rw-r--r--app/Template/user_view/sidebar.php76
39 files changed, 196 insertions, 127 deletions
diff --git a/app/Template/analytic/compare_hours.php b/app/Template/analytic/compare_hours.php
index 70d8d02b..e4a0b60e 100644
--- a/app/Template/analytic/compare_hours.php
+++ b/app/Template/analytic/compare_hours.php
@@ -1,5 +1,5 @@
<div class="page-header">
- <h2><?= t('Compare Estimated Time vs Actual Time') ?></h2>
+ <h2><?= t('Estimated vs actual time') ?></h2>
</div>
<div class="listing">
diff --git a/app/Template/analytic/sidebar.php b/app/Template/analytic/sidebar.php
index de3dccf8..0f5ee101 100644
--- a/app/Template/analytic/sidebar.php
+++ b/app/Template/analytic/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Reportings') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('AnalyticController', 'tasks') ?>>
<?= $this->url->link(t('Task distribution'), 'AnalyticController', 'tasks', array('project_id' => $project['id'])) ?>
diff --git a/app/Template/board/table_column.php b/app/Template/board/table_column.php
index 6336234a..75a6eb4c 100644
--- a/app/Template/board/table_column.php
+++ b/app/Template/board/table_column.php
@@ -47,6 +47,7 @@
</li>
<?php endif ?>
<?php endif ?>
+ <?= $this->hook->render('template:board:column:dropdown', array('swimlane' => $swimlane, 'column' => $column)) ?>
</ul>
</span>
<?php endif ?>
diff --git a/app/Template/board/table_tasks.php b/app/Template/board/table_tasks.php
index fd9ce5e7..1651f5d6 100644
--- a/app/Template/board/table_tasks.php
+++ b/app/Template/board/table_tasks.php
@@ -4,7 +4,8 @@
<td class="
board-column-<?= $column['id'] ?>
<?= $column['task_limit'] > 0 && $column['nb_tasks'] > $column['task_limit'] ? 'board-task-list-limit' : '' ?>
- ">
+ "
+ >
<!-- tasks list -->
<div class="board-task-list board-column-expanded" data-column-id="<?= $column['id'] ?>" data-swimlane-id="<?= $swimlane['id'] ?>" data-task-limit="<?= $column['task_limit'] ?>">
diff --git a/app/Template/config/about.php b/app/Template/config/about.php
index 8e2d1325..8d5a575d 100644
--- a/app/Template/config/about.php
+++ b/app/Template/config/about.php
@@ -9,7 +9,7 @@
</li>
<li>
<?= t('Author:') ?>
- <strong>Frédéric Guillot</strong> (<a href="https://github.com/fguillot/kanboard/blob/master/CONTRIBUTORS.md" target="_blank"><?= t('contributors') ?></a>)
+ <strong>Frédéric Guillot</strong> (<a href="https://github.com/kanboard/kanboard/blob/master/CONTRIBUTORS.md" target="_blank"><?= t('contributors') ?></a>)
</li>
<li>
<?= t('License:') ?>
diff --git a/app/Template/config/sidebar.php b/app/Template/config/sidebar.php
index e304f0d0..239edc19 100644
--- a/app/Template/config/sidebar.php
+++ b/app/Template/config/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Actions') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('ConfigController', 'index') ?>>
<?= $this->url->link(t('About'), 'ConfigController', 'index') ?>
diff --git a/app/Template/dashboard/projects.php b/app/Template/dashboard/projects.php
index 962e4d83..3a7f1d86 100644
--- a/app/Template/dashboard/projects.php
+++ b/app/Template/dashboard/projects.php
@@ -6,8 +6,8 @@
<?php else: ?>
<table class="table-fixed table-small">
<tr>
- <th class="column-5"><?= $paginator->order('Id', 'id') ?></th>
- <th class="column-3"><?= $paginator->order('<i class="fa fa-lock fa-fw" title="'.t('Private project').'"></i>', 'is_private') ?></th>
+ <th class="column-5"><?= $paginator->order('Id', \Kanboard\Model\ProjectModel::TABLE.'.id') ?></th>
+ <th class="column-3"><?= $paginator->order('<i class="fa fa-lock fa-fw" title="'.t('Private project').'"></i>', \Kanboard\Model\ProjectModel::TABLE.'.is_private') ?></th>
<th class="column-25"><?= $paginator->order(t('Project'), \Kanboard\Model\ProjectModel::TABLE.'.name') ?></th>
<th class="column-10"><?= t('Tasks') ?></th>
<th><?= t('Columns') ?></th>
diff --git a/app/Template/dashboard/sidebar.php b/app/Template/dashboard/sidebar.php
index 86cc20f8..df4e91a5 100644
--- a/app/Template/dashboard/sidebar.php
+++ b/app/Template/dashboard/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= $this->text->e($user['name'] ?: $user['username']) ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('DashboardController', 'show') ?>>
<?= $this->url->link(t('Overview'), 'DashboardController', 'show', array('user_id' => $user['id'])) ?>
diff --git a/app/Template/dashboard/subtasks.php b/app/Template/dashboard/subtasks.php
index 8e0aa3ce..ca550e4c 100644
--- a/app/Template/dashboard/subtasks.php
+++ b/app/Template/dashboard/subtasks.php
@@ -6,10 +6,10 @@
<?php else: ?>
<table class="table-fixed table-small">
<tr>
- <th class="column-5"><?= $paginator->order('Id', 'tasks.id') ?></th>
+ <th class="column-5"><?= $paginator->order('Id', \Kanboard\Model\TaskModel::TABLE.'.id') ?></th>
<th class="column-20"><?= $paginator->order(t('Project'), 'project_name') ?></th>
<th><?= $paginator->order(t('Task'), 'task_name') ?></th>
- <th><?= $paginator->order(t('Subtask'), 'title') ?></th>
+ <th><?= $paginator->order(t('Subtask'), \Kanboard\Model\SubtaskModel::TABLE.'.title') ?></th>
<th class="column-20"><?= t('Time tracking') ?></th>
</tr>
<?php foreach ($paginator->getCollection() as $subtask): ?>
diff --git a/app/Template/dashboard/tasks.php b/app/Template/dashboard/tasks.php
index b3257c33..d9cb4f9e 100644
--- a/app/Template/dashboard/tasks.php
+++ b/app/Template/dashboard/tasks.php
@@ -6,12 +6,12 @@
<?php else: ?>
<table class="table-fixed table-small">
<tr>
- <th class="column-5"><?= $paginator->order('Id', 'tasks.id') ?></th>
+ <th class="column-5"><?= $paginator->order('Id', \Kanboard\Model\TaskModel::TABLE.'.id') ?></th>
<th class="column-20"><?= $paginator->order(t('Project'), 'project_name') ?></th>
- <th><?= $paginator->order(t('Task'), 'title') ?></th>
- <th class="column-5"><?= $paginator->order(t('Priority'), 'tasks.priority') ?></th>
+ <th><?= $paginator->order(t('Task'), \Kanboard\Model\TaskModel::TABLE.'.title') ?></th>
+ <th class="column-5"><?= $paginator->order(t('Priority'), \Kanboard\Model\TaskModel::TABLE.'.priority') ?></th>
<th class="column-20"><?= t('Time tracking') ?></th>
- <th class="column-10"><?= $paginator->order(t('Due date'), 'date_due') ?></th>
+ <th class="column-10"><?= $paginator->order(t('Due date'), \Kanboard\Model\TaskModel::TABLE.'.date_due') ?></th>
<th class="column-10"><?= $paginator->order(t('Column'), 'column_title') ?></th>
</tr>
<?php foreach ($paginator->getCollection() as $task): ?>
diff --git a/app/Template/event/comment_delete.php b/app/Template/event/comment_delete.php
new file mode 100644
index 00000000..ead7d56a
--- /dev/null
+++ b/app/Template/event/comment_delete.php
@@ -0,0 +1,11 @@
+<p class="activity-title">
+ <?= e('%s removed a comment on the task %s',
+ $this->text->e($author),
+ $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))
+ ) ?>
+ <span class="activity-date"><?= $this->dt->datetime($date_creation) ?></span>
+</p>
+<div class="activity-description">
+ <p class="activity-task-title"><?= $this->text->e($task['title']) ?></p>
+ <div class="markdown"><?= $this->text->markdown($comment['comment']) ?></div>
+</div>
diff --git a/app/Template/event/comment_update.php b/app/Template/event/comment_update.php
index 5a0821bd..5be598ac 100644
--- a/app/Template/event/comment_update.php
+++ b/app/Template/event/comment_update.php
@@ -7,4 +7,7 @@
</p>
<div class="activity-description">
<p class="activity-task-title"><?= $this->text->e($task['title']) ?></p>
+ <?php if (! empty($comment['comment'])): ?>
+ <div class="markdown"><?= $this->text->markdown($comment['comment']) ?></div>
+ <?php endif ?>
</div>
diff --git a/app/Template/event/subtask_delete.php b/app/Template/event/subtask_delete.php
new file mode 100644
index 00000000..8ac11853
--- /dev/null
+++ b/app/Template/event/subtask_delete.php
@@ -0,0 +1,15 @@
+<p class="activity-title">
+ <?= e('%s removed a subtask for the task %s',
+ $this->text->e($author),
+ $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))
+ ) ?>
+ <span class="activity-date"><?= $this->dt->datetime($date_creation) ?></span>
+</p>
+<div class="activity-description">
+ <p class="activity-task-title"><?= $this->text->e($task['title']) ?></p>
+ <ul>
+ <li>
+ <?= $this->text->e($subtask['title']) ?> (<strong><?= $this->text->e($subtask['status_name']) ?></strong>)
+ </li>
+ </ul>
+</div>
diff --git a/app/Template/event/task_assignee_change.php b/app/Template/event/task_assignee_change.php
index 7c962223..7539cd0b 100644
--- a/app/Template/event/task_assignee_change.php
+++ b/app/Template/event/task_assignee_change.php
@@ -8,7 +8,7 @@
$this->text->e($assignee)
) ?>
<?php else: ?>
- <?= e('%s remove the assignee of the task %s', $this->text->e($author), $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))) ?>
+ <?= e('%s removed the assignee of the task %s', $this->text->e($author), $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))) ?>
<?php endif ?>
<span class="activity-date"><?= $this->dt->datetime($date_creation) ?></span>
</p>
diff --git a/app/Template/event/task_internal_link_create_update.php b/app/Template/event/task_internal_link_create_update.php
new file mode 100644
index 00000000..de257977
--- /dev/null
+++ b/app/Template/event/task_internal_link_create_update.php
@@ -0,0 +1,16 @@
+<p class="activity-title">
+ <?= e('%s set a new internal link for the task %s',
+ $this->text->e($author),
+ $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))
+ ) ?>
+ <span class="activity-date"><?= $this->dt->datetime($date_creation) ?></span>
+</p>
+<div class="activity-description">
+ <p class="activity-task-title">
+ <?= e(
+ 'This task is now linked to the task %s with the relation "%s"',
+ $this->url->link(t('#%d', $task_link['opposite_task_id']), 'TaskViewController', 'show', array('task_id' => $task_link['opposite_task_id'])),
+ $this->text->e($task_link['label'])
+ ) ?>
+ </p>
+</div>
diff --git a/app/Template/event/task_internal_link_delete.php b/app/Template/event/task_internal_link_delete.php
new file mode 100644
index 00000000..e537bf81
--- /dev/null
+++ b/app/Template/event/task_internal_link_delete.php
@@ -0,0 +1,16 @@
+<p class="activity-title">
+ <?= e('%s removed an internal link for the task %s',
+ $this->text->e($author),
+ $this->url->link(t('#%d', $task['id']), 'TaskViewController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']))
+ ) ?>
+ <span class="activity-date"><?= $this->dt->datetime($date_creation) ?></span>
+</p>
+<div class="activity-description">
+ <p class="activity-task-title">
+ <?= e(
+ 'The link with the relation "%s" to the task %s have been removed',
+ $this->text->e($task_link['label']),
+ $this->url->link(t('#%d', $task_link['opposite_task_id']), 'TaskViewController', 'show', array('task_id' => $task_link['opposite_task_id']))
+ ) ?>
+ </p>
+</div>
diff --git a/app/Template/export/sidebar.php b/app/Template/export/sidebar.php
index 55fbaeef..463c0cee 100644
--- a/app/Template/export/sidebar.php
+++ b/app/Template/export/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Exports') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('ExportController', 'tasks') ?>>
<?= $this->url->link(t('Tasks'), 'ExportController', 'tasks', array('project_id' => $project['id'])) ?>
diff --git a/app/Template/export/subtasks.php b/app/Template/export/subtasks.php
index a82cb3d1..878a7132 100644
--- a/app/Template/export/subtasks.php
+++ b/app/Template/export/subtasks.php
@@ -1,5 +1,5 @@
<div class="page-header">
- <h2><?= t('Subtasks exportation for "%s"', $project['name']) ?></h2>
+ <h2><?= t('Subtasks export') ?></h2>
</div>
<p class="alert alert-info"><?= t('This report contains all subtasks information for the given date range.') ?></p>
@@ -21,4 +21,4 @@
<div class="form-actions">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
-</form> \ No newline at end of file
+</form>
diff --git a/app/Template/export/summary.php b/app/Template/export/summary.php
index 60aa306f..d9362a9b 100644
--- a/app/Template/export/summary.php
+++ b/app/Template/export/summary.php
@@ -1,5 +1,5 @@
<div class="page-header">
- <h2><?= t('Daily project summary export for "%s"', $project['name']) ?></h2>
+ <h2><?= t('Daily project summary export') ?></h2>
</div>
<p class="alert alert-info"><?= t('This export contains the number of tasks per column grouped per day.') ?></p>
@@ -21,4 +21,4 @@
<div class="form-actions">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
-</form> \ No newline at end of file
+</form>
diff --git a/app/Template/export/tasks.php b/app/Template/export/tasks.php
index bed8ab90..ae411326 100644
--- a/app/Template/export/tasks.php
+++ b/app/Template/export/tasks.php
@@ -1,5 +1,5 @@
<div class="page-header">
- <h2><?= t('Tasks exportation for "%s"', $project['name']) ?></h2>
+ <h2><?= t('Tasks exportation') ?></h2>
</div>
<p class="alert alert-info"><?= t('This report contains all tasks information for the given date range.') ?></p>
@@ -21,4 +21,4 @@
<div class="form-actions">
<button type="submit" class="btn btn-blue"><?= t('Execute') ?></button>
</div>
-</form> \ No newline at end of file
+</form>
diff --git a/app/Template/feed/project.php b/app/Template/feed/project.php
deleted file mode 100644
index 213a04d4..00000000
--- a/app/Template/feed/project.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?= '<?xml version="1.0" encoding="utf-8"?>' ?>
-<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
- <title><?= t('%s\'s activity', $project['name']) ?></title>
- <link rel="alternate" type="text/html" href="<?= $this->url->base() ?>"/>
- <link rel="self" type="application/atom+xml" href="<?= $this->url->href('FeedController', 'project', array('token' => $project['token']), false, '', true) ?>"/>
- <updated><?= date(DATE_ATOM) ?></updated>
- <id><?= $this->url->href('FeedController', 'project', array('token' => $project['token']), false, '', true) ?></id>
- <icon><?= $this->url->base() ?>assets/img/favicon.png</icon>
-
- <?php foreach ($events as $e): ?>
- <entry>
- <title type="text"><?= $e['event_title'] ?></title>
- <link rel="alternate" href="<?= $this->url->href('TaskViewController', 'show', array('task_id' => $e['task_id']), false, '', true) ?>"/>
- <id><?= $e['id'].'-'.$e['event_name'].'-'.$e['task_id'].'-'.$e['date_creation'] ?></id>
- <published><?= date(DATE_ATOM, $e['date_creation']) ?></published>
- <updated><?= date(DATE_ATOM, $e['date_creation']) ?></updated>
- <author>
- <name><?= $this->text->e($e['author']) ?></name>
- </author>
- <content type="html">
- <![CDATA[
- <?= $e['event_content'] ?>
- ]]>
- </content>
- </entry>
- <?php endforeach ?>
-</feed>
diff --git a/app/Template/feed/user.php b/app/Template/feed/user.php
deleted file mode 100644
index 0c45f03c..00000000
--- a/app/Template/feed/user.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?= '<?xml version="1.0" encoding="utf-8"?>' ?>
-<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
- <title><?= t('Project activities for %s', $user['name'] ?: $user['username']) ?></title>
- <link rel="alternate" type="text/html" href="<?= $this->url->base() ?>"/>
- <link rel="self" type="application/atom+xml" href="<?= $this->url->href('FeedController', 'user', array('token' => $user['token']), false, '', true) ?>"/>
- <updated><?= date(DATE_ATOM) ?></updated>
- <id><?= $this->url->href('FeedController', 'user', array('token' => $user['token']), false, '', true) ?></id>
- <icon><?= $this->url->base() ?>assets/img/favicon.png</icon>
-
- <?php foreach ($events as $e): ?>
- <entry>
- <title type="text"><?= $e['event_title'] ?></title>
- <link rel="alternate" href="<?= $this->url->href('TaskViewController', 'show', array('task_id' => $e['task_id']), false, '', true) ?>"/>
- <id><?= $e['id'].'-'.$e['event_name'].'-'.$e['task_id'].'-'.$e['date_creation'] ?></id>
- <published><?= date(DATE_ATOM, $e['date_creation']) ?></published>
- <updated><?= date(DATE_ATOM, $e['date_creation']) ?></updated>
- <author>
- <name><?= $this->text->e($e['author']) ?></name>
- </author>
- <content type="html">
- <![CDATA[
- <?= $e['event_content'] ?>
- ]]>
- </content>
- </entry>
- <?php endforeach ?>
-</feed>
diff --git a/app/Template/header.php b/app/Template/header.php
index 13521ae7..a2b3fcb3 100644
--- a/app/Template/header.php
+++ b/app/Template/header.php
@@ -5,7 +5,7 @@
<?= $this->url->link('K<span>B</span>', 'DashboardController', 'show', array(), false, '', t('Dashboard')) ?>
</span>
<span class="title">
- <?php if (isset($project) && ! empty($project)): ?>
+ <?php if (! empty($project) && ! empty($task)): ?>
<?= $this->url->link($this->text->e($project['name']), 'BoardViewController', 'show', array('project_id' => $project['id'])) ?>
<?php else: ?>
<?= $this->text->e($title) ?>
@@ -59,6 +59,7 @@
<?= $this->url->link(t('New private project'), 'ProjectCreationController', 'createPrivate', array(), false, 'popover') ?>
</li>
<?php endif ?>
+ <?= $this->hook->render('template:header:creation-dropdown') ?>
</ul>
</div>
<?php endif ?>
diff --git a/app/Template/notification/comment_delete.php b/app/Template/notification/comment_delete.php
new file mode 100644
index 00000000..928623ec
--- /dev/null
+++ b/app/Template/notification/comment_delete.php
@@ -0,0 +1,7 @@
+<h2><?= $this->text->e($task['title']) ?> (#<?= $task['id'] ?>)</h2>
+
+<h3><?= t('Comment removed') ?></h3>
+
+<?= $this->text->markdown($comment['comment']) ?>
+
+<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?>
diff --git a/app/Template/notification/subtask_delete.php b/app/Template/notification/subtask_delete.php
new file mode 100644
index 00000000..8c5f262c
--- /dev/null
+++ b/app/Template/notification/subtask_delete.php
@@ -0,0 +1,11 @@
+<h2><?= $this->text->e($task['title']) ?> (#<?= $task['id'] ?>)</h2>
+
+<h3><?= t('Subtask removed') ?></h3>
+
+<ul>
+ <li><?= t('Title:') ?> <?= $this->text->e($subtask['title']) ?></li>
+ <li><?= t('Status:') ?> <?= $this->text->e($subtask['status_name']) ?></li>
+ <li><?= t('Assignee:') ?> <?= $this->text->e($subtask['name'] ?: $subtask['username'] ?: '?') ?></li>
+</ul>
+
+<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?>
diff --git a/app/Template/notification/task_file_create.php b/app/Template/notification/task_file_create.php
index feab8dd2..c19f7279 100644
--- a/app/Template/notification/task_file_create.php
+++ b/app/Template/notification/task_file_create.php
@@ -2,4 +2,4 @@
<p><?= t('New attachment added "%s"', $file['name']) ?></p>
-<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?> \ No newline at end of file
+<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?>
diff --git a/app/Template/notification/task_internal_link_create_update.php b/app/Template/notification/task_internal_link_create_update.php
new file mode 100644
index 00000000..73cad84d
--- /dev/null
+++ b/app/Template/notification/task_internal_link_create_update.php
@@ -0,0 +1,11 @@
+<h2><?= $this->text->e($task['title']) ?> (#<?= $task['id'] ?>)</h2>
+
+<p>
+ <?= e(
+ 'This task is now linked to the task %s with the relation "%s"',
+ $this->url->link(t('#%d', $task_link['opposite_task_id']), 'TaskViewController', 'show', array('task_id' => $task_link['opposite_task_id'])),
+ $this->text->e($task_link['label'])
+ ) ?>
+</p>
+
+<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?>
diff --git a/app/Template/notification/task_internal_link_delete.php b/app/Template/notification/task_internal_link_delete.php
new file mode 100644
index 00000000..bb54e0a7
--- /dev/null
+++ b/app/Template/notification/task_internal_link_delete.php
@@ -0,0 +1,11 @@
+<h2><?= $this->text->e($task['title']) ?> (#<?= $task['id'] ?>)</h2>
+
+<p>
+ <?= e(
+ 'The link with the relation "%s" to the task %s have been removed',
+ $this->text->e($task_link['label']),
+ $this->url->link(t('#%d', $task_link['opposite_task_id']), 'TaskViewController', 'show', array('task_id' => $task_link['opposite_task_id']))
+ ) ?>
+</p>
+
+<?= $this->render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?>
diff --git a/app/Template/plugin/sidebar.php b/app/Template/plugin/sidebar.php
index e1b47632..dd1a2a6b 100644
--- a/app/Template/plugin/sidebar.php
+++ b/app/Template/plugin/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Actions') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('PluginController', 'show') ?>>
<?= $this->url->link(t('Installed Plugins'), 'PluginController', 'show') ?>
diff --git a/app/Template/project/sidebar.php b/app/Template/project/sidebar.php
index d0f50596..3be0da48 100644
--- a/app/Template/project/sidebar.php
+++ b/app/Template/project/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Actions') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('ProjectViewController', 'show') ?>>
<?= $this->url->link(t('Summary'), 'ProjectViewController', 'show', array('project_id' => $project['id'])) ?>
diff --git a/app/Template/project_creation/create.php b/app/Template/project_creation/create.php
index d00883ba..b90b15c4 100644
--- a/app/Template/project_creation/create.php
+++ b/app/Template/project_creation/create.php
@@ -19,7 +19,7 @@
<p class="alert"><?= t('Which parts of the project do you want to duplicate?') ?></p>
<?php if (! $is_private): ?>
- <?= $this->form->checkbox('projectPermission', t('Permissions'), 1, true) ?>
+ <?= $this->form->checkbox('projectPermissionModel', t('Permissions'), 1, true) ?>
<?php endif ?>
<?= $this->form->checkbox('categoryModel', t('Categories'), 1, true) ?>
diff --git a/app/Template/project_header/dropdown.php b/app/Template/project_header/dropdown.php
index 79a1b389..f8901289 100644
--- a/app/Template/project_header/dropdown.php
+++ b/app/Template/project_header/dropdown.php
@@ -20,14 +20,6 @@
<i class="fa fa-arrows-h fa-fw"></i> <a href="#" class="filter-toggle-scrolling" title="<?= t('Keyboard shortcut: "%s"', 'c') ?>"><?= t('Horizontal scrolling') ?></a>
</span>
</li>
- <li>
- <span class="filter-max-height" style="display: none">
- <i class="fa fa-arrows-v fa-fw"></i> <a href="#" class="filter-toggle-height"><?= t('Set maximum column height') ?></a>
- </span>
- <span class="filter-min-height">
- <i class="fa fa-arrows-v fa-fw"></i> <a href="#" class="filter-toggle-height"><?= t('Remove maximum column height') ?></a>
- </span>
- </li>
<?php endif ?>
<?php if ($this->user->hasProjectAccess('TaskCreationController', 'show', $project['id'])): ?>
diff --git a/app/Template/project_user_overview/sidebar.php b/app/Template/project_user_overview/sidebar.php
index 9a87d4eb..ccbf9cab 100644
--- a/app/Template/project_user_overview/sidebar.php
+++ b/app/Template/project_user_overview/sidebar.php
@@ -1,6 +1,4 @@
<div class="sidebar">
- <h2><?= t('Actions') ?></h2>
-
<?= $this->form->select(
'user_id',
$users,
diff --git a/app/Template/project_view/duplicate.php b/app/Template/project_view/duplicate.php
index d66ff591..561378d1 100644
--- a/app/Template/project_view/duplicate.php
+++ b/app/Template/project_view/duplicate.php
@@ -11,7 +11,7 @@
<?= $this->form->csrf() ?>
<?php if ($project['is_private'] == 0): ?>
- <?= $this->form->checkbox('projectPermission', t('Permissions'), 1, true) ?>
+ <?= $this->form->checkbox('projectPermissionModel', t('Permissions'), 1, true) ?>
<?php endif ?>
<?= $this->form->checkbox('categoryModel', t('Categories'), 1, true) ?>
diff --git a/app/Template/task/show.php b/app/Template/task/show.php
index 80786715..76c572a1 100644
--- a/app/Template/task/show.php
+++ b/app/Template/task/show.php
@@ -7,9 +7,12 @@
'editable' => $this->user->hasProjectAccess('TaskModificationController', 'edit', $project['id']),
)) ?>
+<?php if(!empty($task['description'])): ?>
<?= $this->hook->render('template:task:show:before-description', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('task/description', array('task' => $task)) ?>
+<?php endif ?>
+<?php if(!empty($subtasks)): ?>
<?= $this->hook->render('template:task:show:before-subtasks', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('subtask/show', array(
'task' => $task,
@@ -17,7 +20,9 @@
'project' => $project,
'editable' => true,
)) ?>
+<?php endif ?>
+<?php if(!empty($internal_links)): ?>
<?= $this->hook->render('template:task:show:before-internal-links', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('task_internal_link/show', array(
'task' => $task,
@@ -27,21 +32,27 @@
'editable' => true,
'is_public' => false,
)) ?>
+<?php endif ?>
+<?php if(!empty($external_links)): ?>
<?= $this->hook->render('template:task:show:before-external-links', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('task_external_link/show', array(
'task' => $task,
'links' => $external_links,
'project' => $project,
)) ?>
+<?php endif ?>
+<?php if(!empty($files)): ?>
<?= $this->hook->render('template:task:show:before-attachments', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('task_file/show', array(
'task' => $task,
'files' => $files,
'images' => $images
)) ?>
+<?php endif ?>
+<?php if(!empty($comments)): ?>
<?= $this->hook->render('template:task:show:before-comments', array('task' => $task, 'project' => $project)) ?>
<?= $this->render('comments/show', array(
'task' => $task,
@@ -49,5 +60,6 @@
'project' => $project,
'editable' => $this->user->hasProjectAccess('CommentController', 'edit', $project['id']),
)) ?>
+<?php endif ?>
<?= $this->hook->render('template:task:show:bottom', array('task' => $task, 'project' => $project)) ?>
diff --git a/app/Template/task/sidebar.php b/app/Template/task/sidebar.php
index b44e6f0b..728741ba 100644
--- a/app/Template/task/sidebar.php
+++ b/app/Template/task/sidebar.php
@@ -1,5 +1,7 @@
<div class="sidebar sidebar-icons">
- <h2><?= t('Task #%d', $task['id']) ?></h2>
+ <div class="sidebar-title">
+ <h2><?= t('Task #%d', $task['id']) ?></h2>
+ </div>
<ul>
<li <?= $this->app->checkMenuSelection('TaskViewController', 'show') ?>>
<i class="fa fa-newspaper-o fa-fw"></i>
@@ -28,7 +30,9 @@
</ul>
<?php if ($this->user->hasProjectAccess('TaskModificationController', 'edit', $task['project_id'])): ?>
- <h2><?= t('Actions') ?></h2>
+ <div class="sidebar-title">
+ <h2><?= t('Actions') ?></h2>
+ </div>
<ul>
<li>
<i class="fa fa-pencil-square-o fa-fw"></i>
diff --git a/app/Template/task_import/sidebar.php b/app/Template/task_import/sidebar.php
index 4cd92af8..04896948 100644
--- a/app/Template/task_import/sidebar.php
+++ b/app/Template/task_import/sidebar.php
@@ -1,5 +1,4 @@
<div class="sidebar">
- <h2><?= t('Imports') ?></h2>
<ul>
<li <?= $this->app->checkMenuSelection('TaskImportController', 'show') ?>>
<?= $this->url->link(t('Tasks').' (CSV)', 'TaskImportController', 'show', array('project_id' => $project['id'])) ?>
diff --git a/app/Template/user_modification/show.php b/app/Template/user_modification/show.php
index 396d550d..506c9161 100644
--- a/app/Template/user_modification/show.php
+++ b/app/Template/user_modification/show.php
@@ -11,16 +11,16 @@
<?= $this->form->text('username', $values, $errors, array('required', isset($values['is_ldap_user']) && $values['is_ldap_user'] == 1 ? 'readonly' : '', 'maxlength="50"')) ?>
<?= $this->form->label(t('Name'), 'name') ?>
- <?= $this->form->text('name', $values, $errors) ?>
+ <?= $this->form->text('name', $values, $errors, array($this->user->hasAccess('UserModificationController', 'show/edit_name') ? '' : 'readonly')) ?>
<?= $this->form->label(t('Email'), 'email') ?>
- <?= $this->form->email('email', $values, $errors) ?>
+ <?= $this->form->email('email', $values, $errors, array($this->user->hasAccess('UserModificationController', 'show/edit_email') ? '' : 'readonly')) ?>
<?= $this->form->label(t('Timezone'), 'timezone') ?>
- <?= $this->form->select('timezone', $timezones, $values, $errors) ?>
+ <?= $this->form->select('timezone', $timezones, $values, $errors, array($this->user->hasAccess('UserModificationController', 'show/edit_timezone') ? '' : 'disabled')) ?>
<?= $this->form->label(t('Language'), 'language') ?>
- <?= $this->form->select('language', $languages, $values, $errors) ?>
+ <?= $this->form->select('language', $languages, $values, $errors, array($this->user->hasAccess('UserModificationController', 'show/edit_language') ? '' : 'disabled')) ?>
<?php if ($this->user->isAdmin()): ?>
<?= $this->form->label(t('Role'), 'role') ?>
diff --git a/app/Template/user_view/sidebar.php b/app/Template/user_view/sidebar.php
index d200a7f5..a80daefa 100644
--- a/app/Template/user_view/sidebar.php
+++ b/app/Template/user_view/sidebar.php
@@ -1,5 +1,7 @@
<div class="sidebar">
- <h2><?= t('Information') ?></h2>
+ <div class="sidebar-title">
+ <h2><?= t('Information') ?></h2>
+ </div>
<ul>
<?php if ($this->user->hasAccess('UserViewController', 'show')): ?>
<li <?= $this->app->checkMenuSelection('UserViewController', 'show') ?>>
@@ -12,24 +14,34 @@
</li>
<?php endif ?>
<?php if ($this->user->isAdmin() || $this->user->isCurrentUser($user['id'])): ?>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'timesheet') ?>>
- <?= $this->url->link(t('Time tracking'), 'UserViewController', 'timesheet', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'lastLogin') ?>>
- <?= $this->url->link(t('Last logins'), 'UserViewController', 'lastLogin', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'sessions') ?>>
- <?= $this->url->link(t('Persistent connections'), 'UserViewController', 'sessions', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'passwordReset') ?>>
- <?= $this->url->link(t('Password reset history'), 'UserViewController', 'passwordReset', array('user_id' => $user['id'])) ?>
- </li>
+ <?php if ($this->user->hasAccess('UserViewController', 'timesheet')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'timesheet') ?>>
+ <?= $this->url->link(t('Time tracking'), 'UserViewController', 'timesheet', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'lastLogin')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'lastLogin') ?>>
+ <?= $this->url->link(t('Last logins'), 'UserViewController', 'lastLogin', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'sessions')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'sessions') ?>>
+ <?= $this->url->link(t('Persistent connections'), 'UserViewController', 'sessions', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'passwordReset')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'passwordReset') ?>>
+ <?= $this->url->link(t('Password reset history'), 'UserViewController', 'passwordReset', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
<?php endif ?>
<?= $this->hook->render('template:user:sidebar:information', array('user' => $user)) ?>
</ul>
- <h2><?= t('Actions') ?></h2>
+ <div class="sidebar-title">
+ <h2><?= t('Actions') ?></h2>
+ </div>
<ul>
<?php if ($this->user->isAdmin() || $this->user->isCurrentUser($user['id'])): ?>
@@ -42,13 +54,13 @@
</li>
<?php endif ?>
- <?php if ($user['is_ldap_user'] == 0): ?>
+ <?php if ($user['is_ldap_user'] == 0 && $this->user->hasAccess('UserCredentialController', 'changePassword')): ?>
<li <?= $this->app->checkMenuSelection('UserCredentialController', 'changePassword') ?>>
<?= $this->url->link(t('Change password'), 'UserCredentialController', 'changePassword', array('user_id' => $user['id'])) ?>
</li>
<?php endif ?>
- <?php if ($this->user->isCurrentUser($user['id'])): ?>
+ <?php if ($this->user->isCurrentUser($user['id']) && $this->user->hasAccess('TwoFactorController', 'index')): ?>
<li <?= $this->app->checkMenuSelection('TwoFactorController', 'index') ?>>
<?= $this->url->link(t('Two factor authentication'), 'TwoFactorController', 'index', array('user_id' => $user['id'])) ?>
</li>
@@ -58,18 +70,26 @@
</li>
<?php endif ?>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'share') ?>>
- <?= $this->url->link(t('Public access'), 'UserViewController', 'share', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'notifications') ?>>
- <?= $this->url->link(t('Notifications'), 'UserViewController', 'notifications', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'external') ?>>
- <?= $this->url->link(t('External accounts'), 'UserViewController', 'external', array('user_id' => $user['id'])) ?>
- </li>
- <li <?= $this->app->checkMenuSelection('UserViewController', 'integrations') ?>>
- <?= $this->url->link(t('Integrations'), 'UserViewController', 'integrations', array('user_id' => $user['id'])) ?>
- </li>
+ <?php if ($this->user->hasAccess('UserViewController', 'share')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'share') ?>>
+ <?= $this->url->link(t('Public access'), 'UserViewController', 'share', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'notifications')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'notifications') ?>>
+ <?= $this->url->link(t('Notifications'), 'UserViewController', 'notifications', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'external')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'external') ?>>
+ <?= $this->url->link(t('External accounts'), 'UserViewController', 'external', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
+ <?php if ($this->user->hasAccess('UserViewController', 'integrations')): ?>
+ <li <?= $this->app->checkMenuSelection('UserViewController', 'integrations') ?>>
+ <?= $this->url->link(t('Integrations'), 'UserViewController', 'integrations', array('user_id' => $user['id'])) ?>
+ </li>
+ <?php endif ?>
<?php endif ?>
<?php if ($this->user->hasAccess('UserCredentialController', 'changeAuthentication')): ?>