checks email for uniqueness upon change
This commit is contained in:
@@ -17,6 +17,7 @@ from django import template
|
||||
from django.db import IntegrityError, transaction
|
||||
from django.views.decorators.csrf import csrf_exempt
|
||||
|
||||
|
||||
from django.shortcuts import render
|
||||
from django.http import (
|
||||
HttpResponse, HttpResponseRedirect,
|
||||
@@ -9703,7 +9704,7 @@ def rower_edit_view(request,message=""):
|
||||
})
|
||||
elif request.method == 'POST' and "weightcategory" in request.POST:
|
||||
accountform = AccountRowerForm(request.POST)
|
||||
userform = UserForm(request.POST)
|
||||
userform = UserForm(request.POST,instance=request.user)
|
||||
if accountform.is_valid() and userform.is_valid():
|
||||
# process
|
||||
cd = accountform.cleaned_data
|
||||
@@ -9720,7 +9721,7 @@ def rower_edit_view(request,message=""):
|
||||
if len(first_name):
|
||||
u.first_name = first_name
|
||||
u.last_name = last_name
|
||||
if len(email):
|
||||
if len(email): ## and check_email_freeforuse(u,email):
|
||||
u.email = email
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user