0

We successfully migrated a huge multi-store site from magento-1.9.3 to magento-2.1.6 last week using Magento migration tool. After migration, we notice that categories are not listing any products although products are there all set in admin. Also we reindexed everything but the issue still remain there until we put the media folder from magento1.9.3 to migrated magento2.1.3/pub/ directory.

We've checked this issue and it seems that Magento\Catalog\Block\Category\View::getProductListHtml() function returns empty product listing html when there is not media with product images.

The case is not same with other magento stores as having a blank media only replaces the placeholders images. My question is, why it is necessary for me to place the old media folder will all images in order to render the products list successfully under categories?

PS: permissions are set properly for pub, no custom module is overriding any class, all the commands (static content, reindex, cacha clean, di compilation) ran completely.

  • Please check your Magento2 default placeholder image. I think it is not present at that path so the product is not displayed. Please check it and then ping me. @Salid – Dhaduk Mitesh Mar 29 '18 at 4:00
  • And also check your debug.log file. Any error occurred or not. – Dhaduk Mitesh Mar 29 '18 at 4:15
  • @DhadukMitesh yes the issue was that there were some custom placeholder images from backend. After removing those placeholders from admin OR putting the placeholder images in media directory worked for me. – saiid Mar 29 '18 at 10:03
0

As suggested by @DhadukMitesh, the issue was that there were some custom placeholder images set from backend.

Stores > Setting > Configuration > Catalog > Catalog > Product Image Placeholders

After removing those placeholders from admin OR putting the placeholder images in media directory worked for me.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.