Added new row to graph period

This commit is contained in:
Arturo Gonzalez 2017-04-10 11:22:20 +02:00
parent 09c29f5fd0
commit 94cdf669b0

View File

@ -352,9 +352,12 @@ function grafico_modulo_sparse_data_chart (&$chart, &$chart_data_extra, &$long_i
elseif ($period < SECONDS_1MONTH) { elseif ($period < SECONDS_1MONTH) {
$time_format = "M \nd H\h"; $time_format = "M \nd H\h";
} }
else { elseif ($period < SECONDS_6MONTHS) {
$time_format = "M \nd H\h"; $time_format = "M \nd H\h";
} }
else {
$time_format = "M Y";
}
} }
else { else {
// Set the title and time format // Set the title and time format
@ -370,9 +373,12 @@ function grafico_modulo_sparse_data_chart (&$chart, &$chart_data_extra, &$long_i
elseif ($period < SECONDS_1MONTH) { elseif ($period < SECONDS_1MONTH) {
$time_format = "M d H\h"; $time_format = "M d H\h";
} }
else { elseif ($period < SECONDS_6MONTHS) {
$time_format = "M d H\h"; $time_format = "M d H\h";
} }
else {
$time_format = "M Y";
}
} }
$timestamp_short = date($time_format, $timestamp); $timestamp_short = date($time_format, $timestamp);