Commit 6886faa9 by Torkel Ödegaard

feat(plugins): fixed cloudwatch query editor

parent 3f945e88
...@@ -6,14 +6,14 @@ ...@@ -6,14 +6,14 @@
<i class="fa fa-bars"></i> <i class="fa fa-bars"></i>
</a> </a>
<ul class="dropdown-menu pull-right" role="menu"> <ul class="dropdown-menu pull-right" role="menu">
<li role="menuitem"><a tabindex="1" ng-click="duplicateDataQuery(target)">Duplicate</a></li> <li role="menuitem"><a tabindex="1" ng-click="ctrl.duplicateDataQuery(target)">Duplicate</a></li>
<li role="menuitem"><a tabindex="1" ng-click="moveDataQuery($index, $index-1)">Move up</a></li> <li role="menuitem"><a tabindex="1" ng-click="ctrl.moveDataQuery($index, $index-1)">Move up</a></li>
<li role="menuitem"><a tabindex="1" ng-click="moveDataQuery($index, $index+1)">Move down</a></li> <li role="menuitem"><a tabindex="1" ng-click="ctrl.moveDataQuery($index, $index+1)">Move down</a></li>
</ul> </ul>
</div> </div>
</li> </li>
<li class="tight-form-item last"> <li class="tight-form-item last">
<a class="pointer" tabindex="1" ng-click="removeDataQuery(target)"> <a class="pointer" tabindex="1" ng-click="ctrl.removeDataQuery(target)">
<i class="fa fa-remove"></i> <i class="fa fa-remove"></i>
</a> </a>
</li> </li>
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
</li> </li>
<li> <li>
<a class="tight-form-item" <a class="tight-form-item"
ng-click="target.hide = !target.hide; get_data();" ng-click="target.hide = !target.hide; ctrl.refresh();"
role="menuitem"> role="menuitem">
<i class="fa fa-eye"></i> <i class="fa fa-eye"></i>
</a> </a>
...@@ -35,4 +35,4 @@ ...@@ -35,4 +35,4 @@
<div class="clearfix"></div> <div class="clearfix"></div>
</div> </div>
<cloudwatch-query-parameter target="target" datasource="datasource" on-change="refreshMetricData()"></cloudwatch-query-parameter> <cloudwatch-query-parameter target="target" datasource="ctrl.datasource" on-change="refreshMetricData()"></cloudwatch-query-parameter>
...@@ -16,7 +16,7 @@ function (angular, _) { ...@@ -16,7 +16,7 @@ function (angular, _) {
$scope.refreshMetricData = function() { $scope.refreshMetricData = function() {
if (!_.isEqual($scope.oldTarget, $scope.target)) { if (!_.isEqual($scope.oldTarget, $scope.target)) {
$scope.oldTarget = angular.copy($scope.target); $scope.oldTarget = angular.copy($scope.target);
$scope.get_data(); $scope.ctrl.refresh();
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment