[FIX] events yaml test, remove event.on_change_address_id
on_change_address_id was used to populate "display" address fields from the address m2o. The address fields were removed in favor of using show_address (in the context), leaving an onchange called returning fields which don't exist in the view, thus crashing the corresponding yaml test (which checks for that). Since the onchange has no purpose left, remove it and its call. bzr revid: xmo@openerp.com-20140108133015-ald901hsy1lqo7tv
This commit is contained in:
parent
1f5b6ecf17
commit
372b52b044
|
@ -272,21 +272,6 @@ class event_event(osv.osv):
|
|||
}
|
||||
return {'value': dic}
|
||||
|
||||
def on_change_address_id(self, cr, uid, ids, address_id, context=None):
|
||||
values = {}
|
||||
if not address_id:
|
||||
return values
|
||||
address = self.pool.get('res.partner').browse(cr, uid, address_id, context=context)
|
||||
values.update({
|
||||
'street' : address.street,
|
||||
'street2' : address.street2,
|
||||
'city' : address.city,
|
||||
'country_id' : address.country_id and address.country_id.id or False,
|
||||
'state_id' : address.state_id and address.state_id.id or False,
|
||||
'zip' : address.zip,
|
||||
})
|
||||
return {'value' : values}
|
||||
|
||||
def onchange_start_date(self, cr, uid, ids, date_begin=False, date_end=False, context=None):
|
||||
res = {'value':{}}
|
||||
if date_end:
|
||||
|
|
|
@ -74,7 +74,7 @@
|
|||
</div>
|
||||
<group name="main_field_group">
|
||||
<group>
|
||||
<field name="address_id" on_change="on_change_address_id(address_id)" context="{'show_address': 1}" options='{"always_reload": True}'/>
|
||||
<field name="address_id" context="{'show_address': 1}" options='{"always_reload": True}'/>
|
||||
<field name="organizer_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company"/>
|
||||
</group>
|
||||
|
|
Loading…
Reference in New Issue