Skip to content
Snippets Groups Projects
Commit e8957379 authored by Dorian Lesbre's avatar Dorian Lesbre
Browse files

WIP signup view

parent 89392c04
No related branches found
No related tags found
No related merge requests found
{% extends "base.html" %}
{% block nav_inscription %}current{% endblock %}
{% block "content" %}
<h2>Inscriptions</h2>
<p>Vous devez être connecté pour pouvoir vous inscrire à l'événement.</p>
<p>Aller à la page de <a href="{% url 'accounts:login' %}">connexion</a> pour vous connectez
ou à celle de <a href="{% url 'accounts:create' %}">création de compte</a> si vous n'avez pas de compte.</p>
{% endblock %}
\ No newline at end of file
......@@ -8,7 +8,7 @@ sitemaps = {"static_pages": views.StaticViewSitemap}
urlpatterns = [
path('', views.static_view, {"template": "home.html"}, name = 'home'),
path('inscription/', views.static_view, {"template":"inscription.html"}, name = 'inscription'),
path('inscription/', views.sign_up, name = 'inscription'),
path('activites/', views.static_view, {"template":"activites.html"}, name = 'activites'),
path('faq/', views.static_view, {"template":"faq.html"}, name = 'FAQ'),
path('favicon.ico', RedirectView.as_view(url='/static/imgs/favicon.ico')),
......
......@@ -13,8 +13,10 @@ def static_view(request, template):
def sign_up(request):
"""Page d'inscription"""
if not settings.REGISTRATION_EVENT_INSCRIPTIONS_OPEN:
return static_view(request, "inscription.html")
return static_view(request, "inscription/closed.html")
if not request.user.is_authenticated:
return static_view(request, "inscription/signin.html")
# TODO : actual inscription form
class StaticViewSitemap(Sitemap):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment