+
+ def stage_set(self, cr, uid, ids, stage_id, context=None):
+ if context is None:
+ context = {}
+ res = super(hr_applicant, self).stage_set(cr, uid, ids,stage_id, context)
+ stage = self.pool.get('hr.recruitment.stage').browse(cr, uid, stage_id, context)
+ if stage.state == 'done':
+ context['onchange'] = True
+ self.case_close_with_emp(cr, uid, ids, context)
+ return res