Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refs #3465, remove Piwik_DataTable_Array::metadata and move data to P…
…iwik_DataTable::metadata.
- Loading branch information
diosmosis
committed
Mar 11, 2013
1 parent
2fa1dca
commit 80ac6ac
Showing
15 changed files
with
79 additions
and
109 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -125,10 +125,10 @@ protected function initChartObjectData() | |
|
||
// the X label is extracted from the 'period' object in the table's metadata | ||
$xLabels = $uniqueIdsDataTable = array(); | ||
foreach($this->dataTable->metadata as $idDataTable => $metadataDataTable) | ||
foreach($this->dataTable->getArray() as $idDataTable => $metadataDataTable) | ||
{ | ||
//eg. "Aug 2009" | ||
$xLabels[] = $metadataDataTable['period']->getLocalizedShortString(); | ||
$xLabels[] = $metadataDataTable->getMetadata('period')->getLocalizedShortString(); | ||
// we keep track of all unique data table that we need to set a Y value for | ||
$uniqueIdsDataTable[] = $idDataTable; | ||
} | ||
|
@@ -193,8 +193,8 @@ protected function initChartObjectData() | |
$this->view->setAxisYUnits($yAxisLabelToUnit); | ||
|
||
$countGraphElements = $this->dataTable->getRowsCount(); | ||
$firstDatatable = reset($this->dataTable->metadata); | ||
$period = $firstDatatable['period']; | ||
$firstDatatable = reset($this->dataTable->getArray()); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
mattab
Member
|
||
$period = $firstDatatable->getMetadata('period'); | ||
|
||
$stepSize = $this->getXAxisStepSize($period->getLabel(), $countGraphElements); | ||
$this->view->setXSteps($stepSize); | ||
|
@@ -203,9 +203,9 @@ protected function initChartObjectData() | |
{ | ||
$axisXOnClick = array(); | ||
$queryStringAsHash = $this->getQueryStringAsHash(); | ||
foreach($this->dataTable->metadata as $idDataTable => $metadataDataTable) | ||
foreach($this->dataTable->getArray() as $idDataTable => $metadataDataTable) | ||
{ | ||
$period = $metadataDataTable['period']; | ||
$period = $metadataDataTable->getMetadata('period'); | ||
$dateInUrl = $period->getDateStart(); | ||
$parameters = array( | ||
'idSite' => $idSite, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
This line produces an error in some cases!
Please fix this @diosmosis