Add views for courses-controller. Fix bugs