Changeset 531
- Timestamp:
- Apr 23, 2013, 11:36:41 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Common/Form/Types/OneToMany.php
r530 r531 41 41 { 42 42 if($Item['Value'] == $DbRow['Id']) $Selected = ' selected="1"'; else $Selected = ''; 43 $Output .= '<option value="'.$DbRow['Id'].'"'.$Selected.'>'.$DbRow[' Id'].': '.$DbRow['Name'].'</option>';43 $Output .= '<option value="'.$DbRow['Id'].'"'.$Selected.'>'.$DbRow['Name'].'</option>'; 44 44 } 45 45 $Output .= '</select>'; -
trunk/Common/Version.php
r530 r531 1 1 <?php 2 2 3 $Revision = 53 0; // Subversion revision3 $Revision = 531; // Subversion revision 4 4 $DatabaseRevision = 527; // SQL structure revision 5 5 $ReleaseTime = '2013-04-23'; -
trunk/Modules/IS/IS.php
r530 r531 29 29 else if($Action == 'view') $Content = $this->ShowView($Table, $ItemId); 30 30 else if($Action == 'delete') $Content = $this->ShowDelete($Table, $ItemId); 31 else $Content = '';31 else $Content = $this->Dashboard(); 32 32 if($this->HideMenu == false) 33 33 { … … 39 39 } else $Output = $Content; 40 40 41 return($Output); 42 } 43 44 function Dashboard() 45 { 46 $Output = '<strong>Nástěnka:</strong><br/>'; 47 $DbResult = $this->Database->select('Task', 'COUNT(*)', 'Progress < 100'); 48 $DbRow = $DbResult->fetch_row(); 49 $Output .= 'Nedokončených úkolů: '.$DbRow['0'].'<br/>'; 50 $DbResult = $this->Database->select('Member', 'COUNT(*)', '1'); 51 $DbRow = $DbResult->fetch_row(); 52 $Output .= 'Zákazníků: '.$DbRow['0'].'<br/>'; 53 $DbResult = $this->Database->select('Subject', 'COUNT(*)', '1'); 54 $DbRow = $DbResult->fetch_row(); 55 $Output .= 'Subjektů: '.$DbRow['0'].'<br/>'; 56 $DbResult = $this->Database->select('User', 'COUNT(*)', '1'); 57 $DbRow = $DbResult->fetch_row(); 58 $Output .= 'Uživatelů: '.$DbRow['0'].'<br/>'; 59 $DbResult = $this->Database->select('NetworkDevice', 'COUNT(*)', '1'); 60 $DbRow = $DbResult->fetch_row(); 61 $Output .= 'Registrovaných zařízení: '.$DbRow['0'].'<br/>'; 62 $DbResult = $this->Database->select('FinanceOperation', 'SUM(Value)', '1'); 63 $DbRow = $DbResult->fetch_row(); 64 $Output .= 'Stav placení: '.$DbRow['0'].'<br/>'; 41 65 return($Output); 42 66 } … … 200 224 } 201 225 } 202 $Output .= '<tr><form action="?a=select& filter=1" method="post">';226 $Output .= '<tr><form action="?a=select&t='.$Table.'&r='.$_GET['r'].'&filter=1" method="post">'; 203 227 foreach($FormClass['Items'] as $ItemIndex => $FormItem) 204 228 if(!array_key_exists($FormItem['Type'], $this->System->FormManager->FormTypes) or … … 313 337 $Output .= '<td><input type="Submit" value="Hledat"/></td></form></tr>'; 314 338 315 $Query = 'SELECT * FROM `'.$FormClass['Table'].'`'.$Filter.' '.$Order['SQL'].$PageList['SQLLimit']; 316 339 // Get total item count in database 340 $Query = 'SELECT COUNT(*) FROM `'.$FormClass['Table'].'`'; 341 $DbResult = $this->Database->query($Query); 342 $DbRow = $DbResult->fetch_assoc(); 343 $TotalCount = $DbRow['COUNT(*)']; 344 345 // Get total filtered item count in database 346 if($UserFilter != '') 347 { 348 $Query = 'SELECT COUNT(*) FROM `'.$FormClass['Table'].'`'.$Filter; 349 $DbResult = $this->Database->query($Query); 350 $DbRow = $DbResult->fetch_assoc(); 351 $TotalFilteredCount = $DbRow['COUNT(*)']; 352 } 353 354 // Load and show items 355 $Query = 'SELECT * FROM `'.$FormClass['Table'].'`'.$Filter.' '.$Order['SQL'].$PageList['SQLLimit']; 356 $VisibleItemCount = 0; 317 357 $DbResult = $this->Database->query($Query); 318 358 while($Row = $DbResult->fetch_assoc()) … … 359 399 } 360 400 $Output .= '</td></tr>'; 361 } 401 $VisibleItemCount = $VisibleItemCount + 1; 402 } 403 $Output .= '<tr><td colspan="'.count($TableColumns).'" style="text-align: right;">Zobrazeno <strong>'.$VisibleItemCount.'</strong>'; 404 if($UserFilter != '') $Output .= ' z filtrovaných <strong>'.$TotalFilteredCount.'</strong>'; 405 $Output .= ' z celkem <strong>'.$TotalCount.'</strong></td></tr>'; 362 406 $Output .= '</table>'; 363 407 $Output .= $PageList['Output']; -
trunk/admin/Updates.php
r527 r531 301 301 $Manager->Execute("INSERT INTO `MenuItem` (`Id` ,`Name` ,`Parent` ,`Action` ,`Menu`) ". 302 302 "VALUES (NULL , 'Nabídky', '23', '".$ActionId."', '1');"); 303 304 303 } 305 304 -
trunk/form_classes.php
r529 r531 586 586 'DefaultSortColumn' => 'Name', 587 587 'Items' => array( 588 'Id' => array('Type' => 'Integer', 'Caption' => 'Identifikace', 'Default' => '', 'ReadOnly' => true), 588 589 'Name' => array('Type' => 'String', 'Caption' => 'Celé jméno', 'Default' => ''), 589 590 'AddressStreet' => array('Type' => 'String', 'Caption' => 'Ulice', 'Default' => ''),
Note:
See TracChangeset
for help on using the changeset viewer.