#715 Group by day -> month+day, group by month -> year+month, months are shown as a localized label

SVN:trunk[2702]
This commit is contained in:
Romain Quetiez
2013-04-26 09:46:31 +00:00
parent 4ea0093f12
commit f97f51b895
6 changed files with 97 additions and 16 deletions

View File

@@ -458,7 +458,7 @@ abstract class DashletGroupBy extends Dashlet
case 'month':
$sGroupByLabel = Dict::Format('UI:DashletGroupBy:Prop-GroupBy:Month', $sAttLabel);
$sGroupByExpr = "DATE_FORMAT($sClassAlias.$sAttCode, '%m')"; // 0 -> 31
$sGroupByExpr = "DATE_FORMAT($sClassAlias.$sAttCode, '%Y-%m')"; // yyyy-mm
break;
case 'day_of_week':
@@ -468,7 +468,7 @@ abstract class DashletGroupBy extends Dashlet
case 'day_of_month':
$sGroupByLabel = Dict::Format('UI:DashletGroupBy:Prop-GroupBy:DayOfMonth', $sAttLabel);
$sGroupByExpr = "DATE_FORMAT($sClassAlias.$sAttCode, '%e')"; // 0 -> 31
$sGroupByExpr = "DATE_FORMAT($sClassAlias.$sAttCode, '%m-%d')"; // mm-dd
break;
default: