Skip to content

Commit

Permalink
Merge pull request odoo#946 from joshuajan/7.0_hr_holidays_report_fix
Browse files Browse the repository at this point in the history
skip the inactivate employee in leaves summary
  • Loading branch information
antonylesuisse committed Jul 7, 2014
2 parents c0aa86b + 6c776d5 commit 6b274e4
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions addons/hr_holidays/report/holidays_summary_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,9 +223,7 @@ def create_xml(self, cr, uid, ids, data, context):
elif data['model']=='ir.ui.menu':
for id in data['form']['depts']:
dept = obj_dept.browse(cr, uid, id, context=context)
cr.execute("""SELECT id FROM hr_employee \
WHERE department_id = %s""", (id,))
emp_ids = [x[0] for x in cr.fetchall()]
emp_ids = obj_emp.search(cr, uid, [('department_id', '=', id)], context=context)
if emp_ids==[]:
continue
dept_done=0
Expand Down

0 comments on commit 6b274e4

Please sign in to comment.