why-echarts-m.js 70 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828
  1. var myChart;
  2. var axisData = [
  3. "2013/1/24", "2013/1/25", "2013/1/28", "2013/1/29", "2013/1/30",
  4. "2013/1/31", "2013/2/1", "2013/2/4", "2013/2/5", "2013/2/6",
  5. "2013/2/7", "2013/2/8", "2013/2/18", "2013/2/19", "2013/2/20",
  6. "2013/2/21", "2013/2/22", "2013/2/25", "2013/2/26", "2013/2/27",
  7. "2013/2/28", "2013/3/1", "2013/3/4", "2013/3/5", "2013/3/6",
  8. "2013/3/7", "2013/3/8", "2013/3/11", "2013/3/12", "2013/3/13",
  9. "2013/3/14", "2013/3/15", "2013/3/18", "2013/3/19", "2013/3/20",
  10. "2013/3/21", "2013/3/22", "2013/3/25", "2013/3/26", "2013/3/27",
  11. "2013/3/28", "2013/3/29", "2013/4/1", "2013/4/2", "2013/4/3",
  12. "2013/4/8", "2013/4/9", "2013/4/10", "2013/4/11", "2013/4/12",
  13. "2013/4/15", "2013/4/16", "2013/4/17", "2013/4/18", "2013/4/19",
  14. "2013/4/22", "2013/4/23", "2013/4/24", "2013/4/25", "2013/4/26",
  15. "2013/5/2", "2013/5/3", "2013/5/6", "2013/5/7", "2013/5/8",
  16. "2013/5/9", "2013/5/10", "2013/5/13", "2013/5/14", "2013/5/15",
  17. "2013/5/16", "2013/5/17", "2013/5/20", "2013/5/21", "2013/5/22",
  18. "2013/5/23", "2013/5/24", "2013/5/27", "2013/5/28", "2013/5/29",
  19. "2013/5/30", "2013/5/31", "2013/6/3", "2013/6/4", "2013/6/5",
  20. "2013/6/6", "2013/6/7", "2013/6/13"
  21. ];
  22. var kData = [ // 开盘,收盘,最低,最高
  23. [2320.26,2302.6,2287.3,2362.94],
  24. [2300,2291.3,2288.26,2308.38],
  25. [2295.35,2346.5,2295.35,2346.92],
  26. [2347.22,2358.98,2337.35,2363.8],
  27. [2360.75,2382.48,2347.89,2383.76],
  28. [2383.43,2385.42,2371.23,2391.82],
  29. [2377.41,2419.02,2369.57,2421.15],
  30. [2425.92,2428.15,2417.58,2440.38],
  31. [2411,2433.13,2403.3,2437.42],
  32. [2432.68,2434.48,2427.7,2441.73],
  33. [2430.69,2418.53,2394.22,2433.89],
  34. [2416.62,2432.4,2414.4,2443.03],
  35. [2441.91,2421.56,2415.43,2444.8],
  36. [2420.26,2382.91,2373.53,2427.07],
  37. [2383.49,2397.18,2370.61,2397.94],
  38. [2378.82,2325.95,2309.17,2378.82],
  39. [2322.94,2314.16,2308.76,2330.88],
  40. [2320.62,2325.82,2315.01,2338.78],
  41. [2313.74,2293.34,2289.89,2340.71],
  42. [2297.77,2313.22,2292.03,2324.63],
  43. [2322.32,2365.59,2308.92,2366.16],
  44. [2364.54,2359.51,2330.86,2369.65],
  45. [2332.08,2273.4,2259.25,2333.54],
  46. [2274.81,2326.31,2270.1,2328.14],
  47. [2333.61,2347.18,2321.6,2351.44],
  48. [2340.44,2324.29,2304.27,2352.02],
  49. [2326.42,2318.61,2314.59,2333.67],
  50. [2314.68,2310.59,2296.58,2320.96],
  51. [2309.16,2286.6,2264.83,2333.29],
  52. [2282.17,2263.97,2253.25,2286.33],
  53. [2255.77,2270.28,2253.31,2276.22],
  54. [2269.31,2278.4,2250,2312.08],
  55. [2267.29,2240.02,2239.21,2276.05],
  56. [2244.26,2257.43,2232.02,2261.31],
  57. [2257.74,2317.37,2257.42,2317.86],
  58. [2318.21,2324.24,2311.6,2330.81],
  59. [2321.4,2328.28,2314.97,2332],
  60. [2334.74,2326.72,2319.91,2344.89],
  61. [2318.58,2297.67,2281.12,2319.99],
  62. [2299.38,2301.26,2289,2323.48],
  63. [2273.55,2236.3,2232.91,2273.55],
  64. [2238.49,2236.62,2228.81,2246.87],
  65. [2229.46,2234.4,2227.31,2243.95],
  66. [2234.9,2227.74,2220.44,2253.42],
  67. [2232.69,2225.29,2217.25,2241.34],
  68. [2196.24,2211.59,2180.67,2212.59],
  69. [2215.47,2225.77,2215.47,2234.73],
  70. [2224.93,2226.13,2212.56,2233.04],
  71. [2236.98,2219.55,2217.26,2242.48],
  72. [2218.09,2206.78,2204.44,2226.26],
  73. [2199.91,2181.94,2177.39,2204.99],
  74. [2169.63,2194.85,2165.78,2196.43],
  75. [2195.03,2193.8,2178.47,2197.51],
  76. [2181.82,2197.6,2175.44,2206.03],
  77. [2201.12,2244.64,2200.58,2250.11],
  78. [2236.4,2242.17,2232.26,2245.12],
  79. [2242.62,2184.54,2182.81,2242.62],
  80. [2187.35,2218.32,2184.11,2226.12],
  81. [2213.19,2199.31,2191.85,2224.63],
  82. [2203.89,2177.91,2173.86,2210.58],
  83. [2170.78,2174.12,2161.14,2179.65],
  84. [2179.05,2205.5,2179.05,2222.81],
  85. [2212.5,2231.17,2212.5,2236.07],
  86. [2227.86,2235.57,2219.44,2240.26],
  87. [2242.39,2246.3,2235.42,2255.21],
  88. [2246.96,2232.97,2221.38,2247.86],
  89. [2228.82,2246.83,2225.81,2247.67],
  90. [2247.68,2241.92,2231.36,2250.85],
  91. [2238.9,2217.01,2205.87,2239.93],
  92. [2217.09,2224.8,2213.58,2225.19],
  93. [2221.34,2251.81,2210.77,2252.87],
  94. [2249.81,2282.87,2248.41,2288.09],
  95. [2286.33,2299.99,2281.9,2309.39],
  96. [2297.11,2305.11,2290.12,2305.3],
  97. [2303.75,2302.4,2292.43,2314.18],
  98. [2293.81,2275.67,2274.1,2304.95],
  99. [2281.45,2288.53,2270.25,2292.59],
  100. [2286.66,2293.08,2283.94,2301.7],
  101. [2293.4,2321.32,2281.47,2322.1],
  102. [2323.54,2324.02,2321.17,2334.33],
  103. [2316.25,2317.75,2310.49,2325.72],
  104. [2320.74,2300.59,2299.37,2325.53],
  105. [2300.21,2299.25,2294.11,2313.43],
  106. [2297.1,2272.42,2264.76,2297.1],
  107. [2270.71,2270.93,2260.87,2276.86],
  108. [2264.43,2242.11,2240.07,2266.69],
  109. [2242.26,2210.9,2205.07,2250.63],
  110. [2190.1,2148.35,2126.22,2190.1]
  111. ];
  112. var placeList = [
  113. {name:'海门', geoCoord:[121.15, 31.89]},
  114. {name:'鄂尔多斯', geoCoord:[109.781327, 39.608266]},
  115. {name:'招远', geoCoord:[120.38, 37.35]},
  116. {name:'舟山', geoCoord:[122.207216, 29.985295]},
  117. {name:'齐齐哈尔', geoCoord:[123.97, 47.33]},
  118. {name:'盐城', geoCoord:[120.13, 33.38]},
  119. {name:'赤峰', geoCoord:[118.87, 42.28]},
  120. {name:'青岛', geoCoord:[120.33, 36.07]},
  121. {name:'乳山', geoCoord:[121.52, 36.89]},
  122. {name:'金昌', geoCoord:[102.188043, 38.520089]},
  123. {name:'泉州', geoCoord:[118.58, 24.93]},
  124. {name:'莱西', geoCoord:[120.53, 36.86]},
  125. {name:'日照', geoCoord:[119.46, 35.42]},
  126. {name:'胶南', geoCoord:[119.97, 35.88]},
  127. {name:'南通', geoCoord:[121.05, 32.08]},
  128. {name:'拉萨', geoCoord:[91.11, 29.97]},
  129. {name:'云浮', geoCoord:[112.02, 22.93]},
  130. {name:'梅州', geoCoord:[116.1, 24.55]},
  131. {name:'文登', geoCoord:[122.05, 37.2]},
  132. {name:'上海', geoCoord:[121.48, 31.22]},
  133. {name:'攀枝花', geoCoord:[101.718637, 26.582347]},
  134. {name:'威海', geoCoord:[122.1, 37.5]},
  135. {name:'承德', geoCoord:[117.93, 40.97]},
  136. {name:'厦门', geoCoord:[118.1, 24.46]},
  137. {name:'汕尾', geoCoord:[115.375279, 22.786211]},
  138. {name:'潮州', geoCoord:[116.63, 23.68]},
  139. {name:'丹东', geoCoord:[124.37, 40.13]},
  140. {name:'太仓', geoCoord:[121.1, 31.45]},
  141. {name:'曲靖', geoCoord:[103.79, 25.51]},
  142. {name:'烟台', geoCoord:[121.39, 37.52]},
  143. {name:'福州', geoCoord:[119.3, 26.08]},
  144. {name:'瓦房店', geoCoord:[121.979603, 39.627114]},
  145. {name:'即墨', geoCoord:[120.45, 36.38]},
  146. {name:'抚顺', geoCoord:[123.97, 41.97]},
  147. {name:'玉溪', geoCoord:[102.52, 24.35]},
  148. {name:'张家口', geoCoord:[114.87, 40.82]},
  149. {name:'阳泉', geoCoord:[113.57, 37.85]},
  150. {name:'莱州', geoCoord:[119.942327, 37.177017]},
  151. {name:'湖州', geoCoord:[120.1, 30.86]},
  152. {name:'汕头', geoCoord:[116.69, 23.39]},
  153. {name:'昆山', geoCoord:[120.95, 31.39]},
  154. {name:'宁波', geoCoord:[121.56, 29.86]},
  155. {name:'湛江', geoCoord:[110.359377, 21.270708]},
  156. {name:'揭阳', geoCoord:[116.35, 23.55]},
  157. {name:'荣成', geoCoord:[122.41, 37.16]},
  158. {name:'连云港', geoCoord:[119.16, 34.59]},
  159. {name:'葫芦岛', geoCoord:[120.836932, 40.711052]},
  160. {name:'常熟', geoCoord:[120.74, 31.64]},
  161. {name:'东莞', geoCoord:[113.75, 23.04]},
  162. {name:'河源', geoCoord:[114.68, 23.73]},
  163. {name:'淮安', geoCoord:[119.15, 33.5]},
  164. {name:'泰州', geoCoord:[119.9, 32.49]},
  165. {name:'南宁', geoCoord:[108.33, 22.84]},
  166. {name:'营口', geoCoord:[122.18, 40.65]},
  167. {name:'惠州', geoCoord:[114.4, 23.09]},
  168. {name:'江阴', geoCoord:[120.26, 31.91]},
  169. {name:'蓬莱', geoCoord:[120.75, 37.8]},
  170. {name:'韶关', geoCoord:[113.62, 24.84]},
  171. {name:'嘉峪关', geoCoord:[98.289152, 39.77313]},
  172. {name:'广州', geoCoord:[113.23, 23.16]},
  173. {name:'延安', geoCoord:[109.47, 36.6]},
  174. {name:'太原', geoCoord:[112.53, 37.87]},
  175. {name:'清远', geoCoord:[113.01, 23.7]},
  176. {name:'中山', geoCoord:[113.38, 22.52]},
  177. {name:'昆明', geoCoord:[102.73, 25.04]},
  178. {name:'寿光', geoCoord:[118.73, 36.86]},
  179. {name:'盘锦', geoCoord:[122.070714, 41.119997]},
  180. {name:'长治', geoCoord:[113.08, 36.18]},
  181. {name:'深圳', geoCoord:[114.07, 22.62]},
  182. {name:'珠海', geoCoord:[113.52, 22.3]},
  183. {name:'宿迁', geoCoord:[118.3, 33.96]},
  184. {name:'咸阳', geoCoord:[108.72, 34.36]},
  185. {name:'铜川', geoCoord:[109.11, 35.09]},
  186. {name:'平度', geoCoord:[119.97, 36.77]},
  187. {name:'佛山', geoCoord:[113.11, 23.05]},
  188. {name:'海口', geoCoord:[110.35, 20.02]},
  189. {name:'江门', geoCoord:[113.06, 22.61]},
  190. {name:'章丘', geoCoord:[117.53, 36.72]},
  191. {name:'肇庆', geoCoord:[112.44, 23.05]},
  192. {name:'大连', geoCoord:[121.62, 38.92]},
  193. {name:'临汾', geoCoord:[111.5, 36.08]},
  194. {name:'吴江', geoCoord:[120.63, 31.16]},
  195. {name:'石嘴山', geoCoord:[106.39, 39.04]},
  196. {name:'沈阳', geoCoord:[123.38, 41.8]},
  197. {name:'苏州', geoCoord:[120.62, 31.32]},
  198. {name:'茂名', geoCoord:[110.88, 21.68]},
  199. {name:'嘉兴', geoCoord:[120.76, 30.77]},
  200. {name:'长春', geoCoord:[125.35, 43.88]},
  201. {name:'胶州', geoCoord:[120.03336, 36.264622]},
  202. {name:'银川', geoCoord:[106.27, 38.47]},
  203. {name:'张家港', geoCoord:[120.555821, 31.875428]},
  204. {name:'三门峡', geoCoord:[111.19, 34.76]},
  205. {name:'锦州', geoCoord:[121.15, 41.13]},
  206. {name:'南昌', geoCoord:[115.89, 28.68]},
  207. {name:'柳州', geoCoord:[109.4, 24.33]},
  208. {name:'三亚', geoCoord:[109.511909, 18.252847]},
  209. {name:'自贡', geoCoord:[104.778442, 29.33903]},
  210. {name:'吉林', geoCoord:[126.57, 43.87]},
  211. {name:'阳江', geoCoord:[111.95, 21.85]},
  212. {name:'泸州', geoCoord:[105.39, 28.91]},
  213. {name:'西宁', geoCoord:[101.74, 36.56]},
  214. {name:'宜宾', geoCoord:[104.56, 29.77]},
  215. {name:'呼和浩特', geoCoord:[111.65, 40.82]},
  216. {name:'成都', geoCoord:[104.06, 30.67]},
  217. {name:'大同', geoCoord:[113.3, 40.12]},
  218. {name:'镇江', geoCoord:[119.44, 32.2]},
  219. {name:'桂林', geoCoord:[110.28, 25.29]},
  220. {name:'张家界', geoCoord:[110.479191, 29.117096]},
  221. {name:'宜兴', geoCoord:[119.82, 31.36]},
  222. {name:'北海', geoCoord:[109.12, 21.49]},
  223. {name:'西安', geoCoord:[108.95, 34.27]},
  224. {name:'金坛', geoCoord:[119.56, 31.74]},
  225. {name:'东营', geoCoord:[118.49, 37.46]},
  226. {name:'牡丹江', geoCoord:[129.58, 44.6]},
  227. {name:'遵义', geoCoord:[106.9, 27.7]},
  228. {name:'绍兴', geoCoord:[120.58, 30.01]},
  229. {name:'扬州', geoCoord:[119.42, 32.39]},
  230. {name:'常州', geoCoord:[119.95, 31.79]},
  231. {name:'潍坊', geoCoord:[119.1, 36.62]},
  232. {name:'重庆', geoCoord:[106.54, 29.59]},
  233. {name:'台州', geoCoord:[121.420757, 28.656386]},
  234. {name:'南京', geoCoord:[118.78, 32.04]},
  235. {name:'滨州', geoCoord:[118.03, 37.36]},
  236. {name:'贵阳', geoCoord:[106.71, 26.57]},
  237. {name:'无锡', geoCoord:[120.29, 31.59]},
  238. {name:'本溪', geoCoord:[123.73, 41.3]},
  239. {name:'克拉玛依', geoCoord:[84.77, 45.59]},
  240. {name:'渭南', geoCoord:[109.5, 34.52]},
  241. {name:'马鞍山', geoCoord:[118.48, 31.56]},
  242. {name:'宝鸡', geoCoord:[107.15, 34.38]},
  243. {name:'焦作', geoCoord:[113.21, 35.24]},
  244. {name:'句容', geoCoord:[119.16, 31.95]},
  245. {name:'北京', geoCoord:[116.46, 39.92]},
  246. {name:'徐州', geoCoord:[117.2, 34.26]},
  247. {name:'衡水', geoCoord:[115.72, 37.72]},
  248. {name:'包头', geoCoord:[110, 40.58]},
  249. {name:'绵阳', geoCoord:[104.73, 31.48]},
  250. {name:'乌鲁木齐', geoCoord:[87.68, 43.77]},
  251. {name:'枣庄', geoCoord:[117.57, 34.86]},
  252. {name:'杭州', geoCoord:[120.19, 30.26]},
  253. {name:'淄博', geoCoord:[118.05, 36.78]},
  254. {name:'鞍山', geoCoord:[122.85, 41.12]},
  255. {name:'溧阳', geoCoord:[119.48, 31.43]},
  256. {name:'库尔勒', geoCoord:[86.06, 41.68]},
  257. {name:'安阳', geoCoord:[114.35, 36.1]},
  258. {name:'开封', geoCoord:[114.35, 34.79]},
  259. {name:'济南', geoCoord:[117, 36.65]},
  260. {name:'德阳', geoCoord:[104.37, 31.13]},
  261. {name:'温州', geoCoord:[120.65, 28.01]},
  262. {name:'九江', geoCoord:[115.97, 29.71]},
  263. {name:'邯郸', geoCoord:[114.47, 36.6]},
  264. {name:'临安', geoCoord:[119.72, 30.23]},
  265. {name:'兰州', geoCoord:[103.73, 36.03]},
  266. {name:'沧州', geoCoord:[116.83, 38.33]},
  267. {name:'临沂', geoCoord:[118.35, 35.05]},
  268. {name:'南充', geoCoord:[106.110698, 30.837793]},
  269. {name:'天津', geoCoord:[117.2, 39.13]},
  270. {name:'富阳', geoCoord:[119.95, 30.07]},
  271. {name:'泰安', geoCoord:[117.13, 36.18]},
  272. {name:'诸暨', geoCoord:[120.23, 29.71]},
  273. {name:'郑州', geoCoord:[113.65, 34.76]},
  274. {name:'哈尔滨', geoCoord:[126.63, 45.75]},
  275. {name:'聊城', geoCoord:[115.97, 36.45]},
  276. {name:'芜湖', geoCoord:[118.38, 31.33]},
  277. {name:'唐山', geoCoord:[118.02, 39.63]},
  278. {name:'平顶山', geoCoord:[113.29, 33.75]},
  279. {name:'邢台', geoCoord:[114.48, 37.05]},
  280. {name:'德州', geoCoord:[116.29, 37.45]},
  281. {name:'济宁', geoCoord:[116.59, 35.38]},
  282. {name:'荆州', geoCoord:[112.239741, 30.335165]},
  283. {name:'宜昌', geoCoord:[111.3, 30.7]},
  284. {name:'义乌', geoCoord:[120.06, 29.32]},
  285. {name:'丽水', geoCoord:[119.92, 28.45]},
  286. {name:'洛阳', geoCoord:[112.44, 34.7]},
  287. {name:'秦皇岛', geoCoord:[119.57, 39.95]},
  288. {name:'株洲', geoCoord:[113.16, 27.83]},
  289. {name:'石家庄', geoCoord:[114.48, 38.03]},
  290. {name:'莱芜', geoCoord:[117.67, 36.19]},
  291. {name:'常德', geoCoord:[111.69, 29.05]},
  292. {name:'保定', geoCoord:[115.48, 38.85]},
  293. {name:'湘潭', geoCoord:[112.91, 27.87]},
  294. {name:'金华', geoCoord:[119.64, 29.12]},
  295. {name:'岳阳', geoCoord:[113.09, 29.37]},
  296. {name:'长沙', geoCoord:[113, 28.21]},
  297. {name:'衢州', geoCoord:[118.88, 28.97]},
  298. {name:'廊坊', geoCoord:[116.7, 39.53]},
  299. {name:'菏泽', geoCoord:[115.480656, 35.23375]},
  300. {name:'合肥', geoCoord:[117.27, 31.86]},
  301. {name:'武汉', geoCoord:[114.31, 30.52]},
  302. {name:'大庆', geoCoord:[125.03, 46.58]}
  303. ];
  304. var optionMap = {
  305. calculable : {
  306. title: {
  307. text: '【拖拽重计算】',
  308. subtext: '试试把你关心的数据图形拖拽到一起'
  309. },
  310. tooltip : {
  311. trigger: 'item',
  312. formatter: "{a} <br/>{b} : {c} ({d}%)"
  313. },
  314. legend: {
  315. y: 60,
  316. data:['Chrome','Firefox','Safari','IE9+','IE8','IE7','IE6-']
  317. },
  318. toolbox: {
  319. show : true,
  320. feature : {
  321. dataView : {show: true, readOnly: false},
  322. restore : {show: true},
  323. saveAsImage : {show: true}
  324. }
  325. },
  326. calculable : true,
  327. series : [
  328. {
  329. name:'浏览器占比',
  330. type:'pie',
  331. center: ['50%', '65%'], // 默认全局居中
  332. data:[
  333. {value:535, name:'Chrome'},
  334. {value:310, name:'Firefox'},
  335. {value:234, name:'Safari'},
  336. {value:235, name:'IE9+'},
  337. {value:1035, name:'IE8'},
  338. {value:1305, name:'IE7'},
  339. {value:948, name:'IE6-'}
  340. ]
  341. }
  342. ]
  343. },
  344. magicType : {
  345. title: {
  346. text: '【动态类型切换】',
  347. subtext: '切换图表类型会让您对这份数据有更多的解读'
  348. },
  349. tooltip : {
  350. trigger: 'axis'
  351. },
  352. legend: {
  353. y: 60,
  354. data:['意向','预购','成交']
  355. },
  356. toolbox: {
  357. show : true,
  358. feature : {
  359. mark : {show: true},
  360. dataView : {show: true, readOnly: false},
  361. magicType: {show: true, type : ['line', 'bar', 'stack', 'tiled']},
  362. restore : {show: true},
  363. saveAsImage : {show: true}
  364. }
  365. },
  366. calculable : true,
  367. grid: {
  368. y:100
  369. },
  370. xAxis : [
  371. {
  372. type : 'category',
  373. boundaryGap : true,
  374. data : ['周一','周二','周三','周四','周五','周六','周日']
  375. }
  376. ],
  377. yAxis : [
  378. {
  379. type : 'value'
  380. }
  381. ],
  382. series : [
  383. {
  384. name:'意向',
  385. type:'bar',
  386. smooth:true,
  387. itemStyle: {normal: {areaStyle: {type: 'default'}}},
  388. data:[1320, 1132, 601, 234, 120, 90, 20]
  389. },
  390. {
  391. name:'预购',
  392. type:'bar',
  393. smooth:true,
  394. itemStyle: {normal: {areaStyle: {type: 'default'}}},
  395. data:[30, 182, 434, 791, 390, 30, 10]
  396. },
  397. {
  398. name:'成交',
  399. type:'bar',
  400. smooth:true,
  401. itemStyle: {normal: {areaStyle: {type: 'default'}}},
  402. data:[10, 12, 21, 54, 260, 830, 710]
  403. }
  404. ]
  405. },
  406. dataRange : {
  407. title : {
  408. text: '【值域漫游】',
  409. subtext: '聚焦到你所关心的数值上'
  410. },
  411. tooltip : {
  412. trigger: 'item'
  413. },
  414. dataRange: {
  415. min: 0,
  416. max: 55000,
  417. x: 'left',
  418. text:['高','低'], // 文本,默认为数值文本
  419. color:[ 'red', 'yellow'],//颜色
  420. calculable : true,
  421. realtime: false
  422. },
  423. toolbox: {
  424. show : true,
  425. feature : {
  426. mark : {show: true},
  427. dataView : {show: true, readOnly: false},
  428. restore : {show: true},
  429. saveAsImage : {show: true}
  430. }
  431. },
  432. series : [
  433. {
  434. name: '2011全国GDP',
  435. type: 'map',
  436. mapType: 'china',
  437. itemStyle:{
  438. normal:{label:{show:true}},
  439. emphasis:{color:'rgba(104,255,104,0.5)'}
  440. },
  441. data:[
  442. {name:'西藏', value:605.83},
  443. {name:'青海', value:1670.44},
  444. {name:'宁夏', value:2102.21},
  445. {name:'海南', value:2522.66},
  446. {name:'甘肃', value:5020.37},
  447. {name:'贵州', value:5701.84},
  448. {name:'新疆', value:6610.05},
  449. {name:'云南', value:8893.12},
  450. {name:'重庆', value:10011.37},
  451. {name:'吉林', value:10568.83},
  452. {name:'山西', value:11237.55},
  453. {name:'天津', value:11307.28},
  454. {name:'江西', value:11702.82},
  455. {name:'广西', value:11720.87},
  456. {name:'陕西', value:12512.3},
  457. {name:'黑龙江', value:12582},
  458. {name:'内蒙古', value:14359.88},
  459. {name:'安徽', value:15300.65},
  460. {name:'北京', value:16251.93},
  461. {name:'福建', value:17560.18},
  462. {name:'上海', value:19195.69},
  463. {name:'湖北', value:19632.26},
  464. {name:'湖南', value:19669.56},
  465. {name:'四川', value:21026.68},
  466. {name:'辽宁', value:22226.7},
  467. {name:'河北', value:24515.76},
  468. {name:'河南', value:26931.03},
  469. {name:'浙江', value:32318.85},
  470. {name:'山东', value:45361.85},
  471. {name:'江苏', value:49110.27},
  472. {name:'广东', value:53210.28}
  473. ]
  474. }
  475. ]
  476. },
  477. dataZoom : {
  478. title : {
  479. text: '【数据区域缩放】',
  480. subtext: '聚焦到你所关心的数据上'
  481. },
  482. tooltip : {
  483. trigger: 'axis',
  484. formatter: function (params) {
  485. var res = params[0].seriesName + ' ' + params[0].name;
  486. res += '<br/> 开盘 : ' + params[0].value[0] + ' 最高 : ' + params[0].value[3];
  487. res += '<br/> 收盘 : ' + params[0].value[1] + ' 最低 : ' + params[0].value[2];
  488. return res;
  489. }
  490. },
  491. toolbox: {
  492. y: 'top',
  493. orient:'vertical',
  494. show : true,
  495. feature : {
  496. restore : {show: true},
  497. dataZoom : {show: true}
  498. }
  499. },
  500. dataZoom : {
  501. show : true,
  502. realtime: true,
  503. start : 0,
  504. end : 50
  505. },
  506. xAxis : [
  507. {
  508. type : 'category',
  509. boundaryGap : true,
  510. axisTick: {onGap:false},
  511. data : axisData
  512. }
  513. ],
  514. yAxis : [
  515. {
  516. type : 'value',
  517. scale:true,
  518. splitNumber: 9,
  519. boundaryGap: [0.05, 0.05],
  520. splitArea : {show : true}
  521. }
  522. ],
  523. series : [
  524. {
  525. name:'上证指数',
  526. type:'k',
  527. data: kData
  528. }
  529. ]
  530. },
  531. timeline : {
  532. timeline : {
  533. autoPlay:true,
  534. data : [1,2,3,4,5 ],
  535. type: 'number'
  536. },
  537. options : [
  538. {
  539. title : {
  540. x:'right',
  541. text: '【百搭时间轴】',
  542. subtext: '时间维度的拓展 '
  543. },
  544. tooltip : {
  545. trigger: 'item',
  546. formatter: "{a} <br/>{b} : {c} ({d}%)"
  547. },
  548. legend: {
  549. orient: 'vertical',
  550. x: 'left',
  551. data:['Chrome','Firefox','Safari','IE9+','IE8-']
  552. },
  553. toolbox: {
  554. show : true,
  555. orient: 'vertical',
  556. x: 'right',
  557. y: 'center',
  558. feature : {
  559. mark : {show: true},
  560. dataView : {show: true, readOnly: false},
  561. magicType : {
  562. show: true,
  563. type: ['pie', 'funnel'],
  564. option: {
  565. funnel: {
  566. x: '25%',
  567. width: '50%',
  568. funnelAlign: 'left',
  569. max: 1700
  570. }
  571. }
  572. },
  573. restore : {show: true},
  574. saveAsImage : {show: true}
  575. }
  576. },
  577. series : [
  578. {
  579. name:'浏览器(数据纯属虚构)',
  580. type:'pie',
  581. center: ['45%', '50%'],
  582. radius: '50%',
  583. data:[
  584. {value: 1 * 128 + 80, name:'Chrome'},
  585. {value: 1 * 64 + 160, name:'Firefox'},
  586. {value: 1 * 32 + 320, name:'Safari'},
  587. {value: 1 * 16 + 640, name:'IE9+'},
  588. {value: 1 * 8 + 1280, name:'IE8-'}
  589. ]
  590. }
  591. ]
  592. },
  593. {
  594. series : [
  595. {
  596. name:'浏览器(数据纯属虚构)',
  597. type:'pie',
  598. data:[
  599. {value: 3 * 128 + 80, name:'Chrome'},
  600. {value: 3 * 64 + 160, name:'Firefox'},
  601. {value: 3 * 32 + 320, name:'Safari'},
  602. {value: 3 * 16 + 640, name:'IE9+'},
  603. {value: 3 * 8 + 1280, name:'IE8-'}
  604. ]
  605. }
  606. ]
  607. },
  608. {
  609. series : [
  610. {
  611. name:'浏览器(数据纯属虚构)',
  612. type:'pie',
  613. data:[
  614. {value: 5 * 128 + 80, name:'Chrome'},
  615. {value: 5 * 64 + 160, name:'Firefox'},
  616. {value: 5 * 32 + 320, name:'Safari'},
  617. {value: 5 * 16 + 640, name:'IE9+'},
  618. {value: 5 * 8 + 1280, name:'IE8-'}
  619. ]
  620. }
  621. ]
  622. },
  623. {
  624. series : [
  625. {
  626. name:'浏览器(数据纯属虚构)',
  627. type:'pie',
  628. data:[
  629. {value: 7 * 128 + 80, name:'Chrome'},
  630. {value: 7 * 64 + 160, name:'Firefox'},
  631. {value: 7 * 32 + 320, name:'Safari'},
  632. {value: 7 * 16 + 640, name:'IE9+'},
  633. {value: 7 * 8 + 1280, name:'IE8-'}
  634. ]
  635. }
  636. ]
  637. },
  638. {
  639. series : [
  640. {
  641. name:'浏览器(数据纯属虚构)',
  642. type:'pie',
  643. data:[
  644. {value: 14 * 128 + 80, name:'Chrome'},
  645. {value: 13 * 64 + 160, name:'Firefox'},
  646. {value: 12 * 32 + 320, name:'Safari'},
  647. {value: 12 * 16 + 640, name:'IE9+'},
  648. {value: 12 * 8 + 1280, name:'IE8-'}
  649. ]
  650. }
  651. ]
  652. }
  653. ]
  654. },
  655. scatter : {
  656. title : {
  657. text: '【大规模散点】',
  658. subtext: '现代浏览器就足以展现百万级数据'
  659. },
  660. tooltip : {
  661. trigger: 'item'
  662. },
  663. legend: {
  664. x:'left',
  665. y:'bottom',
  666. data:['sin','cos']
  667. },
  668. toolbox: {
  669. show : true,
  670. feature : {
  671. mark : {show: true},
  672. dataZoom : {show: true},
  673. dataView : {show: true, readOnly: false},
  674. restore : {show: true},
  675. saveAsImage : {show: true}
  676. }
  677. },
  678. xAxis : [
  679. {
  680. type : 'value',
  681. scale:true,
  682. show: false
  683. }
  684. ],
  685. yAxis : [
  686. {
  687. type : 'value',
  688. scale:true,
  689. splitArea : {show : true}
  690. }
  691. ],
  692. series : [
  693. {
  694. name:'sin',
  695. type:'scatter',
  696. large: true,
  697. symbol:'circle',
  698. data: (function () {
  699. var d = [];
  700. var len = 5000;
  701. var x = 0;
  702. while (len--) {
  703. x = (Math.random() * 8).toFixed(3) - 0;
  704. d.push([
  705. x,
  706. //Math.random() * 10
  707. (Math.sin(x) - x * (len % 2 ? 0.1 : -0.1) * Math.random()).toFixed(3) - 0
  708. ]);
  709. }
  710. return d;
  711. })()
  712. },
  713. {
  714. name:'cos',
  715. type:'scatter',
  716. large: true,
  717. symbol:'circle',
  718. data: (function () {
  719. var d = [];
  720. var len = 5000;
  721. var x = 0;
  722. while (len--) {
  723. x = (Math.random() * 8).toFixed(3) - 0;
  724. d.push([
  725. x,
  726. //Math.random() * 10
  727. (Math.cos(x) - x * (len % 2 ? 0.1 : -0.1) * Math.random()).toFixed(3) - 0
  728. ]);
  729. }
  730. return d;
  731. })()
  732. }
  733. ]
  734. },
  735. force : {
  736. title : {
  737. text: '【力导向布局】',
  738. subtext: '复杂关系网络的最美呈现'
  739. },
  740. tooltip : {
  741. trigger: 'item',
  742. formatter: '{a} : {b}'
  743. },
  744. toolbox: {
  745. show : true,
  746. feature : {
  747. magicType: {show: true, type: ['force', 'chord']},
  748. restore : {show: true}
  749. }
  750. },
  751. legend: {
  752. x:'left',
  753. y:'bottom',
  754. data:['家人','朋友']
  755. },
  756. series : [
  757. {
  758. type:'force',
  759. ribbonType: false,
  760. categories : [
  761. {
  762. name: '人物',
  763. itemStyle: {
  764. normal: {
  765. color : '#ff7f50'
  766. }
  767. }
  768. },
  769. {
  770. name: '家人',
  771. itemStyle: {
  772. normal: {
  773. color : '#87cdfa'
  774. }
  775. }
  776. },
  777. {
  778. name:'朋友',
  779. itemStyle: {
  780. normal: {
  781. color : '#9acd32'
  782. }
  783. }
  784. }
  785. ],
  786. itemStyle: {
  787. normal: {
  788. label: {
  789. show: true,
  790. textStyle: {
  791. color: '#800080'
  792. }
  793. },
  794. nodeStyle : {
  795. brushType : 'both',
  796. strokeColor : 'rgba(255,215,0,0.4)',
  797. lineWidth : 8
  798. }
  799. },
  800. emphasis: {
  801. label: {
  802. show: false
  803. // textStyle: null // 默认使用全局文本样式,详见TEXTSTYLE
  804. },
  805. nodeStyle : {
  806. r: 30
  807. },
  808. linkStyle : {}
  809. }
  810. },
  811. minRadius : 15,
  812. maxRadius : 25,
  813. density : 0.05,
  814. attractiveness: 1.2,
  815. radius: '40%',
  816. minRadius: 5,
  817. maxRadius: 10,
  818. nodes:[
  819. {category:0, name: '乔布斯', value : 10},
  820. {category:1, name: '丽萨-乔布斯',value : 2},
  821. {category:1, name: '保罗-乔布斯',value : 3},
  822. {category:1, name: '克拉拉-乔布斯',value : 3},
  823. {category:1, name: '劳伦-鲍威尔',value : 7},
  824. {category:2, name: '史蒂夫-沃兹尼艾克',value : 5},
  825. {category:2, name: '奥巴马',value : 8},
  826. {category:2, name: '比尔-盖茨',value : 9},
  827. {category:2, name: '乔纳森-艾夫',value : 4},
  828. {category:2, name: '蒂姆-库克',value : 4},
  829. {category:2, name: '龙-韦恩',value : 1},
  830. ],
  831. links : [
  832. {source : 1, target : 0, weight : 1},
  833. {source : 2, target : 0, weight : 2},
  834. {source : 3, target : 0, weight : 1},
  835. {source : 4, target : 0, weight : 2},
  836. {source : 5, target : 0, weight : 3},
  837. {source : 6, target : 0, weight : 6},
  838. {source : 7, target : 0, weight : 6},
  839. {source : 8, target : 0, weight : 1},
  840. {source : 9, target : 0, weight : 1},
  841. {source : 10, target : 0, weight : 1},
  842. {source : 3, target : 2, weight : 1},
  843. {source : 6, target : 2, weight : 1},
  844. {source : 6, target : 3, weight : 1},
  845. {source : 6, target : 4, weight : 1},
  846. {source : 6, target : 5, weight : 1},
  847. {source : 7, target : 6, weight : 6},
  848. {source : 7, target : 3, weight : 1},
  849. {source : 9, target : 6, weight : 1}
  850. ]
  851. }
  852. ]
  853. },
  854. gauge :{
  855. title : {
  856. text: '【商业BI】',
  857. subtext: '显示关键性能指标以辅助于绩效管理'
  858. },
  859. color : [
  860. 'rgba(255, 69, 0, 0.5)',
  861. 'rgba(255, 150, 0, 0.5)',
  862. 'rgba(255, 200, 0, 0.5)',
  863. 'rgba(155, 200, 50, 0.5)',
  864. 'rgba(55, 200, 100, 0.5)'
  865. ],
  866. tooltip : {
  867. trigger: 'item',
  868. formatter: "{a} <br/>{b} : {c}%"
  869. },
  870. series : [
  871. {
  872. name:'业务指标',
  873. type:'gauge',
  874. center : ['50%', '60%'], // 默认全局居中
  875. radius : '80%',
  876. startAngle: 225,
  877. endAngle : -45,
  878. splitNumber: 10, // 分割段数,默认为5
  879. axisLine: { // 坐标轴线
  880. lineStyle: { // 属性lineStyle控制线条样式
  881. color: [[0.2, '#228b22'],[0.8, '#48b'],[1, 'rgb(255, 80, 20)']],
  882. width: 8
  883. }
  884. },
  885. axisTick: { // 坐标轴小标记
  886. splitNumber: 10, // 每份split细分多少段
  887. length :12, // 属性length控制线长
  888. lineStyle: { // 属性lineStyle控制线条样式
  889. color: 'auto'
  890. }
  891. },
  892. axisLabel: { // 坐标轴文本标签,详见axis.axisLabel
  893. textStyle: { // 其余属性默认使用全局文本样式,详见TEXTSTYLE
  894. color: 'auto'
  895. }
  896. },
  897. splitLine: { // 分隔线
  898. show: true, // 默认显示,属性show控制显示与否
  899. length :30, // 属性length控制线长
  900. lineStyle: { // 属性lineStyle(详见lineStyle)控制线条样式
  901. color: 'auto'
  902. }
  903. },
  904. pointer : {
  905. width : 5,
  906. color: 'auto'
  907. },
  908. title : {
  909. show : true,
  910. offsetCenter: [0, '-30%'], // x, y,单位px
  911. textStyle: { // 其余属性默认使用全局文本样式,详见TEXTSTYLE
  912. fontWeight: 'bolder'
  913. }
  914. },
  915. detail : {
  916. formatter:'{value}%',
  917. offsetCenter: [0, '40%'],
  918. textStyle: { // 其余属性默认使用全局文本样式,详见TEXTSTYLE
  919. color: 'auto',
  920. fontWeight: 'bolder'
  921. }
  922. },
  923. data:[{value: 85, name: '完成率'}]
  924. }
  925. ]
  926. },
  927. funnel :{
  928. title : {
  929. text: '【商业BI】',
  930. subtext: '漏斗图在营销分析中广泛使用'
  931. },
  932. color : [
  933. 'rgba(255, 69, 0, 0.5)',
  934. 'rgba(255, 150, 0, 0.5)',
  935. 'rgba(255, 200, 0, 0.5)',
  936. 'rgba(155, 200, 50, 0.5)',
  937. 'rgba(55, 200, 100, 0.5)'
  938. ],
  939. tooltip : {
  940. trigger: 'item',
  941. formatter: "{a} <br/>{b} : {c}%"
  942. },
  943. legend: {
  944. y: 'bottom',
  945. data : ['展现','点击','访问','','咨询','订单']
  946. },
  947. series : [
  948. {
  949. name:'预期',
  950. type:'funnel',
  951. y: 60,
  952. x2: 70,
  953. itemStyle: {
  954. normal: {
  955. label: {
  956. formatter: '{b}预期'
  957. },
  958. labelLine: {
  959. show : false
  960. }
  961. },
  962. emphasis: {
  963. label: {
  964. position:'inside',
  965. formatter: '{b}预期 : {c}%'
  966. }
  967. }
  968. },
  969. data:[
  970. {value:60, name:'访问'},
  971. {value:40, name:'咨询'},
  972. {value:20, name:'订单'},
  973. {value:80, name:'点击'},
  974. {value:100, name:'展现'}
  975. ]
  976. },
  977. {
  978. name:'实际',
  979. type:'funnel',
  980. y: 60,
  981. x2: 70,
  982. maxSize: '80%',
  983. itemStyle: {
  984. normal: {
  985. borderColor: '#fff',
  986. borderWidth: 2,
  987. label: {
  988. position: 'inside',
  989. formatter: '{c}%',
  990. textStyle: {
  991. color: '#fff'
  992. }
  993. }
  994. },
  995. emphasis: {
  996. label: {
  997. position:'inside',
  998. formatter: '{b}实际 : {c}%'
  999. }
  1000. }
  1001. },
  1002. data:[
  1003. {value:30, name:'访问'},
  1004. {value:10, name:'咨询'},
  1005. {value:5, name:'订单'},
  1006. {value:50, name:'点击'},
  1007. {value:80, name:'展现'}
  1008. ]
  1009. }
  1010. ]
  1011. },
  1012. mix :(function(){
  1013. // original
  1014. var data = [30, 20, 54, 21, 90, 30, 10];
  1015. var gap = 0;
  1016. var total = 0;
  1017. var maxIndex;
  1018. var dataArray = (function(){
  1019. var max = Math.max.apply(Math, data);
  1020. var min = Math.min.apply(Math, data);
  1021. gap = Math.round((max - min));
  1022. var nd = [{value:data[0] + gap,symbol:'none'}];
  1023. for (var i = 0, l = data.length; i < l; i++) {
  1024. if (data[i] == max) {
  1025. maxIndex = i;
  1026. }
  1027. total += data[i];
  1028. nd.push(data[i] + gap);
  1029. }
  1030. nd.push({value:data[data.length - 1] + gap,symbol:'none'});
  1031. return nd;
  1032. })();
  1033. var option = {
  1034. backgroundColor:'#fff',
  1035. title : {
  1036. text: '【混搭】',
  1037. subtext: '尽情发挥你的天马行空的创意',
  1038. x: 'center'
  1039. },
  1040. legend: {
  1041. data:['销量', '占比'],
  1042. y: 50,
  1043. selectedMode: false
  1044. },
  1045. tooltip : {
  1046. trigger: 'item',
  1047. formatter: function(params){
  1048. if (params.seriesName == '占比') {
  1049. return '总量 : ' + total + '<br/>'
  1050. + params.name + ' : ' + params.value + '<br/>'
  1051. + '占比 : ' + params.percent + '%';
  1052. }
  1053. else if (params.name != '占位'){
  1054. update(params);
  1055. return params.seriesName + '<br/>'
  1056. + params.name + ' : ' + params.value;
  1057. }
  1058. },
  1059. axisPointer: {
  1060. type: 'none'
  1061. }
  1062. },
  1063. toolbox: {
  1064. show : true,
  1065. feature : {
  1066. saveAsImage : {show: true}
  1067. }
  1068. },
  1069. grid:{
  1070. backgroundColor:'#ccc',
  1071. borderWidth:0,
  1072. x: 40,
  1073. x2: 50,
  1074. },
  1075. xAxis : [
  1076. {
  1077. type : 'category',
  1078. boundaryGap : false,
  1079. show : false,
  1080. data : ['占位','周一','周二','周三','周四','周五','周六','周日','占位']
  1081. }
  1082. ],
  1083. yAxis : [
  1084. {
  1085. type : 'value',
  1086. boundaryGap:[0,0.5],
  1087. show : false
  1088. }
  1089. ],
  1090. animation: false,
  1091. series : [
  1092. {
  1093. name:'销量',
  1094. type:'line',
  1095. symbol: 'emptyCircle',
  1096. symbolSize: 6,
  1097. showAllSymbol:true,
  1098. smooth:true,
  1099. itemStyle: {normal: {areaStyle: {type: 'default'}}},
  1100. data: dataArray
  1101. },
  1102. {
  1103. name:'遮罩',
  1104. type:'pie',
  1105. tooltip: {show:false},
  1106. radius : [100, 600],
  1107. itemStyle: {
  1108. normal: {color: '#fff',label:{show:false},labelLine:{show:false}},
  1109. emphasis: {color:'rgba(0,0,0,0)'}
  1110. },
  1111. data:[
  1112. {value:100, name:'直接访问'}
  1113. ]
  1114. },
  1115. {
  1116. name:'占比',
  1117. type:'pie',
  1118. clickable: false,
  1119. clockWise: true,
  1120. radius : [110, 125],
  1121. data:[
  1122. {
  1123. itemStyle: {normal: {
  1124. label:{
  1125. position:'inside',
  1126. formatter: '\n{b} : {c}\n( {d}% )',
  1127. textStyle: {
  1128. fontSize: 15,
  1129. baseline: 'top',
  1130. color: '#1e90ff'
  1131. }
  1132. },
  1133. labelLine:{show:false}
  1134. }}
  1135. },
  1136. {
  1137. name:'其他',
  1138. tooltip: {show:false},
  1139. itemStyle: {normal: {color: '#fff',label:{show:false},labelLine:{show:false}}}
  1140. }
  1141. ]
  1142. }
  1143. ]
  1144. };
  1145. function changePieSeries(params) {
  1146. var curData = params.value - gap;
  1147. option.series[2].startAngle = -90 + (curData / total * 360) / 2;
  1148. option.series[2].data[0].name = params.name;
  1149. option.series[2].data[0].value = curData;
  1150. option.series[2].data[1].value = total - curData;
  1151. for (var i = 1, l = option.series[0].data.length - 1; i < l; i++) {
  1152. if (option.series[0].data[i].symbol) {
  1153. option.series[0].data[i].symbol = 'emptyCircle';
  1154. option.series[0].data[i].symbolSize = 6;
  1155. }
  1156. }
  1157. option.series[0].data[params.dataIndex] = {
  1158. name : params.name,
  1159. value : params.value,
  1160. symbol: 'emptyDiamond',
  1161. symbolSize: 10
  1162. }
  1163. }
  1164. function update(params){
  1165. changePieSeries(params);
  1166. option.animation = true;
  1167. myChart.setOption(option);
  1168. }
  1169. changePieSeries({
  1170. name : option.xAxis[0].data[maxIndex + 1],
  1171. value : option.series[0].data[maxIndex + 1],
  1172. dataIndex: maxIndex + 1
  1173. });
  1174. return option;
  1175. })(),
  1176. effect2: {
  1177. title : {
  1178. text: '【特效】',
  1179. subtext: '轻松实现百度迁徙数据可视化特效'
  1180. },
  1181. color: ['gold','aqua','lime'],
  1182. tooltip : {
  1183. trigger: 'item',
  1184. formatter: '{b}'
  1185. },
  1186. legend: {
  1187. y: 'bottom',
  1188. data:['北京', '上海', '广州'],
  1189. selectedMode: 'single',
  1190. selected:{
  1191. '上海' : false,
  1192. '广州' : false
  1193. }
  1194. },
  1195. toolbox: {
  1196. show : true,
  1197. x: 'right',
  1198. y: 'top',
  1199. feature : {
  1200. mark : {show: true},
  1201. dataView : {show: true, readOnly: false},
  1202. restore : {show: true},
  1203. saveAsImage : {show: true}
  1204. }
  1205. },
  1206. dataRange: {
  1207. min : 0,
  1208. max : 100,
  1209. calculable : true,
  1210. realtime: false,
  1211. x: 'left',
  1212. color: ['#ff3333', 'orange', 'yellow','lime','aqua']
  1213. },
  1214. series : [
  1215. {
  1216. name: '全国',
  1217. type: 'map',
  1218. roam: true,
  1219. hoverable: false,
  1220. mapType: 'china',
  1221. itemStyle:{
  1222. normal:{
  1223. borderColor:'rgba(100,149,237,1)',
  1224. borderWidth:0.5,
  1225. areaStyle:{
  1226. color: '#1b1b1b'
  1227. }
  1228. }
  1229. },
  1230. data:[],
  1231. markLine : {
  1232. smooth:true,
  1233. symbol: ['none', 'circle'],
  1234. symbolSize : 1,
  1235. itemStyle : {
  1236. normal: {
  1237. color:'#fff',
  1238. borderWidth:1,
  1239. borderColor:'rgba(30,144,255,0.5)'
  1240. }
  1241. },
  1242. data : [
  1243. [{name:'北京'},{name:'包头'}],
  1244. [{name:'北京'},{name:'北海'}],
  1245. [{name:'北京'},{name:'武汉'}],
  1246. [{name:'北京'},{name:'无锡'}],
  1247. [{name:'北京'},{name:'厦门'}],
  1248. [{name:'北京'},{name:'西宁'}],
  1249. [{name:'北京'},{name:'徐州'}],
  1250. [{name:'北京'},{name:'烟台'}],
  1251. [{name:'北京'},{name:'盐城'}],
  1252. [{name:'北京'},{name:'珠海'}],
  1253. [{name:'上海'},{name:'包头'}],
  1254. [{name:'上海'},{name:'北海'}],
  1255. [{name:'上海'},{name:'广州'}],
  1256. [{name:'上海'},{name:'郑州'}],
  1257. [{name:'上海'},{name:'长春'}],
  1258. [{name:'上海'},{name:'重庆'}],
  1259. [{name:'上海'},{name:'北京'}],
  1260. [{name:'上海'},{name:'沈阳'}],
  1261. [{name:'上海'},{name:'秦皇岛'}],
  1262. [{name:'上海'},{name:'西安'}],
  1263. [{name:'上海'},{name:'石家庄'}],
  1264. [{name:'上海'},{name:'温州'}],
  1265. [{name:'上海'},{name:'武汉'}],
  1266. [{name:'上海'},{name:'厦门'}],
  1267. [{name:'上海'},{name:'西宁'}],
  1268. [{name:'上海'},{name:'徐州'}],
  1269. [{name:'上海'},{name:'烟台'}],
  1270. [{name:'上海'},{name:'珠海'}],
  1271. [{name:'广州'},{name:'北海'}],
  1272. [{name:'广州'},{name:'郑州'}],
  1273. [{name:'广州'},{name:'长春'}],
  1274. [{name:'广州'},{name:'重庆'}],
  1275. [{name:'广州'},{name:'太原'}],
  1276. [{name:'广州'},{name:'乌鲁木齐'}],
  1277. [{name:'广州'},{name:'温州'}],
  1278. [{name:'广州'},{name:'武汉'}],
  1279. [{name:'广州'},{name:'无锡'}],
  1280. [{name:'广州'},{name:'厦门'}],
  1281. [{name:'广州'},{name:'西宁'}],
  1282. [{name:'广州'},{name:'徐州'}],
  1283. [{name:'广州'},{name:'烟台'}],
  1284. [{name:'广州'},{name:'盐城'}]
  1285. ],
  1286. },
  1287. geoCoord: {
  1288. '上海': [121.4648,31.2891],
  1289. '东莞': [113.8953,22.901],
  1290. '东营': [118.7073,37.5513],
  1291. '中山': [113.4229,22.478],
  1292. '临汾': [111.4783,36.1615],
  1293. '临沂': [118.3118,35.2936],
  1294. '丹东': [124.541,40.4242],
  1295. '丽水': [119.5642,28.1854],
  1296. '乌鲁木齐': [87.9236,43.5883],
  1297. '佛山': [112.8955,23.1097],
  1298. '保定': [115.0488,39.0948],
  1299. '兰州': [103.5901,36.3043],
  1300. '包头': [110.3467,41.4899],
  1301. '北京': [116.4551,40.2539],
  1302. '北海': [109.314,21.6211],
  1303. '南京': [118.8062,31.9208],
  1304. '南宁': [108.479,23.1152],
  1305. '南昌': [116.0046,28.6633],
  1306. '南通': [121.1023,32.1625],
  1307. '厦门': [118.1689,24.6478],
  1308. '台州': [121.1353,28.6688],
  1309. '合肥': [117.29,32.0581],
  1310. '呼和浩特': [111.4124,40.4901],
  1311. '咸阳': [108.4131,34.8706],
  1312. '哈尔滨': [127.9688,45.368],
  1313. '唐山': [118.4766,39.6826],
  1314. '嘉兴': [120.9155,30.6354],
  1315. '大同': [113.7854,39.8035],
  1316. '大连': [122.2229,39.4409],
  1317. '天津': [117.4219,39.4189],
  1318. '太原': [112.3352,37.9413],
  1319. '威海': [121.9482,37.1393],
  1320. '宁波': [121.5967,29.6466],
  1321. '宝鸡': [107.1826,34.3433],
  1322. '宿迁': [118.5535,33.7775],
  1323. '常州': [119.4543,31.5582],
  1324. '广州': [113.5107,23.2196],
  1325. '廊坊': [116.521,39.0509],
  1326. '延安': [109.1052,36.4252],
  1327. '张家口': [115.1477,40.8527],
  1328. '徐州': [117.5208,34.3268],
  1329. '德州': [116.6858,37.2107],
  1330. '惠州': [114.6204,23.1647],
  1331. '成都': [103.9526,30.7617],
  1332. '扬州': [119.4653,32.8162],
  1333. '承德': [117.5757,41.4075],
  1334. '拉萨': [91.1865,30.1465],
  1335. '无锡': [120.3442,31.5527],
  1336. '日照': [119.2786,35.5023],
  1337. '昆明': [102.9199,25.4663],
  1338. '杭州': [119.5313,29.8773],
  1339. '枣庄': [117.323,34.8926],
  1340. '柳州': [109.3799,24.9774],
  1341. '株洲': [113.5327,27.0319],
  1342. '武汉': [114.3896,30.6628],
  1343. '汕头': [117.1692,23.3405],
  1344. '江门': [112.6318,22.1484],
  1345. '沈阳': [123.1238,42.1216],
  1346. '沧州': [116.8286,38.2104],
  1347. '河源': [114.917,23.9722],
  1348. '泉州': [118.3228,25.1147],
  1349. '泰安': [117.0264,36.0516],
  1350. '泰州': [120.0586,32.5525],
  1351. '济南': [117.1582,36.8701],
  1352. '济宁': [116.8286,35.3375],
  1353. '海口': [110.3893,19.8516],
  1354. '淄博': [118.0371,36.6064],
  1355. '淮安': [118.927,33.4039],
  1356. '深圳': [114.5435,22.5439],
  1357. '清远': [112.9175,24.3292],
  1358. '温州': [120.498,27.8119],
  1359. '渭南': [109.7864,35.0299],
  1360. '湖州': [119.8608,30.7782],
  1361. '湘潭': [112.5439,27.7075],
  1362. '滨州': [117.8174,37.4963],
  1363. '潍坊': [119.0918,36.524],
  1364. '烟台': [120.7397,37.5128],
  1365. '玉溪': [101.9312,23.8898],
  1366. '珠海': [113.7305,22.1155],
  1367. '盐城': [120.2234,33.5577],
  1368. '盘锦': [121.9482,41.0449],
  1369. '石家庄': [114.4995,38.1006],
  1370. '福州': [119.4543,25.9222],
  1371. '秦皇岛': [119.2126,40.0232],
  1372. '绍兴': [120.564,29.7565],
  1373. '聊城': [115.9167,36.4032],
  1374. '肇庆': [112.1265,23.5822],
  1375. '舟山': [122.2559,30.2234],
  1376. '苏州': [120.6519,31.3989],
  1377. '莱芜': [117.6526,36.2714],
  1378. '菏泽': [115.6201,35.2057],
  1379. '营口': [122.4316,40.4297],
  1380. '葫芦岛': [120.1575,40.578],
  1381. '衡水': [115.8838,37.7161],
  1382. '衢州': [118.6853,28.8666],
  1383. '西宁': [101.4038,36.8207],
  1384. '西安': [109.1162,34.2004],
  1385. '贵阳': [106.6992,26.7682],
  1386. '连云港': [119.1248,34.552],
  1387. '邢台': [114.8071,37.2821],
  1388. '邯郸': [114.4775,36.535],
  1389. '郑州': [113.4668,34.6234],
  1390. '鄂尔多斯': [108.9734,39.2487],
  1391. '重庆': [107.7539,30.1904],
  1392. '金华': [120.0037,29.1028],
  1393. '铜川': [109.0393,35.1947],
  1394. '银川': [106.3586,38.1775],
  1395. '镇江': [119.4763,31.9702],
  1396. '长春': [125.8154,44.2584],
  1397. '长沙': [113.0823,28.2568],
  1398. '长治': [112.8625,36.4746],
  1399. '阳泉': [113.4778,38.0951],
  1400. '青岛': [120.4651,36.3373],
  1401. '韶关': [113.7964,24.7028]
  1402. }
  1403. },
  1404. {
  1405. name: '北京',
  1406. type: 'map',
  1407. mapType: 'china',
  1408. data:[],
  1409. markLine : {
  1410. smooth:true,
  1411. effect : {
  1412. show: true,
  1413. scaleSize: 1,
  1414. period: 30,
  1415. color: '#fff',
  1416. shadowBlur: 10
  1417. },
  1418. itemStyle : {
  1419. normal: {
  1420. borderWidth:1,
  1421. lineStyle: {
  1422. type: 'solid',
  1423. shadowBlur: 10
  1424. }
  1425. }
  1426. },
  1427. data : [
  1428. [{name:'北京'}, {name:'上海',value:95}],
  1429. [{name:'北京'}, {name:'广州',value:90}],
  1430. [{name:'北京'}, {name:'大连',value:80}],
  1431. [{name:'北京'}, {name:'南宁',value:70}],
  1432. [{name:'北京'}, {name:'南昌',value:60}],
  1433. [{name:'北京'}, {name:'拉萨',value:50}],
  1434. [{name:'北京'}, {name:'长春',value:40}],
  1435. [{name:'北京'}, {name:'包头',value:30}],
  1436. [{name:'北京'}, {name:'重庆',value:20}],
  1437. [{name:'北京'}, {name:'常州',value:10}]
  1438. ]
  1439. },
  1440. markPoint : {
  1441. symbol:'emptyCircle',
  1442. symbolSize : function (v){
  1443. return 10 + v/10
  1444. },
  1445. effect : {
  1446. show: true,
  1447. shadowBlur : 0
  1448. },
  1449. itemStyle:{
  1450. normal:{
  1451. label:{show:false}
  1452. },
  1453. emphasis: {
  1454. label:{position:'top'}
  1455. }
  1456. },
  1457. data : [
  1458. {name:'上海',value:95},
  1459. {name:'广州',value:90},
  1460. {name:'大连',value:80},
  1461. {name:'南宁',value:70},
  1462. {name:'南昌',value:60},
  1463. {name:'拉萨',value:50},
  1464. {name:'长春',value:40},
  1465. {name:'包头',value:30},
  1466. {name:'重庆',value:20},
  1467. {name:'常州',value:10}
  1468. ]
  1469. }
  1470. },
  1471. {
  1472. name: '上海',
  1473. type: 'map',
  1474. mapType: 'china',
  1475. data:[],
  1476. markLine : {
  1477. smooth:true,
  1478. effect : {
  1479. show: true,
  1480. scaleSize: 1,
  1481. period: 30,
  1482. color: '#fff',
  1483. shadowBlur: 10
  1484. },
  1485. itemStyle : {
  1486. normal: {
  1487. borderWidth:1,
  1488. lineStyle: {
  1489. type: 'solid',
  1490. shadowBlur: 10
  1491. }
  1492. }
  1493. },
  1494. data : [
  1495. [{name:'上海'},{name:'包头',value:95}],
  1496. [{name:'上海'},{name:'昆明',value:90}],
  1497. [{name:'上海'},{name:'广州',value:80}],
  1498. [{name:'上海'},{name:'郑州',value:70}],
  1499. [{name:'上海'},{name:'长春',value:60}],
  1500. [{name:'上海'},{name:'重庆',value:50}],
  1501. [{name:'上海'},{name:'长沙',value:40}],
  1502. [{name:'上海'},{name:'北京',value:30}],
  1503. [{name:'上海'},{name:'丹东',value:20}],
  1504. [{name:'上海'},{name:'大连',value:10}]
  1505. ]
  1506. },
  1507. markPoint : {
  1508. symbol:'emptyCircle',
  1509. symbolSize : function (v){
  1510. return 10 + v/10
  1511. },
  1512. effect : {
  1513. show: true,
  1514. shadowBlur : 0
  1515. },
  1516. itemStyle:{
  1517. normal:{
  1518. label:{show:false}
  1519. },
  1520. emphasis: {
  1521. label:{position:'top'}
  1522. }
  1523. },
  1524. data : [
  1525. {name:'包头',value:95},
  1526. {name:'昆明',value:90},
  1527. {name:'广州',value:80},
  1528. {name:'郑州',value:70},
  1529. {name:'长春',value:60},
  1530. {name:'重庆',value:50},
  1531. {name:'长沙',value:40},
  1532. {name:'北京',value:30},
  1533. {name:'丹东',value:20},
  1534. {name:'大连',value:10}
  1535. ]
  1536. }
  1537. },
  1538. {
  1539. name: '广州',
  1540. type: 'map',
  1541. mapType: 'china',
  1542. data:[],
  1543. markLine : {
  1544. smooth:true,
  1545. effect : {
  1546. show: true,
  1547. scaleSize: 1,
  1548. period: 30,
  1549. color: '#fff',
  1550. shadowBlur: 10
  1551. },
  1552. itemStyle : {
  1553. normal: {
  1554. borderWidth:1,
  1555. lineStyle: {
  1556. type: 'solid',
  1557. shadowBlur: 10
  1558. }
  1559. }
  1560. },
  1561. data : [
  1562. [{name:'广州'},{name:'福州',value:95}],
  1563. [{name:'广州'},{name:'太原',value:90}],
  1564. [{name:'广州'},{name:'长春',value:80}],
  1565. [{name:'广州'},{name:'重庆',value:70}],
  1566. [{name:'广州'},{name:'西安',value:60}],
  1567. [{name:'广州'},{name:'成都',value:50}],
  1568. [{name:'广州'},{name:'常州',value:40}],
  1569. [{name:'广州'},{name:'北京',value:30}],
  1570. [{name:'广州'},{name:'北海',value:20}],
  1571. [{name:'广州'},{name:'海口',value:10}]
  1572. ]
  1573. },
  1574. markPoint : {
  1575. symbol:'emptyCircle',
  1576. symbolSize : function (v){
  1577. return 10 + v/10
  1578. },
  1579. effect : {
  1580. show: true,
  1581. shadowBlur : 0
  1582. },
  1583. itemStyle:{
  1584. normal:{
  1585. label:{show:false}
  1586. },
  1587. emphasis: {
  1588. label:{position:'top'}
  1589. }
  1590. },
  1591. data : [
  1592. {name:'福州',value:95},
  1593. {name:'太原',value:90},
  1594. {name:'长春',value:80},
  1595. {name:'重庆',value:70},
  1596. {name:'西安',value:60},
  1597. {name:'成都',value:50},
  1598. {name:'常州',value:40},
  1599. {name:'北京',value:30},
  1600. {name:'北海',value:20},
  1601. {name:'海口',value:10}
  1602. ]
  1603. }
  1604. }
  1605. ]
  1606. },
  1607. effect3:{
  1608. title : {
  1609. text: '【特效】',
  1610. subtext: '大规模炫光特效'
  1611. },
  1612. color: [
  1613. 'rgba(250, 250, 210, 0.8)',
  1614. 'rgba(14, 241, 242, 0.8)',
  1615. 'rgba(37, 140, 249, 0.8)'
  1616. ],
  1617. legend: {
  1618. y:'bottom',
  1619. data:['强','中','弱']
  1620. },
  1621. toolbox: {
  1622. show : true,
  1623. x: 'right',
  1624. y: 'top',
  1625. feature : {
  1626. mark : {show: true},
  1627. dataView : {show: true, readOnly: false},
  1628. restore : {show: true},
  1629. saveAsImage : {show: true}
  1630. }
  1631. },
  1632. series : [
  1633. {
  1634. name: '弱',
  1635. type: 'map',
  1636. mapType: 'china',
  1637. itemStyle:{
  1638. normal:{
  1639. borderColor:'rgba(100,149,237,1)',
  1640. borderWidth:1.5,
  1641. areaStyle:{
  1642. color: '#1b1b1b'
  1643. }
  1644. }
  1645. },
  1646. data : [],
  1647. markPoint : {
  1648. symbolSize: 2,
  1649. large: true,
  1650. effect : {
  1651. show: true
  1652. },
  1653. data : (function(){
  1654. var data = [];
  1655. var len = 2000;
  1656. var geoCoord
  1657. while(len--) {
  1658. geoCoord = placeList[len % placeList.length].geoCoord;
  1659. data.push({
  1660. name : placeList[len % placeList.length].name + len,
  1661. value : 10,
  1662. geoCoord : [
  1663. geoCoord[0] + Math.random() * 5 * -1,
  1664. geoCoord[1] + Math.random() * 3 * -1
  1665. ]
  1666. })
  1667. }
  1668. return data;
  1669. })()
  1670. }
  1671. },
  1672. {
  1673. name: '中',
  1674. type: 'map',
  1675. mapType: 'china',
  1676. data : [],
  1677. markPoint : {
  1678. symbolSize: 3,
  1679. large: true,
  1680. effect : {
  1681. show: true
  1682. },
  1683. data : (function(){
  1684. var data = [];
  1685. var len = 500;
  1686. var geoCoord
  1687. while(len--) {
  1688. geoCoord = placeList[len % placeList.length].geoCoord;
  1689. data.push({
  1690. name : placeList[len % placeList.length].name + len,
  1691. value : 50,
  1692. geoCoord : [
  1693. geoCoord[0] + Math.random() * 5 * -1,
  1694. geoCoord[1] + Math.random() * 3 * -1
  1695. ]
  1696. })
  1697. }
  1698. return data;
  1699. })()
  1700. }
  1701. },
  1702. {
  1703. name: '强',
  1704. type: 'map',
  1705. mapType: 'china',
  1706. hoverable: false,
  1707. roam:true,
  1708. data : [],
  1709. markPoint : {
  1710. symbol : 'diamond',
  1711. symbolSize: 6,
  1712. large: true,
  1713. effect : {
  1714. show: true
  1715. },
  1716. data : (function(){
  1717. var data = [];
  1718. var len = placeList.length;
  1719. while(len--) {
  1720. data.push({
  1721. name : placeList[len].name,
  1722. value : 90,
  1723. geoCoord : placeList[len].geoCoord
  1724. })
  1725. }
  1726. return data;
  1727. })()
  1728. }
  1729. }
  1730. ]
  1731. }
  1732. }
  1733. function initChart(index) {
  1734. disposeChart();
  1735. var dom = $('section.active .main')[0];
  1736. if (dom) {
  1737. var key = $(dom).attr('optionKey');
  1738. myChart = echarts.init(dom, 'infographic');
  1739. myChart.setOption(optionMap[key]);
  1740. }
  1741. }
  1742. function disposeChart() {
  1743. if (myChart) {
  1744. myChart.dispose();
  1745. myChart = null;
  1746. }
  1747. }
  1748. require.config({
  1749. paths:{
  1750. echarts: './js/dist',
  1751. }
  1752. });
  1753. $(function(){
  1754. require(
  1755. [
  1756. 'echarts',
  1757. 'echarts/chart/line',
  1758. 'echarts/chart/bar',
  1759. 'echarts/chart/scatter',
  1760. 'echarts/chart/k',
  1761. 'echarts/chart/pie',
  1762. 'echarts/chart/force',
  1763. 'echarts/chart/chord',
  1764. 'echarts/chart/map',
  1765. 'echarts/chart/gauge',
  1766. 'echarts/chart/funnel'
  1767. ],
  1768. function (ec) {
  1769. echarts = ec;
  1770. resize();
  1771. $('.page div').click(pageHandler);
  1772. window.onresize = function(){
  1773. resize();
  1774. }
  1775. }
  1776. );
  1777. });
  1778. function resize() {
  1779. var height = document.documentElement.clientHeight - 50 + 'px';
  1780. var width = document.documentElement.clientWidth + 'px';
  1781. $('#content').height(height).width(width);
  1782. $('.section').height(height).width(width);
  1783. $('.main').height(document.documentElement.clientHeight - 65 + 'px');
  1784. myChart && myChart.resize();
  1785. }
  1786. function bindPageHandler() {
  1787. }
  1788. function pageHandler() {
  1789. var upOrdown = $(this)[0].className;
  1790. if (upOrdown == 'page-down') {
  1791. if ($(this).html() == '再看一次') {
  1792. window.location.reload();
  1793. return;
  1794. }
  1795. if (!$('.active').removeClass('active').css('left', '-100%')
  1796. .next().addClass('active').css('left', 0).next()[0]
  1797. ) {
  1798. $(this).html('再看一次');
  1799. }
  1800. else {
  1801. $(this).html('下一页');
  1802. }
  1803. $(this).prev().removeClass('disabled');
  1804. }
  1805. else if (upOrdown == 'page-up') {
  1806. !$('.active').removeClass('active').css('left', '100%')
  1807. .prev().addClass('active').css('left', 0).prev()[0]
  1808. && $(this).addClass('disabled');
  1809. $(this).next().removeClass('disabled').html('下一页');
  1810. }
  1811. initChart();
  1812. }
  1813. if (document.location.href.indexOf('local') == -1) {
  1814. var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://");
  1815. document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3Fb78830c9a5dad062d08b90b2bc0cf5da' type='text/javascript'%3E%3C/script%3E"));
  1816. }