investHome.js 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849
  1. let app = new Vue({
  2. el: '#app',
  3. data () {
  4. return {
  5. year: '2022',
  6. time: '',
  7. timer: '',
  8. mapName: 'shanxi',
  9. geoCoordMap: {},
  10. config1: {
  11. number: [100],
  12. content: '{nt}个',
  13. },
  14. storageRecordConfig: null,
  15. companyList: [
  16. { name: '山西焦煤' },
  17. { name: '晋能控股' },
  18. { name: '华新燃气' },
  19. { name: '山西建投' },
  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. ],
  35. amountList: amountList,
  36. amountTotal: 0,
  37. classOption: {
  38. step: 0.5
  39. }
  40. }
  41. },
  42. created () {
  43. this.amountList.map(item=> {
  44. this.amountTotal += Number(item.value)
  45. })
  46. this.time = formatDate()
  47. this.timer = setInterval(() => {
  48. this.time = formatDate()
  49. }, 1000)
  50. },
  51. beforeDestroy () {
  52. if (this.timer) {
  53. clearInterval(this.timer);
  54. }
  55. },
  56. mounted () {
  57. setTimeout(() => {
  58. // 左侧图表
  59. this.initChartL1()
  60. this.initChartL2()
  61. this.initChartR1()
  62. this.initChinaChart()
  63. this.initProjectList()
  64. },0)
  65. },
  66. methods: {
  67. numFormat (value) {
  68. if (!value) return '0'
  69. var intPart = Number(value).toFixed(0) // 获取整数部分
  70. var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
  71. var floatPart = '.00' // 预定义小数部分
  72. var value2Array = value.toString().split('.')
  73. // =2表示数据有小数位
  74. if (value2Array.length === 2) {
  75. floatPart = value2Array[1].toString() // 拿到小数部分
  76. if (floatPart.length === 1) {
  77. // 补0
  78. return intPartFormat + '.' + floatPart + '0'
  79. } else {
  80. return intPartFormat + '.' + floatPart
  81. }
  82. } else {
  83. return intPartFormat
  84. }
  85. },
  86. convertData (data) {
  87. var res = []
  88. for (var i = 0; i < data.length; i++) {
  89. var geoCoord = this.geoCoordMap[data[i].name]
  90. if (geoCoord) {
  91. res.push({
  92. name: data[i].name,
  93. value: geoCoord.concat(data[i].value),
  94. })
  95. }
  96. }
  97. return res
  98. },
  99. initChinaChart () {
  100. var data = [
  101. { name: '吕梁市', value: 150 },
  102. { name: '大同市', value: 190 },
  103. { name: '忻州市', value: 140 },
  104. { name: '朔州市', value: 160 },
  105. { name: '晋中市', value: 100 },
  106. { name: '太原市', value: 300 },
  107. { name: '临汾市', value: 190 },
  108. { name: '长治市', value: 100 },
  109. { name: '晋城市', value: 280 },
  110. { name: '运城市', value: 180 },
  111. { name: '阳泉市', value: 110 },
  112. ]
  113. var moveLine = {
  114. normal: [
  115. {
  116. fromName: '太原市',
  117. toName: '吕梁市',
  118. coords: [
  119. [112.3352, 37.9413],
  120. [111.3574, 37.7325],
  121. ],
  122. },
  123. {
  124. fromName: '太原市',
  125. toName: '忻州市',
  126. coords: [
  127. [112.3352, 37.9413],
  128. [112.4561, 38.8971],
  129. ],
  130. },
  131. {
  132. fromName: '太原市',
  133. toName: '临汾市',
  134. coords: [
  135. [112.3352, 37.9413],
  136. [111.4783, 36.1615],
  137. ],
  138. },
  139. {
  140. fromName: '太原市',
  141. toName: '阳泉市',
  142. coords: [
  143. [112.3352, 37.9413],
  144. [113.4778, 38.0951],
  145. ],
  146. },
  147. {
  148. fromName: '太原市',
  149. toName: '晋中市',
  150. coords: [
  151. [112.3352, 37.9413],
  152. [112.7747, 37.37],
  153. ],
  154. },
  155. {
  156. fromName: '太原市',
  157. toName: '运城市',
  158. coords: [
  159. [112.3352, 37.9413],
  160. [111.1487, 35.2002],
  161. ],
  162. },
  163. {
  164. fromName: '太原市',
  165. toName: '大同市',
  166. coords: [
  167. [112.3352, 37.9413],
  168. [113.7854, 39.8035],
  169. ],
  170. },
  171. {
  172. fromName: '太原市',
  173. toName: '晋城市',
  174. coords: [
  175. [112.3352, 37.9413],
  176. [112.7856, 35.6342],
  177. ],
  178. },
  179. {
  180. fromName: '太原市',
  181. toName: '长治市',
  182. coords: [
  183. [112.3352, 37.9413],
  184. [112.8625, 36.4746],
  185. ],
  186. },
  187. {
  188. fromName: '太原市',
  189. toName: '朔州市',
  190. coords: [
  191. [112.3352, 37.9413],
  192. [113.0713, 39.6991],
  193. ],
  194. },
  195. ],
  196. }
  197. /*获取地图数据*/
  198. let myChart = echarts.init(this.$refs['echarts-map'])
  199. echarts.registerMap('shanxi', {
  200. type: 'FeatureCollection',
  201. features: [
  202. {
  203. type: 'Feature',
  204. id: '1409',
  205. properties: { name: '忻州市', cp: [112.4561, 38.8971], childNum: 14 },
  206. geometry: {
  207. type: 'Polygon',
  208. coordinates: [
  209. '@@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',
  210. ],
  211. encodeOffsets: [[113614, 39657]],
  212. },
  213. },
  214. {
  215. type: 'Feature',
  216. id: '1411',
  217. properties: { name: '吕梁市', cp: [111.3574, 37.7325], childNum: 13 },
  218. geometry: {
  219. type: 'Polygon',
  220. coordinates: [
  221. '@@@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',
  222. ],
  223. encodeOffsets: [[113614, 39657]],
  224. },
  225. },
  226. {
  227. type: 'Feature',
  228. id: '1410',
  229. properties: { name: '临汾市', cp: [111.4783, 36.1615], childNum: 17 },
  230. geometry: {
  231. type: 'Polygon',
  232. coordinates: [
  233. '@@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',
  234. ],
  235. encodeOffsets: [[113063, 37784]],
  236. },
  237. },
  238. {
  239. type: 'Feature',
  240. id: '1407',
  241. properties: { name: '晋中市', cp: [112.7747, 37.37], childNum: 11 },
  242. geometry: {
  243. type: 'Polygon',
  244. coordinates: [
  245. '@@@š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@',
  246. ],
  247. encodeOffsets: [[114087, 37682]],
  248. },
  249. },
  250. {
  251. type: 'Feature',
  252. id: '1408',
  253. properties: { name: '运城市', cp: [111.1487, 35.2002], childNum: 13 },
  254. geometry: {
  255. type: 'Polygon',
  256. coordinates: [
  257. '@@„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@„',
  258. ],
  259. encodeOffsets: [[113232, 36597]],
  260. },
  261. },
  262. {
  263. type: 'Feature',
  264. id: '1402',
  265. properties: { name: '大同市', cp: [113.7854, 39.8035], childNum: 8 },
  266. geometry: {
  267. type: 'Polygon',
  268. coordinates: [
  269. '@@²£š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',
  270. ],
  271. encodeOffsets: [[115335, 41209]],
  272. },
  273. },
  274. {
  275. type: 'Feature',
  276. id: '1404',
  277. properties: { name: '长治市', cp: [112.8625, 36.4746], childNum: 12 },
  278. geometry: {
  279. type: 'Polygon',
  280. coordinates: [
  281. '@@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',
  282. ],
  283. encodeOffsets: [[116269, 37637]],
  284. },
  285. },
  286. {
  287. type: 'Feature',
  288. id: '1406',
  289. properties: { name: '朔州市', cp: [113.0713, 39.6991], childNum: 5 },
  290. geometry: {
  291. type: 'Polygon',
  292. coordinates: [
  293. '@@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‚',
  294. ],
  295. encodeOffsets: [[114615, 40562]],
  296. },
  297. },
  298. {
  299. type: 'Feature',
  300. id: '1405',
  301. properties: { name: '晋城市', cp: [112.7856, 35.6342], childNum: 6 },
  302. geometry: {
  303. type: 'Polygon',
  304. coordinates: [
  305. '@@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°',
  306. ],
  307. encodeOffsets: [[115223, 36895]],
  308. },
  309. },
  310. {
  311. type: 'Feature',
  312. id: '1401',
  313. properties: { name: '太原市', cp: [112.3352, 37.9413], childNum: 5 },
  314. geometry: {
  315. type: 'Polygon',
  316. coordinates: [
  317. '@@„@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š@°',
  318. ],
  319. encodeOffsets: [[114503, 39134]],
  320. },
  321. },
  322. {
  323. type: 'Feature',
  324. id: '1403',
  325. properties: { name: '阳泉市', cp: [113.4778, 38.0951], childNum: 3 },
  326. geometry: {
  327. type: 'Polygon',
  328. coordinates: [
  329. '@@°@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',
  330. ],
  331. encodeOffsets: [[115864, 39336]],
  332. },
  333. },
  334. ],
  335. UTF8Encoding: true,
  336. })
  337. var mapFeatures = echarts.getMap(this.mapName).geoJson.features
  338. mapFeatures.forEach(v => {
  339. // 地区名称
  340. var name = v.properties.name
  341. // 地区经纬度
  342. this.geoCoordMap[name] = v.properties.cp
  343. })
  344. // <p>当前阶段:<span>可论证阶段</span></p>
  345. // <p>时间节点:<span>2021.10-2022.10</span></p>
  346. let option = {
  347. tooltip: {
  348. padding: 15,
  349. enterable: true,
  350. transitionDuration: 1,
  351. formatter: (params, ticket, callback) => {
  352. let tipHtml = `
  353. <div class="tooltip-cont">
  354. <p>新开工:<span>工程建设项目</span></p>
  355. <p>总投资额:<span>${params.data.value}亿</span></p>
  356. </div>`
  357. callback(ticket, tipHtml)
  358. return tipHtml
  359. },
  360. },
  361. visualMap: {
  362. show: false,
  363. min: 0,
  364. max: 300,
  365. right: 0,
  366. bottom: 0,
  367. text: ['高', '低'],
  368. textStyle: {
  369. color: '#f1f1f1'
  370. },
  371. realtime: false,
  372. calculable: false,
  373. inRange: {
  374. color: ['lightskyblue', '#2754b7']
  375. }
  376. },
  377. geo: {
  378. show: true,
  379. map: 'shanxi',
  380. layoutCenter: ['50%', '50%'], //地图位置
  381. layoutSize: '100%',
  382. label: {
  383. normal: {
  384. show: false,
  385. },
  386. emphasis: {
  387. show: false,
  388. },
  389. },
  390. roam: false,
  391. itemStyle: {
  392. normal: {
  393. areaColor: '#1946a8',
  394. shadowColor: '#1946a8',
  395. borderWidth: 1, //设置外层边框
  396. borderColor: '#1946a8',
  397. shadowOffsetX: 10,
  398. shadowOffsetY: 5,
  399. shadowBlur: 2,
  400. },
  401. emphasis: {
  402. areaColor: '#1946a8',
  403. borderColor: '#d4bc1d',
  404. borderWidth: 2, //设置外层边框
  405. },
  406. },
  407. },
  408. series: [
  409. {
  410. name: '散点',
  411. type: 'scatter',
  412. coordinateSystem: 'geo',
  413. data: this.convertData(data),
  414. symbolSize: function (val) {
  415. return 10
  416. },
  417. label: {
  418. normal: {
  419. formatter: '{b}',
  420. position: [10, 10],
  421. fontSize: 15,
  422. fontWeight: 600,
  423. fontStyle: 'italic',
  424. color: '#fff',
  425. show: true,
  426. },
  427. emphasis: {
  428. show: true,
  429. },
  430. },
  431. itemStyle: {
  432. normal: {
  433. color: '#000',
  434. borderWidth: 2,
  435. borderColor: '#fff',
  436. },
  437. },
  438. },
  439. {
  440. type: 'map',
  441. map: this.mapName,
  442. geoIndex: 0,
  443. aspectScale: 1.5, //长宽比
  444. showLegendSymbol: true, // 存在legend时显示
  445. label: {
  446. normal: {
  447. show: true,
  448. },
  449. emphasis: {
  450. show: false,
  451. textStyle: {
  452. color: '#fff',
  453. },
  454. },
  455. },
  456. roam: true,
  457. itemStyle: {
  458. normal: {
  459. areaColor: '#031525',
  460. borderColor: '#3B5077',
  461. },
  462. emphasis: {
  463. areaColor: '#2B91B7',
  464. },
  465. },
  466. animation: false,
  467. data: data,
  468. },
  469. {
  470. name: '点',
  471. type: 'scatter',
  472. coordinateSystem: 'geo',
  473. zlevel: 6,
  474. },
  475. {
  476. name: 'Top 5',
  477. type: 'effectScatter',
  478. coordinateSystem: 'geo',
  479. data: this.convertData(
  480. data
  481. .sort(function (a, b) {
  482. return b.value - a.value
  483. })
  484. .slice(0, 5)
  485. ),
  486. symbolSize: function (val) {
  487. return 15
  488. },
  489. showEffectOn: 'render',
  490. rippleEffect: {
  491. brushType: 'stroke',
  492. },
  493. hoverAnimation: true,
  494. label: {
  495. normal: {
  496. formatter: '{b}',
  497. position: 'left',
  498. show: false,
  499. },
  500. },
  501. itemStyle: {
  502. normal: {
  503. color: 'yellow',
  504. shadowBlur: 10,
  505. shadowColor: 'yellow',
  506. },
  507. },
  508. zlevel: 1000,
  509. },
  510. {
  511. name: '线路',
  512. type: 'lines',
  513. zlevel: 2,
  514. effect: {
  515. show: true,
  516. period: 4, //箭头指向速度,值越小速度越快
  517. trailLength: 0.02, //特效尾迹长度[0,1]值越大,尾迹越长重
  518. symbol: 'arrow', //箭头图标
  519. symbolSize: 5, //图标大小
  520. },
  521. lineStyle: {
  522. normal: {
  523. color: '#00FFFF',
  524. width: 1,
  525. type: 'dashed',
  526. opacity: 0.5, //尾迹线条透明度
  527. curveness: -0.3, //尾迹线条曲直度
  528. },
  529. },
  530. data: moveLine.normal,
  531. },
  532. ],
  533. }
  534. myChart.setOption(option)
  535. },
  536. initChartL1 () {
  537. let myChart = echarts.init(this.$refs['echartL1'])
  538. let option = {
  539. tooltip: {
  540. trigger: 'item',
  541. },
  542. color: ['#6682f5', '#69c0ff', '#43ede3','#8ba2ff'],
  543. legend: {
  544. top: 'center',
  545. orient: 'vertical',
  546. right: '2%',
  547. textStyle: {
  548. color: '#9DB9EB',
  549. },
  550. },
  551. series: [
  552. {
  553. name: '',
  554. type: 'pie',
  555. radius: ['55%', '80%'],
  556. labelLine: {
  557. normal: {
  558. lineStyle: {
  559. width: 1,
  560. },
  561. },
  562. },
  563. data: statusList,
  564. },
  565. ],
  566. }
  567. myChart.setOption(option)
  568. tools.loopShowTooltip(myChart, option, {
  569. nterval: 2000,
  570. loopSeries: true,
  571. })
  572. },
  573. initChartL2 () {
  574. let myChart = echarts.init(this.$refs['echartL2'])
  575. let option = {
  576. tooltip: {
  577. trigger: 'axis',
  578. axisPointer: {
  579. type: 'cross',
  580. },
  581. },
  582. grid: {
  583. top: '16%',
  584. right: '3%',
  585. left: '10%',
  586. bottom: '23%',
  587. },
  588. legend: {
  589. top: '1',
  590. right: '10',
  591. textStyle: {
  592. color: 'rgba(250,250,250,0.6)',
  593. },
  594. },
  595. xAxis: {
  596. data: executeList.map(item=>item.name),
  597. axisLine: {
  598. show: true, //隐藏X轴轴线
  599. lineStyle: {
  600. color: '#005094',
  601. width: 1,
  602. },
  603. },
  604. axisTick: {
  605. show: false, //隐藏X轴刻度
  606. },
  607. axisLabel: {
  608. show: true,
  609. rotate: 40,
  610. textStyle: {
  611. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  612. },
  613. },
  614. },
  615. yAxis: [
  616. {
  617. type: 'value',
  618. nameTextStyle: {
  619. color: '#ebf8ac',
  620. },
  621. splitLine: {
  622. show: true,
  623. lineStyle: {
  624. color: '#68b4dd66',
  625. type: 'dashed',
  626. },
  627. },
  628. axisLine: {
  629. show: true,
  630. lineStyle: {
  631. color: '#3D7495',
  632. },
  633. },
  634. axisLabel: {
  635. show: true,
  636. textStyle: {
  637. color: 'rgba(250,250,250,0.6)',
  638. },
  639. },
  640. },
  641. ],
  642. series: [
  643. {
  644. name: '计划投资',
  645. type: 'bar',
  646. barWidth: 10,
  647. itemStyle: {
  648. normal: {
  649. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  650. {
  651. offset: 0,
  652. color: '#69c0ff',
  653. },
  654. {
  655. offset: 1,
  656. color: '#082550',
  657. },
  658. ]),
  659. },
  660. },
  661. data: executeList.map(item=>item.value),
  662. },
  663. {
  664. name: '实际投资',
  665. type: 'bar',
  666. barWidth: 10,
  667. itemStyle: {
  668. normal: {
  669. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  670. {
  671. offset: 0,
  672. color: '#957DFF',
  673. },
  674. {
  675. offset: 1,
  676. color: '#082550',
  677. },
  678. ]),
  679. },
  680. },
  681. data: executeList.map(item=>item.value2),
  682. },
  683. ],
  684. }
  685. myChart.setOption(option)
  686. tools.loopShowTooltip(myChart, option, {
  687. nterval: 2000,
  688. loopSeries: true,
  689. })
  690. },
  691. initChartR1 () {
  692. let myChart = echarts.init(this.$refs['echartR1'])
  693. let option = {
  694. tooltip: {
  695. trigger: 'axis',
  696. formatter: '{a0}:{c0}' + '亿元' + '<br/>' + '{a1}:{c1}' + '%',
  697. axisPointer: {
  698. type: 'cross',
  699. },
  700. },
  701. grid: {
  702. top: '16%',
  703. right: '10%',
  704. left: '10%',
  705. bottom: '10%',
  706. },
  707. legend: {
  708. top: '1',
  709. textStyle: {
  710. color: 'rgba(250,250,250,0.6)',
  711. },
  712. },
  713. xAxis: {
  714. data: industryList.map(item=> item.name),
  715. axisLine: {
  716. show: true, //隐藏X轴轴线
  717. lineStyle: {
  718. color: '#005094',
  719. width: 1,
  720. },
  721. },
  722. axisTick: {
  723. show: false, //隐藏X轴刻度
  724. },
  725. axisLabel: {
  726. show: true,
  727. // rotate: 20,
  728. textStyle: {
  729. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  730. },
  731. },
  732. },
  733. yAxis: [
  734. {
  735. type: 'value',
  736. name: '亿元',
  737. nameTextStyle: {
  738. color: 'rgba(255,255,255,0.6)',
  739. },
  740. splitLine: {
  741. show: true,
  742. lineStyle: {
  743. color: '#68b4dd66',
  744. type: 'dashed',
  745. },
  746. },
  747. axisLine: {
  748. show: true,
  749. lineStyle: {
  750. color: '#3D7495',
  751. },
  752. },
  753. axisLabel: {
  754. show: true,
  755. textStyle: {
  756. color: 'rgba(250,250,250,0.6)',
  757. },
  758. },
  759. },
  760. {
  761. type: 'value',
  762. axisLine: {
  763. show: false,
  764. },
  765. splitLine: {
  766. show: false,
  767. },
  768. axisLabel: {
  769. show: true,
  770. formatter: '{value} %',
  771. textStyle: {
  772. color: 'rgba(250,250,250,0.6)',
  773. },
  774. },
  775. },
  776. ],
  777. series: [
  778. {
  779. type: 'bar',
  780. name: '投资金额',
  781. barWidth: 15,
  782. itemStyle: {
  783. normal: {
  784. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  785. {
  786. offset: 0,
  787. color: '#69c0ff',
  788. },
  789. {
  790. offset: 1,
  791. color: '#082550',
  792. },
  793. ]),
  794. },
  795. },
  796. data: industryList.map(item=> item.value),
  797. },
  798. {
  799. type: 'line',
  800. name: '投资占比',
  801. type: 'line',
  802. yAxisIndex: 1,
  803. smooth: true, //平滑曲线显示
  804. showAllSymbol: true, //显示所有图形。
  805. symbol: 'circle', //标记的图形为实心圆
  806. symbolSize: 4, //标记的大小
  807. smooth: false,
  808. itemStyle: {
  809. //折线拐点标志的样式
  810. color: '#fbe138',
  811. borderColor: '#fbe138',
  812. width: 1,
  813. shadowColor: '#fbe138',
  814. shadowBlur: 2,
  815. },
  816. lineStyle: {
  817. color: '#fbe138',
  818. width: 1,
  819. },
  820. data: industryList.map(item=> item.value2),
  821. },
  822. ],
  823. }
  824. myChart.setOption(option)
  825. tools.loopShowTooltip(myChart, option, {
  826. nterval: 2000,
  827. loopSeries: true,
  828. })
  829. },
  830. initProjectList() {
  831. let dataList = []
  832. projectList.map(item=> {
  833. dataList.push([item.name,item.value+'亿',item.status])
  834. })
  835. this.storageRecordConfig = {
  836. header: ['项目名称', '投资金额', '项目进度'],
  837. headerBGC: '#05507b33',
  838. oddRowBGC: '#05507b33',
  839. evenRowBGC: '',
  840. headerHeight: '40',
  841. rowNum: 5,
  842. columnWidth: [350,100],
  843. align: ['center', 'center', 'center'],
  844. data: dataList,
  845. }
  846. }
  847. },
  848. })