Refactoring: extracted controller with list and edit ability