Copyright (C) 2005 James Grant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ ?> << ".i18n("Back to Administration")."\n"; echo "<< ".i18n("Back to Judges")."\n"; if($_GET['edit']) $edit=$_GET['edit']; if($_POST['edit']) $edit=$_POST['edit']; if($_GET['action']) $action=$_GET['action']; if($_POST['action']) $action=$_POST['action']; $q=mysql_query("SELECT * FROM judges_schedulerconfig WHERE year='-1'"); while($r=mysql_fetch_object($q)) { mysql_query("INSERT INTO judges_schedulerconfig (var,val,description,year) VALUES ( '".mysql_escape_string($r->var)."', '".mysql_escape_string($r->val)."', '".mysql_escape_string($r->description)."', '".$config['FAIRYEAR']."')"); } if($_POST['action']=="save") { if($_POST['saveconfig']) { foreach($_POST['saveconfig'] as $key=>$val) { mysql_query("UPDATE judges_schedulerconfig SET val='".mysql_escape_string(stripslashes($val))."' WHERE year='".$config['FAIRYEAR']."' AND var='$key'"); } } echo happy(i18n("Judges Scheduler Configuration successfully saved")); } $q=mysql_query("SELECT * FROM config WHERE year=0 ORDER BY var"); echo "
"; echo "\n"; echo ""; echo ""; $q=mysql_query("SELECT * FROM judges_schedulerconfig WHERE year='".$config['FAIRYEAR']."' ORDER BY var"); $schedulerconfig=array(); while($r=mysql_fetch_object($q)) { $schedulerconfig[$r->var]=$r->val; echo ""; } echo "


".i18n("Scheduler configuration settings for fair year %1",array($config['FAIRYEAR']))."

$r->var".i18n($r->description)."var]\" value=\"$r->val\" />
"; echo "\n"; echo "
"; echo "
"; $ok=checkPrerequisites(); if($ok) { echo i18n("Everything looks in order, we're ready to create the divisional awards judging teams. Click 'Create Divisional Awards Judging Teams' below to start the scheduler. Please be patient as it may take 20-30 seconds to find an optimal solution to the judging team assignments"); echo "
"; echo "
"; echo "".i18n("Create Divisional Awards Judging Teams").""; } echo ""; echo "
"; echo "
"; echo "
"; send_footer(); ?>