aboutsummaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorGravatar equinoxmatt <me@mattbutterworth.co.uk> 2020-05-09 11:49:49 +0100
committerGravatar GitHub <noreply@github.com> 2020-05-09 12:49:49 +0200
commitbe10486f5e45148c78ab0c0a57a4056d5fc2889a (patch)
tree0cedad1658d91c0aea5e776e48dc3bb06bc4b435 /app/views
parent17539668eac84b9f7b86de036c9e23fa226054d6 (diff)
2914 show last login date (#2936)
* Add new last_login param to default user config * Add English translation strings for last login feature * Update last_login when user successfully logs in. * Add last_login column to manage users screen * Add last_login to user details screen * Remove accidental docker-compose.yml * Fix whitespace * Use last modified time for config file * Remove last_login field from default user config * Touch user configuration file upon succesful login * Add translations with todos * Fix whitespace * Use last_user_activity * Semi-colomn Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
Diffstat (limited to 'app/views')
-rw-r--r--app/views/user/details.phtml7
-rw-r--r--app/views/user/manage.phtml6
2 files changed, 10 insertions, 3 deletions
diff --git a/app/views/user/details.phtml b/app/views/user/details.phtml
index ee5e381fd..8b3cc3a44 100644
--- a/app/views/user/details.phtml
+++ b/app/views/user/details.phtml
@@ -45,6 +45,13 @@
</div>
<div class="form-group">
+ <label class="group-name"><?= _t('admin.user.last_user_activity') ?></label>
+ <div class="group-controls">
+ <?= $this->details['last_user_activity'] ?>
+ </div>
+ </div>
+
+ <div class="form-group">
<label class="group-name" for="newPasswordPlain"><?= _t('admin.user.password_form') ?></label>
<div class="group-controls">
<div class="stick">
diff --git a/app/views/user/manage.phtml b/app/views/user/manage.phtml
index 627d229d2..5c4e1e128 100644
--- a/app/views/user/manage.phtml
+++ b/app/views/user/manage.phtml
@@ -77,20 +77,20 @@
<th><?= _t('admin.user.feed_count') ?></th>
<th><?= _t('admin.user.article_count') ?></th>
<th><?= _t('admin.user.database_size') ?></th>
- <th>&nbsp;</th>
+ <th><?= _t('admin.user.last_user_activity') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($this->users as $username => $values) : ?>
<tr>
- <td><?= $username ?></td>
+ <td><a href="<?= _url('user', 'details', 'username', $username) ?>"><?= $username ?></a></td>
<td><?= $values['is_admin'] ? '✔' : ' ' ?></td>
<td><?= $values['mail_login'] ?></td>
<td><?= _t("gen.lang.{$values['language']}") ?></td>
<td><?= format_number($values['feed_count']) ?></td>
<td><?= format_number($values['article_count']) ?></td>
<td><?= format_bytes($values['database_size']) ?></td>
- <td><a href="<?= _url('user', 'details', 'username', $username) ?>">Details</a></td>
+ <td><?= $values['last_user_activity'] ?></td>
</tr>
<?php endforeach ?>
</tbody>