Skip to content

[BUG] Saved status tool filter preferences are active but not shown #3442

@lunkwill42

Description

@lunkwill42

Describe the bug

As part of testing CSRF issues, I discovered that the Status tool has an unrelated problem:

I can change and save my status filter settings, and it works. But when I reload the status page, it appears that my saved preferences are not there any more, yet they are demonstrably in effect in the status list.

To Reproduce

To effectively reproduce this bug, you must have active alerts in your NAV installation.

Steps to reproduce the behavior:

  1. Go to Toolbox → Status
  2. Click on Show status filter
  3. Click in the Choose fields to filter status by form field
  4. Type event and select Event type from the dropdown list
  5. Click in the newly appeared Event type form field.
  6. Type box and select boxState value from the dropdown list.
  7. Observe and verify that the alert list has indeed been filtered to only show boxDown alerts (this only works if you have alerts of several types in the list to begin with
  8. Click on the Save as my default status fitler button.
  9. Reload the page.
  10. Observe that the alerts still seem to be filtered by the saved criteria, yet the filter form now looks like it has been reset.

Expected behavior

When loaded, the Status filter form should display the user's saved filters.

Screenshots

Before reloading page:

Image

After reloading page:

Image

Environment (please complete the following information):

  • If the problem is with the web ui: Linux, Firefox 141.0
  • OS on the NAV server: Debian 12 (Bookworm)
  • NAV version installed: master (6f93c7b)
  • Method of installation: devcontainer

Additional context

I have no idea when this stopped working, but it definitely did work at some point.

Metadata

Metadata

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions