From 0789b7e550d99731ac1413da5ef54b3e0865d446 Mon Sep 17 00:00:00 2001 From: fahed Date: Thu, 5 Mar 2026 15:38:11 +0300 Subject: [PATCH] fix: superadmin can edit own brands and modules in team panel Brands and modules fields were hidden/disabled when editing self. Superadmins now see editable brands dropdown and modules toggles. Co-Authored-By: Claude Opus 4.6 --- client/src/components/TeamMemberPanel.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/components/TeamMemberPanel.jsx b/client/src/components/TeamMemberPanel.jsx index f7942e6..a0a4baf 100644 --- a/client/src/components/TeamMemberPanel.jsx +++ b/client/src/components/TeamMemberPanel.jsx @@ -249,7 +249,7 @@ export default function TeamMemberPanel({ member, isEditingSelf, onClose, onSave
- {isEditingSelf ? ( + {isEditingSelf && userRole !== 'superadmin' ? (
{(form.brands || []).length === 0 ? '—' : (form.brands || []).join(', ')}
@@ -317,7 +317,7 @@ export default function TeamMemberPanel({ member, isEditingSelf, onClose, onSave
{/* Modules toggle */} - {!isEditingSelf && canManageTeam && ( + {(!isEditingSelf || userRole === 'superadmin') && canManageTeam && (