Refactored views to use viewsets for simplification.