421 lines
11 KiB
TypeScript
421 lines
11 KiB
TypeScript
import {
|
|
IconHome,
|
|
IconAlertTriangle,
|
|
IconSettings,
|
|
IconMap,
|
|
IconDatabase,
|
|
IconUsers,
|
|
IconMessageCircle,
|
|
IconMenu2,
|
|
IconAlbum,
|
|
IconMusicBolt,
|
|
IconCommand,
|
|
IconFrame,
|
|
IconChartPie,
|
|
IconRobot,
|
|
IconSearch,
|
|
IconDashboard,
|
|
IconRobotFace,
|
|
IconGavel,
|
|
IconMapPin2,
|
|
IconSlice,
|
|
IconWorldBolt,
|
|
IconWorld,
|
|
IconPin,
|
|
IconMapPin,
|
|
IconLayersDifference,
|
|
IconFriends,
|
|
IconDna,
|
|
IconDna2,
|
|
IconUsersGroup,
|
|
IconNavigation,
|
|
IconApps,
|
|
IconUserCheck,
|
|
IconShield,
|
|
IconShieldCheck,
|
|
IconActivity,
|
|
IconTarget,
|
|
IconPlaylistAdd,
|
|
IconUserCircle,
|
|
IconHistory,
|
|
IconBuilding,
|
|
IconStar,
|
|
IconKey,
|
|
IconLock,
|
|
IconShieldLock,
|
|
IconUser,
|
|
IconUserShield,
|
|
IconFile,
|
|
IconFileText,
|
|
IconClipboardList,
|
|
IconClock,
|
|
IconEye,
|
|
IconRadar,
|
|
IconRoute,
|
|
IconMapPins,
|
|
IconLocation,
|
|
IconMap2,
|
|
IconPolygon,
|
|
IconCalendar
|
|
} from '@tabler/icons-react';
|
|
import { ROUTES } from '@/constants/routes';
|
|
|
|
// Accept user as a parameter
|
|
export function getNavData(user: {
|
|
id: string;
|
|
name: string;
|
|
email: string;
|
|
avatar: string;
|
|
}) {
|
|
return {
|
|
user,
|
|
teams: [
|
|
{
|
|
id: 'team-1',
|
|
name: 'Polres Jember',
|
|
icon: IconShield,
|
|
plan: 'Enterprise'
|
|
}
|
|
// {
|
|
// id: "team-2",
|
|
// name: "Polsek Area",
|
|
// icon: IconShieldCheck,
|
|
// plan: "Regional",
|
|
// },
|
|
// {
|
|
// id: "team-3",
|
|
// name: "Polsek ",
|
|
// icon: IconUserCheck,
|
|
// plan: "Local",
|
|
// },
|
|
],
|
|
NavPreMain: [
|
|
{
|
|
id: 'nav-pre-1',
|
|
title: 'Welcome',
|
|
url: '/dashboard/welcome',
|
|
icon: IconHome,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-pre-2',
|
|
title: 'Quick Search',
|
|
url: '/search',
|
|
icon: IconSearch,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-pre-3',
|
|
title: 'Sigap AI',
|
|
url: '/dashboard/sigap-ai',
|
|
icon: IconRobotFace,
|
|
isActive: true,
|
|
subItems: []
|
|
}
|
|
],
|
|
navMain: [
|
|
{
|
|
id: 'nav-main-1',
|
|
title: 'Dashboard Overview',
|
|
url: ROUTES.DASHBOARD,
|
|
slug: 'dashboard-overview',
|
|
orderSeq: 1,
|
|
icon: IconApps,
|
|
isActive: true,
|
|
description: 'Key metrics and system overview',
|
|
badge: 'kpi',
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-main-2',
|
|
title: 'User Management',
|
|
url: '/dashboard/user-management',
|
|
slug: 'user-management',
|
|
orderSeq: 2,
|
|
icon: IconUsers,
|
|
isActive: true,
|
|
description: 'Manage users, roles and permissions',
|
|
badge: 'users',
|
|
subItems: [
|
|
{
|
|
id: 'nav-main-2-1',
|
|
title: 'Citizens',
|
|
url: '/dashboard/user-management/citizens',
|
|
slug: 'citizens',
|
|
icon: IconUser,
|
|
orderSeq: 1,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-main-2-2',
|
|
title: 'Officers',
|
|
url: '/dashboard/user-management/officers',
|
|
slug: 'officers',
|
|
icon: IconUserShield,
|
|
orderSeq: 2,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-main-2-3',
|
|
title: 'Permissions',
|
|
url: '/dashboard/user-management/roles',
|
|
slug: 'roles-permissions',
|
|
icon: IconLock,
|
|
orderSeq: 3,
|
|
isActive: true,
|
|
subSubItems: [
|
|
{
|
|
id: 'nav-main-2-3-1',
|
|
title: 'Role Definition',
|
|
url: '/dashboard/user-management/roles/definition',
|
|
slug: 'role-definition',
|
|
icon: IconKey,
|
|
orderSeq: 1,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-2-3-2',
|
|
title: 'Permission Matrix',
|
|
url: '/dashboard/user-management/roles/permissions',
|
|
slug: 'permission-matrix',
|
|
icon: IconShieldLock,
|
|
orderSeq: 2,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-2-3-3',
|
|
title: 'Access Control',
|
|
url: '/dashboard/user-management/roles/access-control',
|
|
slug: 'access-control',
|
|
icon: IconShieldCheck,
|
|
orderSeq: 3,
|
|
isActive: true
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
id: 'nav-main-3',
|
|
title: 'Crime Management',
|
|
url: '/dashboard/crime-management',
|
|
slug: 'crime-management',
|
|
orderSeq: 3,
|
|
icon: IconGavel,
|
|
isActive: true,
|
|
subItems: [
|
|
{
|
|
id: 'nav-main-3-1',
|
|
title: 'Crime Overview',
|
|
url: '/dashboard/crime-management/overview',
|
|
slug: 'crime-overview',
|
|
icon: IconMapPin2,
|
|
orderSeq: 1,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-main-3-2',
|
|
title: 'Incident Reports',
|
|
url: '/dashboard/crime-management/reports',
|
|
slug: 'incident-reports',
|
|
icon: IconFileText,
|
|
orderSeq: 2,
|
|
isActive: true,
|
|
subSubItems: [
|
|
{
|
|
id: 'nav-main-3-2-1',
|
|
title: 'Cases',
|
|
url: '/dashboard/crime-management/reports/cases',
|
|
slug: 'cases',
|
|
icon: IconClipboardList,
|
|
orderSeq: 1,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-3-2-2',
|
|
title: 'Evidence',
|
|
url: '/dashboard/crime-management/reports/evidence',
|
|
slug: 'evidences',
|
|
icon: IconDatabase,
|
|
orderSeq: 2,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-3-2-3',
|
|
title: 'Witnesses',
|
|
url: '/dashboard/crime-management/reports/witnesses',
|
|
slug: 'witnesses',
|
|
icon: IconEye,
|
|
orderSeq: 3,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-3-2-4',
|
|
title: 'Timelines',
|
|
url: '/dashboard/crime-management/reports/timeline',
|
|
slug: 'timeline',
|
|
icon: IconClock,
|
|
orderSeq: 4,
|
|
isActive: true
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
id: 'nav-main-4',
|
|
title: 'Geographic Management',
|
|
url: '/dashboard/geographics',
|
|
slug: 'geographic-management',
|
|
orderSeq: 4,
|
|
icon: IconWorld,
|
|
isActive: true,
|
|
description: 'Manage locations and geographic data',
|
|
badge: 'geo',
|
|
subItems: [
|
|
{
|
|
id: 'nav-main-4-1',
|
|
title: 'Location Management',
|
|
url: '/dashboard/geographic/locations',
|
|
slug: 'location-management',
|
|
icon: IconMapPin,
|
|
orderSeq: 1,
|
|
isActive: true,
|
|
subItems: [
|
|
{
|
|
id: 'nav-main-4-1-1',
|
|
title: 'Cities',
|
|
url: '/dashboard/geographic/locations/cities',
|
|
slug: 'cities',
|
|
icon: IconBuilding,
|
|
orderSeq: 1,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-4-1-2',
|
|
title: 'Districts',
|
|
url: '/dashboard/geographic/locations/districts',
|
|
slug: 'districts',
|
|
icon: IconMap2,
|
|
orderSeq: 2,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-4-1-3',
|
|
title: 'Coordinates & Mapping',
|
|
url: '/dashboard/geographic/locations/coordinates',
|
|
slug: 'coordinates',
|
|
icon: IconLocation,
|
|
orderSeq: 3,
|
|
isActive: true
|
|
}
|
|
]
|
|
},
|
|
{
|
|
id: 'nav-main-4-2',
|
|
title: 'Unit Deployment',
|
|
url: '/dashboard/geographic/units',
|
|
slug: 'unit-deployment',
|
|
icon: IconBuilding,
|
|
orderSeq: 2,
|
|
isActive: true,
|
|
subSubItems: [
|
|
{
|
|
id: 'nav-main-4-2-1',
|
|
title: 'Police Units',
|
|
url: '/dashboard/geographic/units/police-units',
|
|
slug: 'police-units',
|
|
icon: IconShield,
|
|
orderSeq: 1,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-4-2-2',
|
|
title: 'Patrol Assignment',
|
|
url: '/dashboard/geographic/units/patrol-assignment',
|
|
slug: 'patrol-assignment',
|
|
icon: IconRoute,
|
|
orderSeq: 2,
|
|
isActive: true
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
id: 'nav-main-5',
|
|
title: 'Demographics',
|
|
url: '/dashboard/demographics',
|
|
slug: 'demographics',
|
|
orderSeq: 5,
|
|
icon: IconFriends,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'nav-main-6 ',
|
|
title: 'Operations',
|
|
url: '/dashboard/systems',
|
|
slug: 'operations-monitoring',
|
|
orderSeq: 5,
|
|
icon: IconRadar,
|
|
isActive: true,
|
|
description: 'Monitor operations and patrol activities',
|
|
badge: 'ops',
|
|
subItems: [
|
|
{
|
|
id: 'nav-main-6-1',
|
|
title: 'Sessions',
|
|
url: '/dashboard/systems/sessions',
|
|
slug: 'active-sessions',
|
|
icon: IconActivity,
|
|
orderSeq: 1,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-6-2',
|
|
title: 'Events',
|
|
url: '/dashboard/systems/sessions/events',
|
|
slug: 'event-management',
|
|
icon: IconCalendar,
|
|
orderSeq: 2,
|
|
isActive: true
|
|
},
|
|
{
|
|
id: 'nav-main-6-3',
|
|
title: 'Resources',
|
|
url: '/dashboard/systems/sessions/resources',
|
|
slug: 'resource-allocation',
|
|
icon: IconTarget,
|
|
orderSeq: 3,
|
|
isActive: true
|
|
}
|
|
]
|
|
}
|
|
],
|
|
reports: [
|
|
{
|
|
id: 'report-1',
|
|
name: 'Crime Reports',
|
|
url: '/dashboard/reports/crime-reports',
|
|
icon: IconFrame,
|
|
isActive: true,
|
|
subItems: []
|
|
},
|
|
{
|
|
id: 'report-2',
|
|
name: 'Demographics Reports',
|
|
url: '/dashboard/reports/demographics-reports',
|
|
icon: IconChartPie,
|
|
isActive: true,
|
|
subItems: []
|
|
}
|
|
]
|
|
};
|
|
}
|