From 9b399951f430b26379a2bf8b13ace99290227e61 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Sun, 14 Jun 2015 11:50:31 -0400 Subject: Improve activity stream/notification for task update events and add new notification for swimlane change --- app/Template/event/events.php | 2 + app/Template/event/task_move_swimlane.php | 19 ++++++ app/Template/event/task_update.php | 5 ++ app/Template/notification/task_move_swimlane.php | 19 ++++++ app/Template/notification/task_update.php | 63 +------------------ app/Template/task/changes.php | 78 ++++++++++++++++++++++++ 6 files changed, 124 insertions(+), 62 deletions(-) create mode 100644 app/Template/event/task_move_swimlane.php create mode 100644 app/Template/notification/task_move_swimlane.php create mode 100644 app/Template/task/changes.php (limited to 'app/Template') diff --git a/app/Template/event/events.php b/app/Template/event/events.php index 2dc79871..971f6587 100644 --- a/app/Template/event/events.php +++ b/app/Template/event/events.php @@ -7,6 +7,8 @@

text->contains($event['event_name'], 'subtask')): ?> + text->contains($event['event_name'], 'task.move')): ?> + text->contains($event['event_name'], 'task')): ?> text->contains($event['event_name'], 'comment')): ?> diff --git a/app/Template/event/task_move_swimlane.php b/app/Template/event/task_move_swimlane.php new file mode 100644 index 00000000..ca440dbf --- /dev/null +++ b/app/Template/event/task_move_swimlane.php @@ -0,0 +1,19 @@ +user->avatar($email, $author) ?> + +

+ + e($author), + $this->url->link(t('#%d', $task['id']), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) + ) ?> + + e($author), + $this->url->link(t('#%d', $task['id']), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])), + $this->e($task['swimlane_name']) + ) ?> + +

+

+ e($task['title']) ?> +

\ No newline at end of file diff --git a/app/Template/event/task_update.php b/app/Template/event/task_update.php index 7d036d43..e8254bcb 100644 --- a/app/Template/event/task_update.php +++ b/app/Template/event/task_update.php @@ -8,4 +8,9 @@

e($task['title']) ?> + +

+ render('task/changes', array('changes' => $changes, 'task' => $task)) ?> +
+

\ No newline at end of file diff --git a/app/Template/notification/task_move_swimlane.php b/app/Template/notification/task_move_swimlane.php new file mode 100644 index 00000000..04de7cc6 --- /dev/null +++ b/app/Template/notification/task_move_swimlane.php @@ -0,0 +1,19 @@ +

e($task['title']) ?> (#)

+ + + +render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?> \ No newline at end of file diff --git a/app/Template/notification/task_update.php b/app/Template/notification/task_update.php index 0352788b..54f5c6d1 100644 --- a/app/Template/notification/task_update.php +++ b/app/Template/notification/task_update.php @@ -1,65 +1,4 @@

e($task['title']) ?> (#)

- - - -

- - - -

- text->markdown($task['description']) ?> - - - +render('task/changes', array('changes' => $changes, 'task' => $task)) ?> render('notification/footer', array('task' => $task, 'application_url' => $application_url)) ?> \ No newline at end of file diff --git a/app/Template/task/changes.php b/app/Template/task/changes.php new file mode 100644 index 00000000..c7fc0d52 --- /dev/null +++ b/app/Template/task/changes.php @@ -0,0 +1,78 @@ + + + + +

+
text->markdown($task['description']) ?>
+ + \ No newline at end of file -- cgit v1.2.3