literature.views module#

class literature.views.AuthorDetail(**kwargs)[source]#

Bases: CitationMixin, DetailView

get_context_data(**kwargs)[source]#

Insert the single object into the context dict.

model#

alias of Author

class literature.views.AuthorList(**kwargs)[source]#

Bases: ListView

get_queryset()[source]#

Return the list of items for this view.

The return value must be an iterable and may be an instance of QuerySet in which case QuerySet specific behavior will be enabled.

model#

alias of Author

class literature.views.CitationMixin[source]#

Bases: object

citation_style = 'bootstrap'#
get_context_data(**kwargs)[source]#
class literature.views.LiteratureDetail(**kwargs)[source]#

Bases: FormCollectionView, CitationMixin

collection_class#

alias of LiteratureFormCollection

extra_context = None#
form_valid(form)[source]#
template_name = 'literature/literature_form.html'#
class literature.views.LiteratureForm(data=None, files=None, auto_id='id_%s', prefix=None, initial=None, error_class=<class 'django.forms.utils.ErrorList'>, label_suffix=None, empty_permitted=False, instance=None, use_required_attribute=None, renderer=None)[source]#

Bases: ModelForm

class Meta[source]#

Bases: object

exclude = ['published', 'year']#
model#

alias of Literature

base_fields = {'CSL': <django.forms.fields.JSONField object>, 'abstract': <django.forms.fields.CharField object>, 'authors': <sortedm2m.forms.SortedMultipleChoiceField object>, 'citation_key': <django.forms.fields.CharField object>, 'collections': <django.forms.models.ModelMultipleChoiceField object>, 'comment': <django.forms.fields.CharField object>, 'container_title': <django.forms.fields.CharField object>, 'keyword': <taggit.forms.TagField object>, 'language': <django.forms.fields.CharField object>, 'pdf': <django.forms.fields.FileField object>, 'title': <django.forms.fields.CharField object>, 'type': <django.forms.fields.TypedChoiceField object>}#
declared_fields = {}#
property media#

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

class literature.views.LiteratureList(**kwargs)[source]#

Bases: CitationMixin, ListView

get_queryset()[source]#

Return the list of items for this view.

The return value must be an iterable and may be an instance of QuerySet in which case QuerySet specific behavior will be enabled.

model#

alias of Literature

literature.views.process_csl(request)[source]#