Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AnalyticalTable]: If infinite loading is enabled, loading new rows erases select all #6830

Open
1 task done
Nemin32 opened this issue Jan 17, 2025 · 1 comment · May be fixed by #6831
Open
1 task done

[AnalyticalTable]: If infinite loading is enabled, loading new rows erases select all #6830

Nemin32 opened this issue Jan 17, 2025 · 1 comment · May be fixed by #6831

Comments

@Nemin32
Copy link

Nemin32 commented Jan 17, 2025

Describe the bug

We are trying to implement a feature where a user may act on possibly hundreds of rows of data which is dynamically loaded into an AnalyticalTable using a scroll-triggered infinite load. Our issue is that upon scrolling down, the newly loaded rows are not selected, and the selected all checkmark switches into the indeterminate "some rows selected" state.

This forces users to press select all after every single data load until the desired amount of rows are selected, which is very counter-intuitive and could easily result in users not noticing that less data is selected than intended.

Isolated Example

No response

Reproduction steps

  1. Create an AnalyticalTable with a scroll-triggered infinite load andselectionMode set to multiple
  2. Enable select all by checking the mark on the top left corner.
  3. Scroll until new data is loaded
  4. Observe that the new data is not selected and the checkmark has turned into a square.

This page is kind-of an example, however, for some reason it completely deselects everything on more data load: https://sap.github.io/ui5-webcomponents-react/v2/?path=/story/data-display-analyticaltable--infinite-scrolling&args=selectionMode:Multiple

Expected Behaviour

If select-all is enabled: All newly loaded rows should be selected as well.
If only some rows are selected: The selected rows' state is preserved.

Screenshots or Videos

No response

UI5 Web Components for React Version

2.4.0

UI5 Web Components Version

2.4.0

Browser

Firefox

Operating System

MacOS 15

Additional Context

No response

Relevant log output

Organization

GCID

Declaration

  • I’m not disclosing any internal or sensitive information.
@Lukas742
Copy link
Contributor

Hi @Nemin32

you have to prevent the internal table state from resetting when updating data. You can find out more about this in the "How to stop the table state from automatically resetting when the data changes?" Recipe.

The linked PR will outline this behavior better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🆕 New
Development

Successfully merging a pull request may close this issue.

2 participants