Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
b8bca8ba
Commit
b8bca8ba
authored
Jul 14, 2013
by
Rashid Khan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed old mentions of eventBus, still need to refactor fields/table
parent
a768c9c1
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
17 additions
and
80 deletions
+17
-80
config.js
+1
-1
panels/bettermap/module.js
+1
-1
panels/dashcontrol/module.js
+2
-2
panels/derivequeries/module.js
+2
-10
panels/histogram/module.js
+1
-0
panels/hits/module.js
+2
-8
panels/map/module.js
+2
-7
panels/pie/module.js
+1
-8
panels/query/module.js
+1
-9
panels/timepicker/module.js
+2
-9
panels/trends/module.js
+2
-25
No files found.
config.js
View file @
b8bca8ba
...
...
@@ -20,7 +20,7 @@ var config = new Settings(
elasticsearch
:
"http://"
+
window
.
location
.
hostname
+
":9200"
,
// elasticsearch: 'http://localhost:9200',
kibana_index
:
"kibana-int"
,
modules
:
[
'histogram'
,
'map'
,
'pie'
,
'table'
,
'stringquery'
,
'sort'
,
modules
:
[
'histogram'
,
'map'
,
'pie'
,
'table'
'timepicker'
,
'text'
,
'fields'
,
'hits'
,
'dashcontrol'
,
'column'
,
'derivequeries'
,
'trends'
,
'bettermap'
,
'query'
],
}
...
...
panels/bettermap/module.js
View file @
b8bca8ba
...
...
@@ -15,7 +15,7 @@
*/
angular
.
module
(
'kibana.bettermap'
,
[])
.
controller
(
'bettermap'
,
function
(
$scope
,
eventBus
,
query
,
dashboard
,
filterSrv
)
{
.
controller
(
'bettermap'
,
function
(
$scope
,
query
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
panels/dashcontrol/module.js
View file @
b8bca8ba
...
...
@@ -27,7 +27,7 @@
*/
angular
.
module
(
'kibana.dashcontrol'
,
[])
.
controller
(
'dashcontrol'
,
function
(
$scope
,
$routeParams
,
$http
,
eventBus
,
timer
,
dashboard
)
{
.
controller
(
'dashcontrol'
,
function
(
$scope
,
$routeParams
,
$http
,
timer
,
dashboard
)
{
$scope
.
panel
=
$scope
.
panel
||
{};
// Set and populate defaults
...
...
@@ -150,7 +150,7 @@ angular.module('kibana.dashcontrol', [])
})
}
})
.
directive
(
'dashUpload'
,
function
(
timer
,
eventBus
,
dashboard
){
.
directive
(
'dashUpload'
,
function
(
timer
,
dashboard
){
return
{
restrict
:
'A'
,
link
:
function
(
scope
,
elem
,
attrs
)
{
...
...
panels/derivequeries/module.js
View file @
b8bca8ba
...
...
@@ -11,19 +11,11 @@
* size :: how many queries to generate
* fields :: a list of fields known to us
* query_mode :: how to create query
### Group Events
#### Sends
* query :: Always broadcast as an array, even in multi: false
* get_time :: Request the time object from the timepicker
#### Receives
* query :: An array of queries. This is probably needs to be fixed.
* time :: populate index and time
* fields :: A list of fields known to us
*/
angular
.
module
(
'kibana.derivequeries'
,
[])
.
controller
(
'derivequeries'
,
function
(
$scope
,
$rootScope
,
query
,
eventBus
,
fields
,
dashboard
,
filterSrv
)
{
.
controller
(
'derivequeries'
,
function
(
$scope
,
$rootScope
,
query
,
fields
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
panels/histogram/module.js
View file @
b8bca8ba
...
...
@@ -226,6 +226,7 @@ angular.module('kibana.histogram', [])
to
:
moment
.
utc
(
_to
),
field
:
$scope
.
panel
.
time_field
})
dashboard
.
refresh
();
}
...
...
panels/hits/module.js
View file @
b8bca8ba
...
...
@@ -13,16 +13,10 @@
* donut :: Only applies to 'pie' charts. Punches a hole in the chart for some reason
* tilt :: Only 'pie' charts. Janky 3D effect. Looks terrible 90% of the time.
* lables :: Only 'pie' charts. Labels on the pie?
### Group Events
#### Sends
* get_time :: On panel initialization get time range to query
#### Receives
* time :: An object containing the time range to use and the index(es) to query
* query :: An Array of queries, even if its only one
*/
angular
.
module
(
'kibana.hits'
,
[])
.
controller
(
'hits'
,
function
(
$scope
,
eventBus
,
query
,
dashboard
,
filterSrv
)
{
.
controller
(
'hits'
,
function
(
$scope
,
query
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
@@ -142,7 +136,7 @@ angular.module('kibana.hits', [])
$scope
.
get_data
();
}
}).
directive
(
'hitsChart'
,
function
(
eventBus
,
query
)
{
}).
directive
(
'hitsChart'
,
function
(
query
)
{
return
{
restrict
:
'A'
,
link
:
function
(
scope
,
elem
,
attrs
,
ctrl
)
{
...
...
panels/map/module.js
View file @
b8bca8ba
...
...
@@ -19,16 +19,11 @@
* spyable :: Show the 'eye' icon that reveals the last ES query
* index_limit :: This does nothing yet. Eventually will limit the query to the first
N indices
### Group Events
#### Sends
* get_time :: On panel initialization get time range to query
#### Receives
* time :: An object containing the time range to use and the index(es) to query
* query :: An Array of queries, this panel uses only the first one
*/
angular
.
module
(
'kibana.map'
,
[])
.
controller
(
'map'
,
function
(
$scope
,
$rootScope
,
eventBus
,
query
,
dashboard
,
filterSrv
)
{
.
controller
(
'map'
,
function
(
$scope
,
$rootScope
,
query
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
panels/pie/module.js
View file @
b8bca8ba
...
...
@@ -23,17 +23,10 @@
doesn't have a field
* spyable :: Show the 'eye' icon that displays the last ES query for this panel
### Group Events
#### Sends
* get_time :: On panel initialization get time range to query
#### Receives
* time :: An object containing the time range to use and the index(es) to query
* query :: An Array of queries, this panel will use the first in the array
*/
angular
.
module
(
'kibana.pie'
,
[])
.
controller
(
'pie'
,
function
(
$scope
,
$rootScope
,
eventBus
,
query
,
dashboard
,
filterSrv
)
{
.
controller
(
'pie'
,
function
(
$scope
,
$rootScope
,
query
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
panels/query/module.js
View file @
b8bca8ba
...
...
@@ -9,18 +9,10 @@
* query :: A string or an array of querys. String if multi is off, array if it is on
This should be fixed, it should always be an array even if its only
one element
* multi :: Allow input of multiple queries? true/false
* multi_arrange :: How to arrange multu query string panels, 'vertical' or 'horizontal'
### Group Events
#### Sends
* query :: Always broadcast as an array, even in multi: false
#### Receives
* query :: An array of queries. This is probably needs to be fixed.
*/
angular
.
module
(
'kibana.query'
,
[])
.
controller
(
'query'
,
function
(
$scope
,
eventBus
,
query
,
$rootScope
)
{
.
controller
(
'query'
,
function
(
$scope
,
query
,
$rootScope
)
{
// Set and populate defaults
var
_d
=
{
...
...
panels/timepicker/module.js
View file @
b8bca8ba
...
...
@@ -15,17 +15,10 @@
* enable :: true/false, enable auto refresh by default. Default: false
* interval :: Seconds between auto refresh. Default: 30
* min :: The lowest interval a user may set
### Group Events
#### Sends
* time :: Object Includes from, to and index
#### Receives
* get_time :: Receives an object containing a $id, broadcasts back to it.
*/
angular
.
module
(
'kibana.timepicker'
,
[])
.
controller
(
'timepicker'
,
function
(
$scope
,
$rootScope
,
eventBus
,
$timeout
,
timer
,
$http
,
dashboard
,
filterSrv
)
{
.
controller
(
'timepicker'
,
function
(
$scope
,
$rootScope
,
$timeout
,
timer
,
$http
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
@@ -228,7 +221,7 @@ angular.module('kibana.timepicker', [])
return
$scope
.
panel
.
filter_id
;
}
// Prefer to pass around Date() objects
in the EventBus
since interacting with
// Prefer to pass around Date() objects since interacting with
// moment objects in libraries that are expecting Date()s can be tricky
function
compile_time
(
time
)
{
time
=
_
.
clone
(
time
)
...
...
panels/trends/module.js
View file @
b8bca8ba
...
...
@@ -19,7 +19,7 @@
*/
angular
.
module
(
'kibana.trends'
,
[])
.
controller
(
'trends'
,
function
(
$scope
,
eventBus
,
kbnIndex
,
query
,
dashboard
,
filterSrv
)
{
.
controller
(
'trends'
,
function
(
$scope
,
kbnIndex
,
query
,
dashboard
,
filterSrv
)
{
// Set and populate defaults
var
_d
=
{
...
...
@@ -37,11 +37,7 @@ angular.module('kibana.trends', [])
$scope
.
$on
(
'refresh'
,
function
(){
$scope
.
get_data
()})
eventBus
.
register
(
$scope
,
'time'
,
function
(
event
,
time
){
set_time
(
time
)
});
// Now that we're all setup, request the time from our group
eventBus
.
broadcast
(
$scope
.
$id
,
$scope
.
panel
.
group
,
'get_time'
)
$scope
.
get_data
();
}
$scope
.
get_data
=
function
(
segment
,
query_id
)
{
...
...
@@ -173,19 +169,6 @@ angular.module('kibana.trends', [])
return
x
==
0
?
null
:
100
*
(
y
-
x
)
/
x
}
$scope
.
remove_query
=
function
(
q
)
{
$scope
.
panel
.
query
=
_
.
without
(
$scope
.
panel
.
query
,
q
);
$scope
.
get_data
();
}
$scope
.
add_query
=
function
(
label
,
query
)
{
$scope
.
panel
.
query
.
unshift
({
query
:
query
,
label
:
label
,
});
$scope
.
get_data
();
}
$scope
.
set_refresh
=
function
(
state
)
{
$scope
.
refresh
=
state
;
}
...
...
@@ -197,9 +180,4 @@ angular.module('kibana.trends', [])
$scope
.
$emit
(
'render'
);
}
function
set_time
(
time
)
{
$scope
.
time
=
time
;
$scope
.
get_data
();
}
})
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment