Multi-company fixes in hr_holidays_usability
This commit is contained in:
@@ -14,7 +14,9 @@ class HrHolidaysMassAllocation(models.TransientModel):
|
||||
@api.model
|
||||
def _default_employees(self):
|
||||
return self.env['hr.employee'].search([
|
||||
('holiday_exclude_mass_allocation', '=', False)])
|
||||
('holiday_exclude_mass_allocation', '=', False),
|
||||
('company_id', '=', self.env.user.company_id.id),
|
||||
])
|
||||
|
||||
@api.model
|
||||
def _get_default_holiday_status(self):
|
||||
|
||||
@@ -39,6 +39,7 @@ class HrHolidaysPost(models.TransientModel):
|
||||
('state', '=', 'validate'),
|
||||
('posted_date', '=', False),
|
||||
('vacation_date_to', '<=', self.before_date),
|
||||
('company_id', '=', self.env.user.company_id.id),
|
||||
])
|
||||
self.write({
|
||||
'state': 'done',
|
||||
|
||||
Reference in New Issue
Block a user