Ignore:
Timestamp:
Jan 15, 2016, 10:24:05 PM (9 years ago)
Author:
chronos
Message:
  • Modified: Now translation groups are also localized.
  • Modified: Translated team page.
Location:
trunk/Modules/Translation
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/Translation/Progress.php

    r837 r846  
    5252      while($Group = $DbResult->fetch_assoc())
    5353      {
    54         $Output .= '<tr><td>'.$Group['Name'].'</td><td>'.$Group['Translated'].'</td><td>'.$Group['Total'].'</td><td>'.ProgressBar(150, $Group['Percent']).'</td></tr>';
     54        $Output .= '<tr><td>'.T($Group['Name']).'</td><td>'.$Group['Translated'].'</td><td>'.$Group['Total'].'</td><td>'.ProgressBar(150, $Group['Percent']).'</td></tr>';
    5555        $Translated += $Group['Translated'];
    5656        $Total += $Group['Total'];
     
    114114    if($Language['Enabled'] == 1)
    115115    {
    116       $Lang = ' <a href="?language='.$Language['Id'].'">'.$Language['Name'].'</a>';
     116      $Lang = ' <a href="?language='.$Language['Id'].'">'.T($Language['Name']).'</a>';
    117117      if($Language['Id'] == $_SESSION['language']) $Output .= '<strong>'.$Lang.'</strong> ';
    118118        else $Output .= $Lang;
     
    121121    if(is_numeric($_SESSION['language'])) $LanguageName = $LanguageList[$_SESSION['language']]['Name'];
    122122      else $LanguageName = T('All');
    123     $Output .= '<br/><br /><h3>'.sprintf(T('Statistics of translation completion of language %s for version %s'), $LanguageName, $_SESSION['StatVersion']).'</h3><br/>';
     123    $Output .= '<br/><br /><h3>'.sprintf(T('Statistics of translation completion of language %s for version %s'), T($LanguageName), $_SESSION['StatVersion']).'</h3><br/>';
    124124    $Output .= $this->ShowStatTable();
    125125
  • trunk/Modules/Translation/Translation.php

    r843 r846  
    1919    $this->License = 'GNU/GPL';
    2020    $this->Description = 'Translation of text items and groups from original language to other languages.';
    21     $this->Dependencies = array('News');
     21    $this->Dependencies = array('News', 'Search');
    2222  }
    2323
     
    4949      'Icon' => '',
    5050    ));
     51    /*
    5152    if(array_key_exists('Search', $this->System->ModuleManager->Modules))
    5253    {
     
    6263
    6364        $this->System->ModuleManager->Modules['Search']->RegisterSearch('group'.$Group['Id'],
    64         sprintf(T('Translation group "%s"'), $Group['Name']), $Columns, '`'.$Table.'`', $this->System->Link('/TranslationList.php?group='.
    65         $Group['Id'].'&amp;user=0&amp;state=0&amp;entry=&amp;text='));
     65          sprintf(T('Translation group "%s"'), $Group['Name']), $Columns, '`'.$Table.'`',
     66          $this->System->Link('/TranslationList.php?group='.
     67          $Group['Id'].'&amp;user=0&amp;state=0&amp;entry=&amp;text='));
    6668      }
    6769    }
     70    */
    6871  }
    6972
  • trunk/Modules/Translation/TranslationList.php

    r845 r846  
    5959      if($Filter['Group'] != 0)
    6060      {
    61         if(isset($TranslationTree[$Filter['Group']]) == false) ErrorMessage('Překladová skupina dle zadaného Id neexistuje.');
     61        if(isset($TranslationTree[$Filter['Group']]) == false)
     62          ErrorMessage('Překladová skupina dle zadaného Id neexistuje.');
    6263        $Table = $TranslationTree[$Filter['Group']]['TablePrefix'];
    6364      }
     
    7778      if($Group['Id'] == $Filter['Group']) $Selected = ' selected="selected"';
    7879      else $Selected = '';
    79       $Output .= '<option value="'.$Group['Id'].'"'.$Selected.'>'.$Group['Name'].'</option>';
     80      $Output .= '<option value="'.$Group['Id'].'"'.$Selected.'>'.T($Group['Name']).'</option>';
    8081    }
    8182    $Output .= '</select></td>';
     
    414415   while($Group = $DbResult->fetch_assoc())
    415416   {
    416      $Output .= '<tr><td><a href="'.$this->System->Link('/TranslationList.php?group='.$Group['Id'].'&amp;action=filter').'">'.$Group['Name'].'</a></td>'.
     417     $Output .= '<tr><td><a href="'.$this->System->Link('/TranslationList.php?group='.$Group['Id'].'&amp;action=filter').'">'.T($Group['Name']).'</a></td>'.
    417418       '<td>'.$Group['SourceType'].'</td><td>';
    418419     if($Group['MangosTable'] != '') $Output .= $Group['MangosTable'].'.sql ';
     
    503504    if($this->System->User->Licence(LICENCE_ADMIN))
    504505    {
    505       $DbResult = $this->System->Database->select('Group', '*', 'Id='.$_GET['id']);
     506      $DbResult = $this->System->Database->select('Group', '*', '`Id`='.$_GET['id']);
    506507      if($DbResult->num_rows == 1)
    507508      {
Note: See TracChangeset for help on using the changeset viewer.