Upport fix to 8.0
This commit is contained in:
@@ -227,7 +227,11 @@ class HrHolidays(models.Model):
|
||||
def vacation_from(self):
|
||||
hour = 0 # = morning
|
||||
if self.vacation_time_from and self.vacation_time_from == 'noon':
|
||||
hour = 12 # noon, LOCAL TIME
|
||||
hour = 13 # noon, LOCAL TIME
|
||||
# Warning : when the vacation STARTs at Noon, it starts at 1 p.m.
|
||||
# to avoid an overlap (which would be blocked by a constraint of
|
||||
# hr_holidays) if a user requests 2 half-days with different
|
||||
# holiday types on the same day
|
||||
datetime_str = False
|
||||
if self.vacation_date_from:
|
||||
date_dt = fields.Date.from_string(self.vacation_date_from)
|
||||
@@ -246,7 +250,11 @@ class HrHolidays(models.Model):
|
||||
def vacation_to(self):
|
||||
hour = 23 # = evening
|
||||
if self.vacation_time_to and self.vacation_time_to == 'noon':
|
||||
hour = 14 # Noon, LOCAL TIME
|
||||
hour = 12 # Noon, LOCAL TIME
|
||||
# Warning : when vacation STOPs at Noon, it stops at 12 a.m.
|
||||
# to avoid an overlap (which would be blocked by a constraint of
|
||||
# hr_holidays) if a user requests 2 half-days with different
|
||||
# holiday types on the same day
|
||||
datetime_str = False
|
||||
if self.vacation_date_to:
|
||||
date_dt = fields.Date.from_string(self.vacation_date_to)
|
||||
|
||||
Reference in New Issue
Block a user