Calendar module: add month view

This commit is contained in:
Francis Lachapelle
2015-06-12 11:44:35 -04:00
parent a2c469d46a
commit 8f47e62dd2
6 changed files with 137 additions and 34 deletions
+13 -1
View File
@@ -82,7 +82,7 @@ String.prototype.asDate = function () {
if (this.length == 8) {
newDate = new Date(this.substring(0, 4),
this.substring(4, 6) - 1,
this.substring(6, 8));
this.substring(6, 8)); // yyyymmdd
}
}
}
@@ -156,6 +156,18 @@ Date.prototype.beginOfWeek = function() {
return beginOfWeek;
};
Date.prototype.endOfWeek = function() {
var endOfWeek = this.beginOfWeek();
endOfWeek.addDays(6);
endOfWeek.setHours(23);
endOfWeek.setMinutes(59);
endOfWeek.setSeconds(59);
endOfWeek.setMilliseconds(999);
return endOfWeek;
};
// YYYYMMDD
Date.prototype.getDayString = function() {
var newString = this.getYear();