Added course type BE

Fixes #6
This commit is contained in:
Thomas Forgione 2017-09-29 14:48:32 +02:00
parent f134b08ecf
commit f0fbf40363
No known key found for this signature in database
GPG Key ID: C75CD416BD1FFCE1
1 changed files with 8 additions and 4 deletions

View File

@ -22,24 +22,28 @@ function fromIcal(string) {
cal.Type = { cal.Type = {
TD: 1, TD: 1,
TP: 2, TP: 2,
CTD: 3, BE: 3,
CM: 4, CTD: 4,
Other: 5, CM: 5,
Other: 6,
} }
cal.getTypeName = function(type) { cal.getTypeName = function(type) {
switch (type) { switch (type) {
case cal.Type.TD: return "TD";
case cal.Type.TP: return "TP"; case cal.Type.TP: return "TP";
case cal.Type.CTD: return "CTD"; case cal.Type.CTD: return "CTD";
case cal.Type.CM: return "CM"; case cal.Type.CM: return "CM";
case cal.Type.BE: return "BE";
default: return "Other"; default: return "Other";
} }
} }
cal.getFactor = function(type) { cal.getFactor = function(type) {
switch (type) { switch (type) {
case cal.Type.TP:
case cal.Type.TD: case cal.Type.TD:
case cal.Type.TP:
case cal.Type.BE:
return 1; return 1;
case cal.Type.CTD: return 1.25; case cal.Type.CTD: return 1.25;
case cal.Type.CM: return 1.5; case cal.Type.CM: return 1.5;