From aa799b6e0bcb7222fe07fdd439fd5e0967b8ec69 Mon Sep 17 00:00:00 2001 From: Exodus4D Date: Thu, 19 Jan 2017 22:26:05 +0100 Subject: [PATCH] - fixed "statistics" module, closed #424 --- app/main/controller/api/statistic.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/main/controller/api/statistic.php b/app/main/controller/api/statistic.php index b2067732..ab89776e 100644 --- a/app/main/controller/api/statistic.php +++ b/app/main/controller/api/statistic.php @@ -169,7 +169,7 @@ class Statistic extends Controller\AccessController { ]; // date offset condition ---------------------------------------------------------------------------------- - $sqlDateOffset = " AND CONCAT(`log`.`year`, `log`.`week`) BETWEEN :yearWeekStart AND :yearWeekEnd "; + $sqlDateOffset = " AND CONCAT(`log`.`year`, LPAD(`log`.`week`, 2, 0) ) BETWEEN :yearWeekStart AND :yearWeekEnd "; $queryData[':yearWeekStart'] = $this->concatYearWeek($yearStart, $weekStart); $queryData[':yearWeekEnd'] = $this->concatYearWeek($yearEnd, $weekEnd);