Adding prices to Featured Items?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 years ago
Could some one please provide some guidance on how to add item prices to featured items that are displayed on the homepage.

I am using nop 2.20, in case that helps.

Many thanks
12 years ago
You have to modify the code source to do that. Roughly, in the Catalog controller, you can change the HomePageProducts action to call PrepareProductOverviewModel with the preparePriceModel to true and in the view use the ProductBox partial view instead of the SmallProductBox.

However, the site will be slower because computing the price model takes a significant amount of time especially if you have complex discounts.

In my implementation, I cached the ProductModels (with appropriate variations for displaying the correct price depending on tax settings, preferences, currency, language, etc) for each product, making things significantly faster. The cache gets refreshed automatically whenever a product, product variant, category or discount is modified.
12 years ago
Just set 'CatalogSettings.UseSmallProductBoxOnHomePage' setting to 'false
12 years ago
I was sure this action didn't use the setting. I was wrong. That's the easiest way to show the price.
12 years ago
This option was added in 2.20
12 years ago
Cheers Andrei,
Where do i find that setting please?

Many thanks for your help
12 years ago
Admin area > configuration > settings > all settings (advanced)
12 years ago
Thanks,
Is this non small product box used anywhere else on the site? i am guessing i will need to style it up multiple times otherwise
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.