$res_grp = mysql_query("SELECT \r\n\t\t\t\t\t\t\t\tr.xRunde\r\n\t\t\t\t\t\t\tFROM\r\n\t\t\t\t\t\t\t\trunde as r\r\n\t\t\t\t\t\t\tWHERE\txWettkampf = {$_POST['eventgroup']}\r\n\t\t\t\t\t\t\tAND r.Gruppe ='' "); if (mysql_num_rows($res_grp) > 0) { $row_grp = mysql_fetch_array($res_grp); $groupexist = true; } if ($_POST['round'] > 0 || $groupexist) { $tt = new Timetable(); if ($groupexist) { $tt->round = $row_grp[0]; $tt->grp = $_POST['eventgroup']; } $tt->change(); } else { if (!empty($_POST['min'])) { $tt = new Timetable(); $tt->add(); } } if (!empty($GLOBALS['AA_ERROR'])) { AA_printErrorMsg($GLOBALS['AA_ERROR']); } } elseif ($_POST['arg'] == "change_lastdisc") { // first check if there are seeded rounds in current and next 'last discipline' list($cCat, $cCode) = split("_", $_POST['lastround']); // fetch round from current last discipline (cCat, cCode) and rounds from selectet last discipline /*$res = mysql_query("SELECT r.xRunde FROM runde as r , wettkampf as w WHERE
function AA_meeting_addTime($st, $wTyp, $item, $dTyp) { // date, item, roundtype, hr, min include './convtables.inc.php'; if ($wTyp > $cfgEventType[$strEventTypeSingleCombined] && $row[2] != $cfgEventType[$strEventTypeTeamSM]) { if ($dTyp == $cfgDisciplineType[$strDiscTypeTrack] || $dTyp == $cfgDisciplineType[$strDiscTypeTrackNoWind] || $dTyp == $cfgDisciplineType[$strDiscTypeDistance] || $dTyp == $cfgDisciplineType[$strDiscTypeRelay]) { // discipline type track $_POST['roundtype'] = 6; // round type "Serie" } else { // discipline type tech $_POST['roundtype'] = 9; // round type "ohne" } } if (preg_match("/[\\.,;:]/", $st) == 0) { $_POST['hr'] = substr($st, 0, -2); if (strlen($st) == 3) { $_POST['min'] = substr($st, 1); } elseif (strlen($st) == 4) { $_POST['min'] = substr($st, 2); } } else { list($_POST['hr'], $_POST['min']) = preg_split("/[\\.,;:]/", $st); } // auto configure enrolement and manipulation time $result = mysql_query("\r\n SELECT\r\n d.Typ\r\n , d.Appellzeit\r\n , d.Stellzeit\r\n FROM\r\n wettkampf as w\r\n LEFT JOIN disziplin_" . $_COOKIE['language'] . " as d USING(xDisziplin)\r\n WHERE w.xWettkampf = " . $item); $row = mysql_fetch_row($result); $stdEtime = strtotime($row[1]); // hold standard delay for enrolement time $stdMtime = strtotime($row[2]); // and manipulation time $tmp = strtotime($_POST['hr'] . ":" . $_POST['min'] . ":00"); $tmp = $tmp - $stdEtime; $_POST['etime'] = floor($tmp / 3600) . ":" . floor($tmp % 3600 / 60); $tmp = strtotime($_POST['hr'] . ":" . $_POST['min'] . ":00"); $tmp = $tmp - $stdMtime; $_POST['mtime'] = floor($tmp / 3600) . ":" . floor($tmp % 3600 / 60); if ($_POST['round'] > 0) { $tt = new Timetable(); $tt->change(); } else { $tt = new Timetable(); $tt->add(); } }