fix: Overview route, add period selector back, prepare product CRUD routes
This commit is contained in:
@@ -327,6 +327,8 @@ function AppRoutes() {
|
|||||||
{/* Products */}
|
{/* Products */}
|
||||||
<Route path="/products" element={<ProductsIndex />} />
|
<Route path="/products" element={<ProductsIndex />} />
|
||||||
<Route path="/products/new" element={<ProductNew />} />
|
<Route path="/products/new" element={<ProductNew />} />
|
||||||
|
<Route path="/products/:id/edit" element={<ProductNew />} />
|
||||||
|
<Route path="/products/:id" element={<ProductNew />} />
|
||||||
<Route path="/products/categories" element={<ProductCategories />} />
|
<Route path="/products/categories" element={<ProductCategories />} />
|
||||||
<Route path="/products/tags" element={<ProductTags />} />
|
<Route path="/products/tags" element={<ProductTags />} />
|
||||||
<Route path="/products/attributes" element={<ProductAttributes />} />
|
<Route path="/products/attributes" element={<ProductAttributes />} />
|
||||||
|
|||||||
@@ -64,8 +64,19 @@ export default function DashboardSubmenuBar({ items = [], fullscreen = false }:
|
|||||||
})}
|
})}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Refresh & Dummy Toggle */}
|
{/* Period Selector, Refresh & Dummy Toggle */}
|
||||||
<div className="flex items-center gap-2 flex-shrink-0">
|
<div className="flex items-center gap-2 flex-shrink-0">
|
||||||
|
<Select value={period} disabled>
|
||||||
|
<SelectTrigger className="w-[140px] h-8">
|
||||||
|
<SelectValue />
|
||||||
|
</SelectTrigger>
|
||||||
|
<SelectContent>
|
||||||
|
<SelectItem value="7">{__('Last 7 days')}</SelectItem>
|
||||||
|
<SelectItem value="14">{__('Last 14 days')}</SelectItem>
|
||||||
|
<SelectItem value="30">{__('Last 30 days')}</SelectItem>
|
||||||
|
<SelectItem value="all">{__('All Time')}</SelectItem>
|
||||||
|
</SelectContent>
|
||||||
|
</Select>
|
||||||
{!useDummy && (
|
{!useDummy && (
|
||||||
<Button
|
<Button
|
||||||
variant="outline"
|
variant="outline"
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ function getStaticFallbackTree(): MainNode[] {
|
|||||||
path: '/',
|
path: '/',
|
||||||
icon: 'layout-dashboard',
|
icon: 'layout-dashboard',
|
||||||
children: [
|
children: [
|
||||||
{ label: 'Overview', mode: 'spa', path: '/dashboard', exact: true },
|
{ label: 'Overview', mode: 'spa', path: '/', exact: true },
|
||||||
{ label: 'Revenue', mode: 'spa', path: '/dashboard/revenue' },
|
{ label: 'Revenue', mode: 'spa', path: '/dashboard/revenue' },
|
||||||
{ label: 'Orders', mode: 'spa', path: '/dashboard/orders' },
|
{ label: 'Orders', mode: 'spa', path: '/dashboard/orders' },
|
||||||
{ label: 'Products', mode: 'spa', path: '/dashboard/products' },
|
{ label: 'Products', mode: 'spa', path: '/dashboard/products' },
|
||||||
|
|||||||
Reference in New Issue
Block a user