Developer forum

Forum » Ecommerce - Standard features » Error rendering a filter

Error rendering a filter

Aki Ruuskanen
Reply

Hi,

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

The names of the filters are 

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

For some reason I get an exception when that filter is active on a productcatalogue module. 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() 

 

 

 

 


Replies

 
Nicolai Høeg Pedersen
Reply

Seems like you somehow have the same value in some of the same product fields - that is giving this error.

 

Will bug it so we can solve it.

 
Aki Ruuskanen
Reply

OK, could you please keep me posted. It is kind of critical to a customer that are going live tomorrow. 

/Aki

 

 
Aki Ruuskanen
Reply

Hi Nicolai,

Do you have any more input on this. Is it a official bug? Any planned hotfixes?

Regards / Aki

 

You must be logged in to post in the forum