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

Table | Multiple Selection with dataKey shows wrong selected row count upon CTRL+A #15903

Closed
mehmetcetin01140 opened this issue Jun 25, 2024 · 1 comment · Fixed by #15904, #15917 or #15926 · May be fixed by Rodolphe33/gestion-personnel#12 or diaz-rigo/austins#17
Assignees
Labels
LTS-16-PORTABLE LTS-FIXED-16.9.12 PRO Support Issue was reported by PRO User Type: Bug Issue contains a bug related to a specific component. Something about the component is not working v18-port
Milestone

Comments

@mehmetcetin01140
Copy link
Contributor

Steps to reproduce:
Create a p-table with multiple selection enabled and use the dataKey property.
Populate the table with sample data.
Click on the Top rows in the table and press CTRL+A to select all rows.

Expected Result: All rows should be selected, and the selected row count should display the correct number of rows.

Actual Result: All rows are selected, but the selected row count is incorrect.

Sample Application: https://stackblitz.com/edit/z1cdw3-crjdxm?file=angular.json

@mehmetcetin01140 mehmetcetin01140 added Type: Bug Issue contains a bug related to a specific component. Something about the component is not working PRO Support Issue was reported by PRO User labels Jun 25, 2024
@mehmetcetin01140 mehmetcetin01140 added this to the 17.18.2 milestone Jun 25, 2024
@mehmetcetin01140 mehmetcetin01140 self-assigned this Jun 25, 2024
@github-actions github-actions bot added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jun 25, 2024
@mehmetcetin01140 mehmetcetin01140 removed the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jun 25, 2024
cetincakiroglu added a commit that referenced this issue Jun 27, 2024
Fixed #15903 - Table | Multiple Selection with dataKey shows wrong se…
@quentin-ineat-ca
Copy link

quentin-ineat-ca commented Jun 27, 2024

@cetincakiroglu Unfortunately still not functional. Same stackblitz than above but updated primeng 17.18.2. https://stackblitz.com/edit/z1cdw3-snozxu
Cmd + a is now working but selection with datakey is now broken.

  1. CMD + A : ok
  2. Then CMD + Click on a line : The total is broken and duplicate all selected lines.

Please add unit tests for table because it's such a critical component 🙏
A bit disappointed that this ticket mentions 'datakey' and 'ctrl + a' but 'datakey' alone was not even tested after the fix.

@github-actions github-actions bot added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jun 28, 2024
@cetincakiroglu cetincakiroglu removed the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jun 28, 2024
cetincakiroglu added a commit that referenced this issue Jun 28, 2024
cetincakiroglu added a commit that referenced this issue Jun 28, 2024
Revert "Fixed #15903 - Table | Multiple Selection with dataKey shows wrong selected row count upon CTRL+A"
cetincakiroglu added a commit that referenced this issue Jun 28, 2024
Revert "Fixed #15903 - Table | Multiple Selection with dataKey shows wrong se…"
@github-actions github-actions bot added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Jul 1, 2024
@mehmetcetin01140 mehmetcetin01140 modified the milestones: 17.18.2, 17.18.3 Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment