diff --git a/wagtail/admin/templates/wagtailadmin/reports/page_types_usage_results.html b/wagtail/admin/templates/wagtailadmin/reports/page_types_usage_results.html index 5469a8bfc3..ef7d07486d 100644 --- a/wagtail/admin/templates/wagtailadmin/reports/page_types_usage_results.html +++ b/wagtail/admin/templates/wagtailadmin/reports/page_types_usage_results.html @@ -2,9 +2,7 @@ {% load i18n wagtailadmin_tags %} {% block results %} - {% if object_list %} - {% include "wagtailadmin/reports/listing/_list_page_types_usage.html" with page_types=object_list %} - {% endif %} + {% include "wagtailadmin/reports/listing/_list_page_types_usage.html" with page_types=object_list %} {% endblock %} {% block no_results_message %} diff --git a/wagtail/admin/templates/wagtailadmin/reports/site_history_results.html b/wagtail/admin/templates/wagtailadmin/reports/site_history_results.html index c98d6c6f8d..7940d466be 100644 --- a/wagtail/admin/templates/wagtailadmin/reports/site_history_results.html +++ b/wagtail/admin/templates/wagtailadmin/reports/site_history_results.html @@ -2,52 +2,50 @@ {% load i18n wagtailadmin_tags %} {% block results %} - {% if object_list %} -
+ {% trans 'Name' %} + | ++ {% trans 'Type' %} + | ++ {% trans 'Action' %} + | ++ {% trans 'User' %} + | ++ {% trans 'Date / Time' %} + | +|||||
---|---|---|---|---|---|---|---|---|---|
- {% trans 'Name' %} - | -- {% trans 'Type' %} - | -- {% trans 'Action' %} - | -- {% trans 'User' %} - | -- {% trans 'Date / Time' %} - | ++ {% if entry.edit_url %} + {{ entry.label }} + {% else %} + {{ entry.label }} + {% endif %} + | ++ {{ entry.content_type|format_content_type }} + | ++ {{ entry.message }} + | ++ {% include "wagtailadmin/shared/user_avatar.html" with user=entry.user username=entry.user_display_name %} + | +{% human_readable_date entry.timestamp %} |
- {% if entry.edit_url %} - {{ entry.label }} - {% else %} - {{ entry.label }} - {% endif %} - | -- {{ entry.content_type|format_content_type }} - | -- {{ entry.message }} - | -- {% include "wagtailadmin/shared/user_avatar.html" with user=entry.user username=entry.user_display_name %} - | -{% human_readable_date entry.timestamp %} | -
+ {% trans 'Workflow' %} + | ++ {% trans 'Page/Snippet' %} + | ++ {% trans 'Status' %} + | ++ {% trans 'Tasks' %} + | ++ {% trans 'Requested by' %} + | ++ {% trans 'Started at' %} + | +||||||
---|---|---|---|---|---|---|---|---|---|---|---|
- {% trans 'Workflow' %} - | -- {% trans 'Page/Snippet' %} - | -- {% trans 'Status' %} - | -- {% trans 'Tasks' %} - | -- {% trans 'Requested by' %} - | -- {% trans 'Started at' %} - | ++ {{ workflow_state.workflow }} + | ++ + {% latest_str workflow_state.content_object %} + + {% i18n_enabled as show_locale_labels %} + {% if show_locale_labels and workflow_state.content_object.locale_id %} + {% locale_label_from_id workflow_state.content_object.locale_id as locale_label %} + {% status locale_label classname="w-status--label" %} + {% endif %} + | ++ {% admin_url_name workflow_state.content_object 'workflow_history_detail' as workflow_history_detail_url_name %} + {% url workflow_history_detail_url_name workflow_state.content_object.pk|admin_urlquote workflow_state.pk as status_url %} + {% status workflow_state.get_status_display url=status_url classname="w-status--primary" %} + | +
+ {{ workflow_name }}+ {% trans 'Incomplete task' as incomplete_title %} + {% for task in workflow_state.all_tasks_with_status %} + + {% if task.status == 'approved' %} + {% icon "success" title=task.status_display classname="initial" %} + {% elif task.status == 'rejected' %} + {% icon "error" title=task.status_display classname="initial" %} + {% else %} + {% icon "radio-empty" title=incomplete_title classname="initial" %} + {% endif %} + + {% endfor %} + |
+ {{ workflow_state.requested_by|user_display_name }} | +{{ workflow_state.created_at }} |
- {{ workflow_state.workflow }} - | -- - {% latest_str workflow_state.content_object %} - - {% i18n_enabled as show_locale_labels %} - {% if show_locale_labels and workflow_state.content_object.locale_id %} - {% locale_label_from_id workflow_state.content_object.locale_id as locale_label %} - {% status locale_label classname="w-status--label" %} - {% endif %} - | -- {% admin_url_name workflow_state.content_object 'workflow_history_detail' as workflow_history_detail_url_name %} - {% url workflow_history_detail_url_name workflow_state.content_object.pk|admin_urlquote workflow_state.pk as status_url %} - {% status workflow_state.get_status_display url=status_url classname="w-status--primary" %} - | -
- {{ workflow_name }}- {% trans 'Incomplete task' as incomplete_title %} - {% for task in workflow_state.all_tasks_with_status %} - - {% if task.status == 'approved' %} - {% icon "success" title=task.status_display classname="initial" %} - {% elif task.status == 'rejected' %} - {% icon "error" title=task.status_display classname="initial" %} - {% else %} - {% icon "radio-empty" title=incomplete_title classname="initial" %} - {% endif %} - - {% endfor %} - |
- {{ workflow_state.requested_by|user_display_name }} | -{{ workflow_state.created_at }} | -
+ {% trans 'Task' %} + | ++ {% trans 'Page/Snippet' %} + | ++ {% trans 'Status' %} + | ++ {% trans 'Started at' %} + | ++ {% trans 'Completed at' %} + | +|||||
---|---|---|---|---|---|---|---|---|---|
- {% trans 'Task' %} - | -- {% trans 'Page/Snippet' %} - | -- {% trans 'Status' %} - | -- {% trans 'Started at' %} - | -- {% trans 'Completed at' %} - | ++ {{ task_state.task }} + | ++ {% with task_state.workflow_state.content_object as object %} + + {% latest_str object %} + + {% i18n_enabled as show_locale_labels %} + {% if show_locale_labels and object.locale_id %} + {% locale_label_from_id object.locale_id as locale_label %} + {% status locale_label classname="w-status--label" %} + {% endif %} + {% endwith %} + | ++ {% status task_state.get_status_display classname="w-status--primary" %} + | +{{ task_state.started_at }} | +{{ task_state.finished_at }} |
- {{ task_state.task }} - | -- {% with task_state.workflow_state.content_object as object %} - - {% latest_str object %} - - {% i18n_enabled as show_locale_labels %} - {% if show_locale_labels and object.locale_id %} - {% locale_label_from_id object.locale_id as locale_label %} - {% status locale_label classname="w-status--label" %} - {% endif %} - {% endwith %} - | -- {% status task_state.get_status_display classname="w-status--primary" %} - | -{{ task_state.started_at }} | -{{ task_state.finished_at }} | -