[MM-63516] Target LegalHold users by groups#137
Conversation
|
@fmartingr some of the Playwright Tests are failing on this PR, but I don't believe they are related to my change. For example: I know you recently made fixes for Playwright Tests - do you have any ideas on why they may be failing here? |
I investigated a bit and there was a change on the trial request this week, country code is now mandatory. I've managed this in a new PR and I'm waiting on directions on how to fill the country field: #138 |
fmartingr
left a comment
There was a problem hiding this comment.
Great work on this! Left a few non-blocking comments/questions.
BenCookie95
left a comment
There was a problem hiding this comment.
Looks mostly good! Just a few comments
This reverts commit 1ea8ffb.
|
@davidkrauser We need to run this job whenever we want for testing, for which there is already a PR created #129 . Is there any other way to run this job(one could be manually hitting the API through postman) since this PR is not merged yet? |
|
@AayushChaudhary0001 we could wait until #129 merges before testing this if that helps - it looks like that one is close to finished. WDYT? |
|
@davidkrauser It consists of some comments, which should not take much time to fix. Once that is merged, we can quickly test this as well as it would help us in the completion. Let me know if this works for you. |
|
@AayushChaudhary0001 that would work just fine, thank you. |
This fixes: - A compilation error (userID -> user.Id) - Broken grid layout on legal hold table view (needed an extra column) - Broken handling of null user ID array
|
@AayushChaudhary0001 This should be ready to be looked at again when you are available. I've merged in the latest from 'main' and fixed up the conflicts. |
Summary
This change adds support for specifying LDAP groups when defining Legal Hold users. Previously, administrators could only select individual users. Now, they can specify groups, and all users within those groups will be included in the legal hold report. This makes managing users in a report much easier and more scalable.
Ticket Link
https://mattermost.atlassian.net/browse/MM-63516
Changes
The commits in this PR are roughly grouped by specific change:
New Features
Bug Fixes & Maintenance
Limitations
The end user is currently limited to 5000 users in a group. This is way more than I expect a user will use, and thus isn't a real limitation. I included this just to ensure we don't have an unbounded group size. It's specified here, and can be updated later if we want to limit it further:
mattermost-plugin-legal-hold/server/legalhold/legal_hold.go
Lines 487 to 488 in 07e8c0d
The real limit is still the total number of posts that can be included in a report, which is specified here:
mattermost-plugin-legal-hold/server/legalhold/legal_hold.go
Line 22 in 07e8c0d
Video Demo
Here is a video of the new UI components in action:
legal-hold-group-ui.webm
Update: you can now search by group @-name
This was requested here: #137 (comment)
search-by-name.webm