[FIX]: crm_partner_assign: Fixed a problem when there is no partner found
bzr revid: rpa@tinyerp.com-20101008105641-lk93kad5hbf3hrx0
This commit is contained in:
parent
9e33cddedc
commit
0aa7ad9d0b
|
@ -171,7 +171,8 @@ class crm_lead(osv.osv):
|
|||
AND partner_weight > 0) AS d
|
||||
ORDER BY distance LIMIT 1""", (result[1],result[0]))
|
||||
res = cr.dictfetchone()
|
||||
part_ids.append(res['id'])
|
||||
if res:
|
||||
part_ids.append(res['id'])
|
||||
|
||||
total = 0
|
||||
toassign = []
|
||||
|
|
Loading…
Reference in New Issue