summaryrefslogtreecommitdiff
path: root/model_fs.js
diff options
context:
space:
mode:
Diffstat (limited to 'model_fs.js')
-rw-r--r--model_fs.js13
1 files changed, 9 insertions, 4 deletions
diff --git a/model_fs.js b/model_fs.js
index 036689c..e90b1a0 100644
--- a/model_fs.js
+++ b/model_fs.js
@@ -108,12 +108,17 @@ exports.rebuildFiles = function() {
for (var k in data) {
if (!data.hasOwnProperty(k)) { continue; }
var ev = data[k];
- ev.time = ev.start.toLocaleTimeString();
if(ev.start && ev.summary) {
- if(typeof compEv[ev.start.toLocaleDateString()] == "undefined") {
- compEv[ev.start.toLocaleDateString()] = [];
+ var dateStr = ev.start.toLocaleDateString();
+ ev.start = ev.start.toLocaleTimeString();
+ ev.end = ev.end.toLocaleTimeString();
+ delete ev.rrule;
+ delete ev.uid;
+ delete ev.type;
+ if(typeof compEv[dateStr] == "undefined") {
+ compEv[dateStr] = [];
}
- compEv[ev.start.toLocaleDateString()].push(ev);
+ compEv[dateStr].push(ev);
}
}
setEvents(slideset, compEv, function(err) {