From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: Mira Limbeck <m.limbeck@proxmox.com>, pmg-devel@lists.proxmox.com
Subject: Re: [pmg-devel] [PATCH pmg-gui v2] fix #4510: add filter box to many grids
Date: Wed, 21 Feb 2024 17:57:31 +0100 [thread overview]
Message-ID: <7ba40235-f75b-4233-95f3-0a73c762ae7f@proxmox.com> (raw)
In-Reply-To: <9caa86c3-246c-4c74-a295-f62c69fff6e0@proxmox.com>
Am 21/02/2024 um 17:55 schrieb Thomas Lamprecht:
> yeah I could reproduce this here too, this is because the filter needs clearing
> for any change, as otherwise all those filtered out since the last full clear
> won't be considered any more. The following diff on-top fixes this:
>
>
> diff --git a/js/form/FilterField.js b/js/form/FilterField.js
> index 53fdfbf..2c6d4b8 100644
> --- a/js/form/FilterField.js
> +++ b/js/form/FilterField.js
> @@ -34,6 +34,9 @@ Ext.define('PMG.form.FilterField', {
> me.store = grid.getStore();
> }
>
> + me.store.clearFilter();
> + field.triggers.clear.setVisible(value.length > 0);
> +
> if (value) {
> me.store.filterBy((rec) => me.filteredFields.some((fieldDef) => {
> let fieldname, renderer;
> @@ -47,10 +50,6 @@ Ext.define('PMG.form.FilterField', {
> let testedValue = renderer(rec.data[fieldname]);
> return testedValue.toString().toLowerCase().indexOf(value.toLowerCase()) !== -1;
> }));
> - field.triggers.clear.setVisible(true);
> - } else {
> - me.store.clearFilter();
> - field.triggers.clear.setVisible(false);
> }
> },
> },
>
>
I missed the v3...
prev parent reply other threads:[~2024-02-21 16:57 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-21 13:01 Dominik Csapak
2024-02-21 14:45 ` Mira Limbeck
2024-02-21 16:55 ` Thomas Lamprecht
2024-02-21 16:57 ` Thomas Lamprecht [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7ba40235-f75b-4233-95f3-0a73c762ae7f@proxmox.com \
--to=t.lamprecht@proxmox.com \
--cc=m.limbeck@proxmox.com \
--cc=pmg-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.