I'm trying to update the discount of every SaleOrderLine on a SaleOrder after the discount of another SaleOrderLine with the same product_id has been changed.
So far I can update the discount field by searching the affected lines on the database, write the new discount and return the id's fo the affected lines to update the UI, but with the changes can't be discarded, as they were written to the database.
I've tried to make the discount field depend on the discount of the other SaleOrderLines, but the execution of this gets all messy as there isn't a clean way to check which line has the new discount.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Contabilidad
- Inventario
- PoS
- Project
- MRP
Se marcó esta pregunta
2871
Vistas
¿Le interesa esta conversación? ¡Participe en ella!
Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.
InscribirsePublicaciones relacionadas | Respuestas | Vistas | Actividad | |
---|---|---|---|---|
How to add a sequence a field?
Resuelto
|
|
2
dic 24
|
21258 | |
|
0
sept 24
|
1093 | ||
|
3
ago 24
|
2208 | ||
|
0
feb 24
|
1518 | ||
|
0
feb 24
|
1097 |