Admin User v1
This commit is contained in:
53
frontend/src/pages/admin/AdminCatalogPage.tsx
Normal file
53
frontend/src/pages/admin/AdminCatalogPage.tsx
Normal file
@@ -0,0 +1,53 @@
|
||||
/**
|
||||
* @ai-summary Desktop admin page for vehicle catalog management
|
||||
* @ai-context CRUD operations for makes, models, years, trims, engines
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { Navigate } from 'react-router-dom';
|
||||
import { Box, Typography, CircularProgress } from '@mui/material';
|
||||
import { Card } from '../../shared-minimal/components/Card';
|
||||
import { useAdminAccess } from '../../core/auth/useAdminAccess';
|
||||
|
||||
export const AdminCatalogPage: React.FC = () => {
|
||||
const { isAdmin, loading } = useAdminAccess();
|
||||
|
||||
if (loading) {
|
||||
return (
|
||||
<Box sx={{ display: 'flex', justifyContent: 'center', alignItems: 'center', minHeight: '50vh' }}>
|
||||
<CircularProgress />
|
||||
</Box>
|
||||
);
|
||||
}
|
||||
|
||||
if (!isAdmin) {
|
||||
return <Navigate to="/garage/settings" replace />;
|
||||
}
|
||||
|
||||
return (
|
||||
<Box sx={{ py: 2 }}>
|
||||
<Typography variant="h4" sx={{ fontWeight: 700, color: 'text.primary', mb: 4 }}>
|
||||
Vehicle Catalog Management
|
||||
</Typography>
|
||||
|
||||
<Card>
|
||||
<Typography variant="h6" sx={{ fontWeight: 600, mb: 3 }}>
|
||||
Platform Catalog
|
||||
</Typography>
|
||||
<Typography variant="body2" color="text.secondary">
|
||||
Vehicle catalog management interface coming soon.
|
||||
</Typography>
|
||||
<Typography variant="body2" color="text.secondary" sx={{ mt: 2 }}>
|
||||
Features:
|
||||
</Typography>
|
||||
<ul>
|
||||
<li>Manage vehicle makes</li>
|
||||
<li>Manage vehicle models</li>
|
||||
<li>Manage model years</li>
|
||||
<li>Manage trims</li>
|
||||
<li>Manage engine specifications</li>
|
||||
</ul>
|
||||
</Card>
|
||||
</Box>
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user