# Path: books/app_settings.py
# BOOKS_STATICS_VIA_DJANGO = getattr(settings, 'BOOKS_STATICS_VIA_DJANGO', False)
# 
# Path: books/views.py
# def add_language(request):
#     def get_context_data(self, **kwargs):
#     def get_context_data(self, **kwargs):
# def download_book(request, book_id):
# def tags(request, qtype=None, group_slug=None):
# def tags_listgroups(request):
# def _book_list(request, queryset, qtype=None, list_by='latest', **kwargs):
# def _author_list(request, queryset, qtype=None, list_by='latest', **kwargs):
# def home(request):
# def root(request, qtype=None):
# def latest(request, qtype=None):
# def by_title(request, qtype=None, author_id=None):
# def by_author(request, qtype=None):
# def by_tag(request, tag, qtype=None):
# def most_downloaded(request, qtype=None):
# class BookDetailView(DetailView):
# class BookEditView(UpdateView):
# class BookAddView(CreateView):
# class BookDeleteView(DeleteView):


import os
from django.conf.urls import include, url
from django.conf import settings
from books.app_settings import BOOKS_STATICS_VIA_DJANGO
from books import views
    from django.views.static import serve
     {}, 'most_downloaded'),

    # Tag groups:
    url(r'^tags/groups.atom$', views.tags_listgroups,
     {}, 'tags_listgroups'),

    # Book list Atom:
    url(r'^catalog.atom$', views.root,
     {'qtype': u'feed'}, 'root_feed'),
    url(r'^latest.atom$', views.latest,
     {'qtype': u'feed'}, 'latest_feed'),
    url(r'^by-title.atom$', views.by_title,
     {'qtype': u'feed'}, 'by_title_feed'),
    url(r'^by-author.atom$', views.by_author,
     {'qtype': u'feed'}, 'by_author_feed'),
    url(r'^by-author/(?P<author_id>\d+).atom$', views.by_title,
     {'qtype': u'feed'}, 'by_author_feed'),
    url(r'^tags/(?P<tag>.+).atom$', views.by_tag,
     {'qtype': u'feed'}, 'by_tag_feed'),
    url(r'^by-popularity.atom$', views.most_downloaded,
     {'qtype': u'feed'}, 'most_downloaded_feed'),

    # Tag groups:
    url(r'^tags/groups/(?P<group_slug>[-\w]+)/$', views.tags,
     {}, 'tag_groups'),

    url(r'^tags/groups/(?P<group_slug>[-\w]+).atom$', views.tags,
     {'qtype': u'feed'}, 'tag_groups_feed'),

    # Tag list:

# Path: books/app_settings.py
# BOOKS_STATICS_VIA_DJANGO = getattr(settings, 'BOOKS_STATICS_VIA_DJANGO', False)
# 
# Path: books/views.py
# def add_language(request):
#     def get_context_data(self, **kwargs):
#     def get_context_data(self, **kwargs):
# def download_book(request, book_id):
# def tags(request, qtype=None, group_slug=None):
# def tags_listgroups(request):
# def _book_list(request, queryset, qtype=None, list_by='latest', **kwargs):
# def _author_list(request, queryset, qtype=None, list_by='latest', **kwargs):
# def home(request):
# def root(request, qtype=None):
# def latest(request, qtype=None):
# def by_title(request, qtype=None, author_id=None):
# def by_author(request, qtype=None):
# def by_tag(request, tag, qtype=None):
# def most_downloaded(request, qtype=None):
# class BookDetailView(DetailView):
# class BookEditView(UpdateView):
# class BookAddView(CreateView):
# class BookDeleteView(DeleteView):


# Path: books/urls.py
import os
from django.conf.urls import include, url
from django.conf import settings
from books.app_settings import BOOKS_STATICS_VIA_DJANGO
from books import views
    from django.views.static import serve

     {}, 'most_downloaded'),

    # Tag groups:
    url(r'^tags/groups.atom$', views.tags_listgroups,
     {}, 'tags_listgroups'),

    # Book list Atom:
    url(r'^catalog.atom$', views.root,
     {'qtype': u'feed'}, 'root_feed'),
    url(r'^latest.atom$', views.latest,
     {'qtype': u'feed'}, 'latest_feed'),
    url(r'^by-title.atom$', views.by_title,
     {'qtype': u'feed'}, 'by_title_feed'),
    url(r'^by-author.atom$', views.by_author,
     {'qtype': u'feed'}, 'by_author_feed'),
    url(r'^by-author/(?P<author_id>\d+).atom$', views.by_title,
     {'qtype': u'feed'}, 'by_author_feed'),
    url(r'^tags/(?P<tag>.+).atom$', views.by_tag,
     {'qtype': u'feed'}, 'by_tag_feed'),
    url(r'^by-popularity.atom$', views.most_downloaded,
     {'qtype': u'feed'}, 'most_downloaded_feed'),

    # Tag groups:
    url(r'^tags/groups/(?P<group_slug>[-\w]+)/$', views.tags,
     {}, 'tag_groups'),

    url(r'^tags/groups/(?P<group_slug>[-\w]+).atom$', views.tags,
     {'qtype': u'feed'}, 'tag_groups_feed'),

    # Tag list:

    url(r'^tags/$', views.tags, {}, 'tags'),