A receipt is the final step in the MRP cycle. It confirms that the materials included in a dispatch have physically arrived at the obra warehouse. Confirming a receipt increments the obra warehouse’sDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/ElthonJohan/Sistema-MRP/llms.txt
Use this file to discover all available pages before exploring further.
Inventory.stock for each dispatched material and writes an IN movement record.
What a receipt confirms
A receipt is always linked to exactly one dispatch viaReceipt.dispatch_id. The create_receipt() service uses the dispatch’s items directly — no separate item selection is needed:
- For each
DispatchItem, it callsget_or_create_inventory()for the obra warehouse, scoped to the same project as the requirement (budget_id,budget_name). Inventory.stock += dispatched_qtyis applied to the obra warehouse record.- A
Movement(movement_type="IN", reference_type="receipt", reference_id=receipt.id)is written for each material.
(False, "Este despacho ya fue recibido").
How to register a receipt
Open the Receipts page
Navigate to Recepciones in the sidebar. Only dispatches that have not yet been received appear in the selector.
Select the dispatch
Choose the dispatch from the Selecciona despacho dropdown. The selector shows the Guía de Remisión number and dispatch date.
Review the materials
The page lists each material in the dispatch with quantity, unit, and unit price. Materials with
dispatched_qty = 0 are shown in grey as already received.What happens after receipt
| Effect | Detail |
|---|---|
| Obra stock increases | Inventory.stock += dispatched_qty on the obra warehouse record, scoped to the requirement’s project |
| IN movement recorded | Movement(movement_type="IN", reference_type="receipt") per material |
| Dispatch marked received | The dispatch gains a Receipt relation; it moves to the Historial de Recepciones view |
Requirement or its items — status changes on the requirement happen only during dispatch creation.
Receipt history
Completed receipts appear in the Historial de Recepciones section with filters by obra, project, date range, and guia number. The history can be exported as CSV using the Descargar CSV button.All The receipt history card also displays
receipt_date timestamps are recorded in Lima/Peru time (UTC-5, no daylight saving time). The offset is applied in receipt_service.py via:"hora Lima (UTC-5)" alongside the receipt date to make the timezone explicit.