Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
35f55cab
Commit
35f55cab
authored
May 12, 2016
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(templating): improved detection of nested template variables, fixes #4986, fixes #4987
parent
0201ac24
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
1 deletions
+8
-1
CHANGELOG.md
+1
-0
public/app/features/templating/templateSrv.js
+2
-1
public/test/specs/templateSrv-specs.js
+5
-0
No files found.
CHANGELOG.md
View file @
35f55cab
# 3.0.2 Stable (unreleased)
*
**Templating**
: Fixed issue mixing row repeat and panel repeats, fixes
[
#4988
](
https://github.com/grafana/grafana/issues/4988
)
*
**Templating**
: Fixed issue detecting dependencies in nested variables, fixes
[
#4987
](
https://github.com/grafana/grafana/issues/4987
)
, fixes
[
#4986
](
https://github.com/grafana/grafana/issues/4986
)
# 3.0.1 Stable (2016-05-11)
...
...
public/app/features/templating/templateSrv.js
View file @
35f55cab
...
...
@@ -97,7 +97,8 @@ function (angular, _) {
if
(
!
str
)
{
return
false
;
}
return
str
.
indexOf
(
'$'
+
variableName
)
!==
-
1
||
str
.
indexOf
(
'[['
+
variableName
+
']]'
)
!==
-
1
;
var
match
=
this
.
_regex
.
exec
(
str
);
return
match
&&
(
match
[
1
]
===
variableName
||
match
[
2
]
===
variableName
);
};
this
.
highlightVariablesAsHtml
=
function
(
str
)
{
...
...
public/test/specs/templateSrv-specs.js
View file @
35f55cab
...
...
@@ -190,6 +190,11 @@ define([
expect
(
contains
).
to
.
be
(
true
);
});
it
(
'should not find it if only part matches with $var syntax'
,
function
()
{
var
contains
=
_templateSrv
.
containsVariable
(
'this.$ServerDomain.filters'
,
'Server'
);
expect
(
contains
).
to
.
be
(
false
);
});
it
(
'should find it with [[var]] syntax'
,
function
()
{
var
contains
=
_templateSrv
.
containsVariable
(
'this.[[test]].filters'
,
'test'
);
expect
(
contains
).
to
.
be
(
true
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment