diff --git a/portail/templates/portail/index.html b/portail/templates/portail/index.html
new file mode 100644
index 00000000..9fa792b9
--- /dev/null
+++ b/portail/templates/portail/index.html
@@ -0,0 +1,48 @@
+{% extends "base.html" %}
+
+{% load i18n %}
+
+{% block content %}
+
+
{% blocktrans trimmed with asso_name=asso.name %}Welcome onto the captive portal of {{ asso_name }}!{% endblocktrans %}
+
+
+
+ {% if not user.is_authenticated %}
+
+
+
+
+
{% trans "Registration" %}
+
{% trans "If you don't have an account yet and you want to access the Internet and the organisation's services, create your own personal account." %}
+
{% trans "Sign up" %}
+
+
+
+
+
+
+
+
+
{% trans "Logging in" %}
+
{% trans "If you already have an account, log in. You can manage your subscriptions to the organisation." %}
+
{% trans "Log in" %}
+
+
+
+
+ {% else %}
+
+ {% endif %}
+
+{% endblock %}
diff --git a/portail/urls.py b/portail/urls.py
index 2d65a021..6548e296 100644
--- a/portail/urls.py
+++ b/portail/urls.py
@@ -29,9 +29,10 @@ from cotisations.views import new_facture
from django.conf.urls import url
from django.contrib.auth.views import LoginView
-from .views import SignUpView
+from .views import IndexView, SignUpView
urlpatterns = [
+ url(r"^$", IndexView.as_view(), name="index"),
url(r"^signup/$", SignUpView.as_view(), name="signup"),
url(r"^login/$", LoginView.as_view(), name="login"),
url(r"^extend-connection/(?P[0-9]+)/$", new_facture, name="extend-connection"),
diff --git a/portail/views.py b/portail/views.py
index b0cf096a..f52fa1b5 100644
--- a/portail/views.py
+++ b/portail/views.py
@@ -24,7 +24,8 @@ from cotisations.utils import find_payment_method
from django.contrib.auth import login
from django.db import transaction
from django.urls import reverse_lazy
-from django.views.generic import CreateView
+from django.views.generic import CreateView, TemplateView
+from preferences.models import AssoOption
from .forms import AdherentForm, MembershipForm
@@ -83,3 +84,12 @@ class SignUpView(CreateView):
def get_success_url(self):
return reverse_lazy("users:profil", args=(self.object.pk,))
+
+
+class IndexView(TemplateView):
+ template_name = "portail/index.html"
+
+ def get_context_data(self, **kwargs):
+ context = super().get_context_data(**kwargs)
+ context["asso"] = AssoOption.objects.get_or_create()[0]
+ return context