diff --git a/src/c3nav/editor/templates/editor/changeset.html b/src/c3nav/editor/templates/editor/changeset.html index ce1c2e4e..2e650afb 100644 --- a/src/c3nav/editor/templates/editor/changeset.html +++ b/src/c3nav/editor/templates/editor/changeset.html @@ -27,24 +27,57 @@ {% blocktrans %}last update at {{ datetime }}{% endblocktrans %} {% endwith %}
++ {% if not active and not changeset.closed %} + + {% endif %} + {% if can_edit %} + {% trans 'Edit' %} + {% endif %} +
{% bootstrap_messages %} +{% if changeset.last_state_update and changeset.state != 'unproposed' %} +{% blocktrans %}These changes are currently pending review.{% endblocktrans %}
+ {% if changeset.author == request.user %} +{% blocktrans %}As long as the review is pending you can unpropose them to edit them again.{% endblocktrans %}
+ {% endif %} + {% elif changeset.state == 'review' %} + {% with user=changeset.assigned_to %} + {% url 'editor.users.detail' pk=changeset.assigned_to.pk as user_url %} +{% blocktrans %}These changes are currently being reviewed by {{ user }}{% endblocktrans %}
+ {% endwith %} + {% elif changeset.state == 'rejected' or changeset.state == 'finallyrejected' %} + {% with user=changeset.last_state_update.user comment=changeset.last_state_update.comment %} + {% url 'editor.users.detail' pk=changeset.last_state_update.user.pk as user_url %} +{% blocktrans %}Your changes were rejected by {{ user }}:{% endblocktrans %}
+{% blocktrans %}“{{ comment }}”{% endblocktrans %}
+ {% if changeset.author == request.user %} + {% if changeset.state == 'rejected' %} +{% blocktrans %}You can now edit your changes and propose them again.{% endblocktrans %}
+ {% else %} +{% blocktrans %}This rejection is final.{% endblocktrans %}
+ {% endif %} + {% endif %} + {% endwith %} + {% elif changeset.state == 'applied' %} + {% with user=changeset.last_state_update.user %} + {% url 'editor.users.detail' pk=changeset.last_state_update.user.pk as user_url %} +{% blocktrans %}Your changes were applied by {{ user }}.{% endblocktrans %}
+ {% endwith %} + {% endif %} + {{ changeset.last_state_update.datetime|date:"DATETIME_FORMAT" }} +{{ changeset.description }}
{% endif %} -{% if changeset.author == request.user %} - {% if changeset.proposed and not changeset.applied %} - {% if not changeset.assigned_to %} -- {% blocktrans %}Your changes are currently waiting for review. As long as no reviewer has been assigned to your changes, you can still unpropose and edit them.{% endblocktrans %} -
- {% else %} -- {% blocktrans %}Your changes are currently being reviewed.{% endblocktrans %} -
- {% endif %} - {% endif %} -{% endif %} - {% for obj in changed_objects %}