[IMP]CRM: set the phonecall_id and partner_id
bzr revid: sbh@tinyerp.com-20100119101404-1aoj4wt6onyjkj6f
This commit is contained in:
parent
0847e08576
commit
5ab447841e
|
@ -91,9 +91,15 @@ class opportunity2phonecall(wizard.interface):
|
|||
'categ_id' : form['category_id'],
|
||||
'description' : form['note'],
|
||||
'date' : form['deadline'],
|
||||
'section_id' : form['section_id']
|
||||
'section_id' : form['section_id'],
|
||||
'partner_id': opportunity.partner_id.id,
|
||||
'partner_address_id':opportunity.partner_address_id.id,
|
||||
'description':opportunity.description
|
||||
}, context=context)
|
||||
|
||||
vals = {}
|
||||
if not opportunity.phonecall_id:
|
||||
vals.update({'phonecall_id' : new_case})
|
||||
opportunity_case_obj.write(cr, uid, [opportunity.id], vals)
|
||||
opportunity_case_obj.case_cancel(cr, uid, [opportunity.id])
|
||||
phonecall_case_obj.case_open(cr, uid, [new_case])
|
||||
|
||||
|
|
Loading…
Reference in New Issue