mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-22 19:33:11 +00:00
Etiquettes en francais sur les models
This commit is contained in:
parent
5277510666
commit
374d173539
1 changed files with 13 additions and 1 deletions
|
@ -32,11 +32,23 @@ class School(models.Model):
|
|||
return self.name
|
||||
|
||||
class UserForm(ModelForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(InfoForm, self).__init__(*args, **kwargs)
|
||||
self.fields['name'].label = 'Nom'
|
||||
self.fields['surname'].label = 'Prenom'
|
||||
self.fields['school'].label = 'Etablissement'
|
||||
|
||||
class Meta:
|
||||
model = User
|
||||
fields = '__all__'
|
||||
|
||||
class InfoForm(ModelForm):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(InfoForm, self).__init__(*args, **kwargs)
|
||||
self.fields['name'].label = 'Nom'
|
||||
self.fields['surname'].label = 'Prenom'
|
||||
self.fields['school'].label = 'Etablissement'
|
||||
|
||||
class Meta:
|
||||
model = User
|
||||
fields = ['name','surname','pseudo','email', 'school', 'promo']
|
||||
|
@ -46,7 +58,7 @@ class PasswordForm(ModelForm):
|
|||
model = User
|
||||
fields = ['pwd_ssha','pwd_ntlm']
|
||||
|
||||
class ArchiveForm(ModelForm):
|
||||
class StateForm(ModelForm):
|
||||
class Meta:
|
||||
model = User
|
||||
fields = ['state']
|
||||
|
|
Loading…
Reference in a new issue