porting PHRAS-1770 to 4.1

This commit is contained in:
Mike Ng
2018-01-04 14:41:19 +04:00
parent 0d7c2bd52d
commit c936582d88

View File

@@ -431,6 +431,7 @@ class record_preview extends record_adapter
$nbDays--; // because 0 is included
for ($d=$nbDays; $d>=0; $d--) {
$datetime = new DateTime('-' . $d . ' days');
$datetime->modify('+1 day');
$date = date_format($datetime, 'Y-m-d');
if($d == $nbDays) {
$this->statistics['from'] = $date;