mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-17 05:22:16 +00:00
16 lines
478 B
Python
16 lines
478 B
Python
from RIGS.models import Profile
|
|
from RIGS.forms import ProfileRegistrationFormUniqueEmail
|
|
from registration.signals import user_registered
|
|
|
|
|
|
def user_created(sender, user, request, **kwargs):
|
|
form = ProfileRegistrationFormUniqueEmail(request.POST)
|
|
user.first_name = form.data['first_name']
|
|
user.last_name = form.data['last_name']
|
|
user.initials = form.data['initials']
|
|
# user.phone = form.data['phone']
|
|
user.save()
|
|
|
|
|
|
user_registered.connect(user_created)
|