Commit e86dfcf5 by Carl Bergquist

rename mavgoptions to more generic pipelineaggs

parent 8e18f2c5
...@@ -13,21 +13,21 @@ function (angular, _, queryDef) { ...@@ -13,21 +13,21 @@ function (angular, _, queryDef) {
$scope.metricAggTypes = queryDef.metricAggTypes; $scope.metricAggTypes = queryDef.metricAggTypes;
$scope.extendedStats = queryDef.extendedStats; $scope.extendedStats = queryDef.extendedStats;
$scope.mavgOptions = []; $scope.pipelineAggOptions = [];
$scope.init = function() { $scope.init = function() {
$scope.agg = metricAggs[$scope.index]; $scope.agg = metricAggs[$scope.index];
$scope.validateModel(); $scope.validateModel();
$scope.updateMavgOptions(); $scope.updatePipelineAggOptions();
}; };
$scope.updateMavgOptions = function() { $scope.updatePipelineAggOptions = function() {
$scope.mavgOptions = queryDef.getMovingAverageOptions($scope.target); $scope.pipelineAggOptions = queryDef.getMovingAverageOptions($scope.target);
}; };
$rootScope.onAppEvent('elastic-query-updated', function() { $rootScope.onAppEvent('elastic-query-updated', function() {
$scope.index = _.indexOf(metricAggs, $scope.agg); $scope.index = _.indexOf(metricAggs, $scope.agg);
$scope.updateMavgOptions(); $scope.updatePipelineAggOptions();
$scope.validateModel(); $scope.validateModel();
}, $scope); }, $scope);
...@@ -78,7 +78,7 @@ function (angular, _, queryDef) { ...@@ -78,7 +78,7 @@ function (angular, _, queryDef) {
$scope.toggleOptions = function() { $scope.toggleOptions = function() {
$scope.showOptions = !$scope.showOptions; $scope.showOptions = !$scope.showOptions;
$scope.updateMavgOptions(); $scope.updatePipelineAggOptions();
}; };
$scope.onChangeInternal = function() { $scope.onChangeInternal = function() {
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
Based on Based on
</li> </li>
<li> <li>
<metric-segment-model property="agg.pipelineAgg" options="mavgOptions" on-change="onChangeInternal()" css-class="last"></metric-segment-model> <metric-segment-model property="agg.pipelineAgg" options="pipelineAggOptions" on-change="onChangeInternal()" css-class="last"></metric-segment-model>
</li> </li>
</ul> </ul>
<div class="clearfix"></div> <div class="clearfix"></div>
......
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