Merge lp:~openerp-dev/openobject-addons/6.1-opw-573199-ksa into lp:openobject-addons/6.1

Proposed by Kirti Savalia(OpenERP)
Status: Approved
Approved by: Naresh(OpenERP)
Approved revision: 6717
Proposed branch: lp:~openerp-dev/openobject-addons/6.1-opw-573199-ksa
Merge into: lp:openobject-addons/6.1
Diff against target: 21 lines (+2/-2)
1 file modified
hr_recruitment/ (+2/-2)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/6.1-opw-573199-ksa
Reviewer Review Type Date Requested Status
Naresh(OpenERP) Pending
Review via email:

Description of the change


Fix the problem when stage id is not in the list.


To post a comment you must log in.
Revision history for this message
Naresh(OpenERP) (nch-openerp) wrote :


This bug was qualified as Not Relevant on Trunk (means that architecture on trunk has changed and so this bug has no meaning anymore). If this Merge Proposal could not be merged in v6.1 at the release of v7.0, it will be closed.


Unmerged revisions

6717. By Kirti Savalia(OpenERP)

[FIX]: when stage id is not in the list

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'hr_recruitment/'
2--- hr_recruitment/ 2011-12-31 07:57:20 +0000
3+++ hr_recruitment/ 2012-03-30 11:01:22 +0000
4@@ -243,7 +243,7 @@
5 department = ( or False)
6 st = or False
7 stage_ids =, uid, ['|',('department_id','=',department),('department_id','=',False)], context=context)
8- if st and stage_ids.index(st):
9+ if st in stage_ids and stage_ids.index(st):
10 self.write(cr, uid, [], {'stage_id': stage_ids[stage_ids.index(st)-1]}, context=context)
11 else:
12 self.write(cr, uid, [], {'stage_id': False}, context=context)
13@@ -263,7 +263,7 @@
14 st = or False
15 stage_ids =, uid, ['|',('department_id','=',department),('department_id','=',False)], context=context)
16 val = False
17- if st and len(stage_ids) != stage_ids.index(st)+1:
18+ if st in stage_ids and len(stage_ids) != stage_ids.index(st)+1:
19 val = stage_ids[stage_ids.index(st)+1]
20 elif (not st) and stage_ids:
21 val = stage_ids[0]