Skip to content

Conversation

@iam-vir-harshit
Copy link

@iam-vir-harshit iam-vir-harshit commented Aug 31, 2024

References

Description -

  • The list of current members on the edit group page is searchable now;
  • Edit EPerson page allows (admins) to delete person from groups it is a member of without having to go to that
    group page.

List of changes in this PR:

  1. For searching the current editing group members (includes frontend and backend task) :-
    a) - In the Frontend, we have added a search form;
    b) - In the Backend, we have added a search method("findIsMemberOf") that receives current editing group id and query parameter which
    searches in the current member's list of the editing group;

  2. For deleting the eperson from groups (includes only frontend task) :-
    a) - We have only added an extra column in the edit eperson page for giving remove button;
    b) - We are utilizing the same api created for unlinking an eperson from the group in the edit group page;

Steps to reproduce:-

Task 1- Search option in the group edit page (in current epeople members section)

  1. Login as admin user
  2. Go to Access Control option in the side pannel
  3. Then go to Groups section in the Access Control
  4. Then choose a group to edit and enter into the edit group screen
  5. In the current members of EPeople section, now you will get a search option to search a member

Task 2- Remove button in the particular EPeople edit page

  1. Login as admin user
  2. Go to Access Control option in the side pannel
  3. Then go to People section in the Access Control
  4. Then choose a epeople to edit and enter into the edit epeople screen
  5. At the bottom, in the "Member of these groups" section, now you will find remove button corresponding to each group

@github-actions
Copy link

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@iam-vir-harshit
Copy link
Author

Rebased with dspace-angular main branch

Copy link
Member

@tdonohue tdonohue left a comment

Choose a reason for hiding this comment

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

@iam-vir-harshit : Thanks also for this PR! Apologies for the delay in reviewing this, but we gave this a code review as a team in today's Developer Meeting. Overall, the code looks good, but again we are noticing that automated tests are missing:

  • The changes to eperson-form.component.ts should all be tested in eperson-form.component.spec.ts
  • Similarly, the changes to members-list.component.ts should all have automated tests in members-list.component.spec.ts.

Once those automated tests are added, the Codecov warnings on this PR (in the "Files changed" tab) should go away (or mostly go away). We can then work to get this tested and merged quickly. Thanks again!

@github-actions
Copy link

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue
Copy link
Member

@iam-vir-harshit : Just a friendly reminder, that if you want this PR to be considered for the 9.0 release, we will need to have the feedback above resolved soon (and any merge conflicts resolved). Our 9.0 feature merger deadline is March 28. Anything not approved & merged by that date will unfortunately need to be delayed for the next major release.

@tdonohue tdonohue moved this from 👀 Under Review to ❓ Stalled/On Hold in DSpace 9.0 Release Mar 28, 2025
@github-actions
Copy link

github-actions bot commented May 5, 2025

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@github-actions
Copy link

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue tdonohue moved this from 🙋 Needs Reviewers Assigned to 👀 Under Review in DSpace 10.0 Release May 19, 2025
@tdonohue tdonohue requested a review from MarieVerdonck July 17, 2025 14:58
Copy link
Member

@tdonohue tdonohue left a comment

Choose a reason for hiding this comment

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

@iam-vir-harshit and @PitbaranK : We reviewed this as a team in today's DSpace Developers Meeting. I've summarized the code review feedback in the comments below. Let us know once you've addressed these comments, and hopefully we can find someone to quickly re-review or test it.


@if (activeEPerson$ | async) {
<h1 class="border-bottom pb-2">{{messagePrefix + '.edit' | translate}}</h1>
<h1 class="border-bottom pb-2">{{messagePrefix + '.edit' | translate}}</h1>
Copy link
Member

Choose a reason for hiding this comment

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

All these re-alignment changes should be removed, as it makes the code more difficult to read. It's possible these occurred automatically from your IDE, but please remove any unnecessary changes to code alignment from this file.

</tr>
</thead>
<tbody>
@for (group of (groups$ | async)?.payload?.page; track group) {
Copy link
Member

Choose a reason for hiding this comment

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

All the changes in this file appear to be code realignment. We don't see where you've added the delete button to this page? Is there code missing?

You should remove all the alignment changes (i.e. undo all current changes to this file), and double check that the delete button has been added into this HTML.

* Deletes a given group from the Group list of the eperson currently being edited present in
* @param group group we want to delete as of which the current eperson being edited is member of
*/
deleteGroupFromMember(group: Group) {
Copy link
Member

Choose a reason for hiding this comment

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

This method is only being called in your spec file. I suspect it's supposed to be called by an actual delete button.

searchDone: boolean;

// Whether or not user has done a EPeople Member search yet
searchCurrentMembersDone: boolean;
Copy link
Member

Choose a reason for hiding this comment

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

This variable is never used. We believe it can be removed.


selectedReviewers: EPerson[] = [];

searchCurrentMembersForm: UntypedFormGroup;
Copy link
Member

Choose a reason for hiding this comment

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

Why did you add this form to the reviewers-list.component.ts? It doesn't appear to be used at all? Either it should be used or it should be removed.


"admin.access-control.epeople.form.table.remove": "Remove",

"admin.access-control.epeople.form.table.edit.buttons.removegroup": "Remove member from group \"{{name}}\"",
Copy link
Member

Choose a reason for hiding this comment

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

These two i18n keys are not used at this time. But, I suspect it is because there's code missing from your eperson-form.component.html file.

@PitbaranK
Copy link

PitbaranK commented Aug 19, 2025

Hi @tdonohue,
We have incorporated all the feedbacks against code review provided by you. Can you please update on the same?

@MarieVerdonck,
Can you please review the changes against #2869 and let us know will it fulfil the requirements?

@tdonohue tdonohue self-requested a review August 22, 2025 15:07
@github-actions
Copy link

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue
Copy link
Member

@iam-vir-harshit : This PR has a merge conflict because it looks like you've updated every *.json5 translation file in this PR. That's usually not the best practice because it will result in this PR having a merge conflict nearly every time someone adds new translations.

Instead, we recommend only updating the en.json5 file when adding new i18n keys. If you wanted to translate those keys immediately you could update them in one or two other *.json5 files. But, we have a process where we "re-sync" all other *.json5 files, so it's not necessary for you to do that re-sync in this PR...as it will make it more difficult for you to keep this PR free of merge conflicts.

@iam-vir-harshit
Copy link
Author

Reopening this PR with the recommended *.json5 translation file changes rollback except the en.json5 changes.

@iam-vir-harshit
Copy link
Author

@tdonohue,
As we can see, there are test case failures in run tests (18.x) are not related to our changes. Can you please re run the same from your side once?

@github-actions
Copy link

Hi @iam-vir-harshit,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue tdonohue moved this from ✅ Done to 👀 Under Review in DSpace 10.0 Release Nov 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

authorization related to authorization, permissions or groups new feature

Projects

Status: 👀 Under Review

Development

Successfully merging this pull request may close these issues.

Difficult to find users to delete from group in large groups

4 participants