8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-26 14:42:25 +00:00

Fixed field creation

This commit is contained in:
edpibu 2018-09-19 23:24:15 +02:00 committed by chirac
parent b7359f5b38
commit 1d107d33f2

View file

@ -379,18 +379,17 @@ class AdherentCreationForm(AdherentForm):
"""Formulaire de création d'un user. """Formulaire de création d'un user.
AdherentForm auquel on ajoute une checkbox afin d'éviter les AdherentForm auquel on ajoute une checkbox afin d'éviter les
doublons d'utilisateurs""" doublons d'utilisateurs"""
def __init__(self, *args, **kwargs):
super(AdherentCreationForm, self).__init__(*args, **kwargs)
# Champ permettant d'éviter au maxium les doublons d'utilisateurs # Champ permettant d'éviter au maxium les doublons d'utilisateurs
former_user_check_info = _("If you already have an account, please use it. "\ former_user_check_info = _("If you already have an account, please use it. "\
+ "If your lost access to it, please consider "\ + "If your lost access to it, please consider "\
+ "using the forgotten password button on the "\ + "using the forgotten password button on the "\
+ "login page or contacting support.") + "login page or contacting support.")
self.fields['former_user_check'] = forms.BooleanField(required=True, former_user_check = forms.BooleanField(required=True, help_text=former_user_check_info)
help_text=former_user_check_info) former_user_check = _("I have not had an account before")
self.fields['former_user_check'].label = _("I have not had an account before")
def __init__(self, *args, **kwargs):
super(AdherentCreationForm, self).__init__(*args, **kwargs)
class ClubForm(FormRevMixin, FieldPermissionFormMixin, ModelForm): class ClubForm(FormRevMixin, FieldPermissionFormMixin, ModelForm):
"""Formulaire de base d'edition d'un user. Formulaire de base, utilisé """Formulaire de base d'edition d'un user. Formulaire de base, utilisé