[IMP] crm: improve the view and fix the probelm of leadtopartner wizard

bzr revid: sbh@tinyerp.com-20100309095820-aajs2fedvcglyhjw
This commit is contained in:
sbh (Open ERP)
2010-03-09 15:28:20 +05:30
parent 2feb455905
commit 45309dff2c
3 changed files with 3 additions and 3 deletions
@@ -57,7 +57,6 @@ class crm_phonecall2phonecall(osv.osv_memory):
values['date']=this.date
phonecall_proxy = self.pool.get('crm.phonecall')
phonecall_id = phonecall_proxy.create(cr, uid, values, context=context)
value = {
'name': _('Phone Call'),
'view_type': 'form',
@@ -9,8 +9,8 @@
<form string="Schedule Other Call" col="2">
<field name="name"/>
<field name="user_id" />
<field name="section_id"/>
<field name="date" string="Planned Date"/>
<field name="section_id"/>
<group colspan="2" col="2" >
<button name="action_cancel" string="_Cancel" icon="gtk-cancel" special="cancel" />
<button name="action_apply" type="object" string="_Apply" icon="gtk-apply" />
+2 -1
View File
@@ -56,6 +56,7 @@ class crm_lead2partner(osv.osv_memory):
partner_obj = self.pool.get('res.partner')
contact_obj = self.pool.get('res.partner.address')
rec_ids = context and context.get('record_ids',False)
value={}
for case in case_obj.browse(cr, uid, rec_ids):
if case.partner_id:
raise wizard.except_wizard(_('Warning !'),
@@ -71,7 +72,7 @@ class crm_lead2partner(osv.osv_memory):
partner_id = partner_ids and partner_ids[0] or False
if not partner_id:
value = self._make_partner(cr, uid, ids, context)
return value or {}
return value
def _create_partner(self, cr, uid, ids, context):
case_obj = self.pool.get('crm.lead')