From f3d355b3dace71ae1a6d1b1405185662248d55a3 Mon Sep 17 00:00:00 2001 From: Dark-Storm Date: Sun, 16 Sep 2018 23:14:07 +0200 Subject: [PATCH] =?UTF-8?q?Cr=C3=A9ation=20du=20diagramme=20de=20classes.?= =?UTF-8?q?=20Modifications=20mineures=20des=20templates?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/routes.py | 3 + app/static/css/global.css | 17 +- app/static/css/navbar.css | 2 +- app/templates/base/alerts.html | 30 +-- app/templates/base/navbar.html | 243 ------------------------- app/templates/base/navbar/account.html | 10 +- app/templates/register.html | 85 +++++---- app/templates/validation.html | 3 +- assets/diagramme_1.dia | Bin 0 -> 3447 bytes 9 files changed, 90 insertions(+), 303 deletions(-) create mode 100644 assets/diagramme_1.dia diff --git a/app/routes.py b/app/routes.py index fe7f6f6..a327b31 100644 --- a/app/routes.py +++ b/app/routes.py @@ -10,6 +10,9 @@ from app.models import User def index(): form = LoginForm() + flash('pseudo ou mot de passe invalide', 'error') + flash('tout ça c\'est ok !', 'ok') + flash('mais ça non', 'error') if form.validate_on_submit(): user = User.query.filter_by(username=form.username.data).first() if user is None or not user.check_password(form.password.data): diff --git a/app/static/css/global.css b/app/static/css/global.css index 6fe5e6f..e03131d 100644 --- a/app/static/css/global.css +++ b/app/static/css/global.css @@ -167,13 +167,20 @@ input[type="button"].raised:active { } /* Input text */ +input[type="text"], +input[type="search"], +input[type="password"] { + background: #FFFFFF; color: #000000; +} + input[type="text"]:focus, input[type="search"]:focus, input[type="password"]:focus { - + box-shadow: :0 0 0 0.2rem rgba(0,123,255,0.25); } + section { margin: 10px 5%; } @@ -186,4 +193,10 @@ section h1 { section * { transition: .15s ease; -} \ No newline at end of file +} + + +/* Bootstrap-style rules */ +.flex { + display: flex; +} diff --git a/app/static/css/navbar.css b/app/static/css/navbar.css index d2dd033..1b36e6f 100644 --- a/app/static/css/navbar.css +++ b/app/static/css/navbar.css @@ -180,7 +180,7 @@ nav a:focus { margin-right: 10px; } -#menu form p { +#menu form div { padding: 0 5%; } #menu form input[type="text"] { diff --git a/app/templates/base/alerts.html b/app/templates/base/alerts.html index 1157c2e..276cab1 100644 --- a/app/templates/base/alerts.html +++ b/app/templates/base/alerts.html @@ -1,15 +1,15 @@ -{% with messages = get_flashed_messages() %} -{% if messages %} -{% for message in messages %} -
- - - - - {{ message }} - - -
-{% endfor %} -{% endif %} -{% endwith %} \ No newline at end of file +{% with messages = get_flashed_messages(with_categories=true) %} + {% if messages %} + {% for category, message in messages %} +
+ + + + + {{ message }} + + +
+ {% endfor %} + {% endif %} +{% endwith %} diff --git a/app/templates/base/navbar.html b/app/templates/base/navbar.html index bd61bac..c526f14 100644 --- a/app/templates/base/navbar.html +++ b/app/templates/base/navbar.html @@ -69,7 +69,6 @@ diff --git a/app/templates/base/navbar/account.html b/app/templates/base/navbar/account.html index 4ca29aa..529a9bc 100644 --- a/app/templates/base/navbar/account.html +++ b/app/templates/base/navbar/account.html @@ -49,14 +49,14 @@

Invité

-
+ {{ form.hidden_tag() }} -

+

{{ form.username(size=32, placeholder="Identifiant") }} {{ form.password(size=32, placeholder="Mot de passe") }} -

-

{{ form.submit() }}

-

{{ form.remember_me.label }} {{ form.remember_me() }}

+
+
{{ form.submit() }}
+
{{ form.remember_me.label }} {{ form.remember_me() }}

Mot de passe oublié ? diff --git a/app/templates/register.html b/app/templates/register.html index 2eb4771..f2b5725 100644 --- a/app/templates/register.html +++ b/app/templates/register.html @@ -1,41 +1,56 @@ {% extends "base/container.html" %} {% block content %} -
+
+
+

Planète Casio

+

Pourquoi s'inscrire sur Planète Casio ? Parce que c'est cool et qu'ici on peut mettre plein de truc sympas. + Vous saviez que Planète Casio c'est : +

    +
  • Presque 10000 membres
  • +
  • (Bon ok, seulement une vingtaine de vraiments actifs)
  • +
  • Plein de programmes
  • +
  • Une multitude de tutos pour mieux comprendre comment fonctionne sa calto
  • +
  • Mais surtout, une communauté au top !
  • +
+ Et oui, ça fait beaucoup, mais bon, je commence à être à court de trucs à écrire ici, donc bon… +

+
+
+

Inscription :

-

Inscription :

- -
- {{ form2.hidden_tag() }} -

- {{ form2.username.label }}
- {{ form2.username(size=32) }}
- {% for error in form2.username.errors %} - [{{ error }}] - {% endfor %} -

-

- {{ form2.email.label }}
- {{ form2.email(size=64) }}
- {% for error in form2.email.errors %} - [{{ error }}] - {% endfor %} -

-

- {{ form2.password.label }}
- {{ form2.password(size=32) }}
- {% for error in form2.password.errors %} - [{{ error }}] - {% endfor %} -

-

- {{ form2.password2.label }}
- {{ form2.password2(size=32) }}
- {% for error in form2.password2.errors %} - [{{ error }}] - {% endfor %} -

-

{{ form2.submit() }}

-
+
+ {{ form2.hidden_tag() }} +
+ {{ form2.username.label }} + {{ form2.username() }} + {% for error in form2.username.errors %} + [{{ error }}] + {% endfor %} +
+
+ {{ form2.email.label }} + {{ form2.email() }} + {% for error in form2.email.errors %} + [{{ error }}] + {% endfor %} +
+
+ {{ form2.password.label }} + {{ form2.password() }} + {% for error in form2.password.errors %} + [{{ error }}] + {% endfor %} +
+
+ {{ form2.password2.label }} + {{ form2.password2() }} + {% for error in form2.password2.errors %} + [{{ error }}] + {% endfor %} +
+
{{ form2.submit() }}
+
+
{% endblock %} diff --git a/app/templates/validation.html b/app/templates/validation.html index cf2108b..0b5ffa0 100644 --- a/app/templates/validation.html +++ b/app/templates/validation.html @@ -2,10 +2,9 @@ {% block content %}
-

ici il y aura la page qui demande de checker les mails pour valider


- Retour à la page d'acceuil + Retour à la page d'accueil
{% endblock content %} diff --git a/assets/diagramme_1.dia b/assets/diagramme_1.dia new file mode 100644 index 0000000000000000000000000000000000000000..048f9a8fef0d2043a833cf0d6b0ef2a9026dd152 GIT binary patch literal 3447 zcmaLLXEYmt!p8AfDMIa4tBBgQWAB{?wUw$(jaapX)-0i|QM+bQM3hiet=ef+wYJz% zirS-sa_{|c-+Rt`&b`n7%X5Cbsg!_!jg)N10hhVm!mzOP-U(Z%D#s2WHyS&9m`lK9 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