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

Adding in remove capability for group members + csv download #1367

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

kiram15
Copy link
Contributor

@kiram15 kiram15 commented Dec 12, 2024

Because I'm going on Christmas break, this isn't a fully finished PR. It doesn't contain tests, nor does it have the filter functionality needed in the CSV download when a user searches a string or filters on something else.

For all changes

  • Ensure adequate tests are in place (or reviewed existing tests cover changes)

Only if submitting a visual change

  • Ensure to attach screenshots
  • Ensure to have UX team confirm screenshots

Copy link

codecov bot commented Dec 12, 2024

Codecov Report

Attention: Patch coverage is 53.42466% with 34 lines in your changes missing coverage. Please review.

Project coverage is 85.53%. Comparing base (371f043) to head (7cf109c).

Files with missing lines Patch % Lines
...leManagement/GroupDetailPage/DownloadCsvButton.jsx 53.33% 14 Missing ⚠️
...leManagement/GroupDetailPage/RemoveMemberModal.jsx 33.33% 10 Missing ⚠️
src/components/PeopleManagement/utils.js 11.11% 8 Missing ⚠️
...leManagement/GroupDetailPage/GroupMembersTable.jsx 94.11% 1 Missing ⚠️
src/components/PeopleManagement/constants.js 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1367      +/-   ##
==========================================
- Coverage   85.72%   85.53%   -0.19%     
==========================================
  Files         609      611       +2     
  Lines       13363    13423      +60     
  Branches     2812     2812              
==========================================
+ Hits        11455    11481      +26     
- Misses       1838     1872      +34     
  Partials       70       70              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

return `${year}-${month}-${day}-group-detail-report.csv`;
};

const createCsvData = (jsonData) => jsonToCsv(jsonData.map(row => ({
Copy link
Contributor

@marlonkeating marlonkeating Dec 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue with generating the csv file like this is that it can only generate a file with the current page of group member results.

If you want to take the client side approach, you can do it (prior art here) but you'll need to do another fetch of the data with page_size set to the total count of the filtered results.

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

Successfully merging this pull request may close these issues.

2 participants