Add client dashboard page, restore MyCompany to people+edit only

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Krao Hasanee
2026-03-27 00:52:52 -04:00
parent aeaf6558ac
commit 2c4f42ea55
6 changed files with 180 additions and 77 deletions
+1
View File
@@ -25,6 +25,7 @@ function ClientNav({ onNav }) {
<div className="sidebar-section">
<div className="sidebar-section-label">My Work</div>
{[
{ to: '/my-dashboard', label: 'Dashboard' },
{ to: '/my-projects', label: 'Projects' },
{ to: '/my-invoices', label: 'Invoices' },
{ to: '/my-company', label: 'Company' },
+1 -1
View File
@@ -5,7 +5,7 @@ export default function ProtectedRoute({ children, role }) {
const { currentUser } = useAuth();
if (!currentUser) return <Navigate to="/" replace />;
if (role && currentUser.role !== role) {
return <Navigate to={currentUser.role === 'team' ? '/dashboard' : '/my-requests'} replace />;
return <Navigate to={currentUser.role === 'team' ? '/dashboard' : '/my-dashboard'} replace />;
}
return children;
}