From 271fe8ecf13f99c8041b122027f11cbcb8658629 Mon Sep 17 00:00:00 2001 From: Qwann Date: Tue, 21 Feb 2017 16:27:29 +0100 Subject: [PATCH] defining default side nav --- shared/templates/base.html | 37 ++++++++++++++++++++++++++++- user/templates/user/base_user.html | 38 ------------------------------ user/templates/user/user_form.html | 2 +- 3 files changed, 37 insertions(+), 40 deletions(-) delete mode 100644 user/templates/user/base_user.html diff --git a/shared/templates/base.html b/shared/templates/base.html index 290a74d..ac763ba 100644 --- a/shared/templates/base.html +++ b/shared/templates/base.html @@ -16,9 +16,44 @@ {% endif %}
- + {% block sidenav %} + {% if not user.is_authenticated %} +
  • + + + Se connecter + +
  • +
  • + + + Créer un compte + +
  • +
  • + + + Mot de passe oublié + +
  • + {% endif %} + {% if user.is_authenticated %} +
  • + + + Changer de mot de passe + +
  • +
  • + + + Se déconnecter + +
  • + {% endif %} {% endblock %} + {% endblock %} {% block real_content %} diff --git a/user/templates/user/base_user.html b/user/templates/user/base_user.html deleted file mode 100644 index fa35902..0000000 --- a/user/templates/user/base_user.html +++ /dev/null @@ -1,38 +0,0 @@ -{% extends "base.html" %} - -{% block sidenav %} - {% if not user.is_authenticated %} -
  • - - - Se connecter - -
  • -
  • - - - Créer un compte - -
  • -
  • - - - Mot de passe oublié - -
  • - {% endif %} - {% if user.is_authenticated %} -
  • - - - Changer de mot de passe - -
  • -
  • - - - Se déconnecter - -
  • - {% endif %} -{% endblock %} diff --git a/user/templates/user/user_form.html b/user/templates/user/user_form.html index 8b5fb83..067564d 100644 --- a/user/templates/user/user_form.html +++ b/user/templates/user/user_form.html @@ -1,4 +1,4 @@ -{% extends "user/base_user.html" %} +{% extends "base.html" %} {% load widget_tweaks %} {% load bootstrap %}