How to create and register new component

Thursday, April 25, 2024 1:53:34 PM
  • Posted: Tuesday, July 28, 2020 11:16 AM
  • 34
Hi everyone!

I want create and register new component in Grand.Web\Views\Shared\Components\ ?
I copied SimilarProducts folder(with Default.cshtml), than past and rename SimilarProductsCustom and rebuild project.

When i Run project i see "System.InvalidOperationException: A view component named SimilarProductsCustom could not be found."

How to add a new component and fix this error?
Thanks.
0
  • Posted: Tuesday, July 28, 2020 1:23 PM
  • 953
If you want to do that in that way, please search for all references for SimilarProducts. And then copy and rename all of them :) Why don't you use, other group of related products? :) For example crosssales or related?
Best regards,
Patryk

GrandNode Team
0
  • Posted: Wednesday, July 29, 2020 2:37 AM
  • 34
Hi, Patryk.

I want to do component that show in ProductPage related products (10 products in slider line) and this products have the condition:
1. Category products like as category main product from ProductPage.
2. Cost range all related products stay between -30% to +30% from main product in ProductPage.

Thanks.
0
back to top
Filters