const ROLE_PERMISSIONS = { super_admin: [ "tenant.view", "tenant.manage", "tenant.status", "billing.view", "billing.manage", "analytics.view", "settings.manage", "system.manage", "location.view", "location.history.view", "location.settings.manage" ], admin: [ "employee.view", "employee.manage", "attendance.view", "attendance.manage", "payroll.view", "payroll.manage", "leave.view", "leave.manage", "advance.view", "advance.manage", "reports.view", "reports.export", "settings.manage", "scheduling.view", "scheduling.manage", "location.view", "location.history.view", "location.settings.manage" ], hr: [ "employee.view", "employee.manage", "attendance.view", "attendance.manage", "payroll.view", "payroll.manage", "leave.view", "leave.manage", "advance.view", "reports.view", "reports.export", "scheduling.view", "scheduling.manage", "location.view", "location.history.view" ], manager: [ "employee.view", "attendance.view", "attendance.manage", "leave.view", "leave.manage", "advance.view", "reports.view", "scheduling.view", "scheduling.manage" ], staff: [ "self.attendance", "self.profile", "self.leave", "self.advance" ] }; const ADMIN_ROUTES = [ { id: "dashboard", path: "/admin/dashboard", reactKey: null, label: "Dashboard", title: "Enterprise Command Center", containerId: "custom-enterprise-dashboard", renderFnName: "renderEnterpriseDashboardView", permission: null, sidebarGroup: "core", svg: `` }, { id: "attendance", path: "/admin/attendance", reactKey: null, label: "Attendance Control", title: "Attendance Control", containerId: "custom-attendance-control", renderFnName: "renderAttendanceControlView", permission: "attendance.view", featureFlag: "module_attendance_enabled", sidebarGroup: "core", svg: `` }, { id: "face-registrations", path: "/admin/face-registrations", reactKey: null, label: "Face Registrations", title: "Face Registrations", containerId: "custom-face-registration", renderFnName: "renderFaceRegistrationView", permission: "attendance.manage", featureFlag: "module_attendance_enabled", sidebarGroup: "core", svg: `` }, { id: "live-location", path: "/admin/live-location", reactKey: null, label: "Live Staff Location", title: "Live Staff Location", containerId: "custom-live-location", renderFnName: "renderLiveLocationView", permission: "location.view", featureFlag: "module_location_enabled", sidebarGroup: "core", svg: `` }, { id: "employees", path: "/admin/employees", reactKey: "employees", label: "Employee Management", title: "Employee Management", permission: "employee.view", featureFlag: "module_employee_enabled", sidebarGroup: "core", svg: `` }, { id: "leaves", path: "/admin/leaves", reactKey: "leave", label: "Leave Requests", title: "Leave Requests", permission: "leave.view", featureFlag: "module_leave_enabled", sidebarGroup: "core", svg: `` }, { id: "tasks", path: "/admin/tasks", reactKey: null, label: "Task Management", title: "Task Management", containerId: "custom-admin-tasks", renderFnName: "renderAdminTasksView", permission: "employee.view", featureFlag: "module_employee_enabled", sidebarGroup: "work", svg: `` }, { id: "tasks-create", path: "/admin/tasks/create", reactKey: null, label: null, title: "New Task", containerId: "custom-admin-tasks-create", renderFnName: "renderAdminTasksCreateView", permission: "employee.manage", featureFlag: "module_employee_enabled", sidebarGroup: "work" }, { id: "targets", path: "/admin/targets", reactKey: null, label: "Rewards & Targets", title: "Rewards & Targets", containerId: "custom-rewards-targets", renderFnName: "renderRewardsTargetsView", permission: "payroll.view", featureFlag: "module_payroll_enabled", sidebarGroup: "work", svg: `` }, { id: "announcements", path: "/admin/announcements", reactKey: null, label: "Announcements", title: "Announcements", containerId: "custom-announcements", renderFnName: "renderAnnouncementsView", permission: "employee.view", featureFlag: "module_employee_enabled", sidebarGroup: "comms", svg: `` }, { id: "documents", path: "/admin/documents", reactKey: null, label: "Company Documents", title: "Company Documents", containerId: "custom-documents", renderFnName: "renderDocumentsView", permission: "employee.view", featureFlag: "module_employee_enabled", sidebarGroup: "comms", svg: `` }, { id: "training", path: "/admin/training", reactKey: null, label: "Training Center", title: "Training Center", containerId: "custom-training", renderFnName: "renderTrainingView", permission: "employee.view", featureFlag: "module_employee_enabled", sidebarGroup: "comms", svg: `` }, { id: "payroll", path: "/admin/payroll", reactKey: "payroll", label: "Payroll & Salary", title: "Payroll & Salary", permission: "payroll.view", featureFlag: "module_payroll_enabled", sidebarGroup: "business", svg: `` }, { id: "push-notifications", path: "/admin/push-notifications", reactKey: "notifications", label: "Push Notifications", title: "Push Notifications", permission: "settings.manage", sidebarGroup: "system", svg: `` }, { id: "settings", path: "/admin/settings", reactKey: "settings", label: "Settings", title: "Settings", containerId: "bt-settings-page-container", renderFnName: "renderSettingsPage", permission: "settings.manage", sidebarGroup: "system", svg: `` }, { id: "scheduling", path: "/admin/scheduling", reactKey: null, label: "Shifts & Rosters", title: "Shifts & Rosters", containerId: "bt-scheduling-page-container", renderFnName: "renderSchedulingPage", permission: "scheduling.view", featureFlag: "module_scheduling_enabled", sidebarGroup: "business", svg: `` }, { id: "advances", path: "/admin/advances", reactKey: null, label: "Salary Advances", title: "Salary Advances", containerId: "bt-advances-page-container", renderFnName: "renderAdvancesPage", permission: "advance.view", featureFlag: "module_advance_enabled", sidebarGroup: "business", svg: `` }, { id: "reports", path: "/admin/reports", reactKey: "reports", label: "Reports & Analytics", title: "Reports & Analytics", containerId: "bt-reports-page-container", renderFnName: "renderReportsPage", permission: "reports.view", featureFlag: "module_reports_enabled", sidebarGroup: "business", svg: `` }, { id: "geo", path: "/admin/geo", reactKey: "geo", label: "Geo Tracking", title: "Geo Tracking", permission: "attendance.view", featureFlag: "module_attendance_enabled", sidebarGroup: "core", svg: `` } ]; if (typeof module !== "undefined" && module.exports) { module.exports = { ADMIN_ROUTES, ROLE_PERMISSIONS }; } if (typeof globalThis !== "undefined") { globalThis.ADMIN_ROUTES = ADMIN_ROUTES; globalThis.ROLE_PERMISSIONS = ROLE_PERMISSIONS; }