Developer forum

Forum » Ecommerce - Standard features » Error rendering filter i frontend

Error rendering filter i frontend

Aki Ruuskanen
Reply

Hi,

I have a filtergroup called "Skärmar" with 8 "product field value" filters.

The names of the filters in that group are:

  • 3D-teknik
  • Diagonal storlek
  • Nätverksknytbarhet
  • 3D
  • Skrämupplösning
  • Smart-TV
  • Styrning
  • TV-Tuner

When I activate the filter in the productcatalogue module I get the following error in frontend. Any ideas?

 

System.ArgumentException: An item with the same key has already been added.
   at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
   at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
   at Dynamicweb.eCommerce.Products.Categories.Category.GetValues(Boolean onlyActive)
   at Dynamicweb.Searching.Specialized.eCommerce.ProductFieldsFilter.CategoryFieldInfo.GetValuesToRender(String[] selected, FieldInfoCacheSettings cache)
   at Dynamicweb.Searching.Specialized.eCommerce.ProductFieldsFilterProvider.GetOptions()
   at Dynamicweb.Extensibility.Searching.eCommerce.FilterManager.GetFilterOptions(Filter filter)
   at Dynamicweb.Searching.Specialized.eCommerce.ProductFieldsFilterProvider.Render(Template template)
   at Dynamicweb.Extensibility.Searching.eCommerce.FilterRenderer.Render(Template loopTemplate, Template masterTemplate)
   at Dynamicweb.eCommerce.Frontend.Renderer.RenderSearchFilters(Template template, IEnumerable`1 filters)
   at Dynamicweb.eCommerce.Frontend.Renderer.RenderSearchFilters(Template template)
   at Dynamicweb.eCommerce.Frontend.Renderer.RenderSearchTemplate()
   at Dynamicweb.eCommerce.Frontend.Renderer.RenderProducts(ProductCollection Products, Template ParentTemplate, String LoopName, Int32 LoopCounter, Boolean renderRelated)
   at Dynamicweb.eCommerce.Frontend.Renderer.RenderProducts(ProductCollection Products, Template ParentTemplate)
   at Dynamicweb.eCommerce.Frontend.Frontend.ListProducts(ProductCollection products, String groupsIdent, Boolean hasBeenSorted)
   at Dynamicweb.eCommerce.Frontend.Frontend.ListProducts(ProductCollection products, String groupsIdent)
   at Dynamicweb.eCommerce.Frontend.Frontend.List(String groups)
   at Dynamicweb.eCommerce.Frontend.Frontend.EcomRender()
   at Dynamicweb.eCommerce.Frontend.Frontend.GetContent()
   at Dynamicweb.Frontend.Content.getModule(DataRow& ParagraphRow)

 

 

 


Replies

 
Aki Ruuskanen
Reply

I have also found out that it is only specifik filters in the group that is causing the error. So my guess is that its got something to do with the values that are rendered by the system. Strange.....

 

 
Nicolai Høeg Pedersen

 

You must be logged in to post in the forum