Commit 34a30a7e4df0e84e1d485d006cbf2e2590674ac2
1 parent
40624062
Exists in
master
and in
63 other branches
auto fill of min/max for variable table from args
Showing
1 changed file
with
10 additions
and
1 deletions
Show diff stats
src/Request/ParamInfoRequestClass.php
... | ... | @@ -145,7 +145,8 @@ class ParamInfoRequestClass extends RequestAbstractClass |
145 | 145 | 'name' => $tableNode->getAttribute("name"), |
146 | 146 | 'units' => $tableNode->getAttribute("units"), |
147 | 147 | 'variable' => ($tableNode->getAttribute("variable") === "true"), |
148 | - 'channels' => array() | |
148 | + 'channels' => array(), | |
149 | + 'minmax' => array() | |
149 | 150 | ); |
150 | 151 | |
151 | 152 | if (!$tableResult['variable']) { |
... | ... | @@ -157,6 +158,14 @@ class ParamInfoRequestClass extends RequestAbstractClass |
157 | 158 | ); |
158 | 159 | } |
159 | 160 | } |
161 | + else { | |
162 | + if ($tableNode->hasAttribute("minValue")) { | |
163 | + $tableResult['minmax'] = array( | |
164 | + 'min' => $tableNode->getAttribute("minValue"), | |
165 | + 'max' => $tableNode->getAttribute("maxValue") | |
166 | + ); | |
167 | + } | |
168 | + } | |
160 | 169 | |
161 | 170 | $result['tables'][] = $tableResult; |
162 | 171 | } | ... | ... |