Changeset 76


Ignore:
Timestamp:
Aug 24, 2009, 8:53:09 PM (15 years ago)
Author:
george
Message:
  • Přidáno: Podpora pro oprávnění uživatelů a skupin.
  • Upraveno: V include souborech použita cesta aktuálního skriptu.
Location:
trunk/www
Files:
4 added
3 deleted
16 edited

Legend:

Unmodified
Added
Removed
  • trunk/www/Application/Config/ConfigSample.php

    r74 r76  
    3131    'UserAnonymousId' => 1,
    3232    'UserConsoleId' => 2,
     33    'Locale' => 'cz',
    3334  ),
    3435  'BaseDir' => '/opt/wowhosting/',
  • trunk/www/Application/Controller/Cluster.php

    r74 r76  
    66  {
    77    $Page = new PageView($this->System);
    8     $View = new ClusterView($this->System);
    9     return($Page->GetOutput($View->ItemList()));
     8    if($this->System->Modules['Permission']->Check('Cluster', 'ItemList'))
     9    {
     10      $View = new ClusterView($this->System);
     11      return($Page->GetOutput($View->ItemList()));
     12    } else return($Page->AccessDenied());
    1013  }   
    1114
     
    1316  {
    1417    $Page = new PageView($this->System);
    15     $View = new ClusterView($this->System);
    16     return($Page->GetOutput($View->Add()));
     18    if($this->System->Modules['Permission']->Check('Cluster', 'Add'))
     19    {
     20      $View = new ClusterView($this->System);
     21      return($Page->GetOutput($View->Add()));
     22    } else return($Page->AccessDenied());
    1723  }   
    1824
     
    2026  {
    2127    $Page = new PageView($this->System);
    22     $View = new ClusterView($this->System);
    23     return($Page->GetOutput($View->Restore()));
     28    if($this->System->Modules['Permission']->Check('Cluster', 'Remove'))
     29    {
     30      $View = new ClusterView($this->System);
     31      return($Page->GetOutput($View->Restore()));
     32    } else return($Page->AccessDenied());
    2433  }   
    2534 
     
    2736  {
    2837    $Page = new PageView($this->System);
    29     $View = new ClusterView($this->System);
    30     return($Page->GetOutput($View->Show()));
     38    if($this->System->Modules['Permission']->Check('Cluster', 'Show'))
     39    {
     40      $View = new ClusterView($this->System);
     41      return($Page->GetOutput($View->Show()));
     42    } else return($Page->AccessDenied());
    3143  }   
    3244
     
    3446  {
    3547    $Page = new PageView($this->System);
    36     $View = new ClusterView($this->System);
    37     return($Page->GetOutput($View->Edit()));
     48    if($this->System->Modules['Permission']->Check('Cluster', 'Edit'))
     49    {
     50      $View = new ClusterView($this->System);
     51      return($Page->GetOutput($View->Edit()));
     52    } else return($Page->AccessDenied());
    3853  }   
    3954}
  • trunk/www/Application/Controller/HomePage.php

    r73 r76  
    66  {
    77    $Page = new PageView($this->System);
    8     $View = new HomePageView($this->System);
    9     return($Page->GetOutput($View->Welcome()));
     8    if($this->System->Modules['Permission']->Check('HomePage', 'Show'))
     9    {
     10      $View = new HomePageView($this->System);
     11      return($Page->GetOutput($View->Welcome()));
     12    } else return($Page->AccessDenied());
    1013  }
    1114 
     
    1316  {
    1417    $Page = new PageView($this->System);
    15     $View = new HomePageView($this->System);
    16     return($Page->GetOutput($View->Info()));
     18    if($this->System->Modules['Permission']->Check('HomePage', 'Info'))
     19    {
     20      $View = new HomePageView($this->System);
     21      return($Page->GetOutput($View->Info()));
     22    } else return($Page->AccessDenied());
    1723  }
    1824
     
    2026  {
    2127    $Page = new PageView($this->System);
    22     $View = new HomePageView($this->System);
    23     return($Page->GetOutput($View->State()));
     28    if($this->System->Modules['Permission']->Check('HomePage', 'State'))
     29    {
     30      $View = new HomePageView($this->System);
     31      return($Page->GetOutput($View->State()));
     32    } else return($Page->AccessDenied());
    2433  }
    2534}
  • trunk/www/Application/Controller/Include.php

    r74 r76  
    11<?php
    22
    3 include('Application/Controller/HomePage.php');
    4 include('Application/Controller/Realm.php');
    5 include('Application/Controller/Server.php');
    6 include('Application/Controller/User.php');
    7 include('Application/Controller/Client.php');
    8 include('Application/Controller/Emulator.php');
    9 include('Application/Controller/Task.php');
    10 include('Application/Controller/News.php');
    11 include('Application/Controller/Debug.php');
    12 include('Application/Controller/Backup.php');
    13 include('Application/Controller/Cluster.php');
     3include(dirname(__FILE__).'/HomePage.php');
     4include(dirname(__FILE__).'/Realm.php');
     5include(dirname(__FILE__).'/Server.php');
     6include(dirname(__FILE__).'/User.php');
     7include(dirname(__FILE__).'/Client.php');
     8include(dirname(__FILE__).'/Emulator.php');
     9include(dirname(__FILE__).'/Task.php');
     10include(dirname(__FILE__).'/News.php');
     11include(dirname(__FILE__).'/Debug.php');
     12include(dirname(__FILE__).'/Backup.php');
     13include(dirname(__FILE__).'/Cluster.php');
    1414
    1515?>
  • trunk/www/Application/Controller/User.php

    r71 r76  
    1414    $Page = new PageView($this->System);
    1515    $View = new UserView($this->System);
    16     return($Page->GetOutput($View->Loginfinish()));
     16    return($Page->GetOutput($View->LoginFinish()));
    1717  } 
    1818
  • trunk/www/Application/Include.php

    r75 r76  
    11<?php
    22
    3 include('Application/CustomTypes.php');
     3include(dirname(__FILE__).'/CustomTypes.php');
    44
    5 if(file_exists('Application/Config/Config.php')) include('Application/Config/Config.php');
    6   else die('Nenalezen soubor Application/Config/Config.php. Vytvořte jej kopií ze souboru Application/Config/ConfigSample.php.');
     5if(file_exists(dirname(__FILE__).'/Config/Config.php')) include(dirname(__FILE__).'/Config/Config.php');
     6  else die('Nenalezen soubor '.dirname(__FILE__).'/Config/Config.php. Vytvořte jej kopií ze souboru '.dirname(__FILE__).'/Config/ConfigSample.php.');
    77 
    8 if(file_exists('Application/Localization/'.$Config['Web']['Locale'].'.php')
    9   include('Application/Localization/'.$Config['Web']['Locale'].'.php');
    10   else die('Nenalezen soubor Application/Localization/'.$Config['Web']['Locale'].'.php. Buď máte špatně nastaven jazyk nebo vám chybí jazykový soubor.');
     8if(file_exists(dirname(__FILE__).'/Localization/'.$Config['Web']['Locale'].'.php'))
     9  include(dirname(__FILE__).'/Localization/'.$Config['Web']['Locale'].'.php');
     10  else die('Nenalezen soubor '.dirname(__FILE__).'/Localization/'.$Config['Web']['Locale'].'.php. Buď máte špatně nastaven jazyk nebo vám chybí jazykový soubor.');
    1111
    12 include('Application/Model/Include.php');
    13 include('Application/View/Include.php');
    14 include('Application/Controller/Include.php');
     12include(dirname(__FILE__).'/Model/Include.php');
     13include(dirname(__FILE__).'/View/Include.php');
     14include(dirname(__FILE__).'/Controller/Include.php');
    1515
    1616?>
  • trunk/www/Application/Model/Include.php

    r74 r76  
    11<?php
    22
    3 include('Application/Model/User.php');
    4 include('Application/Model/Server.php');
    5 include('Application/Model/Realm.php');
    6 include('Application/Model/Emulator.php');
    7 include('Application/Model/MangosConfigurationFile.php');
    8 include('Application/Model/MangosDebug.php');
    9 include('Application/Model/Task.php');
    10 include('Application/Model/Backup.php');
    11 include('Application/Model/Platform.php');
    12 include('Application/Model/History.php');
     3include(dirname(__FILE__).'/User.php');
     4include(dirname(__FILE__).'/Server.php');
     5include(dirname(__FILE__).'/Realm.php');
     6include(dirname(__FILE__).'/Emulator.php');
     7include(dirname(__FILE__).'/MangosConfigurationFile.php');
     8include(dirname(__FILE__).'/MangosDebug.php');
     9include(dirname(__FILE__).'/Task.php');
     10include(dirname(__FILE__).'/Backup.php');
     11include(dirname(__FILE__).'/Platform.php');
     12include(dirname(__FILE__).'/History.php');
     13include(dirname(__FILE__).'/Permission.php');
     14include(dirname(__FILE__).'/Log.php');
    1315
    1416?>
  • trunk/www/Application/View/Cluster.php

    r74 r76  
    2828    $Table->LoadValuesFromDatabase($this->Database);
    2929    $Output .= $Table->Show();
    30     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR)
    31     {
    32       //$Output .= '<br /><div style="text-align: center;"><a href="?Action=BackupAdd">Zálohovat</a></dev>';     
    33     }
    3430    return($Output);
    3531  }
  • trunk/www/Application/View/Include.php

    r74 r76  
    11<?php
    22
    3 include('Application/View/Page.php');
    4 include('Application/View/HomePage.php');
    5 include('Application/View/User.php');
    6 include('Application/View/Server.php');
    7 include('Application/View/Realm.php');
    8 include('Application/View/Emulator.php');
    9 include('Application/View/Task.php');
    10 include('Application/View/Backup.php');
    11 include('Application/View/Update.php');
    12 include('Application/View/Database.php');
    13 include('Application/View/News.php');
    14 include('Application/View/Client.php');
    15 include('Application/View/Debug.php');
    16 include('Application/View/Cluster.php');
     3include(dirname(__FILE__).'/Page.php');
     4include(dirname(__FILE__).'/HomePage.php');
     5include(dirname(__FILE__).'/User.php');
     6include(dirname(__FILE__).'/Server.php');
     7include(dirname(__FILE__).'/Realm.php');
     8include(dirname(__FILE__).'/Emulator.php');
     9include(dirname(__FILE__).'/Task.php');
     10include(dirname(__FILE__).'/Backup.php');
     11include(dirname(__FILE__).'/Update.php');
     12include(dirname(__FILE__).'/Database.php');
     13include(dirname(__FILE__).'/News.php');
     14include(dirname(__FILE__).'/Client.php');
     15include(dirname(__FILE__).'/Debug.php');
     16include(dirname(__FILE__).'/Cluster.php');
    1717
    1818?>
  • trunk/www/Application/View/Page.php

    r74 r76  
    3535    ' <a href="?Module=Emulator&amp;Action=ItemList">Verze emulátoru</a>'.
    3636    '</span><div class="MenuItem2">';
    37     if($this->System->Modules['User']->User['Id'] == $this->Config['Web']['UserAnonymousId'])
     37    if($this->System->Modules['User']->Data['Id'] == $this->Config['Web']['UserAnonymousId'])
    3838    {
    3939      $Output .= '<a href="'.$this->System->Config['Web']['RootFolder'].'/?Module=User&amp;Action=Login">Přihlášení</a>';
    4040      if($this->Config['Web']['UserRegistrationEnabled']) $Output .= ' <a href="'.$this->System->Config['Web']['RootFolder'].'/?Module=User&amp;Action=Register">Registrace</a>';
    41     } else $Output .= $this->System->Modules['User']->User['Name'].' <a href="'.$this->Config['Web']['RootFolder'].'/?Module=User&amp;Action=Logout">Odhlásit</a>'.
     41    } else $Output .= $this->System->Modules['User']->Data['Name'].' <a href="'.$this->Config['Web']['RootFolder'].'/?Module=User&amp;Action=Logout">Odhlásit</a>'.
    4242       ' <a href="'.$this->Config['Web']['RootFolder'].'/?Module=User&amp;Action=Options">Nastavení</a>';
    4343    $Output .= '</div></div>';
     
    6464  {
    6565    $Output = '<table class="BasicTable"><tr>';
    66     if($this->System->Modules['User']->User['Id'] != $this->Config['Web']['UserAnonymousId'])
     66    if($this->System->Modules['User']->Data['Id'] != $this->Config['Web']['UserAnonymousId'])
    6767      $Output .= '<td class="UserMenu">'.$this->UserMenu().'</td>';
    6868    $Output .= '<td class="Content">'.$Content.'</td>';
     
    7979  {   
    8080    $Output = '<strong>Uživatelské menu</strong><br />';
    81     if($this->System->Modules['User']->User['Id'] != $this->Config['Web']['UserAnonymousId'])
     81    if($this->System->Modules['User']->Data['Id'] != $this->Config['Web']['UserAnonymousId'])
    8282    {
    8383      $Output .= '<div><a href="?Module=Cluster&amp;Action=ItemList">Uzly skupiny</a></div>';
     
    8989      //$Output .= '<div><a href="?Action=UpdateList&amp;Id='.$Server['Id'].'">Dostupné aktualizace</a></div>';
    9090
    91       if($this->System->Modules['User']->User['Role'] == USER_ROLE_ADMINISTRATOR)
     91      if($this->System->Modules['Permission']->CheckPermission('News', 'Add'))
    9292      {
    9393        $Output .= '<div><a href="?Module=News&amp;Action=Add">Přidat aktualitu</a></div>';
     
    107107    else echo($Output);
    108108  }
     109
     110  function SystemMessage($Text)
     111  {
     112    return('<table align="center"><tr><td><div class="SystemMessage"><h3>Systémová zpráva</h3><div>'.$Text.'</div></div</td></tr></table>');
     113    //ShowFooter();
     114    //die();
     115  }
     116 
     117  function AccessDenied()
     118  {
     119    return($this->GetOutput($this->SystemMessage($this->System->Translate('AccessDenied')))); 
     120  }
    109121}
    110122
  • trunk/www/Application/View/Server.php

    r73 r76  
    8989    {
    9090      if($_GET['Filter'] == 'User')
    91         $Table->Definition['Table'] = substr($Table->Definition['Table'], 0, -1).' WHERE User='.$this->System->Modules['User']->User['Id'].')';
     91        $Table->Definition['Table'] = substr($Table->Definition['Table'], 0, -1).' WHERE User='.$this->System->Modules['User']->Data['Id'].')';
    9292    }
    9393    $Table->OnRow = array($this, 'ShowListOnRow');
     
    101101    }
    102102    $Output .= $Table->Show();
    103     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER)
     103    if($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER)
    104104    {
    105105      $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server');
    106106      $DbRow = $DbResult->fetch_row();
    107107      $ServerCount = $DbRow[0];
    108       $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->User['Id']);
     108      $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->Data['Id']);
    109109      $DbRow = $DbResult->fetch_row();
    110110      if(($ServerCount < $Config['MaxServerCount']) and ($DbRow[0] < $Config['MaxServerCountPerUser']))
     
    137137    $Output .= $Form->ShowTable();
    138138    $Output .= '<div style="text-align: center">';
    139     if((($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER) and ($this->System->Modules['User']->User['Id'] == $Server->Server['User'])) or ($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR))
     139    if((($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER) and ($this->System->Modules['User']->Data['Id'] == $Server->Server['User'])) or ($this->System->Modules['User']->Data['Role'] >= USER_ROLE_ADMINISTRATOR))
    140140    {
    141141      $Output .= '<br /><a href="http://'.$this->System->Config['Web']['Host'].'/mysql/">Správa databáze</a> ';
     
    168168   
    169169    $Output = '';
    170     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER)
     170    if($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER)
    171171    {
    172172      $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server');
     
    175175      if($ServerCount < $Config['MaxServerCount'])
    176176      {
    177         $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->User['Id']);
     177        $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->Data['Id']);
    178178        $DbRow = $DbResult->fetch_row();
    179179        if($DbRow[0] >= $Config['MaxServerCountPerUser']) $Output .= $this->System->SystemMessage('Nový server', 'Na jeden účet lze vytvořit maximálně '.$Config['MaxServerCountPerUser'].' serverů');
     
    196196   
    197197    $Output = '';
    198     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER)
    199     {
    200       $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->User['Id']);
     198    if($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER)
     199    {
     200      $DbResult = $this->Database->query('SELECT COUNT(*) FROM Server WHERE User='.$this->System->Modules['User']->Data['Id']);
    201201      $DbRow = $DbResult->fetch_row();
    202202      if($DbRow[0] >= $Config['MaxServerCountPerUser']) $Output .= $this->System->SystemMessage('Nový server', 'Na jeden účet lze vytvořit maximálně '.$Config['MaxServerCountPerUser'].' serverů');
     
    210210        $Form = new Form($this->System, $this->CreateFormClass, array());
    211211        $Form->LoadValuesFromForm();
    212         $this->Database->insert('Server', array('Name' => $Form->Values['Name'], 'Description' => $Form->Values['Description'], 'User' => $this->System->Modules['User']->User['Id'], 'Homepage' => $Form->Values['Homepage'], 'Database' => $Form->Values['Database'], 'NetworkPortRealmd' => $NewPortRealmd, 'Lock' => 1, 'TimeCreate' => 'NOW()'));
     212        $this->Database->insert('Server', array('Name' => $Form->Values['Name'], 'Description' => $Form->Values['Description'], 'User' => $this->System->Modules['User']->Data['Id'], 'Homepage' => $Form->Values['Homepage'], 'Database' => $Form->Values['Database'], 'NetworkPortRealmd' => $NewPortRealmd, 'Lock' => 1, 'TimeCreate' => 'NOW()'));
    213213        $LastInsertId = $this->Database->insert_id;
    214214        $Server = new Server($this->Database, $LastInsertId);
     
    229229    $Output = '';
    230230    $Server = new Server($this->Database, $_POST['ServerId']);
    231     if(($this->System->Modules['User']->User['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR))
     231    if(($this->System->Modules['User']->Data['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->Data['Role'] >= USER_ROLE_ADMINISTRATOR))
    232232    {
    233233      $Form = new Form($this->System, $this->EditFormClass, array());
     
    251251    $Output = '';
    252252    $Server = new Server($this->Database, $_GET['Id']);
    253     if(($this->System->Modules['User']->User['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR))
     253    if(($this->System->Modules['User']->Data['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->Data['Role'] >= USER_ROLE_ADMINISTRATOR))
    254254    {
    255255      $Form = new Form($this->System, $this->EditFormClass);
     
    265265  {
    266266    $Output = '';
    267     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER)
     267    if($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER)
    268268    {
    269269      $Server = new Server($this->Database, $_GET['Id']);
    270       if(($this->System->Modules['User']->User['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR))
     270      if(($this->System->Modules['User']->User['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->Data['Role'] >= USER_ROLE_ADMINISTRATOR))
    271271      {
    272272        $Output .= $this->System->SystemMessage('Spuštění serveru', $Server->Start());
     
    281281  {
    282282    $Output = '';
    283     if($this->System->Modules['User']->User['Role'] >= USER_ROLE_USER)
     283    if($this->System->Modules['User']->Data['Role'] >= USER_ROLE_USER)
    284284    {
    285285      $Server = new Server($this->Database, $_GET['Id']);
    286       if(($this->System->Modules['User']->User['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->User['Role'] >= USER_ROLE_ADMINISTRATOR))
     286      if(($this->System->Modules['User']->Data['Id'] == $Server->Server['User']) or ($this->System->Modules['User']->Data['Role'] >= USER_ROLE_ADMINISTRATOR))
    287287      {
    288288        $Output .= $this->System->SystemMessage('Zastavení serveru', $Server->Stop());
  • trunk/www/Application/View/User.php

    r71 r76  
    7070    $Result = $this->System->Modules['User']->Login($Form->Values['Username'], $Form->Values['Password']);
    7171    $Output = $this->System->SystemMessage('Přihlášení', $Result);
    72     if($Result <> USER_LOGGED_IN)
     72    if($Result <> $this->System->Translate('UserLoggedIn'))
    7373    {
    7474      $Form->Values['Password'] = '';
     
    9090      $Result = $this->System->Modules['User']->Register($Form->Values['Login'], $Form->Values['Password'], $Form->Values['Password2'], $Form->Values['Email'], $Form->Values['Name']);
    9191      $Output = $this->System->SystemMessage('Registrace nového účtu', $Result);
    92       if($Result <> USER_REGISTRATED)
     92      if($Result <> $this->System->Translate('UserRegistrated'))
    9393      {
    9494        $Form->OnSubmit = '?Module=User&amp;Action=UserRegisterSave';
     
    112112    $Result = $this->System->Modules['User']->PasswordRecoveryRequest($Form->Values['Name'], $Form->Values['Email']);
    113113    $Output = $this->System->SystemMessage('Obnova hesla', $Result);
    114     if($Result <> USER_PASSWORD_RECOVERY_SUCCESS)
     114    if($Result <> $this->System->Translate('UserPasswordRecoverySuccess'))
    115115    {
    116116      $Output .= $Form->ShowEditForm();
  • trunk/www/Base/Include.php

    r75 r76  
    11<?php
    22
    3 include('Base/Module.php');
    4 include('Base/Error.php');
    5 include('Base/Database.php');
    6 include('Base/UTF8.php');
    7 include('Base/System.php');
    8 include('Base/Global.php');
    9 include('Base/Html.php');
    10 include('Base/Model.php');
    11 include('Base/Controller.php');
    12 include('Base/View.php');
    13 include('Base/Table.php');
    14 include('Base/List.php');
    15 include('Base/Form.php');
    16 include('Base/Log.php');
    17 include('Base/Types/Include.php');
     3include(dirname(__FILE__).'/Module.php');
     4include(dirname(__FILE__).'/Error.php');
     5include(dirname(__FILE__).'/Database.php');
     6include(dirname(__FILE__).'/UTF8.php');
     7include(dirname(__FILE__).'/System.php');
     8include(dirname(__FILE__).'/Global.php');
     9include(dirname(__FILE__).'/Html.php');
     10include(dirname(__FILE__).'/Model.php');
     11include(dirname(__FILE__).'/Controller.php');
     12include(dirname(__FILE__).'/View.php');
     13include(dirname(__FILE__).'/Table.php');
     14include(dirname(__FILE__).'/List.php');
     15include(dirname(__FILE__).'/Form.php');
     16include(dirname(__FILE__).'/Log.php');
     17include(dirname(__FILE__).'/Types/Include.php');
    1818
    1919?>
  • trunk/www/Base/System.php

    r75 r76  
    9898  }
    9999 
    100   function SystemMessage($Title, $Text)
    101   {
    102     return('<table align="center"><tr><td><div class="SystemMessage"><h3>'.$Title.'</h3><div>'.$Text.'</div></div</td></tr></table>');
    103     //ShowFooter();
    104     //die();
    105   }
    106 
    107100  function MailUTF8($To, $Subject = '(No subject)', $Message = '', $Header = '')
    108101  {
  • trunk/www/Base/Types/Include.php

    r71 r76  
    11<?php
    22
    3 include('Base/Types/Base.php');
    4 include('Base/Types/Enumeration.php');
    5 include('Base/Types/Boolean.php');
    6 include('Base/Types/Integer.php');
    7 include('Base/Types/String.php');
    8 include('Base/Types/Text.php');
    9 include('Base/Types/PointerOneToMany.php');
    10 include('Base/Types/PointerOneToOne.php');
    11 include('Base/Types/Date.php');
    12 include('Base/Types/Time.php');
    13 include('Base/Types/DateTime.php');
    14 include('Base/Types/Password.php');
    15 include('Base/Types/Float.php');
    16 include('Base/Types/Hyperlink.php');
    17 include('Base/Types/Hidden.php');
    18 include('Base/Types/File/File.php');
    19 include('Base/Types/GPS.php');
    20 include('Base/Types/IPv4Address.php');
     3include(dirname(__FILE__).'/Base.php');
     4include(dirname(__FILE__).'/Enumeration.php');
     5include(dirname(__FILE__).'/Boolean.php');
     6include(dirname(__FILE__).'/Integer.php');
     7include(dirname(__FILE__).'/String.php');
     8include(dirname(__FILE__).'/Text.php');
     9include(dirname(__FILE__).'/PointerOneToMany.php');
     10include(dirname(__FILE__).'/PointerOneToOne.php');
     11include(dirname(__FILE__).'/Date.php');
     12include(dirname(__FILE__).'/Time.php');
     13include(dirname(__FILE__).'/DateTime.php');
     14include(dirname(__FILE__).'/Password.php');
     15include(dirname(__FILE__).'/Float.php');
     16include(dirname(__FILE__).'/Hyperlink.php');
     17include(dirname(__FILE__).'/Hidden.php');
     18include(dirname(__FILE__).'/File/File.php');
     19include(dirname(__FILE__).'/GPS.php');
     20include(dirname(__FILE__).'/IPv4Address.php');
    2121
    2222$TypeDefinitionList = array(
  • trunk/www/index.php

    r74 r76  
    1919$System->AddModule(new Log($System));
    2020$System->AddModule(new User($System));
     21$System->AddModule(new Permission($System));
    2122if(isset($_SERVER['REMOTE_ADDR'])) $System->Modules['User']->Check();
    22   else $System->Modules['User']->User['Id'] = $Config['Web']['UserConsoleId'];
     23  else $System->Modules['User']->Data['Id'] = $Config['Web']['UserConsoleId'];
     24$System->Modules['Permission']->LoadForUser($System->Modules['User']->Data['Id']);
     25print_r($System->Modules['Permission']->Data);
    2326
    2427if(array_key_exists('Module', $_GET)) $Module = $_GET['Module'];
Note: See TracChangeset for help on using the changeset viewer.