mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
This commit is contained in:
parent
0201ac24e7
commit
35f55cabf0
@ -1,6 +1,7 @@
|
|||||||
# 3.0.2 Stable (unreleased)
|
# 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 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)
|
# 3.0.1 Stable (2016-05-11)
|
||||||
|
|
||||||
|
@ -97,7 +97,8 @@ function (angular, _) {
|
|||||||
if (!str) {
|
if (!str) {
|
||||||
return false;
|
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) {
|
this.highlightVariablesAsHtml = function(str) {
|
||||||
|
@ -190,6 +190,11 @@ define([
|
|||||||
expect(contains).to.be(true);
|
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() {
|
it('should find it with [[var]] syntax', function() {
|
||||||
var contains = _templateSrv.containsVariable('this.[[test]].filters', 'test');
|
var contains = _templateSrv.containsVariable('this.[[test]].filters', 'test');
|
||||||
expect(contains).to.be(true);
|
expect(contains).to.be(true);
|
||||||
|
Loading…
Reference in New Issue
Block a user