summaryrefslogtreecommitdiffstats
path: root/web/old/datasource.html
diff options
context:
space:
mode:
authorLennart Weller <lhw@ring0.de>2016-06-22 14:24:06 +0000
committerLennart Weller <lhw@ring0.de>2016-06-22 14:24:06 +0000
commit924c86341e59f6961c7699840fb30bc00757e23d (patch)
tree0c22aa313daca9c8119801bef922fe93102360fa /web/old/datasource.html
parentImported Upstream version 1.2.0 (diff)
downloadnetdata-924c86341e59f6961c7699840fb30bc00757e23d.tar.xz
netdata-924c86341e59f6961c7699840fb30bc00757e23d.zip
Imported Upstream version 1.2.0+dfsgupstream/1.2.0+dfsg
Diffstat (limited to 'web/old/datasource.html')
-rw-r--r--web/old/datasource.html56
1 files changed, 0 insertions, 56 deletions
diff --git a/web/old/datasource.html b/web/old/datasource.html
deleted file mode 100644
index f61db4fb9..000000000
--- a/web/old/datasource.html
+++ /dev/null
@@ -1,56 +0,0 @@
-<html>
- <style>
- * {font-family:Arial}
- div {float: left; margin: 0 0 0 0; }
- </style>
- <head>
- <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
- <title>NetData Datasource Example</title>
- <script type="text/javascript" src="http://www.google.com/jsapi"></script>
- <script type="text/javascript">
-
- google.load('visualization', '1', {packages: ['charteditor']});
- // google.load('visualization', '1.0'); // Note: No need to specify chart libraries.
-
- google.setOnLoadCallback(drawVisualization);
-
- var wrapper;
- function drawVisualization() {
- wrapper = new google.visualization.ChartWrapper({
- containerId: 'graph_div',
- chartType: 'AreaChart',
- dataSourceUrl: 'http:/datasource/system.cpu/60/1/max', // it needs a protocol to work, even in relative URLs
- refreshInterval: 1,
- options: {
- isStacked: true,
- areaOpacity: 0.85,
- lineWidth: 1,
- title: 'CPU utilization',
- width: window.innerWidth - 50,
- height: window.innerHeight - 50,
- hAxis: {title: "Time of Day", viewWindowMode: 'maximized', format:'HH:mm:ss'},
- vAxis: {title: "percent", viewWindowMode: 'pretty', minValue: 0, maxValue: 100},
- focusTarget: 'category',
- annotation: {'1': {style: 'line'}},
- },
- });
- wrapper.draw();
- }
-
- function openEditor() {
- var editor = new google.visualization.ChartEditor();
- google.visualization.events.addListener(editor, 'ok', function() {
- wrapper = editor.getChartWrapper();
- wrapper.draw(document.getElementById('graph_div'));
- });
- editor.openDialog(wrapper);
- }
-
- </script>
- </head>
- <body>
- <input type='button' onclick='openEditor()' value='Open Editor'>
- <br/>
- <div><div id="graph_div"/></div>
- </body>
-</html>