Skip to content

feat: [UIE-9357] - IAM Delegation: Default Roles table#12990

Merged
mpolotsk-akamai merged 11 commits intolinode:developfrom
mpolotsk-akamai:UIE-9357-default-roles-table
Oct 29, 2025
Merged

feat: [UIE-9357] - IAM Delegation: Default Roles table#12990
mpolotsk-akamai merged 11 commits intolinode:developfrom
mpolotsk-akamai:UIE-9357-default-roles-table

Conversation

@mpolotsk-akamai
Copy link
Contributor

@mpolotsk-akamai mpolotsk-akamai commented Oct 15, 2025

Description 📝

This PR adds the Default Roles table for Default Access.

Changes 🔄

List any change(s) relevant to the reviewer.

  • Update AssignedRolesTable
  • Update Change/Unassign Role drawers

Scope 🚢

Upon production release, changes in this PR will be visible to:

  • All customers
  • Some customers (e.g. in Beta or Limited Availability)
  • No customers / Not applicable

Target release date 🗓️

11/04

Preview 📷

Screenshot 2025-10-23 at 11 19 34 AM
Screenshot 2025-10-23 at 11 20 02 AM
Screenshot 2025-10-23 at 11 21 02 AM

How to test 🧪

Prerequisites

(How to setup test environment)

  • IAM parent/child DevCloud account (IAM Delegation (Parent/Child) flag should be enabled)
  • use MSW CRUD mode

Verification steps

(How to verify changes)

  • go to /iam/roles/
  • click 'View default roles' button
  • go to 'Default Roles' tab
  • verify that table with default roles is visible
Author Checklists

As an Author, to speed up the review process, I considered 🤔

👀 Doing a self review
❔ Our contribution guidelines
🤏 Splitting feature into small PRs
➕ Adding a changeset
🧪 Providing/improving test coverage
🔐 Removing all sensitive information from the code and PR description
🚩 Using a feature flag to protect the release
👣 Providing comprehensive reproduction steps
📑 Providing or updating our documentation
🕛 Scheduling a pair reviewing session
📱 Providing mobile support
♿ Providing accessibility support


  • I have read and considered all applicable items listed above.

As an Author, before moving this PR from Draft to Open, I confirmed ✅

  • All tests and CI checks are passing
  • TypeScript compilation succeeded without errors
  • Code passes all linting rules

@mpolotsk-akamai mpolotsk-akamai self-assigned this Oct 15, 2025
@mpolotsk-akamai mpolotsk-akamai added the IAM Delegation Implementing the new Parent/Child delegation UI label Oct 21, 2025
@mpolotsk-akamai mpolotsk-akamai force-pushed the UIE-9357-default-roles-table branch from 1bb52a9 to f065ad2 Compare October 21, 2025 13:25
@mpolotsk-akamai mpolotsk-akamai force-pushed the UIE-9357-default-roles-table branch from f065ad2 to 87db233 Compare October 22, 2025 13:48
@mpolotsk-akamai mpolotsk-akamai marked this pull request as ready for review October 23, 2025 09:23
@mpolotsk-akamai mpolotsk-akamai requested a review from a team as a code owner October 23, 2025 09:25
Copy link
Contributor

@abailly-akamai abailly-akamai left a comment

Choose a reason for hiding this comment

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

UI looks good! and logic is mostly good and in sync with the entities tab.

Approving pending some cleanup and code quality improvements.

onClose={() => setIsUpdateEntitiesDrawerOpen(false)}
open={isUpdateEntitiesDrawerOpen}
role={selectedRole}
username={username}
Copy link
Contributor

Choose a reason for hiding this comment

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

same comment as above. This can all be cleaned up since the useIsDefaultDelegationRolesForChildAccount is used in all those modals

iamQueries.user(username)._ctx.roles.queryKey,
role,
);
if (username && enabled) {
Copy link
Contributor

Choose a reason for hiding this comment

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

@abailly-akamai , could you please check if that's what you mean? I haven't found anything similar to this in CM (might've missed something)

Copy link
Contributor

Choose a reason for hiding this comment

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

This works but I would simplify: (sorry the enabled suggestion was not appropriate/needed)

conditional queries/mutations are tricky to handle. usually we tend to render different components but I think this should suffice.

Maybe i am overthinking this and username ?? '' is fine but either way the challenge is to surface a proper error if that happens. Usually i try to prevent sending a mutation if we already know the payload isn't right. sending '' is just getting around the types which isn't ideal

export const useUserRolesMutation = (username: string | undefined) => {
  const queryClient = useQueryClient();

  return useMutation<IamUserRoles, APIError[], IamUserRoles>({
    mutationFn: (data) => {
      if (!username) {
        throw new Error('Username is required');
      }
      return updateUserRoles(username, data);
    },
    onSuccess: (role) => {
      if (username) {
        queryClient.setQueryData<IamUserRoles>(
          iamQueries.user(username)._ctx.roles.queryKey,
          role,
        );
      }
    },
  });
};

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated, thanks!

@mpolotsk-akamai mpolotsk-akamai force-pushed the UIE-9357-default-roles-table branch from 34e926d to d599b68 Compare October 29, 2025 11:38
@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🔺 3 failing tests on test run #12 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
3 Failing844 Passing12 Skipped41m 33s

Details

Failing Tests
SpecTest
clone-linode.spec.tsCloud Manager Cypress Tests→clone linode » can clone a Linode from Linode details page
create-firewall.spec.tsCloud Manager Cypress Tests→create firewall » "before all" hook for "creates a firewall without a linode"
timerange-verification.spec.tsCloud Manager Cypress Tests→Integration tests for verifying Cloudpulse custom and preset configurations » should implement and validate custom date/time picker for a specific date and time range

Troubleshooting

Use this command to re-run the failing tests:

pnpm cy:run -s "cypress/e2e/core/linodes/clone-linode.spec.ts,cypress/e2e/core/firewalls/create-firewall.spec.ts,cypress/e2e/core/cloudpulse/timerange-verification.spec.ts"

@github-project-automation github-project-automation bot moved this from Review to Approved in Cloud Manager Oct 29, 2025
@mpolotsk-akamai mpolotsk-akamai merged commit 767597e into linode:develop Oct 29, 2025
34 of 35 checks passed
@github-project-automation github-project-automation bot moved this from Approved to Merged in Cloud Manager Oct 29, 2025
corya-akamai added a commit to corya-akamai/manager that referenced this pull request Dec 8, 2025
Merge in FEE/cloud-manager from release/dev-sync-20251031d to dev

Squashed commit of the following:

commit c34d4069039fc4e11d92111855487833d59b0982
Merge: e10e817 72a3e63
Author: Conal Ryan <corya@akamai.coms>
Date:   Fri Oct 31 10:41:12 2025 -0400

    Merge branch 'develop' of github.com:linode/manager into release/dev-sync-20251031d

commit 72a3e63
Author: aaleksee-akamai <aaleksee@akamai.com>
Date:   Fri Oct 31 13:06:23 2025 +0100

    feat: [UIE-9154] - IAM: clean up nodebalancer permissions (linode#13017)

    * feat: [UIE-9154] - IAM: clean up nodebalancer permissions

    * changesets

    * update perm for nodebalancer_contributor

commit 7f451c9
Author: kagora-akamai <kagora@akamai.com>
Date:   Fri Oct 31 08:35:17 2025 +0100

    upcoming: [DPS-34191] - logs delivery pendo tags (linode#13022)

    * upcoming: [DPS-34191] - logs delivery pendo tags

    * Added changeset: Logs Delivery Stream/Destination Pendo tags

    * Change Edit Destination/Stream button to Save button

    * update e2e with Edit to Save change

commit 30c2181
Author: Hana Xu <115299789+hana-akamai@users.noreply.github.com>
Date:   Thu Oct 30 14:54:15 2025 -0400

    refactor: [UIE-9323] - Replace Formik with React Hook Form in DatabaseManageNetworkingDrawer (linode#13002)

    ## Description 📝

    Refactor Database Manage Networking drawer to use React Hook Form instead of Formik

    ## How to test 🧪

    ### Prerequisites

    (How to setup test environment)

    - Have the Database VPC feature flag enabled

    ### Verification steps

    (How to verify changes)

    - [ ] Go to the details page of a Database and click on the Networking tab, then click on Manage Networking to open the drawer
    - [ ] Test adding/removing a VPC, error messages, etc
    - [ ] There should be no regressions compared to prod

commit 4f4e91d
Author: Alban Bailly <130582365+abailly-akamai@users.noreply.github.com>
Date:   Thu Oct 30 17:55:46 2025 +0100

    fix: [UIE-9484] - Enhance `enabled` checks for queries ran within `useQueryWithPermissions` (linode#13039)

commit 0de8842
Author: Jaalah Ramos <125309814+jaalah-akamai@users.noreply.github.com>
Date:   Thu Oct 30 12:39:16 2025 -0400

    fix: [M3-10691] - Upcoming maintenance “When” shows time until maintenance; derive start when absent (linode#13020)

    * change: [M3-10691] - Upcoming maintenance “When” shows time until maintenance; derive start when absent

    * Add changeset

    * Change changeset

    * Fix double display of banners for a single linode

    * Mock maintenance policies for MSW to ensure proper  time

    * Update broken cypress tests due to banner display changes

    * revert PlatformMaintenanceBanner.tsx changes

    * Update unit test

    ---------

    Co-authored-by: Jaalah Ramos <jaalah.ramos@gmail.com>

commit 356fc4e
Author: santoshp210-akamai <159890961+santoshp210-akamai@users.noreply.github.com>
Date:   Thu Oct 30 13:27:13 2025 +0530

    upcoming: [DI-27663]: Resetting stale dimension filter values from the from (linode#13018)

    * upcoming: [DI-27663] - Hook to remove invalidate dimension filter values from form

    * renaming the hook

    * removed unnecessary comment

    * add changesets

    * upcmong: [DI-27663] - Added unit tests to the cleanup hook

    * fix tense in changeset

commit 40219ce
Author: Ankita <ankitaan@akamai.com>
Date:   Thu Oct 30 01:18:46 2025 +0530

    upcoming: [DI-27803] - Add new optional NodeBalancers filter in Nodebalancer-Firewall dashboard (linode#13029)

    * [DI-27803] - Add new optional nodebalancers filter in nodebalancer firewall dashboard

    * [DI-27803] - update as latest aclp dev

    * upcoming: [DI-27803] - cleanup

    * upcoming: [DI-27803] - more cleanup

    * upcoming: [DI-27803] - Pr comments

    * upcoming: [DI-27803] - Pass order by

    * upcoming: [DI-27803] - Minor cleanup

    * upcoming: [DI-27803] - Add temporary integration in firewalls page for reviewer

    * upcoming: [DI-27803] - Add changeset

    * upcoming: [DI-27803] - use existing style const

    * upcoming: [DI-27803] - Remove temporary integration in service page

commit 3de19a3
Author: smans-akamai <smans@akamai.com>
Date:   Wed Oct 29 15:32:06 2025 -0400

    chore: [UIE-8745] - Add missing changeset for Table and Paginator web component integration in DBaaS (linode#13035)

    * chore: [UIE-8745] - Add missing changeset for Table and Paginator web component integration in DBaaS

    * Adding actual changeset file pointing to previous PR with missing changeset

commit 756ab86
Author: Jaalah Ramos <125309814+jaalah-akamai@users.noreply.github.com>
Date:   Wed Oct 29 15:02:04 2025 -0400

    fix: [M3-10688] - Add ability to enter migration queue (linode#13024)

    * hotfix: [M3-10688] - Add ability to enter migration queue

    * Bump version and changelog

    * Revert hotfix changes and add changeset

    * Add feature flag

    ---------

    Co-authored-by: Jaalah Ramos <jaalah.ramos@gmail.com>

commit df33614
Author: Purvesh Makode <pmakode@akamai.com>
Date:   Wed Oct 29 19:56:11 2025 +0530

    fix: [M3-10689] -  MTC supported regions ids for MTC Linode Migrations (linode#13026)

    * Fix invalid oslo region id and update MTC_SUPPORTED_REGIONS

    * Add regions mock data for us-iad-2

    * Update comment

    * Added changeset: Update `MTC_SUPPORTED_REGIONS` to include valid region IDs (`no-osl-1`, `us-iad`, `us-iad-2`) and replaced invalid `no-east`

    * Extend mtc2025 feature flag to support mtc supported regions

    * Revert the last commit to keep this branch in the working state

    This reverts commit c180d98.

    * Add new flag and extend it to support MTC regions

commit 67ff37f
Author: mpolotsk-akamai <157619599+mpolotsk-akamai@users.noreply.github.com>
Date:   Wed Oct 29 14:25:32 2025 +0100

    fix: [UIE-9267] - IAM: VPC assign linode permission fix (linode#13030)

    * fix: [UIE-9267] - IAM: VPC assign linode permission fix

    * Added changeset: IAM: Linodes without required permissions visible and selectable in Assign/Unassign Linodes selector

    * fix: [UIE-9267] - IAM: unit test fix

    * fix: [UIE-9267] - IAM: refactoring

commit 767597e
Author: mpolotsk-akamai <157619599+mpolotsk-akamai@users.noreply.github.com>
Date:   Wed Oct 29 13:42:51 2025 +0100

    feat: [UIE-9357] - IAM Delegation: Default Roles table (linode#12990)

    * feat: [UIE-9357] - IAM Delegation: Default Roles Table

    * feat: [UIE-9357] - IAM Delegation: unit test

    * feat: [UIE-9357] - IAM Delegation: refactoring

    * feat: [UIE-9357] - rebase

    * feat: [UIE-9357] - remove useAssignedRoles hook since it's no longer needed

    * Added changeset: IAM: Default Roles Table

    * feat: [UIE-9357] - review fix

    * feat: [UIE-9357] - test fix

    * feat: [UIE-9357] - review fix

    * feat: [UIE-9357] - mock data fix, view entities url fix

    * feat: [UIE-9357] - refactor

    ---------

    Co-authored-by: Alban Bailly <abailly@akamai.com>

commit 02d7050
Author: Ankita <ankitaan@akamai.com>
Date:   Wed Oct 29 11:16:16 2025 +0530

    upcoming: [DI-27803] -  Introduce style constant for hiding scroll bar for filters (linode#13028)

    * upcoming: [DI-27803] - Introduce style constant for hiding scroll bar

    * upcoming: [DI-27803] - Remove loading constraint from options

    * upcoming: [DI-27803] - Update prop name

    * upcoming: [DI-27803] - Add changeset

commit f7b9ff7
Author: smans-akamai <smans@akamai.com>
Date:   Tue Oct 28 16:10:16 2025 -0400

    change: [UIE-9447] - DBaaS - Remove legacy backend calls (linode#13015)

    * change: [UIE-9447] - DBaaS - Remove legacy backend calls and clean up unused logic

    * Fixing databases utilities tests

    * try mocking types

    * try increasing timeout

    * Adding changesets

    * Updating changeset comment and create-database.spec mockDatabase platform

    * Removing changeset and updating PR to refactor

    * Adding back changeset

    ---------

    Co-authored-by: Hana Xu <hxu@akamai.com>

commit 49c6491
Author: Alban Bailly <130582365+abailly-akamai@users.noreply.github.com>
Date:   Tue Oct 28 17:29:35 2025 +0100

    fix: [UIE-9435] - IAM - Ensure useEntitiesPermissions does not run for admin users (linode#13012)

    * get rid of fetch loop

    * test fix

    * loading states

    * fix redundant call

    * more loading states

    * only for admins then

    * simple fix for admins

    * comment

    * Added changeset: IAM - Ensure useEntitiesPermissions does not run for admin users

commit 5e60908
Merge: c1cff6d 6fde11f
Author: Banks Nussman <bnussman@akamai.com>
Date:   Tue Oct 28 12:14:26 2025 -0400

    Merge branch 'master' into develop

commit 6fde11f
Merge: a79aaf8 ae97be6
Author: Banks Nussman <115251059+bnussman-akamai@users.noreply.github.com>
Date:   Tue Oct 28 12:12:44 2025 -0400

    Release v1.153.2 - staging → master (linode#13021)

    * hotfix: [M3-10688] - Add ability to enter migration queue (linode#13016)

    * hotfix: [M3-10688] - Add ability to enter migration queue

    * Bump version and changelog

    ---------

    Co-authored-by: Jaalah Ramos <jaalah.ramos@gmail.com>

    * hotfix: [UIE-9467] - Update Linode invoice US address (linode#13019)

    * Linode invoice US address update

    * Update changelog

    ---------

    Co-authored-by: Banks Nussman <bnussman@akamai.com>

    * Revert "hotfix: [M3-10688] - Add ability to enter migration queue" (linode#13023)

    * Revert "hotfix: [M3-10688] - Add ability to enter migration queue (linode#13016)"

    This reverts commit 8a7101e.

    * version bump

    * Update packages/manager/CHANGELOG.md

    Co-authored-by: Dajahi Wiley <114682940+dwiley-akamai@users.noreply.github.com>

    ---------

    Co-authored-by: Jaalah Ramos <125309814+jaalah-akamai@users.noreply.github.com>
    Co-authored-by: Jaalah Ramos <jaalah.ramos@gmail.com>
    Co-authored-by: Purvesh Makode <pmakode@akamai.com>
    Co-authored-by: Dajahi Wiley <114682940+dwiley-akamai@users.noreply.github.com>

commit c1cff6d
Author: Ankita <ankitaan@akamai.com>
Date:   Tue Oct 28 21:10:39 2025 +0530

    upcoming: [DI-27803] - Firewall-Nodebalancer dashboard enhancements - filtering of firewalls & single select firewall filter (linode#13014)

    * add filtering for firewalls

    * update comments

    * upcoming: [DI-27803] - Update util

    * upcoming: [DI-27803] - Update comments

    * upcoming: [DI-27803] - Update util and comments

    * upcoming: [DI-27803] - Update custom-select, config, utils

    * upcoming: [DI-27803] - Remove type error

    * upcoming: [DI-27803] - Update comments

    * upcoming: [DI-27803] - Improve consistency

    * [DI-27803] - fix linode interface filtering bug

    * upcoming: [DI-27803] - Add changeset

    * upcoming: [DI-27803] - Avoid type casting, convert to string array

    ---------

    Co-authored-by: Nikhil Agrawal <165884194+nikhagra-akamai@users.noreply.github.com>

commit ae97be6
Author: Banks Nussman <115251059+bnussman-akamai@users.noreply.github.com>
Date:   Tue Oct 28 11:11:20 2025 -0400

    Update packages/manager/CHANGELOG.md

    Co-authored-by: Dajahi Wiley <114682940+dwiley-akamai@users.noreply.github.com>

... and 58 more commits
shagufa-akamai pushed a commit to shagufa-akamai/manager that referenced this pull request Dec 11, 2025
* feat: [UIE-9357] - IAM Delegation: Default Roles Table

* feat: [UIE-9357] - IAM Delegation: unit test

* feat: [UIE-9357] - IAM Delegation: refactoring

* feat: [UIE-9357] - rebase

* feat: [UIE-9357] - remove useAssignedRoles hook since it's no longer needed

* Added changeset: IAM: Default Roles Table

* feat: [UIE-9357] - review fix

* feat: [UIE-9357] - test fix

* feat: [UIE-9357] - review fix

* feat: [UIE-9357] - mock data fix, view entities url fix

* feat: [UIE-9357] - refactor

---------

Co-authored-by: Alban Bailly <abailly@akamai.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

IAM Delegation Implementing the new Parent/Child delegation UI

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants