Index: trunk/extensions/MetricsReporting/ApiAnalyticsBase.php |
— | — | @@ -40,7 +40,7 @@ |
41 | 41 | |
42 | 42 | $query['conds']['date'] = $params['months']; |
43 | 43 | |
44 | | - if ( $params['normalised'] ) { |
| 44 | + if ( $params['normalized'] ) { |
45 | 45 | // Do data normalisation stuffs here |
46 | 46 | } |
47 | 47 | // if/switch on $params['data'] |
— | — | @@ -90,13 +90,13 @@ |
91 | 91 | foreach( $res as $row ) { |
92 | 92 | $item = array(); |
93 | 93 | foreach( $fields as $field ) { |
94 | | - $item[$field] = $row->$field; |
| 94 | + $item[$field] = $row->$$field; |
95 | 95 | } |
96 | 96 | $data[] = $item; |
97 | 97 | } |
98 | 98 | |
99 | | - $result->setIndexedTagName( $data, 'metric' ); |
100 | | - $result->addValue( 'quermetricy', $this->getModuleName(), $data ); |
| 99 | + $result->setIndexedTagName( $data, 'data' ); |
| 100 | + $result->addValue( 'metric', $this->getModuleName(), $data ); |
101 | 101 | } |
102 | 102 | |
103 | 103 | protected abstract function getQueryInfo(); |
— | — | @@ -116,7 +116,7 @@ |
117 | 117 | ApiBase::PARAM_TYPE => 'string', |
118 | 118 | ApiBase::PARAM_REQUIRED => true, |
119 | 119 | ), |
120 | | - 'normalized' => 'bool', |
| 120 | + 'normalized' => false, |
121 | 121 | 'data' => array( |
122 | 122 | ApiBase::PARAM_DFLT => 'timeseries', |
123 | 123 | ApiBase::PARAM_ISMULTI => true, |