Spaces:
Running on CPU Upgrade
Running on CPU Upgrade
Update frontend/src/pages/Settings.jsx
Browse files- frontend/src/pages/Settings.jsx +15 -15
frontend/src/pages/Settings.jsx
CHANGED
|
@@ -604,21 +604,6 @@ export const AlertSettingsPage = () => {
|
|
| 604 |
}
|
| 605 |
};
|
| 606 |
|
| 607 |
-
if (loading) {
|
| 608 |
-
return (
|
| 609 |
-
<div className="flex items-center justify-center py-2xl font-label-md text-label-md text-on-surface-variant text-left">
|
| 610 |
-
<span className="material-symbols-outlined animate-spin mr-sm">sync</span>
|
| 611 |
-
Loading Settings...
|
| 612 |
-
</div>
|
| 613 |
-
);
|
| 614 |
-
}
|
| 615 |
-
|
| 616 |
-
// Pre-fill user profile info or fallback to Mercer placeholder
|
| 617 |
-
const profileName = user ? user.email.split('@')[0] : 'Alex';
|
| 618 |
-
const profileLastName = user ? 'User' : 'Mercer';
|
| 619 |
-
const profileEmail = user ? user.email : 'alex.mercer@larxiuswss.io';
|
| 620 |
-
const profileRole = user?.role ? `Role: ${user.role}` : 'Lead Security Engineer';
|
| 621 |
-
|
| 622 |
const isSchedulerAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin', 'soc_analyst'].includes(user?.role);
|
| 623 |
const isDemoBookingsAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin'].includes(user?.role);
|
| 624 |
const isNotificationsAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin', 'soc_analyst', 'executive_user'].includes(user?.role);
|
|
@@ -644,6 +629,21 @@ export const AlertSettingsPage = () => {
|
|
| 644 |
}
|
| 645 |
}, [user?.role, activeTab]);
|
| 646 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 647 |
return (
|
| 648 |
<div className="flex flex-col gap-gutter text-left w-full">
|
| 649 |
|
|
|
|
| 604 |
}
|
| 605 |
};
|
| 606 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 607 |
const isSchedulerAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin', 'soc_analyst'].includes(user?.role);
|
| 608 |
const isDemoBookingsAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin'].includes(user?.role);
|
| 609 |
const isNotificationsAllowed = ['super_admin', 'support_engineer', 'admin', 'org_admin', 'soc_analyst', 'executive_user'].includes(user?.role);
|
|
|
|
| 629 |
}
|
| 630 |
}, [user?.role, activeTab]);
|
| 631 |
|
| 632 |
+
if (loading) {
|
| 633 |
+
return (
|
| 634 |
+
<div className="flex items-center justify-center py-2xl font-label-md text-label-md text-on-surface-variant text-left">
|
| 635 |
+
<span className="material-symbols-outlined animate-spin mr-sm">sync</span>
|
| 636 |
+
Loading Settings...
|
| 637 |
+
</div>
|
| 638 |
+
);
|
| 639 |
+
}
|
| 640 |
+
|
| 641 |
+
// Pre-fill user profile info or fallback to Mercer placeholder
|
| 642 |
+
const profileName = user ? user.email.split('@')[0] : 'Alex';
|
| 643 |
+
const profileLastName = user ? 'User' : 'Mercer';
|
| 644 |
+
const profileEmail = user ? user.email : 'alex.mercer@larxiuswss.io';
|
| 645 |
+
const profileRole = user?.role ? `Role: ${user.role}` : 'Lead Security Engineer';
|
| 646 |
+
|
| 647 |
return (
|
| 648 |
<div className="flex flex-col gap-gutter text-left w-full">
|
| 649 |
|