fe840f2003
Profile view - Let the user see his information. - List the clubs whose he is a member. Profile edition view - Renamed from previous "profile" view - User can now change "occupation" field. Club detail view - Informations about a club. - Accessible by staff members and "respos" of the club. - List members, with subscription fee (if applicable). Club admin - Change memberships of clubs added.
16 lines
349 B
Python
16 lines
349 B
Python
from django import forms
|
|
from django.contrib.auth.models import User
|
|
|
|
from .models import Profile
|
|
|
|
|
|
class UserForm(forms.ModelForm):
|
|
class Meta:
|
|
model = User
|
|
fields = ["first_name", "last_name"]
|
|
|
|
|
|
class ProfileForm(forms.ModelForm):
|
|
class Meta:
|
|
model = Profile
|
|
fields = ["phone", "departement", "occupation"]
|