1
0
mirror of https://gitlab.crans.org/bde/nk20 synced 2024-11-26 10:27:07 +00:00
nk20/apps/member/forms.py

24 lines
606 B
Python
Raw Normal View History

2019-07-08 11:59:31 +00:00
# -*- mode: python; coding: utf-8 -*-
# Copyright (C) 2018-2019 by BDE ENS Paris-Saclay
# SPDX-License-Identifier: GPL-3.0-or-later
2019-08-11 14:22:52 +00:00
from django.contrib.auth.forms import UserChangeForm, UserCreationForm
from django.contrib.auth.models import User
from django import forms
2019-07-08 11:59:31 +00:00
2019-08-11 21:25:27 +00:00
from .models import Profile, Club
2019-07-08 11:59:31 +00:00
2019-08-11 14:22:52 +00:00
class ProfileForm(forms.ModelForm):
2019-08-11 15:52:41 +00:00
"""
Forms pour la création d'un profile utilisateur.
"""
2019-08-11 14:22:52 +00:00
class Meta:
model = Profile
fields = '__all__'
2019-08-11 15:39:05 +00:00
exclude = ['user']
2019-08-11 21:25:27 +00:00
class ClubForm(forms.ModelForm):
class Meta:
model = Club
fields ='__all__'