mirror of
https://github.com/wagtail/wagtail.git
synced 2024-12-01 11:41:20 +01:00
Human readable dates and i18n
This commit is contained in:
parent
3b085b9f89
commit
dad2d7edf5
@ -70,8 +70,9 @@
|
||||
{% for task_state in task_states %}
|
||||
<td>
|
||||
{% if task_state.status == 'approved' or task_state.status == 'rejected' %}
|
||||
{# FIXME: i18n #}
|
||||
<div class="status-tag primary">{{ task_state.get_status_display }}</div> at <b>{{ task_state.finished_at }}</b>
|
||||
{% blocktrans with action='<div class="status-tag primary">'|add:task_state.get_status_display|add:'</div>'|safe at=task_state.finished_at %}
|
||||
{{ action }} at <b>{{ at }}</b>
|
||||
{% endblocktrans %}
|
||||
{% else %}
|
||||
<div class="status-tag primary">{{ task_state.get_status_display }}</div>
|
||||
{% endif %}
|
||||
|
@ -42,8 +42,12 @@
|
||||
</span>
|
||||
{% endfor %}
|
||||
</td>
|
||||
<td>{{ workflow_state.requested_by }}</td>
|
||||
<td>{{ workflow_state.created_at }}</td>
|
||||
<td>{{ workflow_state.requested_by.get_full_name|default:workflow_state.requested_by.get_username }}</td>
|
||||
<td>
|
||||
<div class="human-readable-date" title="{{ workflow_state.created_at|date:"d M Y H:i" }}">
|
||||
{% blocktrans with time_period=workflow_state.created_at|timesince %}{{ time_period }} ago{% endblocktrans %}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
|
Loading…
Reference in New Issue
Block a user