initial commit
This commit is contained in:
commit
6f5167c24f
45 changed files with 763 additions and 0 deletions
17
users/forms.py
Normal file
17
users/forms.py
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
from django import forms
|
||||
from django.contrib.auth.forms import UserCreationForm, UserChangeForm
|
||||
from .models import CustomUser
|
||||
|
||||
|
||||
class CustomUserCreationForm(UserCreationForm):
|
||||
|
||||
class Meta(UserCreationForm.Meta):
|
||||
model = CustomUser
|
||||
fields = ('username', 'email')
|
||||
|
||||
|
||||
class CustomUserChangeForm(UserChangeForm):
|
||||
|
||||
class Meta:
|
||||
model = CustomUser
|
||||
fields = UserChangeForm.Meta.fields
|
||||
Loading…
Add table
Add a link
Reference in a new issue