Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormattab <matthieu.aubry@gmail.com>2013-06-13 09:23:46 +0400
committermattab <matthieu.aubry@gmail.com>2013-06-16 12:11:03 +0400
commitdd2140c8c3faf2cfca30fd6fea0350ca953695da (patch)
tree0281474580d9931cf11a9956fdb5f08c00cb64f6 /plugins/VisitTime
parent6be9fb2002a0a7da79af55e3263f23c5addfa79c (diff)
Adding new classes
Disabling VisitTime.getByDayOfWeek since I dont understand how to make it work / why it's changed yet
Diffstat (limited to 'plugins/VisitTime')
-rw-r--r--plugins/VisitTime/API.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/plugins/VisitTime/API.php b/plugins/VisitTime/API.php
index 807b399869..dddd2431e0 100644
--- a/plugins/VisitTime/API.php
+++ b/plugins/VisitTime/API.php
@@ -71,7 +71,6 @@ class Piwik_VisitTime_API
// get metric data for every day within the supplied period
$oPeriod = Piwik_Period::makePeriodFromQueryParams(Piwik_Site::getTimezoneFor($idSite), $period, $date);
$dateRange = $oPeriod->getDateStart()->toString() . ',' . $oPeriod->getDateEnd()->toString();
-
$archive = Piwik_Archive::build($idSite, 'day', $dateRange, $segment);
// disabled for multiple sites/dates
@@ -79,14 +78,18 @@ class Piwik_VisitTime_API
throw new Exception("VisitTime.getByDayOfWeek does not support multiple sites.");
}
- if ( count ($archive->getParams()->getPeriods() ) > 1) {
+ $periods = $archive->getParams()->getPeriods();
+ if ( count ($periods) > 1
+ && !($periods[0] instanceof Piwik_Period_Day)) {
throw new Exception("VisitTime.getByDayOfWeek does not support multiple dates.");
}
+ //FIXMEA
+ throw new exception("Temporarily broken - stay tuned");
+
$dataTable = $archive->getDataTableFromNumeric($metrics);
// if there's no data for this report, don't bother w/ anything else
- // TODO: with changes to getDataTableFromNumeric, this code would have to check if every row has 0 column values. is it really necessary? (assuming no for now)
if ($dataTable->getRowsCount() == 0) {
return $dataTable;
}