summaryrefslogtreecommitdiff
path: root/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic
diff options
context:
space:
mode:
authorAntony Lesuisse <al@openerp.com>2011-09-05 13:03:09 +0200
committerAntony Lesuisse <al@openerp.com>2011-09-05 13:03:09 +0200
commitbedfc48dcfb066e61209337235e339975dd093d0 (patch)
treefd1bab7b9f21380f1aa3ca7675018f13b4d9e652 /addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic
parent272424894a91aa136952cf88ef206afab5b5505c (diff)
rename base into web part1
bzr revid: al@openerp.com-20110905110309-egx167t1ni1fzho1
Diffstat (limited to 'addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic')
-rw-r--r--addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/01_add.html83
-rw-r--r--addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/02_events.html96
-rw-r--r--addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/03_sorting.html73
-rw-r--r--addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/04_filtering.html81
4 files changed, 0 insertions, 333 deletions
diff --git a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/01_add.html b/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/01_add.html
deleted file mode 100644
index 7a3b45f8cee..00000000000
--- a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/01_add.html
+++ /dev/null
@@ -1,83 +0,0 @@
-<!--conf
-<sample>
- <product version="2.6" edition="std"/>
- <modifications>
- <modified date="100609"/>
- </modifications>
- </sample>
- -->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
-<head>
- <title>Adding</title>
- <script src="../../codebase/dhtmlxchart.js" type="text/javascript"></script>
- <link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxchart.css">
- <script>
- var data = [
- { sales:"3.0", year:"2000" },
- { sales:"3.8", year:"2001" },
- { sales:"3.4", year:"2002" },
- { sales:"4.1", year:"2003" },
- { sales:"4.3", year:"2004" },
- { sales:"9.9", year:"2005" },
- { sales:"7.4", year:"2006" },
- { sales:"9.0", year:"2007" },
- { sales:"7.3", year:"2008" },
- { sales:"4.8", year:"2009" }
- ];
-
- var barChart1;
-
- window.onload = function(){
- barChart1 = new dhtmlXChart({
- view:"bar",
- container:"chart1",
- value:"#sales#",
- label:"#sales#",
- color:"#b3e025",
- gradient:true,
- border:false,
- width:50,
- tooltip:{
- template:"#sales#"
- },
- xAxis:{
- title:"Sales per year",
- template:"#year#"
- },
- padding:{
- top:20,
- left:0,
- right:0
- }
- });
- barChart1.parse(data,"json");
- }
-
- var counter = 2010;
- function add_new () {
- barChart1.add({
- year:counter,
- sales:(Math.random()*5).toFixed(2)
- });
- counter++;
- }
- function delete_first(){
- barChart1.remove(barChart1.first());
- }
- </script>
-</head>
-<body>
- <table>
- <tr>
- <td><div id="chart1" style="width:750px;height:300px;border:1px solid #A4BED4;"></div></td>
- </tr>
- </table>
-
-
-
-
- <input type="button" value="add" onclick="add_new()">
- <input type="button" value="delete" onclick="delete_first()">
-</body>
-</html>
diff --git a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/02_events.html b/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/02_events.html
deleted file mode 100644
index 495d42bf795..00000000000
--- a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/02_events.html
+++ /dev/null
@@ -1,96 +0,0 @@
-<!--conf
-<sample>
- <product version="2.6" edition="std"/>
- <modifications>
- <modified date="100609"/>
- </modifications>
- </sample>
- -->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
-<head>
- <title>Events</title>
- <script src="../../codebase/dhtmlxchart.js" type="text/javascript"></script>
- <link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxchart.css">
- <script>
- var data = [
- { sales:"3.0", year:"2000" },
- { sales:"3.8", year:"2001" },
- { sales:"3.4", year:"2002" },
- { sales:"4.1", year:"2003" },
- { sales:"4.3", year:"2004" },
- { sales:"9.9", year:"2005" },
- { sales:"7.4", year:"2006" },
- { sales:"9.0", year:"2007" },
- { sales:"7.3", year:"2008" },
- { sales:"4.8", year:"2009" }
- ];
- var barChart1;
- window.onload = function(){
- barChart1 = new dhtmlXChart({
- view:"bar",
- container:"chart1",
- value:"#sales#",
- label:"#sales#",
- color:"#b3e025",
- gradient:true,
- border:false,
- width:50,
- tooltip:{
- template:"#sales#"
- },
- xAxis:{
- title:"Sales per year",
- template:"#year#"
- },
- padding:{
- top:20,
- left:0,
- right:0
- }
- });
- barChart1.parse(data,"json");
- barChart1.attachEvent("onMouseMove", function(id){
- id = barChart1.get(id).year;
- log("onMouseMove", id);
- return true;
- });
- barChart1.attachEvent("onMouseOut", function(id){
- log("onMouseOut", id);
- return true;
- });
-
- barChart1.attachEvent("onItemClick", function(id){
- id = barChart1.get(id).year;
- log("onItemClick", id);
- return true;
- });
- barChart1.attachEvent("onItemDblClick", function(id){
- id = barChart1.get(id).year;
- log("onItemDblClick", id);
- return true;
- });
-
- }
-
- function log(name, id){
- var t = document.createElement("DIV");
- t.innerHTML = name+" for element "+id;
-
- var p = document.getElementById("log_div");
- p.insertBefore(t, p.firstChild);
- }
-
- </script>
-</head>
-<body>
- <table>
- <tr>
- <td><div id="chart1" style="width:750px;height:300px;border:1px solid #A4BED4;"></div></td>
- </tr>
- </table>
- <div id="log_div" style="widht:950px; height:300px; font-family:Tahoma;overflow:auto"></div>
-
-
-</body>
-</html>
diff --git a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/03_sorting.html b/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/03_sorting.html
deleted file mode 100644
index cb8b254fe10..00000000000
--- a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/03_sorting.html
+++ /dev/null
@@ -1,73 +0,0 @@
-<!--conf
-<sample>
- <product version="2.6" edition="std"/>
- <modifications>
- <modified date="100609"/>
- </modifications>
- </sample>
- -->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
-<head>
- <title>Sorting</title>
- <script src="../../codebase/dhtmlxchart.js" type="text/javascript"></script>
- <link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxchart.css">
- <script>
- var data = [
- { sales:"3.0", year:"2000" },
- { sales:"3.8", year:"2001" },
- { sales:"3.4", year:"2002" },
- { sales:"4.1", year:"2003" },
- { sales:"4.3", year:"2004" },
- { sales:"9.9", year:"2005" },
- { sales:"7.4", year:"2006" },
- { sales:"9.0", year:"2007" },
- { sales:"7.3", year:"2008" },
- { sales:"4.8", year:"2009" }
- ];
-
- var barChart1;
-
- window.onload = function(){
- barChart1 = new dhtmlXChart({
- view:"bar",
- container:"chart1",
- value:"#sales#",
- label:"#sales#",
- color:"#b3e025",
- gradient:true,
- border:false,
- width:50,
- tooltip:{
- template:"#sales#"
- },
- xAxis:{
- title:"Sales per year",
- template:"#year#"
- },
- padding:{
- top:20,
- left:0,
- right:0
- }
- });
- barChart1.parse(data,"json");
- }
-
- </script>
-</head>
-<body >
- <table>
- <tr>
- <td><div id="chart1" style="width:750px;height:300px;border:1px solid #A4BED4;"></div></td>
- </tr>
- </table>
-
-
-
- <input type="button" value="sort by sales, ASC" onclick="barChart1.sort('#sales#','asc');">
- <input type="button" value="sort by sales, DESC" onclick="barChart1.sort('#sales#','desc');">
- <input type="button" value="sort by year, ASC" onclick="barChart1.sort('#year#','asc');">
- <input type="button" value="sort by year, DESC" onclick="barChart1.sort('#year#','desc');">
-</body>
-</html>
diff --git a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/04_filtering.html b/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/04_filtering.html
deleted file mode 100644
index 230aa820800..00000000000
--- a/addons/base_graph/static/lib/dhtmlxGraph/samples/08_dynamic/04_filtering.html
+++ /dev/null
@@ -1,81 +0,0 @@
-<!--conf
-<sample>
- <product version="2.6" edition="std"/>
- <modifications>
- <modified date="100609"/>
- </modifications>
- </sample>
- -->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
-<head>
- <title>Filtering</title>
- <script src="../../codebase/dhtmlxchart.js" type="text/javascript"></script>
- <link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxchart.css">
- <script>
- var data = [
- { sales:"3.0", year:"2000" },
- { sales:"3.8", year:"2001" },
- { sales:"3.4", year:"2002" },
- { sales:"4.1", year:"2003" },
- { sales:"4.3", year:"2004" },
- { sales:"9.9", year:"2005" },
- { sales:"7.4", year:"2006" },
- { sales:"9.0", year:"2007" },
- { sales:"7.3", year:"2008" },
- { sales:"4.8", year:"2009" }
- ];
-
- window.onload = function(){
- barChart = new dhtmlXChart({
- view:"bar",
- container:"chart1",
- value:"#sales#",
- label:"#sales#",
- color:"#b3e025",
- gradient:true,
- border:false,
- width:50,
- tooltip:{
- template:"#sales#"
- },
- xAxis:{
- title:"Sales per year",
- template:"#year#"
- },
- padding:{
- top:30,
- left:0,
- right:0
- }
- });
- barChart.parse(data,"json");
- }
-
- function filter_year(){
- barChart.filter(function(obj){
- return obj.year >2005;
- })
- }
- function filter_sales(){
- barChart.filter(function(obj){
- return obj.sales < 8;
- })
- }
-
- </script>
-</head>
-<body>
- <table>
- <tr>
- <td><div id="chart1" style="width:750px;height:300px;border:1px solid #A4BED4;"></div></td>
- </tr>
- </table>
-
-
-
- <input type="button" value="show all" onclick="barChart.filter();">
- <input type="button" value="show year > 2005" onclick="filter_year()">
- <input type="button" value="show sales < 8" onclick="filter_sales()">
-</body>
-</html>