feat(course_page.html): add ?next= parameter to login/signup buttons on course page while logged out
This commit is contained in:
@@ -37,8 +37,9 @@
|
|||||||
{# If the user is not authenticated, we can prompt them to log in or sign up. #}
|
{# If the user is not authenticated, we can prompt them to log in or sign up. #}
|
||||||
<div class="not-prose mt-8 p-4 bg-blue-100 border-l-4 border-blue-500 text-blue-700">
|
<div class="not-prose mt-8 p-4 bg-blue-100 border-l-4 border-blue-500 text-blue-700">
|
||||||
<p>{% trans "You need to be logged in to access this course. Please log in or sign up to view the modules." %}</p>
|
<p>{% trans "You need to be logged in to access this course. Please log in or sign up to view the modules." %}</p>
|
||||||
<a href="{% url 'account_login' %}" class="mt-4 inline-block bg-blue-600 text-white px-4 py-2 rounded hover:bg-blue-700 transition">{% trans "Login" %}</a>
|
<a href="{% url 'account_login' %}?next={{ request.path }}" class="mt-4 inline-block bg-blue-600 text-white px-4 py-2 rounded hover:bg-blue-700 transition">{% trans "Login" %}</a>
|
||||||
<a href="{% url 'account_signup' %}" class="mt-4 inline-block bg-green-600 text-white px-4 py-2 rounded hover:bg-green-700 transition">{% trans "Sign Up" %}</a>
|
<a href="{% url 'account_signup' %}?next={{ request.path }}" class="mt-4 inline-block bg-green-600 text-white px-4 py-2 rounded hover:bg-green-700 transition ml-2">{% trans "Sign Up" %}</a>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
{% else %}
|
{% else %}
|
||||||
<div class="not-prose mt-8 p-4 bg-yellow-100 border-l-4 border-yellow-500 text-yellow-700">
|
<div class="not-prose mt-8 p-4 bg-yellow-100 border-l-4 border-yellow-500 text-yellow-700">
|
||||||
|
|||||||
Reference in New Issue
Block a user