Browse Source

Coloca as 'choices' do formulario no models, em Sessao

pull/250/head
Eduardo Calil 9 years ago
committed by Marcio Mazza
parent
commit
e6744ed292
  1. 15
      sessao/forms.py

15
sessao/forms.py

@ -70,16 +70,6 @@ class VotacaoEditForm(forms.Form):
class SessaoForm(ModelForm):
hora_inicio = forms.CharField(label=_('Horário Inicio'),
required=True,
widget=forms.TextInput(
attrs={'class': 'hora'}))
hora_fim = forms.CharField(label=_('Horário Fim'),
required=True,
widget=forms.TextInput(
attrs={'class': 'hora'}))
class Meta:
model = SessaoPlenaria
fields = ['numero',
@ -97,6 +87,11 @@ class SessaoForm(ModelForm):
'url_audio',
'url_video']
widgets = {
'hora_inicio': forms.TextInput(attrs={'class': 'hora'}),
'hora_fim': forms.TextInput(attrs={'class': 'hora'}),
}
def __init__(self, *args, **kwargs):
row1 = crispy_layout_mixin.to_row(

Loading…
Cancel
Save