fix login redirect

sync_v2
Raz 8 months ago
parent a2242fcda5
commit 3c8adb5673
  1. 2
      tournaments/templates/registration/login.html
  2. 2
      tournaments/templates/tournaments/navigation_base.html
  3. 2
      tournaments/urls.py

@ -26,7 +26,7 @@
{% endfor %}
</div>
{% endif %}
<form method="post" action="{% url 'login' %}">
<form method="post" action="{% url 'custom-login' %}">
{% csrf_token %}
<input type="hidden" name="next" value="{{ request.GET.next }}">
<label for="username">Identifiant ou e-mail </label>

@ -6,7 +6,7 @@
<a href="{% url 'my-tournaments' %}" class="orange">Mes tournois</a>
<a href="{% url 'profile' %}">Mon compte</a>
{% else %}
<a href="{% url 'login' %}">Se connecter</a>
<a href="{% url 'custom-login' %}">Se connecter</a>
{% endif %}
<a href="{% url 'download' %}" class="download-button">Ajouter vos tournois</a>
</nav>

@ -54,7 +54,7 @@ urlpatterns = [
path('terms-of-use/', views.terms_of_use, name='terms-of-use'),
path('utils/xls-to-csv/', views.xls_to_csv, name='xls-to-csv'),
path('mail-test/', views.simple_form_view, name='mail-test'),
path('login/', CustomLoginView.as_view(), name='login'),
path('login/', CustomLoginView.as_view(), name='custom-login'),
path('password_change/',
auth_views.PasswordChangeView.as_view(
success_url='/profile/', # Redirect back to profile after success

Loading…
Cancel
Save