#32876: The parametered `all` is not preserved after save object in django 
admin.
-------------------------------+--------------------------------------
     Reporter:  A-hông         |                    Owner:  nobody
         Type:  Uncategorized  |                   Status:  closed
    Component:  contrib.admin  |                  Version:  3.2
     Severity:  Normal         |               Resolution:  invalid
     Keywords:                 |             Triage Stage:  Unreviewed
    Has patch:  0              |      Needs documentation:  0
  Needs tests:  0              |  Patch needs improvement:  0
Easy pickings:  0              |                    UI/UX:  0
-------------------------------+--------------------------------------

Old description:

> 1. Login in django admin
> 2. Enter a changelist page of model
> 3. Order by a column in changelist page
> 4. Display all in changelist page
> 5. Enter change form page
> 6. Save
> 7. The order is keeped but `all` is disappeared

New description:

 1. Login in django admin
 2. Enter a changelist page of model
 3. Order by a column in changelist page
 4. Display all in changelist page
 5. Enter change form page
 6. Save
 7. The order is kept but `all` is disappeared

--

Comment (by A-hông):

 `q`(query), `o`(order) and `all`(display all) can be set at the same time.
 `q`(query) and `o`(order) are kept but `all`(display all) not, when from
 change form back to changelist.

 `all` should be kept in the fillter of changelist.
 I found
 
[https://github.com/django/django/blob/1bbb98d9a4b7d83e422b14ae2429cb368eff5a13/django/contrib/admin/templatetags/admin_urls.py#L42
 parse_qsl in admin_urls.py] will remove the keys which has no value.


 > from urllib.parse import parse_qsl, unquote, urlparse, urlunparse
 > parse_qsl('q=2&all=')
 > => [('q', '2')]

 It is why `all`(display all) cannot be kept.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/32876#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/072.21fcb8266a175c8c4f8b5e87a4c8d93c%40djangoproject.com.

Reply via email to