thabloid package

Submodules

thabloid.admin module

class thabloid.admin.ThabloidAdmin(model, admin_site)[source]

Bases: django.contrib.admin.options.ModelAdmin

form

alias of ThabloidAdminForm

list_filter = ('year',)
property media
class thabloid.admin.ThabloidAdminForm(*args, **kwargs)[source]

Bases: django.forms.models.ModelForm

base_fields = {}
declared_fields = {}
property media

Return all media required to render the widgets on this form.

thabloid.admin.association_year_choices()[source]

thabloid.apps module

class thabloid.apps.ThabloidConfig(app_name, app_module)[source]

Bases: django.apps.config.AppConfig

name = 'thabloid'
verbose_name = 'Thabloid'

thabloid.models module

class thabloid.models.Thabloid(id, year, issue, file)[source]

Bases: django.db.models.base.Model

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

property cover
extract_thabloid_pages(wait)[source]
file

The descriptor for the file attribute on the model instance. Return a FieldFile when accessed so you can write code like:

>>> from myapp.models import MyModel
>>> instance = MyModel.objects.get(pk=1)
>>> instance.file.size

Assign a file object on assignment so you can do:

>>> with open('/path/to/hello.world') as f:
...     instance.file = File(f)
get_absolute_url()[source]
id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

issue

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
page_url(page=None, second_page=None)[source]
property pages
pagesets(count)[source]
post_extract()[source]
save(*args, wait=False, **kwargs)[source]

Save the current instance. Override this in a subclass if you want to control the saving process.

The ‘force_insert’ and ‘force_update’ parameters can be used to insist that the “save” must be an SQL insert or update (or equivalent for non-SQL backends), respectively. Normally, they should not be set.

year

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

thabloid.models.thabloid_filename(instance, filename)[source]

thabloid.sitemaps module

class thabloid.sitemaps.StaticViewSitemap[source]

Bases: django.contrib.sitemaps.Sitemap

changefreq = 'monthly'
items()[source]
location(item)[source]
class thabloid.sitemaps.ThabloidSitemap[source]

Bases: django.contrib.sitemaps.Sitemap

changefreq = 'never'
items()[source]
location(item)[source]

thabloid.urls module

The routes defined by the thabloid package

thabloid.views module

thabloid.views.index(request)[source]
thabloid.views.pages(request, year, issue)[source]