mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-12-01 14:47:38 +00:00
17 lines
311 B
Text
17 lines
311 B
Text
{% stripspace %}
|
|
|
|
// FieldNamesResponse formats /select/logsql/field_names response
|
|
{% func FieldNamesResponse(names []string) %}
|
|
{
|
|
"names":[
|
|
{% if len(names) > 0 %}
|
|
{%q= names[0] %}
|
|
{% for _, v := range names[1:] %}
|
|
,{%q= v %}
|
|
{% endfor %}
|
|
{% endif %}
|
|
]
|
|
}
|
|
{% endfunc %}
|
|
|
|
{% endstripspace %}
|