[FIX]: make wizard working for all models related to the CRM

leads, oppurtunity

bzr revid: mga@tinyerp.com-20100203113948-xzfo7doiz96w19wp
This commit is contained in:
Mantavya Gajjar
2010-02-03 17:09:48 +05:30
parent 423b3beefe
commit 1f6470dfb3
@@ -112,7 +112,7 @@ def _get_info(self, cr, uid, data, context):
return {}
pool = pooler.get_pool(cr.dbname)
case = pool.get('crm.lead').browse(cr, uid, data['id'])
case = pool.get(data.get('model')).browse(cr, uid, data['id'])
if not case.user_id:
raise wizard.except_wizard(_('Error'),_('You must define a responsible user for this case in order to use this action!'))