misc: remove link to FranceConnect screen if there's no authentic (#34209)
This commit is contained in:
parent
20018fbac8
commit
a5836a35b6
|
@ -9,7 +9,9 @@
|
|||
<li><a href="{% url 'profile-home' %}">{% trans 'User Profile' %}</a></li>
|
||||
<li><a href="{% url 'theme-home' %}">{% trans 'Theme' %}</a></li>
|
||||
<li><a href="{% url 'emails-home' %}">{% trans 'Emails' %}</a></li>
|
||||
{% if has_authentic %}
|
||||
<li><a href="{% url 'franceconnect-home' %}">FranceConnect</a></li>
|
||||
{% endif %}
|
||||
<li><a href="{% url 'matomo-home' %}">{% trans 'User tracking' %}</a></li>
|
||||
<li><a href="{% url 'environment-home' %}">{% trans 'Services' %}</a></li>
|
||||
<li><a href="{% url 'environment-variables' %}">{% trans 'Variables' %}</a></li>
|
||||
|
|
|
@ -33,6 +33,7 @@ class Home(TemplateView):
|
|||
def get_context_data(self, **kwargs):
|
||||
context = super(Home, self).get_context_data(**kwargs)
|
||||
context['services'] = [x for x in get_installed_services() if not x.secondary]
|
||||
context['has_authentic'] = bool(Authentic.objects.filter(secondary=False))
|
||||
return context
|
||||
|
||||
home = admin_required(Home.as_view())
|
||||
|
|
Loading…
Reference in New Issue