diff --git a/.gitignore b/.gitignore
index aa7ea9b..8c73834 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,6 +9,7 @@
# environment variables
.env
+
# virtual env
venv/
diff --git a/back_latienda/settings/base.py b/back_latienda/settings/base.py
index 4996fc6..af2f1b1 100644
--- a/back_latienda/settings/base.py
+++ b/back_latienda/settings/base.py
@@ -85,7 +85,7 @@ TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [os.path.join(BASE_DIR, '../templates'),],
- 'APP_DIRS': True,
+ # 'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
'django.template.context_processors.debug',
@@ -93,6 +93,12 @@ TEMPLATES = [
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
],
+ 'loaders': [
+ (
+ 'django.template.loaders.filesystem.Loader',
+ [os.path.join(BASE_DIR, '../templates')],
+ ),
+ ],
},
},
]
@@ -153,7 +159,7 @@ USE_TZ = True
# https://docs.djangoproject.com/en/2.2/howto/static-files/
STATIC_URL = '/static/'
-
+STATIC_ROOT = 'static'
TAXONOMY_FILE = 'shop-taxonomy.es-ES.txt'
diff --git a/back_latienda/settings/production.py b/back_latienda/settings/production.py
index f506476..eafc231 100644
--- a/back_latienda/settings/production.py
+++ b/back_latienda/settings/production.py
@@ -41,7 +41,7 @@ DEFAULT_FILE_STORAGE = 'storages.backends.s3boto3.S3Boto3Storage'
EMAIL_BACKEND = "anymail.backends.amazon_ses.EmailBackend"
# DEFAULT_FROM_EMAIL = "no-reply@latienda.com"
-DEFAULT_FROM_EMAIL = "samuel.molina@enreda.coop"
+DEFAULT_FROM_EMAIL = "info@latienda.coop"
SERVER_EMAIL = "mail-server@latienda.com"
diff --git a/products/views.py b/products/views.py
index d1eb045..03a750d 100644
--- a/products/views.py
+++ b/products/views.py
@@ -293,7 +293,7 @@ def purchase_email(request):
return Response({"error": "Related compay has no contact email address"}, status=status.HTTP_406_NOT_ACCEPTABLE)
try:
# send email to company
- company_message = render_to_string('purchase_notification.html', {
+ company_message = render_to_string('purchase_notification_v2.html', {
'company': company,
'user': request.user,
'product': product,
diff --git a/templates/purchase_contact_confirmation_v2.html b/templates/purchase_contact_confirmation_v2.html
new file mode 100644
index 0000000..e69de29
diff --git a/templates/purchase_notification.html b/templates/purchase_notification.html
deleted file mode 100755
index c377a12..0000000
--- a/templates/purchase_notification.html
+++ /dev/null
@@ -1,175 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
- Interés en copra de producto
-
-
-
-
-
-
-
-
-
-
-
Enlace al producto
-
Nombre del producto: {{product.name}}
-
{{product.sku}}
-
{{product.price}}
-
-
-
Datos cliente
-
- - Nombre:
- - {{user.full_name}}
- - Email:
- - {{user.email}}
- - Teléfono:
- - {{telephone}}
- - Comentarios:
- - {{comment}}
-
-
-
-
-
-
-
-
diff --git a/templates/purchase_notification_v2.html b/templates/purchase_notification_v2.html
new file mode 100755
index 0000000..668ce6e
--- /dev/null
+++ b/templates/purchase_notification_v2.html
@@ -0,0 +1,1033 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+ Interés en compra de
+ producto
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+ |
+
+
+ |
+
+ Enlace al
+ producto
+
+ Nombre del
+ producto
+
+ {{product.name}}
+
+ {{product.sku}}
+
+ {{product.price}}€
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+ Datos cliente
+
+ |
+
+
+ |
+
+ Nombre:
+
+ {{user.full_name}}
+
+ |
+
+
+ |
+
+ Email:
+
+ {{user.email}}
+
+ |
+
+
+ |
+
+ Teléfono:
+
+ {{telephone}}
+
+ |
+
+
+ |
+
+ Comentarios: {{comment}}
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+ |
+
+
+ |
+
+ 2021 La Tienda.coop
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+