Commit 74ae756d by Torkel Ödegaard Committed by GitHub

Fix: Graphite query ast to string fix (#16297)

Fixes #16291
parent 5c3a0a62
......@@ -19,6 +19,7 @@ export default class GraphiteQuery {
this.datasource = datasource;
this.target = target;
this.templateSrv = templateSrv;
this.scopedVars = scopedVars;
this.parseTarget();
this.removeTagValue = '-- remove tag --';
......@@ -162,7 +163,9 @@ export default class GraphiteQuery {
updateModelTarget(targets) {
const wrapFunction = (target: string, func: any) => {
return func.render(target, this.templateSrv.replace);
return func.render(target, (value: string) => {
return this.templateSrv.replace(value, this.scopedVars);
});
};
if (!this.target.textEditor) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment