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
1e425244
Commit
1e425244
authored
Nov 18, 2014
by
Jeff Klukas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor timspan default in scripted examples.
parent
0c6618d2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
src/app/dashboards/scripted.js
+2
-2
src/app/dashboards/scripted_async.js
+2
-2
src/app/dashboards/scripted_templated.js
+2
-2
No files found.
src/app/dashboards/scripted.js
View file @
1e425244
...
...
@@ -23,7 +23,7 @@ var dashboard, timspan;
var
ARGS
;
// Set a default timespan if one isn't specified
timspan
=
'
1d'
;
timspan
=
ARGS
.
from
||
'now-
1d'
;
// Intialize a skeleton with nothing but a rows array and service object
dashboard
=
{
...
...
@@ -33,7 +33,7 @@ dashboard = {
// Set a title
dashboard
.
title
=
'Scripted dash'
;
dashboard
.
time
=
{
from
:
"now-"
+
(
ARGS
.
from
||
timspan
)
,
from
:
timspan
,
to
:
"now"
};
...
...
src/app/dashboards/scripted_async.js
View file @
1e425244
...
...
@@ -25,7 +25,7 @@ return function(callback) {
var
dashboard
,
timspan
;
// Set a default timespan if one isn't specified
timspan
=
'
1d'
;
timspan
=
ARGS
.
from
||
'now-
1d'
;
// Intialize a skeleton with nothing but a rows array and service object
dashboard
=
{
...
...
@@ -36,7 +36,7 @@ return function(callback) {
// Set a title
dashboard
.
title
=
'Scripted dash'
;
dashboard
.
time
=
{
from
:
"now-"
+
(
ARGS
.
from
||
timspan
)
,
from
:
timspan
,
to
:
"now"
};
...
...
src/app/dashboards/scripted_templated.js
View file @
1e425244
...
...
@@ -23,7 +23,7 @@ var dashboard, timspan;
var
ARGS
;
// Set a default timespan if one isn't specified
timspan
=
'
1d'
;
timspan
=
ARGS
.
from
||
'now-
1d'
;
// Intialize a skeleton with nothing but a rows array and service object
dashboard
=
{
...
...
@@ -33,7 +33,7 @@ dashboard = {
// Set a title
dashboard
.
title
=
'Scripted dash'
;
dashboard
.
time
=
{
from
:
"now-"
+
(
ARGS
.
from
||
timspan
)
,
from
:
timspan
,
to
:
"now"
};
dashboard
.
templating
=
{
...
...
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