- Timestamp:
- Oct 21, 2008, 9:05:41 AM (16 years ago)
- Location:
- lists
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
lists/SystemList.php
r11 r16 18 18 } 19 19 20 function ListSystemListOnEdit($Parameters) 21 { 22 global $Database; 23 24 $DbResult = $Database->query('SELECT `TableName` FROM `'.$Parameters['ListTableName'].'` WHERE ItemId='.$Parameters['ItemId'].' ORDER BY `Id` DESC LIMIT 1,1'); 25 $DbRow = $DbResult->fetch_assoc(); 26 if($DbRow['TableName'] != $Parameters['TableName']) 27 $Database->query('RENAME TABLE `'.$DbRow['TableName'].'` TO `'.$Parameters['TableName'].'`'); 28 } 29 20 30 ?> -
lists/SystemListItem.php
r13 r16 6 6 7 7 //print_r($Parameters); 8 $DbResult = $Database-> select('SystemType', 'DbDataType', 'Id='.$Parameters['Type']);8 $DbResult = $Database->query('SELECT DbDataType FROM SystemType WHERE ItemId='.$Parameters['Type'].' ORDER BY Id DESC LIMIT 1'); 9 9 //echo($Database->LastQuery); 10 10 $DbRow = $DbResult->fetch_assoc(); 11 $DbResult = $Database-> select('SystemList', 'TableName', 'Id='.$Parameters[$Parameters['Column']]);11 $DbResult = $Database->query('SELECT TableName FROM SystemList WHERE ItemId='.$Parameters[$Parameters['Column']].' ORDER BY Id DESC LIMIT 1'); 12 12 //echo($Database->LastQuery); 13 13 $DbRow2 = $DbResult->fetch_assoc();
Note:
See TracChangeset
for help on using the changeset viewer.