flake8 fixes for the schedule edit form.

The schedule edit form had missing imports and a call to a django feature not supported in django 1.4.