Commit 6a679a7f7dcb58bd2bdeb2ecef0ba4ea75d7e626
1 parent
64280af6
Exists in
master
and in
9 other branches
#11478 - Infobulle
Showing
2 changed files
with
12 additions
and
1 deletions
Show diff stats
php/classes/AmdaAction.php
... | ... | @@ -189,9 +189,13 @@ class AmdaAction |
189 | 189 | case 'catalog': |
190 | 190 | if ($isLeaf) { |
191 | 191 | $info = '<b>Nb intervals:</b> '.$child->getAttribute('intervals').'<br/>'; |
192 | - // ICIIIII | |
193 | 192 | $objectMgr = new TimeTableMgr(); |
193 | + | |
194 | 194 | $obj_info = $objectMgr->getObject($id, $nodeType); |
195 | + | |
196 | + if($nodeType == "catalog") | |
197 | + $info .='<b>Nb columns:</b> '.$obj_info['nbParam']. '<br/>'; | |
198 | + | |
195 | 199 | if (!empty($obj_info) && !empty($obj_info['description'])) { |
196 | 200 | $info .= '<b>Description:</b> '. $obj_info['description'] . '<br/>'; |
197 | 201 | } | ... | ... |
php/classes/TimeTableMgr.php
... | ... | @@ -74,8 +74,14 @@ class TimeTableMgr extends AmdaObjectMgr |
74 | 74 | $attributes = $objToGet->childNodes; |
75 | 75 | |
76 | 76 | $nbInt = 0; |
77 | + $nbParam = 0; | |
77 | 78 | foreach ($attributes as $attribute) { |
78 | 79 | if ($attribute->nodeType == XML_ELEMENT_NODE) { |
80 | + if($attribute->tagName == 'parameters'){ | |
81 | + foreach($attribute->childNodes as $parameter){ | |
82 | + $nbParam++; | |
83 | + } | |
84 | + } | |
79 | 85 | /*if ($attribute->tagName == 'intervals') { |
80 | 86 | $start = $attribute -> getElementsByTagName('start')->item(0) -> nodeValue; |
81 | 87 | $stop = $attribute -> getElementsByTagName('stop')->item(0) -> nodeValue; |
... | ... | @@ -116,6 +122,7 @@ class TimeTableMgr extends AmdaObjectMgr |
116 | 122 | if($attributesToReturn['surveyStop'] == "" ) |
117 | 123 | $attributesToReturn['surveyStop'] = $stop; |
118 | 124 | $attributesToReturn['nbIntervals'] = $nbInt; |
125 | + $attributesToReturn['nbParam'] = $nbParam; | |
119 | 126 | |
120 | 127 | return $attributesToReturn; |
121 | 128 | } | ... | ... |