From 75751f9c89eb8162c541f1dc87478175e904e5d0 Mon Sep 17 00:00:00 2001 From: Diego Calvo Date: Thu, 25 Mar 2021 15:16:31 +0100 Subject: [PATCH] active and verify users --- core/views.py | 1 + products/utils.py | 1 + 2 files changed, 2 insertions(+) diff --git a/core/views.py b/core/views.py index 4c62e7c..21634fa 100644 --- a/core/views.py +++ b/core/views.py @@ -195,6 +195,7 @@ def activate_user(request, uidb64, token): if user is not None and utils.account_activation_token.check_token(user, token): # activate user user.is_active = True + user.email_verified = True user.save() if settings.ACTIVATION_REDIRECT: return redirect(settings.ACTIVATION_REDIRECT) diff --git a/products/utils.py b/products/utils.py index 49d7edc..936c866 100644 --- a/products/utils.py +++ b/products/utils.py @@ -250,6 +250,7 @@ def product_loader(csv_reader, user, company=None): 'tags': row['tags'], 'category': row['categoria'], 'identifiers': row['identificadores'], + 'active': True, 'history': history, 'creator': user, # 'valid': True