Remove user created content blocks from Chapter overview in CMS

This commit is contained in:
Lorenz Padberg 2022-07-27 16:09:17 +02:00
parent 0398c1bfc6
commit 7a77ae6eb2
1 changed files with 12 additions and 8 deletions

View File

@ -72,14 +72,18 @@
<div style="margin-top:10px; padding-left: 30px"> <div style="margin-top:10px; padding-left: 30px">
<ul> <ul>
{% for c in page.get_children %} {% for c in page.get_children %}
<li> {% if not c.specific.user_created %}
{% if page_perms.can_edit %} <li>
<a href="{% url 'wagtailadmin_pages:edit' c.id %}" {% if page_perms.can_edit %}
title="{% trans 'Edit this page' %}">{{ c.get_admin_display_title }}</a> <a href="{% url 'wagtailadmin_pages:edit' c.id %}"
{% else %} title="{% trans 'Edit this page' %}"> {{ c.get_admin_display_title }}
{{ c.get_admin_display_title }} </a>
{% endif %} {% else %}
</li> {{ c.get_admin_display_title }}
{% endif %}
</li>
{% endif %}
{% endfor %} {% endfor %}
</ul> </ul>
</div> </div>