fixed some minor bugs

Departments were not preselected for courses/edit for admins. I have
fixed it in this commit

A popup with an error comes up for surveysummary if no students are
in the class. I have now added an additional check to redirect users
away if the classlist is empty.

I have included a restriction in events index for events export.
The action is greyed out if the event is a survey.