Make sure login redirects (?next=) work

This commit is contained in:
Tobias Kunze 2025-03-21 15:58:59 +01:00
parent 4e603246f7
commit 81396297f9
2 changed files with 3 additions and 1 deletions

View file

@ -14,6 +14,7 @@
{% provider_login_url provider process=process scope=scope auth_params=auth_params as href %}
<form method="post" action="{{ href }}">
{% csrf_token %}
{{ redirect_field }}
<button href="{{ href }}"
class="btn btn-warning btn-lg icon icon-left"
title="{{ provider.name }}">
@ -39,7 +40,7 @@
style="max-width: 400px">
{% url 'account_login' as form_action %}
{% translate "Sign In" as form_submit_label %}
{% include "includes/form.html" %}
{% include "includes/form.html" with extra_field=redirect_field %}
</div>
</div>
{% endblock card_content %}

View file

@ -5,6 +5,7 @@
{% include "includes/form_errors.html" %}
{% csrf_token %}
{{ form }}
{% if extra_field %}{{ extra_field }}{% endif %}
<div class="col-sm-12 d-flex justify-content-end">
<button class="btn btn-primary me-1 mb-1" type="submit">
{% if form_submit_label %}