-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Table: datakey attribute not working correctly in table with expandable rows group #13645
Comments
Hello, |
Hi @ZellCorp @AhmedSaulti , A similar issue has been addressed in #14672 |
Hi @cetincakiroglu, The current challenge is to have a checkbox at the level of the group header which reflects only on the rows of its group, that doesn't go on correctly. I will try to work on it in a custom manner but if there is a clue about it that its included already, I would appreciate it. Thanks |
Could you please share a stackblitz example about the row issue and tag me so we can investigate |
Here my friend a demo based on the example, I modified the table header to be a tristate checkbox and wanted to apply the same logic to the group header as well, showing partial and full selection. https://stackblitz.com/edit/sahfjj?file=src%2Fapp%2Fdemo%2Ftable-expandable-row-group-demo.html |
Hi @AhmedSaulti, Unfortunately, that behavior is not supported. All we can do is try monkey patch to find a workaround. We cannot also update the table so it can behave tristate or reflect the group selection. Maybe you can try treatable component for it? Compared to the table, it's easier to utilize checkbox selection in groups with tree table https://primeng.org/treetable#checkbox However, tristate is not supported in treatable too, you'll still need to find a workaround. I'm closing the issue since the mentioned bug has already fixed. Could you please open a discussion and share it with the community if you find a workaround with tristate? Maybe someone trying to do same, would be a good example. |
Describe the bug
Hello !
there the issue :
Using the table component, when datakey value is from a different object than the one used in groupRowsBy
Then, the row group will change to contains only one element except the case where datakey value is undefined.
For exemple consider the following data/domain object :
This code will work (useless part removed for the explication):
This code will not (useless part removed for the explication):
The bug can be reproduced using the demo from : https://primeng.org/table#expand
Or from the stackblitz link below.
Good luck :)
Environment
Nothing specific.
Reproducer
https://stackblitz.com/edit/yxteqe?file=src%2Fapp%2Fdemo%2Ftable-expandable-row-group-demo.html
Angular version
16.2.0
PrimeNG version
16.3.1
Build / Runtime
TypeScript
Language
TypeScript
Node version (for AoT issues node --version)
18.13.0
Browser(s)
No response
Steps to reproduce the behavior
Expected behavior
We expect to see all data displayed by group and identify them by their id
The text was updated successfully, but these errors were encountered: