Ignore:
Timestamp:
Apr 7, 2020, 12:55:39 AM (5 years ago)
Author:
chronos
Message:
  • Modified: Improved code formatting.
File:
1 edited

Legend:

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

    r40 r55  
    3939    $this->Title = 'Tanec - Tance - '.$this->Title;
    4040    $Output = '';
    41     if(count($this->System->PathItems) > 1)
     41    if (count($this->System->PathItems) > 1)
    4242    {
    4343      $id = $this->System->PathItems[1] * 1;
     
    6060    $Output .= '<tr><th>Český název</th><th>Anglický název</th><th>Detail</th></tr>';
    6161    $DbResult = $this->Database->select('DanceFigure', '*', '(`Dance`='.$id.')');
    62     while($DanceFigure = $DbResult->fetch_assoc())
     62    while ($DanceFigure = $DbResult->fetch_assoc())
    6363    {
    6464      $Output .= '<tr>'.
     
    7474    $Output .= '<tr><th>Název</th><th>Skupina</th><th>Odkaz</th></tr>';
    7575    $DbResult = $this->Database->select('Resource', '*, (SELECT Name FROM ResourceGroup WHERE ResourceGroup.Id=Resource.Group) AS GroupName', '(`Dance`='.$id.')');
    76     while($DbRow = $DbResult->fetch_assoc())
     76    while ($DbRow = $DbResult->fetch_assoc())
    7777    {
    7878      $Output .= '<tr>'.
     
    8686      /*
    8787          $DbResult2 = $this->Database->select('ResourceGroup', '*');
    88     while($ResourceGroup = $DbResult2->fetch_assoc())
     88    while ($ResourceGroup = $DbResult2->fetch_assoc())
    8989    {
    9090      $Output .= '<th>'.$ResourceGroup['Name'].'</th>';
     
    9292
    9393      $DbResult2 = $this->Database->select('ResourceGroup', '*');
    94       while($ResourceGroup = $DbResult2->fetch_assoc())
     94      while ($ResourceGroup = $DbResult2->fetch_assoc())
    9595      {
    9696        $Output .= '<td>';
    97         while($Resource = $DbResult3->fetch_assoc())
     97        while ($Resource = $DbResult3->fetch_assoc())
    9898        {
    9999          $Output .= '<a href="'.$Resource['URL'].'">'.$Resource['Name'].'</a> ';
     
    122122    $Output .= '<tr><th>Název</th><th>Skupina</th><th>Detail</th></tr>';
    123123    $DbResult = $this->Database->select('Dance', '*, (SELECT Name FROM DanceGroup WHERE DanceGroup.Id=Dance.Group) AS GroupName', '1 ORDER BY `Name`');
    124     while($Dance = $DbResult->fetch_assoc())
     124    while ($Dance = $DbResult->fetch_assoc())
    125125    {
    126126      $Output .= '<tr>'.
     
    132132    $Output .= '</table>';
    133133
    134     return($Output);
     134    return $Output;
    135135  }
    136136}
     
    149149    $this->Title = 'Taneční figura - Tance - '.$this->Title;
    150150    $Output = '';
    151     if(count($this->System->PathItems) > 1)
     151    if (count($this->System->PathItems) > 1)
    152152    {
    153153      $id = $this->System->PathItems[1] * 1;
     
    169169    $Output .= '<tr><th>Skupina videí</th><th></th><th>Detail</th></tr>';
    170170    $DbResult = $this->Database->select('DanceFigure', '*', '(`Dance`='.$id.')');
    171     while($DanceFigure = $DbResult->fetch_assoc())
     171    while ($DanceFigure = $DbResult->fetch_assoc())
    172172    {
    173173      $Output .= '<tr>'.
     
    181181      /*
    182182          $DbResult2 = $this->Database->select('ResourceGroup', '*');
    183     while($ResourceGroup = $DbResult2->fetch_assoc())
     183    while ($ResourceGroup = $DbResult2->fetch_assoc())
    184184    {
    185185      $Output .= '<th>'.$ResourceGroup['Name'].'</th>';
     
    187187
    188188      $DbResult2 = $this->Database->select('ResourceGroup', '*');
    189       while($ResourceGroup = $DbResult2->fetch_assoc())
     189      while ($ResourceGroup = $DbResult2->fetch_assoc())
    190190      {
    191191        $Output .= '<td>';
    192         while($Resource = $DbResult3->fetch_assoc())
     192        while ($Resource = $DbResult3->fetch_assoc())
    193193        {
    194194          $Output .= '<a href="'.$Resource['URL'].'">'.$Resource['Name'].'</a> ';
     
    217217    $Output .= '<tr><th>Název</th><th>Skupina</th><th>Tanec</th><th>Detail</th></tr>';
    218218    $DbResult = $this->Database->select('DanceFigure', '*, (SELECT Dance.Name FROM Dance WHERE Dance.Id=DanceFigure.Dance) AS DanceName', '1 ORDER BY `NameCz`');
    219     while($DbRow = $DbResult->fetch_assoc())
     219    while ($DbRow = $DbResult->fetch_assoc())
    220220    {
    221221      $Output .= '<tr>'.
     
    228228    $Output .= '</table>';
    229229
    230     return($Output);
    231   }
    232 }
     230    return $Output;
     231  }
     232}
Note: See TracChangeset for help on using the changeset viewer.