In backend, set a special price for a product.
That only the Special Price is set.
The Special Price is set for the product
Workaround for now is to set the News From Date and News To Date to passed dates if you are using for example a widget showing new products.
@antboiko can you check if this is working as intended/documented or a bug?
@thomasnordkvist
Hi Thomas, could you please tell me what Magento version you use?
Thanks,
Anton.
I have this issue in version 2.0.4 whish is the only version I have access to at the moment
@thomasnordkvist thanks for reporting this issue. Internal ticket MAGETWO-52577 was created.
Hi,
Has this issue been addressed at all? I am using Magento 2.1.2 and still the same issue is happening.
Is there a release planned that fixes this?
Hi @joe980 , I increased priority for the fix. It won't be delivered in the next release 2.1.3, so it scheduled for 2.1.4. If any changes happened I inform you
2.1.4 and 2.1.5 are out and bug still exists. can you raise priority so it will be included in 2.1.6?
2.15 still an issue for me.
I used this work around for now. Simply adding a date to all products that have NULL values in these fields.
Login in to PhpMyAdmin
Go to table catalog_product_entity_datetime
Find the attribute ids of news from date and news to date (or go to the attribute in admin and find id in the url key)
Run query below (change the atrribute_id(s) to match your ids obtained from above)
UPDATE catalog_product_entity_datetime
SET value = '2000-01-01 00:00:00'
WHERE attribute_id = 77 AND value IS NULL OR attribute_id = 78 AND value IS NULL
Still an issue in 2.1.6
Confirmed still an issue for 2.1.6
Confirmed still an issue for 2.1.7
The problem is that Magento\Catalog\Model\Attribute\Backend\Startdate sets the from-date to the current date when the product has a special price. This also incorrectly sets all other start/from dates, for instance the news_from_date. A possible fix is to add an extra check for the special_from_date attribute before setting it:
Change
if ($startDate == '' && $object->getSpecialPrice()) {
$startDate = $this->_localeDate->date();
}
to
if ($attributeName == "special_from_date" && $startDate == '' && $object->getSpecialPrice()) {
$startDate = $this->_localeDate->date();
}
Internal ticket to track issue progress: MAGETWO-72252
@thomasnordkvist thank you for your report.
The fix for this issue is already fixed in 2.2.0 release
Most helpful comment
Hi @joe980 , I increased priority for the fix. It won't be delivered in the next release 2.1.3, so it scheduled for 2.1.4. If any changes happened I inform you