From a3184c5d142848b5147811ed246e39545e978805 Mon Sep 17 00:00:00 2001 From: Gertjan van den Burg Date: Mon, 18 Mar 2019 16:57:31 +0000 Subject: refactor --- app/templates/404.html | 6 ------ app/templates/500.html | 7 ------- app/templates/auth/login.html | 16 ++++++++++++++ app/templates/auth/register.html | 11 ++++++++++ app/templates/auth/reset_password.html | 11 ++++++++++ app/templates/auth/reset_password_request.html | 11 ++++++++++ app/templates/base.html | 8 +++---- app/templates/email/reset_password.html | 2 +- app/templates/email/reset_password.txt | 2 +- app/templates/errors/404.html | 6 ++++++ app/templates/errors/500.html | 7 +++++++ app/templates/login.html | 29 -------------------------- app/templates/register.html | 11 ---------- app/templates/reset_password.html | 11 ---------- app/templates/reset_password_request.html | 11 ---------- 15 files changed, 68 insertions(+), 81 deletions(-) delete mode 100644 app/templates/404.html delete mode 100644 app/templates/500.html create mode 100644 app/templates/auth/login.html create mode 100644 app/templates/auth/register.html create mode 100644 app/templates/auth/reset_password.html create mode 100644 app/templates/auth/reset_password_request.html create mode 100644 app/templates/errors/404.html create mode 100644 app/templates/errors/500.html delete mode 100644 app/templates/login.html delete mode 100644 app/templates/register.html delete mode 100644 app/templates/reset_password.html delete mode 100644 app/templates/reset_password_request.html (limited to 'app/templates') diff --git a/app/templates/404.html b/app/templates/404.html deleted file mode 100644 index 51295c4..0000000 --- a/app/templates/404.html +++ /dev/null @@ -1,6 +0,0 @@ -{% extends "base.html" %} - -{% block app_content %} -

Page Not Found

-

Home

-{% endblock %} diff --git a/app/templates/500.html b/app/templates/500.html deleted file mode 100644 index adda72b..0000000 --- a/app/templates/500.html +++ /dev/null @@ -1,7 +0,0 @@ -{% extends "base.html" %} - -{% block app_content %} -

An unexpected error has occurred

-

The administrator has been notified, apologies for the inconvenience.

-

Home

-{% endblock %} diff --git a/app/templates/auth/login.html b/app/templates/auth/login.html new file mode 100644 index 0000000..27268b2 --- /dev/null +++ b/app/templates/auth/login.html @@ -0,0 +1,16 @@ +{% extends "base.html" %} +{% import 'bootstrap/wtf.html' as wtf %} + +{% block app_content %} +

Sign In

+
+
+ {{ wtf.quick_form(form) }} +
+
+

New User? Click to Register!

+

+Forgot your password? +Click here to reset it +

+{% endblock %} diff --git a/app/templates/auth/register.html b/app/templates/auth/register.html new file mode 100644 index 0000000..c430b38 --- /dev/null +++ b/app/templates/auth/register.html @@ -0,0 +1,11 @@ +{% extends "base.html" %} +{% import 'bootstrap/wtf.html' as wtf %} + +{% block app_content %} +

Register

+
+
+ {{ wtf.quick_form(form) }} +
+
+{% endblock %} diff --git a/app/templates/auth/reset_password.html b/app/templates/auth/reset_password.html new file mode 100644 index 0000000..cab00c9 --- /dev/null +++ b/app/templates/auth/reset_password.html @@ -0,0 +1,11 @@ +{% extends "base.html" %} +{% import 'bootstrap/wtf.html' as wtf %} + +{% block app_content %} +

Reset Your Password

+
+
+ {{ wtf.quick_form(form) }} +
+
+{% endblock %} diff --git a/app/templates/auth/reset_password_request.html b/app/templates/auth/reset_password_request.html new file mode 100644 index 0000000..c516141 --- /dev/null +++ b/app/templates/auth/reset_password_request.html @@ -0,0 +1,11 @@ +{% extends "base.html" %} +{% import 'bootstrap/wtf.html' as wtf %} + +{% block app_content %} +

Reset Password

+
+
+ {{ wtf.quick_form(form) }} +
+
+{% endblock %} diff --git a/app/templates/base.html b/app/templates/base.html index ee03e3d..8e51695 100644 --- a/app/templates/base.html +++ b/app/templates/base.html @@ -14,17 +14,17 @@ - AnnotateChange + AnnotateChange diff --git a/app/templates/email/reset_password.html b/app/templates/email/reset_password.html index f7403a5..5ce604d 100644 --- a/app/templates/email/reset_password.html +++ b/app/templates/email/reset_password.html @@ -1,7 +1,7 @@

Dear {{ user.username }},

To reset your password - + click here .

diff --git a/app/templates/email/reset_password.txt b/app/templates/email/reset_password.txt index da1330f..0f7b0e7 100644 --- a/app/templates/email/reset_password.txt +++ b/app/templates/email/reset_password.txt @@ -2,7 +2,7 @@ Dear {{ user.username }}, To reset your password click on the following link: -{{ url_for('reset_password', token=token, _external=True) }} +{{ url_for('auth.reset_password', token=token, _external=True) }} If you have not requested a password reset then you can simply ignore this email. diff --git a/app/templates/errors/404.html b/app/templates/errors/404.html new file mode 100644 index 0000000..80f5bd6 --- /dev/null +++ b/app/templates/errors/404.html @@ -0,0 +1,6 @@ +{% extends "base.html" %} + +{% block app_content %} +

Page Not Found

+

Home

+{% endblock %} diff --git a/app/templates/errors/500.html b/app/templates/errors/500.html new file mode 100644 index 0000000..5297e6a --- /dev/null +++ b/app/templates/errors/500.html @@ -0,0 +1,7 @@ +{% extends "base.html" %} + +{% block app_content %} +

An unexpected error has occurred

+

The administrator has been notified, apologies for the inconvenience.

+

Home

+{% endblock %} diff --git a/app/templates/login.html b/app/templates/login.html deleted file mode 100644 index 9b862f6..0000000 --- a/app/templates/login.html +++ /dev/null @@ -1,29 +0,0 @@ -{% extends "base.html" %} - -{% block app_content %} -

Sign In

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

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

-

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

-

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

-

{{ form.submit() }}

-
-

New User? Click to Register!

-

- Forgot your password? - Click here to reset it -

-{% endblock %} diff --git a/app/templates/register.html b/app/templates/register.html deleted file mode 100644 index c430b38..0000000 --- a/app/templates/register.html +++ /dev/null @@ -1,11 +0,0 @@ -{% extends "base.html" %} -{% import 'bootstrap/wtf.html' as wtf %} - -{% block app_content %} -

Register

-
-
- {{ wtf.quick_form(form) }} -
-
-{% endblock %} diff --git a/app/templates/reset_password.html b/app/templates/reset_password.html deleted file mode 100644 index cab00c9..0000000 --- a/app/templates/reset_password.html +++ /dev/null @@ -1,11 +0,0 @@ -{% extends "base.html" %} -{% import 'bootstrap/wtf.html' as wtf %} - -{% block app_content %} -

Reset Your Password

-
-
- {{ wtf.quick_form(form) }} -
-
-{% endblock %} diff --git a/app/templates/reset_password_request.html b/app/templates/reset_password_request.html deleted file mode 100644 index c516141..0000000 --- a/app/templates/reset_password_request.html +++ /dev/null @@ -1,11 +0,0 @@ -{% extends "base.html" %} -{% import 'bootstrap/wtf.html' as wtf %} - -{% block app_content %} -

Reset Password

-
-
- {{ wtf.quick_form(form) }} -
-
-{% endblock %} -- cgit v1.2.3