kers/users/forms.py
2020-07-22 05:34:40 +02:00

15 lines
427 B
Python

from django.contrib.auth.forms import UserCreationForm, UserChangeForm
from .models import CustomUser
class CustomUserCreationForm(UserCreationForm):
class Meta(UserCreationForm):
model = CustomUser
fields = ('username', 'student_number', 'real_name',)
class CustomUserChangeForm(UserChangeForm):
class Meta:
model = CustomUser
fields = ('username', 'student_number', 'real_name',)