added pointer to show more, reset values on new query

This commit is contained in:
Patrick O'Carroll 2018-04-24 17:40:03 +02:00
parent c2cc77fa08
commit a40314022b
2 changed files with 2 additions and 1 deletions

View File

@ -97,6 +97,7 @@ export class VariableEditorCtrl {
};
$scope.runQuery = function() {
$scope.optionsLimit = 20;
return variableSrv.updateOptions($scope.current).catch(err => {
if (err.data && err.data.message) {
err.message = err.data.message;

View File

@ -286,7 +286,7 @@
<span class="gf-form-label">{{option.text}}</span>
</div>
<div class="gf-form" ng-if= "current.options.length > optionsLimit">
<span class="gf-form-label btn-secondary" ng-click="showMoreOptions()">Show more</span>
<a class="gf-form-label btn-secondary" ng-click="showMoreOptions()">Show more</a>
</div>
</div>
</div>