- gab mit dem bestehenden Ordner downloads Probleme

renamed:    md/downloads.md -> md/download.md
	renamed:    yaml/downloads.subNav.yaml -> yaml/download.subNav.yaml
	modified:   yaml/extras.subNav.yaml
- kleinere Rechtschreibekorrektur
	modified:   md/index.md
- überflüßige Datei entfernt
	deleted:    md/kontakt.md~
- das Zitat wieder zurück in den Header geholt
	modified:   pandocTemplate/cwsvJudo.html5.pandocTemplate
- muss nocheinmal überprüft werden: warum funktioniert die
Jahresansicht der News nicht?
	modified:   phpLib/cwsvJudo/newsLib.php
	modified:   phpLib/cwsvJudo/newsTableHtml.php
- Überwachen der alten Adressen für eine korrekte Umleitung
	new file:   redirecting/pagesDesktop/redirecter.php
	new file:   redirecting/pagesDesktop/redirects.json
	new file:   redirecting/pagesMobile/redirecter.php
	new file:   redirecting/pagesMobile/redirects.json
- ein zu frühes melden im Wettkampfplaner verhindern!
	modified:   wkParticipo/eventKalender.php
	modified:   wkParticipo/lib/wkParticipoLib.inc.php
	modified:   wkParticipo/showWkEvent.php
This commit is contained in:
marko
2018-07-23 10:53:18 +02:00
parent 93ad33a7bd
commit 4ca073001c
15 changed files with 353 additions and 161 deletions

View File

@@ -1,79 +1,80 @@
<?php
require_once('./local/wkParticipoConf.php.inc');
require_once('./authLogin.php');
require_once('./local/db.php.inc');
require_once('./lib/wkParticipoLib.inc.php');
$sqlMessage = array();
$mysqlConn = @new mysqli($db_server, $db_user, $db_password, $db_name);
if ($mysqlConn->connect_error) {
$sqlMessage['error'] .= 'Datenbankverbindung fehlgeschlagen: ' . $mysqlConn->connect_error;
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Wettkampfplanung der Judoka des CWSV</title>
<link rel="stylesheet" href="./style.css">
</head>
<body>
<?php echo $login_status;?>
<?php echo htmlRetMessage($sqlMessage);?>
<h1>Wettkampfplanung - Kalender</h1>
<style>
.navBar{
display: flex;
flex-flow: column;
}
</style>
<div class="navBar">
<a class="touchLink" href="./index.php">
<div>Zur Übersicht zurück</div>
</a>
<a class="touchLink" href="http://cwsvjudo.bplaced.net/pages/desktop/wkParticipo/calendar.php">
<div>die geplanten Wettkämpfe als iCal</div>
</a>
<a class="touchLink" href="https://www.google.com/calendar/render?cid=http://cwsvjudo.bplaced.net/pages/desktop/wkParticipo/calendar.php">
<div>alle geplanten Wettkämpfe in den Google Kalender übernehmen</div>
</a>
</div>
<h2 id="wettkaempfen">Anstehende Wettkämpfe</h2>
<?php
$wkEvents = getCommingWkEvents($mysqlConn);
if( empty($wkEvents) ){
?>
<p>Momentan befinden sich anscheinend keine Wettkämpfe in Planung!</p>
<?php
}
else{
foreach( $wkEvents as $wk){
$wkEvent = getWkEventData($mysqlConn, $wk['id']);
echo htmlWkEvent($wkEvent, getStarterForEvent($mysqlConn, $wkEvent['id']), getFahrtenForEvent($mysqlConn, $wkEvent['id']));
?>
<hr />
<?php
}
}
?>
<!--Beginn der Einbindung des Counters-->
<?php
$chCounter_page_title = "Wettkampfplaner -- Eventkalender";
$chCounter_page_url = $_SERVER[HTTP_HOST] . $_SERVER[REQUEST_URI] . "?user=".$_SESSION['user']['username'];
$chCounter_visible=0;
// include( $_SERVER['DOCUMENT_ROOT'].'/expCounter/counter.php');
?>
</body>
</html>
<?php
require_once('./local/wkParticipoConf.php.inc');
require_once('./authLogin.php');
require_once('./local/db.php.inc');
require_once('./lib/wkParticipoLib.inc.php');
$sqlMessage = array();
$mysqlConn = @new mysqli($db_server, $db_user, $db_password, $db_name);
if ($mysqlConn->connect_error) {
$sqlMessage['error'] .= 'Datenbankverbindung fehlgeschlagen: ' . $mysqlConn->connect_error;
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Wettkampfplanung der Judoka des CWSV</title>
<link rel="stylesheet" href="./style.css">
<link rel="stylesheet" href="wkParticipo.css">
</head>
<body>
<?php echo $login_status;?>
<?php echo htmlRetMessage($sqlMessage);?>
<h1>Wettkampfplanung - Kalender</h1>
<style>
.navBar{
display: flex;
flex-flow: column;
}
</style>
<div class="navBar">
<a class="touchLink" href="./index.php">
<div>Zur Übersicht zurück</div>
</a>
<a class="touchLink" href="http://cwsvjudo.bplaced.net/pages/desktop/wkParticipo/calendar.php">
<div>die geplanten Wettkämpfe als iCal</div>
</a>
<a class="touchLink" href="https://www.google.com/calendar/render?cid=http://cwsvjudo.bplaced.net/pages/desktop/wkParticipo/calendar.php">
<div>alle geplanten Wettkämpfe in den Google Kalender übernehmen</div>
</a>
</div>
<h2 id="wettkaempfen">Anstehende Wettkämpfe</h2>
<?php
$wkEvents = getCommingWkEvents($mysqlConn);
if( empty($wkEvents) ){
?>
<p>Momentan befinden sich anscheinend keine Wettkämpfe in Planung!</p>
<?php
}
else{
foreach( $wkEvents as $wk){
$wkEvent = getWkEventData($mysqlConn, $wk['id']);
echo htmlWkEvent($wkEvent, getStarterForEvent($mysqlConn, $wkEvent['id']), getFahrtenForEvent($mysqlConn, $wkEvent['id']));
?>
<hr />
<?php
}
}
?>
<!--Beginn der Einbindung des Counters-->
<?php
$chCounter_page_title = "Wettkampfplaner -- Eventkalender";
$chCounter_page_url = $_SERVER[HTTP_HOST] . $_SERVER[REQUEST_URI] . "?user=".$_SESSION['user']['username'];
$chCounter_visible=0;
// include( $_SERVER['DOCUMENT_ROOT'].'/expCounter/counter.php');
?>
</body>
</html>

View File

@@ -1209,6 +1209,9 @@ $retHtml = "";
foreach($fahrten as $fahrt)
$anzPlätze += $fahrt['plaetze'];
$heuteDateTime = DateTime::createFromFormat("Y-m-d", date("Y-m-d"));
$einschreibeDateTime = DateTime::createFromFormat("Y-m-d", $aWkEvent['meldefrist']);
$retHtml =
"<div class=\"wkInfoCard\">".
"<time class=\"wkInfoCardDate\" datetime=\"".$aWkEvent['Datum']."\">".
@@ -1244,10 +1247,13 @@ $retHtml = "";
"<input type=\"hidden\" name=\"f[eventId]\" value=".
( isset( $aWkEvent['id'] ) ? $aWkEvent['id'] : "").
" />".
( date("Y-m-d") > $aWkEvent['meldefrist']?
"<button type=\"submit\" disabled>ist die Einschreibefrist bereits abgelaufen!</button>".
"<p>Frist für das Einschreiben verpasst? Für ein nachträgliches Einschreiben mit dem Admin verständigen (<a href=\"mailto:cwsvjudo@arcor.de?Subject=" . ( rawurlencode("Meldefrist ".$aWkEvent['Veranstaltung']) ) . "\" target=\"_top\">Email an cwsvjudo@arcor.de</a>).</p>"
:"<button type=\"submit\">jmd. einschreiben</button>"
( $heuteDateTime->modify( "+ 4 weeks") < $einschreibeDateTime?
"<button type=\"submit\" disabled>ist es noch zu früh jemanden einzuschreiben!</button>"
:( date("Y-m-d") > $aWkEvent['meldefrist']?
"<button type=\"submit\" disabled>ist die Einschreibefrist bereits abgelaufen!</button>".
"<p>Frist für das Einschreiben verpasst? Für ein nachträgliches Einschreiben mit dem Admin verständigen (<a href=\"mailto:cwsvjudo@arcor.de?Subject=" . ( rawurlencode("Meldefrist ".$aWkEvent['Veranstaltung']) ) . "\" target=\"_top\">Email an cwsvjudo@arcor.de</a>).</p>"
:"<button type=\"submit\">jmd. einschreiben</button>"
)
).
"</form>"
).
@@ -1269,7 +1275,7 @@ $retHtml = "";
"</div>".
"<div class=\"wkInfoCardButtonBar\">".
"<a href =\"./showWkEvent.php?eventId=".$aWkEvent['eventId']."\" class=\"wkInfoCardButton wkInfoCardButtonSuccess wkInfoCardButtonRaised\">Detailansicht</a>".
"<a href =\"./showWkEvent.php?eventId=".$aWkEvent['id']."\" class=\"wkInfoCardButton wkInfoCardButtonSuccess wkInfoCardButtonRaised\">Detailansicht</a>".
"<a href =\"/ressourcen/phpLib/calendar.php?wkID=".$aWkEvent['wkId']."\" class=\"wkInfoCardButton wkInfoCardButtonSuccess wkInfoCardButtonRaised\">Termin als iCal</a>".
"<a href =\"".addToGcalUrl( $aWkEvent['Veranstaltung'], $aWkEvent['Datum'] )."\" class=\"wkInfoCardButton wkInfoCardButtonSuccess wkInfoCardButtonRaised\">In den Google Calendar</a>".
"</div>".

View File

@@ -61,7 +61,7 @@
<ul>
<li>Wettkampfname: <?php echo mb_convert_encoding($eventData['Veranstaltung'], 'UTF-8', 'ISO-8859-1');?></li>
<li>Datum: <time datetime="<?php echo mb_convert_encoding($eventData['Datum'], 'UTF-8', 'ISO-8859-1');?>"><?php echo mb_convert_encoding($eventData['Datum'], 'UTF-8', 'ISO-8859-1');?></time></li>
<li>Frist zum Einschreiben: <time datetime="<?php echo mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1');?>"><?php echo mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1');?></time> <a class="touchLink" href ="<?php echo(addToGcalUrl(mb_convert_encoding($eventData['Veranstaltung'], 'UTF-8', 'ISO-8859-1'), mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1') ));?>">Einschreibefrist in den Google Calendar eintragen</a></li>
<li>Frist zum Einschreiben: <time datetime="<?php echo mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1');?>"><?php echo mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1');?></time> <a class="touchLink" href ="<?php echo(addToGcalUrl(mb_convert_encoding($eventData['Veranstaltung'], 'UTF-8', 'ISO-8859-1'), mb_convert_encoding($eventData['meldefrist'], 'UTF-8', 'ISO-8859-1') ));?>">Einschreibefrist in den Google Calendar übernehmen</a></li>
<li>Altersklassen: <?php echo mb_convert_encoding($eventData['Altersklassen'], 'UTF-8', 'ISO-8859-1');?></li>
<li>Ort: <a class="touchLink" href="<?php echo $eventData['Routenplaner'];?>"><?php echo mb_convert_encoding($eventData['Ort'], 'UTF-8', 'ISO-8859-1');?></a></li>
</ul>
@@ -165,19 +165,22 @@
echo("<div>Bereits eingeschrieben!</div>");
}
else{
if( date("Y-m-d") > $eventData['meldefrist']){
echo "<button class=\"touchButton\" type=\"submit\" disabled>Die Frist zum Einschreiben (".$eventData['meldefrist'].") ist bereits abgelaufen!</button>";
if (!empty($_SESSION['login'])){
echo( "<p>Frist für das Einschreiben verpasst? Für ein nachträgliches Eintragen mit dem Admin verständigen (<a href=\"mailto:cwsvjudo@arcor.de?Subject=".rawurlencode("Meldefrist ".mb_convert_encoding($eventData['Veranstaltung'], 'UTF-8', 'ISO-8859-1'))."\" target=\"_top\">Email an cwsvjudo@arcor.de</a>).</p>" );
}
$heuteDateTime = DateTime::createFromFormat("Y-m-d", date("Y-m-d"));
$einschreibeDateTime = DateTime::createFromFormat("Y-m-d", $eventData['meldefrist']);
if($heuteDateTime->modify( "+ 4 weeks") < $einschreibeDateTime){
echo("<button type=\"submit\" disabled>Es ist noch zu früh jemanden einzuschreiben!</button>");
}
else{
echo "<button class=\"touchButton\" type=\"submit\" name=\"submit\">Einschreiben</button>";
if( date("Y-m-d") > $eventData['meldefrist']){
echo "<button class=\"touchButton\" type=\"submit\" disabled>Die Frist zum Einschreiben (".$eventData['meldefrist'].") ist bereits abgelaufen!</button>";
if (!empty($_SESSION['login'])){
echo( "<p>Frist für das Einschreiben verpasst? Für ein nachträgliches Eintragen mit dem Admin verständigen (<a href=\"mailto:cwsvjudo@arcor.de?Subject=".rawurlencode("Meldefrist ".mb_convert_encoding($eventData['Veranstaltung'], 'UTF-8', 'ISO-8859-1'))."\" target=\"_top\">Email an cwsvjudo@arcor.de</a>).</p>" );
}
}
else{
echo "<button class=\"touchButton\" type=\"submit\" name=\"submit\">Einschreiben</button>";
}
}
}
?>