add parent controller to controller class, refactor