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 have a many2one field : 'Numeros_bl': fields.many2one('stock.picking', 'Numeros Bls', readonly=True),
On xml I made :
<field name="Numeros_bl" widget="selection" domain="[('state','=','done'),('invoice_state','=','2binvoiced'),('partner_id','=',partner_id)]"/>
Invalid XML architecture as error. Nothing else in the traceback.
Why it's not accepting the widget ?
widget="selection" doesn't support dynamic domains. If you need dynamic domain you have to remove the widget.
But the static domain like <field name="Numeros_bl" widget="selection" domain="[('state','=','done')]"/> will work.
Selection widgets are pre-filtered server-side, and are not meant for dynamic domains, so this will not work and is not a bug.
This is a limitation of all OpenERP version so far (including 6.0), due to semantics of the fields.selection column type.
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: 12/12/14, 9:32 AM|
|Seen: 1667 times|
|Last updated: 7/30/15, 5:12 AM|