You are viewing limited content. For full access, please sign in.

Question

Question

Weblink - Hide 'Sort by' Drop Down Box

asked on January 30, 2023

We have a client on Weblink 11 and they want the 'Sort Results By' drop down box to display the following:

Unfortunately the only way we know how to make it do this is to add the 'Sort by' option and set 'Path' as the default. That results in two problems.

1) The client does not want two drop down boxes, they only want one.

2) It's introducing an extra click to get the 'Sort Results By' drop down box to populate the way we want it to.

I will demonstrate. I enter the search term "201207250516" and hit Submit once. This is what I get:

I have to click Submit again to make it appear the way the customer wants:

So this might be a ham-fisted approach, but this is what I want to do. I want to define the 'Sort by' option with 'Path' as the default but then I want to hide it from the user. And I want to somehow make a single click on the 'Submit' button behave as if it were a double click. Maybe that involves some kind of autoclick after the user hits 'Submit' the first time to perform the search.

Is this doable through some mix of CSS, .ASPX alterations and javascript? It would provide exactly what the client wants.

 

1 0

Replies

replied on January 30, 2023

The client just wants Path to be the default search option.

0 0
replied on January 31, 2023

I copied Sam Carson on this and got this reply:

"Hi Michael,

 

Thank you for the Answers post. I was able to reproduce the behavior you described there where clicking “Submit” a second time causes the “Sort result by:” value to flip to the one specified in the Search Form. This is not specific to the “Path” sort by option. If I set the Search Form’s default “Sort by” to “Name”, the first time I select Submit the results are sorted by “Date modified”, and the second time it flips to “Name” as expected.

 

This is likely a bug. I ran it by Dev and we do not believe the CustomSearch interface initially ignoring the specified default Sort By option in a Search Form is intended behavior. Our tentative suspicion is a timing issue between asynchronous calls. As it is easily reproducible with your instructions, I will file a priority issue with the Development team and request the following:

  1. A software hotfix/patch and timeline. I will convey the urgency and context that this is holding up an overdue production go-live, however, please understand that higher priority level requests are generally reserved for higher Severity issues, such as those involving security, potential data loss, or complete loss of core functionality.
  2. Guidance on a temporary workaround, such as a JavaScript/CSS modification, if we could not expect the hotfix within two weeks.

 

The correct route to take almost certainly involves getting the Double Submit bug fixed and then configuring the Search Form’s Sort Option with Path as the Default. If they are really hung up on there being “two dropdowns”, it is almost certainly easiest to simply hide that search form element with CSS. I would avoid trying to auto select the Path value from the results pane dropdown when it clearly does not necessarily exist as an option for everyone until after the Search Form Sort Option injects it there."

 

I'm glad he was able to reproduce the issue and hopefully they'll be able to get a fix or workaround in place soon.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.