Skip to content

Commit 7bfbe0e

Browse files
committed
Replace variables via template service.
1 parent 1348ff3 commit 7bfbe0e

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/datasource.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ export class DataSource extends DataSourceApi<LFQuery, LFDataSourceOptions> {
6060
sparql = sparql.replace(/[?$]_from/g, fromTime.toString());
6161
sparql = sparql.replace(/[?$]_to/g, toTime.toString());
6262

63+
sparql = this.templateSrv.replace(sparql);
64+
6365
console.log("final query", sparql);
6466

6567
const fetchFunc = async (input: Request | string, init?: RequestInit): Promise<Response> => {

0 commit comments

Comments
 (0)