I'm trying to feed a dojoX Calendar data from a store. The data looks correct coming from the store, but I keep getting the following error in Firebug: Cannot parse date string (2016-11-12 12:00:00), specify a "decodeDate" function that translates this string into a Date object.
I have a decodeDate function specified. Here's how I'm creating the calendar:
var calendar = new Calendar({
dateInterval: "week",
startTimeAttr: "begin",
endTimeAttr: "end",
store: calendarStore,
cssClassFunc: function(item) {
return item.calendar;
},
decodeDate: function(s) {
return stamp.fromISOString(s);
},
encodeDate: function(t) {
return stamp.toISOString(s);
},
style: "position:relative; width:500px; height:450px"
}, "eventsCalendar");
As you can see, I do have a decodeDate function specified. When I store the date into my database, I stored it as 2016-11-12T12:00:00, yet what is in there is 2016-11-12 12:00:00. Could this be causing the issue? If so, how do I correct it?
Thanks,
Harry
--
Dojo Toolkit:
http://dojotoolkit.org/Tutorials:
http://dojotoolkit.org/documentation/[hidden email]
To unsubscribe, visit:
http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest