agenda: holidays display for other services improved

Closes #4114
This commit is contained in:
Serghei Mihai 2013-12-16 13:29:12 +01:00
parent 5d6a177e94
commit 5c9550bfc9
No known key found for this signature in database
GPG Key ID: 76D1C964BF2FA1AF
1 changed files with 2 additions and 1 deletions

View File

@ -163,6 +163,7 @@ def get_daily_appointments(date, worker, service, time_tables, events, holidays)
delta = interval.upper_bound - interval.lower_bound
delta_minutes = delta.seconds / 60
appointment = Appointment()
appointment.type = 'busy-here'
label = u"Congé (%s)" % holiday.holiday_type.name
appointment.init_holiday_time(label,
delta_minutes,
@ -171,7 +172,7 @@ def get_daily_appointments(date, worker, service, time_tables, events, holidays)
services = holiday.services.all()
if service not in services:
appointment.type = 'busy-elsewhere'
appointment.other_services_names = [s.slug for s in services]
appointment.other_services_names = [s.slug for s in services]
appointments.append(appointment)
for time_table in time_tables:
interval_set = IntervalSet.between(time_table.to_interval(date).lower_bound.time(),