Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class AnswerChoiceForm(forms.Form):
- CHOICES = (
- (None, None),
- (1, 'Disagree strongly'),
- (2, 'Disagree a little'),
- (3, 'Neither agree nor disagree'),
- (4, 'Agree a little'),
- (5, 'Agree strongly'),
- )
- answer_choice = forms.ChoiceField(
- widget=forms.Select(
- attrs={'class': 'form-control', 'style': 'width: 270px;'}
- ),
- choices=CHOICES,
- validators=[none_choice_validator],
- required=True
- )
- class Meta:
- fields = ['answer_choice']
Add Comment
Please, Sign In to add comment