[FIX] hr_holidays: Refusal of holidays was broken when leave is requested by category

lp bug: https://launchpad.net/bugs/794099 fixed

bzr revid: jvo@tinyerp.com-20110607171935-icqldup5eqmcem0b
This commit is contained in:
Jay Vora (OpenERP)
2011-06-07 22:49:35 +05:30
parent 6ccb0e047a
commit a356667de1
+2 -2
View File
@@ -294,8 +294,8 @@ class hr_holidays(osv.osv):
# If a category that created several holidays, cancel all related
wf_service = netsvc.LocalService("workflow")
for id in record.linked_request_ids or []:
wf_service.trg_validate(uid, 'hr.holidays', id, 'cancel', cr)
for res in record.linked_request_ids:
wf_service.trg_validate(uid, 'hr.holidays', res.id, 'cancel', cr)
return True