Changeset 10 for types/PointerOneToOne.php
- Timestamp:
- Oct 12, 2008, 8:43:23 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
types/PointerOneToOne.php
r9 r10 6 6 7 7 $Columns = ''; 8 $ItemType = explode(':', $Item['Type']); 9 $TargetTable = $ItemType[1]; 8 $TargetTable = $Type['Parameters'][0]; 10 9 11 10 foreach($Lists[$TargetTable]['Items'] as $ListItem) … … 25 24 26 25 $Columns = ''; 27 $ItemType = explode(':', $Item['Type']); 28 $TargetTable = $ItemType[1]; 26 $TargetTable = $Type['Parameters'][0]; 29 27 30 28 foreach($Lists[$TargetTable]['Items'] as $ListItem) … … 42 40 } 43 41 44 function TypePointerOneToOne ViewHtml($Type,$Item)42 function TypePointerOneToOneOnView($Item) 45 43 { 46 global $Database, $Lists ;44 global $Database, $Lists, $Types; 47 45 48 $ ItemType = explode(':', $Item['Type']);49 $TargetTable = $ ItemType[1];46 $Type = $Types[$Item['Type']]; 47 $TargetTable = $Type['Parameters'][0]; 50 48 $TargetName = GetTablePointerName($Type, $Item); 51 49 $Output = '<a href="?Action=ViewItem&Table='.$TargetTable.'&Item='.$TargetName['Id'].'">'.$TargetName['Name'].'</a>'; … … 53 51 } 54 52 55 function TypePointerOneToOne EditHtml($Type,$Item)53 function TypePointerOneToOneOnEdit($Item) 56 54 { 57 global $Database, $Lists ;55 global $Database, $Lists, $Types; 58 56 57 $Type = $Types[$Item['Type']]; 59 58 $Output = '<select name="'.$Item['Name'].'">'; 60 59 $TargetNameList = GetTablePointerNameList($Type, $Item);
Note:
See TracChangeset
for help on using the changeset viewer.