Skip to content

Commit

Permalink
feat: add new url from role groups (#3178)
Browse files Browse the repository at this point in the history
  • Loading branch information
novakzaballa committed Dec 20, 2023
1 parent 353d077 commit eebc541
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions api/organisations/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@
RoleEnvironmentPermissionsViewSet,
RoleOrganisationPermissionViewSet,
RoleProjectPermissionsViewSet,
RolesByGroupViewSet,
RolesByUserViewSet,
RoleViewSet,
UserRoleViewSet,
Expand All @@ -111,6 +112,10 @@
parent_router=organisations_router, parent_prefix=r"users", lookup="user"
)

nested_group_roles_routes = routers.NestedSimpleRouter(
parent_router=organisations_router, parent_prefix=r"groups", lookup="group"
)

organisations_router.register("roles", RoleViewSet, basename="organisation-roles")
nested_roles_router = routers.NestedSimpleRouter(
organisations_router, r"roles", lookup="role"
Expand All @@ -120,6 +125,11 @@
viewset=RolesByUserViewSet,
basename="role-users",
)
nested_group_roles_routes.register(
prefix="roles",
viewset=RolesByGroupViewSet,
basename="role-groups",
)
nested_roles_router.register(
"environments-permissions",
RoleEnvironmentPermissionsViewSet,
Expand All @@ -145,5 +155,6 @@
url(r"^", include(organisations_router.urls)),
url(r"^", include(nested_roles_router.urls)),
url(r"^", include(nested_user_roles_routes.urls)),
url(r"^", include(nested_group_roles_routes.urls)),
]
)

3 comments on commit eebc541

@vercel
Copy link

@vercel vercel bot commented on eebc541 Dec 20, 2023

Choose a reason for hiding this comment

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

@vercel
Copy link

@vercel vercel bot commented on eebc541 Dec 20, 2023

Choose a reason for hiding this comment

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

@vercel
Copy link

@vercel vercel bot commented on eebc541 Dec 20, 2023

Choose a reason for hiding this comment

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

Successfully deployed to the following URLs:

docs – ./docs

docs.flagsmith.com
docs-git-main-flagsmith.vercel.app
docs-flagsmith.vercel.app
docs.bullet-train.io

Please sign in to comment.