Ignore:
Timestamp:
Jun 18, 2013, 8:56:09 PM (12 years ago)
Author:
chronos
Message:
  • Upraveno: Část týkající se překládání přepracována na aplikační modul.
Location:
trunk/Modules/Translation
Files:
1 added
1 moved

Legend:

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

    r549 r550  
    11<?php
    22
    3 include('includes/global.php');
    4 
     3class PageTranslationList extends Page
     4{
    55function ShowFilter($GroupId = 0)
    66{
     
    134134  if($Filter['Text'] != '')
    135135  {
    136     $Items = array('(`ID` LIKE "%'.$Filter['Text'].'%")', '(`Entry` LIKE "%'.$Filter['Text'].'%")');
     136    $Items = array('(`T`.`ID` LIKE "%'.$Filter['Text'].'%")', '(`T`.`Entry` LIKE "%'.$Filter['Text'].'%")');
    137137    if($Filter['Group'] != 0)
    138138    foreach($TranslationTree[$Filter['Group']]['Items'] as $GroupItem)
    139139    if($GroupItem['Visible'] == 1)
    140       $Items[] = '(`'.$GroupItem['Column'].'` LIKE "%'.$Filter['Text'].'%")';
     140      $Items[] = '(`T`.`'.$GroupItem['Column'].'` LIKE "%'.$Filter['Text'].'%")';
    141141    $Filter['SQL'] .= ' AND ('.implode(' OR ', $Items).')';
    142142  }
     
    252252    if($Group['TablePrefix'] != '')
    253253    {
    254       $Filter = ShowFilter($Group['Id']);
     254      $Filter = $this->ShowFilter($Group['Id']);
    255255      $ID = $System->Database->query('SELECT COUNT(*) FROM `'.$Group['TablePrefix'].'` AS `T` WHERE 1 '.$Filter['SQL']);
    256256      $Line = $ID->fetch_row();
     
    376376}
    377377
    378 $Action = GetParameter('action', '');
    379 if($Action == 'filter') $Output = ShowMenu();
    380 else if($Action == 'grouplist') $Output = ShowGroupTypeList();
    381 else if($Action == 'groupadd') $Output = ShowGroupAdd();
    382 else if($Action == 'groupaddfinish') $Output = ShowGroupAddFinish();
    383 else
    384 {
    385   $Filter = ShowFilter();
    386   if($Filter['Group'] > 0) $Output = ShowTranslationList($Filter);
    387     else $Output = ShowGroupList($Filter);
     378function Show()
     379{
     380  $Action = GetParameter('action', '');
     381  if($Action == 'filter') $Output = $this->ShowMenu();
     382  else if($Action == 'grouplist') $Output = $this->ShowGroupTypeList();
     383  else if($Action == 'groupadd') $Output = $this->ShowGroupAdd();
     384  else if($Action == 'groupaddfinish') $Output = $this->ShowGroupAddFinish();
     385  else
     386  {
     387    $Filter = $this->ShowFilter();
     388    if($Filter['Group'] > 0) $Output = $this->ShowTranslationList($Filter);
     389      else $Output = $this->ShowGroupList($Filter);
     390  }
     391  return($Output);
    388392}   
    389 
    390 ShowPage($Output);
    391 
    392 ?>
     393}
Note: See TracChangeset for help on using the changeset viewer.