Including reversion templates for ease of use... probably a bad idea. From version...
[htsworkflow.git] / templates / reversion / object_history.html
1 {% extends "admin/object_history.html" %}
2 {% load i18n %}
3
4
5 {% block content %}
6         <div id="content-main">
7         
8                 <p>{% blocktrans %}Choose a date from the list below to revert to a previous version of this object.{% endblocktrans %}</p>
9         
10                 <div class="module">
11                         {% if action_list %}
12                             <table id="change-history">
13                                 <thead>
14                                         <tr>
15                                             <th scope="col">{% trans 'Date/time' %}</th>
16                                             <th scope="col">{% trans 'User' %}</th>
17                                             <th scope="col">{% trans 'Comment' %}</th>
18                                         </tr>
19                                 </thead>
20                                 <tbody>
21                                         {% for action in action_list %}
22                                                 <tr>
23                                                     <th scope="row"><a href="./{{action.pk}}/">{{action.revision.date_created|date:_("DATETIME_FORMAT")}}</a></th>
24                                                     <td>{{action.revision.user.username}}{% if action.revision.user.first_name %} ({{action.revision.user.first_name}} {{action.revision.user.last_name}}){% endif %}</td>
25                                                     <td>{{action.revision.comment|default:""}}</td>
26                                                 </tr>
27                                         {% endfor %}
28                                 </tbody>
29                             </table>
30                         {% else %}
31                             <p>{% trans "This object doesn't have a change history. It probably wasn't added via this admin site." %}</p>
32                         {% endif %}
33                 </div>
34         </div>
35 {% endblock %}