This question has been flagged
2048 Views

I'm creating a method on my custom module.py to open hr_employee table and retrive work email about employee with a particular Tags... So i write this but doesn't function... :-(

def req_email_to(self, cr, uid, ids, context=None):
    value=[]
    id_category=self.pool.get('hr.employee.category').search(cr, uid, [('name', '=', 'CEO')], context=context)
    id_emp=self.pool.get('hr.employee').search(cr, uid, [(id_category, 'in', 'employee_ids')], context=context)        
    return value

def req_aut(self, cr, uid, ids, context=None):
    res= self.req_email_to(self, cr, uid, ids)

I get an error "AttributeError: 'list' object has no attribute 'split'"

Avatar
Discard