def retrieve(self, request, pk=None): employee = VisionsHelper.get_employee(pk) serializer = VisionsEmployeeSerializer(instance=employee) return Response(serializer.data)
def list(self, request): employees = VisionsHelper.get_all_employees() serializer = VisionsEmployeeSerializer(instance=employees, many=True) return Response(serializer.data)