Saturday, August 9, 2025
1 change · 18.0
Resolved issues and error corrections
Fixes several issues in Spain’s VeriFactu compliance flow, including cancellation handling, refund classification, and point-of-sale refund links. This helps ensure Spanish invoices and POS transactions are reported with the correct customer and document information, reducing validation errors and compliance risk.
Original PR description
- Use the right function instead of `button_cancel`. - Fix "is_simplified" in case of refund. Only `R5` should be simplified. For R1 to R4 we need to set the partner info in the JSON / XML…
- Use the right function instead of `button_cancel`.
- Fix "is_simplified" in case of refund. Only `R5` should be simplified.
For R1 to R4 we need to set the partner info in the JSON / XML
(`Destinatarios`)
- Fix refunding in PoS w.r.t. uninvoiced / invoiced combinations
of refunding and refunded order.
- We can invoice an uninvoiced order. Here we have to retrieve the
refunded Veri*Factu document from the order when creating the
record values for the refunding move.
- We can refund w/o invoice an invoiced order. Here We have to retrieve the
refunded Veri*Factu document from the invoice when creating the
record values for the refunding order.
- Move the error checks s.t. the record values can be extended
more easily.
- Invoices from PoS orders should not be simplified.
(The PoS order would be could enough.)
- We should not set the simplified partner automatically anymore
(in case no partner is set). That way there will be an error
when validating the order.
- We should use `sudo` when querying the number of spanish companies
in the database. The results should be independent of access rights.
task-None
Forward-Port-Of: odoo/odoo#221000