Users App Loses Filters After Search Cleared (Despite Their Being Checked in the UI)

Description

Overview: If you search for something in Users and then clear your search, you suddenly see all records in your search results, regardless of what filters you have applied (the filters remain checked, which adds to the confusion).

Steps to Repro:

  1. Log into folio-stable as diku-admin

  2. Go to users

  3. Notice that only active users (users with a check in the active column) are shown in search results (this is good)

  4. Type something into the search box to execute a search

  5. Clear out the search box by clicking the X in the search input box

Expected: Only active users should display in the results list because that filter is still applied

Actual: Inactive users (without the checkmark) are now displaying

Additional info: This bug applies to any applied filter.

Environment

None

Potential Workaround

None

Attachments

1
  • 20 Jul 2017, 11:50 AM

Checklist

hide

TestRail: Results

Activity

Show:

Charlotte Whitt August 1, 2017 at 10:13 PM

Manually tested in FOLIO test http://folio-testing.aws.indexdata.com/ version @folio/users 2.8.100430, using Chrome.

Tested using different filters in User status, and in Patron groups. Looks good as spec'ed. I'll close the issue as done.

Mike Taylor July 26, 2017 at 10:52 AM

I filed the related issue as https://folio-org.atlassian.net/browse/UIU-167#icft=UIU-167. This one can now be closed.

Mike Taylor July 26, 2017 at 10:48 AM

Fixed in https://github.com/folio-org/ui-users/commit/5d959547ee0feeb423406c0033213ea696448831

However, as noted in that commit, the UI state (filters, highlighted sort criterion) are not changed to match what is specified in the new URL. That is a distinct problem with potentially significant ramifications, which I shall file as a separate issue.

Mike Taylor July 20, 2017 at 1:20 PM

We don't really need to pursue this, but ...

I used the term "virgin state" specifically to differentiate it from the "default state" or "starting state", which has the "Active" filter checked and the sort-order set to Name.

Cate Boerema July 20, 2017 at 1:07 PM

Well, the "virgin state" has the active filter applied by default, so even if we were resetting to the virgin state, that should still be applied. That said, we don't want clearing the search to remove the filters. I never realized until now that it was doing that (because the filters remain checked in the UI even though they no longer apply to the search results). I will change this bug description to be more generic since I now see it's not just the Status Filter that is impacted.

Done

Details

Assignee

Reporter

Priority

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs
Created July 20, 2017 at 11:50 AM
Updated August 2, 2017 at 10:32 AM
Resolved August 2, 2017 at 10:32 AM
TestRail: Cases
TestRail: Runs

Flag notifications