summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJulien MUETTON <the.mouette@gmail.com>2010-09-08 15:13:57 +0200
committerJulien MUETTON <the.mouette@gmail.com>2010-09-08 15:13:57 +0200
commit0ff86a22833fdeb72d87394bc9fe60a9178ff56f (patch)
tree6755a17a49f02a32cf2764060f3b3165fe1f5caa
parentbf9078efa9e8ac64abcdaf78a6c3a5e8f720cd7e (diff)
downloadjquery-week-calendar-0ff86a22833fdeb72d87394bc9fe60a9178ff56f.zip
jquery-week-calendar-0ff86a22833fdeb72d87394bc9fe60a9178ff56f.tar.gz
jquery-week-calendar-0ff86a22833fdeb72d87394bc9fe60a9178ff56f.tar.bz2
corrected the error when no userId is provided for a calEvent. see http://groups.google.com/group/jquery-week-calendar/browse_thread/thread/61bb695c5e906aae
-rw-r--r--jquery.weekcalendar.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/jquery.weekcalendar.js b/jquery.weekcalendar.js
index 2db7c50..49ba1be 100644
--- a/jquery.weekcalendar.js
+++ b/jquery.weekcalendar.js
@@ -2125,10 +2125,13 @@
_getEventUserId: function(calEvent){
var self = this;
var options = this.options;
- if($.isFunction(options.getEventUserId)){
+ if( options.showAsSeparateUsers && options.users && options.users.length ){
+ if($.isFunction(options.getEventUserId)){
return options.getEventUserId(calEvent, self.element);
- }
- return calEvent.userId;
+ }
+ return calEvent.userId;
+ }
+ return [];
},
/**
* sets the event user id on given calEvent