mirror of
https://github.com/grafana/grafana.git
synced 2024-12-01 21:19:28 -06:00
20 lines
371 B
Go
20 lines
371 B
Go
package pushurl
|
|
|
|
import (
|
|
"net/url"
|
|
"strings"
|
|
)
|
|
|
|
const (
|
|
frameFormatParam = "gf_live_frame_format"
|
|
)
|
|
|
|
// FrameFormatFromValues extracts frame format tip from url values.
|
|
func FrameFormatFromValues(values url.Values) string {
|
|
frameFormat := strings.ToLower(values.Get(frameFormatParam))
|
|
if frameFormat == "" {
|
|
frameFormat = "labels_column"
|
|
}
|
|
return frameFormat
|
|
}
|