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
3cbfe21b
Commit
3cbfe21b
authored
Sep 28, 2015
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into cloudwatch
parents
25d7b8d0
cb7424ce
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
49 additions
and
65 deletions
+49
-65
public/app/features/templating/templateSrv.js
+4
-1
public/app/features/templating/templateValuesSrv.js
+4
-1
public/app/panels/graph/axisEditor.html
+18
-49
public/app/panels/singlestat/module.js
+8
-0
public/app/panels/singlestat/singleStatPanel.js
+2
-2
public/app/partials/playlist.html
+8
-8
public/app/plugins/datasource/elasticsearch/queryBuilder.js
+1
-0
public/less/variables.dark.less
+1
-1
public/less/variables.light.less
+1
-1
public/test/specs/templateSrv-specs.js
+1
-1
public/test/specs/templateValuesSrv-specs.js
+1
-1
No files found.
public/app/features/templating/templateSrv.js
View file @
3cbfe21b
...
...
@@ -44,7 +44,10 @@ function (angular, _) {
return
'('
+
value
.
join
(
'|'
)
+
')'
;
}
case
"lucene"
:
{
return
'('
+
value
.
join
(
' OR '
)
+
')'
;
var
quotedValues
=
_
.
map
(
value
,
function
(
val
)
{
return
'
\\\
"'
+
val
+
'
\\\
"'
;
});
return
'('
+
quotedValues
.
join
(
' OR '
)
+
')'
;
}
case
"pipe"
:
{
return
value
.
join
(
'|'
);
...
...
public/app/features/templating/templateValuesSrv.js
View file @
3cbfe21b
...
...
@@ -262,7 +262,10 @@ function (angular, _, kbn) {
break
;
}
case
'lucene'
:
{
allValue
=
'('
+
_
.
pluck
(
variable
.
options
,
'text'
).
join
(
' OR '
)
+
')'
;
var
quotedValues
=
_
.
map
(
variable
.
options
,
function
(
val
)
{
return
'
\\\
"'
+
val
.
text
+
'
\\\
"'
;
});
allValue
=
'('
+
quotedValues
.
join
(
' OR '
)
+
')'
;
break
;
}
case
'regex values'
:
{
...
...
public/app/panels/graph/axisEditor.html
View file @
3cbfe21b
...
...
@@ -4,7 +4,7 @@
<div
class=
"tight-form"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 80px"
>
<strong>
Left Y
</strong>
Left Y
</li>
<li
class=
"tight-form-item"
>
Unit
...
...
@@ -46,10 +46,10 @@
</ul>
<div
class=
"clearfix"
></div>
</div>
<div
class=
"tight-form"
>
<div
class=
"tight-form
last
"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 80px"
>
<strong>
Right Y
</strong>
Right Y
</li>
<li
class=
"tight-form-item"
>
Unit
...
...
@@ -97,7 +97,7 @@
<div
class=
"tight-form"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 80px"
>
<strong>
Show Axis
</strong>
Show Axis
</li>
<li
class=
"tight-form-item"
>
X-Axis
...
...
@@ -114,10 +114,10 @@
</ul>
<div
class=
"clearfix"
></div>
</div>
<div
class=
"tight-form"
>
<div
class=
"tight-form
last
"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 80px"
>
<strong>
Thresholds
</strong>
Thresholds
</li>
<li
class=
"tight-form-item"
>
Level 1
...
...
@@ -140,11 +140,7 @@
<spectrum-picker
ng-model=
"panel.grid.threshold2Color"
ng-change=
"render()"
></spectrum-picker>
</li>
<li
class=
"tight-form-item last"
>
Line mode
<input
class=
"cr1"
id=
"panel.grid.thresholdLine"
type=
"checkbox"
ng-model=
"panel.grid.thresholdLine"
ng-checked=
"panel.grid.thresholdLine"
ng-change=
"render()"
>
<label
for=
"panel.grid.thresholdLine"
class=
"cr1"
></label>
<editor-checkbox
text=
"Line mode"
model=
"panel.grid.thresholdLine"
change=
"render()"
></editor-checkbox>
</li>
</ul>
<div
class=
"clearfix"
></div>
...
...
@@ -157,31 +153,19 @@
<div
class=
"tight-form last"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 110px"
>
<strong>
Legend
</strong>
Legend
</li>
<li
class=
"tight-form-item"
>
Show
<input
class=
"cr1"
id=
"panel.legend.show"
type=
"checkbox"
ng-model=
"panel.legend.show"
ng-checked=
"panel.legend.show"
ng-change=
"get_data()"
>
<label
for=
"panel.legend.show"
class=
"cr1"
></label>
<editor-checkbox
text=
"Show"
model=
"panel.legend.show"
change=
"get_data()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item"
>
Table
<input
class=
"cr1"
id=
"panel.legend.alignAsTable"
type=
"checkbox"
ng-model=
"panel.legend.alignAsTable"
ng-checked=
"panel.legend.alignAsTable"
ng-change=
"render()"
>
<label
for=
"panel.legend.alignAsTable"
class=
"cr1"
></label>
<editor-checkbox
text=
"Table"
model=
"panel.legend.alignAsTable"
change=
"render()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item"
>
Right side
<input
class=
"cr1"
id=
"panel.legend.rightSide"
type=
"checkbox"
ng-model=
"panel.legend.rightSide"
ng-checked=
"panel.legend.rightSide"
ng-change=
"render()"
>
<label
for=
"panel.legend.rightSide"
class=
"cr1"
></label>
<editor-checkbox
text=
"Right side"
model=
"panel.legend.rightSide"
change=
"render()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item last"
>
<span
bs-tooltip=
"'Hides series with only null values'"
>
Hide empty
<span>
<input
class=
"cr1"
id=
"panel.legend.hideEmpty"
type=
"checkbox"
ng-model=
"panel.legend.hideEmpty"
ng-checked=
"panel.legend.hideEmpty"
ng-change=
"render()"
>
<label
for=
"panel.legend.hideEmpty"
class=
"cr1"
></label>
<editor-checkbox
text=
"Hide empty"
model=
"panel.legend.hideEmpty"
change=
"render()"
></editor-checkbox>
</li>
</ul>
<div
class=
"clearfix"
></div>
...
...
@@ -191,37 +175,22 @@
<div
class=
"tight-form"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
style=
"width: 105px"
>
<strong>
Legend values
</strong>
Legend values
</li>
<li
class=
"tight-form-item"
>
Min
<input
class=
"cr1"
id=
"panel.legend.min"
type=
"checkbox"
ng-model=
"panel.legend.min"
ng-checked=
"panel.legend.min"
ng-change=
"legendValuesOptionChanged()"
>
<label
for=
"panel.legend.min"
class=
"cr1"
></label>
<editor-checkbox
text=
"Min"
model=
"panel.legend.min"
change=
"legendValuesOptionChanged()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item"
>
Max
<input
class=
"cr1"
id=
"panel.legend.max"
type=
"checkbox"
ng-model=
"panel.legend.max"
ng-checked=
"panel.legend.max"
ng-change=
"legendValuesOptionChanged()"
>
<label
for=
"panel.legend.max"
class=
"cr1"
></label>
<editor-checkbox
text=
"Max"
model=
"panel.legend.max"
change=
"legendValuesOptionChanged()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item"
>
Avg
<input
class=
"cr1"
id=
"panel.legend.avg"
type=
"checkbox"
ng-model=
"panel.legend.avg"
ng-checked=
"panel.legend.avg"
ng-change=
"legendValuesOptionChanged()"
>
<label
for=
"panel.legend.avg"
class=
"cr1"
></label>
<editor-checkbox
text=
"Avg"
model=
"panel.legend.avg"
change=
"legendValuesOptionChanged()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item"
>
Current
<input
class=
"cr1"
id=
"panel.legend.current"
type=
"checkbox"
ng-model=
"panel.legend.current"
ng-checked=
"panel.legend.current"
ng-change=
"legendValuesOptionChanged()"
>
<label
for=
"panel.legend.current"
class=
"cr1"
></label>
<editor-checkbox
text=
"Current"
model=
"panel.legend.current"
change=
"legendValuesOptionChanged()"
></editor-checkbox>
</li>
<li
class=
"tight-form-item last"
>
Total
<input
class=
"cr1"
id=
"panel.legend.total"
type=
"checkbox"
ng-model=
"panel.legend.total"
ng-checked=
"panel.legend.total"
ng-change=
"legendValuesOptionChanged()"
>
<label
for=
"panel.legend.total"
class=
"cr1"
></label>
<editor-checkbox
text=
"Total"
model=
"panel.legend.total"
change=
"legendValuesOptionChanged()"
></editor-checkbox>
</li>
</ul>
<div
class=
"clearfix"
></div>
...
...
public/app/panels/singlestat/module.js
View file @
3cbfe21b
...
...
@@ -186,6 +186,14 @@ function (angular, app, _, kbn, TimeSeries, PanelMeta) {
$scope
.
setValues
=
function
(
data
)
{
data
.
flotpairs
=
[];
if
(
$scope
.
series
.
length
>
1
)
{
$scope
.
inspector
.
error
=
new
Error
();
$scope
.
inspector
.
error
.
message
=
'Multiple Series Error'
;
$scope
.
inspector
.
error
.
data
=
'Metric query returns '
+
$scope
.
series
.
length
+
' series. Single Stat Panel expects a single series.
\
n
\
nResponse:
\
n'
+
JSON
.
stringify
(
$scope
.
series
);
throw
$scope
.
inspector
.
error
;
}
if
(
$scope
.
series
&&
$scope
.
series
.
length
>
0
)
{
var
lastPoint
=
_
.
last
(
$scope
.
series
[
0
].
datapoints
);
var
lastValue
=
_
.
isArray
(
lastPoint
)
?
lastPoint
[
0
]
:
null
;
...
...
public/app/panels/singlestat/singleStatPanel.js
View file @
3cbfe21b
...
...
@@ -122,8 +122,8 @@ function (angular, app, _, $) {
xaxis
:
{
show
:
false
,
mode
:
"time"
,
min
:
scope
.
range
.
from
.
getTime
(),
max
:
scope
.
range
.
to
.
getTime
(),
min
:
scope
.
range
.
from
.
valueOf
(),
max
:
scope
.
range
.
to
.
valueOf
(),
},
grid
:
{
hoverable
:
false
,
show
:
false
},
};
...
...
public/app/partials/playlist.html
View file @
3cbfe21b
...
...
@@ -12,10 +12,10 @@
</div>
<div
class=
"gf-box-body"
>
<div
class=
"row"
style=
"margin-bottom: 10px;"
>
<div
class=
"span
6
"
>
<div
class=
"row
-fluid
"
style=
"margin-bottom: 10px;"
>
<div
class=
"span
12
"
>
<div
style=
"display: inline-block"
>
<div
class=
"tight-form"
>
<div
class=
"tight-form
last
"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
>
Search
...
...
@@ -28,13 +28,11 @@
</div>
</div>
</div>
<div
class=
"span6"
>
<h5>
Playlist dashboards
</h5>
</div>
</div>
<div
class=
"row"
>
<div
class=
"row
-fluid
"
>
<div
class=
"span6"
>
<h5>
Search result
</h5>
<table
class=
"grafana-options-table"
>
<tr
ng-repeat=
"dashboard in filteredHits"
>
<td
style=
"white-space: nowrap;"
>
...
...
@@ -55,6 +53,8 @@
</table>
</div>
<div
class=
"span6"
>
<h5>
Playlist dashboards
</h5>
<table
class=
"grafana-options-table"
>
<tr
ng-repeat=
"dashboard in playlist"
>
<td
style=
"white-space: nowrap;"
>
...
...
@@ -78,7 +78,7 @@
<br>
<br>
<div
class=
"pull-left"
>
<div
class=
"tight-form"
>
<div
class=
"tight-form
last
"
>
<ul
class=
"tight-form-list"
>
<li
class=
"tight-form-item"
>
Timespan between dashboard change
...
...
public/app/plugins/datasource/elasticsearch/queryBuilder.js
View file @
3cbfe21b
...
...
@@ -174,6 +174,7 @@ function (angular) {
"1"
:
{
"terms"
:
{
"field"
:
queryDef
.
field
,
"size"
:
0
,
"order"
:
{
"_term"
:
"asc"
}
...
...
public/less/variables.dark.less
View file @
3cbfe21b
...
...
@@ -68,7 +68,7 @@
@altFontFamily: @serifFontFamily;
@headingsFontFamily: inherit; // empty to use BS default, @baseFontFamily
@headingsFontWeight:
normal
; // instead of browser default, bold
@headingsFontWeight:
bold
; // instead of browser default, bold
@headingsColor: darken(@white,11%); // empty to use BS default, @textColor
@inputText: @black;
...
...
public/less/variables.light.less
View file @
3cbfe21b
...
...
@@ -80,7 +80,7 @@
@altFontFamily: @serifFontFamily;
@headingsFontFamily: inherit; // empty to use BS default, @baseFontFamily
@headingsFontWeight:
normal
; // instead of browser default, bold
@headingsFontWeight:
bold
; // instead of browser default, bold
@headingsColor: @textColor; // empty to use BS default, @textColor
...
...
public/test/specs/templateSrv-specs.js
View file @
3cbfe21b
...
...
@@ -68,7 +68,7 @@ define([
value
:
[
'test'
,
'test2'
],
}
});
expect
(
result
).
to
.
be
(
'(
test OR test2
)'
);
expect
(
result
).
to
.
be
(
'(
\\\
"test
\\\
" OR
\\\
"test2
\\\
"
)'
);
});
it
(
'multi value and regex format should render regex string'
,
function
()
{
...
...
public/test/specs/templateValuesSrv-specs.js
View file @
3cbfe21b
...
...
@@ -321,7 +321,7 @@ define([
});
it
(
'should add lucene glob'
,
function
()
{
expect
(
scenario
.
variable
.
options
[
0
].
value
).
to
.
be
(
'(
backend1 OR backend2
)'
);
expect
(
scenario
.
variable
.
options
[
0
].
value
).
to
.
be
(
'(
\\\
"backend1
\\\
" OR
\\\
"backend2
\\\
"
)'
);
});
});
...
...
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