I have an object. I would like to define his by addind one of his many2one field name's (mission_id) and his sequence. So I write this code. but when create the objet i am getting the field (mission_id) id's numbre plus the object (mission_wave) sequence. How can i get mission_id name's instead of id?
Thanks.
class mission_wave(osv.osv):
def create(self, vals):if vals.get('name', '/') == '/':
vals['name'] = str(vals.get('mission_id') + str(self.env['ir.sequence'].get('hr.mission.wave'))
return super(hr_mission_wave, self).create(vals)