mirror of
https://gitlab.com/animath/si/plateforme-corres2math.git
synced 2025-07-04 19:04:03 +02:00
Personal page
This commit is contained in:
@ -26,6 +26,18 @@ class SignupForm(UserCreationForm):
|
||||
fields = ('first_name', 'last_name', 'email', 'password1', 'password2', 'role',)
|
||||
|
||||
|
||||
class UserForm(forms.ModelForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super().__init__(*args, **kwargs)
|
||||
self.fields["first_name"].required = True
|
||||
self.fields["last_name"].required = True
|
||||
self.fields["email"].required = True
|
||||
|
||||
class Meta:
|
||||
model = User
|
||||
fields = ('first_name', 'last_name', 'email',)
|
||||
|
||||
|
||||
class StudentRegistrationForm(forms.ModelForm):
|
||||
class Meta:
|
||||
model = StudentRegistration
|
||||
|
Reference in New Issue
Block a user