Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I would like to apply a constraint on specific fields whatever the fileds that are modified.
For example I would like to check that field 'my_field' is checked whatever the filed that is changed :
@api.constrains('write_date', 'create_date', 'my_field')
.../... Blabla raise ValdiationError
This part works well if my_field is modified, yet it's not thrown if another field is changed.
So the constraints does not apply each time you validate a record.
How is it possible to do so?
Do I need to override the write method?
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 4/4/16, 12:16 PM|
|Seen: 695 times|
|Last updated: 4/4/16, 12:16 PM|