Fix to bemade_time_off_follower.
This commit is contained in:
parent
0cf3ded6fe
commit
12ed7b8ce5
1 changed files with 2 additions and 0 deletions
|
|
@ -14,6 +14,8 @@ class MailThread(models.AbstractModel):
|
||||||
user = self.env['res.users'].search([('partner_id', '=', recipient['id'])], limit=1)
|
user = self.env['res.users'].search([('partner_id', '=', recipient['id'])], limit=1)
|
||||||
if user:
|
if user:
|
||||||
employee = self.env['hr.employee'].search([('user_id', '=', user.id)], limit=1)
|
employee = self.env['hr.employee'].search([('user_id', '=', user.id)], limit=1)
|
||||||
|
else:
|
||||||
|
employee = False
|
||||||
|
|
||||||
if employee:
|
if employee:
|
||||||
employee_id = employee.id
|
employee_id = employee.id
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue