Index dropdown initially displays "ID" but is set empty

Description

When you first enter the Codex Search application at http://localhost:3000/codexsearch?sort=title both source filters are unselected (so that you will get results from both sources), and no query-index is selected – but, because the "no query-index" option is disabled when the EBSCO KB source is included, it displays as though "ID" was selected.

The "no query-index" option means that the app will try to search in several fields (title, publishers, etc.) – which is not supported by the Codex source EBSCO KB.

CSP Request Details

None

CSP Rejection Details

None

Potential Workaround

None

Checklist

hide

TestRail: Results

Activity

Show:

Mike Taylor January 12, 2018 at 10:19 PM

... Which ugh requires a one-line change in stripes-components, too.

Mike Taylor January 12, 2018 at 9:56 PM

I've poked around a fair bit with this, having ui-search's render method notice if the selected query index is one that's disabled under the current selection of sources. This only sort of works, because while we can (and I do) change which index appears selected, the actual query that gets generated is from the qindex URL query parameter. We can change that, but doing so from within render is bad practice, and sure enough it doesn't consistently work – specifically, on the first render, the URL for some reason doesn't get updated.

Conclusion: we need to update the qindex parameter as a side-effect of changing the values of the Source filter. That means that <SearchAndSort> needs the ability to call back to the application when a filter changes, which means sigh yet another new STSMACOM issue.

Done

Details

Assignee

Reporter

Labels

Priority

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs
Created January 10, 2018 at 6:24 PM
Updated January 13, 2018 at 12:21 AM
Resolved January 13, 2018 at 12:21 AM
TestRail: Cases
TestRail: Runs

Flag notifications