Pankita Shah(OpenERP) has proposed merging
lp:~openerp-dev/openobject-addons/trunk-bug-1071793-shp into
lp:openobject-addons.
Requested reviews:
Atul Patel(OpenERP) (atp-openerp)
Related bugs:
Bug #1071793 in OpenERP Addons: "[trunk] When user alters the stages for
leads, new leads won't get into draft mode"
https://bugs.launchpad.net/openobject-addons/+bug/1071793
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1071793-shp/+merge/131891
hello,
i have fixed problem of draft state when select type = 'lead' field.
thanks
shp
--
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1071793-shp/+merge/131891
Your team OpenERP R&D Team is subscribed to branch
lp:~openerp-dev/openobject-addons/trunk-bug-1071793-shp.
=== modified file 'crm/crm_lead.py'
--- crm/crm_lead.py 2012-10-15 09:02:00 +0000
+++ crm/crm_lead.py 2012-10-29 12:54:35 +0000
@@ -50,7 +50,7 @@
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', '=', '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'
@@ -340,7 +340,7 @@
cases = self.browse(cr, uid, cases, context=context)
# collect all section_ids
section_ids = []
- types = ['both']
+ types = ['lead','opportunity','both']
if section_id:
section_ids.append(section_id)
for lead in cases:
_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help : https://help.launchpad.net/ListHelp