kopia lustrzana https://github.com/wagtail/wagtail
Just compare the live revision id, rather than the whole object
This avoid running a query, which in this case would be `n`pull/7316/head
rodzic
07490bfb18
commit
02d8dac97e
|
@ -38,7 +38,7 @@
|
|||
{% endwith %}
|
||||
{% if entry.revision %}
|
||||
{% if entry.action == 'wagtail.publish' %}
|
||||
{% if entry.revision == page.live_revision %}<span class="status-tag primary">{% trans 'Live version' %}</span>{% endif %}
|
||||
{% if entry.revision_id == page.live_revision_id %}<span class="status-tag primary">{% trans 'Live version' %}</span>{% endif %}
|
||||
{% elif entry.content_changed %}
|
||||
{% if entry.revision == page_latest_revision %}<span class="status-tag primary">{% trans 'Current draft' %}</span>{% endif %}
|
||||
{% include "wagtailadmin/pages/revisions/_actions.html" with revision=entry.revision %}
|
||||
|
|
Ładowanie…
Reference in New Issue