How saiv4568/sis-escolar works
1. Overall shape
- This is a Laravel monolith for a school/academic management system.
- The app is centered on server-rendered Blade pages plus Livewire components for interactive CRUD screens, with Eloquent models backed by database migrations.
2. Primary user-facing areas
- There are two main UI paths:
- Traditional authentication/profile pages and a few controller-driven pages.
- A larger Livewire-based admin area for managing academic records and users.
- The resources/views tree shows this split clearly: auth, layouts, home, users, reportes, and livewire views.
3. Domain modules
- The core business entities are school objects: Estudiante, Personal, Gestion, Materia, Grado, Aula, Designacion, Matricula, Contenido, Evaluacion, Nota, Presentacion, Rol, and User.
- The Livewire components mirror these entities one-to-one in many cases, which suggests each component owns a module’s list/create/edit/delete workflow.
4. Request flow
- Browser requests enter through routes/web.php and are handled either by controllers or Livewire components.
- Controllers are used for authentication, profile, home, and user-facing pages.
- Livewire components likely handle most stateful interaction without full page reloads, while still rendering Blade views on the server.
5. Persistence layer
- Data is modeled with Eloquent in app/Models and persisted via explicit migrations in database/migrations.
- The migration set is domain-heavy and includes both identity/auth tables and the academic tables, indicating a relational schema with strong entity boundaries.
6. Authentication and authorization
- Standard Laravel auth scaffolding is present: login, registration, password reset, verification, confirmation.
- There is a dedicated Rol model and a rols table, implying role-based access control layered on top of Laravel auth.
- Middleware in app/Http/Middleware and app/Http/Kernel.php enforce session, CSRF, guest/auth redirects, and request hygiene.
7. Validation and business rules
- Input validation is handled through Laravel request objects, such as ProfileUpdateRequest.
- This suggests the app keeps some domain rules in form/request validation rather than only in controllers or components.
8. Reporting subsystem
- The resources/views/reportes templates and the Reportes Livewire component form a reporting boundary.
- These views likely generate printable or exportable academic reports such as final grades by student, subject, or trimester.
- Reporting is separated from the CRUD screens, which is useful when drawing the architecture diagram as its own output branch.
9. UI composition
- Layouts live in resources/views/layouts, with a dedicated guest layout and an app layout.
- Static assets are served from public and resources pipelines, including Bootstrap, Font Awesome, and custom CSS/JS.
- The front end is mostly Blade-driven rather than SPA-driven.
10. Localization
- The app is localized in English and Spanish via lang/en and lang/es.
- That means labels, auth messages, validation text, and UI copy are likely language-aware across the system.
11. Supporting application structure
- app/Providers contains standard Laravel service providers, so the app follows conventional framework bootstrapping.
- app/Console and routes/console.php exist for scheduled or CLI tasks, though the repo tree does not show heavy background-job usage.
- routes/api.php and broadcasting files are present but do not appear central to the architecture.
12. Operational boundaries
- The application boundary is a typical Laravel stack: HTTP request in, session/auth/middleware, controller or Livewire handling, Eloquent DB access, Blade response out.
- Storage directories are standard Laravel runtime areas for logs, cache, sessions, and framework-generated views.
- No separate service tier is evident; the system appears self-contained inside one Laravel codebase.
13. What to emphasize in a diagram
- Place Livewire as the main interaction layer for academic administration.
- Place Controllers/Auth/Profile as a smaller conventional web layer.
- Draw Eloquent models and migrations as the domain/data boundary beneath both.
- Show Reportes as an output-focused subsystem distinct from CRUD modules.
- Show Roles/User/Auth as the cross-cutting access-control boundary spanning the rest of the app.
Main entry points: web.php Web routes · base.blade.php Admin views · Estudiante.php School models · ProfileController.php Profile
Components 20
UI Layer
Blade pages and interactive Livewire screens
- Web routes · Main HTTP entry point that dispatches browser requests to controllers or Livewire pages
routes/web.php - Home · Landing and authenticated home page controller
app/Http/Controllers/HomeController.php - Profile · Profile editing and account self-service controller
app/Http/Controllers/ProfileController.php - Users · Controller-driven user management page(s)
app/Http/Controllers/UserController.php - Livewire base · Shared Livewire component base for admin CRUD screens
app/Livewire/Base.php - Academic CRUD · Stateful admin modules for school records such as students, grades, subjects, enrollment, grades, and class designations
app/Livewire/Estudiantes.php - Admin users · Interactive management for users and roles
app/Livewire/Usuarios.php - Layouts · App and guest shells plus shared navigation
resources/views/layouts/app.blade.php - Admin views · Blade templates backing the Livewire CRUD modules
resources/views/livewire/base.blade.php - Static assets · Compiled JS/CSS and vendor assets for the Blade interface
resources/js/app.js
Domain Layer
Eloquent models and database schema
- School models · Primary academic entities and user/role models
app/Models/Estudiante.php - Schema · Relational schema for auth, roles, and academic records
database/migrations/2024_05_07_130519_create_estudiantes_table.php
Access Control
Authentication, roles, and request protection
- Auth views · Login, registration, password reset, verification, and profile pages
resources/views/auth/login.blade.php - Profile request · Validation and update rules for profile changes
app/Http/Requests/ProfileUpdateRequest.php - Middleware · Auth, guest redirect, CSRF, signature, and request hygiene protections
app/Http/Middleware/Authenticate.php
Reports
Report generation and printable academic outputs
- Reportes UI · Reporting interface that drives academic report views
app/Livewire/Reportes.php - Report views · Printable academic report templates
resources/views/reportes/notasFinalesEstudiante.blade.php
Framework
Laravel bootstrapping and shared application services
- HTTP kernel · Registers middleware stack and request pipeline
app/Http/Kernel.php - Providers · Application bootstrapping and authorization/service wiring
app/Providers/AppServiceProvider.php - Localization · English and Spanish strings for auth, validation, and UI text
lang/en.json
Connections 24
- Web routes → Home: home · Routes homepage and authenticated landing pages
- Web routes → Profile: profile · Routes account profile actions
- Web routes → Users: users · Routes controller-driven user pages
- Web routes → Academic CRUD: admin screens · Dispatches most academic management screens to Livewire
- Web routes → Admin users: roles/users · Dispatches admin access-management screens
- Web routes → Reportes UI: reports · Dispatches reporting pages to Livewire
- Home → Layouts: renders · Uses the app layout for server-rendered pages
- Profile → Profile request: validates · Applies request validation for profile updates
- Profile → Auth views: renders · Uses auth/profile Blade templates
- Users → Admin views: renders · Uses Blade views for user management pages
- Livewire base → Admin views: renders · Provides the shared Livewire screen shell
- Academic CRUD → School models: CRUDs · Reads and writes the academic domain models
- Academic CRUD → Admin views: renders · Backs the interactive admin templates
- Admin users → School models: manages · Manages users and roles through the domain layer
- Admin users → Admin views: renders · Backs admin user-management templates
- Reportes UI → Report views: renders · Produces report-specific Blade outputs
- Reportes UI → School models: aggregates · Collects academic data for reports
- School models → Schema: persisted by · Models are backed by explicit relational migrations
- Middleware → HTTP kernel: registered in · Middleware stack is assembled in the HTTP kernel
- HTTP kernel → Web routes: protects · Applies the request pipeline before routing
- Providers → HTTP kernel: bootstraps · Framework service providers support request handling and auth setup
- Localization → Auth views: localizes · Provides translated UI and auth text
- Localization → Admin views: localizes · Provides translated labels and messages
- Static assets → Layouts: included by · Static assets are loaded by the Blade layouts