index.js 147 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011
  1. let app = new Vue({
  2. el: "#app",
  3. data () {
  4. return {
  5. count: 0, //重点项目两线指标轮到哪个
  6. list: [], //重点项目两线指标数组
  7. countType: 0, //重点项目两线指标数组
  8. mapShow: true, // false为中国地图 true为山西地图
  9. leftEcharts1: "",
  10. leftEcharts2: "",
  11. leftEcharts3: "",
  12. leftEcharts4: "",
  13. leftEcharts5: "",
  14. leftEcharts6: "",
  15. leftEcharts7: "",
  16. leftEcharts8: "",
  17. leftEcharts9: "",
  18. leftEcharts10: "",
  19. leftEcharts11: "",
  20. leftEcharts12: '',
  21. leftEcharts13: '',
  22. leftEcharts14: '',
  23. leftEcharts15: '',
  24. echartR2Fd: true, // 投后进度成本偏差防抖
  25. leftEcharts16: '', // 中国地图背景地球
  26. rightEcharts1: '', // 投后进度成本偏差
  27. shanxiMap: "", // 山西地图
  28. chinaMap: '', // 中国地图
  29. industryProportion: 1, // 主辅业占比轮播
  30. industryLayout: 0, //产业布局分析
  31. time1: "", // 4秒定时器
  32. time2: "", // 针对投前产业布局分析的定时器
  33. projectNum: 0, // 项目阶段分析指示器
  34. projecList: [ //项目阶段分析内容距离
  35. [
  36. { name: '特别监管', value: '1230', value2: '1036' },
  37. { name: '备案', value: '1230', value2: '1036' },
  38. { name: '项目储备', distance: '250px' }
  39. ],
  40. [
  41. { name: '特别监管', value: '1230', value2: '1036' },
  42. { name: '备案', value: '1230', value2: '1036' },
  43. { name: '项目储备', distance: '370px' }
  44. ],
  45. [
  46. { name: '特别监管', value: '1230', value2: '1036' },
  47. { name: '备案', value: '1230', value2: '1036' },
  48. { name: '项目储备', distance: '490px' }
  49. ],
  50. [
  51. { name: '特别监管', value: '1230', value2: '1036' },
  52. { name: '备案', value: '1230', value2: '1036' },
  53. { name: '项目储备', distance: '610px' }
  54. ],
  55. [
  56. { name: '特别监管', value: '1230', value2: '1036' },
  57. { name: '备案', value: '1230', value2: '1036' },
  58. { name: '项目储备', distance: '350px' }
  59. ],
  60. [
  61. { name: '特别监管', value: '1230', value2: '1036' },
  62. { name: '备案', value: '1230', value2: '1036' },
  63. { name: '项目储备', distance: '470px' }
  64. ],
  65. [
  66. { name: '特别监管', value: '1230', value2: '1036' },
  67. { name: '备案', value: '1230', value2: '1036' },
  68. { name: '项目储备', distance: '590px' }
  69. ],
  70. [
  71. { name: '特别监管', value: '1230', value2: '1036' },
  72. { name: '备案', value: '1230', value2: '1036' },
  73. { name: '项目储备', distance: '710px' }
  74. ],
  75. ],
  76. storageRecordConfig: {
  77. waitTime: "2000",
  78. hoverPause: true,
  79. header: ["企业集团", "项目名 ", "投资总额"],
  80. headerHeight: 80,
  81. headerBGC: '#69C0FF20',
  82. oddRowBGC: '#011e4800',
  83. evenRowBGC: '#69C0FF20',
  84. // oddRowBGC: '#05507b33',
  85. rowNum: 6,
  86. columnWidth: [150, 450, 150],
  87. align: ["center", "center", "center"],
  88. data: [
  89. ["国际能源", "娄烦县120MW智慧光伏发电项目+10%储能", "6.78亿元"],
  90. ["国际能源", "平朔矿区150MW农光储氢一体化项目", "7.84亿元"],
  91. ["汾酒集团", "汾酒2030技改原酒产储能扩建项目(一期)", "91.02亿元"],
  92. [
  93. "大地控股",
  94. "山西大地控股忻州新店矿业有限公司投资建设年产800万吨精品砂石骨料项目",
  95. "8.67亿元",
  96. ],
  97. ["潞安化工", "分布式光伏发电项目", "2.01亿元"],
  98. ["太重集团", "设立太重(大同)新能源产业投资公司", "0.30亿元"],
  99. [
  100. "大地控股",
  101. "山西大地宏翔环保科技有限公司电厂固废资源化综合利用建设项目",
  102. "3.60亿元",
  103. ],
  104. [
  105. "大地控股",
  106. "山西大地海科环保科技有限公司电厂固废资源化综合利用建设项目",
  107. "3.11亿元",
  108. ],
  109. ["汾酒集团", "保健酒园区新增原酒产能项目", "4.98亿元"],
  110. ["汾酒集团", "白玉酒厂改扩建项目", "4.96亿元"],
  111. ["华阳新材", "5GW高效光伏组件制造项目", "4.82亿元"],
  112. ["华新燃气", "吉县—延长输气管道项目(一期工程)", "3.54亿元"],
  113. ["太重集团", "建设液压挖掘机配套油缸项目", "2.60亿元"],
  114. [
  115. "华远陆港",
  116. "物产集团参股设立项目公司投资建设山西物产万科(太原)综合物流产业园项目",
  117. "6.60亿元",
  118. ],
  119. ["太重集团", "设立昔阳县晶能新能源有限公司", "0.50亿元"],
  120. ["山西建投", "设立山西低碳环保产业集团有限公司", "30.00亿元"],
  121. [
  122. "山西建投",
  123. "设立山西省太忻经济一体化发展投资集团有限公司",
  124. "30.00亿元",
  125. ],
  126. ["华新燃气", "设立山西华新液化天然气集团有限公司", "3.00亿元"],
  127. ["交控集团", "设立山西交控新能源发展有限公司", "3.00亿元"],
  128. ],
  129. },
  130. storageRecordConfig2: {
  131. header: ['企业集团', '项目名称', '投资金额'],
  132. headerBGC: '#69C0FF20',
  133. oddRowBGC: '#011e4800',
  134. evenRowBGC: '#69C0FF20',
  135. headerHeight: '80',
  136. rowNum: 6,
  137. // columnWidth: [250],
  138. align: ['center', 'center', 'center'],
  139. data: [
  140. ["战略性新兴产业", "新材料", "20,340.00"],
  141. ["战略性新兴产业", "新材料", "20,340.00"],
  142. ["战略性新兴产业", "新材料", "20,340.00"],
  143. ["战略性新兴产业", "新材料", "20,340.00"],
  144. ["战略性新兴产业", "新材料", "20,340.00"],
  145. ["战略性新兴产业", "新材料", "20,340.00"],
  146. ["战略性新兴产业", "新材料", "20,340.00"],
  147. ["战略性新兴产业", "新材料", "20,340.00"],
  148. ["战略性新兴产业", "新材料", "20,340.00"],
  149. ],
  150. },
  151. meansList: [
  152. {
  153. label: "初步设计",
  154. value: "106",
  155. },
  156. {
  157. label: "详细设计",
  158. value: "103",
  159. },
  160. {
  161. label: "施工",
  162. value: "62",
  163. },
  164. {
  165. label: "完工",
  166. value: "35",
  167. },
  168. {
  169. label: "验收",
  170. value: "42",
  171. },
  172. {
  173. label: "结算",
  174. value: "33",
  175. },
  176. ],
  177. stockRightList: [
  178. {
  179. label: "前期准备",
  180. value: "66",
  181. },
  182. {
  183. label: "变更登记",
  184. value: "77",
  185. },
  186. ],
  187. costList: [
  188. {
  189. num: 160,
  190. value: 284,
  191. status: "正偏差",
  192. },
  193. {
  194. num: 280,
  195. value: 129,
  196. status: "容差内",
  197. },
  198. {
  199. num: 103,
  200. value: 1082,
  201. status: "负偏差",
  202. },
  203. ],
  204. investData: {
  205. investList: [
  206. {
  207. name: "大地控股",
  208. yse: "26.79",
  209. yqhte: "9.64",
  210. czrde: "121.59",
  211. jse: "120.13",
  212. fke: "36.4",
  213. url: "./img/logos/logo15.png",
  214. },
  215. {
  216. name: "云时代",
  217. yse: "21.79",
  218. yqhte: "9.64",
  219. czrde: "121.59",
  220. jse: "120.13",
  221. fke: "36.4",
  222. url: "./img/logos/logo16.png",
  223. },
  224. {
  225. name: "华舰体育",
  226. yse: "26.79",
  227. yqhte: "9.64",
  228. czrde: "121.59",
  229. jse: "120.13",
  230. fke: "36.4",
  231. url: "./img/logos/logo17.png",
  232. },
  233. {
  234. name: "神农科技",
  235. yse: "26.79",
  236. yqhte: "9.64",
  237. czrde: "121.59",
  238. jse: "120.13",
  239. fke: "36.4",
  240. url: "./img/logos/logo18.png",
  241. },
  242. {
  243. name: "山西焦煤",
  244. yse: "26.79",
  245. yqhte: "9.64",
  246. czrde: "121.59",
  247. jse: "120.13",
  248. fke: "36.4",
  249. url: "./img/logos/logo1.png",
  250. },
  251. {
  252. name: "晋能控股",
  253. yse: "26.79",
  254. yqhte: "9.64",
  255. czrde: "121.59",
  256. jse: "120.13",
  257. fke: "36.4",
  258. url: "./img/logos/logo2.png",
  259. },
  260. {
  261. name: "华阳新材",
  262. yse: "26.79",
  263. yqhte: "9.64",
  264. czrde: "121.59",
  265. jse: "120.13",
  266. fke: "36.4",
  267. url: "./img/logos/logo3.png",
  268. },
  269. {
  270. name: "潞安化工",
  271. yse: "26.79",
  272. yqhte: "9.64",
  273. czrde: "121.59",
  274. jse: "120.13",
  275. fke: "36.4",
  276. url: "./img/logos/logo4.png",
  277. },
  278. {
  279. name: "华新燃气",
  280. yse: "26.79",
  281. yqhte: "9.64",
  282. czrde: "121.59",
  283. jse: "120.13",
  284. fke: "36.4",
  285. url: "./img/logos/logo5.png",
  286. },
  287. {
  288. name: "太重集团",
  289. yse: "26.79",
  290. yqhte: "9.64",
  291. czrde: "121.59",
  292. jse: "120.13",
  293. fke: "36.4",
  294. url: "./img/logos/logo6.png",
  295. },
  296. {
  297. name: "国际能源",
  298. yse: "26.79",
  299. yqhte: "9.64",
  300. czrde: "121.59",
  301. jse: "120.13",
  302. fke: "36.4",
  303. url: "./img/logos/logo7.png",
  304. },
  305. {
  306. name: "华远陆港",
  307. yse: "26.79",
  308. yqhte: "9.64",
  309. czrde: "121.59",
  310. jse: "120.13",
  311. fke: "36.4",
  312. url: "./img/logos/logo8.png",
  313. },
  314. {
  315. name: "水控集团",
  316. yse: "26.79",
  317. yqhte: "9.64",
  318. czrde: "121.59",
  319. jse: "120.13",
  320. fke: "36.4",
  321. url: "./img/logos/logo9.png",
  322. },
  323. {
  324. name: "文旅集团",
  325. yse: "26.79",
  326. yqhte: "9.64",
  327. czrde: "121.59",
  328. jse: "120.13",
  329. fke: "36.4",
  330. url: "./img/logos/logo10.png",
  331. },
  332. {
  333. name: "交控集团",
  334. yse: "26.79",
  335. yqhte: "9.64",
  336. czrde: "121.59",
  337. jse: "120.13",
  338. fke: "36.4",
  339. url: "./img/logos/logo11.png",
  340. },
  341. {
  342. name: "航产集团",
  343. yse: "26.79",
  344. yqhte: "9.64",
  345. czrde: "121.59",
  346. jse: "120.13",
  347. fke: "36.4",
  348. url: "./img/logos/logo12.png",
  349. },
  350. {
  351. name: "山西建投",
  352. yse: "26.79",
  353. yqhte: "9.64",
  354. czrde: "121.59",
  355. jse: "120.13",
  356. fke: "36.4",
  357. url: "./img/logos/logo13.png",
  358. },
  359. {
  360. name: "汾酒集团",
  361. yse: "26.79",
  362. yqhte: "9.64",
  363. czrde: "121.59",
  364. jse: "120.13",
  365. fke: "36.4",
  366. url: "./img/logos/logo14.png",
  367. },
  368. ],
  369. },
  370. riskData: {
  371. x: [
  372. { name: "大地控股", value: [14, 13, 6, 15, 13, 4] },
  373. { name: "云时代", value: [15, 12, 12, 10, 24, 6] },
  374. { name: "华舰体育", value: [14, 13, 6, 15, 13, 4] },
  375. { name: "神农科技", value: [14, 13, 6, 15, 13, 4] },
  376. { name: "山西焦煤", value: [14, 13, 6, 15, 13, 4] },
  377. { name: "晋能控股", value: [14, 13, 6, 15, 13, 4] },
  378. { name: "华阳新材", value: [14, 13, 6, 15, 13, 4] },
  379. { name: "潞安化工", value: [14, 13, 6, 15, 13, 4] },
  380. { name: "华新燃气", value: [14, 13, 6, 15, 13, 4] },
  381. { name: "太重集团", value: [14, 13, 6, 15, 13, 4] },
  382. { name: "国际能源", value: [14, 13, 6, 15, 13, 4] },
  383. { name: "华远陆港", value: [14, 13, 6, 15, 13, 4] },
  384. { name: "水控集团", value: [14, 13, 6, 15, 13, 4] },
  385. { name: "文旅集团", value: [14, 13, 6, 15, 13, 4] },
  386. { name: "交控集团", value: [14, 13, 6, 15, 13, 4] },
  387. { name: "航产集团", value: [14, 13, 6, 15, 13, 4] },
  388. { name: "山西建投", value: [14, 13, 6, 15, 13, 4] },
  389. { name: "汾酒集团", value: [14, 13, 6, 15, 13, 4] },
  390. ],
  391. y1: [
  392. 120, 110, 200, 220, 123, 345, 323, 123, 233, 234, 123, 143, 120, 110,
  393. 20, 220, 123, 345,
  394. ],
  395. y2: [
  396. 120, 110, 210, 220, 123, 345, 323, 123, 233, 234, 123, 143, 120, 110,
  397. 20, 220, 123, 345,
  398. ],
  399. y3: [
  400. 120, 110, 230, 220, 123, 345, 323, 123, 233, 234, 123, 143, 120, 110,
  401. 20, 220, 123, 345,
  402. ],
  403. },
  404. inner: 0,
  405. innerDeg: 0,
  406. timer: null, // 两秒定时器
  407. witchs: 0,
  408. topIndex: 0,
  409. echartR1Fd1: true,
  410. echartR2Fd2: true,
  411. echartC1Fd1:true,
  412. r3Index: 0,
  413. riskData1: {
  414. x: [
  415. "大地控股",
  416. "云时代",
  417. "华舰体育",
  418. "神农科技",
  419. "山西焦煤",
  420. "晋能控股",
  421. "华阳新材",
  422. "潞安化工",
  423. "华新燃气",
  424. "太重集团",
  425. "国际能源",
  426. "华远陆港",
  427. "水控集团",
  428. "文旅集团",
  429. "交控集团",
  430. "航产集团",
  431. "山西建投",
  432. "汾酒集团",
  433. ],
  434. y1: [
  435. 100, 45, 67, 110, 108, 120, 110, 45, 67, 110, 108, 34, 100, 45, 67,
  436. 110, 108, 34,
  437. ],
  438. y2: [
  439. 120, 50, 67, 130, 56, 233, 100, 78, 98, 100, 120, 78, 120, 90, 56,
  440. 120, 110, 78,
  441. ],
  442. y3: [
  443. 130, 76, 67, 120, 89, 111, 87, 123, 56, 65, 45, 98, 230, 78, 99, 130,
  444. 56, 98,
  445. ],
  446. y4: [
  447. 90, 100, 67, 90, 110, 120, 34, 231, 34, 78, 78, 100, 110, 120, 67, 89,
  448. 78, 110,
  449. ],
  450. y5: [
  451. 110, 110, 67, 110, 120, 95, 78, 45, 120, 110, 98, 233, 100, 45, 67,
  452. 98, 98, 34,
  453. ],
  454. },
  455. };
  456. },
  457. created () { },
  458. beforeDestroy () {
  459. clearInterval(this.timer);
  460. clearInterval(this.time1);
  461. clearInterval(this.time2);
  462. },
  463. mounted () {
  464. let that = this
  465. this.time4s();
  466. this.timeNs();
  467. this.filterLpData();
  468. this.lpRotate();
  469. setTimeout(() => {
  470. if (that.mapShow) {
  471. that.leftEcharts12Fun()
  472. that.leftEcharts14Fun()
  473. that.leftEcharts9Fun()
  474. that.leftEcharts15Fun()
  475. that.leftEcharts13Fun()
  476. that.shanxiEchartsFun()
  477. } else {
  478. that.chinaEchartsFun()
  479. that.leftEcharts16Fun() // 中国地图背景地球
  480. }
  481. this.leftEcharts1Fun();
  482. this.leftEcharts2Fun();
  483. this.leftEcharts3Fun();
  484. this.leftEcharts4Fun();
  485. this.leftEcharts5Fun();
  486. this.leftEcharts6Fun();
  487. this.leftEcharts7Fun();
  488. this.leftEcharts8Fun();
  489. this.leftEcharts10Fun();
  490. this.leftEcharts11Fun();
  491. this.rightEcharts1Fun();
  492. this.initChartR2();
  493. this.initChartR4();
  494. });
  495. },
  496. methods: {
  497. // 解决乘法失去精度
  498. numMulti (num1, num2) {
  499. var baseNum = 0;
  500. try {
  501. baseNum += num1.toString().split(".")[1].length;
  502. } catch (e) {
  503. }
  504. try {
  505. baseNum += num2.toString().split(".")[1].length;
  506. } catch (e) {
  507. }
  508. return Number(num1.toString().replace(".", "")) * Number(num2.toString().replace(".", "")) / Math.pow(10, baseNum);
  509. },
  510. // 解决减法失去精度
  511. numSub (num1, num2) {
  512. var baseNum, baseNum1, baseNum2;
  513. var precision;// 精度
  514. try {
  515. baseNum1 = num1.toString().split(".")[1].length;
  516. } catch (e) {
  517. baseNum1 = 0;
  518. }
  519. try {
  520. baseNum2 = num2.toString().split(".")[1].length;
  521. } catch (e) {
  522. baseNum2 = 0;
  523. }
  524. baseNum = Math.pow(10, Math.max(baseNum1, baseNum2));
  525. precision = (baseNum1 >= baseNum2) ? baseNum1 : baseNum2;
  526. return ((num1 * baseNum - num2 * baseNum) / baseNum).toFixed(precision);
  527. },
  528. rightEcharts1Fun () {
  529. let that = this
  530. let sumA = 42
  531. // 所有在100范围外的全部变成0,其他值相应增加/减少sumA
  532. right5.forEach(item => {
  533. item.forEach(item2 => {
  534. if (Number(item2[1]) < 0) {
  535. item2[1] = that.$set(item2, 1, Number(that.numSub(item2[1], sumA)))
  536. } else if (Number(item2[1]) > 0) {
  537. item2[1] = that.$set(item2, 1, Number(item2[1]) + sumA)
  538. }
  539. if (Number(item2[1]) < (-100 - sumA)) {
  540. item2[1] = that.$set(item2, 1, 0)
  541. item2[1] = that.$set(item2, 2, 0)
  542. } else if (Number(item2[1]) > (100 + sumA)) {
  543. item2[1] = that.$set(item2, 1, 0)
  544. item2[1] = that.$set(item2, 2, 0)
  545. }
  546. })
  547. })
  548. const itemStyle = {
  549. // opacity: 0.8,
  550. shadowBlur: 10,
  551. shadowOffsetX: 0,
  552. shadowOffsetY: 0,
  553. shadowColor: 'rgba(0,0,0,0.3)'
  554. };
  555. that.rightEcharts1 = echarts.init(this.$refs['rightEcharts1'])
  556. that.rightEcharts1.on('showTip', (params) => {
  557. // 如果是7或者15并且满足防抖则切换
  558. if ((params.dataIndex == 5 || params.dataIndex == 11) && that.echartR2Fd) {
  559. that.echartR2Fd = false
  560. setTimeout(() => {
  561. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  562. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  563. that.rightEcharts1.setOption(option);
  564. // 防止勿刷新做的防抖
  565. setTimeout(() => {
  566. that.echartR2Fd = true
  567. }, 2000)
  568. }, 1900);
  569. // 如果是17表示到了最后一个,那么重新来一遍
  570. } else if (params.dataIndex == 17 && that.echartR2Fd) {
  571. that.echartR2Fd = false
  572. setTimeout(() => {
  573. option.dataZoom[0].endValue = 0
  574. option.dataZoom[0].startValue = 5
  575. that.rightEcharts1.setOption(option);
  576. // 防止勿刷新做的防抖
  577. setTimeout(() => {
  578. that.echartR2Fd = true
  579. }, 2000)
  580. }, 1900)
  581. }
  582. })
  583. let option = {
  584. color: [{
  585. type: 'radial', // linear 线性渐变 radial径向渐变
  586. x: 0.5,
  587. y: 0.5,
  588. r: 0.5,
  589. colorStops: [{
  590. offset: 0, color: '#58F7DF' // 0% 处的颜色
  591. }, {
  592. offset: 1, color: '#4ECFBB' // 100% 处的颜色
  593. }]
  594. },
  595. {
  596. type: 'radial', // linear 线性渐变 radial径向渐变
  597. x: 0.5,
  598. y: 0.5,
  599. r: 0.5,
  600. colorStops: [{
  601. offset: 0, color: '#7FD9FF' // 0% 处的颜色
  602. }, {
  603. offset: 1, color: '#40A9FF' // 100% 处的颜色
  604. }]
  605. }, {
  606. type: 'radial', // linear 线性渐变 radial径向渐变
  607. x: 0.5,
  608. y: 0.5,
  609. r: 0.5,
  610. colorStops: [{
  611. offset: 0, color: '#FF9592' // 0% 处的颜色
  612. }, {
  613. offset: 1, color: '#D2706D' // 100% 处的颜色
  614. }]
  615. }
  616. ],
  617. dataZoom: [
  618. {
  619. // start: 9,//默认为@
  620. // end: 100,//黑认认为1@0
  621. type: "slider",
  622. show: false,
  623. // xAxisIndex: [0]
  624. handlesize: 0,//滑动条的 左右2个滑动条的大小
  625. startValue: 5,// 初始显示值
  626. endValue: 0,// 结束显示值
  627. height: 10,//组件高度
  628. left: "5%",
  629. right: "4%",//右边的距离
  630. bottom: "25%",//底边的距离
  631. borderColor: "#939",
  632. fillerColor: "#269cdb",
  633. borderRadius: 5,
  634. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  635. showDataShadow: false,//是否显示数据阴影
  636. showDetail: false,//即拖拽时候是否显示详细数值信息
  637. truerealtime: true,//是否实时更新
  638. filterMode: "filter"
  639. }, {
  640. type: 'inside',
  641. show: true,
  642. start: 1,
  643. end: 100,
  644. zoomOnMouseWheel: false, //滚轮是否触发缩放
  645. moveOnMouseMove: false, //鼠标滚轮触发滚动
  646. }
  647. ],
  648. legend: {
  649. selectedMode: false,
  650. top: 10,
  651. data: ['正偏差', '容差', '负偏差'],
  652. textStyle: {
  653. fontSize: 20,
  654. color: '#fff',
  655. fontFamily: 'Microsoft YaHei'
  656. }
  657. },
  658. textStyle: {
  659. color: '#fff',
  660. },
  661. tooltip: {
  662. show: true,
  663. trigger: "axis",
  664. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  665. borderColor: "rgba(50,50,50,0.7)",
  666. textStyle: {
  667. color: "#fff",
  668. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  669. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  670. fontSize: "28", // 文字字体大小
  671. },
  672. formatter: data => {
  673. return `${data[0].value[0]}<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[0].color}"></span> ${data[0].seriesName}:${that.numFormat(data[0].data[2])}亿<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[1].color}"></span> ${data[1].seriesName}:${that.numFormat(data[1].data[2])}亿<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[2].color}"></span> ${data[2].seriesName}:${that.numFormat(data[2].data[2])}亿`
  674. },
  675. axisPointer: {
  676. // // type: 'cross',',
  677. },
  678. },
  679. grid: {
  680. top: '10%',
  681. right: '7%',
  682. left: '7%',
  683. bottom: '5%',
  684. },
  685. yAxis: {
  686. min: (-101 - sumA),
  687. max: (101 + sumA),
  688. maxInterval: 1,
  689. splitLine: {
  690. show: false,
  691. // interval:,
  692. lineStyle: {
  693. color: '#68b4dd66',
  694. type: 'dashed',
  695. },
  696. },
  697. axisLine: {
  698. show: false
  699. },
  700. axisTick: {
  701. show: false
  702. },
  703. axisLabel: {
  704. show: true,
  705. // formatter: '{value}',
  706. formatter (data) {
  707. if (data == (100 + sumA)) {
  708. return '100%'
  709. } else if (data == (-100 - sumA)) {
  710. return '-100%'
  711. } else if (data == (-5 - sumA)) {
  712. return '-5%'
  713. } else if (data == (5 + sumA)) {
  714. return '5%'
  715. }
  716. },
  717. textStyle: {
  718. color: '#fff',
  719. fontSize: '20',
  720. fontFamily: 'Microsoft YaHei'
  721. },
  722. },
  723. nameTextStyle: {
  724. color: '#fff',
  725. fontSize: 20,
  726. fontFamily: 'Microsoft YaHei'
  727. },
  728. },
  729. xAxis: {
  730. data: commonCompany,
  731. axisLine: {
  732. show: false, //隐藏X轴轴线
  733. lineStyle: {
  734. color: '#005094',
  735. width: 1,
  736. },
  737. },
  738. splitLine: {
  739. show: true,
  740. lineStyle: {
  741. color: '#68b4dd66',
  742. type: 'dashed',
  743. },
  744. },
  745. axisTick: {
  746. show: true, //隐藏X轴刻度
  747. },
  748. axisLabel: {
  749. show: true,
  750. // rotate: 40,
  751. padding: [0, 0, 0, 0],
  752. textStyle: {
  753. color: '#fff', //X轴文字颜色
  754. fontSize: 20,
  755. fontFamily: 'Microsoft YaHei'
  756. },
  757. },
  758. },
  759. series: [
  760. {
  761. name: '正偏差',
  762. type: 'scatter',
  763. itemStyle: itemStyle,
  764. data: right5[0],
  765. symbolSize: function (data) {
  766. if ((data[2] > 0 && data[2] < 50) || data[2] == 50) {
  767. return 40;
  768. } else if ((data[2] > 50 && data[2] < 100) || data[2] == 100) {
  769. return 70;
  770. } else if (data[2] > 100) {
  771. return 100;
  772. }
  773. },
  774. markLine: {
  775. symbol: 'none',
  776. data: [
  777. {
  778. name: '100%',
  779. yAxis: 100 + sumA,
  780. lineStyle: {
  781. // color: '#fff',
  782. },
  783. label: {
  784. show: false,
  785. formatter: '{b}',
  786. position: 'right',
  787. color: '#fff',
  788. fontSize: 20,
  789. label: {
  790. show: false
  791. }
  792. },
  793. },
  794. {
  795. name: '5%',
  796. yAxis: 5 + sumA,
  797. lineStyle: {
  798. // color: '#fff',
  799. },
  800. label: {
  801. show: false,
  802. formatter: '{b}',
  803. position: 'right',
  804. color: '#fff',
  805. fontSize: 20,
  806. },
  807. },
  808. {
  809. name: '-5%',
  810. yAxis: -5 - sumA,
  811. lineStyle: {
  812. // color: '#fff',
  813. },
  814. label: {
  815. show: false,
  816. formatter: '{b}',
  817. position: 'right',
  818. color: '#fff',
  819. fontSize: 20,
  820. },
  821. },
  822. {
  823. name: '100%',
  824. yAxis: -100 - sumA,
  825. lineStyle: {
  826. // color: '#fff',
  827. },
  828. label: {
  829. show: false,
  830. formatter: '{b}',
  831. position: 'right',
  832. color: '#fff',
  833. fontSize: 20,
  834. },
  835. },
  836. ],
  837. },
  838. },
  839. {
  840. name: '容差',
  841. type: 'scatter',
  842. itemStyle: itemStyle,
  843. data: right5[1],
  844. symbolSize: function (data) {
  845. if ((data[2] > 0 && data[2] < 50) || data[2] == 50) {
  846. return 40;
  847. } else if ((data[2] > 50 && data[2] < 100) || data[2] == 100) {
  848. return 70;
  849. } else if (data[2] > 100) {
  850. return 100;
  851. }
  852. },
  853. },
  854. {
  855. name: '负偏差',
  856. type: 'scatter',
  857. itemStyle: itemStyle,
  858. data: right5[2],
  859. symbolSize: function (data) {
  860. if ((data[2] > 0 && data[2] < 50) || data[2] == 50) {
  861. return 40;
  862. } else if ((data[2] > 50 && data[2] < 100) || data[2] == 100) {
  863. return 70;
  864. } else if (data[2] > 100) {
  865. return 100;
  866. }
  867. },
  868. }
  869. ]
  870. }
  871. that.rightEcharts1.setOption(option)
  872. tools.loopShowTooltip(that.rightEcharts1, option, {
  873. interval: 2000,
  874. loopSeries: true,
  875. })
  876. },
  877. initChartR2 () {
  878. let that = this;
  879. that.right1Chart = echarts.init(this.$refs["echartR2"]);
  880. that.right1Chart.on("showTip", (params) => {
  881. that.r3Index = params.dataIndex;
  882. that.initChartR3();
  883. // 如果是7或者15并且满足防抖则切换
  884. if (
  885. (params.dataIndex == 5 || params.dataIndex == 11) &&
  886. that.echartR1Fd1
  887. ) {
  888. that.echartR1Fd1 = false;
  889. setTimeout(() => {
  890. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6;
  891. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6;
  892. that.right1Chart.setOption(option);
  893. // 防止勿刷新做的防抖
  894. setTimeout(() => {
  895. that.echartR1Fd1 = true;
  896. }, 2000);
  897. }, 1900);
  898. // 如果是17表示到了最后一个,那么重新来一遍
  899. } else if (params.dataIndex == 17 && that.echartR1Fd1) {
  900. that.echartR1Fd1 = false;
  901. setTimeout(() => {
  902. option.dataZoom[0].endValue = 0;
  903. option.dataZoom[0].startValue = 5;
  904. that.right1Chart.setOption(option);
  905. // 防止勿刷新做的防抖
  906. setTimeout(() => {
  907. that.echartR1Fd1 = true;
  908. }, 2000);
  909. }, 1900);
  910. }
  911. });
  912. let option = {
  913. color: [
  914. {
  915. type: "linear",
  916. x: 0,
  917. y: 0,
  918. x2: 0,
  919. y2: 1,
  920. colorStops: [
  921. {
  922. offset: 0,
  923. color: "#07806E", // 0% 处的颜色
  924. },
  925. {
  926. offset: 1,
  927. color: "#79FFEB", // 100% 处的颜色
  928. },
  929. ],
  930. global: false, // 缺省为 false
  931. },
  932. {
  933. type: "linear",
  934. x: 0,
  935. y: 0,
  936. x2: 0,
  937. y2: 1,
  938. colorStops: [
  939. {
  940. offset: 0,
  941. color: "#9F7F00", // 0% 处的颜色
  942. },
  943. {
  944. offset: 1,
  945. color: "#FBE463", // 100% 处的颜色
  946. },
  947. ],
  948. global: false, // 缺省为 false
  949. },
  950. {
  951. type: "linear",
  952. x: 0,
  953. y: 0,
  954. x2: 0,
  955. y2: 1,
  956. colorStops: [
  957. {
  958. offset: 0,
  959. color: "#91231F", // 0% 处的颜色
  960. },
  961. {
  962. offset: 1,
  963. color: "#F98784", // 100% 处的颜色
  964. },
  965. ],
  966. global: false, // 缺省为 false
  967. }
  968. ],
  969. dataZoom: [
  970. {
  971. // start: 9,//默认为@
  972. // end: 100,//黑认认为1@0
  973. type: "slider",
  974. show: false,
  975. // xAxisIndex: [0]
  976. handlesize: 0, //滑动条的 左右2个滑动条的大小
  977. startValue: 5, // 初始显示值
  978. endValue: 0, // 结束显示值
  979. height: 10, //组件高度
  980. left: "5%",
  981. right: "4%", //右边的距离
  982. bottom: "25%", //底边的距离
  983. borderColor: "#939",
  984. fillerColor: "#269cdb",
  985. borderRadius: 5,
  986. backgroundColor: "#33384b", //两边未选中的滑动条区域的额色
  987. showDataShadow: false, //是否显示数据阴影
  988. showDetail: false, //即拖拽时候是否显示详细数值信息
  989. truerealtime: true, //是否实时更新
  990. filterMode: "filter",
  991. },
  992. {
  993. type: "inside",
  994. show: true,
  995. start: 1,
  996. end: 100,
  997. zoomOnMouseWheel: false, //滚轮是否触发缩放
  998. moveOnMouseMove: false, //鼠标滚轮触发滚动
  999. },
  1000. ],
  1001. legend: {
  1002. top: 10,
  1003. right: 10,
  1004. textStyle: {
  1005. fontSize: 20,
  1006. color: "#fff",
  1007. fontFamily: "Microsoft YaHei",
  1008. },
  1009. itemStyle: {
  1010. borderCap: "round",
  1011. },
  1012. },
  1013. tooltip: {
  1014. trigger: "item",
  1015. show: true,
  1016. position: "top",
  1017. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  1018. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  1019. borderColor: "rgba(50,50,50,0.7)",
  1020. textStyle: {
  1021. color: "#fff",
  1022. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  1023. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  1024. fontSize: "28", // 文字字体大小
  1025. },
  1026. formatter: function (p) {
  1027. return `${p.name}<br>低风险:${that.riskData.y1[p.dataIndex]}个<br>
  1028. 中风险:${that.riskData.y2[p.dataIndex]}个<br>
  1029. 高风险:${that.riskData.y3[p.dataIndex]}个<br>
  1030. `
  1031. },
  1032. },
  1033. grid: {
  1034. left: "3%",
  1035. right: "4%",
  1036. bottom: "3%",
  1037. containLabel: true,
  1038. },
  1039. xAxis: [
  1040. {
  1041. type: "category",
  1042. data: that.riskData.x.map((item) => item.name),
  1043. axisLine: {
  1044. show: true,
  1045. lineStyle: {
  1046. color: "rgba(0, 80, 148, .8)",
  1047. },
  1048. },
  1049. axisTick: {
  1050. show: false,
  1051. },
  1052. axisLabel: {
  1053. color: "#fff",
  1054. rotate: 20,
  1055. fontSize: 22,
  1056. },
  1057. },
  1058. ],
  1059. yAxis: [
  1060. {
  1061. type: "value",
  1062. axisLabel: {
  1063. color: "#fff",
  1064. fontSize: 22,
  1065. },
  1066. splitLine: {
  1067. show: true,
  1068. lineStyle: {
  1069. color: "rgba(104, 180, 221, .2)",
  1070. type: "dashed",
  1071. },
  1072. },
  1073. },
  1074. ],
  1075. series: [
  1076. {
  1077. name: "低风险",
  1078. type: "bar",
  1079. stack: "Ad",
  1080. barWidth: 14,
  1081. emphasis: {
  1082. focus: "series",
  1083. },
  1084. itemStyle: {
  1085. barBorderRadius: [15, 15, 15, 15],
  1086. },
  1087. data: that.riskData.y1,
  1088. },
  1089. {
  1090. name: "中风险",
  1091. type: "bar",
  1092. barWidth: 14,
  1093. stack: "Ad",
  1094. itemStyle: {
  1095. barBorderRadius: [15, 15, 15, 15],
  1096. },
  1097. emphasis: {
  1098. focus: "series",
  1099. },
  1100. data: that.riskData.y2,
  1101. },
  1102. {
  1103. name: "高风险",
  1104. type: "bar",
  1105. barWidth: 14,
  1106. stack: "Ad",
  1107. itemStyle: {
  1108. barBorderRadius: [15, 15, 15, 15],
  1109. },
  1110. emphasis: {
  1111. focus: "series",
  1112. },
  1113. data: that.riskData.y3,
  1114. },
  1115. ],
  1116. };
  1117. that.right1Chart.setOption(option);
  1118. tools.loopShowTooltip(that.right1Chart, option, {
  1119. interval: 2000,
  1120. loopSeries: true,
  1121. });
  1122. },
  1123. initChartR3 () {
  1124. let that = this;
  1125. that.right3Chart = echarts.init(this.$refs["echartR3"]);
  1126. let option = {
  1127. radar: {
  1128. // shape: 'circle',
  1129. splitNumber: 3,
  1130. splitLine: {
  1131. lineStyle: {
  1132. color: ["#DD5955", "#39e1d0", "#2e3d45"],
  1133. },
  1134. },
  1135. splitArea: {
  1136. areaStyle: {
  1137. color: [
  1138. "rgba(88,247,223,0.2)",
  1139. "rgba(255, 224, 54, 0.2)",
  1140. "rgba(221,89,85,0.3)",
  1141. ],
  1142. },
  1143. },
  1144. indicator: [
  1145. { name: "安全风险", max: 25 },
  1146. { name: "付款风险", max: 25 },
  1147. { name: "合同风险", max: 25 },
  1148. { name: "结算风险", max: 25 },
  1149. { name: "进度风险", max: 25 },
  1150. { name: "质量风险", max: 25 },
  1151. ],
  1152. },
  1153. series: [
  1154. {
  1155. name: "风险",
  1156. type: "radar",
  1157. symbol: "circle",
  1158. label: {
  1159. show: true,
  1160. formatter: function (params) {
  1161. return params.value;
  1162. },
  1163. fontSize: 24,
  1164. color: "#68BDFF",
  1165. },
  1166. data: [
  1167. {
  1168. value: that.riskData.x[that.r3Index].value,
  1169. areaStyle: {
  1170. color: "#112b75",
  1171. },
  1172. lineStyle: {
  1173. width: 4,
  1174. color: "#60C1FF",
  1175. },
  1176. label: {
  1177. fontSize: 22,
  1178. },
  1179. },
  1180. ],
  1181. },
  1182. ],
  1183. };
  1184. that.right3Chart.setOption(option);
  1185. },
  1186. initChartR4 () {
  1187. let that = this;
  1188. that.right4Chart = echarts.init(this.$refs["echartR4"]);
  1189. that.right4Chart.on("showTip", (params) => {
  1190. // 如果是7或者15并且满足防抖则切换
  1191. if (
  1192. (params.dataIndex == 5 || params.dataIndex == 11) &&
  1193. that.echartR2Fd2
  1194. ) {
  1195. that.echartR2Fd2 = false;
  1196. setTimeout(() => {
  1197. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6;
  1198. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6;
  1199. that.right4Chart.setOption(option);
  1200. // 防止勿刷新做的防抖
  1201. setTimeout(() => {
  1202. that.echartR2Fd2 = true;
  1203. }, 2000);
  1204. }, 1900);
  1205. // 如果是17表示到了最后一个,那么重新来一遍
  1206. } else if (params.dataIndex == 17 && that.echartR2Fd2) {
  1207. that.echartR2Fd2 = false;
  1208. setTimeout(() => {
  1209. option.dataZoom[0].endValue = 0;
  1210. option.dataZoom[0].startValue = 5;
  1211. that.right4Chart.setOption(option);
  1212. // 防止勿刷新做的防抖
  1213. setTimeout(() => {
  1214. that.echartR2Fd2 = true;
  1215. }, 2000);
  1216. }, 1900);
  1217. }
  1218. });
  1219. let option = {
  1220. dataZoom: [
  1221. {
  1222. // start: 9,//默认为@
  1223. // end: 100,//黑认认为1@0
  1224. type: "slider",
  1225. show: false,
  1226. // xAxisIndex: [0]
  1227. handlesize: 0, //滑动条的 左右2个滑动条的大小
  1228. startValue: 5, // 初始显示值
  1229. endValue: 0, // 结束显示值
  1230. height: 10, //组件高度
  1231. left: "5%",
  1232. right: "4%", //右边的距离
  1233. bottom: "25%", //底边的距离
  1234. borderColor: "#939",
  1235. fillerColor: "#269cdb",
  1236. borderRadius: 5,
  1237. backgroundColor: "#33384b", //两边未选中的滑动条区域的额色
  1238. showDataShadow: false, //是否显示数据阴影
  1239. showDetail: false, //即拖拽时候是否显示详细数值信息
  1240. truerealtime: true, //是否实时更新
  1241. filterMode: "filter",
  1242. },
  1243. {
  1244. type: "inside",
  1245. show: true,
  1246. start: 1,
  1247. end: 100,
  1248. zoomOnMouseWheel: false, //滚轮是否触发缩放
  1249. moveOnMouseMove: false, //鼠标滚轮触发滚动
  1250. },
  1251. ],
  1252. title: {
  1253. text: "企业后评价执行情况",
  1254. left: "center",
  1255. textStyle: {
  1256. color: "#fff",
  1257. fontSize: 32,
  1258. },
  1259. },
  1260. tooltip: {
  1261. trigger: "item",
  1262. show: true,
  1263. position: "top",
  1264. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  1265. borderColor: "rgba(50,50,50,0.7)",
  1266. confine: true,
  1267. textStyle: {
  1268. color: "#fff",
  1269. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  1270. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  1271. fontSize: "28", // 文字字体大小
  1272. },
  1273. formatter: function (p) {
  1274. return `${p.name}<br>应首评项目数:${that.riskData1.y1[p.dataIndex]}个<br>
  1275. 已完成首评项目数:${that.riskData1.y2[p.dataIndex]}个<br>
  1276. 应再评项目数:${that.riskData1.y3[p.dataIndex]}个<br>
  1277. 已完成再评项目数:${that.riskData1.y4[p.dataIndex]}个<br>
  1278. 再评达标项目数:${that.riskData1.y5[p.dataIndex]}个
  1279. `
  1280. },
  1281. },
  1282. legend: {
  1283. show: true,
  1284. textStyle: {
  1285. fontSize: 24,
  1286. color: "rgba(255, 255, 255, .6)",
  1287. },
  1288. inactiveColor: "#fff",
  1289. itemHeight: 20,
  1290. top: "15%",
  1291. backgroundColor: "transparent",
  1292. data: [
  1293. {
  1294. name: "应首评项目数",
  1295. icon: "image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAUCAYAAAC58NwRAAAAAXNSR0IArs4c6QAAAWdJREFUOE+N0k8og3EYB/Dvs8P8CSlTxJGD8u+yTYmNm0gJQznIQRxMoV2cXWSKCznIQdk7SkmOEomNg41y4EjURkLZFI/ed3vX+5v82nt4357n9/s8Pe/v9xCST6+fzVHGKAMDAKqT6WsCNi2ElS0Xfak5Ul+tfi77YewBqNcLpH0vTYSOAxc9kFo5wghINus2lJMPOzl8PE6EpX8qC2lmuMmp8CmABn3FVgJ4bIloLggEnwRzRg6F4wSY9fR2J1CUnYieY0DPrgDiUvASA7pF8PGnJXsp4LEC3wx4L4DAY1pLLQq7GVjM5KcJmKC2fc76fNeOtU6GmBDOzYMt04sLmQjt2sUZRyMCjAEYBKNKyxNuAGwUA8vCaBhbcSrMxviwj1JFU7Nk3NC49iqAk+FCObAu3AngfLJCDmpmjgVwNdskB5UjPgHcrvbLQXmXVwD3O1NyYGmeFkD0aF4OCmqHBPAWXhfAL4WqeuKVsFKCAAAAAElFTkSuQmCC",
  1296. },
  1297. {
  1298. name: "已完成首评项目数",
  1299. icon: "image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAUCAYAAAC58NwRAAAAAXNSR0IArs4c6QAAAXFJREFUOE+V0kFLAkEUB/D/G9eW3UN1sFPYNaJAu2R0Coog8mq0fQH1kEVBhz5Ah6CoLhrdE/LqKQo6VZ7SKCKChKRTBRmhbq47oabsZC22h1nem/k93jCP8P0F+E2HQ1dD4NAAGqqn+TUI8YpciCVo8LOaoeoSKOR6GTOSxOFtFLD+OSFtmpI/obqfqFqZ6Wrqr8NNyJHJK4aPtNLDAue0+1vlnzkiHqG5YvYcwGhj08MUhJyuWhgrvyBjFq3uogp0AB2NbFR2o5sctfCNVxDWc1ag/xPQR0tLXqYg6HTBBMd++RXplpZK2Qg4dtq5NAiLNM3v5a6ilALBY4s4rvKKMdLWw4EjU4E0U3s462gwXQ3DMLeJsfpgmCYgsSVTLkSF0bC24r9NcWucHPA1izZnyXpg8vRIAMfjU/ZgLH4ogDNt1h4Mb8YEcLkSsgf9y+sCuNtaswd92qoAHuMb9qBnIiiA55M9e9DpnRfAe/pAAF9gqJXUYWdYUwAAAABJRU5ErkJggg==",
  1300. },
  1301. {
  1302. name: "应再评项目数",
  1303. icon: "image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAUCAYAAAC58NwRAAAAAXNSR0IArs4c6QAAAV5JREFUOE+V0j8oxGEYwPHvo/wMjgyUslAWcTFhMRiEsHLKYDzFKZRBSskgR7mUG29QjpX86QaDwdlwLotiUYpB/gyHPDru9HsPP+c3vL+e530/T8/b+wipb31KrYJ8vAi9QE0qfYqy+vBEsHtKnpM5SS4bC1qW+8amQl26gP0vcPSSQ2fXiFxJsnKhi8PfDtvgsVo0yJZfhwQCP1XOzCn4ZNuvB0BjerO4HNxtn1FsB24vDRZNggRgpdPNXsjL/4wST7AXNEDiv+DxW0slFVDTCvoG8QjcXGS2NKc+hMVsLo0yLFsBzZNnDoHaP9CJWtRn9XDA8WsOHR8PZx+NQhcDqvQhVH3klTMRVu4fWTZGw97Ktl/VHrePyVfRr1myHwhP3xnAM1nkDJbGzw0wOFvpDCa8+waYCTY5g/6esAFCax5n0NI6b4DI7qgzcDeOGSAW9TuD0up+A1zHQwZ4B2JrgI9r4uMDAAAAAElFTkSuQmCC",
  1304. },
  1305. {
  1306. name: "已完成再评项目数",
  1307. icon: "image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAUCAYAAAC58NwRAAAAAXNSR0IArs4c6QAAAWBJREFUOE9jZICC/1e12Rh4uDIY/jNGMjAw6ECFrzAw/l/O8OXbDEbtq79AYowg4v9jS2mGv3+3MDAwGMAMQKMvMDAz+zDKHn/KCDaZm/skHsUwvRcZfr8zZ/z/0CyX4T/DJBwmowozMuQx/n9gdpyBgcECLsNpycAgXAPhvm1hYPgOkoaDEyANPxkYGNjgQjJbGRiYRSDcv28YGJ54I2v4SUDDWwaGJ17IGr5gcZIV1El/GRjetjMwfD+G5qSHpnkM/xknEufp//mM/2+rsDOwCoGCVZ+ApksMv9+ZERtxFxmYmb3BEYeaNHgyGf7/j2FgYNCEil9nYGRcwvDly3SUpIHslP8PzP4j8xkVTsENhaclZAWvLligaBAzOIFfw9ld1igajN2O4tewar49ioawxIP4NbQ0OqNoqKnfi19DXIoHioZFc3bg12Dt6YOi4ej2Lfg1yBn7o2h4dHYjigYAb0t88hVwEBYAAAAASUVORK5CYII=",
  1308. },
  1309. {
  1310. name: "再评达标项目数",
  1311. icon: "image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAUCAYAAAC58NwRAAAAAXNSR0IArs4c6QAAAWBJREFUOE+V0k8og2EcwPHvkzVZLLm6KItEzWlclIPbdhGKcsCJwzZFdtgOK+8OimIXTjgoSrisXByUgz8nE4mmXFwlZmuaPXr3r/eZ9sZ7eN9+v/f5/J6n3/MTFJ9wWFpTFqYFjAFdxfSthF1blo1wWHzpOaG/gppszkIM6C4VqPheW8ATCYkXoVdOW7g0WVyy8ZSdHhFYlF4E0SqV1bTEJwKaPAd6S3/aWmHEU4j2Y/D4pJgLHWQAaykd9ENDfSH6SEJkTQGZ/4LkryO1O2DYDbkcHB7DQ6LiSAua9AlQN67SAQl+4Y3KWtt7vq1Os04JuPm04/rrxcUt4M5fnHE00jXMIBgHOor5eyQ7dd+sK6NhPEpAk9IYL4VEuWh5lowLfKE3BUS1RnMwOZtQwNaqwxwMTp0p4Gizzxz0D+0p4PRg1Bw4B1YUED+ZMwctrnkFPF8tm4OmzgkFvN5tK+AHKZh4TU8krdoAAAAASUVORK5CYII=",
  1312. },
  1313. ],
  1314. },
  1315. grid: {
  1316. top: "30%",
  1317. left: "3%",
  1318. right: "4%",
  1319. bottom: "3%",
  1320. containLabel: true,
  1321. },
  1322. xAxis: {
  1323. data: that.riskData1.x,
  1324. type: "category",
  1325. splitLine: {
  1326. show: false,
  1327. },
  1328. alignTicks: true,
  1329. axisLine: {
  1330. show: true,
  1331. lineStyle: {
  1332. color: "rgba(0, 80, 148, .8)",
  1333. },
  1334. },
  1335. axisTick: {
  1336. show: false,
  1337. },
  1338. axisLabel: {
  1339. color: "#fff",
  1340. fontSize: 22,
  1341. rotate: 20,
  1342. },
  1343. },
  1344. yAxis: {
  1345. type: "value",
  1346. splitLine: {
  1347. show: true,
  1348. lineStyle: {
  1349. color: "rgba(104, 180, 221, .2)",
  1350. type: "dashed",
  1351. },
  1352. },
  1353. axisLine: {
  1354. show: false,
  1355. },
  1356. axisTick: {
  1357. show: false,
  1358. },
  1359. axisLabel: {
  1360. color: "#fff",
  1361. fontSize: 22,
  1362. },
  1363. },
  1364. series: [
  1365. {
  1366. type: "bar",
  1367. name: "应首评项目数",
  1368. barWidth: 4,
  1369. barGap: "600%",
  1370. data: that.riskData1.y1,
  1371. label: {
  1372. show: true,
  1373. position: "top",
  1374. formatter: " ",
  1375. width: 6,
  1376. height: 6,
  1377. borderRadius: 50,
  1378. borderWidth: 6,
  1379. borderColor: "#40A9FF",
  1380. backgroundColor: "#fff",
  1381. },
  1382. itemStyle: {
  1383. color: {
  1384. x: 0,
  1385. y: 0,
  1386. x2: 0,
  1387. y2: 1,
  1388. colorStops: [
  1389. {
  1390. offset: 0,
  1391. color: "#40A9FF", // 0% 处的颜色
  1392. },
  1393. {
  1394. offset: 1,
  1395. color: "#092351", // 100% 处的颜色
  1396. },
  1397. ],
  1398. },
  1399. },
  1400. },
  1401. {
  1402. type: "bar",
  1403. name: "已完成首评项目数",
  1404. barGap: "600%",
  1405. barWidth: 4,
  1406. data: that.riskData1.y2,
  1407. label: {
  1408. show: true,
  1409. position: "top",
  1410. formatter: " ",
  1411. width: 6,
  1412. height: 6,
  1413. borderRadius: 50,
  1414. borderWidth: 6,
  1415. borderColor: "#58F7DF",
  1416. backgroundColor: "#fff",
  1417. },
  1418. itemStyle: {
  1419. color: {
  1420. x: 0,
  1421. y: 0,
  1422. x2: 0,
  1423. y2: 1,
  1424. colorStops: [
  1425. {
  1426. offset: 0,
  1427. color: "#58F7DF", // 0% 处的颜色
  1428. },
  1429. {
  1430. offset: 1,
  1431. color: "#092351", // 100% 处的颜色
  1432. },
  1433. ],
  1434. },
  1435. },
  1436. },
  1437. {
  1438. type: "bar",
  1439. name: "应再评项目数",
  1440. barGap: "600%",
  1441. barWidth: 4,
  1442. data: that.riskData1.y3,
  1443. label: {
  1444. show: true,
  1445. position: "top",
  1446. formatter: " ",
  1447. width: 6,
  1448. height: 6,
  1449. borderRadius: 50,
  1450. borderWidth: 6,
  1451. borderColor: "#B78CFF",
  1452. backgroundColor: "#fff",
  1453. },
  1454. itemStyle: {
  1455. color: {
  1456. x: 0,
  1457. y: 0,
  1458. x2: 0,
  1459. y2: 1,
  1460. colorStops: [
  1461. {
  1462. offset: 0,
  1463. color: "#B78CFF", // 0% 处的颜色
  1464. },
  1465. {
  1466. offset: 1,
  1467. color: "#092351", // 100% 处的颜色
  1468. },
  1469. ],
  1470. },
  1471. },
  1472. },
  1473. {
  1474. type: "bar",
  1475. name: "已完成再评项目数",
  1476. barGap: "600%",
  1477. barWidth: 4,
  1478. data: that.riskData1.y4,
  1479. label: {
  1480. show: true,
  1481. position: "top",
  1482. formatter: " ",
  1483. width: 6,
  1484. height: 6,
  1485. borderRadius: 50,
  1486. borderWidth: 6,
  1487. borderColor: "#FFE036",
  1488. backgroundColor: "#fff",
  1489. },
  1490. itemStyle: {
  1491. color: {
  1492. x: 0,
  1493. y: 0,
  1494. x2: 0,
  1495. y2: 1,
  1496. colorStops: [
  1497. {
  1498. offset: 0,
  1499. color: "#FFE036", // 0% 处的颜色
  1500. },
  1501. {
  1502. offset: 1,
  1503. color: "#092351", // 100% 处的颜色
  1504. },
  1505. ],
  1506. },
  1507. },
  1508. },
  1509. {
  1510. type: "bar",
  1511. name: "再评达标项目数",
  1512. barGap: "600%",
  1513. barWidth: 4,
  1514. data: that.riskData1.y5,
  1515. label: {
  1516. show: true,
  1517. position: "top",
  1518. formatter: " ",
  1519. width: 6,
  1520. height: 6,
  1521. borderRadius: 50,
  1522. borderWidth: 6,
  1523. borderColor: "#7784FF",
  1524. backgroundColor: "#fff",
  1525. },
  1526. itemStyle: {
  1527. color: {
  1528. x: 0,
  1529. y: 0,
  1530. x2: 0,
  1531. y2: 1,
  1532. colorStops: [
  1533. {
  1534. offset: 0,
  1535. color: "#7784FF", // 0% 处的颜色
  1536. },
  1537. {
  1538. offset: 1,
  1539. color: "#092351", // 100% 处的颜色
  1540. },
  1541. ],
  1542. },
  1543. },
  1544. },
  1545. ],
  1546. };
  1547. that.right4Chart.setOption(option);
  1548. tools.loopShowTooltip(that.right4Chart, option, {
  1549. interval: 2000,
  1550. loopSeries: true,
  1551. });
  1552. },
  1553. clickItem (index) {
  1554. const angle = 360 / this.investData.investList.length;
  1555. this.witchs = index;
  1556. this.inner = index;
  1557. this.innerDeg = this.witchs * angle;
  1558. this.lpRotate();
  1559. },
  1560. lpRotate () {
  1561. const angle = 360 / this.investData.investList.length;
  1562. clearInterval(this.timer);
  1563. this.timer = setInterval(() => {
  1564. this.inner++;
  1565. this.topIndex++;
  1566. this.topIndex = this.topIndex % 8;
  1567. this.witchs = this.inner % this.investData.investList.length;
  1568. this.innerDeg = this.inner * angle;
  1569. // 项目阶段分析弹窗
  1570. if (this.projectNum < 7) {
  1571. this.projectNum = this.projectNum + 1
  1572. } else {
  1573. this.projectNum = 0
  1574. }
  1575. }, 2000);
  1576. },
  1577. filterLpData () {
  1578. const angle = 360 / this.investData.investList.length;
  1579. for (let i in this.investData.investList) {
  1580. this.investData.investList[i].deg = i * angle;
  1581. this.$set(this.investData.investList, i, {
  1582. ...this.investData.investList[i],
  1583. deg: i * angle,
  1584. });
  1585. }
  1586. },
  1587. // 4秒定时器
  1588. time4s () {
  1589. let that = this;
  1590. // 4秒定时器
  1591. this.time1 = setInterval(() => {
  1592. that.industryProportion == 1
  1593. ? (that.industryProportion = 2)
  1594. : (that.industryProportion = 1);
  1595. that.leftEcharts1.dispose();
  1596. that.leftEcharts2.dispose();
  1597. that.leftEcharts3.dispose();
  1598. that.leftEcharts4.dispose();
  1599. that.leftEcharts1Fun();
  1600. that.leftEcharts2Fun();
  1601. that.leftEcharts3Fun();
  1602. that.leftEcharts4Fun();
  1603. }, 4000);
  1604. },
  1605. // 针对投前产业布局分析的定时器
  1606. timeNs () {
  1607. let that = this;
  1608. this.time2 = setInterval(() => {
  1609. if (that.industryLayout < 3) {
  1610. that.industryLayout = that.industryLayout + 1;
  1611. } else {
  1612. that.industryLayout = 0;
  1613. }
  1614. this.time2 && clearInterval(this.time2);
  1615. this.timeNs();
  1616. that.leftEcharts5.dispose();
  1617. that.leftEcharts5Fun();
  1618. }, left1[that.industryLayout].length * 2000);
  1619. },
  1620. // 主辅业占比点击方法
  1621. industryProportionChange (e) {
  1622. let that = this;
  1623. this.industryProportion = e;
  1624. this.time1 && clearInterval(this.time1);
  1625. that.leftEcharts1.dispose();
  1626. that.leftEcharts2.dispose();
  1627. that.leftEcharts3.dispose();
  1628. that.leftEcharts4.dispose();
  1629. that.leftEcharts1Fun();
  1630. that.leftEcharts2Fun();
  1631. that.leftEcharts3Fun();
  1632. that.leftEcharts4Fun();
  1633. this.time4s();
  1634. },
  1635. // 产业布局分析点击方法
  1636. industryLayoutChange (e) {
  1637. this.industryLayout = e;
  1638. this.time2 && clearInterval(this.time2);
  1639. this.leftEcharts5.dispose();
  1640. this.timeNs();
  1641. this.leftEcharts5Fun();
  1642. },
  1643. yuanChange (value) {
  1644. return Number((value / 100000000).toFixed(2));
  1645. },
  1646. // 逢三折断
  1647. numFormat (value) {
  1648. if (!value) return "0";
  1649. // var intPart = Number(value).toFixed(0) // 获取整数部分
  1650. var intPart = parseInt(value); // 获取整数部分
  1651. var intPartFormat = intPart
  1652. .toString()
  1653. .replace(/(\d)(?=(?:\d{3})+$)/g, "$1,"); // 将整数部分逢三一断
  1654. var floatPart = ".00"; // 预定义小数部分
  1655. var value2Array = value.toString().split(".");
  1656. // =2表示数据有小数位
  1657. if (value2Array.length === 2) {
  1658. floatPart = value2Array[1].toString(); // 拿到小数部分
  1659. if (floatPart.length === 1) {
  1660. // 补0
  1661. return intPartFormat + "." + floatPart + "0";
  1662. } else {
  1663. floatPart = floatPart.slice(0, 2);
  1664. return intPartFormat + "." + floatPart;
  1665. }
  1666. } else {
  1667. return intPartFormat;
  1668. }
  1669. },
  1670. leftEcharts1Fun () {
  1671. let that = this;
  1672. this.leftEcharts1 = echarts.init(this.$refs["leftEcharts1"]);
  1673. option = {
  1674. title: {
  1675. text: that.industryProportion == 1 ? "94.4%" : "46.62%",
  1676. x: "center",
  1677. y: "center",
  1678. textStyle: {
  1679. fontWeight: "normal",
  1680. color: "#68BDFF",
  1681. fontSize: "20",
  1682. },
  1683. },
  1684. color: ["#68BDFF", "#254F7F"],
  1685. series: [
  1686. {
  1687. name: "Line 1",
  1688. type: "pie",
  1689. clockWise: true,
  1690. radius: ["80%", "100%"],
  1691. itemStyle: {
  1692. normal: {
  1693. label: {
  1694. show: false,
  1695. },
  1696. labelLine: {
  1697. show: false,
  1698. },
  1699. },
  1700. },
  1701. hoverAnimation: false,
  1702. data: [
  1703. {
  1704. value: 80,
  1705. name: "01",
  1706. itemStyle: {
  1707. normal: {
  1708. label: {
  1709. show: false,
  1710. },
  1711. labelLine: {
  1712. show: false,
  1713. },
  1714. },
  1715. },
  1716. },
  1717. {
  1718. name: "02",
  1719. value: 20,
  1720. },
  1721. ],
  1722. },
  1723. ],
  1724. };
  1725. //轮播
  1726. // tools.loopShowTooltip(leftEcharts1, option, {
  1727. // interval: 2000,
  1728. // loopSeries: true,
  1729. // });
  1730. //注册
  1731. that.leftEcharts1.setOption(option);
  1732. },
  1733. leftEcharts2Fun () {
  1734. let that = this;
  1735. this.leftEcharts2 = echarts.init(this.$refs["leftEcharts2"]);
  1736. let nameList = ["a"];
  1737. let valueList = that.industryProportion == 1 ? [1287.5] : [635.84];
  1738. let total = 1363.88; // 数据总数
  1739. var category = nameList.map((item, index) => {
  1740. return {
  1741. value: valueList[index],
  1742. itemStyle: {
  1743. color: new echarts.graphic.LinearGradient(
  1744. 1,
  1745. 0,
  1746. 0,
  1747. 1,
  1748. [
  1749. {
  1750. offset: 0,
  1751. color: "#40A9FF50",
  1752. },
  1753. {
  1754. offset: 1,
  1755. color: "#40A9FF",
  1756. },
  1757. ],
  1758. false
  1759. ),
  1760. },
  1761. };
  1762. });
  1763. var totalList = [];
  1764. var totalBorderList = [];
  1765. nameList.map((item, index) => {
  1766. totalList.push({
  1767. value: total,
  1768. itemStyle: {
  1769. color: "rgba(51, 147, 236, 0.29)",
  1770. },
  1771. });
  1772. totalBorderList.push({
  1773. value: total,
  1774. itemStyle: {
  1775. borderColor: "rgba(51, 147, 236, 0.29)",
  1776. color: "transparent",
  1777. },
  1778. });
  1779. });
  1780. var datas = [];
  1781. category.forEach((value) => {
  1782. datas.push(value.value);
  1783. });
  1784. option = {
  1785. // backgroundColor: 'rgb(231,238,249)',
  1786. xAxis: {
  1787. max: total,
  1788. splitLine: {
  1789. show: false,
  1790. },
  1791. axisLine: {
  1792. show: false,
  1793. },
  1794. axisLabel: {
  1795. show: false,
  1796. },
  1797. axisTick: {
  1798. show: false,
  1799. },
  1800. },
  1801. grid: {
  1802. left: "0%",
  1803. top: "15%", // 设置条形图的边距
  1804. right: "15%",
  1805. bottom: "5%",
  1806. },
  1807. yAxis: [
  1808. {
  1809. type: "category",
  1810. inverse: false,
  1811. data: nameList,
  1812. axisLine: {
  1813. show: false,
  1814. },
  1815. axisTick: {
  1816. show: false,
  1817. },
  1818. axisLabel: {
  1819. show: false,
  1820. },
  1821. },
  1822. ],
  1823. series: [
  1824. {
  1825. // 内
  1826. type: "bar",
  1827. barWidth: 16,
  1828. barGap: "20%",
  1829. silent: true,
  1830. // label: {
  1831. // normal: {
  1832. // formatter: (item) => {
  1833. // return `${item['name']}:${item['value']} `;
  1834. // },
  1835. // textStyle: {
  1836. // color: 'rgba(105, 120, 136, 1)',
  1837. // fontSize: 14,
  1838. // },
  1839. // position: [0, '-25px'],
  1840. // show: true,
  1841. // },
  1842. // },
  1843. data: category,
  1844. z: 1,
  1845. itemStyle: {
  1846. normal: {
  1847. color: new echarts.graphic.LinearGradient(
  1848. 1,
  1849. 0,
  1850. 0,
  1851. 1,
  1852. [
  1853. {
  1854. offset: 0,
  1855. color: "rgba(81, 193, 156, 1)",
  1856. },
  1857. {
  1858. offset: 1,
  1859. color: "rgba(234, 177, 100, 1)",
  1860. },
  1861. ],
  1862. false
  1863. ),
  1864. },
  1865. },
  1866. animationEasing: "elasticOut",
  1867. },
  1868. {
  1869. // 分隔
  1870. type: "pictorialBar",
  1871. itemStyle: {
  1872. normal: {
  1873. color: "#143362",
  1874. },
  1875. },
  1876. symbolRepeat: "fixed",
  1877. symbolMargin: 8,
  1878. symbol: "rect",
  1879. symbolClip: false,
  1880. symbolSize: [4, 20],
  1881. symbolPosition: "start",
  1882. symbolOffset: [0, -2],
  1883. symbolBoundingData: total,
  1884. data: [total, total, total, total],
  1885. z: 2,
  1886. animationEasing: "elasticOut",
  1887. },
  1888. {
  1889. // label
  1890. type: "pictorialBar",
  1891. symbolBoundingData: total,
  1892. itemStyle: {
  1893. normal: {
  1894. color: "none",
  1895. },
  1896. },
  1897. label: {
  1898. normal: {
  1899. formatter: (params) => {
  1900. var text;
  1901. text = `${((params["data"] * 100) / total).toFixed(2)}亿`;
  1902. return text;
  1903. },
  1904. textStyle: {
  1905. // 图列内容样式
  1906. fontSize: "20",
  1907. fontWeight: 800,
  1908. },
  1909. position: "right",
  1910. offset: [0, -3],
  1911. distance: 10, // 向右偏移位置
  1912. show: true,
  1913. color: "#68BDFF",
  1914. },
  1915. },
  1916. data: datas,
  1917. z: 0,
  1918. },
  1919. {
  1920. name: "外框",
  1921. type: "bar",
  1922. barGap: "-130%", // 设置外框粗细
  1923. data: totalBorderList,
  1924. barWidth: 26,
  1925. itemStyle: {
  1926. normal: {
  1927. // barBorderRadius: [5, 5, 5, 5],
  1928. borderWidth: 1, // 边框宽度
  1929. borderColor: "rgb(51, 147, 236)", // 边框色
  1930. color: "rgb(231,238,249)",
  1931. },
  1932. },
  1933. z: 0,
  1934. },
  1935. ],
  1936. };
  1937. //轮播
  1938. // tools.loopShowTooltip(leftEcharts1, option, {
  1939. // interval: 2000,
  1940. // loopSeries: true,
  1941. // });
  1942. //注册
  1943. that.leftEcharts2.setOption(option);
  1944. },
  1945. leftEcharts3Fun () {
  1946. let that = this;
  1947. this.leftEcharts3 = echarts.init(this.$refs["leftEcharts3"]);
  1948. option = {
  1949. title: {
  1950. text: that.industryProportion == 1 ? "5.6%" : "53.38%",
  1951. x: "center",
  1952. y: "center",
  1953. textStyle: {
  1954. fontWeight: "normal",
  1955. color: "#68BDFF",
  1956. fontSize: "20",
  1957. },
  1958. },
  1959. color: ["#5BDCC8", "#254F7F"],
  1960. series: [
  1961. {
  1962. name: "Line 1",
  1963. type: "pie",
  1964. clockWise: true,
  1965. radius: ["80%", "100%"],
  1966. itemStyle: {
  1967. normal: {
  1968. label: {
  1969. show: false,
  1970. },
  1971. labelLine: {
  1972. show: false,
  1973. },
  1974. },
  1975. },
  1976. hoverAnimation: false,
  1977. data: [
  1978. {
  1979. value: 80,
  1980. name: "01",
  1981. itemStyle: {
  1982. normal: {
  1983. label: {
  1984. show: false,
  1985. },
  1986. labelLine: {
  1987. show: false,
  1988. },
  1989. },
  1990. },
  1991. },
  1992. {
  1993. name: "02",
  1994. value: 20,
  1995. },
  1996. ],
  1997. },
  1998. ],
  1999. };
  2000. //轮播
  2001. // tools.loopShowTooltip(leftEcharts1, option, {
  2002. // interval: 2000,
  2003. // loopSeries: true,
  2004. // });
  2005. //注册
  2006. that.leftEcharts3.setOption(option);
  2007. },
  2008. leftEcharts4Fun () {
  2009. let that = this;
  2010. this.leftEcharts4 = echarts.init(this.$refs["leftEcharts4"]);
  2011. let nameList = ["a"];
  2012. let valueList = that.industryProportion == 1 ? [76.38] : [728.04];
  2013. let total = 1363.88; // 数据总数
  2014. var category = nameList.map((item, index) => {
  2015. return {
  2016. value: valueList[index],
  2017. itemStyle: {
  2018. color: new echarts.graphic.LinearGradient(
  2019. 1,
  2020. 0,
  2021. 0,
  2022. 1,
  2023. [
  2024. {
  2025. offset: 0,
  2026. color: "#5BDCC850",
  2027. },
  2028. {
  2029. offset: 1,
  2030. color: "#5BDCC8",
  2031. },
  2032. ],
  2033. false
  2034. ),
  2035. },
  2036. };
  2037. });
  2038. var totalList = [];
  2039. var totalBorderList = [];
  2040. nameList.map((item, index) => {
  2041. totalList.push({
  2042. value: total,
  2043. itemStyle: {
  2044. color: "rgba(51, 147, 236, 0.29)",
  2045. },
  2046. });
  2047. totalBorderList.push({
  2048. value: total,
  2049. itemStyle: {
  2050. borderColor: "rgba(51, 147, 236, 0.29)",
  2051. color: "transparent",
  2052. },
  2053. });
  2054. });
  2055. var datas = [];
  2056. category.forEach((value) => {
  2057. datas.push(value.value);
  2058. });
  2059. option = {
  2060. // backgroundColor: 'rgb(231,238,249)',
  2061. xAxis: {
  2062. max: total,
  2063. splitLine: {
  2064. show: false,
  2065. },
  2066. axisLine: {
  2067. show: false,
  2068. },
  2069. axisLabel: {
  2070. show: false,
  2071. },
  2072. axisTick: {
  2073. show: false,
  2074. },
  2075. },
  2076. grid: {
  2077. left: "0%",
  2078. top: "15%", // 设置条形图的边距
  2079. right: "15%",
  2080. bottom: "5%",
  2081. },
  2082. yAxis: [
  2083. {
  2084. type: "category",
  2085. inverse: false,
  2086. data: nameList,
  2087. axisLine: {
  2088. show: false,
  2089. },
  2090. axisTick: {
  2091. show: false,
  2092. },
  2093. axisLabel: {
  2094. show: false,
  2095. },
  2096. },
  2097. ],
  2098. series: [
  2099. {
  2100. // 内
  2101. type: "bar",
  2102. barWidth: 16,
  2103. barGap: "20%",
  2104. silent: true,
  2105. // label: {
  2106. // normal: {
  2107. // formatter: (item) => {
  2108. // return `${item['name']}:${item['value']} `;
  2109. // },
  2110. // textStyle: {
  2111. // color: 'rgba(105, 120, 136, 1)',
  2112. // fontSize: 14,
  2113. // },
  2114. // position: [0, '-25px'],
  2115. // show: true,
  2116. // },
  2117. // },
  2118. data: category,
  2119. z: 1,
  2120. itemStyle: {
  2121. normal: {
  2122. color: new echarts.graphic.LinearGradient(
  2123. 1,
  2124. 0,
  2125. 0,
  2126. 1,
  2127. [
  2128. {
  2129. offset: 0,
  2130. color: "rgba(81, 193, 156, 1)",
  2131. },
  2132. {
  2133. offset: 1,
  2134. color: "rgba(234, 177, 100, 1)",
  2135. },
  2136. ],
  2137. false
  2138. ),
  2139. },
  2140. },
  2141. animationEasing: "elasticOut",
  2142. },
  2143. {
  2144. // 分隔
  2145. type: "pictorialBar",
  2146. itemStyle: {
  2147. normal: {
  2148. color: "#143362",
  2149. },
  2150. },
  2151. symbolRepeat: "fixed",
  2152. symbolMargin: 8,
  2153. symbol: "rect",
  2154. symbolClip: false,
  2155. symbolSize: [4, 20],
  2156. symbolPosition: "start",
  2157. symbolOffset: [0, -2],
  2158. symbolBoundingData: total,
  2159. data: [total, total, total, total],
  2160. z: 2,
  2161. animationEasing: "elasticOut",
  2162. },
  2163. {
  2164. // label
  2165. type: "pictorialBar",
  2166. symbolBoundingData: total,
  2167. itemStyle: {
  2168. normal: {
  2169. color: "none",
  2170. },
  2171. },
  2172. label: {
  2173. normal: {
  2174. formatter: (params) => {
  2175. var text;
  2176. text = `${((params["data"] * 100) / total).toFixed(2)}亿`;
  2177. return text;
  2178. },
  2179. textStyle: {
  2180. // 图列内容样式
  2181. fontSize: "20",
  2182. fontWeight: 800,
  2183. },
  2184. position: "right",
  2185. offset: [0, -3],
  2186. distance: 10, // 向右偏移位置
  2187. show: true,
  2188. color: "#68BDFF",
  2189. },
  2190. },
  2191. data: datas,
  2192. z: 0,
  2193. },
  2194. {
  2195. name: "外框",
  2196. type: "bar",
  2197. barGap: "-130%", // 设置外框粗细
  2198. data: totalBorderList,
  2199. barWidth: 26,
  2200. itemStyle: {
  2201. normal: {
  2202. // barBorderRadius: [5, 5, 5, 5],
  2203. borderWidth: 1, // 边框宽度
  2204. borderColor: "rgb(51, 147, 236)", // 边框色
  2205. color: "rgb(231,238,249)",
  2206. },
  2207. },
  2208. z: 0,
  2209. },
  2210. ],
  2211. };
  2212. //轮播
  2213. // tools.loopShowTooltip(leftEcharts1, option, {
  2214. // interval: 2000,
  2215. // loopSeries: true,
  2216. // });
  2217. //注册
  2218. that.leftEcharts4.setOption(option);
  2219. },
  2220. leftEcharts5Fun () {
  2221. let that = this;
  2222. this.leftEcharts5 = echarts.init(this.$refs["leftEcharts5"]);
  2223. let dataList = [];
  2224. left1[that.industryLayout].forEach((item, index) => {
  2225. dataList[index] = {
  2226. value: item.y,
  2227. name: item.name,
  2228. itemStyle: {
  2229. normal: {
  2230. color: new echarts.graphic.LinearGradient(1, 0, 0, 1, [
  2231. {
  2232. offset: 0,
  2233. color: commonColor2[index], //顶部颜色
  2234. },
  2235. {
  2236. offset: 1,
  2237. color: commonColor[index], // 底部颜色
  2238. },
  2239. ]),
  2240. borderColor: commonColor[index],
  2241. borderWidth: 3,
  2242. },
  2243. },
  2244. };
  2245. });
  2246. let option = {
  2247. tooltip: {
  2248. trigger: "item",
  2249. formatter: function (e) {
  2250. return `<span style="display:inline-block;margin-right:15px;border-radius:10px;width:20px;height:20px;background-color:${e.borderColor
  2251. };"></span>${e.name} ${e.percent}%<br>${e.value}亿 ${left1[that.industryLayout][e.seriesIndex].num
  2252. }个`;
  2253. },
  2254. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  2255. textStyle: {
  2256. color: "#fff",
  2257. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  2258. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  2259. fontSize: "28", // 文字字体大小
  2260. },
  2261. },
  2262. legend: {
  2263. top: "center",
  2264. orient: "vertical",
  2265. left: "65%",
  2266. textStyle: {
  2267. color: "#fff",
  2268. fontSize: 20,
  2269. padding: [0, 20],
  2270. },
  2271. },
  2272. graphic: {
  2273. elements: [
  2274. {
  2275. type: "image", //需要填充图片,配置image,如果不需要图片可以配置其他的, text, circle, sector, ring, polygon, polyline, rect, line, bezierCurve, arc, group,
  2276. style: {
  2277. image: "./img/whiteCircle.png", //这里添加图片地址
  2278. width: 80,
  2279. height: 80,
  2280. },
  2281. left: "37.7%", //
  2282. top: "middle", //配置图片居中
  2283. },
  2284. ],
  2285. },
  2286. series: [
  2287. {
  2288. name: "",
  2289. type: "pie",
  2290. radius: ["20%", "90%"],
  2291. center: ["41%", "50%"],
  2292. labelLine: {
  2293. normal: {
  2294. lineStyle: {
  2295. width: 1,
  2296. },
  2297. },
  2298. },
  2299. label: {
  2300. normal: {
  2301. show: false,
  2302. textStyle: {
  2303. fontSize: 28,
  2304. color: "#fff",
  2305. },
  2306. },
  2307. },
  2308. roseType: "area",
  2309. data: dataList,
  2310. },
  2311. {
  2312. tooltip: {
  2313. show: false,
  2314. },
  2315. type: "pie",
  2316. radius: ["90%", "92%"],
  2317. center: ["41%", "50%"],
  2318. hoverAnimation: false,
  2319. name: "",
  2320. data: [
  2321. {
  2322. name: "",
  2323. value: 0,
  2324. itemStyle: {
  2325. normal: {
  2326. color: "#345189",
  2327. },
  2328. },
  2329. },
  2330. ],
  2331. },
  2332. ],
  2333. };
  2334. //轮播
  2335. tools.loopShowTooltip(that.leftEcharts5, option, {
  2336. interval: 2000,
  2337. loopSeries: true,
  2338. });
  2339. //注册
  2340. that.leftEcharts5.setOption(option);
  2341. },
  2342. leftEcharts6Fun () {
  2343. let that = this;
  2344. this.leftEcharts6 = echarts.init(this.$refs["leftEcharts6"]);
  2345. var dataArr = 44;
  2346. var colorSet = {
  2347. color: "#22B95E",
  2348. };
  2349. var color1 = {
  2350. type: "linear",
  2351. x: 0,
  2352. y: 0,
  2353. x2: 1,
  2354. y2: 1,
  2355. colorStops: [
  2356. {
  2357. offset: 0,
  2358. color: "rgba(255,255,255,0.1)",
  2359. },
  2360. {
  2361. offset: 1,
  2362. color: "rgba(255,255,255,0.3)",
  2363. },
  2364. ],
  2365. global: false,
  2366. };
  2367. var color2 = {
  2368. type: "linear",
  2369. x: 0,
  2370. y: 0,
  2371. x2: 1,
  2372. y2: 1,
  2373. colorStops: [
  2374. {
  2375. offset: 0,
  2376. color: "#30DBBA",
  2377. },
  2378. {
  2379. offset: 1,
  2380. color: "#2DE696",
  2381. },
  2382. ],
  2383. global: false,
  2384. };
  2385. option = {
  2386. tooltip: {
  2387. formatter: "{a} <br/>{b} : {c}%",
  2388. },
  2389. series: [
  2390. {
  2391. name: "内部进度条",
  2392. type: "gauge",
  2393. // center: ['20%', '50%'],
  2394. radius: "50%",
  2395. splitNumber: 10,
  2396. axisLine: {
  2397. lineStyle: {
  2398. color: [
  2399. [dataArr / 100, "rgba(0,0,0,0)"],
  2400. [1, "rgba(0,0,0,0)"],
  2401. ],
  2402. width: 1,
  2403. },
  2404. },
  2405. axisLabel: {
  2406. show: false,
  2407. },
  2408. axisTick: {
  2409. show: false,
  2410. },
  2411. splitLine: {
  2412. show: false,
  2413. },
  2414. itemStyle: {
  2415. color: "#ffffff",
  2416. },
  2417. detail: {
  2418. formatter: function (value) {
  2419. if (value !== 0) {
  2420. var num = Math.round(value);
  2421. return parseInt(num).toFixed(0) + "%";
  2422. } else {
  2423. return 0;
  2424. }
  2425. },
  2426. offsetCenter: [0, 117],
  2427. textStyle: {
  2428. padding: [0, 0, 0, 0],
  2429. fontSize: 60,
  2430. color: "#58F7DF",
  2431. },
  2432. },
  2433. title: {
  2434. //标题
  2435. show: true,
  2436. offsetCenter: [0, 220], // x, y,单位px
  2437. textStyle: {
  2438. color: "#40A9FF",
  2439. fontSize: 34, //表盘上的标题文字大小
  2440. fontWeight: 400,
  2441. fontFamily: "MicrosoftYaHei",
  2442. },
  2443. },
  2444. data: [
  2445. {
  2446. name: "总额度:1,323.85亿",
  2447. value: dataArr,
  2448. itemStyle: {
  2449. fontSize: "50", //y轴上方单位的大小
  2450. color: "#FFF666",
  2451. fontFamily: "MicrosoftYaHei",
  2452. },
  2453. },
  2454. ],
  2455. pointer: {
  2456. show: true,
  2457. length: "100%",
  2458. radius: "20%",
  2459. width: 3, //指针粗细
  2460. },
  2461. animationDuration: 4000,
  2462. },
  2463. {
  2464. name: "内部阴影",
  2465. type: "gauge",
  2466. radius: "75%",
  2467. splitNumber: 10,
  2468. axisLine: {
  2469. lineStyle: {
  2470. color: [
  2471. [
  2472. dataArr / 100,
  2473. new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  2474. {
  2475. offset: 0,
  2476. color: "#081947",
  2477. },
  2478. {
  2479. offset: 0.5,
  2480. color: "#5DF5A9",
  2481. },
  2482. {
  2483. offset: 1,
  2484. color: "#F6F16A",
  2485. },
  2486. ]),
  2487. ],
  2488. [1, "#0E4889"],
  2489. ],
  2490. width: 70,
  2491. },
  2492. },
  2493. axisLabel: {
  2494. show: false,
  2495. },
  2496. axisTick: {
  2497. show: false,
  2498. },
  2499. splitLine: {
  2500. show: false,
  2501. },
  2502. itemStyle: {
  2503. show: false,
  2504. },
  2505. },
  2506. {
  2507. name: "外部刻度",
  2508. type: "gauge",
  2509. // center: ['20%', '50%'],
  2510. radius: "90%",
  2511. min: 0, //最小刻度
  2512. max: 100, //最大刻度
  2513. splitNumber: 5, //刻度数量
  2514. startAngle: 225,
  2515. endAngle: -45,
  2516. axisLine: {
  2517. show: true,
  2518. lineStyle: {
  2519. width: 1,
  2520. color: [[1, "rgba(0,0,0,0)"]],
  2521. },
  2522. }, //仪表盘轴线
  2523. axisLabel: {
  2524. show: false,
  2525. color: "#ffffff",
  2526. fontSize: 28,
  2527. fontFamily: "SourceHanSansSC-Regular",
  2528. fontWeight: "bold",
  2529. // position: "top",
  2530. distance: -45,
  2531. formatter: function (v) {
  2532. switch (v + "") {
  2533. case "0":
  2534. return "0";
  2535. case "10":
  2536. return "10";
  2537. case "20":
  2538. return "20";
  2539. case "30":
  2540. return "30";
  2541. case "40":
  2542. return "40";
  2543. case "50":
  2544. return "50";
  2545. case "60":
  2546. return "60";
  2547. case "70":
  2548. return "70";
  2549. case "80":
  2550. return "80";
  2551. case "90":
  2552. return "90";
  2553. case "100":
  2554. return "100";
  2555. }
  2556. },
  2557. }, //刻度标签。
  2558. axisTick: {
  2559. show: true,
  2560. splitNumber: 10,
  2561. lineStyle: {
  2562. color: "#3798D7", //用颜色渐变函数不起作用
  2563. width: 1,
  2564. },
  2565. length: -6,
  2566. }, //刻度样式
  2567. splitLine: {
  2568. show: true,
  2569. length: -12,
  2570. lineStyle: {
  2571. color: "#3798D7", //用颜色渐变函数不起作用
  2572. },
  2573. }, //分隔线样式
  2574. detail: {
  2575. show: false,
  2576. },
  2577. },
  2578. {
  2579. //指针上的圆
  2580. type: "pie",
  2581. tooltip: {
  2582. show: false,
  2583. },
  2584. hoverAnimation: false,
  2585. legendHoverLink: false,
  2586. radius: ["0%", "4%"],
  2587. center: ["50%", "50%"],
  2588. label: {
  2589. normal: {
  2590. show: false,
  2591. },
  2592. },
  2593. labelLine: {
  2594. normal: {
  2595. show: false,
  2596. },
  2597. },
  2598. data: [
  2599. {
  2600. value: 120,
  2601. itemStyle: {
  2602. normal: {
  2603. color: "#ffffff",
  2604. },
  2605. },
  2606. },
  2607. ],
  2608. },
  2609. ],
  2610. };
  2611. //轮播
  2612. // tools.loopShowTooltip(leftEcharts1, option, {
  2613. // interval: 2000,
  2614. // loopSeries: true,
  2615. // });
  2616. //注册
  2617. that.leftEcharts6.setOption(option);
  2618. },
  2619. leftEcharts7Fun () {
  2620. let that = this;
  2621. this.leftEcharts7 = echarts.init(this.$refs["leftEcharts7"]);
  2622. let option = {
  2623. title: {
  2624. text: "固定资产进度分布",
  2625. textStyle: {
  2626. color: "#fff",
  2627. fontSize: 28,
  2628. fontWeight: 500,
  2629. fontFamily: "Microsoft YaHei",
  2630. },
  2631. top: "20",
  2632. left: "220",
  2633. },
  2634. textStyle: {
  2635. color: "#fff",
  2636. },
  2637. tooltip: {
  2638. show: false,
  2639. trigger: "axis",
  2640. formatter: function (params) {
  2641. var tip =
  2642. params[0].axisValue +
  2643. "<br/>" +
  2644. params[0].marker +
  2645. params[0].data[1] +
  2646. ":" +
  2647. params[0].data[2] +
  2648. "个," +
  2649. params[0].data[3] +
  2650. "亿元" +
  2651. "<br/>" +
  2652. params[1].marker +
  2653. params[1].data[1] +
  2654. ":" +
  2655. params[1].data[2] +
  2656. "个," +
  2657. params[1].data[3] +
  2658. "亿元";
  2659. return tip;
  2660. },
  2661. textStyle: {
  2662. color: "#ffffff", // 文字的颜色
  2663. fontSize: "20", // 文字字体大小
  2664. fontFamily: "Microsoft YaHei",
  2665. },
  2666. axisPointer: {
  2667. // lineStyle: {
  2668. // type: 'dashed',
  2669. // width: 2,
  2670. // color: 'rgba(255,255,255,0.6)'
  2671. // },
  2672. animation: false,
  2673. },
  2674. },
  2675. grid: {
  2676. top: "0%",
  2677. right: "5%",
  2678. left: "15%",
  2679. bottom: "-10%",
  2680. },
  2681. yAxis: {
  2682. data: ["备案", "特别监管"],
  2683. splitLine: {
  2684. show: false,
  2685. lineStyle: {
  2686. color: "#68b4dd66",
  2687. type: "dashed",
  2688. },
  2689. },
  2690. axisLine: {
  2691. show: false,
  2692. },
  2693. axisLabel: {
  2694. show: true,
  2695. formatter: "{value}",
  2696. textStyle: {
  2697. color: function (data) {
  2698. if (data == "特别监管") {
  2699. return "#40A9FF";
  2700. } else if (data == "备案") {
  2701. return "#5BDCC8";
  2702. }
  2703. },
  2704. fontSize: 20,
  2705. padding: [0, -10, 0, 0],
  2706. fontFamily: "Microsoft YaHei",
  2707. },
  2708. },
  2709. nameTextStyle: {
  2710. color: "#ebf8ac",
  2711. fontSize: 16,
  2712. fontFamily: "Microsoft YaHei",
  2713. },
  2714. },
  2715. xAxis: {
  2716. data: ["项目储备", "项目立项", "可研论证", "投资决策"],
  2717. axisLine: {
  2718. show: true, //隐藏X轴轴线
  2719. lineStyle: {
  2720. color: "red",
  2721. width: 1,
  2722. },
  2723. },
  2724. axisTick: {
  2725. show: false, //隐藏X轴刻度
  2726. },
  2727. axisLabel: {
  2728. show: true,
  2729. textStyle: {
  2730. color: "#fff", //X轴文字颜色
  2731. fontSize: 20,
  2732. padding: [-80, 0, 0, 0],
  2733. fontFamily: "Microsoft YaHei",
  2734. },
  2735. },
  2736. },
  2737. series: [
  2738. {
  2739. name: "特别监管",
  2740. type: "scatter",
  2741. symbol: "circle", //'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  2742. symbolSize: function (data) {
  2743. return Math.sqrt(data[2]) * 5;
  2744. },
  2745. // label: {
  2746. // emphasis: {
  2747. // show: true,
  2748. // formatter: function (param) {
  2749. // return param.data[2];
  2750. // },
  2751. // position: 'top'
  2752. // }
  2753. // },
  2754. itemStyle: {
  2755. normal: {
  2756. color: "#69c0ff",
  2757. },
  2758. },
  2759. // data: left13[0]
  2760. },
  2761. {
  2762. name: "备案",
  2763. type: "scatter",
  2764. symbol: "circle", //'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  2765. symbolSize: function (data) {
  2766. return Math.sqrt(data[2]) * 5;
  2767. },
  2768. // label: {
  2769. // emphasis: {
  2770. // show: true,
  2771. // formatter: function (param) {
  2772. // return param.data[2];
  2773. // },
  2774. // position: 'top'
  2775. // }
  2776. // },
  2777. itemStyle: {
  2778. normal: {
  2779. color: "#957DFF",
  2780. },
  2781. },
  2782. // data: left13[1]
  2783. },
  2784. ],
  2785. };
  2786. //轮播
  2787. // tools.loopShowTooltip(leftEcharts1, option, {
  2788. // interval: 2000,
  2789. // loopSeries: true,
  2790. // });
  2791. //注册
  2792. that.leftEcharts7.setOption(option);
  2793. },
  2794. leftEcharts8Fun () {
  2795. let that = this;
  2796. this.leftEcharts8 = echarts.init(this.$refs["leftEcharts8"]);
  2797. let option = {
  2798. title: {
  2799. text: "固定资产进度分布",
  2800. textStyle: {
  2801. color: "#fff",
  2802. fontSize: 28,
  2803. fontWeight: 500,
  2804. fontFamily: "Microsoft YaHei",
  2805. },
  2806. top: "20",
  2807. left: "220",
  2808. },
  2809. textStyle: {
  2810. color: "#fff",
  2811. },
  2812. tooltip: {
  2813. show: false,
  2814. trigger: "axis",
  2815. formatter: function (params) {
  2816. var tip =
  2817. params[0].axisValue +
  2818. "<br/>" +
  2819. params[0].marker +
  2820. params[0].data[1] +
  2821. ":" +
  2822. params[0].data[2] +
  2823. "个," +
  2824. params[0].data[3] +
  2825. "亿元" +
  2826. "<br/>" +
  2827. params[1].marker +
  2828. params[1].data[1] +
  2829. ":" +
  2830. params[1].data[2] +
  2831. "个," +
  2832. params[1].data[3] +
  2833. "亿元";
  2834. return tip;
  2835. },
  2836. textStyle: {
  2837. color: "#ffffff", // 文字的颜色
  2838. fontSize: "20", // 文字字体大小
  2839. fontFamily: "Microsoft YaHei",
  2840. },
  2841. axisPointer: {
  2842. // lineStyle: {
  2843. // type: 'dashed',
  2844. // width: 2,
  2845. // color: 'rgba(255,255,255,0.6)'
  2846. // },
  2847. animation: false,
  2848. },
  2849. },
  2850. grid: {
  2851. top: "0%",
  2852. right: "5%",
  2853. left: "15%",
  2854. bottom: "-10%",
  2855. },
  2856. yAxis: {
  2857. data: ["备案", "特别监管"],
  2858. splitLine: {
  2859. show: false,
  2860. lineStyle: {
  2861. color: "#68b4dd66",
  2862. type: "dashed",
  2863. },
  2864. },
  2865. axisLine: {
  2866. show: false,
  2867. },
  2868. axisLabel: {
  2869. show: false,
  2870. formatter: "{value}",
  2871. textStyle: {
  2872. color: "#fff",
  2873. fontSize: 20,
  2874. padding: [0, -10, 0, 0],
  2875. fontFamily: "Microsoft YaHei",
  2876. },
  2877. },
  2878. nameTextStyle: {
  2879. color: "#ebf8ac",
  2880. fontSize: 16,
  2881. fontFamily: "Microsoft YaHei",
  2882. },
  2883. },
  2884. xAxis: {
  2885. data: ["项目储备", "项目立项", "可研论证", "投资决策"],
  2886. axisLine: {
  2887. show: true, //隐藏X轴轴线
  2888. lineStyle: {
  2889. color: "red",
  2890. width: 1,
  2891. },
  2892. },
  2893. axisTick: {
  2894. show: false, //隐藏X轴刻度
  2895. },
  2896. axisLabel: {
  2897. show: true,
  2898. textStyle: {
  2899. color: "#fff", //X轴文字颜色
  2900. fontSize: 20,
  2901. padding: [-80, 0, 0, 0],
  2902. fontFamily: "Microsoft YaHei",
  2903. },
  2904. },
  2905. },
  2906. series: [
  2907. {
  2908. name: "特别监管",
  2909. type: "scatter",
  2910. symbol: "circle", //'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  2911. symbolSize: function (data) {
  2912. return Math.sqrt(data[2]) * 5;
  2913. },
  2914. // label: {
  2915. // emphasis: {
  2916. // show: true,
  2917. // formatter: function (param) {
  2918. // return param.data[2];
  2919. // },
  2920. // position: 'top'
  2921. // }
  2922. // },
  2923. itemStyle: {
  2924. normal: {
  2925. color: "#69c0ff",
  2926. },
  2927. },
  2928. // data: left13[0]
  2929. },
  2930. {
  2931. name: "备案",
  2932. type: "scatter",
  2933. symbol: "circle", //'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  2934. symbolSize: function (data) {
  2935. return Math.sqrt(data[2]) * 5;
  2936. },
  2937. // label: {
  2938. // emphasis: {
  2939. // show: true,
  2940. // formatter: function (param) {
  2941. // return param.data[2];
  2942. // },
  2943. // position: 'top'
  2944. // }
  2945. // },
  2946. itemStyle: {
  2947. normal: {
  2948. color: "#957DFF",
  2949. },
  2950. },
  2951. // data: left13[1]
  2952. },
  2953. ],
  2954. };
  2955. //轮播
  2956. // tools.loopShowTooltip(leftEcharts1, option, {
  2957. // interval: 2000,
  2958. // loopSeries: true,
  2959. // });
  2960. //注册
  2961. that.leftEcharts8.setOption(option);
  2962. },
  2963. shanxiEchartsFun () {
  2964. let that = this;
  2965. this.geoCoordMap = [];
  2966. /*获取地图数据*/
  2967. this.shanxiMap = echarts.init(this.$refs["shanxi"]);
  2968. // echarts.registerMap('china', china)
  2969. echarts.registerMap("china", shanxi);
  2970. // var mapFeatures = echarts.getMap('china').geoJson.features
  2971. // mapFeatures.forEach(v => {
  2972. // // 地区名称
  2973. // var name = v.properties.name
  2974. // // 地区经纬度
  2975. // this.geoCoordMap[name] = v.properties.cp
  2976. // data.push({ name: v.properties.name, value: v.properties.cp[0], value2: v.properties.cp[1] })
  2977. // })
  2978. var data = [
  2979. { name: "大同市", value: 6035, value2: 28 },
  2980. { name: "朔州市", value: 3361, value2: 13 },
  2981. { name: "忻州市", value: 7335, value2: 25 },
  2982. { name: "吕梁市", value: 10904, value2: 45 },
  2983. { name: "太原市", value: 25167, value2: 113 },
  2984. { name: "阳泉市", value: 2512, value2: 28 },
  2985. { name: "晋中市", value: 14857, value2: 52 },
  2986. { name: "临汾市", value: 13055, value2: 30 },
  2987. { name: "长治市", value: 10300, value2: 23 },
  2988. { name: "运城市", value: 4106, value2: 23 },
  2989. { name: "晋城市", value: 4543, value2: 31 },
  2990. ];
  2991. var geoCoordMap = {
  2992. 太原市: [112.53, 37.87],
  2993. 大同市: [113.3, 40.12],
  2994. 阳泉市: [113.57, 37.85],
  2995. 长治市: [113.08, 36.18],
  2996. 晋城市: [112.83, 35.52],
  2997. 朔州市: [112.43, 39.33],
  2998. 晋中市: [112.94, 37.4],
  2999. 运城市: [110.97, 35.03],
  3000. 忻州市: [112.53, 38.72],
  3001. 临汾市: [111.5, 36.08],
  3002. 吕梁市: [111.13, 37.52],
  3003. };
  3004. var convertData = function (data) {
  3005. var res = [];
  3006. for (var i = 0; i < data.length; i++) {
  3007. var geoCoord = geoCoordMap[data[i].name];
  3008. if (geoCoord) {
  3009. res.push({
  3010. name: data[i].name,
  3011. value: geoCoord.concat(data[i].value, data[i].value2),
  3012. });
  3013. }
  3014. }
  3015. return res;
  3016. };
  3017. var convertedData = [
  3018. convertData(data),
  3019. convertData(
  3020. data
  3021. .sort(function (a, b) {
  3022. return b.value - a.value;
  3023. })
  3024. .slice(0, 6)
  3025. ),
  3026. ];
  3027. data.sort(function (a, b) {
  3028. return a.value - b.value;
  3029. });
  3030. option = {
  3031. backgroundColor: "#404a5900",
  3032. animation: true,
  3033. animationDuration: 1000,
  3034. animationEasing: "cubicInOut",
  3035. animationDurationUpdate: 1000,
  3036. animationEasingUpdate: "cubicInOut",
  3037. geo: {
  3038. map: "china",
  3039. center: [112.53, 37.67],
  3040. zoom: 4.5,
  3041. label: {
  3042. emphasis: {
  3043. show: false,
  3044. },
  3045. },
  3046. roam: false,
  3047. itemStyle: {
  3048. normal: {
  3049. borderColor: "#7fb3ff",
  3050. borderWidth: 3,
  3051. areaColor: {
  3052. type: "radial",
  3053. x: 0.5,
  3054. y: 0.5,
  3055. r: 0.8,
  3056. colorStops: [
  3057. {
  3058. offset: 0,
  3059. color: "#468ff8", // 0% 处的颜色
  3060. },
  3061. {
  3062. offset: 1,
  3063. color: "#0a2c6d", // 100% 处的颜色
  3064. },
  3065. ],
  3066. globalCoord: false, // 缺省为 false
  3067. },
  3068. // shadowColor: 'rgba(128, 217, 248, 1)',
  3069. shadowColor: "#468ff8",
  3070. shadowOffsetX: -2,
  3071. shadowOffsetY: 2,
  3072. shadowBlur: 20,
  3073. },
  3074. emphasis: {
  3075. areaColor: {
  3076. colorStops: [
  3077. {
  3078. offset: 0,
  3079. color: "#3844aa", // 0% 处的颜色
  3080. },
  3081. {
  3082. offset: 1,
  3083. color: "#7284fc", // 100% 处的颜色
  3084. },
  3085. ],
  3086. },
  3087. borderColor: "#b3baff",
  3088. borderWidth: 5,
  3089. },
  3090. },
  3091. tooltip: {
  3092. trigger: "item",
  3093. className: "custom-tooltip-box",
  3094. confine: true, // 不超出当前表
  3095. formatter: (params, ticket, callback) => {
  3096. // 清空所有轮播
  3097. for (var k in geoCoordMap) {
  3098. that.shanxiMap.dispatchAction({
  3099. // type: 'geoUnSelect',
  3100. type: "downplay",
  3101. name: k,
  3102. geoIndex: 0,
  3103. });
  3104. that.shanxiMap.dispatchAction({
  3105. // type: 'geoUnSelect',
  3106. type: "downplay",
  3107. name: k,
  3108. seriesName: params.seriesName,
  3109. });
  3110. that.shanxiMap.dispatchAction({
  3111. // type: 'geoUnSelect',
  3112. type: "downplay",
  3113. name: k,
  3114. seriesName: "series\u00001",
  3115. });
  3116. }
  3117. that.shanxiMap.dispatchAction({
  3118. // type: 'geoSelect',
  3119. type: "highlight",
  3120. name: params.name,
  3121. geoIndex: 0,
  3122. });
  3123. that.shanxiMap.dispatchAction({
  3124. // type: 'geoSelect',
  3125. type: "highlight",
  3126. name: params.name,
  3127. seriesName: params.seriesName,
  3128. });
  3129. that.shanxiMap.dispatchAction({
  3130. // type: 'geoSelect',
  3131. type: "highlight",
  3132. name: params.name,
  3133. seriesName: "series\u00001",
  3134. });
  3135. return `<div class="bgTooltip" style="background: url('../img/shanxi/${params.name}.png') no-repeat center center;background-size: 100% 100%;font-size:36px">
  3136. <div class="flex items-center">
  3137. <img src="./img/yellowArrow.png" style="width: 12px;height: 22px;margin-right:10px" alt=""><span class="fb">${params.name}</span>
  3138. </div>
  3139. <div class="blueIcon flex items-center">项目数量:<span class="fb" style="color:#68BDFF;">${params.value[3]}<span style="font-size:20px" class="fn">个</span></span></div>
  3140. <div class="blueIcon flex items-center">投资总额:<span class="fb" style="color:#68BDFF">${params.value[2]}<span style="font-size:20px" class="fn">亿</span></span></div>
  3141. </div>`;
  3142. },
  3143. },
  3144. regions: [
  3145. {
  3146. name: "太原市",
  3147. value: 2000,
  3148. itemStyle: {
  3149. emphasis: {
  3150. borderColor: "#ffe036",
  3151. borderWidth: 5,
  3152. areaColor: {
  3153. type: "radial",
  3154. x: 0.5,
  3155. y: 0.5,
  3156. r: 0.8,
  3157. colorStops: [
  3158. {
  3159. offset: 0,
  3160. color: "#ffe036", // 0% 处的颜色
  3161. },
  3162. {
  3163. offset: 1,
  3164. color: "#7c732a", // 100% 处的颜色
  3165. },
  3166. ],
  3167. globalCoord: false, // 缺省为 false
  3168. },
  3169. },
  3170. },
  3171. },
  3172. {
  3173. name: "南海诸岛",
  3174. itemStyle: {
  3175. // 隐藏地图
  3176. normal: {
  3177. opacity: 0, // 为 0 时不绘制该图形
  3178. },
  3179. },
  3180. label: {
  3181. show: false, // 隐藏文字
  3182. },
  3183. },
  3184. ],
  3185. },
  3186. tooltip: {
  3187. trigger: "item",
  3188. className: "custom-tooltip-box",
  3189. confine: true, // 不超出当前表
  3190. formatter: (e) => {
  3191. console.log('走了这里了', e)
  3192. }
  3193. },
  3194. xAxis: {
  3195. type: "value",
  3196. scale: true,
  3197. position: "top",
  3198. boundaryGap: false,
  3199. splitLine: {
  3200. show: false,
  3201. },
  3202. axisLine: {
  3203. show: false,
  3204. },
  3205. axisTick: {
  3206. show: false,
  3207. },
  3208. axisLabel: {
  3209. margin: 2,
  3210. textStyle: {
  3211. color: "#aaa",
  3212. },
  3213. },
  3214. },
  3215. yAxis: {
  3216. type: "category",
  3217. nameGap: 16,
  3218. axisLine: {
  3219. show: false,
  3220. lineStyle: {
  3221. color: "#ddd",
  3222. },
  3223. },
  3224. axisTick: {
  3225. show: false,
  3226. lineStyle: {
  3227. color: "#ddd",
  3228. },
  3229. },
  3230. axisLabel: {
  3231. interval: 0,
  3232. textStyle: {
  3233. color: "#ddd",
  3234. },
  3235. },
  3236. data: categoryData,
  3237. },
  3238. series: [
  3239. {
  3240. type: "effectScatter",
  3241. colorBy: "data",
  3242. coordinateSystem: "geo",
  3243. data: convertedData[0],
  3244. symbolSize: function (val) {
  3245. return Math.max(val[2] / 500, 8);
  3246. },
  3247. showEffectOn: "emphasis",
  3248. rippleEffect: {
  3249. brushType: "stroke",
  3250. color: "#58F7DF",
  3251. },
  3252. hoverAnimation: true,
  3253. label: {
  3254. normal: {
  3255. formatter: "{b}",
  3256. position: "right",
  3257. show: true,
  3258. fontSize: "30",
  3259. color: "#fff",
  3260. },
  3261. },
  3262. itemStyle: {
  3263. normal: {
  3264. color: "#ffc809",
  3265. shadowBlur: 50,
  3266. shadowColor: "#ffc809",
  3267. },
  3268. emphasis: {
  3269. color: "#58F7DF",
  3270. shadowBlur: 50,
  3271. shadowColor: "#58F7DF",
  3272. },
  3273. },
  3274. zlevel: 99,
  3275. },
  3276. {
  3277. type: "effectScatter",
  3278. colorBy: "data",
  3279. coordinateSystem: "geo",
  3280. data: [
  3281. {
  3282. name: "太原市",
  3283. value: [112.53, 37.87, 25167, 113],
  3284. },
  3285. ],
  3286. symbolSize: function (val) {
  3287. return Math.max(val[2] / 500, 8);
  3288. },
  3289. showEffectOn: "emphasis",
  3290. rippleEffect: {
  3291. brushType: "stroke",
  3292. color: "#DF62F2",
  3293. },
  3294. hoverAnimation: true,
  3295. label: {
  3296. normal: {
  3297. formatter: "{b}",
  3298. position: "right",
  3299. show: true,
  3300. fontSize: "30",
  3301. color: "#fff",
  3302. },
  3303. },
  3304. itemStyle: {
  3305. normal: {
  3306. color: "#ffc809",
  3307. shadowBlur: 50,
  3308. shadowColor: "#ffc809",
  3309. },
  3310. emphasis: {
  3311. color: "#DF62F2",
  3312. shadowBlur: 50,
  3313. shadowColor: "#DF62F2",
  3314. },
  3315. },
  3316. zlevel: 999,
  3317. },
  3318. ],
  3319. };
  3320. var categoryData = [];
  3321. var barData = [];
  3322. var sum = 0;
  3323. for (var i = 0; i < data.length; i++) {
  3324. categoryData.push(data[i].name);
  3325. barData.push(data[i].value);
  3326. sum += data[i].value;
  3327. }
  3328. // this.shanxiMap.on('click', function (params) {
  3329. // if (params.name == '山西') {
  3330. // that.shanxiMap.dispose()
  3331. // that.centerShow = true
  3332. // setTimeout(() => {
  3333. // })
  3334. // }
  3335. // })
  3336. tools.loopShowTooltip(this.shanxiMap, option, {
  3337. interval: 2000,
  3338. loopSeries: false,
  3339. seriesIndex: 0,
  3340. });
  3341. this.shanxiMap.setOption(option);
  3342. },
  3343. chinaEchartsFun () {
  3344. let that = this;
  3345. this.geoCoordMap = [];
  3346. /*获取地图数据*/
  3347. this.chinaMap = echarts.init(this.$refs["china"]);
  3348. echarts.registerMap("china", china);
  3349. // var mapFeatures = echarts.getMap('china').geoJson.features
  3350. // mapFeatures.forEach(v => {
  3351. // // 地区名称
  3352. // var name = v.properties.name
  3353. // // 地区经纬度
  3354. // this.geoCoordMap[name] = v.properties.cp
  3355. // data.push({ name: v.properties.name, value: v.properties.cp[0], value2: v.properties.cp[1] })
  3356. // })
  3357. var data = [
  3358. { "name": "新疆", value: 29780, value2: 80 },
  3359. { "name": "西藏", value: 2186, value2: 80 },
  3360. { "name": "内蒙古", value: 1135, value2: 80 },
  3361. { "name": "青海", value: 29780, value2: 80 },
  3362. { "name": "四川", value: 2568, value2: 80 },
  3363. { "name": "黑龙江", value: 29780, value2: 80 },
  3364. { "name": "甘肃", value: 6959, value2: 80 },
  3365. { "name": "云南", value: 5632, value2: 80 },
  3366. { "name": "广西", value: 6707, value2: 80 },
  3367. { "name": "湖南", value: 29780, value2: 80 },
  3368. { "name": "陕西", value: 1894, value2: 80 },
  3369. { "name": "广东", value: 15769, value2: 80 },
  3370. { "name": "吉林", value: 8259, value2: 80 },
  3371. { "name": "河北", value: 5741, value2: 80 },
  3372. { "name": "湖北", value: 3030, value2: 80 },
  3373. { "name": "贵州", value: 4542, value2: 80 },
  3374. { "name": "山东", value: 19780, value2: 80 },
  3375. { "name": "江西", value: 3157, value2: 80 },
  3376. { "name": "河南", value: 6690, value2: 80 },
  3377. { "name": "辽宁", value: 8678, value2: 80 },
  3378. { "name": "山西", value: 5303, value2: 80 },
  3379. { "name": "安徽", value: 29780, value2: 80 },
  3380. { "name": "福建", value: 10259, value2: 80 },
  3381. { "name": "浙江", value: 3016, value2: 80 },
  3382. { "name": "江苏", value: 3202, value2: 80 },
  3383. { "name": "重庆", value: 4540, value2: 80 },
  3384. { "name": "宁夏", value: 19780, value2: 80 },
  3385. { "name": "海南", value: 8626, value2: 80 },
  3386. { "name": "台湾", value: 4361, value2: 80 },
  3387. { "name": "北京", value: 20000, value2: 80 },
  3388. { "name": "天津", value: 4080, value2: 80 },
  3389. { "name": "上海", value: 19780, value2: 80 },
  3390. { "name": "香港", value: 6991, value2: 80 },
  3391. { "name": "澳门", value: 13873, value2: 80 },
  3392. ];
  3393. var geoCoordMap = {
  3394. "新疆": [86.9023, 41.148],
  3395. "西藏": [87.8695, 31.6846],
  3396. "内蒙古": [110.5977, 41.3408],
  3397. "青海": [95.2402, 35.4199],
  3398. "四川": [102.9199, 30.1904],
  3399. "黑龙江": [128.1445, 46.7156],
  3400. "甘肃": [102.7129, 38.166],
  3401. "云南": [101.0652, 24.6807],
  3402. "广西": [108.7813, 23.6426],
  3403. "湖南": [111.5332, 27.3779],
  3404. "陕西": [108.5996, 33.7396],
  3405. "广东": [113.8668, 22.8076],
  3406. "吉林": [126.1746, 43.5938],
  3407. "河北": [115.4004, 38.1688],
  3408. "湖北": [112.2363, 30.8572],
  3409. "贵州": [106.6113, 26.6385],
  3410. "山东": [118.2402, 36.2307],
  3411. "江西": [115.7156, 27.99],
  3412. "河南": [113.0668, 33.8818],
  3413. "辽宁": [123.0438, 41.0889],
  3414. "山西": [112.44, 37.73],
  3415. "安徽": [117.2461, 31.0361],
  3416. "福建": [118.3008, 25.9277],
  3417. "浙江": [120.498, 29.0918],
  3418. "江苏": [119.8586, 32.915],
  3419. "重庆": [107.7539, 29.8904],
  3420. "宁夏": [105.9961, 37.1096],
  3421. "海南": [109.9512, 19.2041],
  3422. "台湾": [120.8254, 23.5986],
  3423. "北京": [116.4551, 40.2539],
  3424. "天津": [117.4219, 39.4189],
  3425. "上海": [121.4648, 31.2891],
  3426. "香港": [114.6178, 22.3242],
  3427. "澳门": [113.5547, 21.6484],
  3428. '南海诸岛': [128.8254, 21.5986]
  3429. };
  3430. var convertData = function (data) {
  3431. var res = [];
  3432. for (var i = 0; i < data.length; i++) {
  3433. var geoCoord = geoCoordMap[data[i].name];
  3434. if (geoCoord) {
  3435. res.push({
  3436. name: data[i].name,
  3437. value: geoCoord.concat(data[i].value, data[i].value2),
  3438. });
  3439. }
  3440. }
  3441. return res;
  3442. };
  3443. var convertedData = [
  3444. convertData(data),
  3445. convertData(
  3446. data
  3447. .sort(function (a, b) {
  3448. return b.value - a.value;
  3449. })
  3450. .slice(0, 6)
  3451. ),
  3452. ];
  3453. data.sort(function (a, b) {
  3454. return a.value - b.value;
  3455. });
  3456. option = {
  3457. animation: true,
  3458. animationDuration: 1000,
  3459. animationEasing: "cubicInOut",
  3460. animationDurationUpdate: 1000,
  3461. animationEasingUpdate: "cubicInOut",
  3462. geo: {
  3463. map: "china",
  3464. zoom: 0.9,
  3465. label: {
  3466. emphasis: {
  3467. show: false,
  3468. },
  3469. },
  3470. roam: false,
  3471. itemStyle: {
  3472. normal: {
  3473. borderColor: "#7fb3ff",
  3474. borderWidth: 3,
  3475. areaColor: {
  3476. type: "radial",
  3477. x: 0.5,
  3478. y: 0.5,
  3479. r: 0.8,
  3480. colorStops: [
  3481. {
  3482. offset: 0,
  3483. color: "#468ff8", // 0% 处的颜色
  3484. },
  3485. {
  3486. offset: 1,
  3487. color: "#0a2c6d", // 100% 处的颜色
  3488. },
  3489. ],
  3490. globalCoord: false, // 缺省为 false
  3491. },
  3492. // shadowColor: 'rgba(128, 217, 248, 1)',
  3493. shadowColor: "#468ff8",
  3494. shadowOffsetX: -2,
  3495. shadowOffsetY: 2,
  3496. shadowBlur: 20,
  3497. },
  3498. emphasis: {
  3499. areaColor: {
  3500. colorStops: [
  3501. {
  3502. offset: 0,
  3503. color: "#3844aa", // 0% 处的颜色
  3504. },
  3505. {
  3506. offset: 1,
  3507. color: "#7284fc", // 100% 处的颜色
  3508. },
  3509. ],
  3510. },
  3511. borderColor: "#b3baff",
  3512. borderWidth: 5,
  3513. },
  3514. },
  3515. tooltip: {
  3516. trigger: "item",
  3517. className: "custom-tooltip-box",
  3518. confine: true, // 不超出当前表
  3519. formatter: (params, ticket, callback) => {
  3520. // console.log(params, '走了这里了')
  3521. // 清空所有轮播
  3522. for (var k in geoCoordMap) {
  3523. that.chinaMap.dispatchAction({
  3524. // type: 'geoUnSelect',
  3525. type: "downplay",
  3526. name: k,
  3527. geoIndex: 0,
  3528. });
  3529. that.chinaMap.dispatchAction({
  3530. // type: 'geoUnSelect',
  3531. type: "downplay",
  3532. name: k,
  3533. seriesName: params.seriesName,
  3534. });
  3535. that.chinaMap.dispatchAction({
  3536. // type: 'geoUnSelect',
  3537. type: "downplay",
  3538. name: k,
  3539. seriesName: "series\u00001",
  3540. });
  3541. }
  3542. that.chinaMap.dispatchAction({
  3543. // type: 'geoSelect',
  3544. type: "highlight",
  3545. name: params.name,
  3546. geoIndex: 0,
  3547. });
  3548. that.chinaMap.dispatchAction({
  3549. // type: 'geoSelect',
  3550. type: "highlight",
  3551. name: params.name,
  3552. seriesName: params.seriesName,
  3553. });
  3554. that.chinaMap.dispatchAction({
  3555. // type: 'geoSelect',
  3556. type: "highlight",
  3557. name: params.name,
  3558. seriesName: "series\u00001",
  3559. });
  3560. return `<div class="bgTooltip" style="background: rgba(50,50,50,0.7);font-size:36px">
  3561. <div class="flex items-center">
  3562. <img src="./img/yellowArrow.png" style="width: 12px;height: 22px;margin-right:10px" alt=""><span class="fb">${params.name}</span>
  3563. </div>
  3564. <div class="blueIcon flex items-center">项目数量:<span class="fb" style="color:#68BDFF;">${params.value[3]}<span style="font-size:20px" class="fn">个</span></span></div>
  3565. <div class="blueIcon flex items-center">投资总额:<span class="fb" style="color:#68BDFF">${params.value[2]}<span style="font-size:20px" class="fn">亿</span></span></div>
  3566. </div>`;
  3567. },
  3568. },
  3569. regions: [
  3570. {
  3571. name: "山西",
  3572. value: 2000,
  3573. itemStyle: {
  3574. emphasis: {
  3575. borderColor: "#ffe036",
  3576. borderWidth: 5,
  3577. areaColor: {
  3578. type: "radial",
  3579. x: 0.5,
  3580. y: 0.5,
  3581. r: 0.8,
  3582. colorStops: [
  3583. {
  3584. offset: 0,
  3585. color: "#ffe036", // 0% 处的颜色
  3586. },
  3587. {
  3588. offset: 1,
  3589. color: "#7c732a", // 100% 处的颜色
  3590. },
  3591. ],
  3592. globalCoord: false, // 缺省为 false
  3593. },
  3594. },
  3595. },
  3596. },
  3597. // {
  3598. // name: "南海诸岛",
  3599. // itemStyle: {
  3600. // // 隐藏地图
  3601. // normal: {
  3602. // opacity: 0, // 为 0 时不绘制该图形
  3603. // },
  3604. // },
  3605. // label: {
  3606. // show: false, // 隐藏文字
  3607. // },
  3608. // },
  3609. ],
  3610. },
  3611. tooltip: {
  3612. trigger: "item",
  3613. className: "custom-tooltip-box",
  3614. confine: true, // 不超出当前表
  3615. },
  3616. xAxis: {
  3617. type: "value",
  3618. scale: true,
  3619. position: "top",
  3620. boundaryGap: false,
  3621. splitLine: {
  3622. show: false,
  3623. },
  3624. axisLine: {
  3625. show: false,
  3626. },
  3627. axisTick: {
  3628. show: false,
  3629. },
  3630. axisLabel: {
  3631. margin: 2,
  3632. textStyle: {
  3633. color: "#aaa",
  3634. },
  3635. },
  3636. },
  3637. yAxis: {
  3638. type: "category",
  3639. nameGap: 16,
  3640. axisLine: {
  3641. show: false,
  3642. lineStyle: {
  3643. color: "#ddd",
  3644. },
  3645. },
  3646. axisTick: {
  3647. show: false,
  3648. lineStyle: {
  3649. color: "#ddd",
  3650. },
  3651. },
  3652. axisLabel: {
  3653. interval: 0,
  3654. textStyle: {
  3655. color: "#ddd",
  3656. },
  3657. },
  3658. data: categoryData,
  3659. },
  3660. series: [
  3661. {
  3662. type: "effectScatter",
  3663. colorBy: "data",
  3664. coordinateSystem: "geo",
  3665. data: convertedData[0],
  3666. symbolSize: function (val) {
  3667. return Math.max(val[2] / 500, 8);
  3668. },
  3669. showEffectOn: "emphasis",
  3670. rippleEffect: {
  3671. brushType: "stroke",
  3672. color: "#58F7DF",
  3673. },
  3674. hoverAnimation: true,
  3675. label: {
  3676. normal: {
  3677. formatter: "{b}",
  3678. position: "right",
  3679. show: true,
  3680. fontSize: "30",
  3681. color: "#fff",
  3682. },
  3683. },
  3684. itemStyle: {
  3685. normal: {
  3686. color: "#ffc809",
  3687. shadowBlur: 50,
  3688. shadowColor: "#ffc809",
  3689. },
  3690. emphasis: {
  3691. color: "#58F7DF",
  3692. shadowBlur: 50,
  3693. shadowColor: "#58F7DF",
  3694. },
  3695. },
  3696. zlevel: 99,
  3697. },
  3698. {
  3699. type: "effectScatter",
  3700. colorBy: "data",
  3701. coordinateSystem: "geo",
  3702. data: [
  3703. {
  3704. name: "山西",
  3705. value: [112.43, 37.73, 5303, 80],
  3706. },
  3707. ],
  3708. symbolSize: function (val) {
  3709. return Math.max(val[2] / 500, 8);
  3710. },
  3711. showEffectOn: "emphasis",
  3712. rippleEffect: {
  3713. brushType: "stroke",
  3714. color: "#DF62F2",
  3715. },
  3716. hoverAnimation: true,
  3717. label: {
  3718. normal: {
  3719. formatter: "{b}",
  3720. position: "right",
  3721. show: true,
  3722. fontSize: "30",
  3723. color: "#fff",
  3724. },
  3725. },
  3726. itemStyle: {
  3727. normal: {
  3728. color: "#ffc809",
  3729. shadowBlur: 50,
  3730. shadowColor: "#ffc809",
  3731. },
  3732. emphasis: {
  3733. color: "#DF62F2",
  3734. shadowBlur: 50,
  3735. shadowColor: "#DF62F2",
  3736. },
  3737. },
  3738. zlevel: 999,
  3739. },
  3740. ],
  3741. };
  3742. var categoryData = [];
  3743. var barData = [];
  3744. var sum = 0;
  3745. for (var i = 0; i < data.length; i++) {
  3746. categoryData.push(data[i].name);
  3747. barData.push(data[i].value);
  3748. sum += data[i].value;
  3749. }
  3750. this.chinaMap.on('click', function (params) {
  3751. if (params.name == '山西') {
  3752. that.chinaMap.dispose()
  3753. that.leftEcharts16.dispose()
  3754. that.mapShow = true
  3755. setTimeout(() => {
  3756. that.leftEcharts12Fun()
  3757. that.leftEcharts14Fun()
  3758. that.leftEcharts9Fun()
  3759. that.leftEcharts15Fun()
  3760. that.leftEcharts13Fun()
  3761. that.shanxiEchartsFun()
  3762. })
  3763. }
  3764. })
  3765. tools.loopShowTooltip(this.chinaMap, option, {
  3766. interval: 2000,
  3767. loopSeries: false,
  3768. seriesIndex: 0,
  3769. });
  3770. this.chinaMap.setOption(option);
  3771. },
  3772. leftEcharts9Fun () {
  3773. let that = this;
  3774. this.leftEcharts9 = echarts.init(this.$refs["leftEcharts9"]);
  3775. // var ROOT_PATH = 'https://echarts.apache.org/examples';
  3776. let option = {
  3777. backgroundColor: "#00000000",
  3778. globe: {
  3779. globeRadius: 55,
  3780. baseTexture: "./img/3D/world1.jpg",
  3781. heightTexture: "./img/3D/world1.jpg",
  3782. displacementScale: 0.04,
  3783. shading: "realistic",
  3784. // environment: './img/3D/world2.jpg',
  3785. realisticMaterial: {
  3786. roughness: 0.9,
  3787. },
  3788. postEffect: {
  3789. enable: true,
  3790. },
  3791. light: {
  3792. main: {
  3793. intensity: 3,
  3794. shadow: true,
  3795. },
  3796. },
  3797. },
  3798. };
  3799. that.leftEcharts9.setOption(option);
  3800. },
  3801. leftEcharts10Fun () {
  3802. let that = this;
  3803. this.leftEcharts10 = echarts.init(this.$refs["leftEcharts10"]);
  3804. option = {
  3805. grid: {
  3806. top: 45,
  3807. right: 0,
  3808. left: 80,
  3809. bottom: 80,
  3810. },
  3811. tooltip: {
  3812. show: true,
  3813. trigger: "axis",
  3814. formatter: (data) => {
  3815. return `${data[0].name
  3816. }<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[0].color
  3817. }"></span> ${data[0].seriesName}:${that.numFormat(
  3818. data[0].value
  3819. )}亿<br/><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[1].color.colorStops[0].color
  3820. }"></span> ${data[1].seriesName}:${that.numFormat(
  3821. data[1].value
  3822. )}亿`;
  3823. },
  3824. axisPointer: {
  3825. // 坐标轴指示器,坐标轴触发有效
  3826. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  3827. },
  3828. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  3829. borderColor: "rgba(50,50,50,0.7)",
  3830. textStyle: {
  3831. color: "#fff",
  3832. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  3833. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  3834. fontSize: "28", // 文字字体大小
  3835. },
  3836. },
  3837. xAxis: {
  3838. data: commonCompany,
  3839. axisTick: {
  3840. show: false,
  3841. },
  3842. // x轴的字体颜色
  3843. axisLabel: {
  3844. rotate: 40,
  3845. textStyle: {
  3846. color: "white",
  3847. fontSize: "20",
  3848. fontFamily: "Microsoft YaHei",
  3849. },
  3850. },
  3851. //y轴线的颜色以及宽度
  3852. axisLine: {
  3853. show: true,
  3854. lineStyle: {
  3855. color: "#1E5389",
  3856. width: 1,
  3857. type: "solid",
  3858. },
  3859. },
  3860. },
  3861. yAxis: {
  3862. name: "亿",
  3863. axisTick: {
  3864. lineStyle: {
  3865. color: "#18416F",
  3866. },
  3867. },
  3868. // y轴的字体颜色
  3869. axisLabel: {
  3870. textStyle: {
  3871. color: "white",
  3872. fontSize: "20",
  3873. fontFamily: "Microsoft YaHei",
  3874. },
  3875. },
  3876. splitLine: {
  3877. show: true,
  3878. lineStyle: {
  3879. color: "#68b4dd66",
  3880. width: 1,
  3881. type: "dashed",
  3882. },
  3883. },
  3884. //y轴线的颜色以及宽度
  3885. axisLine: {
  3886. show: true,
  3887. lineStyle: {
  3888. color: "#1E5389",
  3889. width: 1,
  3890. type: "solid",
  3891. },
  3892. },
  3893. nameTextStyle: {
  3894. color: "#fff",
  3895. fontSize: 20,
  3896. fontFamily: "Microsoft YaHei",
  3897. },
  3898. },
  3899. series: [
  3900. {
  3901. name: "已用额度",
  3902. type: "pictorialBar",
  3903. symbol: "fixed",
  3904. symbolSize: [20, 5],
  3905. symbolMargin: 2,
  3906. symbolRepeat: "repeat",
  3907. data: [
  3908. 26, 36, 16, 46, 26, 36, 16, 46, 26, 36, 16, 46, 26, 36, 16, 46,
  3909. 26, 36,
  3910. ],
  3911. showBackground: false,
  3912. barWidth: "15",
  3913. itemStyle: {
  3914. color: "#40A9FF",
  3915. },
  3916. zlevel: 1,
  3917. },
  3918. {
  3919. name: "总额度",
  3920. type: "pictorialBar",
  3921. symbol: "fixed",
  3922. symbolSize: [30, 5],
  3923. symbolMargin: 2,
  3924. symbolRepeat: "repeat",
  3925. data: [
  3926. 390, 390, 390, 200, 390, 390, 390, 200, 390, 390, 390, 200, 390,
  3927. 390, 390, 200, 390, 200,
  3928. ],
  3929. barGap: "-130%",
  3930. barWidth: "25",
  3931. itemStyle: {
  3932. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  3933. {
  3934. offset: 0,
  3935. color: "#b9b7c030",
  3936. },
  3937. {
  3938. offset: 1,
  3939. color: "#b9b7c030",
  3940. },
  3941. ]),
  3942. },
  3943. },
  3944. ],
  3945. };
  3946. //轮播
  3947. tools.loopShowTooltip(that.leftEcharts10, option, {
  3948. interval: 2000,
  3949. loopSeries: true,
  3950. });
  3951. //注册
  3952. that.leftEcharts10.setOption(option);
  3953. },
  3954. // 重点项目两线指标轮播方法
  3955. scrollChange (index) {
  3956. if (index == 18) {
  3957. this.count = -1;
  3958. } else {
  3959. this.count = index;
  3960. }
  3961. if (this.count > 12 && this.count != 18) {
  3962. this.countType = 1;
  3963. } else {
  3964. this.countType = 0;
  3965. }
  3966. for (var i = 0; i < this.list.length; i++) {
  3967. if (i == 2) {
  3968. this.list[i].classList.add("light");
  3969. } else {
  3970. this.list[i].classList.remove("light");
  3971. }
  3972. }
  3973. this.leftEcharts11 ? this.leftEcharts11.dispose() : "";
  3974. this.leftEcharts11Fun();
  3975. },
  3976. leftEcharts11Fun () {
  3977. let that = this;
  3978. this.leftEcharts11 = echarts.init(this.$refs["leftEcharts11"]);
  3979. option = {
  3980. tooltip: {
  3981. trigger: "axis",
  3982. formatter:
  3983. "指标:" +
  3984. "{c0}" +
  3985. "<br/>" +
  3986. "发展线:" +
  3987. "{c1}" +
  3988. "<br/>" +
  3989. "生存线:" +
  3990. "{c2}", //+ '<br/>'+ '{a1}:{c1}' + '%',
  3991. axisPointer: {
  3992. type: "shadow",
  3993. },
  3994. backgroundColor: "rgba(50,50,50,0.7)",
  3995. borderColor: "rgba(50,50,50,0.7)",
  3996. textStyle: {
  3997. color: "#fff",
  3998. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  3999. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  4000. fontSize: "28", // 文字字体大小
  4001. }
  4002. },
  4003. grid: {
  4004. top: "10%",
  4005. right: "5%",
  4006. left: "15%",
  4007. bottom: "20%",
  4008. },
  4009. xAxis: {
  4010. data: [
  4011. "总投资收益率",
  4012. "销售利润率",
  4013. "成本费用利润率",
  4014. "总资产周转率",
  4015. "财务内部收益率",
  4016. ],
  4017. // data: left15[this.countType],
  4018. axisLine: {
  4019. show: true, //隐藏X轴轴线
  4020. lineStyle: {
  4021. color: "#005094",
  4022. width: 1,
  4023. },
  4024. },
  4025. axisTick: {
  4026. show: true, //隐藏X轴刻度
  4027. },
  4028. axisLabel: {
  4029. show: true,
  4030. rotate: 30,
  4031. textStyle: {
  4032. color: "#fff", //X轴文字颜色
  4033. fontSize: 20,
  4034. fontFamily: "Microsoft YaHei",
  4035. },
  4036. },
  4037. },
  4038. yAxis: [
  4039. {
  4040. type: "value",
  4041. splitLine: {
  4042. show: true,
  4043. lineStyle: {
  4044. color: "#68b4dd66",
  4045. type: "dashed",
  4046. },
  4047. },
  4048. axisLine: {
  4049. show: false,
  4050. },
  4051. axisLabel: {
  4052. show: true,
  4053. formatter: "{value}%",
  4054. textStyle: {
  4055. color: "#fff",
  4056. fontSize: 20,
  4057. fontFamily: "Microsoft YaHei",
  4058. },
  4059. },
  4060. nameTextStyle: {
  4061. color: "#ebf8ac",
  4062. fontSize: 16,
  4063. fontFamily: "Microsoft YaHei",
  4064. },
  4065. },
  4066. ],
  4067. series: [
  4068. {
  4069. name: "实际值",
  4070. type: "bar",
  4071. barWidth: 20,
  4072. itemStyle: {
  4073. normal: {
  4074. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4075. {
  4076. offset: 0,
  4077. color: "#69c0ff",
  4078. },
  4079. {
  4080. offset: 1,
  4081. color: "#082550",
  4082. },
  4083. ]),
  4084. },
  4085. },
  4086. data: [70, 52, 33, 41, 52],
  4087. // data: this.storageRecordConfig.data.length == 0 ? [] : this.storageRecordConfig.data.length == 1 ? left12[this.count][2] : left12[this.count + 1][2]
  4088. },
  4089. {
  4090. name: "",
  4091. type: "line",
  4092. barWidth: 15,
  4093. itemStyle: {
  4094. normal: {
  4095. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4096. {
  4097. offset: 0,
  4098. color: "#69c0ff",
  4099. },
  4100. {
  4101. offset: 1,
  4102. color: "green",
  4103. },
  4104. ]),
  4105. },
  4106. },
  4107. data: [20, 30, 15, 28, 36],
  4108. // data: this.storageRecordConfig.data.length == 0 ? [] : this.storageRecordConfig.data.length == 1 ? left12[this.count][1] : left12[this.count + 1][1]
  4109. },
  4110. {
  4111. name: "",
  4112. type: "line",
  4113. barWidth: 15,
  4114. itemStyle: {
  4115. normal: {
  4116. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4117. {
  4118. offset: 0,
  4119. color: "#69c0ff",
  4120. },
  4121. {
  4122. offset: 1,
  4123. color: "yellow",
  4124. },
  4125. ]),
  4126. },
  4127. },
  4128. data: [15, 22, 17, 33, 14],
  4129. // data: this.storageRecordConfig.data.length == 0 ? [] : this.storageRecordConfig.data.length == 1 ? left12[this.count][0] : left12[this.count + 1][0]
  4130. },
  4131. ],
  4132. };
  4133. //轮播
  4134. tools.loopShowTooltip(that.leftEcharts11, option, {
  4135. interval: 2000,
  4136. loopSeries: true,
  4137. });
  4138. //注册
  4139. that.leftEcharts11.setOption(option);
  4140. },
  4141. leftEcharts12Fun () {
  4142. let that = this;
  4143. this.leftEcharts12 = echarts.init(this.$refs["leftEcharts12"]);
  4144. var totalData = [{
  4145. name: '传统产业',
  4146. value: 12,
  4147. radio: 0.13
  4148. }, {
  4149. name: '公共基础产业',
  4150. value: 52,
  4151. radio: 0.01
  4152. }, {
  4153. name: '战略性新兴产业',
  4154. value: 15,
  4155. radio: 3.9
  4156. }, {
  4157. name: '特色优势产业',
  4158. value: 56,
  4159. radio: 10.5
  4160. }];
  4161. var data = [];
  4162. for (var i = 0; i < totalData.length; i++) {
  4163. data.push({
  4164. value: totalData[i].value,
  4165. name: totalData[i].name,
  4166. itemStyle: {
  4167. normal: {
  4168. borderWidth: 8,
  4169. shadowBlur: 0,
  4170. borderColor: commonColor[i],
  4171. shadowColor: commonColor[i]
  4172. }
  4173. }
  4174. },
  4175. {
  4176. value: 5,
  4177. name: '',
  4178. itemStyle: {
  4179. normal: {
  4180. label: {
  4181. show: false
  4182. },
  4183. labelLine: {
  4184. show: false
  4185. },
  4186. color: 'rgba(0, 0, 0, 0)',
  4187. borderColor: 'rgba(0, 0, 0, 0)',
  4188. borderWidth: 0
  4189. }
  4190. }
  4191. }
  4192. );
  4193. }
  4194. var seriesOption = [
  4195. {
  4196. name: '',
  4197. type: 'pie',
  4198. clockWise: false,
  4199. radius: [170, 160],
  4200. center: [260, 250],
  4201. hoverAnimation: false,
  4202. itemStyle: {
  4203. normal: {
  4204. label: {
  4205. show: false,
  4206. }
  4207. }
  4208. },
  4209. data: data
  4210. },
  4211. {
  4212. type: 'pie',
  4213. radius: [120, 120],
  4214. center: [260, 250],
  4215. zlevel: 3,
  4216. silent: true,
  4217. label: {
  4218. normal: {
  4219. show: false
  4220. },
  4221. },
  4222. labelLine: {
  4223. normal: {
  4224. show: false
  4225. }
  4226. },
  4227. data: _pie3()
  4228. },
  4229. {
  4230. type: "liquidFill",
  4231. radius: "40%",
  4232. data: [left2[0]],
  4233. center: [260, 250],
  4234. backgroundStyle: {
  4235. color: {
  4236. type: "radial",
  4237. x: 0.5,
  4238. y: 0.5,
  4239. r: 0.5,
  4240. // 水球体颜色
  4241. colorStops: [
  4242. {
  4243. offset: 0,
  4244. color: "#010a11",
  4245. },
  4246. {
  4247. offset: 0.75,
  4248. // color: "#203852",
  4249. color: "#1a2f45",
  4250. },
  4251. {
  4252. offset: 1,
  4253. // color: "#354e6d",
  4254. color: "#2b405a",
  4255. // color: "#314967",
  4256. },
  4257. ],
  4258. globalCoord: false,
  4259. },
  4260. },
  4261. outline: {
  4262. borderDistance: 0,
  4263. itemStyle: {
  4264. borderWidth: 0,
  4265. borderColor: {
  4266. type: "linear",
  4267. x: 0,
  4268. y: 0,
  4269. x2: 0,
  4270. y2: 1,
  4271. colorStops: [
  4272. ],
  4273. globalCoord: false,
  4274. },
  4275. },
  4276. },
  4277. color: [
  4278. {
  4279. x: 0,
  4280. y: 0,
  4281. x2: 0,
  4282. y2: 1,
  4283. colorStops: [{
  4284. offset: 0,
  4285. color: '#237386',
  4286. },
  4287. {
  4288. offset: 1,
  4289. color: '#0078C8',
  4290. },],
  4291. },
  4292. {
  4293. x: 0,
  4294. y: 0,
  4295. x2: 0,
  4296. y2: 1,
  4297. colorStops: [{
  4298. offset: 0,
  4299. color: '#2F97A9',
  4300. },
  4301. {
  4302. offset: 1,
  4303. color: '#0078C8',
  4304. },],
  4305. },
  4306. {
  4307. x: 0,
  4308. y: 0,
  4309. x2: 0,
  4310. y2: 1,
  4311. colorStops: [{
  4312. offset: 0,
  4313. color: '#48E0ED',
  4314. },
  4315. {
  4316. offset: 1,
  4317. color: '#0078C8',
  4318. },],
  4319. }
  4320. ],
  4321. label: {
  4322. normal: {
  4323. textStyle: {
  4324. fontSize: '50',
  4325. color: "#58E6F7", // x轴文字颜色
  4326. },
  4327. },
  4328. },
  4329. },
  4330. ];
  4331. option = {
  4332. color: commonColor,
  4333. title: {
  4334. show: false,
  4335. text: '风险类型123',
  4336. top: '48%',
  4337. textAlign: "center",
  4338. left: "49%",
  4339. textStyle: {
  4340. color: '#fff',
  4341. fontSize: 18,
  4342. fontWeight: '400'
  4343. }
  4344. },
  4345. tooltip: {
  4346. show: false
  4347. },
  4348. legend: {
  4349. icon: "circle",
  4350. orient: 'vertical',
  4351. formatter: function (name) {
  4352. let num
  4353. for (let i = 0; i < totalData.length; i++) {
  4354. if (totalData[i].name === name) {
  4355. num = name + ':' + totalData[i].value + '(' + totalData[i].radio + '%' + ')'
  4356. }
  4357. }
  4358. return num
  4359. },
  4360. data: ['传统产业', '公共基础产业', '战略性新兴产业', '特色优势产业'],
  4361. right: 0,
  4362. bottom: 0,
  4363. align: 'left',
  4364. textStyle: {
  4365. color: '#FFF', // 文字的颜色
  4366. fontSize: '20', // 文字字体大小
  4367. fontFamily: 'Microsoft YaHei'
  4368. },
  4369. itemGap: 20
  4370. },
  4371. toolbox: {
  4372. show: false
  4373. },
  4374. series: seriesOption
  4375. }
  4376. function _pie3 () {
  4377. let dataArr = [];
  4378. for (var i = 0; i < 100; i++) {
  4379. if (i % 2 === 0) {
  4380. dataArr.push({
  4381. name: (i + 1).toString(),
  4382. value: 25,
  4383. itemStyle: {
  4384. normal: {
  4385. color: "#5A5DE0",
  4386. borderWidth: 1,
  4387. borderColor: "#5A5DE0"
  4388. }
  4389. }
  4390. })
  4391. } else {
  4392. dataArr.push({
  4393. name: (i + 1).toString(),
  4394. value: 20,
  4395. itemStyle: {
  4396. normal: {
  4397. color: "rgba(0,0,0,0)",
  4398. borderWidth: 0,
  4399. borderColor: "rgba(0,0,0,0)"
  4400. }
  4401. }
  4402. })
  4403. }
  4404. }
  4405. return dataArr
  4406. }
  4407. //轮播
  4408. tools.loopShowTooltip(that.leftEcharts12, option, {
  4409. interval: 2000,
  4410. loopSeries: true,
  4411. });
  4412. //注册
  4413. that.leftEcharts12.setOption(option);
  4414. },
  4415. leftEcharts13Fun () {
  4416. let that = this;
  4417. this.leftEcharts13 = echarts.init(this.$refs["leftEcharts13"]);
  4418. var totalData = [{
  4419. name: '新建',
  4420. value: 12,
  4421. radio: 0.13
  4422. }, {
  4423. name: '续建',
  4424. value: 52,
  4425. radio: 0.01
  4426. }];
  4427. var data = [];
  4428. for (var i = 0; i < totalData.length; i++) {
  4429. data.push({
  4430. value: totalData[i].value,
  4431. name: totalData[i].name,
  4432. itemStyle: {
  4433. normal: {
  4434. borderWidth: 8,
  4435. shadowBlur: 0,
  4436. borderColor: commonColor[i],
  4437. shadowColor: commonColor[i]
  4438. }
  4439. }
  4440. },
  4441. {
  4442. value: 5,
  4443. name: '',
  4444. itemStyle: {
  4445. normal: {
  4446. label: {
  4447. show: false
  4448. },
  4449. labelLine: {
  4450. show: false
  4451. },
  4452. color: 'rgba(0, 0, 0, 0)',
  4453. borderColor: 'rgba(0, 0, 0, 0)',
  4454. borderWidth: 0
  4455. }
  4456. }
  4457. }
  4458. );
  4459. }
  4460. var seriesOption = [
  4461. {
  4462. name: '',
  4463. type: 'pie',
  4464. clockWise: false,
  4465. radius: [170, 160],
  4466. center: [350, 250],
  4467. hoverAnimation: false,
  4468. itemStyle: {
  4469. normal: {
  4470. label: {
  4471. show: false,
  4472. }
  4473. }
  4474. },
  4475. data: data
  4476. },
  4477. {
  4478. type: 'pie',
  4479. radius: [120, 120],
  4480. center: [350, 250],
  4481. zlevel: 3,
  4482. silent: true,
  4483. label: {
  4484. normal: {
  4485. show: false
  4486. },
  4487. },
  4488. labelLine: {
  4489. normal: {
  4490. show: false
  4491. }
  4492. },
  4493. data: _pie3()
  4494. }
  4495. ];
  4496. option = {
  4497. color: commonColor,
  4498. title: {
  4499. show: true,
  4500. text: '35%',
  4501. top: '40%',
  4502. textAlign: "center",
  4503. left: "50%",
  4504. textStyle: {
  4505. fontWeight: '600',
  4506. fontFamily: 'Microsoft YaHei',
  4507. fontSize: '50',
  4508. color: "#58E6F7", // x轴文字颜色
  4509. }
  4510. },
  4511. tooltip: {
  4512. show: false
  4513. },
  4514. legend: {
  4515. icon: "circle",
  4516. orient: 'vertical',
  4517. formatter: function (name) {
  4518. let num
  4519. for (let i = 0; i < totalData.length; i++) {
  4520. if (totalData[i].name === name) {
  4521. num = name + ':' + totalData[i].value + '(' + totalData[i].radio + '%' + ')'
  4522. }
  4523. }
  4524. return num
  4525. },
  4526. data: ['新建', '续建'],
  4527. right: 0,
  4528. bottom: 0,
  4529. align: 'left',
  4530. textStyle: {
  4531. color: '#FFF', // 文字的颜色
  4532. fontSize: '20', // 文字字体大小
  4533. },
  4534. itemGap: 20
  4535. },
  4536. toolbox: {
  4537. show: false
  4538. },
  4539. series: seriesOption
  4540. }
  4541. function _pie3 () {
  4542. let dataArr = [];
  4543. for (var i = 0; i < 1; i++) {
  4544. if (i % 2 === 0) {
  4545. dataArr.push({
  4546. name: (i + 1).toString(),
  4547. value: 25,
  4548. itemStyle: {
  4549. normal: {
  4550. color: "#5A5DE0",
  4551. borderWidth: 1,
  4552. borderColor: "#5A5DE0"
  4553. }
  4554. }
  4555. })
  4556. } else {
  4557. dataArr.push({
  4558. name: (i + 1).toString(),
  4559. value: 20,
  4560. itemStyle: {
  4561. normal: {
  4562. color: "rgba(0,0,0,0)",
  4563. borderWidth: 0,
  4564. borderColor: "rgba(0,0,0,0)"
  4565. }
  4566. }
  4567. })
  4568. }
  4569. }
  4570. return dataArr
  4571. }
  4572. //轮播
  4573. tools.loopShowTooltip(that.leftEcharts13, option, {
  4574. interval: 2000,
  4575. loopSeries: true,
  4576. });
  4577. //注册
  4578. that.leftEcharts13.setOption(option);
  4579. },
  4580. leftEcharts14Fun () {
  4581. let that = this;
  4582. this.leftEcharts14 = echarts.init(this.$refs["leftEcharts14"]);
  4583. that.leftEcharts14.on("showTip", (params) => {
  4584. // 如果是7或者15并且满足防抖则切换
  4585. if (
  4586. (params.dataIndex == 5 || params.dataIndex == 11) &&
  4587. that.echartC1Fd1
  4588. ) {
  4589. that.echartC1Fd1 = false;
  4590. setTimeout(() => {
  4591. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6;
  4592. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6;
  4593. that.leftEcharts14.setOption(option);
  4594. // 防止勿刷新做的防抖
  4595. setTimeout(() => {
  4596. that.echartC1Fd1 = true;
  4597. }, 2000);
  4598. }, 1900);
  4599. // 如果是17表示到了最后一个,那么重新来一遍
  4600. } else if (params.dataIndex == 17 && that.echartC1Fd1) {
  4601. that.echartC1Fd1 = false;
  4602. setTimeout(() => {
  4603. option.dataZoom[0].endValue = 0;
  4604. option.dataZoom[0].startValue = 5;
  4605. that.leftEcharts14.setOption(option);
  4606. // 防止勿刷新做的防抖
  4607. setTimeout(() => {
  4608. that.echartC1Fd1 = true;
  4609. }, 2000);
  4610. }, 1900);
  4611. }
  4612. });
  4613. let option = {
  4614. dataZoom: [
  4615. {
  4616. // start: 9,//默认为@
  4617. // end: 100,//黑认认为1@0
  4618. type: "slider",
  4619. show: false,
  4620. yAxisIndex: 0,
  4621. handlesize: 0, //滑动条的 左右2个滑动条的大小
  4622. startValue: 5, // 初始显示值
  4623. endValue: 0, // 结束显示值
  4624. height: 10, //组件高度
  4625. left: "5%",
  4626. right: "4%", //右边的距离
  4627. bottom: "25%", //底边的距离
  4628. borderColor: "#939",
  4629. fillerColor: "#269cdb",
  4630. borderRadius: 5,
  4631. backgroundColor: "#33384b", //两边未选中的滑动条区域的额色
  4632. showDataShadow: false, //是否显示数据阴影
  4633. showDetail: false, //即拖拽时候是否显示详细数值信息
  4634. truerealtime: true, //是否实时更新
  4635. filterMode: "filter",
  4636. },
  4637. {
  4638. type: "inside",
  4639. show: true,
  4640. start: 1,
  4641. end: 100,
  4642. zoomOnMouseWheel: false, //滚轮是否触发缩放
  4643. moveOnMouseMove: false, //鼠标滚轮触发滚动
  4644. },
  4645. ],
  4646. tooltip: {
  4647. show: true,
  4648. trigger: "axis",
  4649. // formatter: (data) => {
  4650. // return `${data[0].name
  4651. // }<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[0].color
  4652. // }"></span> ${data[0].seriesName}:${that.numFormat(
  4653. // data[0].value
  4654. // )}亿<br/><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[1].color.colorStops[0].color
  4655. // }"></span> ${data[1].seriesName}:${that.numFormat(
  4656. // data[1].value
  4657. // )}亿`;
  4658. // },
  4659. axisPointer: {
  4660. // 坐标轴指示器,坐标轴触发有效
  4661. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  4662. },
  4663. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  4664. borderColor: "rgba(50,50,50,0.7)",
  4665. textStyle: {
  4666. color: "#fff",
  4667. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  4668. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  4669. fontSize: "28", // 文字字体大小
  4670. },
  4671. },
  4672. legend: {
  4673. top: "top",
  4674. textStyle: {
  4675. color: "#fff",
  4676. fontSize: 20,
  4677. padding: [0, 20],
  4678. },
  4679. },
  4680. grid: {
  4681. left: '3%',
  4682. right: '7%',
  4683. bottom: '3%',
  4684. containLabel: true
  4685. },
  4686. xAxis: {
  4687. name: '亿',
  4688. nameTextStyle: {
  4689. color: '#fff',
  4690. fontSize: 20,
  4691. fontFamily: 'Microsoft YaHei'
  4692. },
  4693. type: 'value',
  4694. axisLabel: {
  4695. textStyle: {
  4696. color: "white",
  4697. fontSize: '20',
  4698. fontFamily: 'Microsoft YaHei'
  4699. },
  4700. },
  4701. splitLine: {
  4702. show: true,
  4703. lineStyle: {
  4704. color: "#68b4dd66",
  4705. width: 1,
  4706. type: "dashed",
  4707. },
  4708. },
  4709. },
  4710. yAxis: {
  4711. type: 'category',
  4712. axisTick: {
  4713. lineStyle: {
  4714. color: "#18416F",
  4715. },
  4716. },
  4717. // y轴的字体颜色
  4718. axisLabel: {
  4719. textStyle: {
  4720. color: "white",
  4721. fontSize: '20',
  4722. fontFamily: 'Microsoft YaHei'
  4723. },
  4724. },
  4725. splitLine: {
  4726. show: false,
  4727. lineStyle: {
  4728. color: "#68b4dd66",
  4729. width: 1,
  4730. type: "dashed",
  4731. },
  4732. },
  4733. //y轴线的颜色以及宽度
  4734. axisLine: {
  4735. show: true,
  4736. lineStyle: {
  4737. color: "#1E5389",
  4738. width: 1,
  4739. type: "solid",
  4740. },
  4741. },
  4742. nameTextStyle: {
  4743. color: '#fff',
  4744. fontSize: 20,
  4745. fontFamily: 'Microsoft YaHei'
  4746. },
  4747. data: that.riskData1.x
  4748. },
  4749. series: [
  4750. {
  4751. name: '实际投资',
  4752. type: 'bar',
  4753. data: that.riskData1.y1,
  4754. barGap: '-145%',
  4755. barWidth: "15",
  4756. zlevel: 10,
  4757. itemStyle: {
  4758. barBorderRadius: [0, 20, 20, 0],
  4759. color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [
  4760. {
  4761. offset: 0,
  4762. color: '#0F357C',
  4763. },
  4764. {
  4765. offset: 1,
  4766. color: '#B78CFF',
  4767. },
  4768. ]),
  4769. },
  4770. },
  4771. {
  4772. name: '计划投资',
  4773. type: 'bar',
  4774. data: that.riskData1.y1,
  4775. barWidth: "30",
  4776. itemStyle: {
  4777. barBorderRadius: [0, 50, 50, 0],
  4778. borderColor: '#B78CFF',
  4779. color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [
  4780. {
  4781. offset: 0,
  4782. color: '#0F357C80',
  4783. },
  4784. {
  4785. offset: 1,
  4786. color: '#10417F80',
  4787. },
  4788. ]),
  4789. },
  4790. }
  4791. ]
  4792. };
  4793. //轮播
  4794. tools.loopShowTooltip(that.leftEcharts14, option, {
  4795. interval: 2000,
  4796. loopSeries: true,
  4797. });
  4798. //注册
  4799. that.leftEcharts14.setOption(option);
  4800. },
  4801. leftEcharts15Fun () {
  4802. let that = this;
  4803. this.leftEcharts15 = echarts.init(this.$refs["leftEcharts15"]);
  4804. var xdata = ['煤炭和煤电', '煤电和新能源', '煤炭和化工', '煤炭和数字', '煤炭和降碳'];
  4805. var data = [70, 60, 80, 200, 300];
  4806. var maxArr = [100, 100, 100];
  4807. option = {
  4808. tooltip: {
  4809. show: true,
  4810. trigger: "axis",
  4811. // formatter: (data) => {
  4812. // return `${data[0].name
  4813. // }<br /><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[0].color
  4814. // }"></span> ${data[0].seriesName}:${that.numFormat(
  4815. // data[0].value
  4816. // )}亿<br/><span style="display:inline-block;border-radius:50%; width:20px;height:20px;background-color:${data[1].color.colorStops[0].color
  4817. // }"></span> ${data[1].seriesName}:${that.numFormat(
  4818. // data[1].value
  4819. // )}亿`;
  4820. // },
  4821. axisPointer: {
  4822. // 坐标轴指示器,坐标轴触发有效
  4823. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  4824. },
  4825. backgroundColor: "rgba(50,50,50,0.7)", // 提示框浮层的背景颜色
  4826. borderColor: "rgba(50,50,50,0.7)",
  4827. textStyle: {
  4828. color: "#fff",
  4829. fontStyle: "normal", // 文字字体的风格('normal',无样式;'italic',斜体;'oblique',倾斜字体)
  4830. fontWeight: "normal", // 文字字体的粗细('normal',无样式;'bold',加粗;'bolder',加粗的基础上再加粗;'lighter',变细;数字定义粗细也可以,取值范围100至700)
  4831. fontSize: "28", // 文字字体大小
  4832. },
  4833. },
  4834. grid: {
  4835. left: "4%",
  4836. right: "4%",
  4837. bottom: "3%",
  4838. top: "15%",
  4839. containLabel: true
  4840. },
  4841. xAxis: {
  4842. data: xdata,
  4843. triggerEvent: true,
  4844. axisTick: {
  4845. show: false
  4846. },
  4847. axisLine: {
  4848. show: false
  4849. },
  4850. axisLabel: {
  4851. show: true,
  4852. rotate: 0,
  4853. interval: 0,
  4854. textStyle: {
  4855. padding: [14, 0, 0, 0],
  4856. fontSize: 14,
  4857. color: "rgba(255,255,255,1)"
  4858. }
  4859. }
  4860. },
  4861. yAxis: {
  4862. name: "单位:个数",
  4863. triggerEvent: true,
  4864. nameTextStyle: {
  4865. color: "rgba(255,255,255,1)",
  4866. fontSize: 16,
  4867. padding: [0, 0, 10, -20]
  4868. },
  4869. splitLine: {
  4870. show: true,
  4871. lineStyle: {
  4872. color: 'rgba(255,255,255,.1)'
  4873. }
  4874. },
  4875. axisTick: {
  4876. show: false
  4877. },
  4878. axisLine: {
  4879. show: true,
  4880. lineStyle: {
  4881. color: 'rgba(255,255,255,.1)'
  4882. }
  4883. },
  4884. axisLabel: {
  4885. show: true,
  4886. textStyle: {
  4887. color: "rgb(148,159,167)",
  4888. fontSize: 16
  4889. }
  4890. }
  4891. },
  4892. series: [
  4893. {
  4894. name: "数量",
  4895. type: "pictorialBar",
  4896. barCategoryGap: "60%",
  4897. // symbol: 'path://M0,10 L10,10 L5,0 L0,10 z',
  4898. symbol: "path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z",
  4899. itemStyle: {
  4900. normal: {
  4901. //渐变色
  4902. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
  4903. offset: 0,
  4904. color: "#01EAED"
  4905. },
  4906. {
  4907. offset: 0.5,
  4908. color: "#02C4DD"
  4909. },
  4910. {
  4911. offset: 1,
  4912. color: "#029ED9"
  4913. }
  4914. ])
  4915. }
  4916. },
  4917. label: {
  4918. normal: {
  4919. show: false,
  4920. position: "top",
  4921. textStyle: {
  4922. color: "#fff",
  4923. fontSize: 20
  4924. }
  4925. }
  4926. },
  4927. data: data,
  4928. }
  4929. ]
  4930. }
  4931. //轮播
  4932. tools.loopShowTooltip(that.leftEcharts15, option, {
  4933. interval: 2000,
  4934. loopSeries: true,
  4935. });
  4936. //注册
  4937. that.leftEcharts15.setOption(option);
  4938. },
  4939. leftEcharts16Fun () {
  4940. let that = this;
  4941. this.leftEcharts16 = echarts.init(this.$refs["leftEcharts16"]);
  4942. // var ROOT_PATH = 'https://echarts.apache.org/examples';
  4943. let option = {
  4944. backgroundColor: "#00000000",
  4945. globe: {
  4946. globeRadius: 85,
  4947. baseTexture: "./img/3D/world1.jpg",
  4948. heightTexture: "./img/3D/world1.jpg",
  4949. displacementScale: 0.04,
  4950. shading: "realistic",
  4951. // environment: './img/3D/world2.jpg',
  4952. realisticMaterial: {
  4953. roughness: 0.9,
  4954. },
  4955. postEffect: {
  4956. enable: true,
  4957. },
  4958. light: {
  4959. main: {
  4960. intensity: 1,
  4961. shadow: true,
  4962. },
  4963. },
  4964. },
  4965. };
  4966. that.leftEcharts16.setOption(option);
  4967. },
  4968. // 回到中国地图
  4969. backChina () {
  4970. let that = this
  4971. if (!this.mapShow) {
  4972. return
  4973. }
  4974. this.mapShow = false
  4975. that.leftEcharts12.dispose()
  4976. that.leftEcharts14.dispose()
  4977. that.leftEcharts9.dispose()
  4978. that.leftEcharts15.dispose()
  4979. that.leftEcharts13.dispose()
  4980. that.shanxiMap.dispose()
  4981. setTimeout(() => {
  4982. that.chinaEchartsFun()
  4983. that.leftEcharts16Fun()
  4984. });
  4985. },
  4986. },
  4987. });