| 12345678910111213141516171819202122 |
- '''
- @author: olivier.massot, 2018
- '''
- from django import forms
- from martor.fields import MartorFormField
- from main.models import Story
- class StoryForm(forms.ModelForm):
-
- description = MartorFormField(label="Description")
-
- class Meta:
- model = Story
- fields = ('epic', 'name', 'description', 'assignees', 'sprints')
-
- def __init__(self, *args, **kwargs):
- super(StoryForm, self).__init__(*args, **kwargs)
- self.fields['assignees'].required = False
- self.fields['sprints'].required = False
|