Issues with /variable with different text and value
umyio opened this issue · 4 comments
umyio commented
Hi,
I'm using Grafana 8.5.3 and the current version of the plugin.
I've implemented the POST /variable
endpoint and it returns the following:
[
{
"__text":"None",
"value":"0"
},
{
"__text":"TimedOut",
"value":"1"
},
{
"__text":"OkPassed",
"value":"2"
},
{
"__text":"Ok",
"value":"3"
},
{
"__text":"Warning",
"value":"4"
},
{
"__text":"Error",
"value":"5"
}
]
In Grafana though I see that the text and the value are used as separate values for a variable, so the variable values consist of all values and all texts.
Any idea what the issue could be?
Thank you for your help.
Best wishes, Anton
simPod commented
Hi, try changing the key to __value
…On Mon, May 23, 2022, 17:57 umyio ***@***.***> wrote:
Hi,
I'm using Grafana 8.5.3 and the current version of the plugin.
I've implemented the POST /variable endpoint and it returns the following:
[
{
"__text":"None",
"value":"0"
},
{
"__text":"TimedOut",
"value":"1"
},
{
"__text":"OkPassed",
"value":"2"
},
{
"__text":"Ok",
"value":"3"
},
{
"__text":"Warning",
"value":"4"
},
{
"__text":"Error",
"value":"5"
}
]
In Grafana though I see that the text and the value are used as separate
values for a variable, so the variable values consist of all values and all
texts.
Any idea what the issue could be?
Thank you for your help.
Best wishes, Anton
—
Reply to this email directly, view it on GitHub
<#287>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACQAJISUJTA5CM3MJT2OBLVLOTGVANCNFSM5WWKKEQQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
umyio commented
Hi,
thank you. That modification worked:
[
{
"__text":"None",
"__value":"0"
},
{
"__text":"TimedOut",
"__value":"1"
},
{
"__text":"OkPassed",
"__value":"2"
},
{
"__text":"Ok",
"__value":"3"
},
{
"__text":"Warning",
"__value":"4"
},
{
"__text":"Error",
"__value":"5"
}
]
Would you mind to update the ReadMe.md when you have time to reflect that?
simPod commented
Can you send PR? thanks
…On Mon, May 23, 2022 at 6:03 PM umyio ***@***.***> wrote:
Hi,
thank you. That modification worked:
[
{
"__text":"None",
"__value":"0"
},
{
"__text":"TimedOut",
"__value":"1"
},
{
"__text":"OkPassed",
"__value":"2"
},
{
"__text":"Ok",
"__value":"3"
},
{
"__text":"Warning",
"__value":"4"
},
{
"__text":"Error",
"__value":"5"
}
]
Would you mind to update the ReadMe.md when you have time to reflect that?
—
Reply to this email directly, view it on GitHub
<#287 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACQAJPONDCRD46SBI7QMETVLOT6XANCNFSM5WWKKEQQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
umyio commented
Done