Re: Clear all filters

2020-05-19 Thread Adam Johnson
Fran, your design looks nice. I think we should make a ticket that combines
making the "X total" link preserve the query params and adding your other
suggested changes.

On Tue, 19 May 2020 at 08:12, Aymeric Augustin <
aymeric.augus...@polytechnique.org> wrote:

> On 18 May 2020, at 11:10, Mariusz Felisiak 
> wrote:
>
> Link to the right of the search box ("X total") already removes the entire
> query string, so ...
>
>
> Ah, this is a bug I'm hitting!
>
> I have a small personal app where I classify data. Some classification is
> automated with regexes. New data needs to be classified manually.
>
> My typical workflow is:
>
> - filter on unclassified data
> - find something interesting
> - use the search field to find all similar data
> - classify it (directly in the list view, thanks to list_editable)
> - clear the search => I lose my filter :-(
> - filter on unclassified data again
> - etc.
>
> Having to set the filter again and again is a minor annoyance so I haven't
> bothered to report a bug. But it's the wrong behavior in this case.
>
> Best regards,
>
> --
> Aymeric.
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/D962DF7E-2B2F-4D37-9F8C-609ACE4120E9%40polytechnique.org
> 
> .
>


-- 
Adam

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM0rd5KcJxnU2Y379vX9WUsSSn_MBJXEj6CHPE2yPKSCbw%40mail.gmail.com.


Re: Clear all filters

2020-05-19 Thread Aymeric Augustin
On 18 May 2020, at 11:10, Mariusz Felisiak  wrote:

> Link to the right of the search box ("X total") already removes the entire 
> query string, so ...


Ah, this is a bug I'm hitting!

I have a small personal app where I classify data. Some classification is 
automated with regexes. New data needs to be classified manually.

My typical workflow is:

- filter on unclassified data
- find something interesting
- use the search field to find all similar data
- classify it (directly in the list view, thanks to list_editable)
- clear the search => I lose my filter :-(
- filter on unclassified data again
- etc.

Having to set the filter again and again is a minor annoyance so I haven't 
bothered to report a bug. But it's the wrong behavior in this case.

Best regards,

-- 
Aymeric.



-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/D962DF7E-2B2F-4D37-9F8C-609ACE4120E9%40polytechnique.org.


Re: Clear all filters

2020-05-18 Thread Mariusz Felisiak
OK, I added new ticket https://code.djangoproject.com/ticket/31603.

Thanks y'all

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/d0b554c5-43c7-4cfe-8a11-4bc05323636f%40googlegroups.com.


Re: Clear all filters

2020-05-18 Thread Markus Holtermann
I tend to agree with Adam.

>From a UI/UX perspective, the location where the "Clear all filters" button 
>is, as well as the wording, suggest to me that it's only the filters on the 
>right side. The search query, while technically filtering the query set, 
>doesn't seem like a filter in the UI.

I'd potentially argue otherwise if the search field was in the filter box on 
the right.

Additionally, looking at it from the back-end, search terms and filters have 
nothing in common except for the queryset.

Cheers,

Markus


On Mon, May 18, 2020, at 11:10 AM, Mariusz Felisiak wrote:
> > I disagree Mariusz. I would NOT expect this. The "Clear all filters" button 
> > is grouped with the filters, visually separate from the search and sort 
> > controls. It's a very legitimate use case to clear the filters and maintain 
> > the search or sort, and quite a common workflow when trying to find a 
> > particular object.
> 
> The idea of this feature was to remove all filters and *search 
> criteria* in one click (see the ticket description[2]). The first 
> proposition was to put this link in actions [2], but I proposed moving 
> it to filters. I'm not sure if link for clearing only filters is still 
> necessary (and it wasn't the intention of reporter), we can remove this 
> feature if it's misleading. Link to the right of the search box ("X 
> total") already removes the entire query string, so ...
> 
> > Additionally, I see that the link only preserves the _popup=1 query param. 
> > if users have extended their admin views with any extra query params, they 
> > will also be wiped, which is less than helpful. I know I have extended the 
> > admin with extra params before e.g. to control the queryset.
> 
> Link to the right of the search box ("X total") that was added in 2005 
> [3] do the same. We should probably use `add_preserved_filters`.
> 
> [1] https://code.djangoproject.com/ticket/27888
> [2] https://github.com/django/django/pull/12351#issuecomment-577415747
> [3] 
> https://github.com/django/django/commit/9dda4abee1225db7a7b195b84c915fdd141a7260
> 
>  -- 
>  You received this message because you are subscribed to the Google 
> Groups "Django developers (Contributions to Django itself)" group.
>  To unsubscribe from this group and stop receiving emails from it, send 
> an email to django-developers+unsubscr...@googlegroups.com.
>  To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-developers/ed3810c9-bb86-4e05-97dd-4818efa1617c%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/django-developers/ed3810c9-bb86-4e05-97dd-4818efa1617c%40googlegroups.com?utm_medium=email_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/a366340a-9b8e-4ac5-9478-10380680de99%40www.fastmail.com.


Re: Clear all filters

2020-05-18 Thread Mariusz Felisiak

>
> I disagree Mariusz. I would NOT expect this. The "Clear all filters" 
> button is grouped with the filters, visually separate from the search and 
> sort controls. It's a very legitimate use case to clear the filters and 
> maintain the search or sort, and quite a common workflow when trying to 
> find a particular object.


The idea of this feature was to remove all filters and *search criteria* in 
one click (see the ticket description[2]). The first proposition was to put 
this link in actions [2], but I proposed moving it to filters. I'm not sure 
if link for clearing only filters is still necessary (and it wasn't the 
intention of reporter), we can remove this feature if it's misleading. Link 
to the right of the search box ("X total") already removes the entire query 
string, so ...

Additionally, I see that the link only preserves the _popup=1 query param. 
> if users have extended their admin views with any extra query params, they 
> will also be wiped, which is less than helpful. I know I have extended the 
> admin with extra params before e.g. to control the queryset.
>

Link to the right of the search box ("X total") that was added in 2005 [3] 
do the same. We should probably use `add_preserved_filters`.

[1] https://code.djangoproject.com/ticket/27888
[2] https://github.com/django/django/pull/12351#issuecomment-577415747
[3] 
https://github.com/django/django/commit/9dda4abee1225db7a7b195b84c915fdd141a7260

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/ed3810c9-bb86-4e05-97dd-4818efa1617c%40googlegroups.com.


Re: Clear all filters

2020-05-18 Thread Adam Johnson
I disagree Mariusz. I would NOT expect this. The "Clear all filters" button
is grouped with the filters, visually separate from the search and sort
controls. It's a very legitimate use case to clear the filters and maintain
the search or sort, and quite a common workflow when trying to find a
particular object.

Additionally, I see that the link only preserves the _popup=1 query param.
if users have extended their admin views with any extra query params, they
will also be wiped, which is less than helpful. I know I have extended the
admin with extra params before e.g. to control the queryset.

I'm +1 on changing this to take the current query params and remove only
the filter-related ones.

On Mon, 18 May 2020 at 05:36, Mariusz Felisiak 
wrote:

> Hi,
>
>  IMO the current behavior is expected, it is also included in the ticket
> description (see comment[1]).
>
> Best,
> Mariusz
>
> [1] https://code.djangoproject.com/ticket/27888#comment:1
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/56339b28-59a3-4e41-b364-adf7faa4cb83%40googlegroups.com
> <https://groups.google.com/d/msgid/django-developers/56339b28-59a3-4e41-b364-adf7faa4cb83%40googlegroups.com?utm_medium=email_source=footer>
> .
>


-- 
Adam

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM0tnc6SR2Mjb4N%2BD8UyAAExMY%2BRJyRS955DofSAEpVmsw%40mail.gmail.com.


Re: Clear all filters

2020-05-17 Thread Mariusz Felisiak
Hi,

 IMO the current behavior is expected, it is also included in the ticket 
description (see comment[1]).

Best,
Mariusz

[1] https://code.djangoproject.com/ticket/27888#comment:1

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/56339b28-59a3-4e41-b364-adf7faa4cb83%40googlegroups.com.