investHome.js 42 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360
  1. let app = new Vue({
  2. el: '#app',
  3. data () {
  4. return {
  5. showTip: false,
  6. showTip2: false,
  7. tipTitle: '',
  8. tipTitle2: '',
  9. year: '2022',
  10. time: '',
  11. timer: '',
  12. mapName: 'shanxi',
  13. geoCoordMap: {},
  14. config1: {
  15. number: [100],
  16. content: '{nt}个',
  17. },
  18. storageRecordConfig: null,
  19. companyList: [
  20. { name: '山西焦煤' },
  21. { name: '晋能控股' },
  22. { name: '华新燃气' },
  23. { name: '山西建投' },
  24. { name: '潞安化工' },
  25. { name: '华远陆港' },
  26. { name: '航产集团' },
  27. { name: '大地控股' },
  28. { name: '国新能源' },
  29. { name: '汾酒集团' },
  30. { name: '云时代' },
  31. { name: '神农科技' },
  32. { name: '华阳新材' },
  33. { name: '华舰体育' },
  34. { name: '交控集团' },
  35. { name: '文旅集团' },
  36. { name: '水控集团' },
  37. { name: '太重集团' },
  38. ],
  39. amountList: amountList,
  40. amountTotal: 0,
  41. classOption: {
  42. step: 0.5
  43. }
  44. }
  45. },
  46. created () {
  47. this.amountList.map(item => {
  48. this.amountTotal += Number(item.value)
  49. })
  50. this.time = formatDate()
  51. this.timer = setInterval(() => {
  52. this.time = formatDate()
  53. }, 1000)
  54. },
  55. beforeDestroy () {
  56. if (this.timer) {
  57. clearInterval(this.timer);
  58. }
  59. },
  60. mounted () {
  61. setTimeout(() => {
  62. // 左侧图表
  63. //this.initChartTip()
  64. this.initChartTip2()
  65. this.initChartTip3()
  66. this.initChartTip4()
  67. this.initChartL1()
  68. this.initChartL2()
  69. this.initChartR1()
  70. this.initChinaChart()
  71. this.initProjectList()
  72. }, 0)
  73. },
  74. methods: {
  75. numFormat (value) {
  76. if (!value) return '0'
  77. var intPart = Number(value).toFixed(0) // 获取整数部分
  78. var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
  79. var floatPart = '.00' // 预定义小数部分
  80. var value2Array = value.toString().split('.')
  81. // =2表示数据有小数位
  82. if (value2Array.length === 2) {
  83. floatPart = value2Array[1].toString() // 拿到小数部分
  84. if (floatPart.length === 1) {
  85. // 补0
  86. return intPartFormat + '.' + floatPart + '0'
  87. } else {
  88. return intPartFormat + '.' + floatPart
  89. }
  90. } else {
  91. return intPartFormat
  92. }
  93. },
  94. convertData (data) {
  95. var res = []
  96. for (var i = 0; i < data.length; i++) {
  97. var geoCoord = this.geoCoordMap[data[i].name]
  98. if (geoCoord) {
  99. res.push({
  100. name: data[i].name,
  101. value: geoCoord.concat(data[i].value),
  102. })
  103. }
  104. }
  105. return res
  106. },
  107. initChinaChart () {
  108. var data = [
  109. { name: '吕梁市', value: 150 },
  110. { name: '大同市', value: 190 },
  111. { name: '忻州市', value: 140 },
  112. { name: '朔州市', value: 160 },
  113. { name: '晋中市', value: 100 },
  114. { name: '太原市', value: 300 },
  115. { name: '临汾市', value: 190 },
  116. { name: '长治市', value: 100 },
  117. { name: '晋城市', value: 280 },
  118. { name: '运城市', value: 180 },
  119. { name: '阳泉市', value: 110 },
  120. ]
  121. var moveLine = {
  122. normal: [
  123. {
  124. fromName: '太原市',
  125. toName: '吕梁市',
  126. coords: [
  127. [112.3352, 37.9413],
  128. [111.3574, 37.7325],
  129. ],
  130. },
  131. {
  132. fromName: '太原市',
  133. toName: '忻州市',
  134. coords: [
  135. [112.3352, 37.9413],
  136. [112.4561, 38.8971],
  137. ],
  138. },
  139. {
  140. fromName: '太原市',
  141. toName: '临汾市',
  142. coords: [
  143. [112.3352, 37.9413],
  144. [111.4783, 36.1615],
  145. ],
  146. },
  147. {
  148. fromName: '太原市',
  149. toName: '阳泉市',
  150. coords: [
  151. [112.3352, 37.9413],
  152. [113.4778, 38.0951],
  153. ],
  154. },
  155. {
  156. fromName: '太原市',
  157. toName: '晋中市',
  158. coords: [
  159. [112.3352, 37.9413],
  160. [112.7747, 37.37],
  161. ],
  162. },
  163. {
  164. fromName: '太原市',
  165. toName: '运城市',
  166. coords: [
  167. [112.3352, 37.9413],
  168. [111.1487, 35.2002],
  169. ],
  170. },
  171. {
  172. fromName: '太原市',
  173. toName: '大同市',
  174. coords: [
  175. [112.3352, 37.9413],
  176. [113.7854, 39.8035],
  177. ],
  178. },
  179. {
  180. fromName: '太原市',
  181. toName: '晋城市',
  182. coords: [
  183. [112.3352, 37.9413],
  184. [112.7856, 35.6342],
  185. ],
  186. },
  187. {
  188. fromName: '太原市',
  189. toName: '长治市',
  190. coords: [
  191. [112.3352, 37.9413],
  192. [112.8625, 36.4746],
  193. ],
  194. },
  195. {
  196. fromName: '太原市',
  197. toName: '朔州市',
  198. coords: [
  199. [112.3352, 37.9413],
  200. [113.0713, 39.6991],
  201. ],
  202. },
  203. ],
  204. }
  205. /*获取地图数据*/
  206. let myChart = echarts.init(this.$refs['echarts-map'])
  207. echarts.registerMap('shanxi', {
  208. type: 'FeatureCollection',
  209. features: [
  210. {
  211. type: 'Feature',
  212. id: '1409',
  213. properties: { name: '忻州市', cp: [112.4561, 38.8971], childNum: 14 },
  214. geometry: {
  215. type: 'Polygon',
  216. coordinates: [
  217. '@@Vx@lnbn¦WlnnUšmš°š²VšV‚VVVnUn„ºlz@l„„@Jƒ@kXWVXl@Lƒa@„ƒKUL„ŽlbnKlLnK‚LnKÆXn°šbVV@bUVl°Un@LnaVJUbW@UX²l‚@ČwlVVIšWnkÆa°„„anV‚Kn°™UW¯@™aVUVk@Un@„aV@ValwUanmWU„k@WVUUanaVwnLVl°@nk@mVU@UVK@w„LVKVU@ƒ„K@UUKVUV@@bnL„a‚V„aôšlIXmlKX_°KVV@bVV„@šzV`kblI„V„Ul‚šL@bnV@V„Ċll„„VlIXW@k„a‚U²blKšVnIlJ„albXXlWVn°JnšnL@l@XlJlaX@„X˜W²@l_VmnKšU„blU@mnkVK„¯@U@ƒma@kX¥VƒmakkƒLƒa@aƒ@WIUUVXWWnk@a°a@kkm@kUUmJm@WUUUIk`m@V—kaWWkX™KmƒXk¯ƒ@WKƒLkak@±bƒw@ƒaƒa@akaƒ@ma¯@ƒL—KÇÅkKWbkmġ™±ÅUƒLUK™VVkƒm¯LUVVbƒ„UwUW¯bm„ƒULƒxWJ—@ƒklmkUm@@KnwVkVK@akwƒ@@a¯bƒKkn›VUI™b¯mmbk@UbmKUL@xUUƒ@klmLUŽlVXI‚VVVUVUœU`mLXVWbXnW`Ų°xmށxU@mĉƒƒwU@mbU@UƒmbkVW¦kJ™@ƒX@`¯Im@UlUVVnb@bWJXnmbƒJUU™UUaƒ@UamIkaƒxƒ@@x@b',
  218. ],
  219. encodeOffsets: [[113614, 39657]],
  220. },
  221. },
  222. {
  223. type: 'Feature',
  224. id: '1411',
  225. properties: { name: '吕梁市', cp: [111.3574, 37.7325], childNum: 13 },
  226. geometry: {
  227. type: 'Polygon',
  228. coordinates: [
  229. '@@@a@w„@„wlbnJVb„@VbšVVV„InaWmXI@a‚aUmVUVkn@°J@_„Wš@lIX¥lUnaV„V@naV@„xĊ„n‚V@‚wn¯wƱX_WmXaWUnKV_V›VUUUUWJkUVnKlk¯™@@kmKUaٱKkU@WmI@WUIlUUmVwXƒ‚w@ƒUlUVwœV‚@„Lnb‚W@anU@UšaVkô@l»n@na˜JnUÈLVaƃUUVm„VKVƒ²L@mU_lK@UVWkU‚a@a@U¯aUaƒÑóÑUb™„ƒKk@@aƒk¯mVaUwVƒÑkWUmK@UUKmXUWÝwUa™LUU@aWJUUU@Ua݄U@WL@VKVaVI@WnU@alIVKƒƒ@kIƒmIkJ@™m@ƒ™@@_™K@xƒ@kaW@U„@Vmn@ŽUK@mIƒJUXV¤XXWlkKƒkkK@XmJVakImJU@ó™¯LWKUV@nUVƒLkxmKkLma@kXKmmƒLƒab™LmK@V@mXVÆUxƒX@`nL„aV@@VmLUVnLlLš˜„b@„šŽ°²nx@b‚VUxlb@V¯bUV@zV‚XVĊXVx@lVn@VnnmŽUš@LlJXVƒz¯VWVXbšV@bmn™VUVk„Çþń@XVxmbUlV„Uln„W„@„Xl‚@VLXÒ@bÞJ°¦„L˜ò„@nU‚b@°„X@ŽXbmVU„V„nb@x‚x',
  230. ],
  231. encodeOffsets: [[113614, 39657]],
  232. },
  233. },
  234. {
  235. type: 'Feature',
  236. id: '1410',
  237. properties: { name: '临汾市', cp: [111.4783, 36.1615], childNum: 17 },
  238. geometry: {
  239. type: 'Polygon',
  240. coordinates: [
  241. '@@nW‚@@UnLšK‚a„b„KnnWL@lnblKnLlw„KVU@mVUXL°KôšV@nIlJUbnI@WlL„llLXkWWU£VW„InJ‚@VL@nm@UVƒX@lb„@@wšL@`‚@„šn@V@lw„@n„VmVX„WmwnUlƒœa@_lK„wVlUn°xVKVXXWlUšVVI@K@K„n°KœwlVlU@kna@V_„Wn‚m„UVm@kXml_@m„LlKXw°m@_ôJVUV@X™l@UaV@Va°I„lk»VwUkVmwUmmVn@V¯@KƒU—wmK@U¯wUVÝ@mJƒU—nWK™@@UnKVa„_lykUmKÛnm@™x@ƒUUlwVk™ƒXW@ƒa@Uƒ@@K@ƒkIV™nammVakUlƒ@wX@@kƒ™¯@ƒVVbml@„„°UbULmlVbnbÅK±VƒKVXUJWa@ULWaUU@@U@aWK@UkxUKƒLUUUJ±UkL@V±kk@kam@UV@l@LWl@n@VVUx„LlUUx@VUV™U@aƒIUl™L@°mLU‚ƒbkUUaWUUaUU@aWK—LWJ@bUL@VUVVbU@m@a@kmKmnĉlUK™XƒWUblb—xmIkƒƒU@xWb@lkšVx™LXŽmzVV@bklVVUzm˜@bk„@Vx@xlŽU„@lUbVnl@„Wxnl@n@ŽUbV„mL‚mƒb@`X@lUX@@xlnkLWaUJnnWV™Vn@l„@bULVV@l™V@XnJVX',
  242. ],
  243. encodeOffsets: [[113063, 37784]],
  244. },
  245. },
  246. {
  247. type: 'Feature',
  248. id: '1407',
  249. properties: { name: '晋中市', cp: [112.7747, 37.37], childNum: 11 },
  250. geometry: {
  251. type: 'Polygon',
  252. coordinates: [
  253. '@@@šlInJ„lJ„@‚„ULkJ@bmV@XUJUb‚L@UXKV@ރVbV@VVXI@bVVšKVbÞxVXnWVL@VnLV‚lX„ÒUŽVxUb°n„l@bl@„LšƒVaô҄ÒVb°b@VnLnnV@lmn@lb„U„V@„‚JœUVV‚Xkl@lUzmJ@xšXkl‚bUn„JVšUb„nU‚lb„V@nlLX@lakšV`Ub°š@XVJnU‚L²KlxnI@KV@lbUbVV„KnVl@„zlm@Uš@nŽšI@WUaVl@@mVU„@XkW@ƒnkVKVƒ„_Vw„y@knwVa‚@XalU„@šVnml@„X@V„L‚KVaÞbnnlJšI„mVKn„VVVInVlU„@„m@™mXK@UmyUI@mWUUakamw@wUwmLkakwVƒmK™w@wUam£y@am_ƒW@™UU@knmm„amU@WUa@knw@ƒUUUUV@nƒJm@mVUkKVUUUkKmwƒKULƒKUImV@lUn™nŽm@mbUK@°™bUnmbUmkkƒWUb@am@UXkK@a±@™V™@ĉř„V‚UXVxUVkLWl¯@@bULUlm@@nm`—XƒlWakIkm›VUbUL@Vm@kIƒ@@Kšm@—VaX‚I@W@aU@kUƒVU_™KƒbƒJkkǎ™b@nkKmL™wÅW@kVUUƒVU@WUIƒJmIXmma@_kyVaUUlkUm@ƒkU›x¯Lƒm@L@LUJ™UkVWXUWUL¯wVmUkƒxkL@`›bk„mVnxƒXUWUnmƒƒ@kxU@',
  254. ],
  255. encodeOffsets: [[114087, 37682]],
  256. },
  257. },
  258. {
  259. type: 'Feature',
  260. id: '1408',
  261. properties: { name: '运城市', cp: [111.1487, 35.2002], childNum: 13 },
  262. geometry: {
  263. type: 'Polygon',
  264. coordinates: [
  265. '@@„Vl„nJ˜wkaVa„XšWVLĊknmnL‚l@@bn‚V@UaVU@UVK@aXI˜KXL@bVVVbXVVblV„aVnK@¯šKVk„J@bšVVU@UVwkVƒKVwUUm@@Xk@K@kVUn@lbl@²l@UlK²VVIVV„KVLlw@VXL@b@VV@VŽXbVK‚@XbVIUW„L‚U²ÆLmaUankVKVaƒ¯@ƒnkUa„U°@„š‚n@@kWa„UVaXUW@IXKVw@U™ƒ„™WU@W@@UUƒU@mn@ƒ`m@UUULkUmJ™IUƒ@@UƒK@U@›anƒ™ak_@wmKUwmakV™kmK™V™k¯b™wƒ`kwUIÇx¯»ÇaŃmn@@™mƒmUkV@wkKW@kxmL™UkĉLÝk™xÝw¯lóVU„mV@ĀVVX¦W¤kz@`Vx°„²ĸ‚š@„Ul@x„êĸNJ°¤V„VlXLWnXxmV@nUl@„',
  266. ],
  267. encodeOffsets: [[113232, 36597]],
  268. },
  269. },
  270. {
  271. type: 'Feature',
  272. id: '1402',
  273. properties: { name: '大同市', cp: [113.7854, 39.8035], childNum: 8 },
  274. geometry: {
  275. type: 'Polygon',
  276. coordinates: [
  277. '@@²£šyl@Ȑ˜Ė@bĸŽĢbĸ„˜X„a‚KŤnn@ŎôllÈx„nVnÞDŽV@b‚nXllL°KšbVb@J@b—„‚„@ŽU„„xlKXLlKlXk„@Ulk„JlkUƒVKXUƒÇVIVm@_nǚLšašl‚w„VnU@UUwma@aƒaÝaLmUk@@Wƒ@U@@X™wVWÝUUUk@@VmLƒKV»nwUw™aUL@`mzƒJUIVƒUaUw™KUaVIlJôanÑlLVUn@ša„@VV„@@UUwVK°Vn_lJÆLœéW@UUUÅ@»lm@aÞIVwXW˜UUkkm@U@aƒU@mwU£VWU_kWmƒXwW_°yUkkK@UÇK@kkUVymóK—U@KWIƒbUak@mJ@bkbmLkŽ™UmƒkVU„W¦@lnb@„@Vƒ°ULml@nkVƒa™VmLUnk`±@—XƒWW@kbǦXޝ„WxI@xmbmxXlWV„„@bŎUz@J‚b@bÞb™ŽU@Wbk@ƒxk@WX¯VۙƒWÝbÝUkVUU@alI@a@akLWa™m@U¯UUmÇL@K@aU@¯VUkƒKmX@`@œkJ@nV‚Ub@lbVÆXVW„ULU`VbkLUV@XWl@bXJ˜@VbV@Vl',
  278. ],
  279. encodeOffsets: [[115335, 41209]],
  280. },
  281. },
  282. {
  283. type: 'Feature',
  284. id: '1404',
  285. properties: { name: '长治市', cp: [112.8625, 36.4746], childNum: 12 },
  286. geometry: {
  287. type: 'Polygon',
  288. coordinates: [
  289. '@@Uk™Lky@I‚JVa@mÞaWšy@_W@_WƒXVlUVwš@nw°K@m„UƒVaƒmVkU@mmmnLVUmKXa™U@IlKVUnK@UmWkX@WV_Vƒ@akU@a„KWIXyƒIUVmUn™Ua@WaXUVKVmkUWVkUƒLU@@VƒbƒKbƒIUmƒ@mbVL—x›WUUkn±V¯wƒbÅJUbmLkbmKÅKƒbVnUbƒV™KUb™KUbmLKmƒb™aƒKkUm@UŽnn‚VnxUVlUxl¼ƒk¯JUbU@Vbk@WšU@UVóI@`¯nWxkLƒK@nk`Wn@lUnƒVnm‚ƒXU`@mb@lkV@„VnklVVUblz@`nbWnnJ„IVJ@XUVV„UV@lÆXšxnKlL@mšaȍll„I„ašLV`„UlVV@@b@XJWUb@˜™n@L„@lJn@@UVKVaœUlnlJXb„k˜Wn_@mn@VkVK@a°@XklKVUUwVWUšƒĊƚ@šU²@@blLVWn@@bVa„XllVnnaVmša@¯VLnan@‚šmVm@knUVJ',
  290. ],
  291. encodeOffsets: [[116269, 37637]],
  292. },
  293. },
  294. {
  295. type: 'Feature',
  296. id: '1406',
  297. properties: { name: '朔州市', cp: [113.0713, 39.6991], childNum: 5 },
  298. geometry: {
  299. type: 'Polygon',
  300. coordinates: [
  301. '@@XXWVXVWnnlnn@èÆ¼@„„xlš„ŽV„nblšššVŽÈUVl‚š@„blnœL܃ĊmUkU@Ua‚—@WI@aXk@WVUlKUaV_VKXƒWUUÅka@VaU@mlI@›@_nW„LVl°UV@@b@LÈKVn°V@VšnXblK@b@bkJ@bVVlUÞVÞa„Xܚ°UXWl@„wl@XaV@šÝa@aa@IVyƍ@aƒƒXUWknwna@w‚JXw°ƒWÈ¥kI@W@kmKm™¯IUmkXWWkaƒbkImJ™UkL±aVƒb@lWXkJƒUkƒĉkƒ@UmU@a™KkƒVƒUkJlaU_™yƒ@UU@aUU¯LW`kLWnkJó™ƒbUƒbmK@aU@UVVL@VƒL@„UVULƒK@xUL@VUV@nml¯@UkmKUxmbVbUV@XƒlXVmnVbkxUbU@ƒbm@@VUlUVšb°@VX¯šm‚',
  302. ],
  303. encodeOffsets: [[114615, 40562]],
  304. },
  305. },
  306. {
  307. type: 'Feature',
  308. id: '1405',
  309. properties: { name: '晋城市', cp: [112.7856, 35.6342], childNum: 6 },
  310. geometry: {
  311. type: 'Polygon',
  312. coordinates: [
  313. '@@lV„Lšb„an‚LnKVašLVašL„UVaUm„aÆLnLlanKVaÆI„a°x²UlmVVœX˜wUKna„@Vn„J‚a„L„a@UV@@alUkKVKnkmmVwUk„w@ƒ™@kxWUXƒW@@mƒk@aUa@a¯aƒLkKmwkUm@kL@K@aWIXmƒVƒXƒWkUVakL@UVKƒw@aUK@UUKmLU@¯n™KUwVƒUIWJUWmka™@UXƒJƒk@UkmW@kLWKVƒx@bmI@VUaVU@a¯@UUmVKmX@±`kÝKVxUL±akL@V™bƒLkKmVƒ@XWVUbƒVXb@lm@@lW@@xk„lVUbnnmbUšlJ@„@L„@@V„b@‚WXš„UlkxVV@„šwn@ÜmnLlVkzƒ`UbmL@Vš@XL˜m„VnIÞ@VU°x@VnL˜x„V@LU°',
  314. ],
  315. encodeOffsets: [[115223, 36895]],
  316. },
  317. },
  318. {
  319. type: 'Feature',
  320. id: '1401',
  321. properties: { name: '太原市', cp: [112.3352, 37.9413], childNum: 5 },
  322. geometry: {
  323. type: 'Polygon',
  324. coordinates: [
  325. '@@„@VV@wVKnLVal@na°nšaVJœUlm„L°a@b„@lx@bULUlmx@Ln@lVkn„l˜@XI„w‚K„Vnƒ°aVXVx„ƒUaVU°K„nUlšUVL„KÆVš²Ģ‚lnXalLÈÆ˜L„KUaVkUanmWU™a@WwkUWU¯y¯Ñ@anIl@@aVU„m„I„ymUƒLUUVakaU@@LmJkw±LKmVUI@W¯™VaU_l™kbW@kK@mƒUkaVƒmVaU™ƒIVmalk™W@wnIVy@klkWUU›VI@ƒƒUƒVkam@knU@mmmK@bblVUX@VkLV`@n±KU„ULƒ‚UnVVńUbÇKmV—Imbm@k¼ó@Ul™b@VmV@bXmaƒK@›UUxkV‚V@„xW„UxVnkVVJ@XnJ@XlV²LƂVbnL@lš@°',
  326. ],
  327. encodeOffsets: [[114503, 39134]],
  328. },
  329. },
  330. {
  331. type: 'Feature',
  332. id: '1403',
  333. properties: { name: '阳泉市', cp: [113.4778, 38.0951], childNum: 3 },
  334. geometry: {
  335. type: 'Polygon',
  336. coordinates: [
  337. '@@°@nb„@lb@b„b„b‚@„x²al@lb„KXU@m‚kUWkkmUUƒVwV@XUW@™naVklKXblKnL‚ƒnLVanImaXKlL„ašV@U@KUKW„alƒXK@£WKXUV@VU„ƒUUVW„_V™@W@@K„@šƒUƒƒIWmXUmƒULƒn™JkImmÝaUbLƒK@UƒWk@mn™Uƒ@kVWb@Ubmx@lƒzUxƒ`U„ULml@„XWlƒ@UV@nk@U‚Vb@X™Jm™@@Vknƒyk@ƒzƒJƒnUV@bk@mJ@b°Ò°zXVlVXx‚@šbXVmnVbUlVb',
  338. ],
  339. encodeOffsets: [[115864, 39336]],
  340. },
  341. },
  342. ],
  343. UTF8Encoding: true,
  344. })
  345. var mapFeatures = echarts.getMap(this.mapName).geoJson.features
  346. mapFeatures.forEach(v => {
  347. // 地区名称
  348. var name = v.properties.name
  349. // 地区经纬度
  350. this.geoCoordMap[name] = v.properties.cp
  351. })
  352. // <p>当前阶段:<span>可论证阶段</span></p>
  353. // <p>时间节点:<span>2021.10-2022.10</span></p>
  354. let option = {
  355. tooltip: {
  356. padding: 15,
  357. enterable: true,
  358. transitionDuration: 1,
  359. formatter: (params, ticket, callback) => {
  360. // 清空所有轮播
  361. for (var k in this.geoCoordMap) {
  362. myChart.dispatchAction({
  363. // type: 'geoUnSelect',
  364. type: 'downplay',
  365. name: k,
  366. })
  367. }
  368. // // 如果鼠标滑动到线线上面,则返回空
  369. myChart.dispatchAction({
  370. // type: 'geoSelect',
  371. type: 'highlight',
  372. name: params.name,
  373. })
  374. if (params.componentSubType == 'lines') {
  375. return
  376. }
  377. let tipHtml = `
  378. <div class="tooltip-cont">
  379. <p>新开工:<span>工程建设项目</span></p>
  380. <p>总投资额:<span>${params.data.value}亿</span></p>
  381. </div>`
  382. callback(ticket, tipHtml)
  383. return tipHtml
  384. },
  385. },
  386. visualMap: {
  387. show: false,
  388. min: 0,
  389. max: 300,
  390. right: 0,
  391. bottom: 0,
  392. text: ['高', '低'],
  393. textStyle: {
  394. color: '#f1f1f1'
  395. },
  396. realtime: false,
  397. calculable: false,
  398. inRange: {
  399. color: ['lightskyblue', '#2754b7']
  400. }
  401. },
  402. geo: {
  403. show: true,
  404. map: 'shanxi',
  405. layoutCenter: ['50%', '50%'], //地图位置
  406. layoutSize: '100%',
  407. label: {
  408. normal: {
  409. show: false,
  410. },
  411. emphasis: {
  412. show: false,
  413. },
  414. },
  415. roam: false,
  416. itemStyle: {
  417. normal: {
  418. areaColor: '#1946a8',
  419. shadowColor: '#1946a8',
  420. borderWidth: 1, //设置外层边框
  421. borderColor: '#1946a8',
  422. shadowOffsetX: 10,
  423. shadowOffsetY: 5,
  424. shadowBlur: 2,
  425. },
  426. emphasis: {
  427. areaColor: '#1946a8',
  428. borderColor: '#d4bc1d',
  429. borderWidth: 2, //设置外层边框
  430. },
  431. },
  432. },
  433. series: [
  434. {
  435. name: '散点',
  436. type: 'scatter',
  437. coordinateSystem: 'geo',
  438. data: this.convertData(data),
  439. symbolSize: function (val) {
  440. return 10
  441. },
  442. label: {
  443. normal: {
  444. formatter: '{b}',
  445. position: [10, 10],
  446. fontSize: 15,
  447. fontWeight: 600,
  448. fontStyle: 'italic',
  449. color: '#fff',
  450. show: true,
  451. },
  452. emphasis: {
  453. show: true,
  454. },
  455. },
  456. itemStyle: {
  457. normal: {
  458. color: '#000',
  459. borderWidth: 2,
  460. borderColor: '#fff',
  461. },
  462. },
  463. },
  464. {
  465. type: 'map',
  466. map: this.mapName,
  467. geoIndex: 0,
  468. aspectScale: 1.5, //长宽比
  469. showLegendSymbol: true, // 存在legend时显示
  470. label: {
  471. normal: {
  472. show: true,
  473. },
  474. emphasis: {
  475. show: false,
  476. textStyle: {
  477. color: '#fff',
  478. },
  479. },
  480. },
  481. roam: true,
  482. itemStyle: {
  483. normal: {
  484. areaColor: '#031525',
  485. borderColor: '#3B5077',
  486. },
  487. emphasis: {
  488. areaColor: '#2B91B7',
  489. },
  490. },
  491. animation: false,
  492. data: data,
  493. },
  494. {
  495. name: '点',
  496. type: 'scatter',
  497. coordinateSystem: 'geo',
  498. zlevel: 6,
  499. },
  500. {
  501. name: 'Top 5',
  502. type: 'effectScatter',
  503. coordinateSystem: 'geo',
  504. data: this.convertData(
  505. data
  506. .sort(function (a, b) {
  507. return b.value - a.value
  508. })
  509. .slice(0, 5)
  510. ),
  511. symbolSize: function (val) {
  512. return 15
  513. },
  514. showEffectOn: 'render',
  515. rippleEffect: {
  516. brushType: 'stroke',
  517. },
  518. hoverAnimation: true,
  519. label: {
  520. normal: {
  521. formatter: '{b}',
  522. position: 'left',
  523. show: false,
  524. },
  525. },
  526. itemStyle: {
  527. normal: {
  528. color: 'yellow',
  529. shadowBlur: 10,
  530. shadowColor: 'yellow',
  531. },
  532. },
  533. zlevel: 1000,
  534. },
  535. {
  536. name: '线路',
  537. type: 'lines',
  538. zlevel: 2,
  539. effect: {
  540. show: true,
  541. period: 4, //箭头指向速度,值越小速度越快
  542. trailLength: 0.02, //特效尾迹长度[0,1]值越大,尾迹越长重
  543. symbol: 'arrow', //箭头图标
  544. symbolSize: 5, //图标大小
  545. },
  546. lineStyle: {
  547. normal: {
  548. color: '#00FFFF',
  549. width: 1,
  550. type: 'dashed',
  551. opacity: 0.5, //尾迹线条透明度
  552. curveness: -0.3, //尾迹线条曲直度
  553. },
  554. },
  555. data: moveLine.normal,
  556. },
  557. ],
  558. }
  559. let that = this
  560. myChart.on('click', function (params) {
  561. console.log(params)
  562. if (params.name == '太原市') {
  563. that.showTip = true
  564. }
  565. // window.open('https://www.baidu.com')
  566. })
  567. tools.loopShowTooltip(myChart, option, {
  568. interval: 2000,
  569. loopSeries: true,
  570. });
  571. myChart.setOption(option)
  572. },
  573. // initChartTip(){
  574. // let myChart = echarts.init(this.$refs['echartTip'])
  575. // let option = {
  576. // tooltip: {
  577. // trigger: 'item',
  578. // },
  579. // color: ['#6682f5', '#69c0ff', '#43ede3','#8ba2ff'],
  580. // legend: {
  581. // top: '0',
  582. // orient: 'vertical',
  583. // left: '2%',
  584. // textStyle: {
  585. // color: '#9DB9EB',
  586. // },
  587. // },
  588. // series: [
  589. // {
  590. // name: '',
  591. // type: 'pie',
  592. // center: ['45%','40%'],
  593. // radius: ['35%', '50%'],
  594. // labelLine: {
  595. // normal: {
  596. // lineStyle: {
  597. // width: 1,
  598. // },
  599. // },
  600. // },
  601. // data: statusList,
  602. // },
  603. // ],
  604. // }
  605. // myChart.setOption(option)
  606. // tools.loopShowTooltip(myChart, option, {
  607. // nterval: 2000,
  608. // loopSeries: true,
  609. // })
  610. // myChart.on('click', function(param) {
  611. // console.log(param)
  612. // window.open('https://www.baidu.com')
  613. // })
  614. // },
  615. initChartTip2 () {
  616. let myChart = echarts.init(this.$refs['echartTip2'])
  617. let option = {
  618. tooltip: {
  619. trigger: 'axis',
  620. axisPointer: {
  621. type: 'cross',
  622. },
  623. },
  624. // dataZoom:[
  625. // {
  626. // // start: 9,//默认为@
  627. // // end: 100,//黑认认为1@0
  628. // type: "slider",
  629. // show: true,
  630. // // xAxisIndex: [0]
  631. // handlesize: 0,//滑动条的 左右2个滑动条的大小
  632. // startValue: 9,// 初始显示值
  633. // endValue: 6,// 结束显示值
  634. // height: 10,//组件高度
  635. // left:"5%",
  636. // right: "4%",//右边的距离
  637. // bottom: "25%",//底边的距离
  638. // borderColor:"#939",
  639. // fillerColor:"#269cdb",
  640. // borderRadius: 5,
  641. // backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  642. // showDataShadow: false,//是否显示数据阴影
  643. // showDetail: false,//即拖拽时候是否显示详细数值信息
  644. // truerealtime: false,//是否实时更新
  645. // filterMode: "filter"
  646. // },{
  647. // type:'inside',
  648. // show: true,
  649. // start: 1,
  650. // end: 100
  651. // }
  652. // ],
  653. grid: {
  654. top: '10%',
  655. right: '3%',
  656. left: '10%',
  657. bottom: '30%',
  658. },
  659. legend: {
  660. top: '1',
  661. right: '20',
  662. textStyle: {
  663. color: 'rgba(250,250,250,0.6)',
  664. },
  665. },
  666. xAxis: {
  667. data: tipData.map(item => item.name),
  668. axisLine: {
  669. show: true, //隐藏X轴轴线
  670. lineStyle: {
  671. color: '#005094',
  672. width: 1,
  673. },
  674. },
  675. axisTick: {
  676. show: false, //隐藏X轴刻度
  677. },
  678. axisLabel: {
  679. show: true,
  680. rotate: 40,
  681. textStyle: {
  682. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  683. },
  684. },
  685. },
  686. yAxis: [
  687. {
  688. type: 'value',
  689. nameTextStyle: {
  690. color: '#ebf8ac',
  691. },
  692. splitLine: {
  693. show: true,
  694. lineStyle: {
  695. color: '#68b4dd66',
  696. type: 'dashed',
  697. },
  698. },
  699. axisLine: {
  700. show: true,
  701. lineStyle: {
  702. color: '#3D7495',
  703. },
  704. },
  705. axisLabel: {
  706. show: true,
  707. formatter: '{value} 亿',
  708. textStyle: {
  709. color: 'rgba(250,250,250,0.6)',
  710. },
  711. },
  712. },
  713. ],
  714. series: [
  715. {
  716. name: '投资金额',
  717. type: 'bar',
  718. barWidth: 15,
  719. itemStyle: {
  720. normal: {
  721. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  722. {
  723. offset: 0,
  724. color: '#69c0ff',
  725. },
  726. {
  727. offset: 1,
  728. color: '#082550',
  729. },
  730. ]),
  731. },
  732. },
  733. data: tipData.map(item => item.value),
  734. },
  735. // {
  736. // name: '实际投资',
  737. // type: 'bar',
  738. // barWidth: 10,
  739. // itemStyle: {
  740. // normal: {
  741. // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  742. // {
  743. // offset: 0,
  744. // color: '#957DFF',
  745. // },
  746. // {
  747. // offset: 1,
  748. // color: '#082550',
  749. // },
  750. // ]),
  751. // },
  752. // },
  753. // data: executeList.map(item=>item.value2),
  754. // },
  755. ],
  756. }
  757. myChart.on('click', function (data) {
  758. if (data.name == '交控集团') {
  759. window.location.href = './investHomeChild.html?type=1'
  760. }
  761. })
  762. tools.loopShowTooltip(myChart, option, {
  763. nterval: 2000,
  764. loopSeries: true,
  765. })
  766. myChart.setOption(option)
  767. },
  768. initChartTip3 () {
  769. let myChart = echarts.init(this.$refs['echartTip3'])
  770. let option = {
  771. title: {
  772. //text : '产业类别',
  773. x: 'center',
  774. textStyle: {
  775. color: '#fff'
  776. }
  777. },
  778. tooltip: {
  779. trigger: 'axis',
  780. axisPointer: {
  781. type: 'cross',
  782. },
  783. },
  784. grid: {
  785. top: '15%',
  786. right: '3%',
  787. left: '10%',
  788. bottom: '30%',
  789. },
  790. legend: {
  791. top: '1',
  792. right: '15',
  793. textStyle: {
  794. color: 'rgba(250,250,250,0.6)',
  795. },
  796. },
  797. xAxis: {
  798. data: tipTopData.map(item => item.name),
  799. axisLine: {
  800. show: true, //隐藏X轴轴线
  801. lineStyle: {
  802. color: '#005094',
  803. width: 1,
  804. },
  805. },
  806. axisTick: {
  807. show: false, //隐藏X轴刻度
  808. },
  809. axisLabel: {
  810. show: true,
  811. rotate: 30,
  812. textStyle: {
  813. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  814. },
  815. },
  816. },
  817. yAxis: [
  818. {
  819. type: 'value',
  820. nameTextStyle: {
  821. color: '#ebf8ac',
  822. },
  823. splitLine: {
  824. show: true,
  825. lineStyle: {
  826. color: '#68b4dd66',
  827. type: 'dashed',
  828. },
  829. },
  830. axisLine: {
  831. show: true,
  832. lineStyle: {
  833. color: '#3D7495',
  834. },
  835. },
  836. axisLabel: {
  837. show: true,
  838. formatter: '{value} 亿',
  839. textStyle: {
  840. color: 'rgba(250,250,250,0.6)',
  841. },
  842. },
  843. },
  844. ],
  845. series: [
  846. {
  847. name: '2022年投资完成额',
  848. type: 'bar',
  849. barWidth: 15,
  850. itemStyle: {
  851. normal: {
  852. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  853. {
  854. offset: 0,
  855. color: '#69c0ff',
  856. },
  857. {
  858. offset: 1,
  859. color: '#082550',
  860. },
  861. ]),
  862. },
  863. },
  864. data: tipTopData.map(item => item.value),
  865. },
  866. // {
  867. // name: '实际投资',
  868. // type: 'bar',
  869. // barWidth: 10,
  870. // itemStyle: {
  871. // normal: {
  872. // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  873. // {
  874. // offset: 0,
  875. // color: '#957DFF',
  876. // },
  877. // {
  878. // offset: 1,
  879. // color: '#082550',
  880. // },
  881. // ]),
  882. // },
  883. // },
  884. // data: executeList.map(item=>item.value2),
  885. // },
  886. ],
  887. }
  888. myChart.setOption(option)
  889. tools.loopShowTooltip(myChart, option, {
  890. nterval: 2000,
  891. loopSeries: true,
  892. })
  893. },
  894. initChartTip4 () {
  895. let myChart = echarts.init(this.$refs['echartTip4'])
  896. let option = {
  897. title: {
  898. //text : '投资项目列表',
  899. x: 'center',
  900. textStyle: {
  901. color: '#fff'
  902. }
  903. },
  904. tooltip: {
  905. trigger: 'axis',
  906. axisPointer: {
  907. type: 'cross',
  908. },
  909. },
  910. // dataZoom:[
  911. // {
  912. // // start: 9,//默认为@
  913. // // end: 100,//黑认认为1@0
  914. // type: "slider",
  915. // show: true,
  916. // // xAxisIndex: [0]
  917. // handlesize: 0,//滑动条的 左右2个滑动条的大小
  918. // startValue: 9,// 初始显示值
  919. // endValue: 6,// 结束显示值
  920. // height: 10,//组件高度
  921. // left:"5%",
  922. // right: "4%",//右边的距离
  923. // bottom: "25%",//底边的距离
  924. // borderColor:"#939",
  925. // fillerColor:"#269cdb",
  926. // borderRadius: 5,
  927. // backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  928. // showDataShadow: false,//是否显示数据阴影
  929. // showDetail: false,//即拖拽时候是否显示详细数值信息
  930. // truerealtime: false,//是否实时更新
  931. // filterMode: "filter"
  932. // },{
  933. // type:'inside',
  934. // show: true,
  935. // start: 1,
  936. // end: 100
  937. // }
  938. // ],
  939. grid: {
  940. top: '15%',
  941. right: '3%',
  942. left: '10%',
  943. bottom: '20%',
  944. },
  945. legend: {
  946. top: '0',
  947. right: '20',
  948. textStyle: {
  949. color: 'rgba(250,250,250,0.6)',
  950. },
  951. },
  952. xAxis: {
  953. data: tipBottomData.map(item => item.name),
  954. axisLine: {
  955. show: true, //隐藏X轴轴线
  956. lineStyle: {
  957. color: '#005094',
  958. width: 1,
  959. },
  960. },
  961. axisTick: {
  962. show: false, //隐藏X轴刻度
  963. },
  964. axisLabel: {
  965. show: true,
  966. rotate: 30,
  967. textStyle: {
  968. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  969. },
  970. },
  971. },
  972. yAxis: [
  973. {
  974. type: 'value',
  975. nameTextStyle: {
  976. color: '#ebf8ac',
  977. },
  978. splitLine: {
  979. show: true,
  980. lineStyle: {
  981. color: '#68b4dd66',
  982. type: 'dashed',
  983. },
  984. },
  985. axisLine: {
  986. show: true,
  987. lineStyle: {
  988. color: '#3D7495',
  989. },
  990. },
  991. axisLabel: {
  992. show: true,
  993. formatter: '{value} 亿',
  994. textStyle: {
  995. color: 'rgba(250,250,250,0.6)',
  996. },
  997. },
  998. },
  999. ],
  1000. series: [
  1001. {
  1002. name: '2022年投资完成额',
  1003. type: 'bar',
  1004. barWidth: 15,
  1005. itemStyle: {
  1006. normal: {
  1007. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1008. {
  1009. offset: 0,
  1010. color: '#69c0ff',
  1011. },
  1012. {
  1013. offset: 1,
  1014. color: '#082550',
  1015. },
  1016. ]),
  1017. },
  1018. },
  1019. data: tipBottomData.map(item => item.value),
  1020. },
  1021. ],
  1022. }
  1023. myChart.on('click', function (data) {
  1024. if (data.name == '华阳新材') {
  1025. window.location.href = './investHomeChild.html?type=2'
  1026. }
  1027. })
  1028. myChart.setOption(option)
  1029. tools.loopShowTooltip(myChart, option, {
  1030. nterval: 2000,
  1031. loopSeries: true,
  1032. })
  1033. },
  1034. initChartL1 () {
  1035. let myChart = echarts.init(this.$refs['echartL1'])
  1036. let option = {
  1037. tooltip: {
  1038. trigger: 'item',
  1039. },
  1040. color: ['#6682f5', '#69c0ff', '#43ede3', '#8ba2ff'],
  1041. legend: {
  1042. top: 'center',
  1043. orient: 'vertical',
  1044. right: '2%',
  1045. textStyle: {
  1046. color: '#9DB9EB',
  1047. },
  1048. },
  1049. series: [
  1050. {
  1051. name: '',
  1052. type: 'pie',
  1053. radius: ['55%', '80%'],
  1054. labelLine: {
  1055. normal: {
  1056. lineStyle: {
  1057. width: 1,
  1058. },
  1059. },
  1060. },
  1061. data: statusList,
  1062. },
  1063. ],
  1064. }
  1065. myChart.setOption(option)
  1066. tools.loopShowTooltip(myChart, option, {
  1067. nterval: 2000,
  1068. loopSeries: true,
  1069. })
  1070. },
  1071. initChartL2 () {
  1072. let myChart = echarts.init(this.$refs['echartL2'])
  1073. let option = {
  1074. tooltip: {
  1075. trigger: 'axis',
  1076. axisPointer: {
  1077. type: 'cross',
  1078. },
  1079. },
  1080. grid: {
  1081. top: '16%',
  1082. right: '3%',
  1083. left: '10%',
  1084. bottom: '23%',
  1085. },
  1086. legend: {
  1087. top: '1',
  1088. right: '10',
  1089. textStyle: {
  1090. color: 'rgba(250,250,250,0.6)',
  1091. },
  1092. },
  1093. xAxis: {
  1094. data: executeList.map(item => item.name),
  1095. axisLine: {
  1096. show: true, //隐藏X轴轴线
  1097. lineStyle: {
  1098. color: '#005094',
  1099. width: 1,
  1100. },
  1101. },
  1102. axisTick: {
  1103. show: false, //隐藏X轴刻度
  1104. },
  1105. axisLabel: {
  1106. show: true,
  1107. rotate: 40,
  1108. textStyle: {
  1109. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  1110. },
  1111. },
  1112. },
  1113. yAxis: [
  1114. {
  1115. type: 'value',
  1116. nameTextStyle: {
  1117. color: '#ebf8ac',
  1118. },
  1119. splitLine: {
  1120. show: true,
  1121. lineStyle: {
  1122. color: '#68b4dd66',
  1123. type: 'dashed',
  1124. },
  1125. },
  1126. axisLine: {
  1127. show: true,
  1128. lineStyle: {
  1129. color: '#3D7495',
  1130. },
  1131. },
  1132. axisLabel: {
  1133. show: true,
  1134. textStyle: {
  1135. color: 'rgba(250,250,250,0.6)',
  1136. },
  1137. },
  1138. },
  1139. ],
  1140. series: [
  1141. {
  1142. name: '计划投资',
  1143. type: 'bar',
  1144. barWidth: 10,
  1145. itemStyle: {
  1146. normal: {
  1147. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1148. {
  1149. offset: 0,
  1150. color: '#69c0ff',
  1151. },
  1152. {
  1153. offset: 1,
  1154. color: '#082550',
  1155. },
  1156. ]),
  1157. },
  1158. },
  1159. data: executeList.map(item => item.value),
  1160. },
  1161. {
  1162. name: '实际投资',
  1163. type: 'bar',
  1164. barWidth: 10,
  1165. itemStyle: {
  1166. normal: {
  1167. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1168. {
  1169. offset: 0,
  1170. color: '#957DFF',
  1171. },
  1172. {
  1173. offset: 1,
  1174. color: '#082550',
  1175. },
  1176. ]),
  1177. },
  1178. },
  1179. data: executeList.map(item => item.value2),
  1180. },
  1181. ],
  1182. }
  1183. myChart.setOption(option)
  1184. tools.loopShowTooltip(myChart, option, {
  1185. nterval: 2000,
  1186. loopSeries: true,
  1187. })
  1188. },
  1189. initChartR1 () {
  1190. let myChart = echarts.init(this.$refs['echartR1'])
  1191. let option = {
  1192. tooltip: {
  1193. trigger: 'axis',
  1194. formatter: '{a0}:{c0}' + '亿元' + '<br/>' + '{a1}:{c1}' + '%',
  1195. axisPointer: {
  1196. type: 'cross',
  1197. },
  1198. },
  1199. grid: {
  1200. top: '16%',
  1201. right: '10%',
  1202. left: '10%',
  1203. bottom: '10%',
  1204. },
  1205. legend: {
  1206. top: '1',
  1207. textStyle: {
  1208. color: 'rgba(250,250,250,0.6)',
  1209. },
  1210. },
  1211. xAxis: {
  1212. data: industryList.map(item => item.name),
  1213. axisLine: {
  1214. show: true, //隐藏X轴轴线
  1215. lineStyle: {
  1216. color: '#005094',
  1217. width: 1,
  1218. },
  1219. },
  1220. axisTick: {
  1221. show: false, //隐藏X轴刻度
  1222. },
  1223. axisLabel: {
  1224. show: true,
  1225. // rotate: 20,
  1226. textStyle: {
  1227. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  1228. },
  1229. },
  1230. },
  1231. yAxis: [
  1232. {
  1233. type: 'value',
  1234. name: '亿元',
  1235. nameTextStyle: {
  1236. color: 'rgba(255,255,255,0.6)',
  1237. },
  1238. splitLine: {
  1239. show: true,
  1240. lineStyle: {
  1241. color: '#68b4dd66',
  1242. type: 'dashed',
  1243. },
  1244. },
  1245. axisLine: {
  1246. show: true,
  1247. lineStyle: {
  1248. color: '#3D7495',
  1249. },
  1250. },
  1251. axisLabel: {
  1252. show: true,
  1253. textStyle: {
  1254. color: 'rgba(250,250,250,0.6)',
  1255. },
  1256. },
  1257. },
  1258. {
  1259. type: 'value',
  1260. axisLine: {
  1261. show: false,
  1262. },
  1263. splitLine: {
  1264. show: false,
  1265. },
  1266. axisLabel: {
  1267. show: true,
  1268. formatter: '{value} %',
  1269. textStyle: {
  1270. color: 'rgba(250,250,250,0.6)',
  1271. },
  1272. },
  1273. },
  1274. ],
  1275. series: [
  1276. {
  1277. type: 'bar',
  1278. name: '投资金额',
  1279. barWidth: 15,
  1280. itemStyle: {
  1281. normal: {
  1282. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1283. {
  1284. offset: 0,
  1285. color: '#69c0ff',
  1286. },
  1287. {
  1288. offset: 1,
  1289. color: '#082550',
  1290. },
  1291. ]),
  1292. },
  1293. },
  1294. data: industryList.map(item => item.value),
  1295. },
  1296. {
  1297. type: 'line',
  1298. name: '投资占比',
  1299. type: 'line',
  1300. yAxisIndex: 1,
  1301. smooth: true, //平滑曲线显示
  1302. showAllSymbol: true, //显示所有图形。
  1303. symbol: 'circle', //标记的图形为实心圆
  1304. symbolSize: 4, //标记的大小
  1305. smooth: false,
  1306. itemStyle: {
  1307. //折线拐点标志的样式
  1308. color: '#fbe138',
  1309. borderColor: '#fbe138',
  1310. width: 1,
  1311. shadowColor: '#fbe138',
  1312. shadowBlur: 2,
  1313. },
  1314. lineStyle: {
  1315. color: '#fbe138',
  1316. width: 1,
  1317. },
  1318. data: industryList.map(item => item.value2),
  1319. },
  1320. ],
  1321. }
  1322. myChart.setOption(option)
  1323. tools.loopShowTooltip(myChart, option, {
  1324. nterval: 2000,
  1325. loopSeries: true,
  1326. })
  1327. let that = this
  1328. myChart.on('click', function (param) {
  1329. console.log(param)
  1330. if (param.name == '战略新兴产业投资') {
  1331. that.tipTitle2 = param.name
  1332. that.showTip2 = true
  1333. }
  1334. })
  1335. },
  1336. initProjectList () {
  1337. let dataList = []
  1338. projectList.map(item => {
  1339. dataList.push([item.name, item.value + '亿', item.status])
  1340. })
  1341. this.storageRecordConfig = {
  1342. header: ['项目名称', '投资金额', '项目进度'],
  1343. headerBGC: '#05507b33',
  1344. oddRowBGC: '#05507b33',
  1345. evenRowBGC: '',
  1346. headerHeight: '40',
  1347. rowNum: 5,
  1348. columnWidth: [350, 100],
  1349. align: ['center', 'center', 'center'],
  1350. data: dataList,
  1351. }
  1352. }
  1353. },
  1354. })