From 0d8f1fab9b8f6c2ec82508f445b74b7d0d3b07b7 Mon Sep 17 00:00:00 2001 From: Rashid Khan Date: Fri, 8 Feb 2013 15:57:24 -0700 Subject: [PATCH] fixed histogram and pie editors, added hits and map editors --- dashboards.js | 4 ++-- panels/histogram/editor.html | 2 +- panels/histogram/module.js | 1 + panels/hits/editor.html | 11 +++++++++++ panels/map/editor.html | 11 +++++++++++ panels/pie/editor.html | 12 ++++++------ panels/pie/module.js | 8 ++++++++ 7 files changed, 40 insertions(+), 9 deletions(-) create mode 100644 panels/map/editor.html diff --git a/dashboards.js b/dashboards.js index 1e529dbadd5..c9a09967e4b 100644 --- a/dashboards.js +++ b/dashboards.js @@ -193,8 +193,8 @@ var dashboards = labels : false, colors : ['#BF3030','#1D7373','#86B32D','#A60000','#006363','#679B00'], field : 'country', - mode : "query", - query : { query:"falstaff" } + mode : "terms", + query : { query:"*", field:"play_name" } }, { type : "text", diff --git a/panels/histogram/editor.html b/panels/histogram/editor.html index 879707e9068..67eb79dd7b2 100644 --- a/panels/histogram/editor.html +++ b/panels/histogram/editor.html @@ -28,7 +28,7 @@
- +
diff --git a/panels/histogram/module.js b/panels/histogram/module.js index 2e239bbaab1..5fd402e7de4 100644 --- a/panels/histogram/module.js +++ b/panels/histogram/module.js @@ -25,6 +25,7 @@ angular.module('kibana.histogram', []) $scope.remove_query = function(q) { $scope.panel.query = _.without($scope.panel.query,q); + $scope.get_data(); } $scope.add_query = function(label,query) { diff --git a/panels/hits/editor.html b/panels/hits/editor.html index e69de29bb2d..3d1852ed454 100644 --- a/panels/hits/editor.html +++ b/panels/hits/editor.html @@ -0,0 +1,11 @@ +
+
+
+
Query
+ + +
+
+
Font Size
+ +
diff --git a/panels/map/editor.html b/panels/map/editor.html new file mode 100644 index 00000000000..3b83a0b7547 --- /dev/null +++ b/panels/map/editor.html @@ -0,0 +1,11 @@ +
+
+
+
Query
+ + +
+
+
Map
+ +
diff --git a/panels/pie/editor.html b/panels/pie/editor.html index cb2932a2ec7..291307eade7 100644 --- a/panels/pie/editor.html +++ b/panels/pie/editor.html @@ -31,8 +31,6 @@
-
-
Label
@@ -46,12 +44,11 @@
+
+
-
- -
-
+
@@ -62,6 +59,9 @@
+
+ +
diff --git a/panels/pie/module.js b/panels/pie/module.js index a4c6786c02f..6f0d73a258e 100644 --- a/panels/pie/module.js +++ b/panels/pie/module.js @@ -33,6 +33,14 @@ angular.module('kibana.pie', []) eventBus.broadcast($scope.$id,$scope.panel.group,'get_time') } + + $scope.remove_query = function(q) { + if($scope.panel.mode !== 'query') + return false; + $scope.panel.query = _.without($scope.panel.query,q); + $scope.get_data(); + } + $scope.add_query = function(label,query) { if($scope.panel.mode !== 'query') return false;