Ver código fonte

Fixed #36026 -- Clarified that View.setup() sets the request, args, kwargs attributes.

Chaitanya Rahalkar 3 meses atrás
pai
commit
d97cacc2ae
1 arquivos alterados com 5 adições e 0 exclusões
  1. 5 0
      docs/ref/class-based-views/base.txt

+ 5 - 0
docs/ref/class-based-views/base.txt

@@ -87,6 +87,11 @@ MRO is an acronym for Method Resolution Order.
 
         Performs key view initialization prior to :meth:`dispatch`.
 
+        Assigns the :class:`~django.http.HttpRequest` to the view's ``request``
+        attribute, and any positional and/or keyword arguments
+        :ref:`captured from the URL pattern <how-django-processes-a-request>`
+        to the ``args`` and ``kwargs`` attributes, respectively.
+
         If overriding this method, you must call ``super()``.
 
     .. method:: dispatch(request, *args, **kwargs)