Changeset 415 for trunk/index.php
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:ignore
-
old new 6 6 postfixadmin 7 7 backup 8 .project 9 .buildpath 10 .settings
-
- Property svn:ignore
-
trunk/index.php
r305 r415 9 9 var $ShortTitle = ''; 10 10 11 function ShowLinks($GroupId) 12 { 13 global $Database; 14 15 $DbResult = $Database->query('SELECT * FROM `HyperlinkGroup` WHERE `Id`='.$GroupId); 16 $HyperlinkGroup = $DbResult->fetch_assoc(); 17 11 function ShowLinks($HyperlinkGroup) 12 { 18 13 $Output = ''; 19 $DbResult = $ Database->query('SELECT * FROM `Hyperlink` WHERE (`Group`='.$GroupId.') AND (`Enable` = 1)');14 $DbResult = $this->Database->query('SELECT * FROM `Hyperlink` WHERE (`Group`='.$HyperlinkGroup['Id'].') AND (`Enable` = 1)'); 20 15 while($HyperLink = $DbResult->fetch_assoc()) 21 16 { 22 17 if($HyperLink['IconFile'] == '') $HyperLink['IconFile'] = 'clear.png'; 23 18 if(substr($HyperLink['URL'], 0, 4) != 'http') $HyperLink['URL'] = $this->System->Config['Web']['RootFolder'].$HyperLink['URL']; 24 if(($HyperLink['PermissionModule'] == '') or (($HyperLink['PermissionModule'] != '') and $this->System->Modules['User']-> CheckPermission($HyperLink['PermissionModule'], $HyperLink['PermissionOperation'])))19 if(($HyperLink['PermissionModule'] == '') or (($HyperLink['PermissionModule'] != '') and $this->System->Modules['User']->Models['User']->CheckPermission($HyperLink['PermissionModule'], $HyperLink['PermissionOperation']))) 25 20 $Output .= '<img alt="'.$HyperLink['Name'].'" src="images/favicons/'.$HyperLink['IconFile'].'" width="16" height="16" /> <a href="'.$HyperLink['URL'].'">'.$HyperLink['Name'].'</a><br />'; 26 21 } … … 63 58 if($this->System->Modules['User']->CheckPermission('Finance', 'DisplaySubjectState')) 64 59 { 65 $DbResult = $this->Database->select(' Subject', 'Money', 'Id=(SELECT Subject FROM Member WHERE Id=(SELECT Member FROM User WHERE Id='.$this->System->Modules['User']->User['Id'].'))');60 $DbResult = $this->Database->select('MemberPayment', 'Cash', 'Member=(SELECT Customer FROM UserCustomerRel WHERE Id='.$this->System->Modules['User']->User['Id'].')'); 66 61 if($DbResult->num_rows > 0) 67 62 { 68 63 $DbRow = $DbResult->fetch_assoc(); 69 $Output2 .= ' <img alt="" src="images/favicons/money.png" width="16" height="16" /> '.$DbRow[' Money'].' Kč';64 $Output2 .= ' <img alt="" src="images/favicons/money.png" width="16" height="16" /> '.$DbRow['Cash'].' Kč'; 70 65 } 71 66 } … … 273 268 $Database->select_db($Config['Database']['Database']); 274 269 270 $DbResult = $Database->query('SELECT * FROM `HyperlinkGroup`'); 271 while($DbRow = $DbResult->fetch_assoc()) 272 $HyperlinkGroups[$DbRow['Id']] = $DbRow; 273 275 274 // Show pannels 276 275 //if(IsInternetAddr()) echo('Internet'); else echo('LAN'); 277 //$Output .= $this->InfoBar();276 $Output .= $this->InfoBar(); 278 277 $Output .= '<table id="MainTable"><tr>'; 279 278 $DbResult = $Database->select('PanelColumn', '*'); … … 283 282 else $Width = ''; 284 283 $Output .= '<td valign="top"'.$Width.'>'; 285 $DbResult2 = $Database->query('SELECT * FROM 284 $DbResult2 = $Database->query('SELECT * FROM `Panel` WHERE `PanelColumn`='.$PanelColumn['Id'].' ORDER BY `Order`'); 286 285 while($Panel = $DbResult2->fetch_assoc()) 287 286 { 288 if($Panel['Module'] == 'HyperlinkGroup') $Output .= $this->ShowLinks($ Panel['Parameters']);287 if($Panel['Module'] == 'HyperlinkGroup') $Output .= $this->ShowLinks($HyperlinkGroups[$Panel['Parameters']]); 289 288 else if($Panel['Module'] == 'OnlineHostList') $Output .= $this->Panel('Online počítače', $this->OnlineHostList()); 290 289 else if($Panel['Module'] == 'UserOptions')
Note:
See TracChangeset
for help on using the changeset viewer.