Changeset 21 for trunk/www/form.php
- Timestamp:
- Jun 12, 2009, 7:26:20 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/www/form.php
r16 r21 33 33 foreach($this->Definition['Items'] as $Index => $Item) 34 34 { 35 if(!array_key_exists($Index, $this->Values) and isset($Item['Default'])) $this->Values[$Index] = $Item['Default']; 36 $Edit = ExecuteTypeEvent($Item['Type'], 'OnView', 37 array('Name' => $Index, 'Value' => $this->Values[$Index], 'Type' => $Item['Type'])); 38 array_push($Table['Rows'], array($Item['Caption'], $Edit)); 35 if($Item['Type'] != 'Hidden') 36 { 37 if(!array_key_exists($Index, $this->Values) and isset($Item['Default'])) $this->Values[$Index] = $Item['Default']; 38 $Edit = ExecuteTypeEvent($Item['Type'], 'OnView', 39 array('Name' => $Index, 'Value' => $this->Values[$Index], 'Type' => $Item['Type'])); 40 array_push($Table['Rows'], array($Item['Caption'], $Edit)); 41 } 39 42 } 40 43 $Output = '<div style="text-align: center">'.$this->Definition['Title'].'</div>'.Table($Table, 'WideTable'); … … 60 63 foreach($this->Definition['Items'] as $Index => $Item) 61 64 { 62 if(!array_key_exists($Index, $this->Values) and isset($Item['Default'])) $this->Values[$Index] = $Item['Default']; 63 $Edit = ExecuteTypeEvent($Item['Type'], 'OnEdit', 64 array('Name' => $Index, 'Value' => $this->Values[$Index], 'Type' => $Item['Type'])); 65 array_push($Table['Rows'], array($Item['Caption'].':', $Edit)); 65 if($Item['Type'] != 'Hidden') 66 { 67 if(!array_key_exists($Index, $this->Values) and isset($Item['Default'])) $this->Values[$Index] = $Item['Default']; 68 $Edit = ExecuteTypeEvent($Item['Type'], 'OnEdit', array('Name' => $Index, 'Value' => $this->Values[$Index], 'Type' => $Item['Type'])); 69 array_push($Table['Rows'], array($Item['Caption'].':', $Edit)); 70 } 66 71 } 67 72 $Output = '<fieldset><legend>'.$this->Definition['Title'].'</legend>'.Table($Table, 'BasicTable'). 68 73 '</fieldset>'; 74 foreach($this->Definition['Items'] as $Index => $Item) 75 if($Item['Type'] == 'Hidden') $Output .= ExecuteTypeEvent($Item['Type'], 'OnEdit', array('Name' => $Index, 'Value' => $this->Values[$Index], 'Type' => $Item['Type'])); 69 76 return($Output); 70 77 } … … 78 85 foreach($this->Definition['Items'] as $Index => $Item) 79 86 { 80 $this->Values[$Index] = $DbRow[$Index]; 87 if($Item['Type'] != 'Hidden') 88 $this->Values[$Index] = $DbRow[$Index]; 81 89 } 82 90 }
Note:
See TracChangeset
for help on using the changeset viewer.