mirror of
https://github.com/wagtail/wagtail.git
synced 2024-11-30 01:46:24 +01:00
breadcrumbs - remove ‘move’ breadcrumbs as no longer needed
This commit is contained in:
parent
081f46c07f
commit
f4f621cbc3
@ -1,21 +0,0 @@
|
||||
{% load i18n wagtailadmin_tags %}
|
||||
|
||||
<nav aria-label="{% trans 'Breadcrumb' %}">
|
||||
<ul class="breadcrumb">
|
||||
{% for page in pages %}
|
||||
<li class="breadcrumb-item">
|
||||
<a href="{% url 'wagtailadmin_pages:move_choose_destination' page_to_move_id page.id %}" class="breadcrumb-link">
|
||||
{% if forloop.first %}
|
||||
{% if page.is_root %}{% trans "Root" as label %}{% else %}{% trans 'Home' as label %}{% endif %}
|
||||
{% icon name="site" class_name="home_icon" title=label %}
|
||||
{% else %}
|
||||
<span class="title">{{ page.get_admin_display_title }}</span>
|
||||
{% endif %}
|
||||
{% if not forloop.last %}
|
||||
{% icon name="arrow-right" class_name="arrow_right_icon" %}
|
||||
{% endif %}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</nav>
|
@ -92,21 +92,6 @@ def explorer_breadcrumb(
|
||||
}
|
||||
|
||||
|
||||
@register.inclusion_tag("wagtailadmin/shared/move_breadcrumb.html", takes_context=True)
|
||||
def move_breadcrumb(context, page_to_move, viewed_page):
|
||||
user = context["request"].user
|
||||
cca = get_explorable_root_page(user)
|
||||
if not cca:
|
||||
return {"pages": Page.objects.none()}
|
||||
|
||||
return {
|
||||
"pages": viewed_page.get_ancestors(inclusive=True)
|
||||
.descendant_of(cca, inclusive=True)
|
||||
.specific(),
|
||||
"page_to_move_id": page_to_move.id,
|
||||
}
|
||||
|
||||
|
||||
@register.inclusion_tag("wagtailadmin/shared/search_other.html", takes_context=True)
|
||||
def search_other(context, current=None):
|
||||
request = context["request"]
|
||||
|
Loading…
Reference in New Issue
Block a user