Show the appointment duration only if its different than the standard value.

This commit is contained in:
Alex Tselegidis 2016-08-11 22:56:54 +02:00
parent 4bd0f3661c
commit eef6966798
1 changed files with 4 additions and 3 deletions

View File

@ -165,8 +165,8 @@ window.BackendCalendarTableView = window.BackendCalendarTableView || {};
$(event.target).popover('toggle');
// Fix popover position
if ($('.popover').length > 0) {
if ($('.popover').position().top < 200) $('.popover').css('top', '200px');
if ($('.popover').length > 0 && $('.popover').position().top < 200) {
$('.popover').css('top', '200px');
}
});
@ -606,7 +606,8 @@ window.BackendCalendarTableView = window.BackendCalendarTableView || {};
$event.html(
appointment.customer.last_name +
' <span class="hour">' + startDate.toString('HH:mm') + '</span> (' + eventDuration + '\')'
' <span class="hour">' + startDate.toString('HH:mm') + '</span> '
+ (eventDuration !== parseInt(appointment.service.duration) ? '(' + eventDuration + '\')' : '')
);
$event.data(appointment);