File diff c6b329f0cff0 → 530890f6ad9d
www/conservancy/apps/assignment/forms.py
Show inline comments
...
 
@@ -13,18 +13,20 @@ def validate_in_past(value):
 

	
 
class AssignmentForm(forms.ModelForm):
 
    period_begins = forms.DateField(
 
        label='Start of period to assign',
 
        label='Assign the copyright in my above contributions starting on',
 
        help_text='You can use the day you first started contributing (or, equivalently, your date of birth), or any later date.',
 
        required=True,
 
        widget=forms.DateInput(attrs={'type': 'date'}),
 
        validators=[validate_in_past],
 
    )
 
    period_end_type = forms.ChoiceField(
 
        label='End of period to assign',
 
        label='and ending on',
 
        choices=[
 
            ('all future contributions', 'all future contributions'),
 
            ('all future contributions', 'all future contributions (no end date)'),
 
            ('a specific past date', 'a specific past date (specify below)'),
 
        ],
 
        widget=forms.RadioSelect(),
 
        initial='all future contributions',
 
    )
 
    period_ends = forms.DateField(
 
        label='Specific past date (if applicable)',
...
 
@@ -38,6 +40,10 @@ class AssignmentForm(forms.ModelForm):
 
        help_text='Please be aware that some employment agreements explicitly transfer copyright ownership to the employer. We recommend you review your recent employment agreements for such clauses.',
 
    )
 

	
 
    def __init__(self, *args, **kwargs):
 
        super().__init__(*args, **kwargs)
 
        self.fields['attestation_of_copyright'].required = True
 

	
 
    class Meta:
 
        model = Assignment
 
        fields = [