Ignore:
Timestamp:
Jul 24, 2009, 11:39:21 AM (15 years ago)
Author:
maron
Message:

Plánované úkoly stahování dbc zatím pouze admin

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/export/export.php

    r234 r255  
    281281  {
    282282        echo($Group['Name'].'... ');
    283     $DBCFile = new DBCFile();
    284     $DBCFile->OpenFile('../source/'.$Setting['Version'].'/dbc/'.$Group['DBCFileName'].'.dbc', GetDBCColumns($Setting['Version'],$Group['DBCFileName']));
     283  //  $DBCFile = new DBCFile();
     284  //  $DBCFile->OpenFile('../source/'.$Setting['Version'].'/dbc/'.$Group['DBCFileName'].'.dbc', GetDBCColumns($Setting['Version'],$Group['DBCFileName']));
     285    if (copy('../source/'.$Setting['Version'].'/dbc/'.$Group['DBCFileName'].'.dbc',$TempDir.$Group['DBCFileName'].'.dbc') == false)
     286          die('Nepodařilo se zkopírovat');
    285287    $DBCFile2 = new DBCFile();
    286     $DBCFile2->CreateFile($TempDir.$Group['DBCFileName'].'.dbc', GetDBCColumns($Setting['Version'],$Group['DBCFileName']));
    287         $Count = $DBCFile->GetRecordCount();
     288    $DBCFile2->OpenFile($TempDir.$Group['DBCFileName'].'.dbc', GetDBCColumns($Setting['Version'],$Group['DBCFileName']));
     289        $Count = $DBCFile2->GetRecordCount();
    288290        //if($Group['DBCFileName'] == 'Spell') $Count = 1000;
    289         $Line = $DBCFile->GetLine(0);
     291        $Line = $DBCFile2->GetLine(0);
    290292    $DBCFile2->SetRecordCount($Count);   
    291293    for($I = 0; $I < $Count; $I++)
    292294    {
    293       $Line = $DBCFile->GetLine($I);
     295      $Line = $DBCFile2->GetLine($I);
    294296          $Query = 'SELECT * FROM (SELECT * FROM '.$Group['TablePrefix'].' WHERE (Complete = 1) AND '.$WhereLang.' AND '.$WhereUsers.' AND (entry='.$Line[0].')  AND VersionStart <= '.GetBuildNumber($Setting['Version']).' AND VersionEnd >= '.GetBuildNumber($Setting['Version']).' ORDER BY FIELD(User, '.$SelectedUsers.')) AS T GROUP BY T.entry';       
    295297          $DbResult = $Database->SQLCommand($Query);
Note: See TracChangeset for help on using the changeset viewer.