Developer forum

Forum » Development » Facets outputs value instead of label

Facets outputs value instead of label

Bogdan Ciocsan
Reply

Hi Dynamicweb

I have opened a support case with the following number: CAS-115412-MTXGTD where I described that I have a custom product field which is of the type "multiselect list" and when I am trying to output the facets label, and I get the value of the field instead. The support team suggested that I should post my problem here as they are not able to resolve this matter.

In my loop(FacetOptions) I am trying to output the following: @i.GetString("FacetOption.Label") and unfortunately it gives me the value and not the label. The same code works for other type of fields, but it does not seem to work for the multiple list type.

Can you fix this issue? My customer is currently getting an ugly looking list instead of pretty labels.

Best regards

Bogdan

 


 

category-field.png

Replies

 
Nicolai Høeg Pedersen
Reply

Hi Bogdan

Yes, I can see that. We will look into this for a later release.

BR Nicolai

 
Bogdan Ciocsan
Reply

Hi Nicolai

Any news on when this issue will be fixed? :) 

Best regards

Bogdan

 
Nicolai Høeg Pedersen
Reply

Hi Bogdan

This is TFS#22752 scheduled for 8.9 due in September.

BR Nicolai

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Nicolai,

 

Was this ever released? I guess not because I have a customer that upgraded to 8.9.2.14 because of it and I still have the same problem (unless there's something else I need to do)

https://www.screencast.com/t/UoQ6rW3noBS

 

Best Regards,

Nuno Aguiar

 
Nicolai Pedersen
Reply

Yes, requires a build after June 16th, 2016

If you have data values lik "IHateMySelf_"""',--#_andDoNotLikeLogicalData" you might run into problems.

The custom ecommerce field also has to be of type "15" before this works. Do not know if that is the case for checkbox lists.

I'll ask QA to look into it.

BR Nicolai

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Nicolai,

 

Just to confirm that we don't have bad data and the field is of type 15. Looks like a recurring bug since I tested all 4 types of presentation (radio button, checkbox, dropdown and multiselect) and even reindexed between changes just in case, and got the same result - values in the label tag.

 

And 8.9.2.14 was released after June 16h 2016. In fact it was released on October 27th 2017 :P

 

Recurring bugs are the worst...

 

Best Regards,

Nuno Aguiar

 
Oleg Rodionov
Reply
This post has been marked as an answer

Hi all,

I was able to reproduce the issue commented by Nuno above on DW8.9.2.14 as well as on DW9, TFS#22752 has been reopened, thanks.

BR, Oleg QA

Votes for this answer: 1
 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Oleg,

 

Do you know if the next hotfix for DW8 will be out next Tuesday, on the 21st?

 

Nuno

 
Steffen Kruse Hansen
Reply

Hi Nuno,

I can see from your video, that the problem you're having is related to a Product category field. I can also see, that you have an underscore _ in both your ProductCategory systemname and your ProductCategoryField systemname. Can you get you to try the same approach on a ProductCategory and a ProductCategoryField, where you don't have any underscores in your systemnames?

I have a theory that this is the source to the problem.

Best regards,

Steffen  

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Steffen,

 

Good call... it works. However the underscores were automatically introduced by DW (autofill the values "on blur" of the Name field), and the customer already spent a lot of time setting those up and assigning values on products, so I am stuck with this and cannot apply a workaround (unless I change all references on the DB).

 

I'll wait for the fix. But thank you a lot for shedding some light on the issue.

 

Best Regards,

Nuno Aguiar

 
Adrian Ursu Dynamicweb Employee
Adrian Ursu
Reply

Hi Nuno,

After seeing this post, I ended up excluding the Fields form the index and adding them back in the index without "_".

It's a lot of work if the field list is very long but at least you don't have to mess with the database.

Thanks,

Adrian

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi Adrian,

 

That's a good idea, but it would not work for me either. The customer is creating the category fields himself, and this is just "an extra unneeded step" for him. And it's temporary, so we need to wait fo the fix.

 

Best Regards,

Nuno Aguiar

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi,

 

Any news on this fix? The customer is asking about it again.

 

Best Regards,

Nuno Aguiar

 
Nuno Aguiar Dynamicweb Employee
Nuno Aguiar
Reply

Hi,

 

Any news on this fix on the 8.9 branch?

 

Best Regards,

Nuno

 
Kurt Moskjær Andersen
Kurt Moskjær Andersen
Reply

Any news on this one?

--
Best regards
Kurt Moskjaer Andersen

 
Thomas Jensen
Reply

Hi

I have a Facet (type select) that take "Manufacture name"
The manufacture "Audi" becoms
FacetOption.Label = audi
FacetOption.Name = audi
FacetOption.Value = audi
all in lowercase

Have also a cuscom field where "A3" becoms "a3" in FacetOption

 

Running 9.4.18

Can't finde anything on this in bug fixes or known bugs
So any ETA or news on this?

 

Regards Thomas

 
Nicolai Pedersen
Reply

How do you index definition look like? Is this field analyzed? If so, create a new field - not analyzed and try it again.

 
Nicolai Pedersen
Reply

For the record, TFS#22752 was fixed in July 2016

 
Thomas Jensen
Reply

Hi Nicolai

That worked, so the analyzed will clean up the string, and make it lowercase

 

note:
I was guidet here by this post
https://doc.dynamicweb.com/forum/ecommerce-standard-features/ecommerce-standard-features/wrong-option-name-from-facetoptions

 

Super and Thanks

 

You must be logged in to post in the forum