From 4c7f5e6d2b48242e8c3cc97e30df9a8506b9e333 Mon Sep 17 00:00:00 2001 From: adityacp Date: Tue, 16 May 2017 17:56:40 +0530 Subject: Change forms.py, views.py, send_emails.py, models.py - Alter activation_key field in Profile model - Change get_activation_key function in send_mail to create secret_key of fixed length - Change forms.py to get updated activation_key - Change views.py to save activation_key --- yaksh/forms.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'yaksh/forms.py') diff --git a/yaksh/forms.py b/yaksh/forms.py index 3459be9..c09566f 100644 --- a/yaksh/forms.py +++ b/yaksh/forms.py @@ -150,7 +150,8 @@ class UserRegisterForm(forms.Form): new_profile.key_expiry_time = timezone.now() + \ timezone.timedelta(minutes=20) new_profile.save() - return u_name, pwd, new_user.email, new_profile.activation_key + user_activation_key = Profile.objects.get(user=new_user).activation_key + return u_name, pwd, new_user.email, user_activation_key class UserLoginForm(forms.Form): -- cgit