fixing image sale

This commit is contained in:
Christophe LATOUR 2017-10-25 14:58:27 +02:00
parent 2b49cc5543
commit a6d90e4b40

View File

@ -15,7 +15,7 @@ class Sale extends BaseSale {
global $cookie;
$sale = parent::toArray();
$is_active = strtotime($this->date_start) < strtotime(date('Y-m-d 07:00:00'));
$is_active = strtotime($this->date_start) <= strtotime(date('Y-m-d 07:00:00'));
$sale['img'] = $this->getSaleImage($this->id, $is_active);
$sale['reduction'] = $this->extraFields['reduction'] ? $this->extraFields['reduction'] : '0';
$sale['tags'] = $this->extraFields['tags'] ? $this->extraFields['tags'] : [];