From ffa25009fd06b053e99c14960643f4c5f2c5092a Mon Sep 17 00:00:00 2001 From: Tom Christie Date: Fri, 29 Aug 2014 10:11:44 +0100 Subject: 2.4 release --- api-guide/generic-views.html | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'api-guide/generic-views.html') diff --git a/api-guide/generic-views.html b/api-guide/generic-views.html index be6e19f1..9ae8efff 100644 --- a/api-guide/generic-views.html +++ b/api-guide/generic-views.html @@ -121,6 +121,7 @@ a.fusion-poweredby {
lookup_field - The model field that should be used to for performing object lookup of individual model instances. Defaults to 'pk'. Note that when using hyperlinked APIs you'll need to ensure that both the API views and the serializer classes set the lookup fields if you need to use a custom value.lookup_url_kwarg - The URL keyword argument that should be used for object lookup. The URL conf should include a keyword argument corresponding to this value. If unset this defaults to using the same value as lookup_field.Shortcuts:
-model - This shortcut may be used instead of setting either (or both) of the queryset/serializer_class attributes, although using the explicit style is generally preferred. If used instead of serializer_class, then DEFAULT_MODEL_SERIALIZER_CLASS setting will determine the base serializer class. Note that model is only ever used for generating a default queryset or serializer class - the queryset and serializer_class attributes are always preferred if provided.Pagination:
The following attributes are used to control pagination when used with list views.
filter_backends - A list of filter backend classes that should be used for filtering the queryset. Defaults to the same value as the DEFAULT_FILTER_BACKENDS setting.Deprecated attributes:
+model - This shortcut may be used instead of setting either (or both) of the queryset/serializer_class attributes. The explicit style is preferred over the .model shortcut, and usage of this attribute is now deprecated.Base methods:
get_queryset(self)