mirror of
https://github.com/django/django.git
synced 2025-08-04 19:08:28 +00:00
Fixed #25508 -- Modified QuerySet.__repr__() to disambiguate it from a list.
This commit is contained in:
parent
3543fec3b7
commit
e0837f2cb1
20 changed files with 185 additions and 184 deletions
|
@ -912,7 +912,7 @@ extra forms displayed.
|
|||
``max_num`` does not prevent existing objects from being displayed::
|
||||
|
||||
>>> Author.objects.order_by('name')
|
||||
[<Author: Charles Baudelaire>, <Author: Paul Verlaine>, <Author: Walt Whitman>]
|
||||
<QuerySet [<Author: Charles Baudelaire>, <Author: Paul Verlaine>, <Author: Walt Whitman>]>
|
||||
|
||||
>>> AuthorFormSet = modelformset_factory(Author, fields=('name',), max_num=1)
|
||||
>>> formset = AuthorFormSet(queryset=Author.objects.order_by('name'))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue