[IMP] or condition

bzr revid: shp@tinyerp.com-20121030093057-ybd2uhr926dnyt9u
This commit is contained in:
pankita shah (Open ERP)
2012-10-30 15:00:57 +05:30
parent 5569c20aa1
commit 2a03bc48b9
+2 -2
View File
@@ -50,7 +50,7 @@ class crm_lead(base_stage, format_address, osv.osv):
def _get_default_stage_id(self, cr, uid, context=None):
""" Gives default stage_id """
section_id = self._get_default_section_id(cr, uid, context=context)
return self.stage_find(cr, uid, [], section_id, [('state', '=', 'draft'),'|', ('type', '=', 'lead'),'|',('type', '=', 'both')], context=context)
return self.stage_find(cr, uid, [], section_id, [('state', '=', 'draft'),'|', ('type', '=', 'lead'),('type', '=', 'both')], context=context)
def _resolve_section_id_from_context(self, cr, uid, context=None):
""" Returns ID of section based on the value of 'section_id'
@@ -338,7 +338,7 @@ class crm_lead(base_stage, format_address, osv.osv):
cases = self.browse(cr, uid, cases, context=context)
# collect all section_ids
section_ids = []
types = ['lead','opportunity','both']
types = ['lead','both']
if section_id:
section_ids.append(section_id)
for lead in cases: