feat(platform): add vehicle data management console

This commit is contained in:
lingniu
2026-07-03 20:55:54 +08:00
parent 0d8916df47
commit 859bc3e9ee
45 changed files with 6837 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
import { useState } from 'react';
import { AppShell, type PageKey } from './layout/AppShell';
import { Dashboard } from './pages/Dashboard';
import { History } from './pages/History';
import { Mileage } from './pages/Mileage';
import { Quality } from './pages/Quality';
import { Realtime } from './pages/Realtime';
import { VehicleDetail } from './pages/VehicleDetail';
import { Vehicles } from './pages/Vehicles';
const pages: Record<PageKey, JSX.Element> = {
dashboard: <Dashboard />,
vehicles: <Vehicles />,
realtime: <Realtime />,
detail: <VehicleDetail />,
history: <History />,
mileage: <Mileage />,
quality: <Quality />
};
export default function App() {
const [activePage, setActivePage] = useState<PageKey>('dashboard');
return (
<AppShell activePage={activePage} onChange={setActivePage}>
{pages[activePage]}
</AppShell>
);
}