-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Display log 8 most recent entries before publishing
- Loading branch information
Showing
4 changed files
with
144 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 60 additions & 0 deletions
60
wagtail_fedit/templates/wagtail_fedit/editor/action_publish_confirm.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
{% extends "./action_confirm.html" %} | ||
|
||
{% load i18n wagtailadmin_tags %} | ||
|
||
{% block form_content %} | ||
|
||
<div class="wagtail-fedit-log-entries"> | ||
{% translate "Changes since last publish" as panel_heading %} | ||
{% panel id="wagtail-fedit-log-actions" icon="draft" classname="collapsed" heading=panel_heading %} | ||
|
||
{% if log_entries %} | ||
<table class="listing listing--inline-actions"> | ||
<thead> | ||
<tr> | ||
<th> | ||
{% trans 'Action' %} | ||
</th> | ||
<th> | ||
{% trans 'User' %} | ||
</th> | ||
<th class="updated"> | ||
{% trans 'Date / Time' %} | ||
</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{% page_permissions view.object as page_perms %} | ||
{% for entry in log_entries %} | ||
<tr> | ||
<td> | ||
{% if entry.revision %}<span class="report__results--text">{% endif %} | ||
{{ entry.message }} | ||
{% if entry.revision %}</span>{% endif %} | ||
{% if entry.comment %} | ||
<span class="report__results--comment">{% trans "Comment" %}: <em>{{ entry.comment }}</em></span> | ||
{% endif %} | ||
{% if entry.revision and entry.content_changed and is_page %} | ||
{% if entry.revision == page_latest_revision %}{% trans 'Current draft' as status_label %}{% status status_label classname="w-status--primary" %}{% endif %} | ||
{% include "wagtailadmin/pages/revisions/_actions.html" with revision=entry.revision page=view.object %} | ||
{% endif %} | ||
</td> | ||
<td> | ||
{% include "wagtailadmin/shared/user_avatar.html" with user=entry.user username=entry.user_display_name %} | ||
</td> | ||
<td class="updated">{% human_readable_date entry.timestamp %}</td> | ||
</tr> | ||
{% endfor %} | ||
</tbody> | ||
</table> | ||
{% else %} | ||
<p>{% trans "No log entries found." %}</p> | ||
{% endif %} | ||
|
||
|
||
{% endpanel %} | ||
</div> | ||
|
||
{{ block.super }} | ||
|
||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters