from rest_framework.generics import ListAPIView, RetrieveAPIView, get_object_or_404
from rest_framework.permissions import DjangoModelPermissionsOrAnonReadOnly
from rest_framework.response import Response
from rest_framework.generics import ListAPIView, RetrieveAPIView, get_object_or_404
from rest_framework.permissions import DjangoModelPermissionsOrAnonReadOnly
from rest_framework.response import Response
def get(self, *args, **kwargs):
return HttpResponse(self.get_object().get_media('epub'))
def get(self, *args, **kwargs):
return HttpResponse(self.get_object().get_media('epub'))