5e7a5def3a25ee00d17c9ee673b15b73c0bbcb3d.svn-base 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <meta name="description" content="ECharts">
  8. <meta name="author" content="kener.linfeng@gmail.com">
  9. <title>ECharts · Example</title>
  10. <link rel="shortcut icon" href="../asset/ico/favicon.png">
  11. <!--link href="../asset/css/font-awesome.min.css" rel="stylesheet"-->
  12. <link href="../asset/css/bootstrap.css" rel="stylesheet">
  13. <link href="../asset/css/carousel.css" rel="stylesheet">
  14. <link href="../asset/css/echartsHome.css" rel="stylesheet">
  15. <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
  16. <!--[if lt IE 9]>
  17. <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
  18. <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
  19. <![endif]-->
  20. <script src="./www/js/echarts.js"></script>
  21. <script src="../asset/js/codemirror.js"></script>
  22. <script src="../asset/js/javascript.js"></script>
  23. <link href="../asset/css/codemirror.css" rel="stylesheet">
  24. <link href="../asset/css/monokai.css" rel="stylesheet">
  25. </head>
  26. <body>
  27. <!-- Fixed navbar -->
  28. <div class="navbar navbar-default navbar-fixed-top" role="navigation" id="head"></div>
  29. <div class="container-fluid">
  30. <div class="row-fluid example">
  31. <div id="sidebar-code" class="col-md-4">
  32. <div class="well sidebar-nav">
  33. <div class="nav-header"><a href="javascript:;" onclick="autoResize()" class="glyphicon glyphicon-resize-full" id ="icon-resize" ></a>option</div>
  34. <textarea id="code" name="code">
  35. option = {
  36. title : {
  37. text: '漏斗图(对比)',
  38. subtext: '纯属虚构',
  39. x: 'left',
  40. y: 'bottom'
  41. },
  42. tooltip : {
  43. trigger: 'item',
  44. formatter: "{a} <br/>{b} : {c}%"
  45. },
  46. toolbox: {
  47. show : true,
  48. orient: 'vertical',
  49. y: 'center',
  50. feature : {
  51. mark : {show: true},
  52. dataView : {show: true, readOnly: false},
  53. magicType : {
  54. show: true,
  55. type: ['pie', 'funnel'],
  56. option: {
  57. pie: {
  58. radius : [0, 50]
  59. }
  60. }
  61. },
  62. restore : {show: true},
  63. saveAsImage : {show: true}
  64. }
  65. },
  66. legend: {
  67. orient: 'vertical',
  68. x: 'left',
  69. data : ['产品A','产品B','产品C','产品D','产品E']
  70. },
  71. calculable : true,
  72. series : [
  73. {
  74. name:'漏斗图',
  75. type:'funnel',
  76. width: '40%',
  77. height: '45%',
  78. x:'5%',
  79. y:'50%',
  80. funnelAlign: 'right',
  81. center: ['25%', '25%'], // for pie
  82. data:[
  83. {value:60, name:'产品C'},
  84. {value:30, name:'产品D'},
  85. {value:10, name:'产品E'},
  86. {value:80, name:'产品B'},
  87. {value:100, name:'产品A'}
  88. ]
  89. },
  90. {
  91. name:'金字塔',
  92. type:'funnel',
  93. width: '40%',
  94. height: '45%',
  95. x: '5%',
  96. y: '5%',
  97. sort : 'ascending',
  98. funnelAlign: 'right',
  99. center: ['25%', '75%'], // for pie
  100. data:[
  101. {value:60, name:'产品C'},
  102. {value:30, name:'产品D'},
  103. {value:10, name:'产品E'},
  104. {value:80, name:'产品B'},
  105. {value:100, name:'产品A'}
  106. ]
  107. },
  108. {
  109. name:'漏斗图',
  110. type:'funnel',
  111. width: '40%',
  112. height: '45%',
  113. x:'55%',
  114. y: '5%',
  115. funnelAlign: 'left',
  116. center: ['75%', '25%'], // for pie
  117. data:[
  118. {value:60, name:'产品C'},
  119. {value:30, name:'产品D'},
  120. {value:10, name:'产品E'},
  121. {value:80, name:'产品B'},
  122. {value:100, name:'产品A'}
  123. ]
  124. },
  125. {
  126. name:'金字塔',
  127. type:'funnel',
  128. width: '40%',
  129. height: '45%',
  130. x:'55%',
  131. y:'50%',
  132. sort : 'ascending',
  133. funnelAlign: 'left',
  134. center: ['75%', '75%'], // for pie
  135. data:[
  136. {value:60, name:'产品C'},
  137. {value:30, name:'产品D'},
  138. {value:10, name:'产品E'},
  139. {value:80, name:'产品B'},
  140. {value:100, name:'产品A'}
  141. ]
  142. }
  143. ]
  144. };
  145. </textarea>
  146. </div><!--/.well -->
  147. </div><!--/span-->
  148. <div id="graphic" class="col-md-8">
  149. <div id="main" class="main"></div>
  150. <div>
  151. <button type="button" class="btn btn-sm btn-success" onclick="refresh(true)">刷 新</button>
  152. <span class="text-primary">切换主题</span>
  153. <select id="theme-select"></select>
  154. <span id='wrong-message' style="color:red"></span>
  155. </div>
  156. </div><!--/span-->
  157. </div><!--/row-->
  158. </div><!--/.fluid-container-->
  159. <footer id="footer"></footer>
  160. <!-- Le javascript
  161. ================================================== -->
  162. <!-- Placed at the end of the document so the pages load faster -->
  163. <script src="../asset/js/jquery.min.js"></script>
  164. <script type="text/javascript" src="../asset/js/echartsHome.js"></script>
  165. <script src="../asset/js/bootstrap.min.js"></script>
  166. <script src="../asset/js/echartsExample.js"></script>
  167. </body>
  168. </html>