manager: remove useless link from journal breadcrumb (#47702)

This commit is contained in:
Valentin Deniaud 2021-05-26 14:36:01 +02:00
parent d8cd51c065
commit e71abfa96f
3 changed files with 3 additions and 4 deletions

View File

@ -90,7 +90,7 @@ class DateHierarchy:
def back_urls(self):
def helper():
if self.year:
yield _('All dates'), self.form.make_url(exclude=['year', 'month', 'day'])
yield _('Journal - All dates'), self.form.make_url(exclude=['year', 'month', 'day'])
if self.month:
yield str(self.year), self.form.make_url(exclude=['month', 'day'])
current_datetime = datetime(self.year, self.month or 1, self.day or 1)
@ -103,7 +103,7 @@ class DateHierarchy:
else:
yield str(self.year), '#'
else:
yield _('All dates'), '#'
yield _('Journal - All dates'), '#'
return list(helper())

View File

@ -7,7 +7,6 @@
{{ block.super }}
{% block breadcrumb-before-title %}
{% endblock %}
<a href="#">{% trans 'Journal' %}</a>
{% for caption, url in date_hierarchy.back_urls %}
<a href="{{ url }}">{{ caption }}</a>
{% endfor %}

View File

@ -962,7 +962,7 @@ def test_date_navigation(app, superuser, events):
response = response.click('January 2020')
response = response.click('2020')
response = response.click('All dates')
response = response.click('Journal - All dates')
def test_search(app, superuser, events):