Refactor default and custom roles GraphQL queries
What does this MR do and why?
In the app, we have default roles (also called standard roles) and custom roles (also called member roles). Default roles are the built-in ones like Guest, Reporter, Developer, etc. Custom roles are created by the user. We need to fetch these roles through GraphQL so that they can be shown on the Settings
-> Roles and permissions
page:
In a previous MR, we made some changes to the backend that lets us clean up the frontend GraphQL queries. This MR does the cleanup:
-
Combined
standard_roles.fragment.graphql
andmember_role.fragment.graphql
into a singlerole.fragment.graphql
. -
Renamed
group_member_roles.query.graphql
andinstance_member_roles.query.graphql
togroup_roles.query.graphql
andinstance_roles.query.graphql
. The queries fetch both default roles and custom roles. -
Renamed
CustomRolesApp
toRolesApp
because it shows both default roles and custom roles, not just custom roles.
How to set up and validate locally
This is a refactor, so we just need to confirm that the current functionality still works. For self-managed, follow the repro steps in this video:
For SaaS, first run these shell commands:
export GITLAB_SIMULATE_SAAS=1
gdk restart
Then follow the repro steps in this video:
Related to #468398