{% extends "wagtailadmin/base.html" %} {% load i18n wagtailadmin_tags %} {% block titletag %}{% trans "Workflow progress" %}{% endblock %} {% block content %} {% trans "Workflow progress" as title_str %} {% include "wagtailadmin/shared/header.html" with title=title_str %}
{% trans "Edit / Review" %} {% trans "Workflow history" %}
{% blocktrans trimmed with modified_by=workflow_state.requested_by|user_display_name %}Requested by {{ modified_by }}{% endblocktrans %} {% avatar user=workflow_state.requested_by size="small" %}
{% blocktrans trimmed with workflow_state.created_at as started_at %}Started at {{ started_at }}{% endblocktrans %}
{% fragment as status_tag_variable %}{% status workflow_state.get_status_display classname="primary" %}{% endfragment %} {% blocktrans trimmed with status_tag_variable as status %}Status {{ status }}{% endblocktrans %}
{% for task in tasks %} | {{ task }} | {% endfor %} {% for revision, task_states in task_states_by_revision %}
---|---|
{% if forloop.first %} {% trans "Initial Revision" %} {% else %} {% if not forloop.first %} {% trans "Edited" as action %} {% if revision.user %} {% blocktrans trimmed with ''|add:action|add:'' as action and revision.user|user_display_name as who and revision.created_at as at %} {{ action }} by {{ who }} at {{ at }} {% endblocktrans %} {% else %} {% blocktrans trimmed with ''|add:action|add:'' as action and revision.created_at as at %} {{ action }} at {{ at }} {% endblocktrans %} {% endif %} {% endif %} {% endif %} | {% for task_state in task_states %}
{% if task_state.status == 'approved' or task_state.status == 'rejected' %}
{% if task_state.finished_by %}
{% blocktrans trimmed with action=' '|add:task_state.get_status_display|add:' '|safe who=task_state.finished_by|user_display_name at=task_state.finished_at %}
{{ action }} by {{ who }} at {{ at }}
{% endblocktrans %}
{% else %}
{% blocktrans trimmed with action=''|add:task_state.get_status_display|add:' '|safe at=task_state.finished_at %}
{{ action }} at {{ at }}
{% endblocktrans %}
{% endif %}
{% else %}
{{ task_state.get_status_display }}
{% endif %}
{% if task_state.specific.get_comment %}
{% trans 'with comment:' %} "{{ task_state.specific.get_comment }}" {% endif %} |
{% endfor %}
{{ timeline_item.time }} |
{% if timeline_item.action == 'workflow_started' %}
{% trans "Workflow started" %}
{% elif timeline_item.action == 'workflow_completed' %}
{% trans "Workflow completed" %}
{{ timeline_item.workflow_state.get_status_display }}
{% elif timeline_item.action == 'edited' %}
{% trans "Edited" as action %}
{% if revision.user %}
{% blocktrans trimmed with ''|add:action|add:'' as action and timeline_item.revision.user|user_display_name as who %}
{{ action }} by {{ who }}
{% endblocktrans %}
{% else %}
{{ action }}
{% endif %}
{% elif timeline_item.action == 'task_completed' %}
{{ timeline_item.task_state.task }}
{% if timeline_item.task_state.finished_by %}
{% blocktrans trimmed with action=''|add:timeline_item.task_state.get_status_display|add:' '|safe who=timeline_item.task_state.finished_by|user_display_name %}
{{ action }} by {{ who }}
{% endblocktrans %}
{% else %}
{{ timeline_item.task_state.get_status_display }}
{% endif %}
{% if timeline_item.task_state.specific.get_comment %}
{% trans 'with comment:' %} "{{ timeline_item.task_state.specific.get_comment }}"
{% endif %}
{% endif %}
|