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
b31fccb8
Commit
b31fccb8
authored
Jun 25, 2016
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:grafana/grafana
parents
35f135f6
ab104bcf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletions
+8
-1
public/app/plugins/panel/singlestat/module.ts
+8
-1
No files found.
public/app/plugins/panel/singlestat/module.ts
View file @
b31fccb8
...
...
@@ -199,6 +199,13 @@ class SingleStatCtrl extends MetricsPanelCtrl {
data
.
valueFormated
=
formatFunc
(
data
.
value
,
decimalInfo
.
decimals
,
decimalInfo
.
scaledDecimals
);
data
.
valueRounded
=
kbn
.
roundValue
(
data
.
value
,
decimalInfo
.
decimals
);
}
// Add $seriesName variable for using in prefix or postfix
data
.
scopedVars
=
{
seriesName
:
{
value
:
this
.
series
[
0
].
label
}
};
}
// check value to text mappings if its enabled
...
...
@@ -296,7 +303,7 @@ class SingleStatCtrl extends MetricsPanelCtrl {
}
function
getSpan
(
className
,
fontSize
,
value
)
{
value
=
templateSrv
.
replace
(
value
);
value
=
templateSrv
.
replace
(
value
,
data
.
scopedVars
);
return
'<span class="'
+
className
+
'" style="font-size:'
+
fontSize
+
'">'
+
value
+
'</span>'
;
}
...
...
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