mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Alerting: Integrate alerts with folders (#45763)
* Add Alert rules tab
* Add pagination and a simple name-based filtering
* Add name and label based filtering
* Improve pagination, handle the no results case
* Add tests for alerts folder view
* Add label filtering by clicking a tag
* Add tests for matcher to string method
* Add sorting, improve styles
* Use simple Select component for sorting
* Update default page size
* Remove unused code
* Use existingc thunk
* chore: update swagger spec
* Revert "chore: update swagger spec"
This reverts commit ee79ec7341.
* Code cleanup
* Fix ts
Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>
This commit is contained in:
@@ -46,3 +46,13 @@ function getRefId(num: number): string {
|
||||
return getRefId(Math.floor(num / letters.length) - 1) + letters[num % letters.length];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the input value for non empty string and undefined otherwise
|
||||
*
|
||||
* It is inadvisable to set a query param to an empty string as it will be added to the URL.
|
||||
* It is better to keep it undefined so the param won't be added to the URL at all.
|
||||
*/
|
||||
export function getQueryParamValue(value: string | undefined | null): string | undefined {
|
||||
return value || undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user