From 7a69bc46eb5c2300e93d4b85c6954638a4271132 Mon Sep 17 00:00:00 2001 From: Alexandre Cloutier Date: Thu, 26 Jun 2014 16:42:05 -0400 Subject: [PATCH] applied comments --- SoObjects/Appointments/SOGoAppointmentFolder.m | 2 +- UI/Scheduler/UIxCalendarSelector.m | 2 -- UI/WebServerResources/SchedulerUI.js | 8 +++++++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/SoObjects/Appointments/SOGoAppointmentFolder.m b/SoObjects/Appointments/SOGoAppointmentFolder.m index 0a8746083..6f759a137 100644 --- a/SoObjects/Appointments/SOGoAppointmentFolder.m +++ b/SoObjects/Appointments/SOGoAppointmentFolder.m @@ -3282,7 +3282,7 @@ firstInstanceCalendarDateRange: (NGCalendarDateRange *) fir to: nil title: nil component: @"vtodo" - additionalFilters: @"c_status != 2 AND c_status != 3"]; + additionalFilters: @"c_status != 1 AND c_status != 3"]; activeTasks = [NSNumber numberWithInt:[tasksList count]]; diff --git a/UI/Scheduler/UIxCalendarSelector.m b/UI/Scheduler/UIxCalendarSelector.m index fd9e99c76..2c8a6910d 100644 --- a/UI/Scheduler/UIxCalendarSelector.m +++ b/UI/Scheduler/UIxCalendarSelector.m @@ -121,8 +121,6 @@ _intValueFromHex (NSString *hexString) [calendar setObject: [folder ownerInContext: context] forKey: @"owner"]; fActiveTasks = [folder activeTasks]; - if (fActiveTasks == nil) - fActiveTasks = 0; [calendar setObject:fActiveTasks forKey:@"activeTasks" ]; [calendars addObject: calendar]; } diff --git a/UI/WebServerResources/SchedulerUI.js b/UI/WebServerResources/SchedulerUI.js index ec3d7ce81..d69d69830 100644 --- a/UI/WebServerResources/SchedulerUI.js +++ b/UI/WebServerResources/SchedulerUI.js @@ -2915,7 +2915,13 @@ function initCalendarSelector() { var input = items[i].childNodesWithTag("input")[0]; var activeTasks = items[i].childNodesWithTag("span")[0]; $(input).observe("click", clickEventWrapper(updateCalendarStatus)); - $(activeTasks).innerHTML = "(" + activeTasks.innerText + ")"; + if (activeTasks.textContent == "0") { + activeTasks.innerHTML = ""; + } + else { + activeTasks.innerHTML = "(" + activeTasks.innerText + ")"; + } + } var links = $("calendarSelectorButtons").childNodesWithTag("a");