categories.views.CategoryRelatedList

CategoryRelatedList#

class categories.views.CategoryRelatedList(**kwargs)[source]#

List related category items.

Methods

as_view(**initkwargs)

Main entry point for a request-response process.

dispatch(request, *args, **kwargs)

get(request, *args, **kwargs)

get_allow_empty()

Return True if the view should display empty lists and False if a 404 should be raised instead.

get_context_data(*[, object_list])

Get the context for this view.

get_context_object_name(object_list)

Get the name of the item to be used in the context.

get_ordering()

Return the field or fields to use for ordering the queryset.

get_paginate_by(queryset)

Get the number of items to paginate by, or None for no pagination.

get_paginate_orphans()

Return the maximum number of orphans extend the last page by when paginating.

get_paginator(queryset, per_page[, orphans, ...])

Return an instance of the paginator for this view.

get_queryset()

Get the list of items.

get_template_names()

Get the template names.

http_method_not_allowed(request, *args, **kwargs)

options(request, *args, **kwargs)

Handle responding to requests for the OPTIONS HTTP verb.

paginate_queryset(queryset, page_size)

Paginate the queryset, if needed.

render_to_response(context, **response_kwargs)

Return a response, using the response_class for this view, with a template rendered with the given context.

setup(request, *args, **kwargs)

Initialize attributes shared by all view methods.

Attributes

allow_empty

content_type

context_object_name

extra_context

http_method_names

model

ordering

page_kwarg

paginate_by

paginate_orphans

path_field

queryset

template_engine

template_name

template_name_suffix