Add support for google calendar
This commit is contained in:
@@ -5,10 +5,7 @@ public class TLWLeague {
|
||||
String leagueName = "";
|
||||
switch (id) {
|
||||
case 1:
|
||||
leagueName = "1. Tippliga Würzburg";
|
||||
break;
|
||||
case 2:
|
||||
leagueName = "2. Tippliga Würzburg";
|
||||
leagueName = "Tippliga";
|
||||
break;
|
||||
case 46:
|
||||
leagueName = "Elfmeter";
|
||||
@@ -58,19 +55,19 @@ public class TLWLeague {
|
||||
switch (id) {
|
||||
case 1:
|
||||
case 2:
|
||||
leagueName = "TLW";
|
||||
leagueName = "Tippliga";
|
||||
break;
|
||||
case 46:
|
||||
leagueName = "ELF";
|
||||
leagueName = "Elfmeter";
|
||||
break;
|
||||
case 47:
|
||||
leagueName = "REL";
|
||||
leagueName = "Relegation";
|
||||
break;
|
||||
case 48:
|
||||
leagueName = "WTL";
|
||||
leagueName = "WTL-Pokal";
|
||||
break;
|
||||
case 49:
|
||||
leagueName = "LC";
|
||||
leagueName = "Liga Cup";
|
||||
break;
|
||||
default: break;
|
||||
}
|
||||
|
||||
@@ -9,6 +9,8 @@ import java.util.ArrayList;
|
||||
import java.util.Comparator;
|
||||
import java.util.Date;
|
||||
|
||||
import static de.jeyp91.googlecalendar.TippligaGoogleEventManager.*;
|
||||
|
||||
public class TLWMatchdaysUpdater {
|
||||
|
||||
private final Logger logger = LogManager.getLogger(TLWMatch.class);
|
||||
@@ -72,6 +74,7 @@ public class TLWMatchdaysUpdater {
|
||||
condition;
|
||||
this.beautifulInfo += beautifulInfoStart +
|
||||
"Tippabgabeschluss 1 zu '" + matchdayUpdated.getDeliveryDate() + "'.\n";
|
||||
createOrUpdateEvent(matchdayUpdated, matchdayUpdated.getDeliveryDate(), 1);
|
||||
}
|
||||
|
||||
if (!matchdayOriginal.getDeliveryDate2().equals(matchdayUpdated.getDeliveryDate2())) {
|
||||
@@ -80,6 +83,10 @@ public class TLWMatchdaysUpdater {
|
||||
condition;
|
||||
this.beautifulInfo += beautifulInfoStart +
|
||||
"Tippabgabeschluss 2 zu '" + matchdayUpdated.getDeliveryDate2() + "'.\n";
|
||||
if(!matchdayUpdated.getDeliveryDate2().equals(""))
|
||||
createOrUpdateEvent(matchdayUpdated, matchdayUpdated.getDeliveryDate2(), 2);
|
||||
else
|
||||
deleteEvent(matchdayUpdated, 2);
|
||||
}
|
||||
|
||||
if (!matchdayOriginal.getMatchdayName().equals(matchdayUpdated.getMatchdayName())) {
|
||||
@@ -88,6 +95,9 @@ public class TLWMatchdaysUpdater {
|
||||
condition;
|
||||
this.beautifulInfo += beautifulInfoStart +
|
||||
"Spieltagsname zu '" + matchdayUpdated.getMatchdayName() + "'.\n";
|
||||
createOrUpdateEvent(matchdayUpdated, matchdayUpdated.getDeliveryDate(), 1);
|
||||
if(!matchdayUpdated.getDeliveryDate2().equals(""))
|
||||
createOrUpdateEvent(matchdayUpdated, matchdayUpdated.getDeliveryDate2(), 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user