add school year and security fix
This commit is contained in:
@@ -2,6 +2,7 @@ import { useCallback, useEffect, useRef, useState } from 'react'
|
||||
import { Link, NavLink, Outlet, useLocation, useNavigate } from 'react-router-dom'
|
||||
import { useAuth } from '../auth/AuthProvider'
|
||||
import { CiPublicFooter } from '../components/CiPartials'
|
||||
import { ReadOnlyBanner, SchoolYearSelector } from '../components/schoolYear'
|
||||
import { readPortalStylePrefs, resolvePortalColorMode, type PortalStylePrefs } from '../lib/portalAppearance'
|
||||
import { isParentPortalRole, isTeacherPortalRole } from '../lib/portalRoles'
|
||||
|
||||
@@ -13,6 +14,7 @@ const parentNavItems = [
|
||||
{ to: '/app/parent/enroll-classes', icon: 'bi bi-pencil-square', label: 'Enroll in Classes' },
|
||||
{ to: '/app/parent/events', icon: 'bi bi-bell', label: 'Events' },
|
||||
{ to: '/app/parent/payment', icon: 'bi bi-credit-card', label: 'Invoice' },
|
||||
{ to: '/app/parent/statements', icon: 'bi bi-receipt', label: 'Statements' },
|
||||
{ to: '/app/parent/register-student', icon: 'bi bi-person-plus', label: 'Register Students' },
|
||||
{ to: '/app/parent/report-attendance', icon: 'bi bi-megaphone', label: 'Report Absence' },
|
||||
{ to: '/app/parent/report-cards', icon: 'bi bi-file-earmark-text', label: 'Report Cards' },
|
||||
@@ -214,6 +216,11 @@ export function MainLayout() {
|
||||
))}
|
||||
</ul>
|
||||
</nav>
|
||||
{user ? (
|
||||
<div className="d-none d-lg-flex align-items-center me-2">
|
||||
<SchoolYearSelector compact />
|
||||
</div>
|
||||
) : null}
|
||||
{user ? (
|
||||
<div
|
||||
ref={clusterRef}
|
||||
@@ -333,6 +340,7 @@ export function MainLayout() {
|
||||
</header>
|
||||
|
||||
<main className="container mt-4 flex-grow-1">
|
||||
<ReadOnlyBanner />
|
||||
<Outlet />
|
||||
</main>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user