-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
fix(dashboards): temporary filters broken when changing values #104482
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,6 +10,7 @@ export type GenericFilterSelectorProps = { | |
| onRemoveFilter: (filter: GlobalFilter) => void; | ||
| onUpdateFilter: (filter: GlobalFilter) => void; | ||
| searchBarData: SearchBarData; | ||
| disableRemoveFilter?: boolean; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug:
|
||
| }; | ||
|
|
||
| function getFilterSelector( | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -192,6 +192,7 @@ export type GlobalFilter = { | |
| tag: Tag; | ||
| // The raw filter condition string (e.g. 'tagKey:[values,...]') | ||
| value: string; | ||
| isTemporary?: boolean; | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. With this new |
||
| }; | ||
|
|
||
| /** | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Release filter change clears temporary filters from URL
When the release filter is changed via
ReleasesSelectControl, the handler callsonDashboardFilterChangewithout includingTEMPORARY_FILTERS. The new code indetail.tsxalways setsfilterParams[TEMPORARY_FILTERS]- when it's not provided, it defaults to['']. This overwrites any existingtemporaryFiltersin the URL, effectively clearing temporary filters when users change the release filter. Before this PR, theTEMPORARY_FILTERSkey wasn't set infilterParams, so existing URL values were preserved. The fix requires the release handler to separate and pass temporary filters likeupdateGlobalFiltersdoes.Additional Locations (1)
static/app/views/dashboards/detail.tsx#L518-L525