#114: Set participants tab inactive if usersettings page is active

This commit is contained in:
Emanuel Schuetze 2012-05-20 22:34:41 +02:00
parent f8137da055
commit 37619b0a80
3 changed files with 9 additions and 7 deletions

View File

@ -71,11 +71,6 @@ urlpatterns = patterns('participant.views',
name='user_group_delete',
),
url(r'^user/settings$',
'user_settings',
name='user_settings',
),
url(r'^resetpassword/(?P<user_id>\d+)$',
'reset_password',
name='user_reset_password',

View File

@ -25,7 +25,8 @@
<ul>
{% if user.is_authenticated %}
<li>|<a href="{% url user_logout %}">{%trans "Logout" %}</a></li>
<li>|<a href="{% url user_settings %}">{%trans "User Settings" %}</a></li>
{% url user_settings as url_usersettings %}
<li>|<a href="{% url user_settings %}">{% if request.path == url_usersettings %}<strong>{% endif %}{%trans "User Settings" %}{% if request.path == url_usersettings %}</strong>{% endif %}</a></li>
<li>{%trans "Welcome" %}, <strong>{{ user.username }}</strong></li>
{% else %}
<li><a href="{% url user_login %}">{%trans "Login" %}</a></li>

View File

@ -64,5 +64,11 @@ urlpatterns += patterns('',
url(r'^logout/$',
'django.contrib.auth.views.logout_then_login',
name='user_logout',
)
),
url(r'^usersettings$',
'participant.views.user_settings',
name='user_settings',
),
)