+ def read(self, request, tags=''):
+ if tags == '':
+ return Tag.objects.all()
+ else:
+ return tagged_object_list(request, tags, api=True)
+
+class BookHandler(BaseHandler):
+ model = Book
+ #fields = ('slug', 'title')
+
+ def read(self, request, slug=None):
+ if slug:
+ return get_object_or_404(Book, slug=slug)
+ else:
+ return Book.objects.all()