Added pluggable Avatar providers

This commit is contained in:
Frederic Guillot
2016-03-18 23:06:32 -04:00
parent c4c200b530
commit fa86542f90
25 changed files with 216 additions and 42 deletions

View File

@@ -1,9 +1,7 @@
<div class="comment <?= isset($preview) ? 'comment-preview' : '' ?>" id="comment-<?= $comment['id'] ?>">
<p class="comment-title">
<?php if (! empty($comment['email'])): ?>
<?= $this->user->avatar($comment['email'], $comment['name'] ?: $comment['username']) ?>
<?php endif ?>
<?= $this->user->avatar($comment['user_id'], $comment['username'], $comment['name'], $comment['email']) ?>
<?php if (! empty($comment['username'])): ?>
<span class="comment-username"><?= $this->text->e($comment['name'] ?: $comment['username']) ?></span> @

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s commented the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s updated a comment on the task %s',
$this->text->e($author),

View File

@@ -16,7 +16,16 @@
<?php endif ?>
&nbsp;<?= $this->dt->datetime($event['date_creation']) ?>
</p>
<div class="activity-content"><?= $event['event_content'] ?></div>
<div class="activity-content">
<?= $this->user->avatar(
$event['creator_id'],
$event['author_username'],
$event['author_name'],
$event['email']
) ?>
<?= $event['event_content'] ?>
</div>
</div>
<?php endforeach ?>

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s created a subtask for the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s updated a subtask for the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?php $assignee = $task['assignee_name'] ?: $task['assignee_username'] ?>

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s closed the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s created the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s attached a new file to the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s moved the task %s to the column "%s"',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s moved the task %s to the position #%d in the column "%s"',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?php if ($task['swimlane_id'] == 0): ?>
<?= e('%s moved the task %s to the first swimlane',

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s opened the task %s',
$this->text->e($author),

View File

@@ -1,5 +1,3 @@
<?= $this->user->avatar($email, $author) ?>
<p class="activity-title">
<?= e('%s updated the task %s',
$this->text->e($author),