client/tags: add edit time column

This commit is contained in:
rr- 2016-06-08 22:25:14 +02:00
parent 009e13c6d8
commit e944e89c54
2 changed files with 18 additions and 4 deletions

View File

@ -13,14 +13,18 @@
th th
background: $top-nav-color background: $top-nav-color
.names .names
width: 30% width: 28%
.implications .implications
width: 30% width: 28%
.suggestions .suggestions
width: 30% width: 28%
.usages .usages
text-align: center text-align: center
width: 10% width: 8%
.edit-time
text-align: center
width: 8%
white-space: pre
ul ul
list-style-type: none list-style-type: none
margin: 0 margin: 0

View File

@ -30,6 +30,13 @@
<a href='/tags/text=sort:usages'>Usages</a> <a href='/tags/text=sort:usages'>Usages</a>
<% } %> <% } %>
</th> </th>
<th class='edit-time'>
<% if (ctx.query == 'sort:last-edit-time') { %>
<a href='/tags/text=-sort:last-edit-time'>Edit time</a>
<% } else { %>
<a href='/tags/text=sort:last-edit-time'>Edit time</a>
<% } %>
</th>
</thead> </thead>
<tbody> <tbody>
<% _.each(ctx.results, tag => { %> <% _.each(ctx.results, tag => { %>
@ -66,6 +73,9 @@
<td class='usages'> <td class='usages'>
<%= tag.usages %> <%= tag.usages %>
</td> </td>
<td class='edit-time'>
<%= ctx.makeRelativeTime(tag.lastEditTime) %>
</td>
</tr> </tr>
<% }) %> <% }) %>
</tbody> </tbody>