From 4f7a33d07c67df527ae401751546f7f627821458 Mon Sep 17 00:00:00 2001 From: adieu Date: Wed, 2 Jul 2014 17:36:41 +0800 Subject: [PATCH] Don't wrap callback functions which need to return value to fullcalendar. --- src/calendar.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/calendar.js b/src/calendar.js index 7078cfb..47a4dd0 100644 --- a/src/calendar.js +++ b/src/calendar.js @@ -156,9 +156,9 @@ angular.module('ui.calendar', []) angular.extend(config, uiCalendarConfig); angular.extend(config, calendarSettings); - + angular.forEach(config, function(value,key){ - if (typeof value === 'function'){ + if (typeof value === 'function' && ['eventDataTransform', 'eventClick'].indexOf(key) === -1){ config[key] = wrapFunctionWithScopeApply(config[key]); } }); @@ -264,4 +264,4 @@ angular.module('ui.calendar', []) }); } }; -}]); \ No newline at end of file +}]);