How rumintangpati-cloud/uas_023 works
Purpose and Runtime
This is a Laravel/PHP application for managing sports fields (“lapangan”) and reservations (“reservasi”), with browser-rendered Blade pages plus a JSON API. It runs through the Laravel HTTP front controller at public/index.php; CLI and operational commands enter via artisan. The README is Laravel boilerplate, so repository intent is inferred from domain controllers, models, views, and migrations.
HTTP Entry and Route Boundaries
Web requests are defined in routes/web.php and authentication routes in routes/auth.php; API requests enter separately through routes/api.php. Laravel bootstrapping and middleware registration begin at bootstrap/app.php. This establishes a server-rendered web boundary versus an API boundary, rather than a standalone frontend application.
Identity, Sessions, and Authorization
User identity is persisted by app/Models/User.php and Laravel authentication configuration in config/auth.php. Browser login, registration, verification, password recovery, and session lifecycle are handled by the controllers in app/Http/Controllers/Auth/, including custom login/registration controllers. Role-based access is a distinct authorization layer implemented in app/Http/Middleware/RoleMiddleware.php; the user-role schema change is in database/migrations/2026_07_16_072007_add_role_to_users_table.php.
Field Management Domain
Lapangan is the managed resource, represented by app/Models/Lapangan.php and stored through database/migrations/2026_07_16_070036_create_lapangans_table.php. app/Http/Controllers/LapanganController.php drives browser CRUD, validates writes through app/Http/Requests/StoreLapanganRequest.php and app/Http/Requests/UpdateLapanganRequest.php, and renders the views under resources/views/lapangan/. API-specific field presentation is isolated in app/Http/Controllers/Api/LapanganApiController.php and app/Http/Resources/LapanganResource.php.
Reservation Workflow
Reservation records are modeled by app/Models/Reservasi.php, with persistence defined in database/migrations/2026_07_16_070124_create_reservasis_table.php. app/Http/Controllers/ReservasiController.php is the workflow boundary for creating and listing reservations; incoming creation data is validated by app/Http/Requests/StoreReservasiRequest.php. The browser flow renders reservation forms/listing and a receipt (resources/views/reservasi/create.blade.php, resources/views/reservasi/index.blade.php, resources/views/reservasi/kwitansi.blade.php).
Presentation and Client Assets
Server-side responses use Blade layouts and reusable components, anchored by resources/views/layouts/app.blade.php and resources/views/layouts/guest.blade.php. Domain pages live under resources/views/lapangan/ and resources/views/reservasi/. CSS/JS source assets in resources/css/app.css and resources/js/app.js are built by Vite and deployed as versioned public assets in public/build/.
Persistence and Infrastructure
Laravel Eloquent mediates application models and the configured database (config/database.php); migrations include users, fields, reservations, cache, and jobs tables. Session, cache, queue, mail, filesystem, and logging backends are environment-configured through config/session.php, config/cache.php, config/queue.php, config/mail.php, and config/filesystems.php. No concrete third-party business service integration is evidenced in the tree; these Laravel infrastructure abstractions are the principal external-service boundaries.
Main entry points: app.php Application bootstrap · web.php Web routes · LapanganController.php Field management · ReservasiController.php Reservation workflow
Components 21
Runtime & Routing
- Laravel HTTP runtime
public/index.php - Application bootstrap · Registers middleware and application configuration.
bootstrap/app.php - Web routes · Browser and authenticated application routes.
routes/web.php - Auth routes
routes/auth.php - API routes · JSON API boundary.
routes/api.php - Artisan CLI
artisan
Identity & Access
- Authentication flow · Login, registration, verification, recovery, and sessions.
app/Http/Controllers/Auth/AuthenticatedSessionController.php - User identity
app/Models/User.php - Role authorization
app/Http/Middleware/RoleMiddleware.php
Sports Domain
- Field management · Browser CRUD for sports fields.
app/Http/Controllers/LapanganController.php - Field validation
app/Http/Requests/StoreLapanganRequest.php - Field JSON API
app/Http/Controllers/Api/LapanganApiController.php - Field API representation
app/Http/Resources/LapanganResource.php - Sports field
app/Models/Lapangan.php - Reservation workflow · Creates and lists reservations and receipts.
app/Http/Controllers/ReservasiController.php - Reservation validation
app/Http/Requests/StoreReservasiRequest.php - Reservation
app/Models/Reservasi.php
Presentation
- Blade pages · Layouts, field pages, and reservation forms, lists, and receipts.
resources/views/layouts/app.blade.php - Vite client assets · Builds CSS and JavaScript into versioned public assets.
resources/css/app.css
Persistence & Infrastructure
- Configured database · Eloquent persistence configured by Laravel.
config/database.php - Laravel backends · Environment-configured session, cache, queue, mail, filesystem, and logging.
config/session.php
Connections 26
- Laravel HTTP runtime → Application bootstrap: boots
- Application bootstrap → Web routes: registers
- Application bootstrap → Auth routes: registers
- Application bootstrap → API routes: registers
- Web routes → Role authorization: guards
- Auth routes → Authentication flow: dispatches
- Authentication flow → User identity: authenticates
- Role authorization → User identity: checks role
- Web routes → Field management: dispatches
- Web routes → Reservation workflow: dispatches
- API routes → Field JSON API: dispatches
- Field management → Field validation: validates writes
- Field management → Sports field: manages
- Field JSON API → Sports field: reads
- Field JSON API → Field API representation: serializes
- Reservation workflow → Reservation validation: validates creation
- Reservation workflow → Reservation: creates and lists
- Field management → Blade pages: renders
- Reservation workflow → Blade pages: renders
- Authentication flow → Blade pages: renders
- Sports field → Configured database: persists via Eloquent
- Reservation → Configured database: persists via Eloquent
- User identity → Configured database: persists via Eloquent
- Application bootstrap → Laravel backends: configures
- Vite client assets → Blade pages: styles and enhances
- Artisan CLI → Application bootstrap: boots application