Hi all,


I am using the my personal environment to start using Outsystems and I started with the DropdownSelect component from OutsystemsUIWeb.  When I search for a number the results displayed are the one’s with that number on the label but also the one’s which index has that number:

Example: I have a list with 3 values

1 - Banana

2- Orange

3 - Apple

If I search for 1 on the list it returns Orange (which index of the list is 1). Can someone help me please?

Thanks in advance.

João Manuel

Solution

Joao Manuel wrote:

Hi all,


I am using the my personal environment to start using Outsystems and I started with the DropdownSelect component from OutsystemsUIWeb.  When I search for a number the results displayed are the one’s with that number on the label but also the one’s which index has that number:

Example: I have a list with 3 values

1 - Banana

2- Orange

3 - Apple

If I search for 1 on the list it returns Orange (which index of the list is 1). Can someone help me please?

Thanks in advance.

João Manuel

Hi,

I had this issue in the past. This happens because the default searchFields property of the widget has the values: [‘label’,’value’].


In order to fix this just do the following:

Best regards,

Tiago Reis


Solution

For whos using this search with numbers included, there is still an improvement on the format.

If you search 456 on this subtset:

   title: "123456 - Old Man's War",

   title: "465123 -The Lock Artist"

it will return both results, its using a sort of partial search with a mix of the numbers. 

On the advancedformat option i have added this to complement the previous post:

"{ ""searchFields"": ['label'],

 ""fuseOptions"": {

   threshold: 0.1,

   location: 0,

   distance: 1000,

   maxPatternLength: 32,

   minMatchCharLength: 1

  }

}"


I played around with the treshold to get the result i wanted. Hope it helps someone aswell.

Tiago Tavares wrote:

For whos using this search with numbers included, there is still an improvement on the format.

If you search 456 on this subtset:

   title: "123456 - Old Man's War",

   title: "465123 -The Lock Artist"

it will return both results, its using a sort of partial search with a mix of the numbers. 

On the advancedformat option i have added this to complement the previous post:

"{ ""searchFields"": ['label'],

 ""fuseOptions"": {

   threshold: 0.1,

   location: 0,

   distance: 1000,

   maxPatternLength: 32,

   minMatchCharLength: 1

  }

}"


I played around with the treshold to get the result i wanted. Hope it helps someone aswell.


Hi ,

I would like to change the color of the specific items in the list dropdown like as shown in the attached image file.I'm able to get it by css for the first three child elements in the list using CSS. but when i search particular element the other first three suggested elements also changing the color. I want the color only for those items. Please suggest me how can i achieve this.



Thanks in advance,

Ekadeep K