Show
Ignore:
Timestamp:
10/06/08 18:23:19 (5 years ago)
Author:
MDMAN
Message:

racing.league modified

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • racing.league/files/lib/form/RacingLeagueRacesForm.class.php

    r656 r680  
    1616        public $templateName = 'racingLeagueRaces'; 
    1717        public $saisonID = 0; 
    18         public $new = 0; 
     18        public $newRaces = 0; 
    1919        public $edit = 0; 
    2020        public $race = ''; 
     
    3434                parent::readParameters(); 
    3535 
    36                 if (isset($_REQUEST["saisonID"]))               $this->saisonID = intval($_REQUEST["saisonID"]);         
    37                 if (isset($_REQUEST["new"]))            $this->new = intval($_REQUEST["new"]); 
     36                if (isset($_REQUEST["saisonID"]))       $this->saisonID = intval($_REQUEST["saisonID"]);         
     37                if (isset($_REQUEST["newRaces"]))       $this->newRaces = intval($_REQUEST["newRaces"]); 
    3838                if (isset($_REQUEST["edit"]))           $this->edit = intval($_REQUEST["edit"]); 
    3939                if (isset($_REQUEST["raceID"]))         $this->raceID = intval($_REQUEST["raceID"]); 
     
    5656                parent::validate(); 
    5757 
    58                 // race bei NEW 
    59                 if ($this->new == 1) { 
     58                // race bei newRaces 
     59                if ($this->newRaces == 1) { 
    6060                        if (empty($this->race)) { 
    61                                 $this->new = '1'; 
     61                                $this->newRaces = '1'; 
    6262                                throw new UserInputException('race'); 
    6363                        } 
     
    8484 
    8585                // Hier wird die Anzahl der vorhandenen Renntage ermittelt 
    86                 if ($this->new == 1) { 
     86                if ($this->newRaces == 1) { 
    8787 
    8888                        $sql = "SELECT * 
     
    141141                 
    142142                // Hier wird ein neuer Renntag gespeichert 
    143                 if ($this->race && $this->activeSaisonID != 0 && $this->new == 1) { 
     143                if ($this->race && $this->activeSaisonID != 0 && $this->newRaces == 1) { 
    144144                         
    145145                        $sql = "INSERT INTO wcf".WCF_N."_racing_races (saisonID, raceID, raceNo, racename) 
     
    150150                        $row = 0; 
    151151                        $row = WCF::getDB()->getAffectedRows($res); 
    152                         $this->new = 0; 
     152                        $this->newRaces = 0; 
    153153                        if ($row > 0) {                          
    154154                                WCF::getTPL()->append('userMessages', WCF::getTPL()->fetch('racingLeagueNewSuccess')); 
     
    191191                WCF::getTPL()->assign(array( 
    192192                        'saisonID' => $this->saisonID, 
    193                         'new' => $this->new, 
     193                        'newRaces' => $this->newRaces, 
    194194                        'edit' => $this->edit, 
    195195                        'race' => $this->race,