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
30512b70
Commit
30512b70
authored
Oct 02, 2014
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Plain Diff
Merge fix from 'v1.8.x' branch
Conflicts: CHANGELOG.md
parents
a9a51ee3
bc8fd62c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
5 deletions
+34
-5
CHANGELOG.md
+2
-1
src/app/services/dashboard/dashboardSrv.js
+10
-4
src/test/specs/dashboardSrv-specs.js
+22
-0
No files found.
CHANGELOG.md
View file @
30512b70
...
@@ -6,7 +6,8 @@
...
@@ -6,7 +6,8 @@
-
[
Issue #877
](
https://github.com/grafana/grafana/issues/877
)
. Graph: Smart auto decimal precision when using scaled unit formats
-
[
Issue #877
](
https://github.com/grafana/grafana/issues/877
)
. Graph: Smart auto decimal precision when using scaled unit formats
-
[
Issue #850
](
https://github.com/grafana/grafana/issues/850
)
. Graph: Shared tooltip that shows multiple series & crosshair line, thx @toni-moreno
-
[
Issue #850
](
https://github.com/grafana/grafana/issues/850
)
. Graph: Shared tooltip that shows multiple series & crosshair line, thx @toni-moreno
# 1.8.1 (unreleased)
=======
# 1.8.1 (2014-09-30)
**Fixes**
**Fixes**
-
[
Issue #855
](
https://github.com/grafana/grafana/issues/855
)
. Graph: Fix for scroll issue in graph edit mode when dropdown goes below screen
-
[
Issue #855
](
https://github.com/grafana/grafana/issues/855
)
. Graph: Fix for scroll issue in graph edit mode when dropdown goes below screen
...
...
src/app/services/dashboard/dashboardSrv.js
View file @
30512b70
...
@@ -31,8 +31,8 @@ function (angular, $, kbn, _, moment) {
...
@@ -31,8 +31,8 @@ function (angular, $, kbn, _, moment) {
this
.
rows
=
data
.
rows
||
[];
this
.
rows
=
data
.
rows
||
[];
this
.
nav
=
data
.
nav
||
[];
this
.
nav
=
data
.
nav
||
[];
this
.
time
=
data
.
time
||
{
from
:
'now-6h'
,
to
:
'now'
};
this
.
time
=
data
.
time
||
{
from
:
'now-6h'
,
to
:
'now'
};
this
.
templating
=
data
.
templating
||
{
list
:
[],
enable
:
false
}
;
this
.
templating
=
this
.
_ensureListExist
(
data
.
templating
)
;
this
.
annotations
=
data
.
annotations
||
{
list
:
[],
enable
:
false
}
;
this
.
annotations
=
this
.
_ensureListExist
(
data
.
annotations
)
;
this
.
refresh
=
data
.
refresh
;
this
.
refresh
=
data
.
refresh
;
this
.
version
=
data
.
version
||
0
;
this
.
version
=
data
.
version
||
0
;
...
@@ -40,11 +40,17 @@ function (angular, $, kbn, _, moment) {
...
@@ -40,11 +40,17 @@ function (angular, $, kbn, _, moment) {
this
.
nav
.
push
({
type
:
'timepicker'
});
this
.
nav
.
push
({
type
:
'timepicker'
});
}
}
this
.
updateSchema
(
data
);
this
.
_
updateSchema
(
data
);
}
}
var
p
=
DashboardModel
.
prototype
;
var
p
=
DashboardModel
.
prototype
;
p
.
_ensureListExist
=
function
(
data
)
{
if
(
!
data
)
{
data
=
{};
}
if
(
!
data
.
list
)
{
data
.
list
=
[];
}
return
data
;
};
p
.
getNextPanelId
=
function
()
{
p
.
getNextPanelId
=
function
()
{
var
i
,
j
,
row
,
panel
,
max
=
0
;
var
i
,
j
,
row
,
panel
,
max
=
0
;
for
(
i
=
0
;
i
<
this
.
rows
.
length
;
i
++
)
{
for
(
i
=
0
;
i
<
this
.
rows
.
length
;
i
++
)
{
...
@@ -116,7 +122,7 @@ function (angular, $, kbn, _, moment) {
...
@@ -116,7 +122,7 @@ function (angular, $, kbn, _, moment) {
$rootScope
.
$broadcast
(
'refresh'
);
$rootScope
.
$broadcast
(
'refresh'
);
};
};
p
.
updateSchema
=
function
(
old
)
{
p
.
_
updateSchema
=
function
(
old
)
{
var
i
,
j
,
k
;
var
i
,
j
,
k
;
var
oldVersion
=
this
.
version
;
var
oldVersion
=
this
.
version
;
var
panelUpgrades
=
[];
var
panelUpgrades
=
[];
...
...
src/test/specs/dashboardSrv-specs.js
View file @
30512b70
...
@@ -178,4 +178,26 @@ define([
...
@@ -178,4 +178,26 @@ define([
});
});
describe
(
'when creating dashboard model with missing list for annoations or templating'
,
function
()
{
var
model
;
beforeEach
(
module
(
'grafana.services'
));
beforeEach
(
inject
(
function
(
dashboardSrv
)
{
model
=
dashboardSrv
.
create
({
annotations
:
{
enable
:
true
,
},
templating
:
{
enable
:
true
}
});
}));
it
(
'should add empty list'
,
function
()
{
expect
(
model
.
annotations
.
list
.
length
).
to
.
be
(
0
);
expect
(
model
.
templating
.
list
.
length
).
to
.
be
(
1
);
});
});
});
});
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