Domain restriction doesn't work with selection widget

Bug #581364 reported by toink
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KDE OpenObject Client
New
Undecided
Unassigned

Bug Description

yanked from openobject-client-gtk:

+++
many2one field with a 'widget="selection" attribute in the XML view
definition. Then any domain restriction won't be applied in neither of the two
following cases:

CASE 1

PY model definition:
'country_id': field.many2one('res.country', 'Country'),
'state_id': field.many2one('res.country.state', 'State',
domain="[('country_id','=',country_id)]"),

XML view definition:
<field name="country_id" widget="selection" />
<field name="state_id" widget="selection" />

CASE 2

PY model definition:
'country_id': field.many2one('res.country', 'Country'),
'state_id': field.many2one('res.country.state', 'State'),

XML view definition:
<field name="country_id" widget="selection" />
<field name="state_id" widget="selection"
domain="[('country_id','=',country_id)]" />

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.