Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
f2e0266b
Kaydet (Commit)
f2e0266b
authored
Kas 07, 2013
tarafından
Baptiste Mispelon
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #21396: Document backwards-incompatible change in RedirectView.get_redirect_url.
Thanks to Tim for the review.
üst
536c4478
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
3 deletions
+20
-3
base.txt
docs/ref/class-based-views/base.txt
+14
-3
1.6.txt
docs/releases/1.6.txt
+6
-0
No files found.
docs/ref/class-based-views/base.txt
Dosyayı görüntüle @
f2e0266b
...
...
@@ -233,12 +233,23 @@ RedirectView
**Methods**
.. method:: get_redirect_url(**kwargs)
.. method:: get_redirect_url(*
args, *
*kwargs)
Constructs the target URL for redirection.
.. versionchanged:: 1.6
The signature of this method was changed to include ``*args``.
The default implementation uses :attr:`url` as a starting
string, performs expansion of ``%`` parameters in that string, as well
as the appending of query string if requested by :attr:`query_string`.
string and performs expansion of ``%`` named parameters in that string
using the named groups captured in the URL.
If :attr:`url` is not set, ``get_redirect_url()`` tries to reverse the
:attr:`pattern_name` using what was captured in the URL (both named and
unnamed groups are used).
If requested by :attr:`query_string`, it will also append the query
string to the generated URL.
Subclasses may implement any behavior they wish, as long as the method
returns a redirect-ready URL string.
docs/releases/1.6.txt
Dosyayı görüntüle @
f2e0266b
...
...
@@ -913,6 +913,12 @@ Miscellaneous
been removed. Use ``socket.error`` provided by the standard library instead.
This change was also released in Django 1.5.5.
* The signature of :meth:`django.views.generic.base.RedirectView.get_redirect_url`
has changed and now accepts positional arguments as well (``*args, **kwargs``).
Any unnamed captured group will now be passed to ``get_redirect_url()``
which may result in a ``TypeError`` if you don't update the signature of your
custom method.
Features deprecated in 1.6
==========================
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment