[IMP]: marketing_campaign: When creating a new filter, the model should be selected as the domain of the campaign

bzr revid: rpa@tinyerp.com-20100826063509-a7bmofx5elabngo2
This commit is contained in:
rpa (Open ERP) 2010-08-26 12:05:09 +05:30
parent 8cd554c098
commit c2f8f9ec58
1 changed files with 1 additions and 0 deletions

View File

@ -264,6 +264,7 @@ class marketing_campaign_segment(osv.osv):
if model_name:
mod_name = model_name[0]['model']
res['domain'] = {'ir_filter_id': [('model_id', '=', mod_name)]}
res['context'] = {'default_model_id': model_name[0]['model']}
else:
res['value'] = {'ir_filter_id': False}
return res