As sseen in:
http://hg.tryton.org/modules/account_product/file/tip/product.py#l55
the field “Accounting” of product.category is readonly when the record has parent or children.
This make it pretty easy for a user to create an “invalid” or “unexpected” structure if:
- User creates category A with Accounting=True
- User creates category B with Accounting=False
- User drags and drops B as a child of A.
In that situation the user finds that he/she cannot change the “Accounting” field for category B to “True” because it has a parent and does not easily/intuitively know how to fix it.
Any ideas on how to make it more robust?
Maybe adding a constraint on “parent” to ensure that the value of accounting is the same in self and parent?