kopia lustrzana https://github.com/wagtail/wagtail
Allow navigation from page usage/search results
Remove the allow_navigation flag from the 'explore' page listing, and have navigation always enabled - there's no good reason to leave it out, and people have asked for it. Fixes #952pull/3912/head
rodzic
ef7ef8de13
commit
e93b21036e
|
@ -14,6 +14,7 @@ Changelog
|
|||
* Updated React to 15.6.2 due to relicensing (Janneke Janssen)
|
||||
* User search in the Wagtail admin UI now works across multiple fields (Will Giddens)
|
||||
* `Page.last_published_at` is now a filterable field for search (Mikalai Radchuk)
|
||||
* Page search results and usage listings now include navigation links (Matt Westcott)
|
||||
* Fix: "Open Link in New Tab" on a right arrow in page explorer should open page list (Emily Horsman)
|
||||
* Fix: Using `order_by_relevance=False` when searching with PostgreSQL now works (Mitchel Cabuloy)
|
||||
* Fix: Inline panel first and last sorting arrows correctly hidden in non-default tabs (Matt Westcott)
|
||||
|
|
|
@ -24,6 +24,7 @@ Other features
|
|||
* Wagtail now uses React 15.6.2 and above, released under the MIT license (Janneke Janssen)
|
||||
* User search in the Wagtail admin UI now works across multiple fields (Will Giddens)
|
||||
* ``Page.last_published_at`` is now a filterable field for search (Mikalai Radchuk)
|
||||
* Page search results and usage listings now include navigation links (Matt Westcott)
|
||||
|
||||
Bug fixes
|
||||
~~~~~~~~~
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
{% csrf_token %}
|
||||
|
||||
{% page_permissions parent_page as parent_page_perms %}
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with sortable=1 allow_navigation=1 full_width=1 show_ordering_column=1 parent_page=parent_page orderable=parent_page_perms.can_reorder_children %}
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with sortable=1 full_width=1 show_ordering_column=1 parent_page=parent_page orderable=parent_page_perms.can_reorder_children %}
|
||||
|
||||
{% if do_paginate %}
|
||||
{% url 'wagtailadmin_explore' parent_page.id as pagination_base_url %}
|
||||
|
|
|
@ -4,12 +4,10 @@
|
|||
Navigation controls for the page listing in 'explore' mode
|
||||
{% endcomment %}
|
||||
|
||||
<td class="{% if allow_navigation %}{% if page.is_navigable %}children{% else %}no-children{% endif %}{% endif %}">
|
||||
{% if allow_navigation %}
|
||||
{% if page.is_navigable %}
|
||||
<a href="{% url 'wagtailadmin_explore' page.id %}" class="icon text-replace icon-arrow-right" title="{% blocktrans with title=page.get_admin_display_title %}Explore child pages of '{{ title }}'{% endblocktrans %}">{% trans "Explore" %}</a>
|
||||
{% elif page_perms.can_add_subpage %}
|
||||
<a href="{% url 'wagtailadmin_pages:add_subpage' page.id %}" class="icon text-replace icon-plus-inverse" title="{% blocktrans with title=page.get_admin_display_title %}Add a child page to '{{ title }}'{% endblocktrans %}">{% trans 'Add child page' %}</a>
|
||||
{% endif %}
|
||||
<td class="{% if page.is_navigable %}children{% else %}no-children{% endif %}">
|
||||
{% if page.is_navigable %}
|
||||
<a href="{% url 'wagtailadmin_explore' page.id %}" class="icon text-replace icon-arrow-right" title="{% blocktrans with title=page.get_admin_display_title %}Explore child pages of '{{ title }}'{% endblocktrans %}">{% trans "Explore" %}</a>
|
||||
{% elif page_perms.can_add_subpage %}
|
||||
<a href="{% url 'wagtailadmin_pages:add_subpage' page.id %}" class="icon text-replace icon-plus-inverse" title="{% blocktrans with title=page.get_admin_display_title %}Add a child page to '{{ title }}'{% endblocktrans %}">{% trans 'Add child page' %}</a>
|
||||
{% endif %}
|
||||
</td>
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
{% search_other %}
|
||||
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with show_parent=1 allow_navigation=0 %}
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with show_parent=1 %}
|
||||
|
||||
{% url 'wagtailadmin_pages:search' as pagination_base_url %}
|
||||
{% paginate pages base_url=pagination_base_url %}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{% load i18n wagtailadmin_tags %}
|
||||
<div class="nice-padding">
|
||||
{% if pages %}
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with show_parent=1 allow_navigation=0 %}
|
||||
{% include "wagtailadmin/pages/listing/_list_explore.html" with show_parent=1 %}
|
||||
|
||||
{% url 'wagtailadmin_pages:type_use' app_name content_type.model as pagination_base_url %}
|
||||
{% paginate pages base_url=pagination_base_url %}
|
||||
|
|
Ładowanie…
Reference in New Issue