r93027 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r93026‎ | r93027 | r93028 >
Date:23:12, 24 July 2011
Author:reedy
Status:deferred
Tags:
Comment:
Comment, whitespace
Modified paths:
  • /trunk/extensions/MetricsReporting/ApiAnalyticsBase.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/ComScoreReachPercentageMetric.php (modified) (history)

Diff [purge]

Index: trunk/extensions/MetricsReporting/ApiAnalyticsBase.php
@@ -49,6 +49,7 @@
5050 if ( $params['startmonth'] && !$params['endmonth'] ) {
5151 $query['conds']['date'] = $params['startmonth'];
5252 } else {
 53+ // Note: date must be YYYY-MM-DD, using YYYY-MM may make nasty queries
5354 //add 1 month to end of date because of the way data is stored
5455 $endMonth = date( "Y-m-d", strtotime( $params['endmonth'] . " +1 month" ) );
5556
Index: trunk/extensions/MetricsReporting/metrics/ComScoreReachPercentageMetric.php
@@ -11,7 +11,7 @@
1212
1313 protected function getQueryInfo() {
1414 return array(
15 - 'table' => array( 'comscore', 'comscore_regions'),
 15+ 'table' => array( 'comscore', 'comscore_regions' ),
1616 'conds' => array(),
1717 'options' => array( 'GROUP BY' => 'comscore.region_code, date', 'ORDER BY' => 'comscore.region_code, date' ),
1818 'join_conds' => array( 'comscore_regions' => array( 'LEFT JOIN', "comscore.region_code = comscore_regions.region_code" )
@@ -20,7 +20,7 @@
2121 }
2222
2323 protected function getQueryFields() {
24 - return array( 'date', 'reach', 'comscore.region_code', 'region_name');
 24+ return array( 'date', 'reach', 'comscore.region_code', 'region_name' );
2525 }
2626
2727 protected function takesReportLanguage(){

Status & tagging log