add controllers, refactor routes