The Reservations module is available to both Administrators and Clients. Administrators can see and manage all reservations in the system. Clients can only see reservations linked to their own client record and can cancel their own pending reservations.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/EmirPolito/CRUD-HOTEL-GUEVARINI-Publico/llms.txt
Use this file to discover all available pages before exploring further.
Viewing Reservations
Navigate from the dashboard to Reservaciones. The list shows the following columns:| Column | Description |
|---|---|
| Código | Auto-generated unique code (e.g., RES-9912) |
| Cliente | Guest name linked to the reservation |
| Habitación | Room number assigned |
| Ingreso | Check-in date (DD/MM/YYYY) |
| Salida | Check-out date (DD/MM/YYYY) |
| Estado | Reservation status |
| Acción | Edit / Delete (Administrators) or Cancel (Clients, Pending only) |
Creating a Reservation
Click '+ Nueva Reserva'
On the reservations page, click + Nueva Reserva. This opens
/views/reservaciones/nueva_reserva.php.If there are no active clients or no available rooms, an error message is shown instead of the form.Select the client
Administrators choose from a dropdown of all active clients. Clients are automatically assigned to their own linked client record — the selector is hidden.
Select a room
Choose an available room from the dropdown. Only rooms with status
Disponible are listed, along with their nightly price.Set the dates
Enter the Fecha de Entrada (check-in) and Fecha de Salida (check-out). The check-out date must be strictly after the check-in date — the system rejects equal or reversed dates.
Updating a Reservation
Editing is available to Administrators only.Click 'Editar' on the reservation row
On the reservations list, click Editar next to the reservation. This opens
/views/reservaciones/editar_reserva.php?id={id}.Modify the reservation details
You can update:
- Cliente — Reassign to a different active client
- Habitación — Reassign to a different available room (or the currently assigned one)
- Fecha de Entrada and Fecha de Salida — Adjust the stay dates
- Estado — Change between
Pendiente,Confirmada, orCancelada
Cancelling a Reservation
Clients can cancel their own reservations, but only if the current status isPendiente. Reservations that are already Confirmada or Cancelada show “No cancelable” instead of a cancel button.
To cancel, click the Cancelar button on the reservation row. A confirmation modal appears before any action is taken.
Administrators can also permanently delete reservations using the Eliminar button, which removes the record from the database entirely.
Reservation Statuses
| Status | Description |
|---|---|
Pendiente | Default status when a reservation is first created |
Confirmada | Reservation has been confirmed by an Administrator |
Cancelada | Reservation was cancelled; the room may still show as Occupied until updated |
Date Validation
The check-in date must be strictly before the check-out date. Iffecha_entrada >= fecha_salida, the system rejects the submission and displays an error: “La fecha de salida debe ser mayor a la fecha de entrada.”