feat: add absence notification and analytics features

- Implemented AbsenceNotifyView for notifying absence with session details.
- Created AnalyticsView for displaying group analytics and managing students at risk.
- Added ClassAttendanceView for marking attendance in classes.
- Defined new schemas for analytics and attendance in shared package.
This commit is contained in:
Jose Selesan
2026-09-23 16:24:45 -03:00
parent a363e9e8fc
commit 2e184845e1
59 changed files with 3854 additions and 23 deletions

View File

@@ -13,6 +13,9 @@ import { OnboardingView } from './routes/onboarding'
import { GroupDetailView } from './routes/group-detail'
import { CreateGroupView } from './routes/create-group'
import { JoinGroupView } from './routes/join-group'
import { ClassAttendanceView } from './routes/class-attendance'
import { AbsenceNotifyView } from './routes/absence-notify'
import { AnalyticsView } from './routes/analytics'
const rootRoute = createRootRoute({
component: () => <Outlet />,
@@ -48,6 +51,13 @@ const joinGroupRoute = createRoute({
component: JoinGroupView,
})
// Página pública: el alumno avisa su ausencia con su token personal.
const absenceNotifyRoute = createRoute({
getParentRoute: () => rootRoute,
path: '/avisar-ausencia/$token',
component: AbsenceNotifyView,
})
// Capa con la navegación de la app autenticada (Sidebar + BottomNav).
// El guard redirige a /onboarding a quien no completó el onboarding.
const appLayoutRoute = createRoute({
@@ -80,6 +90,12 @@ const groupDetailRoute = createRoute({
component: GroupDetailView,
})
const groupAnalyticsRoute = createRoute({
getParentRoute: () => appLayoutRoute,
path: '/groups/$groupId/analytics',
component: AnalyticsView,
})
const paymentsRoute = createRoute({
getParentRoute: () => appLayoutRoute,
path: '/payments',
@@ -104,21 +120,30 @@ const profileRoute = createRoute({
component: ProfileView,
})
const classAttendanceRoute = createRoute({
getParentRoute: () => appLayoutRoute,
path: '/class/$sessionId/attendance',
component: ClassAttendanceView,
})
const routeTree = rootRoute.addChildren([
loginRoute,
signupRoute,
verifyEmailRoute,
onboardingRoute,
joinGroupRoute,
absenceNotifyRoute,
appLayoutRoute.addChildren([
indexRoute,
groupsRoute,
createGroupRoute,
groupDetailRoute,
groupAnalyticsRoute,
paymentsRoute,
settingsRoute,
securityRoute,
profileRoute,
classAttendanceRoute,
]),
])