feat: mejorar pos movil y cierre de jornada

This commit is contained in:
mono
2026-10-25 20:03:36 -05:00
parent 3bffc7fdff
commit ba18b73ed9
20 changed files with 262 additions and 73 deletions

View File

@@ -0,0 +1,28 @@
# Spec Delta
## Purpose
Permite vender cómodamente desde celulares mostrando el carrito, la búsqueda de productos y la devuelta sin obligar a recorrer una lista larga.
## ADDED Requirements
### Requirement: Catálogo compacto en POS
The system SHALL keep the cart visible and allow selecting products through a searchable compact list or dialog.
#### Scenario: Selección en móvil
- **WHEN** user opens Ventas on a narrow viewport
- **THEN** the cart and total remain visible
- **AND** user can search and add a product from the catalog dialog
### Requirement: Calcular devuelta
The system SHALL calculate and display change for cash payments before saving a sale.
#### Scenario: Pago en efectivo
- **GIVEN** sale total is 12000
- **WHEN** user enters 20000 as received cash
- **THEN** the UI displays change of 8000
- **AND** the sale can be confirmed
#### Scenario: Efectivo insuficiente
- **WHEN** received cash is below the sale total
- **THEN** confirmation is disabled and an actionable message is shown

View File

@@ -0,0 +1,28 @@
# Spec Delta
## Purpose
Unifica la verificación del efectivo y pagos QR con el cierre de la jornada, evitando que el usuario cierre una jornada sin cuadrar los valores disponibles.
## ADDED Requirements
### Requirement: Cierre unificado
The system SHALL require counted cash and optionally accept the QR bank total before closing a day.
#### Scenario: Cierre con efectivo
- **GIVEN** an open day with recorded sales and expenses
- **WHEN** user enters counted cash and confirms closing
- **THEN** cash difference is calculated and saved
- **AND** the cash reconciliation and day are closed together
#### Scenario: Cierre con banco QR pendiente
- **WHEN** user closes with counted cash and no bank total
- **THEN** the day closes
- **AND** QR bank comparison remains explicitly pending
### Requirement: Ajuste dentro de inventario
The system SHALL expose inventory adjustments from the inventory area with product quantity and reason.
#### Scenario: Ajuste desde inventario
- **WHEN** user selects a product, enters a new quantity and reason
- **THEN** the inventory balance changes and the reason is recorded