LDEV-4486 Prevent user from removing course if there are lessons in it
When sysadming tries to remove a course, he gets warned about lessons
existing in the course or its subcourses. Then he is redirected to a
page where he can remove the lessons. Only if the course and its
subcourses are empty, the course can get removed.