Skip to content

Update approvers dropdown to use new endpoint

Samantha Ming requested to merge approvers-use-new-project-api-fe into master

Issue: #28902 (closed)

What does this MR do?

This MR doesn't change any of the existing UI/UX. The only thing done here is updating it to use the new /projects/:id/groups (BE MR: !53642 (merged))

new-api-endpoint

So now, it will just return the groups that the project belongs to.

(For more info on how the logic in determining the groups, you can see a detailed break down here > #28902 (comment 502684120))

Testing Case

In order to see the groups, we need to create a group and then a project.

  1. Create a new group
  2. Create a project belonging to that group
  • The group that this project belongs to will appear:

image

This project belongs to a group named Public Project Group

  • If a project doesn't belong to a group, no groups will appear:

image

This project does not belong to a group, it belongs to the user Administrator

  • If a group has been selected, it will not reappear in the dropdown (similar to the current/previous behaviour):

skip_groups

Screenshots (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by Samantha Ming

Merge request reports