Explorar o código

fix(templating): another fix for templating and custom all value escaping, fixes #4787

Torkel Ödegaard %!s(int64=9) %!d(string=hai) anos
pai
achega
1dfeb192a3

+ 0 - 5
public/app/features/templating/templateValuesSrv.js

@@ -294,11 +294,6 @@ function (angular, _, kbn) {
     };
 
     this.addAllOption = function(variable) {
-      if (variable.allValue) {
-        variable.options.unshift({text: 'All', value: variable.allValue});
-        return;
-      }
-
       variable.options.unshift({text: 'All', value: "$__all"});
     };
 

+ 1 - 1
public/test/specs/templateValuesSrv-specs.js

@@ -280,7 +280,7 @@ define([
       });
 
       it('should add All option with custom value', function() {
-        expect(scenario.variable.options[0].value).to.be('*');
+        expect(scenario.variable.options[0].value).to.be('$__all');
       });
     });