mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Escape typeahead values in query_part
This commit is contained in:
parent
3a25a0de83
commit
20c1a58488
@ -103,7 +103,7 @@ export function queryPartEditorDirective($compile, templateSrv) {
|
|||||||
$scope.$apply(() => {
|
$scope.$apply(() => {
|
||||||
$scope.handleEvent({ $event: { name: 'get-param-options' } }).then(result => {
|
$scope.handleEvent({ $event: { name: 'get-param-options' } }).then(result => {
|
||||||
const dynamicOptions = _.map(result, op => {
|
const dynamicOptions = _.map(result, op => {
|
||||||
return op.value;
|
return _.escape(op.value);
|
||||||
});
|
});
|
||||||
callback(dynamicOptions);
|
callback(dynamicOptions);
|
||||||
});
|
});
|
||||||
@ -117,6 +117,7 @@ export function queryPartEditorDirective($compile, templateSrv) {
|
|||||||
minLength: 0,
|
minLength: 0,
|
||||||
items: 1000,
|
items: 1000,
|
||||||
updater: value => {
|
updater: value => {
|
||||||
|
value = _.unescape(value);
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
inputBlur.call($input[0], paramIndex);
|
inputBlur.call($input[0], paramIndex);
|
||||||
}, 0);
|
}, 0);
|
||||||
|
Loading…
Reference in New Issue
Block a user