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:
Diffstat (limited to 'core/ViewDataTable/GenerateGraphData/ChartEvolution.php')
-rw-r--r--core/ViewDataTable/GenerateGraphData/ChartEvolution.php32
1 files changed, 2 insertions, 30 deletions
diff --git a/core/ViewDataTable/GenerateGraphData/ChartEvolution.php b/core/ViewDataTable/GenerateGraphData/ChartEvolution.php
index b66e334ee0..fc4d9246cf 100644
--- a/core/ViewDataTable/GenerateGraphData/ChartEvolution.php
+++ b/core/ViewDataTable/GenerateGraphData/ChartEvolution.php
@@ -313,8 +313,8 @@ class Piwik_ViewDataTable_GenerateGraphData_ChartEvolution extends Piwik_ViewDat
private function getXAxisStepSize( $periodLabel, $countGraphElements )
{
- // For Custom Date Range, when the number of elements plotted can be small, make sure the X legend is useful
- if ($countGraphElements <= 3)
+ // when the number of elements plotted can be small, make sure the X legend is useful
+ if ($countGraphElements <= 7)
{
return 1;
}
@@ -322,44 +322,16 @@ class Piwik_ViewDataTable_GenerateGraphData_ChartEvolution extends Piwik_ViewDat
switch ($periodLabel)
{
case 'day':
- if ($countGraphElements <= 9)
- {
- $steps = 4;
- }
- else
- {
$steps = 5;
- }
break;
case 'week':
- if ($countGraphElements <= 4)
- {
- return 2;
- }
- else
- {
$steps = 4;
- }
break;
case 'month':
- if ($countGraphElements <= 6)
- {
- return 2;
- }
- else
- {
$steps = 5;
- }
break;
case 'year':
- if ($countGraphElements <= 10)
- {
- return 2;
- }
- else
- {
$steps = 5;
- }
break;
default:
$steps = 5;