From 1d70446cc488110ae8c8d2302a108d9d5bcc74ea Mon Sep 17 00:00:00 2001 From: gitlawr Date: Wed, 27 May 2026 16:13:22 +0800 Subject: [PATCH] fix(routes): let Org owners see Storage Types menu MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The route was gated on ``canSeeAdmin`` so only platform admins ever saw Storage Types in the sidebar. But the backend route (``gpu_instance_persistent_volume_types``) is tenant-scoped — Org owners can create / list their own — so hiding the menu from them left an admin-defined feature reachable only by URL. Relax to ``canSeeOrgAdmin`` to match. OSS keeps the platform-admin-only behaviour (predicate defaults to ``isPlatformAdmin``); the enterprise access extension widens it to the current-org owner. --- config/routes.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/config/routes.ts b/config/routes.ts index 04041c38..0fb459aa 100644 --- a/config/routes.ts +++ b/config/routes.ts @@ -224,7 +224,12 @@ const baseRoutes = [ path: '/gpu-service/storage-types', key: 'gpuServiceStorageTypes', icon: 'icon-storage-outlined', - access: 'canSeeAdmin', + // Storage types are tenant-scoped on the backend (Org owners + // can create/list their own), so the menu shouldn't be + // platform-admin-only. ``canSeeOrgAdmin`` keeps the gate at + // "admin or current-org owner" — Org members still don't see + // it, which matches the read/write model in the route. + access: 'canSeeOrgAdmin', selectedIcon: 'icon-storage-filled', defaultIcon: 'icon-storage-outlined', component: './gpu-service/storage-types'