Skip to content
This repository has been archived by the owner on Aug 9, 2024. It is now read-only.

Ext.data.TreeStore.filterNodes incorrectly keeps empty nodes in search results #1871

Open
fabriciomurta opened this issue Jan 21, 2022 · 1 comment

Comments

@fabriciomurta
Copy link
Contributor

Found: 5.3.0
Ext.NET forums' thread: TreePanel filter empty container disappear by click

The Ext.NET's own tree filtering facility overridden in Ext.tree.Panel.filterBy() (ultimately calling Ext.data.TreeStore.filterNodes()) incorrectly keeps empty nodes shown even if they have no matching children in the tree.

This causes the node, if interacted with (expading/collapsing), to refresh and finally "vanish" from the tree, making a filtered tree unreliable.

The issue is bound to an Ext.NET specific feature but it seems to have been introduced due to Sencha's changes in API since at least Ext JS 6.

@fabriciomurta
Copy link
Contributor Author

For now, it looks like using store logic (as with Tree Panel > Advanced > Filters Example) and setting store's filterer: 'bottomup' does the same behavior old TreePanel logic filter did.

In the example linked above, adding this listener is enough to set the "store logic" to work as intended:

<Listeners>
    <AfterRender Handler="this.getStore().filterer = 'bottomup';" />
</Listeners>

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant