mezzanine_events/forms.py
def clean(self):
        """
        Validate start/end days.
        Ideally start_day should always be defined no matter what the user enters
        to ensure the list view doesn't display all events ever.
        """
        cleaned_data = super(ListFilterForm, self).clean()

        # Always set a value for start_day
        start = cleaned_data.get("start_day") or today()
        end = cleaned_data.get("end_day")
        if end is not None and end < start:
            end = None

        cleaned_data.update({"start_day": start, "end_day": end})
        return cleaned_data

        Validate start/end days.
        Ideally start_day should always be defined no matter what the user enters
        to ensure the list view doesn't display all events ever.
        
Validate start/end days.
Ideally start_day should always be defined no matter what the user enters
to ensure the list view doesn't display all events ever.
Validate start / end days . Ideally start_day should always be defined no matter what the user enters to ensure the list view doesn ' t display all events ever .
def clean(self):
        cleaned_data = super(ListFilterForm, self).clean()
        start = cleaned_data.get("start_day") or today()
        end = cleaned_data.get("end_day")
        if end is not None and end < start:
            end = None
        cleaned_data.update({"start_day": start, "end_day": end})
        return cleaned_data
def clean ( self ) : cleaned_data = super ( ListFilterForm , self ) . clean ( ) start = cleaned_data . get ( "start_day" ) or today ( ) end = cleaned_data . get ( "end_day" ) if end is not None and end < start : end = None cleaned_data . update ( { "start_day" : start , "end_day" : end } ) return cleaned_data
Validate start/end days.
Validate start / end days .
"""
        Validate start/end days.
        Ideally start_day should always be defined no matter what the user enters
        to ensure the list view doesn't display all events ever.
        """ # Always set a value for start_day
self