Course view refactor

Refactored initialization and stuff in course views