Forwards LOGOUT_URL to templates.
Uses the openstack context preprocessor to pass the LOGOUT_URL from settings to templates and changes the 'Sign out' menu entry to redirect to it instead of the logout view directly. closes-bug: #1747149 Change-Id: Id17ffca6b5e24779433c3f19d009bb2a77f7b901
This commit is contained in:
parent
bcdff69221
commit
a11aa7ff62
@ -87,6 +87,7 @@ def openstack(request):
|
|||||||
context['WEBROOT'] = settings.WEBROOT
|
context['WEBROOT'] = settings.WEBROOT
|
||||||
|
|
||||||
context['USER_MENU_LINKS'] = settings.USER_MENU_LINKS
|
context['USER_MENU_LINKS'] = settings.USER_MENU_LINKS
|
||||||
|
context['LOGOUT_URL'] = settings.LOGOUT_URL
|
||||||
|
|
||||||
# Adding profiler support flag
|
# Adding profiler support flag
|
||||||
profiler_settings = settings.OPENSTACK_PROFILER
|
profiler_settings = settings.OPENSTACK_PROFILER
|
||||||
|
@ -59,7 +59,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
<li class="divider"></li>
|
<li class="divider"></li>
|
||||||
<li>
|
<li>
|
||||||
<a href="{% url 'logout' %}" target="_self">
|
<a href="{{ LOGOUT_URL }}" target="_self">
|
||||||
<span class="fa fa-sign-out"></span>
|
<span class="fa fa-sign-out"></span>
|
||||||
{% trans "Sign Out" %}
|
{% trans "Sign Out" %}
|
||||||
</a>
|
</a>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user