diff --git a/contrib/env-sample b/contrib/env-sample index 7f3ea35..4591608 100644 --- a/contrib/env-sample +++ b/contrib/env-sample @@ -7,4 +7,13 @@ AWS_ACCESS_KEY_ID = AWS_SECRET_ACCESS_KEY = AWS_STORAGE_BUCKET_NAME = INTERNAL_IPS=127.0.0.1 -SENTRY_DSN= \ No newline at end of file +SENTRY_DSN= + +# Configurações de e-mail +EMAIL_BACKEND=django.core.mail.backends.console.EmailBackend +EMAIL_HOST=localhost +EMAIL_PORT=25 +EMAIL_HOST_USER= +EMAIL_HOST_PASSWORD= +EMAIL_USE_TLS=True +DEFAULT_FROM_EMAIL=matheuslopes.py@gmail.com \ No newline at end of file diff --git a/pypro/base/templates/registration/password_reset_form.html b/pypro/base/templates/registration/password_reset_form.html new file mode 100644 index 0000000..7f3bc33 --- /dev/null +++ b/pypro/base/templates/registration/password_reset_form.html @@ -0,0 +1,28 @@ +{% extends 'base/base.html' %} +{% load i18n static %} + + +{% block title %}Formulário de recuperação de senha.{% endblock %} + +{% block body %} +
+
+
+

{{ title }}

+

{% translate 'Forgotten your password? Enter your email address below, and we’ll email instructions for setting a new one.' %}

+ +
{% csrf_token %} +
+
+ {{ form.email.errors }} + + {{ form.email }} +
+ +
+
+
+
+
+ +{% endblock %} diff --git a/pypro/settings.py b/pypro/settings.py index ca570e9..2a7ac6f 100644 --- a/pypro/settings.py +++ b/pypro/settings.py @@ -44,6 +44,10 @@ INSTALLED_APPS = [ + 'pypro.base', + 'pypro.turmas', + 'pypro.aperitivos', + 'pypro.modulos', 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', @@ -51,10 +55,6 @@ 'django.contrib.messages', 'collectfast', 'django.contrib.staticfiles', - 'pypro.base', - 'pypro.turmas', - 'pypro.aperitivos', - 'pypro.modulos', 'ordered_model', 'django_extensions', ] @@ -89,6 +89,17 @@ WSGI_APPLICATION = 'pypro.wsgi.application' +# Configuração de envio de e-mail +EMAIL_BACKEND = config('EMAIL_BACKEND') +EMAIL_HOST = config('EMAIL_HOST') +EMAIL_PORT = config('EMAIL_PORT') +EMAIL_HOST_USER = config('EMAIL_HOST_USER') +EMAIL_HOST_PASSWORD = config('EMAIL_HOST_PASSWORD') +EMAIL_USE_TLS = config('EMAIL_USE_TLS') + +DEFAULT_FROM_EMAIL = config('DEFAULT_FROM_EMAIL') + + # Configuração django-debug-toolbar INTERNAL_IPS = config('INTERNAL_IPS', cast=Csv(), default='127.0.0.1')