abstraction of controller to ng-view