Changeset 717 for trunk/Modules/Download


Ignore:
Timestamp:
Jan 5, 2014, 5:27:18 PM (11 years ago)
Author:
maron
Message:
  • Added: order downloads export by version
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/Download/Download.php

    r716 r717  
    9090                $Output .= '<table class="BaseTable">';
    9191                $Output .= '<tr><th>Stáhnout</th><th>Název</th><th>Datum vytvoření</th><th>Popis</th></tr>';
    92                 $DbRows = $this->System->Database->query('SELECT *, (SELECT Version FROM `ClientVersion` WHERE `ClientVersion`.`Id`=`Export`.`ClientVersion`) AS `ClientVersion` FROM `Export` WHERE `Featured`=1');
     92                $DbRows = $this->System->Database->query('SELECT `ClientVersion`.`Version` as Version, `Export`.`Id`,`Export`.`ClientVersion`,`Export`.`OutputType`,`Export`.`Title`,`Export`.`Description` FROM `Export` JOIN `ClientVersion` as `ClientVersion` ON `ClientVersion`.`Id`=`Export`.`ClientVersion` WHERE `Featured`=1 ORDER BY `ClientVersion`.`BuildNumber` DESC');
    9393      while ($DbExport = $DbRows->fetch_assoc()) {
    94      
     94      //  echo $DbExport['BuildNumber'].'<br />';
    9595        $ExportId = $DbExport['Id'];
    9696                   
    97                     $filename = $System->Config['Web']['TempFolder'].'Export/'.$ExportId.'/'.'Instalace_CzechWoW_'.$DbExport['ClientVersion'].'.exe';
     97                    $filename = $System->Config['Web']['TempFolder'].'Export/'.$ExportId.'/'.'Instalace_CzechWoW_'.$DbExport['Version'].'.exe';
    9898                           
    9999                          if ($DbExport['OutputType'] == 10)
    100           $Output .= '<tr><td><a href="'.$System->Link('/'.$filename).'">CzechWoW_'.$DbExport['ClientVersion'].'.exe</a><br /> <a href="'.$System->Link('/export/?Action=View&amp;ExportId='.$ExportId).'">Export '.$ExportId.'</a></td>';
     100          $Output .= '<tr><td><a href="'.$System->Link('/'.$filename).'">CzechWoW_'.$DbExport['Version'].'.exe</a><br /> <a href="'.$System->Link('/export/?Action=View&amp;ExportId='.$ExportId).'">Export '.$ExportId.'</a></td>';
    101101        else
    102102          $Output .= '<tr><td><a href="'.$System->Link('/export/?Action=View&amp;ExportId='.$ExportId.'&amp;Tab=7').'">Exportovat</a><br /> <a href="'.$this->System->Link('/export/?Action=View&amp;ExportId='.$ExportId).'">Export '.$ExportId.'</a></td>';
Note: See TracChangeset for help on using the changeset viewer.