investHomeGroup.js 196 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023
  1. let app = new Vue({
  2. el: '#app',
  3. data () {
  4. return {
  5. boardType: '', // 哪边的项目看板
  6. pullShow: false, // 选择年份弹窗
  7. pollList: [2021, 2022, 2023, 2024],
  8. mockData: true,// 是否使用修改的数据
  9. year: 2023, // 选择的年份
  10. boardUrl: '', // 跳转路径
  11. boardTipShow: false, // 项目看板弹窗专用
  12. lineCommonCompany: [], //双柱状图弹窗上面的折线图x轴
  13. commonCompanyAll: [], // 公司包括编码
  14. changeLine: true,
  15. versions: false, // 是否使用接口数据数据
  16. app_token: '',
  17. centerShow: false, // 中间内容显示
  18. echartR4Chart: '',// 倒数第二个专用
  19. echartR5Chart: '', // 倒是第一个专用
  20. myChartTip1: '', // 弹窗单个柱状图专用
  21. myChartTip2: '', // 弹窗两个柱状图专用
  22. myChartTip3: '', // 弹窗两个柱状图专用
  23. echartEnterpriseShow: false, // 企业额度分析控制
  24. mapChart: '',//地图专用echarts
  25. chartCarousel: '',//做大屏轮播专用echarts
  26. mapTipShow: false,
  27. echartSingleTipShow: false,
  28. echartDoubleTipShow: false,
  29. projectListTipShow: false, //项目列表专属弹窗
  30. titleUrl: '',
  31. titleName: '',
  32. yellowCount: 0, // 黄圈轮播参数
  33. yellowPosition: 40,// 黄圈悬浮窗位置参数
  34. yellowType: true, // 黄圈悬浮停止轮播
  35. echartR1Fd: true,
  36. echartR2Fd: true,
  37. echartC2Fd: true,
  38. echartR3Fd: true,
  39. echarts1Time: 16000,
  40. time: '',
  41. timer: '',
  42. timer2: '',
  43. center1: center1,
  44. showTip2: false,
  45. showTip3: false,
  46. list: [],
  47. count: 0,
  48. countType: 0,
  49. geoCoordMap: {},
  50. storageRecordConfig2: center9,
  51. titleList: right1,
  52. centerLeftList: right3,
  53. storageRecordConfig: left11,
  54. config5: {
  55. rowNum: 9,
  56. waitTime: 2000,
  57. headerHeight: '40',
  58. header: ["项目名称", "所属组织", '实施主体', '建设性质(新建/续建)', '产业类别', '建设地点', '2022年投资完成额(万元)'],
  59. data: [
  60. ["青银二广高速公路太原联络线建设PPP项目", "交控集团", "山西路桥建设集团有限公司", "新建", "交通运输业", "山西省太原市、晋中市", "148,086.00"],
  61. ["国道241、省道岚马线汾河水库段改线工程", "交控集团", "太原国省道汾河水库段建设管理有限公司", "续建", "交通运输业", "山西省 太原市、吕梁市", "165,314.33"],
  62. ["路桥科技中心", "交控集团", "山西路桥集团多经营有限公司", "续建", "建筑房地产", "山西省太原市", "8,098.26"],
  63. ["路桥科研基地", "交控集团", "山西路桥集团多经有限公司", "续建", "建筑房地产", "山西省太原市", "6,596.56"],
  64. ["武宿高速充电站建设", "交控集团", "山西交通运输投融资集团有限责任公司", "新建", "新能源", "山西省太原市", "100.00"],
  65. ["山西交通研创商务基地项目", "交控集团", "山西交通物流集团有限公司", "续建", "建筑房地产", "山西省太原市", "4,097.00"],
  66. ["山西省交通科学研究院产业化基地", "交控集团", "山西省交通科技研发有限公司", "续建", "建筑房地产", "山西省太原市武洛街27号", "3,242.00"],
  67. ["太长高速公路太原南收费站(二期工程暨龙城服务区)项目", "交控集团", "山西省交通开发投资集团有限公司龙城服务区发展分公司", "续建", "建筑房地产", "山西省太原市", "3,580.00"],
  68. ["山西转型综改示范区中小企业产业园项目", "交控集团", "山西交投综改园区开发有限公司", "续建", "建筑房地产", "山西省太原市", "14,432.00"]
  69. ],
  70. align: ["center", "center", "center", "center", "center", "center", "center"],
  71. headerBGC: "#153A62",
  72. oddRowBGC: "#061F42",
  73. evenRowBGC: "#0C284A",
  74. },
  75. originalConfig6: [],
  76. config6: listPop
  77. }
  78. },
  79. created () {
  80. this.time = formatDate()
  81. this.timer = setInterval(() => {
  82. this.time = formatDate()
  83. }, 1000)
  84. this.timer2 = setInterval(() => {
  85. this.yellowType && this.changeYellow()
  86. }, 2000)
  87. },
  88. beforeDestroy () {
  89. if (this.timer) {
  90. clearInterval(this.timer);
  91. }
  92. if (this.timer2) {
  93. clearInterval(this.timer2);
  94. }
  95. },
  96. mounted () {
  97. this.comeIn()
  98. },
  99. methods: {
  100. comeIn () {
  101. if (this.versions) {
  102. // 接口版
  103. this.getAppToken()
  104. setTimeout(() => {
  105. this.changeTopColor()
  106. // 大屏三
  107. this.initChartR5()
  108. this.changeYellow()
  109. })
  110. } else {
  111. // 假数据版
  112. setTimeout(() => {
  113. this.initChartL1()
  114. this.initChartL2()
  115. this.initChartL3()
  116. this.initChartL4()
  117. this.initChartL5()
  118. this.initChartL6()
  119. this.initChartL7()
  120. this.initChartL8()
  121. this.initChartL10()
  122. this.initChartL11()
  123. this.changeTopColor()
  124. // 大屏二
  125. this.initChinaChart()
  126. // 大屏三
  127. this.initChartR1()
  128. this.initChartR2()
  129. this.initChartR3()
  130. this.changeYellow()
  131. })
  132. }
  133. },
  134. chooseTime (value) {
  135. let that = this
  136. this.year = value
  137. that.destroyCharts()
  138. this.pullShow = false
  139. setTimeout(item => {
  140. that.comeIn()
  141. })
  142. },
  143. destroyCharts () {
  144. this.left10Chart ? this.left10Chart.dispose() : ''
  145. this.left1Chart ? this.left1Chart.destroy() : ''
  146. this.left2Chart ? this.left2Chart.destroy() : ''
  147. this.left3Chart ? this.left3Chart.destroy() : ''
  148. this.left4Chart ? this.left4Chart.destroy() : ''
  149. this.left5Chart ? this.left5Chart.destroy() : ''
  150. this.left6Chart ? this.left6Chart.destroy() : ''
  151. this.left7Chart ? this.left7Chart.dispose() : ''
  152. this.left8Chart ? this.left8Chart.dispose() : ''
  153. this.left9Chart ? this.left9Chart.dispose() : ''
  154. this.chartCarousel ? this.chartCarousel.dispose() : ''
  155. this.myChartTip1 ? this.myChartTip1.dispose() : ''
  156. this.myChartTip2 ? this.myChartTip2.dispose() : ''
  157. this.myChartTip3 ? this.myChartTip3.dispose() : ''
  158. this.left11Chart ? this.left11Chart.dispose() : ''
  159. this.right1Chart ? this.right1Chart.dispose() : ''
  160. this.right2Chart ? this.right2Chart.dispose() : ''
  161. this.right3Chart ? this.right3Chart.dispose() : ''
  162. this.echartR4Chart ? this.echartR4Chart.dispose() : ''
  163. this.echartR5Chart ? this.echartR5Chart.dispose() : ''
  164. this.center1Chart ? this.center1Chart.destroy() : ''
  165. this.center2Chart ? this.center2Chart.dispose() : ''
  166. this.center3Chart ? this.center3Chart.dispose() : ''
  167. this.center4Chart ? this.center4Chart.destroy() : ''
  168. this.mapChart ? this.mapChart.dispose() : ''
  169. },
  170. // 获取token
  171. getAppToken () {
  172. // dev环境
  173. // let value = {
  174. // "appId": "xilan1014", //系统编码
  175. // "appSecret": "12345678910Aa@Bb@Cc", //AccessToken加密认证密钥
  176. // "tenantid": "", //租户id
  177. // "accountId": "", //数据中心id
  178. // "language": "zh_CN"
  179. // }
  180. // SIT环境
  181. let value = {
  182. "appId": "68dp",
  183. "appSecret": "9ErhY^O{n?@Pc#eb7HYX",
  184. "tenantid": "",
  185. "accountId": "1635498801198269440",
  186. "language": "zh_CN"
  187. }
  188. post('/ierp/api/getAppToken.do', value).then(res => {
  189. this.app_token = res.data.app_token
  190. this.getAccessToken()
  191. })
  192. },
  193. // 获取AccessToken
  194. getAccessToken () {
  195. let value = {
  196. "user": "19900000001", //登录用户手机号
  197. "apptoken": this.app_token, //应用令牌
  198. "tenantid": "", //租户id
  199. "accountId": "1635498801198269440",//数据中心id
  200. "usertype": "Mobile"
  201. }
  202. post('/ierp/api/login.do', value).then(res => {
  203. this.access_token = res.data.access_token
  204. this.getOrg()
  205. })
  206. },
  207. // 获取组织架构列表
  208. getOrg () {
  209. return new Promise((resolve, err) => {
  210. let value = {
  211. access_token: this.access_token,
  212. }
  213. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getOrgName', value).then(res => {
  214. this.commonCompanyAll = res.data
  215. commonCompany = res.data.map(item => item.simplename)
  216. // 左边
  217. this.getDate1()
  218. this.getDate2()
  219. this.getDate3()
  220. this.getDate4()
  221. this.getDate5()
  222. this.getDate6()
  223. // 右边
  224. this.getDate7()
  225. this.getDate8()
  226. this.getDate9()
  227. this.getDate10()
  228. // this.getDate11() // 右下A
  229. this.getDate12() // 右下B
  230. // 中间
  231. this.getDate14()
  232. resolve(1);
  233. })
  234. });
  235. },
  236. // 获取左边企业额度分析
  237. getDate1 () {
  238. let that = this
  239. return new Promise((resolve, err) => {
  240. let value = {
  241. access_token: this.access_token,
  242. "data": {
  243. "mdnb_combofield": this.mockData ? 'B' : 'A',
  244. "mdnb_datefield": this.year + '-01-01',
  245. },
  246. pageSize: 1000
  247. }
  248. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqqyedfx', value).then(res => {
  249. if (res.data.rows.length > 0) {
  250. let dataList = res.data.rows[0].entryentity
  251. left3 = [[], [], []]
  252. dataList.forEach(item => {
  253. // 已用额度
  254. left3[0].push(that.yuanChange(item.mdnb_amountfield26))
  255. // 剩余额度
  256. left3[1].push(that.yuanChange(item.mdnb_amountfield27))
  257. // 总额度
  258. left3[2].push(that.yuanChange(item.mdnb_amountfield25))
  259. })
  260. this.initChartL4(dataList)
  261. }
  262. resolve(1);
  263. })
  264. });
  265. },
  266. // 获取左边投资计划分析
  267. getDate2 () {
  268. let that = this
  269. return new Promise((resolve, err) => {
  270. let value = {
  271. access_token: this.access_token,
  272. "data": {
  273. "mdnb_combofield": this.mockData ? 'B' : 'A',
  274. "mdnb_datefield": this.year + '-01-01',
  275. },
  276. pageSize: 1000
  277. }
  278. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqtzjhfx', value).then(res => {
  279. if (res.data.rows.length > 0) {
  280. let dataList = res.data.rows[0]
  281. left4 = []
  282. left4[0] = dataList.mdnb_amountfield7
  283. left4[1] = dataList.mdnb_amountfield13
  284. left4[2] = dataList.mdnb_amountfield23
  285. left4[3] = dataList.mdnb_amountfield43
  286. left4[4] = dataList.mdnb_integerfield14
  287. left5[0].y = that.yuanChange(dataList.mdnb_amountfield9)
  288. left5[0].num = dataList.mdnb_integerfield15
  289. left5[1].y = that.yuanChange(dataList.mdnb_amountfield43)
  290. left5[1].num = dataList.mdnb_integerfield14
  291. left6[0].y = that.yuanChange(dataList.mdnb_amountfield15)
  292. left6[0].num = dataList.mdnb_integerfield16
  293. left6[1].y = that.yuanChange(dataList.mdnb_amountfield16)
  294. left6[1].num = dataList.mdnb_integerfield17
  295. that.initChartL2()
  296. that.initChartL3()
  297. }
  298. resolve(1);
  299. })
  300. });
  301. },
  302. // 获取左边产业布局分析
  303. getDate3 () {
  304. let that = this
  305. return new Promise((resolve, err) => {
  306. let value = {
  307. access_token: this.access_token,
  308. "data": {
  309. "mdnb_combofield": this.mockData ? 'B' : 'A',
  310. "mdnb_datefield": this.year + '-01-01',
  311. },
  312. pageSize: 1000
  313. }
  314. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqcebjfx', value).then(res => {
  315. if (res.data.rows.length > 0) {
  316. let dataList = this.classify(res.data.rows[0].mdnb_entryentity, 'mdnb_textfield1')
  317. // 传统产业分析
  318. if (dataList[0]) {
  319. for (let i = 0; i < left7.length; i++) {
  320. left7[i].num = dataList[0].data[i].mdnb_integerfield13
  321. left7[i].y = dataList[0].data[i].mdnb_amountfield8
  322. }
  323. this.initChartL5()
  324. }
  325. // 战略性新兴产业
  326. if (dataList[1]) {
  327. for (let i = 0; i < left8.length; i++) {
  328. left8[i].num = dataList[1].data[i].mdnb_integerfield13
  329. left8[i].y = dataList[1].data[i].mdnb_amountfield8
  330. }
  331. this.initChartL6()
  332. }
  333. // 特色优势产业
  334. if (dataList[2]) {
  335. for (let i = 0; i < left9.length; i++) {
  336. left9[i].num = dataList[2].data[i].mdnb_integerfield13
  337. left9[i].y = dataList[2].data[i].mdnb_amountfield8
  338. }
  339. this.initChartL7()
  340. }
  341. // 公共基础等产业
  342. if (dataList[3]) {
  343. for (let i = 0; i < left10.length; i++) {
  344. left10[i].num = dataList[3].data[i].mdnb_integerfield13
  345. left10[i].y = dataList[3].data[i].mdnb_amountfield8
  346. }
  347. this.initChartL8()
  348. }
  349. }
  350. resolve(1);
  351. })
  352. });
  353. },
  354. // 获取左边项目阶段分析
  355. getDate4 () {
  356. let that = this
  357. return new Promise((resolve, err) => {
  358. let value = {
  359. access_token: this.access_token,
  360. "data": {
  361. "mdnb_combofield": this.mockData ? 'B' : 'A',
  362. "mdnb_datefield": this.year + '-01-01',
  363. },
  364. pageSize: 1000
  365. }
  366. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqxmjdfx', value).then(res => {
  367. if (res.data.rows.length > 0) {
  368. let dataList = res.data.rows[0]
  369. // 固定资产进度分布
  370. // 特别监管
  371. left13[0][0][2] = dataList.mdnb_integerfield1
  372. left13[0][0][3] = this.yuanChange(dataList.mdnb_amountfield241)
  373. left13[0][1][2] = dataList.mdnb_integerfield3
  374. left13[0][1][3] = this.yuanChange(dataList.mdnb_amountfield5)
  375. left13[0][2][2] = dataList.mdnb_integerfield5
  376. left13[0][2][3] = this.yuanChange(dataList.mdnb_amountfield21)
  377. left13[0][3][2] = dataList.mdnb_integerfield7
  378. left13[0][3][3] = this.yuanChange(dataList.mdnb_amountfield29)
  379. // 备案
  380. left13[1][0][2] = dataList.mdnb_integerfield2
  381. left13[1][0][3] = this.yuanChange(dataList.mdnb_amountfield341)
  382. left13[1][1][2] = dataList.mdnb_integerfield4
  383. left13[1][1][3] = this.yuanChange(dataList.mdnb_amountfield11)
  384. left13[1][2][2] = dataList.mdnb_integerfield6
  385. left13[1][2][3] = this.yuanChange(dataList.mdnb_amountfield28)
  386. left13[1][3][2] = dataList.mdnb_integerfield8
  387. left13[1][3][3] = this.yuanChange(dataList.mdnb_amountfield30)
  388. // 股权类进度分布
  389. // 特别监管
  390. left14[0][0][2] = dataList.mdnb_integerfield11
  391. left14[0][0][3] = this.yuanChange(dataList.mdnb_amountfield2411)
  392. left14[0][1][2] = dataList.mdnb_integerfield31
  393. left14[0][1][3] = this.yuanChange(dataList.mdnb_amountfield51)
  394. left14[0][2][2] = dataList.mdnb_integerfield51
  395. left14[0][2][3] = this.yuanChange(dataList.mdnb_amountfield211)
  396. left14[0][3][2] = dataList.mdnb_integerfield71
  397. left14[0][3][3] = this.yuanChange(dataList.mdnb_amountfield291)
  398. // 备案
  399. left14[1][0][2] = dataList.mdnb_integerfield21
  400. left14[1][0][3] = this.yuanChange(dataList.mdnb_amountfield3411)
  401. left14[1][1][2] = dataList.mdnb_integerfield41
  402. left14[1][1][3] = this.yuanChange(dataList.mdnb_amountfield111)
  403. left14[1][2][2] = dataList.mdnb_integerfield61
  404. left14[1][2][3] = this.yuanChange(dataList.mdnb_amountfield281)
  405. left14[1][3][2] = dataList.mdnb_integerfield81
  406. left14[1][3][3] = this.yuanChange(dataList.mdnb_amountfield301)
  407. this.initChartL10()
  408. this.initChartL11()
  409. }
  410. resolve(1);
  411. })
  412. });
  413. },
  414. // 获取左边投资额度分析
  415. getDate5 () {
  416. let that = this
  417. return new Promise((resolve, err) => {
  418. let value = {
  419. access_token: this.access_token,
  420. "data": {
  421. "mdnb_combofield": this.mockData ? 'B' : 'A',
  422. "mdnb_datefield": this.year + '-01-01',
  423. },
  424. pageSize: 1000
  425. }
  426. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqtzedfx', value).then(res => {
  427. if (res.data.rows.length > 0) {
  428. let dataList = res.data.rows[0]
  429. left1[0] = dataList.mdnb_amountfield
  430. left1[1] = dataList.mdnb_amountfield1
  431. left1[2] = dataList.mdnb_amountfield2
  432. left2[0] = dataList.mdnb_decimalfield
  433. left2[1] = dataList.mdnb_amountfield3
  434. this.initChartL1()
  435. }
  436. resolve(1);
  437. })
  438. });
  439. },
  440. // 获取左边重点项目两线指标
  441. getDate6 () {
  442. let that = this
  443. return new Promise((resolve, err) => {
  444. let value = {
  445. access_token: this.access_token,
  446. "data": {
  447. "mdnb_combofield": this.mockData ? 'B' : 'A',
  448. "mdnb_datefield": this.year + '-01-01',
  449. },
  450. pageSize: 1000
  451. }
  452. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tqzdlxzb', value).then(res => {
  453. if (res.data.rows.length > 0) {
  454. let dataList2 = this.classify(res.data.rows[0].mdnb_entryentity1, 'mdnb_textfield3')
  455. // 右边的柱状图
  456. left12 = []
  457. dataList2.forEach((item, index) => {
  458. left12[index] = [[], [], []]
  459. for (let i = 0; i < 5; i++) {
  460. left12[index][0].push(item.data[i].mdnb_integerfield10)
  461. left12[index][1].push(item.data[i].mdnb_integerfield12)
  462. left12[index][2].push(item.data[i].mdnb_integerfield9)
  463. }
  464. })
  465. that.initChartL9()
  466. // 左边的轮播
  467. let dataList = []
  468. dataList2.forEach((item, index) => {
  469. dataList[index] = []
  470. dataList[index][0] = item.data[0].mdnb_textfield18
  471. dataList[index][1] = item.data[0].mdnb_textfield3
  472. dataList[index][2] = that.yuanChange(item.data[0].mdnb_amountfield24) + '亿'
  473. })
  474. this.storageRecordConfig.data = dataList
  475. this.storageRecordConfig = { ...this.storageRecordConfig }
  476. }
  477. resolve(1);
  478. })
  479. });
  480. },
  481. // 获取右边顶部条数据
  482. getDate7 () {
  483. return new Promise((resolve, err) => {
  484. let value = {
  485. access_token: this.access_token,
  486. "request": {
  487. isInsert: this.mockData ? '1' : '0',
  488. },
  489. pageSize: 1000
  490. }
  491. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getTabpageap', value).then(res => {
  492. right1[0].number = res.data.mdnb_one_step
  493. right1[2].number = res.data.mdnb_two_step
  494. right1[4].number = res.data.mdnb_three_step
  495. right1[6].number = res.data.mdnb_four_step
  496. right1[8].number = res.data.mdnb_five_step
  497. right1[10].number = res.data.mdnb_six_step
  498. right1[12].number = res.data.mdnb_seven_step
  499. right1[14].number = res.data.mdnb_eight_step
  500. resolve(1);
  501. })
  502. });
  503. },
  504. // 获取右边中间左边的(正偏差/容差内/负偏差)
  505. getDate8 () {
  506. return new Promise((resolve, err) => {
  507. let value = {
  508. access_token: this.access_token,
  509. "request": {
  510. isInsert: this.mockData ? '1' : '0',
  511. },
  512. pageSize: 1000
  513. }
  514. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getInvestSunstraction', value).then(res => {
  515. right3[0].value = res.data.mdnb_projectnum_z
  516. right3[0].value2 = res.data.mdnb_amountall_z
  517. right3[1].value = res.data.mdnb_projectnum_r
  518. right3[1].value2 = res.data.mdnb_amountall_r
  519. right3[2].value = res.data.mdnb_projectnum_f
  520. right3[2].value2 = res.data.mdnb_amountall_f
  521. resolve(1);
  522. })
  523. });
  524. },
  525. // 获取右边中间右边的(预算额/已签合同额。。。)
  526. getDate9 () {
  527. return new Promise((resolve, err) => {
  528. let value = {
  529. access_token: this.access_token,
  530. "request": {
  531. isInsert: this.mockData ? '1' : '0',
  532. },
  533. pageSize: 1000
  534. }
  535. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getUnitBudgetExecuteDate', value).then(res => {
  536. res.data.forEach((item, index) => {
  537. right4[index].value = this.yuanChange(item.mdnb_aheadmoney)
  538. right4[index].value2 = this.yuanChange(item.mdnb_edmoney)
  539. right4[index].value3 = this.yuanChange(item.mdnb_smoney)
  540. right4[index].value4 = this.yuanChange(item.mdnb_jmoney)
  541. right4[index].value5 = this.yuanChange(item.mdnb_fkmoney)
  542. })
  543. this.initChartR1()
  544. resolve(1);
  545. })
  546. });
  547. },
  548. // 进度成本偏差
  549. getDate10 () {
  550. let that = this
  551. return new Promise((resolve, err) => {
  552. let value = {
  553. access_token: this.access_token,
  554. "request": {
  555. isInsert: this.mockData ? '1' : '0',
  556. },
  557. pageSize: 1000
  558. }
  559. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getInvestSunstractionGas', value).then(res => {
  560. res.data.forEach((item, index) => {
  561. right5[0][index][1] = item.mdnb_amount_zb
  562. right5[0][index][2] = that.yuanChange(item.mdnb_amount_z)
  563. right5[1][index][1] = item.mdnb_amount_nb
  564. right5[1][index][2] = that.yuanChange(item.mdnb_amount_n)
  565. right5[2][index][1] = item.mdnb_amount_fb
  566. right5[2][index][2] = that.yuanChange(item.mdnb_amount_f)
  567. })
  568. this.initChartR2()
  569. resolve(1);
  570. })
  571. });
  572. },
  573. // 项目风险分析A
  574. getDate11 () {
  575. return new Promise((resolve, err) => {
  576. let value = {
  577. access_token: this.access_token,
  578. "request": {
  579. isInsert: this.mockData ? '1' : '0',
  580. },
  581. pageSize: 1000
  582. }
  583. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getUnitNoSolveDangerDate', value).then(res => {
  584. res.data.forEach((item, index) => {
  585. right6[index].value = item.mdnb_height
  586. right6[index].value2 = item.mdnb_midle
  587. right6[index].value3 = item.mdnb_bottom
  588. })
  589. this.initChartR3()
  590. resolve(1);
  591. })
  592. });
  593. },
  594. // 项目风险分析B(雷达图)
  595. getDate12 () {
  596. return new Promise((resolve, err) => {
  597. let value = {
  598. access_token: this.access_token,
  599. "request": {
  600. isInsert: this.mockData ? '1' : '0',
  601. },
  602. pageSize: 1000
  603. }
  604. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getUnitDangerPoraitDate', value).then(res => {
  605. res.data.forEach((item, index) => {
  606. right7[index][0] = item.mdnb_anquan
  607. right7[index][1] = item.mdnb_fukuan
  608. right7[index][2] = item.mdnb_hetong
  609. right7[index][3] = item.mdnb_jiesuan
  610. right7[index][4] = item.mdnb_jindu
  611. right7[index][5] = item.mdnb_securty
  612. })
  613. this.getDate11()
  614. resolve(1);
  615. })
  616. });
  617. },
  618. // 中间大屏数据
  619. getDate14 () {
  620. let that = this
  621. return new Promise((resolve, err) => {
  622. let value = {
  623. access_token: this.access_token,
  624. mock: this.mockData,
  625. presetYear: this.year
  626. }
  627. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/presetdata/getKeyData', value).then(res => {
  628. // 头部指标
  629. center4[0] = res.data.transformations.estateAmount
  630. center4[1] = res.data.transformations.estateNum
  631. center4[2] = res.data.transformations.figureAmount
  632. center4[3] = res.data.transformations.figureNum
  633. // 左投部指标
  634. center1[0] = res.data.keyIndicators.totalSum
  635. center1[1] = res.data.keyIndicators.total
  636. center1[2] = res.data.keyIndicators.property
  637. center1[3] = res.data.keyIndicators.invest
  638. // 投资产业分布
  639. for (let i = 0; i < center2.length; i++) {
  640. center2[i].y = that.yuanChange(res.data.distribution[i].amount)
  641. center2[i].num = res.data.distribution[i].count
  642. center2[i].typeno = res.data.distribution[i].typeno
  643. }
  644. // 投资执行情况
  645. res.data.implementationStatus.forEach((item, index) => {
  646. center3[index].value = that.yuanChange(item.plan)
  647. center3[index].value2 = that.yuanChange(item.reality)
  648. })
  649. // 五个一体化
  650. res.data.five.forEach((item, index) => {
  651. center6[index] = { name: item.type, value: that.yuanChange(item.amount), typeno: item.typeno }
  652. })
  653. // 投资阶段分析
  654. res.data.investmentStage.forEach((item, index) => {
  655. center7[index] = { name: item.type, value: Number(item.num), value2: that.yuanChange(item.amount), typeno: item.typeno, sliced: false, selected: false }
  656. })
  657. // 重点项目监控
  658. center8 = []
  659. this.originalConfig6 = res.data.projectMonitoring
  660. res.data.projectMonitoring.forEach((item, index) => {
  661. center8.push({ value: item.amount, name: item.name, office: item.group })
  662. })
  663. // 中国地图
  664. centerChina = []
  665. res.data.investmentMap.forEach((item, index) => {
  666. centerChina.push({ name: item.address, value: that.yuanChange(item.amount), value2: item.value2 })
  667. })
  668. // 项目状态
  669. proState.projectStatus1 = res.data.projectStatus.projectStatus1
  670. proState.projectStatus2 = res.data.projectStatus.projectStatus2
  671. proState.projectStatus3 = res.data.projectStatus.projectStatus3
  672. setTimeout(() => {
  673. that.initChinaChart()
  674. })
  675. resolve(1);
  676. })
  677. });
  678. },
  679. // 右边穿透一级
  680. rightPenetrateOne () {
  681. this.boardType = 'right'
  682. return new Promise((resolve, err) => {
  683. let value = {
  684. access_token: this.access_token,
  685. "request": {
  686. isInsert: this.mockData ? '1' : '0'
  687. },
  688. pageSize: 1000
  689. }
  690. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getOneLevelData', value).then(res => {
  691. res.data.forEach((item, index) => {
  692. common4[index] = item.mdnb_projects
  693. common5[index] = item.mdnb_amount_sl
  694. })
  695. setTimeout(() => {
  696. this.initChartLTip2('right')
  697. this.initChartLTip3('right')
  698. })
  699. resolve(1);
  700. })
  701. });
  702. },
  703. // 右边穿透二级
  704. rightPenetrateTwo (modelName, substraction, orgName) {
  705. this.boardType = 'right'
  706. let that = this
  707. return new Promise((resolve, err) => {
  708. let value = {
  709. access_token: this.access_token,
  710. "request": {
  711. isInsert: this.mockData ? '1' : '0',
  712. modelName,
  713. substraction,
  714. orgName
  715. },
  716. pageSize: 1000
  717. }
  718. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_middle/getTwoLevelData', value).then(res => {
  719. that.config6.data = []
  720. that.originalConfig6 = res.data
  721. that.config6.header[5] = '投资总额(亿)'
  722. res.data.forEach((item, index) => {
  723. that.config6.data[index] = []
  724. that.config6.data[index][0] = item.mdnb_project_name
  725. that.config6.data[index][1] = item.mdnb_org
  726. that.config6.data[index][2] = item.mdnb_implement_org
  727. that.config6.data[index][3] = item.mdnb_insdrutytype1
  728. that.config6.data[index][4] = item.mdnb_insdrutytype2
  729. that.config6.data[index][5] = item.mdnb_investment_money
  730. })
  731. that.config6 = { ...that.config6 }
  732. that.projectListTipShow = true
  733. resolve(1);
  734. })
  735. });
  736. },
  737. // 左边穿透一级
  738. leftPenetrateOne (mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, typeNum, type, param, typeCTwo, paramCTwo) {
  739. this.boardType = 'left'
  740. return new Promise((resolve, err) => {
  741. let value = {
  742. access_token: this.access_token,
  743. "data": {
  744. mdnb_combofield: this.mockData ? 'B' : 'A',
  745. mdnb_textfield11,
  746. mdnb_textfield13,
  747. mdnb_textfield16,
  748. mdnb_textfield23,
  749. mdnb_datefield: this.year + '-01-01'
  750. },
  751. pageSize: 1000
  752. }
  753. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/yjct', value).then(res => {
  754. if (res.data.rows.length > 0) {
  755. if (typeNum == 2) {
  756. common4 = []
  757. common5 = []
  758. res.data.rows[0].mdnb_entryentity12.forEach((item, index) => {
  759. common4.push(item.mdnb_integerfield18)
  760. common5.push(item.mdnb_amountfield12)
  761. })
  762. setTimeout(() => {
  763. this.initChartLTip2('left', mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo)
  764. this.initChartLTip3('left', mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo)
  765. })
  766. } else if (typeNum == 1) {
  767. this.initChartLTip('left', mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo)
  768. }
  769. }
  770. resolve(1);
  771. })
  772. });
  773. },
  774. // 左边穿透二级
  775. leftPenetrateTwo (mdnb_textfield12, mdnb_textfield19, mdnb_textfield15, mdnb_textfield17, mdnb_textfield20) {
  776. this.boardType = 'left'
  777. let that = this
  778. if (that.versions) {
  779. return new Promise((resolve, err) => {
  780. let value = {
  781. access_token: this.access_token,
  782. "data": {
  783. mdnb_combofield: this.mockData ? 'B' : 'A',
  784. mdnb_datefield: this.year + '-01-01',
  785. mdnb_textfield12,
  786. mdnb_textfield19,
  787. mdnb_textfield15,
  788. mdnb_textfield17,
  789. mdnb_textfield20
  790. },
  791. pageSize: 1000
  792. }
  793. that.config6.header[5] = '年投资完成额(亿)'
  794. if (mdnb_textfield20) {
  795. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/ejct', value).then(res => {
  796. that.config6.data = []
  797. if (res.data.rows.length > 0) {
  798. that.originalConfig6 = res.data.rows[0].mdnb_entryentity11
  799. that.config6.data = []
  800. res.data.rows[0].mdnb_entryentity11.forEach((item, index) => {
  801. that.config6.data[index] = []
  802. that.config6.data[index][0] = item.mdnb_textfield6
  803. that.config6.data[index][1] = item.mdnb_textfield7
  804. that.config6.data[index][2] = item.mdnb_textfield8
  805. that.config6.data[index][3] = item.mdnb_textfield9
  806. that.config6.data[index][4] = item.mdnb_textfield10
  807. that.config6.data[index][5] = item.mdnb_amountfield22
  808. })
  809. }
  810. that.config6 = { ...that.config6 }
  811. that.projectListTipShow = true
  812. resolve(1);
  813. })
  814. } else {
  815. post('/ierp/kapi/v2/mdnb/mdnb_xmkb/mdnb_manager_preinvest/tzedfxzed', value).then(res => {
  816. if (res.data.rows.length > 0) {
  817. that.originalConfig6 = res.data.rows[0].mdnb_entryentity11
  818. that.config6.data = []
  819. res.data.rows[0].mdnb_entryentity11.forEach((item, index) => {
  820. that.config6.data[index] = []
  821. that.config6.data[index][0] = item.mdnb_textfield6
  822. that.config6.data[index][1] = item.mdnb_textfield7
  823. that.config6.data[index][2] = item.mdnb_textfield8
  824. that.config6.data[index][3] = item.mdnb_textfield9
  825. that.config6.data[index][4] = item.mdnb_textfield10
  826. that.config6.data[index][5] = item.mdnb_amountfield22
  827. })
  828. that.config6 = { ...that.config6 }
  829. that.projectListTipShow = true
  830. }
  831. resolve(1);
  832. })
  833. }
  834. });
  835. } else {
  836. that.projectListTipShow = true
  837. }
  838. },
  839. // 中间穿透一级 一个柱状图还是两个
  840. centerPenetrateOne (type, param, typeNum, typeCTwo, paramCTwo, portType) {
  841. this.boardType = 'center'
  842. let that = this
  843. return new Promise((resolve, err) => {
  844. let value = {
  845. access_token: this.access_token,
  846. mock: this.mockData,
  847. presetYear: this.year,
  848. type,
  849. param
  850. }
  851. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/presetdata/getPenetrationLevel1', value).then(res => {
  852. if (typeNum == 1) {
  853. common3 = []
  854. res.data.keyIndicators.forEach((item, index) => {
  855. if (param == 'cyplanamount') {
  856. common3.push(item.cyplanamount)
  857. }
  858. if (param == 'cyplancount') {
  859. common3.push(item.cyplanamount)
  860. }
  861. if (param == 'szplanamount') {
  862. common3.push(item.cyplanamount)
  863. }
  864. if (param == 'szplancount') {
  865. common3.push(item.szplancount)
  866. }
  867. if (param == 'investamount') {
  868. common3.push(item.investamount)
  869. }
  870. if (param == 'projectcount') {
  871. common3.push(item.projectcount)
  872. }
  873. if (param == 'gdzcamount') {
  874. common3.push(item.projectcount)
  875. }
  876. if (param == 'gqtzamount') {
  877. common3.push(item.projectcount)
  878. }
  879. if (param == 'ceiamount') {
  880. common3.push(item.ceiamount)
  881. }
  882. if (param == 'cpneiamount') {
  883. common3.push(item.cpneiamount)
  884. }
  885. if (param == 'ccheiamount') {
  886. common3.push(item.ccheiamount)
  887. }
  888. if (param == 'cdiamount') {
  889. common3.push(item.cdiamount)
  890. }
  891. if (param == 'cciamount') {
  892. common3.push(item.cciamount)
  893. }
  894. })
  895. setTimeout(() => {
  896. this.initChartLTip('center', '', '', '', '', typeCTwo, paramCTwo, portType)
  897. })
  898. } else if (typeNum == 2) {
  899. common4 = []
  900. common5 = []
  901. if (type == 'distribution') {
  902. that.changeLine = false
  903. that.lineCommonCompany = res.data.topData.map(item => item.type)
  904. common4 = res.data.topData.map(item => item.amount)
  905. common5 = res.data.bottomData.map(item => item.amount)
  906. } else {
  907. if (param == 'new') {
  908. res.data.keyIndicators.forEach((item, index) => {
  909. common4.push(item.newamount)
  910. common5.push(item.newcount)
  911. })
  912. } else if (param == 'renew') {
  913. res.data.keyIndicators.forEach((item, index) => {
  914. common4.push(item.renewamount)
  915. common5.push(item.renewcount)
  916. })
  917. } else if (param == '太原市') {
  918. res.data.investmentMap.forEach((item, index) => {
  919. common4.push(item.value2)
  920. common5.push(item.amount)
  921. })
  922. }
  923. }
  924. setTimeout(() => {
  925. this.initChartLTip2('center', '', '', '', '', type, param, typeCTwo, paramCTwo, portType)
  926. this.initChartLTip3('center', '', '', '', '', type, param, typeCTwo, paramCTwo, portType)
  927. })
  928. } else if (typeNum == 3) {
  929. // 山西地图
  930. center5 = []
  931. res.data.investmentMap.forEach((item, index) => {
  932. center5.push({ name: item.address, value: that.yuanChange(item.amount), value2: item.value2 })
  933. })
  934. setTimeout(() => {
  935. that.initProvinceChart()
  936. });
  937. }
  938. resolve(1);
  939. })
  940. });
  941. },
  942. // 中间穿透二级
  943. centerPenetrateTwo (type, param, orgNum, portType) {
  944. this.boardType = 'center'
  945. let that = this
  946. return new Promise((resolve, err) => {
  947. let value = {
  948. access_token: this.access_token,
  949. mock: this.mockData,
  950. presetYear: this.year,
  951. type,
  952. param,
  953. orgNum
  954. }
  955. that.config6.header[5] = '年投资完成额(亿)'
  956. if (portType == 1) {
  957. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/presetdata/MainPageMonthReportProject', value).then(res => {
  958. that.config6.data = []
  959. that.originalConfig6 = res.data
  960. res.data.forEach((item, index) => {
  961. that.config6.data[index] = []
  962. that.config6.data[index][0] = item.projectname
  963. that.config6.data[index][2] = item.orgName
  964. that.config6.data[index][5] = item.amount
  965. })
  966. that.config6 = { ...that.config6 }
  967. that.projectListTipShow = true
  968. resolve(1);
  969. })
  970. } else if (portType == 2) {
  971. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/presetdata/MainPagePlanProject', value).then(res => {
  972. that.config6.data = []
  973. that.originalConfig6 = res.data
  974. res.data.forEach((item, index) => {
  975. that.config6.data[index] = []
  976. that.config6.data[index][0] = item.projectname
  977. that.config6.data[index][2] = item.orgName
  978. that.config6.data[index][5] = item.amount
  979. })
  980. that.config6 = { ...that.config6 }
  981. that.projectListTipShow = true
  982. resolve(1);
  983. })
  984. } else {
  985. value = {
  986. access_token: this.access_token,
  987. mock: this.mockData,
  988. presetYear: this.year,
  989. type: 'investmentMap',
  990. param: '太原市',
  991. orgNum
  992. }
  993. get('/ierp/kapi/v2/mdnb/mdnb_xmkb/presetdata/MainPageMonthReportProject', value).then(res => {
  994. that.config6.data = []
  995. that.originalConfig6 = res.data
  996. res.data.forEach((item, index) => {
  997. that.config6.data[index] = []
  998. that.config6.data[index][0] = item.projectname
  999. that.config6.data[index][2] = item.orgName
  1000. that.config6.data[index][5] = item.amount
  1001. })
  1002. that.config6 = { ...that.config6 }
  1003. that.projectListTipShow = true
  1004. resolve(1);
  1005. })
  1006. }
  1007. });
  1008. },
  1009. yellowMouse (index) {
  1010. if (index % 2 == 0) {
  1011. this.yellowCount = index
  1012. this.yellowPosition = (index / 2 - 1) * 315 + 40
  1013. this.yellowType = false
  1014. this.changeYellow()
  1015. }
  1016. },
  1017. // 回到中国地图
  1018. backChina () {
  1019. this.centerShow = false
  1020. this.mapChart.dispose()
  1021. setTimeout(() => {
  1022. this.initChinaChart()
  1023. });
  1024. },
  1025. // 找公司编码
  1026. findCode (code) {
  1027. let a = this.commonCompanyAll.find((item, index) => {
  1028. return item.simplename == code
  1029. })
  1030. return a ? a.number.slice(0, 4) : ''
  1031. },
  1032. // 找项目编码
  1033. findProjectCode (a, b, type) {
  1034. if (type == 'center') {
  1035. let c = this.originalConfig6.find(item => {
  1036. return item.name == b && item.group == a
  1037. })
  1038. return c.typeno
  1039. } else if (type == 'right') {
  1040. let c = this.originalConfig6.find(item => {
  1041. return item.mdnb_project_name == a && item.mdnb_org == b
  1042. })
  1043. return c.mdnb_projectnumber
  1044. } else if (type == 'left') {
  1045. let c = this.originalConfig6.find(item => {
  1046. return item.mdnb_textfield6 == a && item.mdnb_textfield8 == b
  1047. })
  1048. return c.mdnb_textfield14
  1049. }
  1050. },
  1051. // 去项目看板
  1052. goLookBoard (e, f) {
  1053. if (f) {
  1054. this.boardType = f
  1055. this.boardUrl = `http://172.21.3.68:8081/ierp/accessTokenLogin.do?access_token=${this.access_token}&redirect=http://172.21.3.68:8081/ierp/index.html?formId=mdnb_threetoproject&prj=${this.findProjectCode(e.row[0], e.row[1], this.boardType)}`
  1056. } else {
  1057. this.boardUrl = `http://172.21.3.68:8081/ierp/accessTokenLogin.do?access_token=${this.access_token}&redirect=http://172.21.3.68:8081/ierp/index.html?formId=mdnb_threetoproject&prj=${this.findProjectCode(e.row[0], e.row[2], this.boardType)}`
  1058. }
  1059. // this.findProjectCode(e.row[0],e.row[2])
  1060. // 当前页面打开
  1061. // window.location.href = `http://192.168.2.111:8080/ierp/accessTokenLogin.do?access_token=${this.access_token}&redirect=http://192.168.2.111:8080/ierp/index.html?formId=mdnb_threetoproject&prj=PL_ZZGY_0_2023_000036`
  1062. // 新页面打开
  1063. // window.open('http://192.168.2.111:8080/ierp/accessTokenLogin.do?access_token=${this.access_token}&redirect=http://192.168.2.111:8080/ierp/index.html?formId=mdnb_threetoproject&prj=PL_ZZGY_0_2023_000036')
  1064. this.boardTipShow = true
  1065. console.log(this.boardUrl, '跳转去的项目看板地址')
  1066. },
  1067. // 根据key分组
  1068. classify (arr, k) {
  1069. let map = {};
  1070. let myArr = [];
  1071. for (let i = 0; i < arr.length; i++) {
  1072. if (!map[arr[i][k]]) {
  1073. let a = {}
  1074. a[k] = arr[i][k]
  1075. a.data = [arr[i]]
  1076. myArr.push(a)
  1077. map[arr[i][k]] = arr[i]
  1078. } else {
  1079. for (let j = 0; j < myArr.length; j++) {
  1080. if (arr[i][k] === myArr[j][k]) {
  1081. myArr[j].data.push(arr[i]);
  1082. break
  1083. }
  1084. }
  1085. }
  1086. }
  1087. return myArr
  1088. },
  1089. // 两个柱状图的弹窗
  1090. showChartLTipDouble (e, location, mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo, portType) {
  1091. this.titleName = e
  1092. this.closeTap()
  1093. this.echartDoubleTipShow = true
  1094. if (this.versions) {
  1095. if (location == 'right') {
  1096. this.rightPenetrateOne()
  1097. }
  1098. if (location == 'left') {
  1099. this.leftPenetrateOne(mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, 2)
  1100. }
  1101. if (location == 'center') {
  1102. this.centerPenetrateOne(type, param, 2, typeCTwo, paramCTwo, portType)
  1103. }
  1104. } else {
  1105. setTimeout(() => {
  1106. this.initChartLTip2()
  1107. this.initChartLTip3()
  1108. })
  1109. }
  1110. },
  1111. // 单个柱状图的弹窗
  1112. showChartLTipSingle (e, location, type, param, mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, typeCTwo, paramCTwo, portType) {
  1113. this.closeTap()
  1114. this.titleName = e
  1115. this.echartSingleTipShow = true
  1116. if (this.versions) {
  1117. if (location == 'center') {
  1118. this.centerPenetrateOne(type, param, 1, typeCTwo, paramCTwo, portType)
  1119. }
  1120. if (location == 'left') {
  1121. this.leftPenetrateOne(mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, 1, type, param)
  1122. }
  1123. } else {
  1124. setTimeout(() => {
  1125. this.initChartLTip(location)
  1126. })
  1127. }
  1128. },
  1129. initChartLTip (location, mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, typeCTwo, paramCTwo, portType) {
  1130. this.myChartTip1 = echarts.init(document.getElementById("echartSingleTip"));
  1131. let option = {
  1132. grid: {
  1133. top: 40,
  1134. right: 0,
  1135. left: 60,
  1136. bottom: 70,
  1137. },
  1138. tooltip: {
  1139. show: true,
  1140. trigger: "axis",
  1141. axisPointer: {
  1142. // 坐标轴指示器,坐标轴触发有效
  1143. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  1144. },
  1145. textStyle: {
  1146. color: '#FFF', // 文字的颜色
  1147. fontSize: '20', // 文字字体大小
  1148. fontFamily: 'Microsoft YaHei'
  1149. },
  1150. },
  1151. xAxis: {
  1152. data: commonCompany,
  1153. axisTick: {
  1154. show: false,
  1155. },
  1156. // x轴的字体颜色
  1157. axisLabel: {
  1158. rotate: 40,
  1159. textStyle: {
  1160. color: "white",
  1161. fontSize: '20',
  1162. fontFamily: 'Microsoft YaHei'
  1163. },
  1164. },
  1165. //y轴线的颜色以及宽度
  1166. axisLine: {
  1167. show: true,
  1168. lineStyle: {
  1169. color: "#1E5389",
  1170. width: 1,
  1171. type: "solid",
  1172. },
  1173. },
  1174. },
  1175. yAxis: {
  1176. name: '亿',
  1177. nameTextStyle: {//y轴上方单位的颜色
  1178. color: '#fff',
  1179. fontSize: '20',
  1180. fontFamily: 'Microsoft YaHei'
  1181. },
  1182. axisTick: {
  1183. lineStyle: {
  1184. color: "#18416F",
  1185. },
  1186. },
  1187. // y轴的字体颜色
  1188. axisLabel: {
  1189. textStyle: {
  1190. color: "white",
  1191. fontSize: '20'
  1192. },
  1193. },
  1194. splitLine: {
  1195. show: true,
  1196. lineStyle: {
  1197. color: '#68b4dd66',
  1198. type: 'dashed',
  1199. },
  1200. },
  1201. //y轴线的颜色以及宽度
  1202. axisLine: {
  1203. show: true,
  1204. lineStyle: {
  1205. color: "#1E5389",
  1206. width: 1,
  1207. type: "solid",
  1208. },
  1209. },
  1210. },
  1211. series: [
  1212. // {
  1213. // name: "2022年额度",
  1214. // type: "bar",
  1215. // data: [263.23, 402.18, 73.28, 144.80, 25.56, 8.23, 0, 12.97, 8.56, -1.72, 0, 0, 0, 76.90, 5.03, 9.14, 0, 0],
  1216. // showBackground: false,
  1217. // backgroundStyle: {
  1218. // color: "#18416F",
  1219. // },
  1220. // barWidth: "10%",
  1221. // itemStyle: {
  1222. // barBorderRadius: [10, 10, 0, 0],
  1223. // color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  1224. // {
  1225. // offset: 0,
  1226. // color: '#082550',
  1227. // },
  1228. // {
  1229. // offset: 1,
  1230. // color: '#69c0ff',
  1231. // },
  1232. // ]),
  1233. // },
  1234. // },
  1235. {
  1236. name: "总额度",
  1237. type: "bar",
  1238. data: common3,
  1239. showBackground: false,
  1240. backgroundStyle: {
  1241. color: "#18416F",
  1242. },
  1243. barWidth: "30%",
  1244. itemStyle: {
  1245. // barBorderRadius: [10, 10, 0, 0],
  1246. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  1247. {
  1248. offset: 0,
  1249. color: '#082550',
  1250. },
  1251. {
  1252. offset: 1,
  1253. color: '#957DFF',
  1254. },
  1255. ]),
  1256. },
  1257. },
  1258. ],
  1259. legend: {
  1260. // data: ["2022年额度", "2023年额度"],
  1261. data: ["总额度"],
  1262. textStyle: {
  1263. // 图列内容样式
  1264. color: "#fff", // 字体颜色
  1265. fontSize: "20",
  1266. fontFamily: 'Microsoft YaHei'
  1267. },
  1268. right: 'center',
  1269. y: 5,
  1270. // 小图标的宽高
  1271. },
  1272. };
  1273. tools.loopShowTooltip(this.myChartTip1, option, {
  1274. nterval: 2000,
  1275. loopSeries: true,
  1276. })
  1277. let that = this
  1278. that.myChartTip1.on('click', function (param) {
  1279. if (that.versions) {
  1280. if (location == 'right') {
  1281. that.rightPenetrateTwo('', '', that.findCode(param.name))
  1282. } else if (location == 'left') {
  1283. that.leftPenetrateTwo(mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, param.name)
  1284. } else if (location == 'center') {
  1285. that.centerPenetrateTwo(typeCTwo, paramCTwo, that.findCode(param.name), portType)
  1286. }
  1287. } else {
  1288. that.projectListTipShow = true
  1289. }
  1290. })
  1291. that.myChartTip1.setOption(option);
  1292. },
  1293. initChartLTip2 (location, mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo, portType) {
  1294. this.myChartTip2 = echarts.init(document.getElementById("echartSingleTip2"));
  1295. let option = {
  1296. grid: {
  1297. top: 40,
  1298. right: 0,
  1299. left: 60,
  1300. bottom: '15%',
  1301. },
  1302. tooltip: {
  1303. show: true,
  1304. trigger: "axis",
  1305. axisPointer: {
  1306. // 坐标轴指示器,坐标轴触发有效
  1307. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  1308. },
  1309. textStyle: {
  1310. color: '#FFF', // 文字的颜色
  1311. fontSize: '20', // 文字字体大小
  1312. fontFamily: 'Microsoft YaHei'
  1313. },
  1314. },
  1315. xAxis: {
  1316. data: this.changeLine ? commonCompany : this.lineCommonCompany,
  1317. axisTick: {
  1318. show: false,
  1319. },
  1320. // x轴的字体颜色
  1321. axisLabel: {
  1322. rotate: 40,
  1323. textStyle: {
  1324. color: "white",
  1325. fontSize: '20',
  1326. fontFamily: 'Microsoft YaHei'
  1327. },
  1328. },
  1329. //y轴线的颜色以及宽度
  1330. axisLine: {
  1331. show: true,
  1332. lineStyle: {
  1333. color: "#1E5389",
  1334. width: 1,
  1335. type: "solid",
  1336. },
  1337. },
  1338. },
  1339. yAxis: {
  1340. name: '个',
  1341. nameTextStyle: {//y轴上方单位的颜色
  1342. color: '#fff',
  1343. fontSize: '20',
  1344. fontFamily: 'Microsoft YaHei'
  1345. },
  1346. axisTick: {
  1347. lineStyle: {
  1348. color: "#18416F",
  1349. },
  1350. },
  1351. // y轴的字体颜色
  1352. axisLabel: {
  1353. textStyle: {
  1354. color: "#fff",
  1355. fontSize: '20',
  1356. fontFamily: 'Microsoft YaHei'
  1357. },
  1358. },
  1359. splitLine: {
  1360. show: true,
  1361. lineStyle: {
  1362. color: '#68b4dd66',
  1363. type: 'dashed',
  1364. },
  1365. },
  1366. //y轴线的颜色以及宽度
  1367. axisLine: {
  1368. show: true,
  1369. lineStyle: {
  1370. color: "#1E5389",
  1371. width: 1,
  1372. type: "solid",
  1373. },
  1374. },
  1375. },
  1376. series: [
  1377. {
  1378. name: "总数量",
  1379. type: this.changeLine ? "bar" : 'line',
  1380. data: common4,
  1381. showBackground: false,
  1382. backgroundStyle: {
  1383. color: "#18416F",
  1384. },
  1385. barWidth: "30%",
  1386. itemStyle: {
  1387. // barBorderRadius: [10, 10, 0, 0],
  1388. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  1389. {
  1390. offset: 0,
  1391. color: '#082550',
  1392. },
  1393. {
  1394. offset: 1,
  1395. color: '#957DFF',
  1396. },
  1397. ]),
  1398. },
  1399. },
  1400. ],
  1401. legend: {
  1402. // data: ["2022年额度", "2023年额度"],
  1403. data: ["总数量"],
  1404. textStyle: {
  1405. // 图列内容样式
  1406. color: "#fff", // 字体颜色
  1407. fontSize: "20",
  1408. fontFamily: 'Microsoft YaHei'
  1409. },
  1410. right: 'center',
  1411. y: 0,
  1412. // 小图标的宽高
  1413. },
  1414. };
  1415. tools.loopShowTooltip(this.myChartTip2, option, {
  1416. nterval: 2000,
  1417. loopSeries: true,
  1418. })
  1419. let that = this
  1420. that.myChartTip2.on('click', function (param) {
  1421. if (that.versions) {
  1422. if (location == 'right') {
  1423. that.rightPenetrateTwo('', '', that.findCode(param.name))
  1424. } else if (location == 'left') {
  1425. that.leftPenetrateTwo(mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, param.name)
  1426. } else if (location == 'center') {
  1427. that.centerPenetrateTwo(typeCTwo, paramCTwo, that.findCode(param.name), portType)
  1428. }
  1429. } else {
  1430. that.projectListTipShow = true
  1431. }
  1432. })
  1433. that.myChartTip2.setOption(option);
  1434. },
  1435. initChartLTip3 (location, mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, type, param, typeCTwo, paramCTwo, portType) {
  1436. this.myChartTip3 = echarts.init(document.getElementById("echartSingleTip3"));
  1437. let option = {
  1438. grid: {
  1439. top: 40,
  1440. right: 0,
  1441. left: 60,
  1442. bottom: '15%',
  1443. },
  1444. tooltip: {
  1445. show: true,
  1446. trigger: "axis",
  1447. axisPointer: {
  1448. // 坐标轴指示器,坐标轴触发有效
  1449. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  1450. },
  1451. textStyle: {
  1452. color: '#FFF', // 文字的颜色
  1453. fontSize: '20', // 文字字体大小
  1454. fontFamily: 'Microsoft YaHei'
  1455. },
  1456. },
  1457. xAxis: {
  1458. data: commonCompany,
  1459. axisTick: {
  1460. show: false,
  1461. },
  1462. // x轴的字体颜色
  1463. axisLabel: {
  1464. rotate: 40,
  1465. textStyle: {
  1466. color: "#fff",
  1467. fontSize: '20',
  1468. fontFamily: 'Microsoft YaHei'
  1469. },
  1470. },
  1471. //y轴线的颜色以及宽度
  1472. axisLine: {
  1473. show: true,
  1474. lineStyle: {
  1475. color: "#1E5389",
  1476. width: 1,
  1477. type: "solid",
  1478. },
  1479. },
  1480. },
  1481. yAxis: {
  1482. name: '亿',
  1483. nameTextStyle: {//y轴上方单位的颜色
  1484. color: '#fff',
  1485. fontSize: '20',
  1486. fontFamily: 'Microsoft YaHei'
  1487. },
  1488. axisTick: {
  1489. lineStyle: {
  1490. color: "#18416F",
  1491. },
  1492. },
  1493. // y轴的字体颜色
  1494. axisLabel: {
  1495. textStyle: {
  1496. color: "#fff",
  1497. fontSize: '20',
  1498. fontFamily: 'Microsoft YaHei'
  1499. },
  1500. },
  1501. splitLine: {
  1502. show: true,
  1503. lineStyle: {
  1504. color: '#68b4dd66',
  1505. type: 'dashed',
  1506. },
  1507. },
  1508. //y轴线的颜色以及宽度
  1509. axisLine: {
  1510. show: true,
  1511. lineStyle: {
  1512. color: "#1E5389",
  1513. width: 1,
  1514. type: "solid",
  1515. },
  1516. },
  1517. },
  1518. series: [,
  1519. {
  1520. name: "总额度",
  1521. type: "bar",
  1522. data: common5,
  1523. showBackground: false,
  1524. backgroundStyle: {
  1525. color: "#18416F",
  1526. },
  1527. barWidth: "30%",
  1528. itemStyle: {
  1529. // barBorderRadius: [10, 10, 0, 0],
  1530. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  1531. {
  1532. offset: 0,
  1533. color: '#082550',
  1534. },
  1535. {
  1536. offset: 1,
  1537. color: '#69c0ff',
  1538. },
  1539. ]),
  1540. },
  1541. },
  1542. ],
  1543. legend: {
  1544. data: ["总额度"],
  1545. textStyle: {
  1546. // 图列内容样式
  1547. color: "#fff", // 字体颜色
  1548. fontSize: "20",
  1549. fontFamily: 'Microsoft YaHei'
  1550. },
  1551. right: 'center',
  1552. y: 5,
  1553. },
  1554. };
  1555. tools.loopShowTooltip(this.myChartTip3, option, {
  1556. nterval: 2000,
  1557. loopSeries: true,
  1558. })
  1559. let that = this
  1560. that.myChartTip3.on('click', function (param) {
  1561. if (that.versions) {
  1562. if (location == 'right') {
  1563. that.rightPenetrateTwo('', '', that.findCode(param.name))
  1564. } else if (location == 'left') {
  1565. that.leftPenetrateTwo(mdnb_textfield11, mdnb_textfield13, mdnb_textfield16, mdnb_textfield23, param.name)
  1566. } else if (location == 'center') {
  1567. that.centerPenetrateTwo(typeCTwo, paramCTwo, that.findCode(param.name), portType)
  1568. }
  1569. } else {
  1570. that.projectListTipShow = true
  1571. }
  1572. })
  1573. that.myChartTip3.setOption(option);
  1574. },
  1575. closeTap () {
  1576. this.changeLine = true
  1577. this.echartEnterpriseShow = false
  1578. this.mapTipShow = false
  1579. this.echartSingleTipShow = false
  1580. this.echartDoubleTipShow = false
  1581. this.projectListTipShow = false
  1582. this.myChartTip1 ? this.myChartTip1.dispose() : ''
  1583. this.myChartTip2 ? this.myChartTip2.dispose() : ''
  1584. this.myChartTip3 ? this.myChartTip3.dispose() : ''
  1585. },
  1586. //点击弹窗左半部分
  1587. popLeftClick () {
  1588. if (this.titleUrl == '2.png') {
  1589. this.titleUrl = '3.png'
  1590. } else if (this.titleUrl == '7.png') {
  1591. this.titleUrl = '8.png'
  1592. } else if (this.titleUrl == '3.png') {
  1593. this.titleUrl = '2.png'
  1594. } else if (this.titleUrl == '8.png') {
  1595. this.titleUrl = '7.png'
  1596. } else if (this.titleUrl == '5.png') {
  1597. this.titleUrl = '2.png'
  1598. } else if (this.titleUrl == '10.png') {
  1599. this.titleUrl = '7.png'
  1600. }
  1601. },
  1602. //点击弹窗右半部分
  1603. poprightClick () {
  1604. if (this.titleUrl == '2.png') {
  1605. this.titleUrl = '5.png'
  1606. } else if (this.titleUrl == '7.png') {
  1607. this.titleUrl = '10.png'
  1608. } else if (this.titleUrl == '5.png') {
  1609. this.titleUrl = '2.png'
  1610. } else if (this.titleUrl == '10.png') {
  1611. this.titleUrl = '7.png'
  1612. } else if (this.titleUrl == '3.png') {
  1613. this.titleUrl = '2.png'
  1614. } else if (this.titleUrl == '8.png') {
  1615. this.titleUrl = '7.png'
  1616. }
  1617. },
  1618. // 标题弹窗
  1619. showTitlePop (e, name) {
  1620. this.closeTap()
  1621. this.titleUrl = e
  1622. this.titleName = name
  1623. this.$nextTick(() => {
  1624. this.mapTipShow = true
  1625. })
  1626. },
  1627. changeYellow () {
  1628. this.titleList.forEach((item, index) => {
  1629. this.$set(this.titleList[index], 'type', 1)
  1630. })
  1631. this.$set(this.titleList[this.yellowCount], 'type', 2)
  1632. if (this.yellowCount == 14) {
  1633. this.yellowCount = 0
  1634. this.yellowPosition += 315
  1635. } else {
  1636. if (this.yellowCount != 0) {
  1637. this.yellowPosition += 315
  1638. } else {
  1639. this.yellowPosition = 40
  1640. }
  1641. this.yellowCount += 2
  1642. }
  1643. },
  1644. numFormat (value) {
  1645. if (!value) return '0'
  1646. // var intPart = Number(value).toFixed(0) // 获取整数部分
  1647. var intPart = parseInt(value)// 获取整数部分
  1648. var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
  1649. var floatPart = '.00' // 预定义小数部分
  1650. var value2Array = value.toString().split('.')
  1651. // =2表示数据有小数位
  1652. if (value2Array.length === 2) {
  1653. floatPart = value2Array[1].toString() // 拿到小数部分
  1654. if (floatPart.length === 1) {
  1655. // 补0
  1656. return intPartFormat + '.' + floatPart + '0'
  1657. } else {
  1658. return intPartFormat + '.' + floatPart
  1659. }
  1660. } else {
  1661. return intPartFormat
  1662. }
  1663. },
  1664. changeTopColor () {
  1665. this.list = document.getElementsByClassName('row-item')
  1666. for (var i = 0; i < this.list.length; i++) {
  1667. if (i == 1) {
  1668. this.list[i].classList.add('light')
  1669. } else {
  1670. this.list[i].classList.remove('light')
  1671. }
  1672. }
  1673. this.initChartL9()
  1674. },
  1675. scrollChange (index) {
  1676. if (index == 18) {
  1677. this.count = -1
  1678. } else {
  1679. this.count = index
  1680. }
  1681. if (this.count > 12 && this.count != 18) {
  1682. this.countType = 1
  1683. } else {
  1684. this.countType = 0
  1685. }
  1686. for (var i = 0; i < this.list.length; i++) {
  1687. if (i == 2) {
  1688. this.list[i].classList.add('light')
  1689. } else {
  1690. this.list[i].classList.remove('light')
  1691. }
  1692. }
  1693. this.chartCarousel.dispose()
  1694. this.initChartL9()
  1695. },
  1696. initChartBall () {
  1697. this.left11Chart = echarts.init(this.$refs['echartBall'])
  1698. option = {
  1699. series: [
  1700. {
  1701. type: "liquidFill",
  1702. radius: "80%",
  1703. data: [left2[0], left2[0] + 0.02, left2[0] - 0.02],
  1704. amplitude: '4%',
  1705. waveLength: '20%', //波浪长度
  1706. // data: [
  1707. // {}
  1708. // ],
  1709. backgroundStyle: {
  1710. color: {
  1711. type: "radial",
  1712. x: 0.5,
  1713. y: 0.5,
  1714. r: 0.5,
  1715. // 水球体颜色
  1716. colorStops: [
  1717. {
  1718. offset: 0,
  1719. color: "#010a11",
  1720. },
  1721. {
  1722. offset: 0.9,
  1723. color: "#1a2f45",
  1724. },
  1725. {
  1726. offset: 1,
  1727. color: "#2b405a",
  1728. },
  1729. ],
  1730. globalCoord: false,
  1731. },
  1732. },
  1733. outline: {
  1734. borderDistance: 0,
  1735. itemStyle: {
  1736. borderWidth: 0,
  1737. borderColor: {
  1738. type: "linear",
  1739. x: 0,
  1740. y: 0,
  1741. x2: 0,
  1742. y2: 1,
  1743. colorStops: [
  1744. ],
  1745. globalCoord: false,
  1746. },
  1747. },
  1748. },
  1749. color: [
  1750. {
  1751. x: 0,
  1752. y: 0,
  1753. x2: 0,
  1754. y2: 1,
  1755. colorStops: [{
  1756. offset: 0,
  1757. color: '#237386',
  1758. },
  1759. {
  1760. offset: 1,
  1761. color: '#0078C8',
  1762. },],
  1763. },
  1764. {
  1765. x: 0,
  1766. y: 0,
  1767. x2: 0,
  1768. y2: 1,
  1769. colorStops: [{
  1770. offset: 0,
  1771. color: '#2F97A9',
  1772. },
  1773. {
  1774. offset: 1,
  1775. color: '#0078C8',
  1776. },],
  1777. },
  1778. {
  1779. x: 0,
  1780. y: 0,
  1781. x2: 0,
  1782. y2: 1,
  1783. colorStops: [{
  1784. offset: 0,
  1785. color: '#48E0ED',
  1786. },
  1787. {
  1788. offset: 1,
  1789. color: '#0078C8',
  1790. },],
  1791. }
  1792. ],
  1793. label: {
  1794. normal: {
  1795. textStyle: {
  1796. color: "#fff", // x轴文字颜色
  1797. fontSize: '70'
  1798. },
  1799. },
  1800. },
  1801. },
  1802. ],
  1803. };
  1804. this.left11Chart.setOption(option)
  1805. },
  1806. initChartL1 () {
  1807. this.left9Chart = echarts.init(this.$refs['echartL1'])
  1808. option = {
  1809. series: [
  1810. {
  1811. type: "liquidFill",
  1812. radius: "80%",
  1813. data: [left2[0], left2[0] + 0.02, left2[0] - 0.02],
  1814. amplitude: '4%',
  1815. // period:'1500',
  1816. waveLength: '20%', //波浪长度
  1817. // data: [
  1818. // {}
  1819. // ],
  1820. backgroundStyle: {
  1821. color: {
  1822. type: "radial",
  1823. x: 0.5,
  1824. y: 0.5,
  1825. r: 0.5,
  1826. // 水球体颜色
  1827. colorStops: [
  1828. {
  1829. offset: 0,
  1830. color: "#010a11",
  1831. },
  1832. {
  1833. offset: 0.9,
  1834. // color: "#203852",
  1835. color: "#1a2f45",
  1836. },
  1837. {
  1838. offset: 1,
  1839. // color: "#354e6d",
  1840. color: "#2b405a",
  1841. // color: "#314967",
  1842. },
  1843. ],
  1844. globalCoord: false,
  1845. },
  1846. },
  1847. outline: {
  1848. borderDistance: 0,
  1849. itemStyle: {
  1850. borderWidth: 0,
  1851. borderColor: {
  1852. type: "linear",
  1853. x: 0,
  1854. y: 0,
  1855. x2: 0,
  1856. y2: 1,
  1857. colorStops: [
  1858. ],
  1859. globalCoord: false,
  1860. },
  1861. },
  1862. },
  1863. color: [
  1864. {
  1865. x: 0,
  1866. y: 0,
  1867. x2: 0,
  1868. y2: 1,
  1869. colorStops: [{
  1870. offset: 0,
  1871. color: '#237386',
  1872. },
  1873. {
  1874. offset: 1,
  1875. color: '#0078C8',
  1876. },],
  1877. },
  1878. {
  1879. x: 0,
  1880. y: 0,
  1881. x2: 0,
  1882. y2: 1,
  1883. colorStops: [{
  1884. offset: 0,
  1885. color: '#2F97A9',
  1886. },
  1887. {
  1888. offset: 1,
  1889. color: '#0078C8',
  1890. },],
  1891. },
  1892. {
  1893. x: 0,
  1894. y: 0,
  1895. x2: 0,
  1896. y2: 1,
  1897. colorStops: [{
  1898. offset: 0,
  1899. color: '#48E0ED',
  1900. },
  1901. {
  1902. offset: 1,
  1903. color: '#0078C8',
  1904. },],
  1905. }
  1906. ],
  1907. label: {
  1908. normal: {
  1909. textStyle: {
  1910. color: "#fff", // x轴文字颜色
  1911. },
  1912. },
  1913. },
  1914. },
  1915. ],
  1916. };
  1917. this.left9Chart.setOption(option)
  1918. },
  1919. initChartL2 () {
  1920. var chartData = left5
  1921. var timer = null;
  1922. var i = 0;
  1923. let that = this
  1924. var option = {
  1925. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  1926. chart: {
  1927. type: 'pie',
  1928. backgroundColor: 'rgba(0,0,0,0)',
  1929. options3d: {
  1930. enabled: true,
  1931. alpha: 45,
  1932. //beta: 0
  1933. },
  1934. events: {
  1935. // load,图表加载完成时触发
  1936. load: function () {
  1937. var chart = this;
  1938. var points = chart.series[0].points;
  1939. var len = points.length;
  1940. timer && clearInterval(timer);
  1941. timer = setInterval(function () {
  1942. autoTooltip(points[i]);
  1943. chartData.forEach((item, index) => {
  1944. item.sliced = false
  1945. item.selected = false
  1946. if (index == i) {
  1947. // item.sliced = true
  1948. // item.selected = true
  1949. }
  1950. })
  1951. that.left1Chart.update({
  1952. series: [{
  1953. type: 'pie',
  1954. name: '占比',
  1955. point: {
  1956. events: {
  1957. click: function (e) {
  1958. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  1959. }
  1960. }
  1961. },
  1962. data: chartData
  1963. }]
  1964. })
  1965. i++;
  1966. if (i === len) {
  1967. i = 0;
  1968. chartData.forEach((item, index) => {
  1969. // item.sliced = false
  1970. // item.selected = false
  1971. })
  1972. that.left1Chart.update({
  1973. series: [{
  1974. type: 'pie',
  1975. name: '占比',
  1976. point: {
  1977. events: {
  1978. click: function (e) {
  1979. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  1980. }
  1981. }
  1982. },
  1983. data: chartData
  1984. }]
  1985. })
  1986. }
  1987. }, 2000);
  1988. },
  1989. legendItemClick: function (event) {
  1990. return true;
  1991. }
  1992. }
  1993. },
  1994. credits: {
  1995. enabled: false //去掉hightchats水印
  1996. },
  1997. legend: {
  1998. // labelFormatter: function() {
  1999. // return 123;
  2000. // },
  2001. align: 'right',//横向位置
  2002. verticalAlign: 'middle', // 纵向位置
  2003. layout: "vertical",//横排还是竖排
  2004. x: -110,
  2005. y: 90,
  2006. symbolWidth: 50,
  2007. itemStyle: {
  2008. fontSize: '20px',
  2009. color: '#fff',
  2010. x: 20,
  2011. fontWeight: 0,
  2012. fontFamily: 'Microsoft YaHei'
  2013. },
  2014. },
  2015. title: {
  2016. text: '主辅业计划占比',
  2017. style: {
  2018. color: '#fff',
  2019. fontSize: 24,
  2020. fontFamily: 'Microsoft YaHei',
  2021. },
  2022. align: 'center',
  2023. verticalAlign: "bottom",
  2024. x: -120
  2025. },
  2026. tooltip: {
  2027. crosshairs: false,
  2028. backgroundColor: 'rgba(0,0,0,0.5)',
  2029. // positioner: function(e){
  2030. // console.log(e, this)
  2031. // },
  2032. // useHTML: false, //开启html模式
  2033. style: {
  2034. color: '#fff',
  2035. fontSize: '20',
  2036. fontWeight: 0,
  2037. fontFamily: 'Microsoft YaHei'
  2038. },
  2039. formatter: function (e) {
  2040. let num = chartData[this.colorIndex].num
  2041. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  2042. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  2043. },
  2044. //pointFormat:
  2045. },
  2046. plotOptions: {
  2047. pie: {
  2048. allowPointSelect: true,
  2049. showInLegend: true, // 图例
  2050. cursor: 'pointer',
  2051. size: 220,
  2052. innerSize: 150, //环形图中间空白,0为饼图
  2053. depth: 25, //立体高度
  2054. slicedOffset: 21, //动画距离
  2055. dataLabels: {
  2056. enabled: false, // 是否展示指示线
  2057. format: '{point.name}: {point.percentage}'
  2058. }
  2059. },
  2060. },
  2061. series: [{
  2062. type: 'pie',
  2063. name: '占比',
  2064. center: ['50%', '50%'],
  2065. point: {
  2066. events: {
  2067. click: function (e) { //点击事件
  2068. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2069. },
  2070. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  2071. chartData.forEach((item, index) => {
  2072. // item.sliced = false
  2073. // item.selected = false
  2074. })
  2075. // chartData[e.target.index].sliced = true
  2076. // chartData[e.target.index].selected = true
  2077. that.left1Chart.update({
  2078. series: [{
  2079. type: 'pie',
  2080. name: '占比',
  2081. point: {
  2082. events: {
  2083. click: function (e) {
  2084. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2085. }
  2086. }
  2087. },
  2088. data: chartData
  2089. }]
  2090. })
  2091. timer && clearInterval(timer);
  2092. },
  2093. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  2094. var points = that.left1Chart.series[0].points;
  2095. var len = points.length;
  2096. timer && clearInterval(timer);
  2097. timer = setInterval(function () {
  2098. autoTooltip(points[i]);
  2099. chartData.forEach((item, index) => {
  2100. // item.sliced = false
  2101. // item.selected = false
  2102. if (index == i) {
  2103. // item.sliced = true
  2104. // item.selected = true
  2105. }
  2106. })
  2107. that.left1Chart.update({
  2108. series: [{
  2109. type: 'pie',
  2110. name: '占比',
  2111. point: {
  2112. events: {
  2113. click: function (e) {
  2114. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2115. }
  2116. }
  2117. },
  2118. data: chartData
  2119. }]
  2120. })
  2121. i++;
  2122. if (i === len) {
  2123. i = 0;
  2124. chartData.forEach((item, index) => {
  2125. item.sliced = false
  2126. item.selected = false
  2127. })
  2128. that.left1Chart.update({
  2129. series: [{
  2130. type: 'pie',
  2131. name: '占比',
  2132. point: {
  2133. events: {
  2134. click: function (e) {
  2135. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2136. }
  2137. }
  2138. },
  2139. data: chartData
  2140. }]
  2141. })
  2142. }
  2143. }, 2000);
  2144. }
  2145. }
  2146. },
  2147. data: chartData
  2148. }]
  2149. }
  2150. that.left1Chart = Highcharts.chart('echartL2', option);
  2151. function autoTooltip (point) {
  2152. that.left1Chart.tooltip.refresh(point);
  2153. }
  2154. },
  2155. initChartL3 () {
  2156. var chartData = left6
  2157. var timer = null;
  2158. var i = 0;
  2159. let that = this
  2160. that.left2Chart = Highcharts.chart('echartL3', {
  2161. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  2162. chart: {
  2163. type: 'pie',
  2164. backgroundColor: 'rgba(0,0,0,0)',
  2165. options3d: {
  2166. enabled: true,
  2167. alpha: 45,
  2168. //beta: 0
  2169. },
  2170. events: {
  2171. // load,图表加载完成时触发
  2172. load: function () {
  2173. var chart = this;
  2174. var points = chart.series[0].points;
  2175. var len = points.length;
  2176. timer && clearInterval(timer);
  2177. timer = setInterval(function () {
  2178. autoTooltip(points[i]);
  2179. chartData.forEach((item, index) => {
  2180. item.sliced = false
  2181. item.selected = false
  2182. if (index == i) {
  2183. // item.sliced = true
  2184. // item.selected = true
  2185. }
  2186. })
  2187. that.left2Chart.update({
  2188. series: [{
  2189. type: 'pie',
  2190. name: '占比',
  2191. point: {
  2192. events: {
  2193. click: function (e) {
  2194. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2195. }
  2196. }
  2197. },
  2198. data: chartData
  2199. }]
  2200. })
  2201. i++;
  2202. if (i === len) {
  2203. i = 0;
  2204. chartData.forEach((item, index) => {
  2205. // item.sliced = false
  2206. // item.selected = false
  2207. })
  2208. that.left2Chart.update({
  2209. series: [{
  2210. type: 'pie',
  2211. name: '占比',
  2212. point: {
  2213. events: {
  2214. click: function (e) {
  2215. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2216. }
  2217. }
  2218. },
  2219. data: chartData
  2220. }]
  2221. })
  2222. }
  2223. }, 2000);
  2224. },
  2225. legendItemClick: function (event) {
  2226. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2227. return true;
  2228. }
  2229. }
  2230. },
  2231. credits: {
  2232. enabled: false //去掉hightchats水印
  2233. },
  2234. legend: {
  2235. // labelFormatter: function() {
  2236. // return 123;
  2237. // },
  2238. align: 'right',//横向位置
  2239. verticalAlign: 'middle', // 纵向位置
  2240. layout: "vertical",//横排还是竖排
  2241. x: -70,
  2242. y: 90,
  2243. symbolWidth: 50,
  2244. itemStyle: {
  2245. fontSize: '20px',
  2246. color: '#fff',
  2247. x: 20,
  2248. fontWeight: 0,
  2249. fontFamily: 'Microsoft YaHei'
  2250. },
  2251. },
  2252. title: {
  2253. text: '项目管理类型',
  2254. style: {
  2255. color: '#fff',
  2256. fontSize: 24,
  2257. fontFamily: 'Microsoft YaHei'
  2258. },
  2259. align: 'center',
  2260. verticalAlign: "bottom",
  2261. x: -120
  2262. },
  2263. tooltip: {
  2264. crosshairs: true,
  2265. backgroundColor: 'rgba(0,0,0,0.5)',
  2266. // positioner: function(e){
  2267. // console.log(e, this)
  2268. // },
  2269. useHTML: false, //开启html模式
  2270. style: {
  2271. color: '#fff',
  2272. fontSize: '20',
  2273. fontFamily: 'Microsoft YaHei'
  2274. },
  2275. formatter: function (e) {
  2276. //console.log(this)
  2277. let num = chartData[this.colorIndex].num
  2278. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  2279. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  2280. },
  2281. //pointFormat:
  2282. },
  2283. plotOptions: {
  2284. pie: {
  2285. allowPointSelect: true,
  2286. showInLegend: true, // 图例
  2287. cursor: 'pointer',
  2288. size: 220,
  2289. innerSize: 150, //环形图中间空白,0为饼图
  2290. depth: 25, //立体高度
  2291. slicedOffset: 21, //动画距离
  2292. dataLabels: {
  2293. enabled: false, // 是否展示指示线
  2294. format: '{point.name}: {point.percentage}'
  2295. }
  2296. },
  2297. },
  2298. series: [{
  2299. type: 'pie',
  2300. name: '占比',
  2301. // center: ['70%', '50%'],
  2302. point: {
  2303. events: {
  2304. click: function (e) { //点击事件
  2305. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2306. },
  2307. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  2308. //console.log(e)
  2309. chartData.forEach((item, index) => {
  2310. item.sliced = false
  2311. item.selected = false
  2312. })
  2313. // chartData[e.target.index].sliced = true
  2314. // chartData[e.target.index].selected = true
  2315. that.left2Chart.update({
  2316. series: [{
  2317. type: 'pie',
  2318. name: '占比',
  2319. point: {
  2320. events: {
  2321. click: function (e) {
  2322. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2323. }
  2324. }
  2325. },
  2326. data: chartData
  2327. }]
  2328. })
  2329. timer && clearInterval(timer);
  2330. },
  2331. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  2332. var points = that.left2Chart.series[0].points;
  2333. var len = points.length;
  2334. timer && clearInterval(timer);
  2335. timer = setInterval(function () {
  2336. autoTooltip(points[i]);
  2337. chartData.forEach((item, index) => {
  2338. item.sliced = false
  2339. item.selected = false
  2340. if (index == i) {
  2341. // item.sliced = true
  2342. // item.selected = true
  2343. }
  2344. })
  2345. that.left2Chart.update({
  2346. series: [{
  2347. type: 'pie',
  2348. name: '占比',
  2349. point: {
  2350. events: {
  2351. click: function (e) {
  2352. that.showChartLTipDouble(e.point.name, 'left', '投资计划分析', e.point.name, '', '')
  2353. }
  2354. }
  2355. },
  2356. data: chartData
  2357. }]
  2358. })
  2359. i++;
  2360. if (i === len) {
  2361. i = 0;
  2362. chartData.forEach((item, index) => {
  2363. item.sliced = false
  2364. item.selected = false
  2365. })
  2366. that.left2Chart.update({
  2367. series: [{
  2368. type: 'pie',
  2369. name: '占比',
  2370. point: {
  2371. events: {
  2372. click: function (e) {
  2373. console.log(e)
  2374. }
  2375. }
  2376. },
  2377. data: chartData
  2378. }]
  2379. })
  2380. }
  2381. }, 2000);
  2382. }
  2383. }
  2384. },
  2385. data: chartData
  2386. }]
  2387. });
  2388. function autoTooltip (point) {
  2389. that.left2Chart.tooltip.refresh(point);
  2390. }
  2391. },
  2392. initChartL4 (dataList) {
  2393. this.left10Chart = echarts.init(document.getElementById("echartL4"));
  2394. let option = {
  2395. grid: {
  2396. top: 45,
  2397. right: 0,
  2398. left: 60,
  2399. bottom: 80,
  2400. },
  2401. tooltip: {
  2402. show: true,
  2403. trigger: "axis",
  2404. formatter: data => {
  2405. return `${data[0].name}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color.colorStops[0].color}"></span> ${data[0].seriesName}:${data[0].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color.colorStops[0].color}"></span> ${data[1].seriesName}:${data[1].value + data[0].value}亿`
  2406. },
  2407. axisPointer: {
  2408. // 坐标轴指示器,坐标轴触发有效
  2409. type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
  2410. },
  2411. textStyle: {
  2412. color: '#FFF', // 文字的颜色
  2413. fontSize: '20', // 文字字体大小
  2414. fontFamily: 'Microsoft YaHei'
  2415. },
  2416. },
  2417. xAxis: {
  2418. data: commonCompany,
  2419. axisTick: {
  2420. show: false,
  2421. },
  2422. // x轴的字体颜色
  2423. axisLabel: {
  2424. rotate: 40,
  2425. textStyle: {
  2426. color: "white",
  2427. fontSize: '20',
  2428. fontFamily: 'Microsoft YaHei'
  2429. },
  2430. },
  2431. //y轴线的颜色以及宽度
  2432. axisLine: {
  2433. show: true,
  2434. lineStyle: {
  2435. color: "#1E5389",
  2436. width: 1,
  2437. type: "solid",
  2438. },
  2439. },
  2440. },
  2441. yAxis: {
  2442. name: '亿',
  2443. axisTick: {
  2444. lineStyle: {
  2445. color: "#18416F",
  2446. },
  2447. },
  2448. // y轴的字体颜色
  2449. axisLabel: {
  2450. textStyle: {
  2451. color: "white",
  2452. fontSize: '20',
  2453. fontFamily: 'Microsoft YaHei'
  2454. },
  2455. },
  2456. splitLine: {
  2457. show: true,
  2458. lineStyle: {
  2459. color: "#68b4dd66",
  2460. width: 1,
  2461. type: "dashed",
  2462. },
  2463. },
  2464. //y轴线的颜色以及宽度
  2465. axisLine: {
  2466. show: true,
  2467. lineStyle: {
  2468. color: "#1E5389",
  2469. width: 1,
  2470. type: "solid",
  2471. },
  2472. },
  2473. nameTextStyle: {
  2474. color: '#fff',
  2475. fontSize: 20,
  2476. fontFamily: 'Microsoft YaHei'
  2477. },
  2478. },
  2479. series: [
  2480. {
  2481. name: "已用额度",
  2482. type: "bar",
  2483. data: left3[0],
  2484. stack: 'Ad',
  2485. showBackground: false,
  2486. backgroundStyle: {
  2487. color: "#18416F",
  2488. },
  2489. barWidth: "20",
  2490. itemStyle: {
  2491. // barBorderRadius: [10, 10, 0, 0],
  2492. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  2493. {
  2494. offset: 0,
  2495. color: '#082550',
  2496. },
  2497. {
  2498. offset: 1,
  2499. color: '#3986F8',
  2500. },
  2501. ]),
  2502. },
  2503. },
  2504. {
  2505. name: "总额度",
  2506. type: "bar",
  2507. data: left3[1],
  2508. stack: 'Ad',
  2509. showBackground: false,
  2510. backgroundStyle: {
  2511. color: "#18416F",
  2512. },
  2513. barWidth: "20",
  2514. itemStyle: {
  2515. // barBorderRadius: [10, 10, 0, 0],
  2516. color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  2517. {
  2518. offset: 0,
  2519. color: '#b9b7c060',
  2520. },
  2521. {
  2522. offset: 1,
  2523. color: '#b9b7c060',
  2524. },
  2525. ]),
  2526. },
  2527. },
  2528. ],
  2529. legend: {
  2530. // data: ["2022年额度", "2023年额度"],
  2531. data: ["2023年额度"],
  2532. textStyle: {
  2533. // 图列内容样式
  2534. color: "#fff", // 字体颜色
  2535. fontSize: "20",
  2536. fontFamily: 'Microsoft YaHei'
  2537. },
  2538. right: 'center',
  2539. y: 5,
  2540. // icon: "roundRect",
  2541. // 小图标的宽高
  2542. },
  2543. };
  2544. let that = this
  2545. tools.loopShowTooltip(that.left10Chart, option, {
  2546. nterval: 2000,
  2547. loopSeries: true,
  2548. })
  2549. that.left10Chart.on('click', function (param) {
  2550. that.titleName = param.name
  2551. that.echartEnterpriseShow = true
  2552. // 如果是接口版数据版
  2553. if (that.versions) {
  2554. let findData = dataList.find(item => {
  2555. return item.mdnb_textfield == param.name
  2556. })
  2557. common1[0] = findData.mdnb_amountfield18
  2558. common1[1] = findData.mdnb_amountfield20
  2559. common1[2] = findData.mdnb_amountfield19
  2560. common1[3] = findData.mdnb_amountfield26
  2561. common1[4] = findData.mdnb_amountfield27
  2562. common1[5] = findData.mdnb_amountfield25
  2563. common2[0] = findData.mdnb_decimalfield6
  2564. }
  2565. setTimeout(() => {
  2566. that.initChartBall()
  2567. });
  2568. })
  2569. that.left10Chart.setOption(option);
  2570. },
  2571. initChartL5 () {
  2572. var chartData = left7
  2573. var timer = null;
  2574. var i = 0;
  2575. let that = this
  2576. var option = {
  2577. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  2578. chart: {
  2579. type: 'pie',
  2580. backgroundColor: 'rgba(0,0,0,0)',
  2581. options3d: {
  2582. enabled: true,
  2583. alpha: 45,
  2584. //beta: 0
  2585. },
  2586. events: {
  2587. // load,图表加载完成时触发
  2588. load: function () {
  2589. var chart = this;
  2590. var points = chart.series[0].points;
  2591. var len = points.length;
  2592. timer && clearInterval(timer);
  2593. timer = setInterval(function () {
  2594. autoTooltip(points[i]);
  2595. chartData.forEach((item, index) => {
  2596. item.sliced = false
  2597. item.selected = false
  2598. if (index == i) {
  2599. item.sliced = true
  2600. item.selected = true
  2601. }
  2602. })
  2603. that.left3Chart.update({
  2604. series: [{
  2605. type: 'pie',
  2606. name: '占比',
  2607. point: {
  2608. events: {
  2609. click: function (e) {
  2610. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '传统产业分析', e.point.name, '')
  2611. // that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '优势特色产业', '体育产业', '')
  2612. }
  2613. }
  2614. },
  2615. data: chartData
  2616. }]
  2617. })
  2618. i++;
  2619. if (i === len) {
  2620. i = 0;
  2621. }
  2622. }, 2000);
  2623. },
  2624. legendItemClick: function (event) {
  2625. console.log(event);
  2626. return true;
  2627. }
  2628. }
  2629. },
  2630. credits: {
  2631. enabled: false //去掉hightchats水印
  2632. },
  2633. legend: {
  2634. // labelFormatter: function() {
  2635. // return 123;
  2636. // },
  2637. align: 'right',//横向位置
  2638. verticalAlign: 'middle', // 纵向位置
  2639. layout: "vertical",//横排还是竖排
  2640. x: -110,
  2641. y: 50,
  2642. symbolWidth: 50,
  2643. itemDistance: 50,
  2644. itemStyle: {
  2645. fontSize: '20px',
  2646. color: '#fff',
  2647. x: 20,
  2648. fontWeight: 0,
  2649. fontFamily: 'Microsoft YaHei'
  2650. },
  2651. },
  2652. title: {
  2653. text: '传统产业分析',
  2654. style: {
  2655. color: '#fff',
  2656. fontSize: 24,
  2657. fontFamily: 'Microsoft YaHei'
  2658. },
  2659. align: 'center',
  2660. verticalAlign: "bottom",
  2661. x: -120
  2662. },
  2663. tooltip: {
  2664. crosshairs: true,
  2665. backgroundColor: 'rgba(0,0,0,0.5)',
  2666. // positioner: function(e){
  2667. // console.log(e, this)
  2668. // },
  2669. useHTML: false, //开启html模式
  2670. style: {
  2671. color: '#fff',
  2672. fontSize: '20',
  2673. fontFamily: 'Microsoft YaHei'
  2674. },
  2675. formatter: function (e) {
  2676. //console.log(this)
  2677. let num = chartData[this.colorIndex].num
  2678. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  2679. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  2680. },
  2681. //pointFormat:
  2682. },
  2683. plotOptions: {
  2684. pie: {
  2685. allowPointSelect: true,
  2686. showInLegend: true, // 图例
  2687. cursor: 'pointer',
  2688. size: 220,
  2689. innerSize: 150, //环形图中间空白,0为饼图
  2690. depth: 25, //立体高度
  2691. slicedOffset: 21, //动画距离
  2692. dataLabels: {
  2693. enabled: false, // 是否展示指示线
  2694. format: '{point.name}: {point.percentage}'
  2695. }
  2696. },
  2697. },
  2698. series: [{
  2699. type: 'pie',
  2700. name: '占比',
  2701. //center: ['35%','50%'],
  2702. point: {
  2703. events: {
  2704. click: function (e) { //点击事件
  2705. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '传统产业分析', e.point.name, '')
  2706. // that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '优势特色产业', '体育产业', '')
  2707. },
  2708. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  2709. //console.log(e)
  2710. chartData.forEach((item, index) => {
  2711. item.sliced = false
  2712. item.selected = false
  2713. })
  2714. chartData[e.target.index].sliced = true
  2715. chartData[e.target.index].selected = true
  2716. that.left3Chart.update({
  2717. series: [{
  2718. type: 'pie',
  2719. name: '占比',
  2720. point: {
  2721. events: {
  2722. click: function (e) {
  2723. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '传统产业分析', e.point.name, '')
  2724. // that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '优势特色产业', '体育产业', '')
  2725. }
  2726. }
  2727. },
  2728. data: chartData
  2729. }]
  2730. })
  2731. timer && clearInterval(timer);
  2732. },
  2733. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  2734. var points = that.left3Chart.series[0].points;
  2735. var len = points.length;
  2736. timer && clearInterval(timer);
  2737. timer = setInterval(function () {
  2738. autoTooltip(points[i]);
  2739. chartData.forEach((item, index) => {
  2740. item.sliced = false
  2741. item.selected = false
  2742. if (index == i) {
  2743. item.sliced = true
  2744. item.selected = true
  2745. }
  2746. })
  2747. that.left3Chart.update({
  2748. series: [{
  2749. type: 'pie',
  2750. name: '占比',
  2751. point: {
  2752. events: {
  2753. click: function (e) {
  2754. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '传统产业分析', e.point.name, '')
  2755. // that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '优势特色产业', '体育产业', '')
  2756. }
  2757. }
  2758. },
  2759. data: chartData
  2760. }]
  2761. })
  2762. i++;
  2763. if (i === len) {
  2764. i = 0;
  2765. }
  2766. }, 2000);
  2767. }
  2768. }
  2769. },
  2770. data: chartData
  2771. }]
  2772. }
  2773. that.left3Chart = Highcharts.chart('echartL5', option);
  2774. function autoTooltip (point) {
  2775. that.left3Chart.tooltip.refresh(point);
  2776. }
  2777. },
  2778. initChartL6 () {
  2779. var chartData = left8
  2780. var timer = null;
  2781. var i = 0;
  2782. let that = this
  2783. var option = {
  2784. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  2785. chart: {
  2786. type: 'pie',
  2787. backgroundColor: 'rgba(0,0,0,0)',
  2788. options3d: {
  2789. enabled: true,
  2790. alpha: 45,
  2791. //beta: 0
  2792. },
  2793. events: {
  2794. // load,图表加载完成时触发
  2795. load: function () {
  2796. var chart = this;
  2797. var points = chart.series[0].points;
  2798. var len = points.length;
  2799. timer && clearInterval(timer);
  2800. timer = setInterval(function () {
  2801. autoTooltip(points[i]);
  2802. chartData.forEach((item, index) => {
  2803. item.sliced = false
  2804. item.selected = false
  2805. if (index == i) {
  2806. item.sliced = true
  2807. item.selected = true
  2808. }
  2809. })
  2810. that.left4Chart.update({
  2811. series: [{
  2812. type: 'pie',
  2813. name: '占比',
  2814. point: {
  2815. events: {
  2816. click: function (e) {
  2817. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '战略性新兴产业', e.point.name, '')
  2818. }
  2819. }
  2820. },
  2821. data: chartData
  2822. }]
  2823. })
  2824. i++;
  2825. if (i === len) {
  2826. i = 0;
  2827. }
  2828. }, 2000);
  2829. },
  2830. legendItemClick: function (event) {
  2831. console.log(event);
  2832. return true;
  2833. }
  2834. }
  2835. },
  2836. credits: {
  2837. enabled: false //去掉hightchats水印
  2838. },
  2839. legend: {
  2840. // labelFormatter: function() {
  2841. // return 123;
  2842. // },
  2843. align: 'right',//横向位置
  2844. verticalAlign: 'middle', // 纵向位置
  2845. layout: "vertical",//横排还是竖排
  2846. x: -30,
  2847. y: 30,
  2848. symbolWidth: 50,
  2849. itemDistance: 50,
  2850. itemStyle: {
  2851. fontSize: '20px',
  2852. color: '#fff',
  2853. x: 20,
  2854. fontWeight: 0,
  2855. fontFamily: 'Microsoft YaHei'
  2856. },
  2857. },
  2858. title: {
  2859. text: '战略性新兴产业',
  2860. style: {
  2861. color: '#fff',
  2862. fontSize: 24,
  2863. fontFamily: 'Microsoft YaHei'
  2864. },
  2865. align: 'center',
  2866. verticalAlign: "bottom",
  2867. x: -120
  2868. },
  2869. tooltip: {
  2870. crosshairs: true,
  2871. backgroundColor: 'rgba(0,0,0,0.5)',
  2872. // positioner: function(e){
  2873. // console.log(e, this)
  2874. // },
  2875. useHTML: false, //开启html模式
  2876. style: {
  2877. color: '#fff',
  2878. fontSize: '20',
  2879. fontFamily: 'Microsoft YaHei'
  2880. },
  2881. formatter: function (e) {
  2882. //console.log(this)
  2883. let num = chartData[this.colorIndex].num
  2884. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  2885. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  2886. },
  2887. //pointFormat:
  2888. },
  2889. plotOptions: {
  2890. pie: {
  2891. allowPointSelect: true,
  2892. showInLegend: true, // 图例
  2893. cursor: 'pointer',
  2894. size: 220,
  2895. innerSize: 150, //环形图中间空白,0为饼图
  2896. depth: 25, //立体高度
  2897. slicedOffset: 21, //动画距离
  2898. dataLabels: {
  2899. enabled: false, // 是否展示指示线
  2900. format: '{point.name}: {point.percentage}'
  2901. }
  2902. },
  2903. },
  2904. series: [{
  2905. type: 'pie',
  2906. name: '占比',
  2907. //center: ['35%','50%'],
  2908. point: {
  2909. events: {
  2910. click: function (e) { //点击事件
  2911. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '战略性新兴产业', e.point.name, '')
  2912. },
  2913. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  2914. //console.log(e)
  2915. chartData.forEach((item, index) => {
  2916. item.sliced = false
  2917. item.selected = false
  2918. })
  2919. chartData[e.target.index].sliced = true
  2920. chartData[e.target.index].selected = true
  2921. that.left4Chart.update({
  2922. series: [{
  2923. type: 'pie',
  2924. name: '占比',
  2925. point: {
  2926. events: {
  2927. click: function (e) {
  2928. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '战略性新兴产业', e.point.name, '')
  2929. }
  2930. }
  2931. },
  2932. data: chartData
  2933. }]
  2934. })
  2935. timer && clearInterval(timer);
  2936. },
  2937. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  2938. var points = that.left4Chart.series[0].points;
  2939. var len = points.length;
  2940. timer && clearInterval(timer);
  2941. timer = setInterval(function () {
  2942. autoTooltip(points[i]);
  2943. chartData.forEach((item, index) => {
  2944. item.sliced = false
  2945. item.selected = false
  2946. if (index == i) {
  2947. item.sliced = true
  2948. item.selected = true
  2949. }
  2950. })
  2951. that.left4Chart.update({
  2952. series: [{
  2953. type: 'pie',
  2954. name: '占比',
  2955. point: {
  2956. events: {
  2957. click: function (e) {
  2958. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '战略性新兴产业', e.point.name, '')
  2959. }
  2960. }
  2961. },
  2962. data: chartData
  2963. }]
  2964. })
  2965. i++;
  2966. if (i === len) {
  2967. i = 0;
  2968. }
  2969. }, 2000);
  2970. }
  2971. }
  2972. },
  2973. data: chartData
  2974. }]
  2975. }
  2976. that.left4Chart = Highcharts.chart('echartL6', option);
  2977. function autoTooltip (point) {
  2978. that.left4Chart.tooltip.refresh(point);
  2979. }
  2980. },
  2981. initChartL7 () {
  2982. var chartData = left9
  2983. var timer = null;
  2984. var i = 0;
  2985. let that = this
  2986. var option = {
  2987. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  2988. chart: {
  2989. type: 'pie',
  2990. backgroundColor: 'rgba(0,0,0,0)',
  2991. options3d: {
  2992. enabled: true,
  2993. alpha: 45,
  2994. //beta: 0
  2995. },
  2996. events: {
  2997. // load,图表加载完成时触发
  2998. load: function () {
  2999. var chart = this;
  3000. var points = chart.series[0].points;
  3001. var len = points.length;
  3002. timer && clearInterval(timer);
  3003. timer = setInterval(function () {
  3004. autoTooltip(points[i]);
  3005. chartData.forEach((item, index) => {
  3006. item.sliced = false
  3007. item.selected = false
  3008. if (index == i) {
  3009. item.sliced = true
  3010. item.selected = true
  3011. }
  3012. })
  3013. that.left5Chart.update({
  3014. series: [{
  3015. type: 'pie',
  3016. name: '占比',
  3017. point: {
  3018. events: {
  3019. click: function (e) {
  3020. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '特色优势产业', e.point.name, '')
  3021. }
  3022. }
  3023. },
  3024. data: chartData
  3025. }]
  3026. })
  3027. i++;
  3028. if (i === len) {
  3029. i = 0;
  3030. }
  3031. }, 2000);
  3032. },
  3033. legendItemClick: function (event) {
  3034. console.log(event);
  3035. return true;
  3036. }
  3037. }
  3038. },
  3039. credits: {
  3040. enabled: false //去掉hightchats水印
  3041. },
  3042. title: {
  3043. text: '特色优势产业',
  3044. style: {
  3045. color: '#fff',
  3046. fontSize: 24,
  3047. fontFamily: 'Microsoft YaHei'
  3048. },
  3049. align: 'center',
  3050. verticalAlign: "bottom",
  3051. x: -120
  3052. },
  3053. legend: {
  3054. // labelFormatter: function() {
  3055. // return 123;
  3056. // },
  3057. align: 'right',//横向位置
  3058. verticalAlign: 'middle', // 纵向位置
  3059. layout: "vertical",//横排还是竖排
  3060. x: -50,
  3061. y: 30,
  3062. symbolWidth: 50,
  3063. itemDistance: 50,
  3064. itemStyle: {
  3065. fontSize: '20px',
  3066. color: '#fff',
  3067. x: 20,
  3068. fontWeight: 0,
  3069. fontFamily: 'Microsoft YaHei'
  3070. },
  3071. },
  3072. tooltip: {
  3073. crosshairs: true,
  3074. backgroundColor: 'rgba(0,0,0,0.5)',
  3075. // positioner: function(e){
  3076. // console.log(e, this)
  3077. // },
  3078. useHTML: false, //开启html模式
  3079. style: {
  3080. color: '#fff',
  3081. fontSize: '20',
  3082. fontFamily: 'Microsoft YaHei'
  3083. },
  3084. formatter: function (e) {
  3085. //console.log(this)
  3086. let num = chartData[this.colorIndex].num
  3087. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  3088. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  3089. },
  3090. //pointFormat:
  3091. },
  3092. plotOptions: {
  3093. pie: {
  3094. allowPointSelect: true,
  3095. showInLegend: true, // 图例
  3096. cursor: 'pointer',
  3097. size: 220,
  3098. innerSize: 150, //环形图中间空白,0为饼图
  3099. depth: 25, //立体高度
  3100. slicedOffset: 21, //动画距离
  3101. dataLabels: {
  3102. enabled: false, // 是否展示指示线
  3103. format: '{point.name}: {point.percentage}'
  3104. }
  3105. },
  3106. },
  3107. series: [{
  3108. type: 'pie',
  3109. name: '占比',
  3110. //center: ['35%','50%'],
  3111. point: {
  3112. events: {
  3113. click: function (e) { //点击事件
  3114. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '特色优势产业', e.point.name, '')
  3115. },
  3116. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  3117. //console.log(e)
  3118. chartData.forEach((item, index) => {
  3119. item.sliced = false
  3120. item.selected = false
  3121. })
  3122. chartData[e.target.index].sliced = true
  3123. chartData[e.target.index].selected = true
  3124. that.left5Chart.update({
  3125. series: [{
  3126. type: 'pie',
  3127. name: '占比',
  3128. point: {
  3129. events: {
  3130. click: function (e) {
  3131. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '特色优势产业', e.point.name, '')
  3132. }
  3133. }
  3134. },
  3135. data: chartData
  3136. }]
  3137. })
  3138. timer && clearInterval(timer);
  3139. },
  3140. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  3141. var points = that.left5Chart.series[0].points;
  3142. var len = points.length;
  3143. timer && clearInterval(timer);
  3144. timer = setInterval(function () {
  3145. autoTooltip(points[i]);
  3146. chartData.forEach((item, index) => {
  3147. item.sliced = false
  3148. item.selected = false
  3149. if (index == i) {
  3150. item.sliced = true
  3151. item.selected = true
  3152. }
  3153. })
  3154. that.left5Chart.update({
  3155. series: [{
  3156. type: 'pie',
  3157. name: '占比',
  3158. point: {
  3159. events: {
  3160. click: function (e) {
  3161. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '特色优势产业', e.point.name, '')
  3162. }
  3163. }
  3164. },
  3165. data: chartData
  3166. }]
  3167. })
  3168. i++;
  3169. if (i === len) {
  3170. i = 0;
  3171. }
  3172. }, 2000);
  3173. }
  3174. }
  3175. },
  3176. data: chartData
  3177. }]
  3178. }
  3179. that.left5Chart = Highcharts.chart('echartL7', option);
  3180. function autoTooltip (point) {
  3181. that.left5Chart.tooltip.refresh(point);
  3182. }
  3183. },
  3184. initChartL8 () {
  3185. var chartData = left10
  3186. var timer = null;
  3187. var i = 0;
  3188. let that = this
  3189. var option = {
  3190. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  3191. chart: {
  3192. type: 'pie',
  3193. backgroundColor: 'rgba(0,0,0,0)',
  3194. options3d: {
  3195. enabled: true,
  3196. alpha: 45,
  3197. //beta: 0
  3198. },
  3199. events: {
  3200. // load,图表加载完成时触发
  3201. load: function () {
  3202. var chart = this;
  3203. var points = chart.series[0].points;
  3204. var len = points.length;
  3205. timer && clearInterval(timer);
  3206. timer = setInterval(function () {
  3207. autoTooltip(points[i]);
  3208. chartData.forEach((item, index) => {
  3209. item.sliced = false
  3210. item.selected = false
  3211. if (index == i) {
  3212. item.sliced = true
  3213. item.selected = true
  3214. }
  3215. })
  3216. that.left6Chart.update({
  3217. series: [{
  3218. type: 'pie',
  3219. name: '占比',
  3220. point: {
  3221. events: {
  3222. click: function (e) {
  3223. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '公共基础等产业', e.point.name, '')
  3224. }
  3225. }
  3226. },
  3227. data: chartData
  3228. }]
  3229. })
  3230. i++;
  3231. if (i === len) {
  3232. i = 0;
  3233. }
  3234. }, 2000);
  3235. },
  3236. legendItemClick: function (event) {
  3237. console.log(event);
  3238. return true;
  3239. }
  3240. }
  3241. },
  3242. credits: {
  3243. enabled: false //去掉hightchats水印
  3244. },
  3245. title: {
  3246. text: '公共基础等产业',
  3247. style: {
  3248. color: '#fff',
  3249. fontSize: 24,
  3250. fontFamily: 'Microsoft YaHei'
  3251. },
  3252. align: 'center',
  3253. verticalAlign: "bottom",
  3254. x: -120
  3255. },
  3256. legend: {
  3257. // labelFormatter: function() {
  3258. // return 123;
  3259. // },
  3260. align: 'right',//横向位置
  3261. verticalAlign: 'middle', // 纵向位置
  3262. layout: "vertical",//横排还是竖排
  3263. x: -70,
  3264. y: 50,
  3265. symbolWidth: 50,
  3266. itemDistance: 50,
  3267. itemStyle: {
  3268. fontSize: '20px',
  3269. color: '#fff',
  3270. x: 20,
  3271. fontWeight: 0,
  3272. fontFamily: 'Microsoft YaHei'
  3273. },
  3274. },
  3275. tooltip: {
  3276. crosshairs: true,
  3277. backgroundColor: 'rgba(0,0,0,0.5)',
  3278. // positioner: function(e){
  3279. // console.log(e, this)
  3280. // },
  3281. useHTML: false, //开启html模式
  3282. style: {
  3283. color: '#fff',
  3284. fontSize: '20',
  3285. fontFamily: 'Microsoft YaHei'
  3286. },
  3287. formatter: function (e) {
  3288. //console.log(this)
  3289. let num = chartData[this.colorIndex].num
  3290. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  3291. return `${this.key}:<b>${this.percentage}%</b><br/><b>${this.y}</b>亿,<b>${num}个</b>`
  3292. },
  3293. //pointFormat:
  3294. },
  3295. plotOptions: {
  3296. pie: {
  3297. allowPointSelect: true,
  3298. showInLegend: true, // 图例
  3299. cursor: 'pointer',
  3300. size: 220,
  3301. innerSize: 150, //环形图中间空白,0为饼图
  3302. depth: 25, //立体高度
  3303. slicedOffset: 21, //动画距离
  3304. dataLabels: {
  3305. enabled: false, // 是否展示指示线
  3306. format: '{point.name}: {point.percentage}'
  3307. }
  3308. },
  3309. },
  3310. series: [{
  3311. type: 'pie',
  3312. name: '占比',
  3313. //center: ['35%','50%'],
  3314. point: {
  3315. events: {
  3316. click: function (e) { //点击事件
  3317. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '公共基础等产业', e.point.name, '')
  3318. },
  3319. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  3320. //console.log(e)
  3321. chartData.forEach((item, index) => {
  3322. item.sliced = false
  3323. item.selected = false
  3324. })
  3325. chartData[e.target.index].sliced = true
  3326. chartData[e.target.index].selected = true
  3327. that.left6Chart.update({
  3328. series: [{
  3329. type: 'pie',
  3330. name: '占比',
  3331. point: {
  3332. events: {
  3333. click: function (e) {
  3334. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '公共基础等产业', e.point.name, '')
  3335. }
  3336. }
  3337. },
  3338. data: chartData
  3339. }]
  3340. })
  3341. timer && clearInterval(timer);
  3342. },
  3343. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  3344. var points = that.left6Chart.series[0].points;
  3345. var len = points.length;
  3346. timer && clearInterval(timer);
  3347. timer = setInterval(function () {
  3348. autoTooltip(points[i]);
  3349. chartData.forEach((item, index) => {
  3350. item.sliced = false
  3351. item.selected = false
  3352. if (index == i) {
  3353. item.sliced = true
  3354. item.selected = true
  3355. }
  3356. })
  3357. that.left6Chart.update({
  3358. series: [{
  3359. type: 'pie',
  3360. name: '占比',
  3361. point: {
  3362. events: {
  3363. click: function (e) {
  3364. that.showChartLTipDouble(e.point.name, 'left', '产业布局分析', '公共基础等产业', e.point.name, '')
  3365. }
  3366. }
  3367. },
  3368. data: chartData
  3369. }]
  3370. })
  3371. i++;
  3372. if (i === len) {
  3373. i = 0;
  3374. }
  3375. }, 2000);
  3376. }
  3377. }
  3378. },
  3379. data: chartData
  3380. }]
  3381. }
  3382. that.left6Chart = Highcharts.chart('echartL8', option);
  3383. function autoTooltip (point) {
  3384. that.left6Chart.tooltip.refresh(point);
  3385. }
  3386. },
  3387. initChartL9 () {
  3388. this.chartCarousel = echarts.init(document.getElementById("echartL9"));
  3389. option = {
  3390. tooltip: {
  3391. trigger: 'axis',
  3392. formatter: '指标:' + '{c0}' + '<br/>' + '发展线:' + '{c1}' + '<br/>' + '生存线:' + '{c2}', //+ '<br/>'+ '{a1}:{c1}' + '%',
  3393. axisPointer: {
  3394. type: 'shadow',
  3395. },
  3396. },
  3397. grid: {
  3398. top: '10%',
  3399. right: '5%',
  3400. left: '12%',
  3401. bottom: '15%',
  3402. },
  3403. xAxis: {
  3404. // data: ['总投资收益率', '销售利润率', '成本费用利润率', '总资产周转率', '财务内部收益率'],
  3405. data: left15[this.countType],
  3406. axisLine: {
  3407. show: true, //隐藏X轴轴线
  3408. lineStyle: {
  3409. color: '#005094',
  3410. width: 1,
  3411. },
  3412. },
  3413. axisTick: {
  3414. show: true, //隐藏X轴刻度
  3415. },
  3416. axisLabel: {
  3417. show: true,
  3418. rotate: 30,
  3419. textStyle: {
  3420. color: '#fff', //X轴文字颜色
  3421. fontSize: 20,
  3422. fontFamily: 'Microsoft YaHei'
  3423. },
  3424. },
  3425. },
  3426. yAxis: [
  3427. {
  3428. type: 'value',
  3429. splitLine: {
  3430. show: true,
  3431. lineStyle: {
  3432. color: '#68b4dd66',
  3433. type: 'dashed',
  3434. },
  3435. },
  3436. axisLine: {
  3437. show: false
  3438. },
  3439. axisLabel: {
  3440. show: true,
  3441. formatter: '{value}%',
  3442. textStyle: {
  3443. color: '#fff',
  3444. fontSize: 20,
  3445. fontFamily: 'Microsoft YaHei'
  3446. },
  3447. },
  3448. nameTextStyle: {
  3449. color: '#ebf8ac',
  3450. fontSize: 16,
  3451. fontFamily: 'Microsoft YaHei'
  3452. },
  3453. },
  3454. ],
  3455. series: [
  3456. {
  3457. name: '实际值',
  3458. type: 'bar',
  3459. barWidth: 20,
  3460. itemStyle: {
  3461. normal: {
  3462. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  3463. {
  3464. offset: 0,
  3465. color: '#69c0ff',
  3466. },
  3467. {
  3468. offset: 1,
  3469. color: '#082550',
  3470. },
  3471. ]),
  3472. },
  3473. },
  3474. // data: [70, 52, 33, 41, 52],
  3475. data: left12[this.count + 1][2]
  3476. },
  3477. {
  3478. name: '',
  3479. type: 'line',
  3480. barWidth: 15,
  3481. itemStyle: {
  3482. normal: {
  3483. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  3484. {
  3485. offset: 0,
  3486. color: '#69c0ff',
  3487. },
  3488. {
  3489. offset: 1,
  3490. color: 'green',
  3491. },
  3492. ]),
  3493. },
  3494. },
  3495. // data: [20, 30, 15, 28, 36],
  3496. data: left12[this.count + 1][1]
  3497. },
  3498. {
  3499. name: '',
  3500. type: 'line',
  3501. barWidth: 15,
  3502. itemStyle: {
  3503. normal: {
  3504. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  3505. {
  3506. offset: 0,
  3507. color: '#69c0ff',
  3508. },
  3509. {
  3510. offset: 1,
  3511. color: 'yellow',
  3512. },
  3513. ]),
  3514. },
  3515. },
  3516. // data: [15, 22, 17, 33, 14],
  3517. data: left12[this.count + 1][0]
  3518. },
  3519. ],
  3520. }
  3521. let that = this
  3522. // this.chartCarousel.on('click', function (param) {
  3523. // that.titleName = param.name
  3524. // that.echartSingleTipShow = true
  3525. // setTimeout(() => {
  3526. // that.initChartLTip()
  3527. // });
  3528. // })
  3529. this.chartCarousel.on('mouseover', (params) => {
  3530. that.$refs.indicator.handleHover(true, 1, 2, 3, 4)
  3531. })
  3532. this.chartCarousel.on('mouseout', (params) => {
  3533. that.$refs.indicator.handleHover(false, 1, 2, 3, 4)
  3534. })
  3535. this.chartCarousel.setOption(option)
  3536. // tools.loopShowTooltip(myChart, option, {
  3537. // nterval: 2000,
  3538. // loopSeries: true,
  3539. // })
  3540. },
  3541. initChartL10 () {
  3542. this.left7Chart = echarts.init(document.getElementById("echartL10"));
  3543. let option = {
  3544. title: {
  3545. text: '固定资产进度分布',
  3546. textStyle: {
  3547. color: '#69C0FF',
  3548. fontSize: 30,
  3549. fontWeight: 500,
  3550. fontFamily: 'Microsoft YaHei'
  3551. },
  3552. top: '20',
  3553. left: '20'
  3554. },
  3555. textStyle: {
  3556. color: '#fff',
  3557. },
  3558. tooltip: {
  3559. trigger: "axis",
  3560. formatter: function (params) {
  3561. var tip = params[0].axisValue + '<br/>' + params[0].marker + params[0].data[1] + ':' + params[0].data[2] + '个,' + params[0].data[3] + '亿' + '<br/>' + params[1].marker + params[1].data[1] + ':' + params[1].data[2] + '个,' + params[1].data[3] + '亿';
  3562. return tip
  3563. },
  3564. textStyle: {
  3565. color: '#ffffff', // 文字的颜色
  3566. fontSize: '20', // 文字字体大小
  3567. fontFamily: 'Microsoft YaHei'
  3568. },
  3569. axisPointer: {
  3570. // lineStyle: {
  3571. // type: 'dashed',
  3572. // width: 2,
  3573. // color: 'rgba(255,255,255,0.6)'
  3574. // },
  3575. animation: false
  3576. }
  3577. },
  3578. grid: {
  3579. top: '0%',
  3580. right: '5%',
  3581. left: '15%',
  3582. bottom: '-10%',
  3583. },
  3584. yAxis: {
  3585. data: ['备案', '特别监管'],
  3586. splitLine: {
  3587. show: false,
  3588. lineStyle: {
  3589. color: '#68b4dd66',
  3590. type: 'dashed',
  3591. },
  3592. },
  3593. axisLine: {
  3594. show: false
  3595. },
  3596. axisLabel: {
  3597. show: true,
  3598. formatter: '{value}',
  3599. textStyle: {
  3600. color: '#fff',
  3601. fontSize: 20,
  3602. padding: [0, -10, 0, 0],
  3603. fontFamily: 'Microsoft YaHei',
  3604. },
  3605. },
  3606. nameTextStyle: {
  3607. color: '#ebf8ac',
  3608. fontSize: 16,
  3609. fontFamily: 'Microsoft YaHei'
  3610. },
  3611. },
  3612. xAxis: {
  3613. data: ['项目储备', '项目立项', '可研论证', '投资决策'],
  3614. axisLine: {
  3615. show: true, //隐藏X轴轴线
  3616. lineStyle: {
  3617. color: '#005094',
  3618. width: 1,
  3619. },
  3620. },
  3621. axisTick: {
  3622. show: false, //隐藏X轴刻度
  3623. },
  3624. axisLabel: {
  3625. show: true,
  3626. textStyle: {
  3627. color: '#fff', //X轴文字颜色
  3628. fontSize: 20,
  3629. padding: [-320, 0, 0, 0],
  3630. fontFamily: 'Microsoft YaHei'
  3631. },
  3632. }
  3633. },
  3634. series: [
  3635. {
  3636. name: '特别监管',
  3637. type: 'scatter',
  3638. symbol: 'circle',//'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  3639. symbolSize: function (data) {
  3640. return Math.sqrt(data[2]) * 5;
  3641. },
  3642. // label: {
  3643. // emphasis: {
  3644. // show: true,
  3645. // formatter: function (param) {
  3646. // return param.data[2];
  3647. // },
  3648. // position: 'top'
  3649. // }
  3650. // },
  3651. itemStyle: {
  3652. normal: {
  3653. color: '#69c0ff'
  3654. }
  3655. },
  3656. data: left13[0]
  3657. },
  3658. {
  3659. name: '备案',
  3660. type: 'scatter',
  3661. symbol: 'circle',//'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
  3662. symbolSize: function (data) {
  3663. return Math.sqrt(data[2]) * 5;
  3664. },
  3665. // label: {
  3666. // emphasis: {
  3667. // show: true,
  3668. // formatter: function (param) {
  3669. // return param.data[2];
  3670. // },
  3671. // position: 'top'
  3672. // }
  3673. // },
  3674. itemStyle: {
  3675. normal: {
  3676. color: '#957DFF'
  3677. }
  3678. },
  3679. data: left13[1]
  3680. },
  3681. ]
  3682. }
  3683. let that = this
  3684. that.left7Chart.on('click', function (param) {
  3685. that.showChartLTipDouble(param.name, 'left', '项目阶段分析', '固定资产', param.name, param.seriesName)
  3686. })
  3687. that.left7Chart.setOption(option)
  3688. tools.loopShowTooltip(that.left7Chart, option, {
  3689. nterval: 2000,
  3690. loopSeries: true,
  3691. })
  3692. },
  3693. initChartL11 () {
  3694. this.left8Chart = echarts.init(document.getElementById("echartL11"));
  3695. let option = {
  3696. title: {
  3697. text: '股权类进度分布',
  3698. textStyle: {
  3699. color: '#69C0FF',
  3700. fontSize: 30,
  3701. fontWeight: 500,
  3702. fontFamily: 'Microsoft YaHei'
  3703. },
  3704. top: '20',
  3705. left: '20'
  3706. },
  3707. textStyle: {
  3708. color: '#fff',
  3709. },
  3710. tooltip: {
  3711. trigger: "axis",
  3712. formatter: function (params) {
  3713. var tip = params[0].axisValue + '<br/>' + params[0].marker + params[0].data[1] + ':' + params[0].data[2] + '个,' + params[0].data[3] + '亿' + '<br/>' + params[1].marker + params[1].data[1] + ':' + params[1].data[2] + '个,' + params[1].data[3] + '亿';
  3714. return tip
  3715. },
  3716. textStyle: {
  3717. color: '#FFF', // 文字的颜色
  3718. fontSize: '20', // 文字字体大小
  3719. fontFamily: 'Microsoft YaHei'
  3720. },
  3721. axisPointer: {
  3722. // lineStyle: {
  3723. // type: 'dashed',
  3724. // width: 2,
  3725. // color: 'rgba(255,255,255,0.6)'
  3726. // },
  3727. animation: true
  3728. }
  3729. },
  3730. grid: {
  3731. top: '0%',
  3732. right: '5%',
  3733. left: '15%',
  3734. bottom: '-10%',
  3735. },
  3736. yAxis: {
  3737. data: ['备案', '特别监管'],
  3738. splitLine: {
  3739. show: false,
  3740. lineStyle: {
  3741. color: '#68b4dd66',
  3742. type: 'dashed',
  3743. },
  3744. },
  3745. axisLine: {
  3746. show: false
  3747. },
  3748. axisLabel: {
  3749. show: true,
  3750. formatter: '{value}',
  3751. textStyle: {
  3752. fontSize: 20,
  3753. padding: [0, -10, 0, 0],
  3754. fontFamily: 'Microsoft YaHei'
  3755. },
  3756. },
  3757. nameTextStyle: {
  3758. color: '#ebf8ac',
  3759. fontSize: 16,
  3760. fontFamily: 'Microsoft YaHei'
  3761. },
  3762. },
  3763. xAxis: {
  3764. data: ['项目储备', '项目立项', '可研论证', '投资决策'],
  3765. axisLine: {
  3766. show: true, //隐藏X轴轴线
  3767. lineStyle: {
  3768. color: '#005094',
  3769. width: 1,
  3770. },
  3771. },
  3772. axisTick: {
  3773. show: true, //隐藏X轴刻度
  3774. },
  3775. axisLabel: {
  3776. show: true,
  3777. textStyle: {
  3778. color: '#fff', //X轴文字颜色
  3779. fontSize: 20,
  3780. padding: [-320, 0, 0, 0],
  3781. fontFamily: 'Microsoft YaHei'
  3782. },
  3783. },
  3784. },
  3785. series: [
  3786. {
  3787. name: '',
  3788. type: 'scatter',
  3789. symbol: 'circle',
  3790. symbolSize: function (data) {
  3791. return Math.sqrt(data[2]) * 5;
  3792. },
  3793. // label: {
  3794. // emphasis: {
  3795. // show: true,
  3796. // formatter: function (param) {
  3797. // return param.data[2];
  3798. // },
  3799. // position: 'top'
  3800. // }
  3801. // },
  3802. itemStyle: {
  3803. normal: {
  3804. color: '#40A9FF'
  3805. }
  3806. },
  3807. data: left14[0]
  3808. },
  3809. {
  3810. name: '',
  3811. type: 'scatter',
  3812. symbol: 'circle',
  3813. symbolSize: function (data) {
  3814. return Math.sqrt(data[2]) * 5;
  3815. },
  3816. // label: {
  3817. // emphasis: {
  3818. // show: true,
  3819. // formatter: function (param) {
  3820. // return param.data[2];
  3821. // },
  3822. // position: 'top'
  3823. // }
  3824. // },
  3825. itemStyle: {
  3826. normal: {
  3827. color: '#957DFF'
  3828. }
  3829. },
  3830. data: left14[1]
  3831. },
  3832. ]
  3833. }
  3834. let that = this
  3835. that.left8Chart.on('click', function (param) {
  3836. that.showChartLTipDouble(param.name, 'left', '项目阶段分析', '股权类进度分布', param.name, param.seriesName)
  3837. })
  3838. that.left8Chart.setOption(option)
  3839. tools.loopShowTooltip(that.left8Chart, option, {
  3840. nterval: 2000,
  3841. loopSeries: true,
  3842. })
  3843. },
  3844. // 大屏二
  3845. initChartC1 () {
  3846. var chartData = center2
  3847. var timer = null;
  3848. var i = 0;
  3849. let that = this
  3850. var option = {
  3851. colors: ['#064F78', '#BDB35D', '#623726', '#955773', '#B57C63', '#73A88E', '#09736D', '#13400B', '#0D3265'],
  3852. chart: {
  3853. type: 'pie',
  3854. backgroundColor: 'rgba(0,0,0,0)',
  3855. options3d: {
  3856. enabled: true,
  3857. alpha: 60,
  3858. //beta: 0
  3859. },
  3860. events: {
  3861. // load,图表加载完成时触发
  3862. load: function () {
  3863. var chart = this;
  3864. var points = chart.series[0].points;
  3865. var len = points.length;
  3866. timer && clearInterval(timer);
  3867. timer = setInterval(function () {
  3868. autoTooltip(points[i]);
  3869. chartData.forEach((item, index) => {
  3870. item.sliced = false
  3871. item.selected = false
  3872. if (index == i) {
  3873. item.sliced = true
  3874. item.selected = true
  3875. }
  3876. })
  3877. that.center1Chart.update({
  3878. series: [{
  3879. type: 'pie',
  3880. name: '占比',
  3881. point: {
  3882. events: {
  3883. click: function (e) {
  3884. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'distribution', e.point.options.typeno, 'industry', e.point.options.typeno, 1)
  3885. }
  3886. }
  3887. },
  3888. data: chartData
  3889. }]
  3890. })
  3891. i++;
  3892. if (i === len) {
  3893. i = 0;
  3894. }
  3895. }, 2000);
  3896. },
  3897. legendItemClick: function (event) {
  3898. console.log(event);
  3899. return true;
  3900. }
  3901. }
  3902. },
  3903. credits: {
  3904. enabled: false //去掉hightchats水印
  3905. },
  3906. legend: {
  3907. layout: 'vertical',
  3908. align: 'right',
  3909. y: -10,
  3910. verticalAlign: 'bottom',
  3911. itemStyle: {
  3912. fontSize: '20px',
  3913. color: '#fff',
  3914. fontWeight: 0,
  3915. fontFamily: 'Microsoft YaHei'
  3916. }
  3917. },
  3918. tooltip: {
  3919. crosshairs: true,
  3920. backgroundColor: 'rgba(0,0,0,0.5)',
  3921. useHTML: false, //开启html模式
  3922. style: {
  3923. color: '#fff',
  3924. fontSize: '20',
  3925. fontFamily: 'Microsoft YaHei'
  3926. },
  3927. formatter: function (e) {
  3928. let num = chartData[this.colorIndex].num
  3929. this.percentage = this.percentage.toFixed(2) //Math.round(this.percentage)
  3930. return `${this.key}:<b>${this.percentage}%</b><br/>投资完成额:<b>${this.y}</b>亿<br/>投资数量:<b>${num}个</b>`
  3931. },
  3932. //pointFormat:
  3933. },
  3934. plotOptions: {
  3935. pie: {
  3936. allowPointSelect: true,
  3937. showInLegend: true, // 图例
  3938. cursor: 'pointer',
  3939. size: 500,
  3940. // innerSize: 330, //环形图中间空白,0为饼图
  3941. innerSize: 0, //环形图中间空白,0为饼图
  3942. depth: 75, //立体高度
  3943. slicedOffset: 40, //动画距离
  3944. dataLabels: {
  3945. enabled: false, // 是否展示指示线
  3946. format: '{point.name}: {point.percentage}'
  3947. }
  3948. },
  3949. },
  3950. title: {
  3951. text: '',
  3952. style: {
  3953. color: '#fff',
  3954. fontSize: 24,
  3955. fontFamily: 'Microsoft YaHei'
  3956. },
  3957. align: 'center',
  3958. verticalAlign: "bottom",
  3959. x: -120
  3960. },
  3961. series: [{
  3962. type: 'pie',
  3963. name: '占比',
  3964. center: ['74%', '50%'],
  3965. point: {
  3966. events: {
  3967. click: function (e) { //点击事件
  3968. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'distribution', e.point.options.typeno, 'industry', e.point.options.typeno, 1)
  3969. },
  3970. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  3971. //console.log(e)
  3972. chartData.forEach((item, index) => {
  3973. item.sliced = false
  3974. item.selected = false
  3975. })
  3976. chartData[e.target.index].sliced = true
  3977. chartData[e.target.index].selected = true
  3978. that.center1Chart.update({
  3979. series: [{
  3980. type: 'pie',
  3981. name: '占比',
  3982. point: {
  3983. events: {
  3984. click: function (e) {
  3985. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'distribution', e.point.options.typeno, 'industry', e.point.options.typeno, 1)
  3986. }
  3987. }
  3988. },
  3989. data: chartData
  3990. }]
  3991. })
  3992. timer && clearInterval(timer);
  3993. },
  3994. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  3995. var points = that.center1Chart.series[0].points;
  3996. var len = points.length;
  3997. timer && clearInterval(timer);
  3998. timer = setInterval(function () {
  3999. autoTooltip(points[i]);
  4000. chartData.forEach((item, index) => {
  4001. item.sliced = false
  4002. item.selected = false
  4003. if (index == i) {
  4004. item.sliced = true
  4005. item.selected = true
  4006. }
  4007. })
  4008. that.center1Chart.update({
  4009. series: [{
  4010. type: 'pie',
  4011. name: '占比',
  4012. point: {
  4013. events: {
  4014. click: function (e) {
  4015. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'distribution', e.point.options.typeno, 'industry', e.point.options.typeno, 1)
  4016. }
  4017. }
  4018. },
  4019. data: chartData
  4020. }]
  4021. })
  4022. i++;
  4023. if (i === len) {
  4024. i = 0;
  4025. }
  4026. }, 2000);
  4027. }
  4028. }
  4029. },
  4030. data: chartData
  4031. }]
  4032. }
  4033. that.center1Chart = Highcharts.chart('echartC1', option);
  4034. function autoTooltip (point) {
  4035. that.center1Chart.tooltip.refresh(point);
  4036. }
  4037. },
  4038. initChartC2 () {
  4039. let that = this
  4040. that.center2Chart = echarts.init(this.$refs['echartC2'])
  4041. that.center2Chart.on('showTip', (params) => {
  4042. // 如果是7或者15并且满足防抖则切换
  4043. if ((params.dataIndex == 5 || params.dataIndex == 11) && that.echartC2Fd) {
  4044. that.echartC2Fd = false
  4045. setTimeout(() => {
  4046. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  4047. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  4048. that.center2Chart.setOption(option);
  4049. // 防止勿刷新做的防抖
  4050. setTimeout(() => {
  4051. that.echartC2Fd = true
  4052. }, 2000)
  4053. }, 1900);
  4054. // 如果是17表示到了最后一个,那么重新来一遍
  4055. } else if (params.dataIndex == 17 && that.echartC2Fd) {
  4056. that.echartC2Fd = false
  4057. setTimeout(() => {
  4058. option.dataZoom[0].endValue = 0
  4059. option.dataZoom[0].startValue = 5
  4060. that.center2Chart.setOption(option);
  4061. // 防止勿刷新做的防抖
  4062. setTimeout(() => {
  4063. that.echartC2Fd = true
  4064. }, 2000)
  4065. }, 1900)
  4066. }
  4067. })
  4068. let option = {
  4069. tooltip: {
  4070. formatter: data => {
  4071. return `${data[0].name}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color.colorStops[0].color}"></span> ${data[0].seriesName}:${data[0].value}亿 <br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color.colorStops[0].color}"></span> ${data[1].seriesName}:${data[1].value}亿`
  4072. },
  4073. trigger: 'axis',
  4074. axisPointer: {
  4075. // type: 'cross',',
  4076. },
  4077. textStyle: {
  4078. color: '#FFF', // 文字的颜色
  4079. fontSize: '20', // 文字字体大小
  4080. fontFamily: 'Microsoft YaHei'
  4081. },
  4082. },
  4083. dataZoom: [
  4084. {
  4085. // start: 9,//默认为@
  4086. // end: 100,//黑认认为1@0
  4087. type: "slider",
  4088. show: false,
  4089. // xAxisIndex: [0]
  4090. handlesize: 0,//滑动条的 左右2个滑动条的大小
  4091. startValue: 5,// 初始显示值
  4092. endValue: 0,// 结束显示值
  4093. height: 10,//组件高度
  4094. left: "5%",
  4095. right: "4%",//右边的距离
  4096. bottom: "25%",//底边的距离
  4097. borderColor: "#939",
  4098. fillerColor: "#269cdb",
  4099. borderRadius: 5,
  4100. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  4101. showDataShadow: false,//是否显示数据阴影
  4102. showDetail: false,//即拖拽时候是否显示详细数值信息
  4103. truerealtime: true,//是否实时更新
  4104. filterMode: "filter"
  4105. }, {
  4106. type: 'inside',
  4107. show: true,
  4108. start: 1,
  4109. end: 100,
  4110. zoomOnMouseWheel: false, //滚轮是否触发缩放
  4111. moveOnMouseMove: false, //鼠标滚轮触发滚动
  4112. }
  4113. ],
  4114. grid: {
  4115. top: '10%',
  4116. right: '3%',
  4117. left: '7%',
  4118. bottom: '15%',
  4119. },
  4120. legend: {
  4121. top: '1',
  4122. right: 'center',
  4123. textStyle: {
  4124. color: '#fff',
  4125. fontSize: '20',
  4126. fontFamily: 'Microsoft YaHei'
  4127. },
  4128. },
  4129. xAxis: {
  4130. data: commonCompany,
  4131. // data: center3.map(item => item.name),
  4132. axisLine: {
  4133. show: true, //隐藏X轴轴线
  4134. lineStyle: {
  4135. color: '#005094',
  4136. width: 1,
  4137. },
  4138. },
  4139. axisTick: {
  4140. show: false, //隐藏X轴刻度
  4141. },
  4142. axisLabel: {
  4143. show: true,
  4144. rotate: 40,
  4145. textStyle: {
  4146. color: '#fff',//'rgba(255,255,255,0.6)', //X轴文字颜色
  4147. fontSize: '20',
  4148. fontFamily: 'Microsoft YaHei'
  4149. },
  4150. },
  4151. },
  4152. yAxis: [
  4153. {
  4154. type: 'value',
  4155. name: '亿',
  4156. splitLine: {
  4157. show: true,
  4158. lineStyle: {
  4159. color: '#68b4dd66',
  4160. type: 'dashed',
  4161. },
  4162. },
  4163. axisLine: {
  4164. show: true,
  4165. lineStyle: {
  4166. color: '#3D7495',
  4167. },
  4168. },
  4169. axisLabel: {
  4170. show: true,
  4171. textStyle: {
  4172. color: '#fff',
  4173. fontSize: '20',
  4174. fontFamily: 'Microsoft YaHei'
  4175. },
  4176. },
  4177. nameTextStyle: {
  4178. color: '#fff',
  4179. fontSize: 20,
  4180. fontFamily: 'Microsoft YaHei'
  4181. },
  4182. },
  4183. ],
  4184. series: [
  4185. {
  4186. name: '计划投资',
  4187. type: 'bar',
  4188. barWidth: 10,
  4189. itemStyle: {
  4190. normal: {
  4191. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4192. {
  4193. offset: 0,
  4194. color: '#69c0ff',
  4195. },
  4196. {
  4197. offset: 1,
  4198. color: '#082550',
  4199. },
  4200. ]),
  4201. },
  4202. },
  4203. data: center3.map(item => item.value),
  4204. },
  4205. {
  4206. name: '实际投资',
  4207. type: 'bar',
  4208. barWidth: 10,
  4209. itemStyle: {
  4210. normal: {
  4211. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4212. {
  4213. offset: 0,
  4214. color: '#957DFF',
  4215. },
  4216. {
  4217. offset: 1,
  4218. color: '#082550',
  4219. },
  4220. ]),
  4221. },
  4222. },
  4223. data: center3.map(item => item.value2),
  4224. },
  4225. ],
  4226. }
  4227. that.center2Chart.on('click', function (param) {
  4228. that.projectListTipShow = true
  4229. that.centerPenetrateTwo('', '', that.findCode(param.name), param.seriesName == '计划投资' ? 2 : 1)
  4230. })
  4231. that.center2Chart.setOption(option)
  4232. tools.loopShowTooltip(that.center2Chart, option, {
  4233. nterval: 2000,
  4234. loopSeries: true,
  4235. })
  4236. // let arr = center3.map(item => item.value2)
  4237. // this.timeOut = setInterval(function () {
  4238. // let startValue = myChart.getModel().option.dataZoom[0].startValue;
  4239. // let endValue = myChart.getModel().option.dataZoom[0].endValue;
  4240. // let start = myChart.getModel().option.xAxis[0].data[startValue];//起始X轴
  4241. // let end = myChart.getModel().option.xAxis[0].data[endValue];//结束X轴
  4242. // // 每次向后滚动一个,最后一个从头开始。
  4243. // // console.log(option.dataZoom[0].endValue);
  4244. // if (option.dataZoom[0].endValue >= 12) {
  4245. // option.dataZoom[0].endValue = 5
  4246. // option.dataZoom[0].startValue = 0
  4247. // } else {
  4248. // option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  4249. // option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  4250. // }
  4251. // // myChart.dispatchAction({
  4252. // // type: 'showTip',
  4253. // // seriesIndex: 0,
  4254. // // dataIndex: startValue +1,
  4255. // // });
  4256. // myChart.setOption(option);
  4257. // }, 12000);
  4258. },
  4259. convertData (data) {
  4260. var res = []
  4261. for (var i = 0; i < data.length; i++) {
  4262. var geoCoord = this.geoCoordMap[data[i].name]
  4263. if (geoCoord) {
  4264. res.push({
  4265. name: data[i].name,
  4266. value: geoCoord.concat(data[i].value),
  4267. })
  4268. }
  4269. }
  4270. return res
  4271. },
  4272. yuanChange (value) {
  4273. return Number((value / 100000000).toFixed(2))
  4274. },
  4275. // 逢三折断
  4276. numFormat (value) {
  4277. if (!value) return '0'
  4278. // var intPart = Number(value).toFixed(0) // 获取整数部分
  4279. var intPart = parseInt(value)// 获取整数部分
  4280. var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
  4281. var floatPart = '.00' // 预定义小数部分
  4282. var value2Array = value.toString().split('.')
  4283. // =2表示数据有小数位
  4284. if (value2Array.length === 2) {
  4285. floatPart = value2Array[1].toString() // 拿到小数部分
  4286. if (floatPart.length === 1) {
  4287. // 补0
  4288. return intPartFormat + '.' + floatPart + '0'
  4289. } else {
  4290. return intPartFormat + '.' + floatPart
  4291. }
  4292. } else {
  4293. return intPartFormat
  4294. }
  4295. },
  4296. initProvinceChart () {
  4297. var data = center5
  4298. this.geoCoordMap = []
  4299. /*获取地图数据*/
  4300. this.mapChart = echarts.init(this.$refs['echarts-map'])
  4301. echarts.registerMap('shanxi', shanxi)
  4302. var mapFeatures = echarts.getMap('shanxi').geoJson.features
  4303. mapFeatures.forEach(v => {
  4304. // 地区名称
  4305. var name = v.properties.name
  4306. // 地区经纬度
  4307. this.geoCoordMap[name] = v.properties.centroid
  4308. // 按照地图乱序
  4309. // data.push({ name: v.properties.name, value: v.properties.centroid[0], value2: v.properties.centroid[1] })
  4310. })
  4311. let option = {
  4312. tooltip: {
  4313. padding: 15,
  4314. enterable: true,
  4315. transitionDuration: 1,
  4316. formatter: (params, ticket, callback) => {
  4317. // 清空所有轮播
  4318. for (var k in this.geoCoordMap) {
  4319. this.mapChart.dispatchAction({
  4320. // type: 'geoUnSelect',
  4321. type: 'downplay',
  4322. name: k,
  4323. })
  4324. }
  4325. // 如果鼠标滑动到线线上面,则返回空
  4326. this.mapChart.dispatchAction({
  4327. // type: 'geoSelect',
  4328. type: 'highlight',
  4329. name: params.name,
  4330. })
  4331. if (params.componentSubType == 'lines') {
  4332. return
  4333. }
  4334. if (params.componentSubType == 'scatter') {
  4335. let tipHtml = `
  4336. <div class="tooltip-cont">
  4337. <p>项目数量:<span>${data[params.dataIndex].value2}个</span></p>
  4338. <p>总投资额:<span>${params.data.value[2]}亿</span></p>
  4339. </div>`
  4340. callback(ticket, tipHtml)
  4341. return tipHtml
  4342. }
  4343. if (params.componentSubType == 'map') {
  4344. let tipHtml = `
  4345. <div class="tooltip-cont">
  4346. <p>项目数量:<span>${data[params.dataIndex].value2}个</span></p>
  4347. <p>总投资额:<span>${params.data.value}亿</span></p>
  4348. </div>`
  4349. callback(ticket, tipHtml)
  4350. return tipHtml
  4351. }
  4352. },
  4353. },
  4354. visualMap: {
  4355. show: false,
  4356. min: 0,
  4357. max: 300,
  4358. right: 0,
  4359. bottom: 0,
  4360. text: ['高', '低'],
  4361. textStyle: {
  4362. color: '#f1f1f1'
  4363. },
  4364. realtime: false,
  4365. calculable: false,
  4366. inRange: {
  4367. color: ['lightskyblue', '#2754b7']
  4368. }
  4369. },
  4370. geo: {
  4371. show: true,
  4372. map: 'shanxi',
  4373. layoutCenter: ['50%', '50%'], //地图位置
  4374. layoutSize: '140%',
  4375. label: {
  4376. normal: {
  4377. position: [100, 100],
  4378. fontSize: 25,
  4379. fontFamily: 'Microsoft YaHei',
  4380. fontWeight: 600,
  4381. color: '#fff',
  4382. show: true,
  4383. },
  4384. emphasis: {
  4385. show: true,
  4386. color: '#e7e1a0',
  4387. fontSize: 30,
  4388. },
  4389. },
  4390. roam: false,
  4391. itemStyle: {
  4392. normal: {
  4393. areaColor: '#1946a8',
  4394. shadowColor: '#1946a8',
  4395. borderWidth: 2, //设置外层边框
  4396. borderColor: '#1946a8',
  4397. shadowOffsetX: 0,
  4398. shadowOffsetY: 0,
  4399. shadowBlur: 0,
  4400. },
  4401. emphasis: {
  4402. areaColor: '#013d95',
  4403. borderColor: '#e7e1a0',
  4404. borderWidth: 4, //设置外层边框
  4405. },
  4406. },
  4407. },
  4408. series: [
  4409. {
  4410. type: 'map',
  4411. map: 'shanxi',
  4412. geoIndex: 0,
  4413. aspectScale: 1.5, //长宽比
  4414. data: data,
  4415. },
  4416. ],
  4417. }
  4418. let that = this
  4419. this.mapChart.on('click', function (params) {
  4420. if (params.name == '太原市') {
  4421. that.showChartLTipDouble(params.name, 'center', '', '', '', '', 'investmentMap', '太原市', '山西省')
  4422. }
  4423. })
  4424. tools.loopShowTooltip(this.mapChart, option, {
  4425. interval: 2000,
  4426. loopSeries: false,
  4427. });
  4428. this.mapChart.setOption(option)
  4429. },
  4430. initChinaChart () {
  4431. var data = centerChina
  4432. this.geoCoordMap = []
  4433. /*获取地图数据*/
  4434. this.mapChart = echarts.init(this.$refs['chinaMap'])
  4435. echarts.registerMap('china', china)
  4436. var mapFeatures = echarts.getMap('china').geoJson.features
  4437. mapFeatures.forEach(v => {
  4438. // 地区名称
  4439. var name = v.properties.name
  4440. // 地区经纬度
  4441. this.geoCoordMap[name] = v.properties.cp
  4442. data.push({ name: v.properties.name, value: v.properties.cp[0], value2: v.properties.cp[1] })
  4443. })
  4444. let option = {
  4445. tooltip: {
  4446. padding: 15,
  4447. enterable: true,
  4448. transitionDuration: 1,
  4449. formatter: (params, ticket, callback) => {
  4450. // 清空所有轮播
  4451. this.mapChart.dispatchAction({
  4452. // type: 'geoUnSelect',
  4453. type: 'downplay',
  4454. name: '南海诸岛',
  4455. })
  4456. for (var k in this.geoCoordMap) {
  4457. this.mapChart.dispatchAction({
  4458. // type: 'geoUnSelect',
  4459. type: 'downplay',
  4460. name: k,
  4461. })
  4462. }
  4463. // 如果鼠标滑动到线线上面,则返回空
  4464. this.mapChart.dispatchAction({
  4465. // type: 'geoSelect',
  4466. type: 'highlight',
  4467. name: params.name,
  4468. })
  4469. if (params.componentSubType == 'lines') {
  4470. return
  4471. }
  4472. if (params.componentSubType == 'scatter') {
  4473. let tipHtml = `
  4474. <div class="tooltip-cont">
  4475. <p>项目数量:<span>${data[params.dataIndex].value2}个</span></p>
  4476. <p>总投资额:<span>${params.data.value[2]}亿</span></p>
  4477. </div>`
  4478. callback(ticket, tipHtml)
  4479. return tipHtml
  4480. }
  4481. if (params.componentSubType == 'map') {
  4482. let tipHtml = `
  4483. <div class="tooltip-cont">
  4484. <p>项目数量:<span>${data[params.dataIndex].value2}个</span></p>
  4485. <p>总投资额:<span>${params.data.value}亿</span></p>
  4486. </div>`
  4487. callback(ticket, tipHtml)
  4488. return tipHtml
  4489. }
  4490. },
  4491. },
  4492. visualMap: {
  4493. show: false,
  4494. min: 0,
  4495. max: 1000,
  4496. left: '100',
  4497. bottom: 100,
  4498. text: ['高', '低'],
  4499. textStyle: {
  4500. color: '#f1f1f1'
  4501. },
  4502. realtime: true, //拖拽时,是否实时更新
  4503. calculable: false,
  4504. inRange: {
  4505. color: ['lightskyblue', '#2754b7']
  4506. },
  4507. itemWidth: 50, //图形的宽度,即长条的宽度。
  4508. itemHeight: 400, //图形的高度,即长条的高度。
  4509. textStyle: {
  4510. fontSize: 30,
  4511. color: '#fff'
  4512. }
  4513. },
  4514. geo: {
  4515. show: true,
  4516. map: 'china',
  4517. layoutCenter: ['50%', '50%'], //地图位置
  4518. layoutSize: '110%',
  4519. label: {
  4520. normal: {
  4521. position: [100, 100],
  4522. fontSize: 25,
  4523. fontFamily: 'Microsoft YaHei',
  4524. fontWeight: 600,
  4525. color: '#fff',
  4526. show: true,
  4527. },
  4528. emphasis: {
  4529. show: true,
  4530. color: '#e7e1a0',
  4531. fontSize: 30,
  4532. },
  4533. },
  4534. // 滑轮缩放
  4535. roam: false,
  4536. itemStyle: {
  4537. normal: {
  4538. areaColor: '#1946a8',
  4539. shadowColor: '#1946a8',
  4540. borderWidth: 2, //设置外层边框
  4541. borderColor: '#0b245b',
  4542. shadowOffsetX: 0,
  4543. shadowOffsetY: 0,
  4544. shadowBlur: 0,
  4545. },
  4546. emphasis: {
  4547. areaColor: '#013d95',
  4548. borderColor: '#e7e1a0',
  4549. borderWidth: 4, //设置外层边框
  4550. },
  4551. },
  4552. },
  4553. series: [
  4554. {
  4555. type: 'map',
  4556. map: 'china',
  4557. geoIndex: 0,
  4558. data: data,
  4559. },
  4560. ],
  4561. }
  4562. let that = this
  4563. this.mapChart.on('click', function (params) {
  4564. if (params.name == '山西') {
  4565. // that.showChartLTipDouble(params.name, 'center', '', '', '', '', '', 'investmentMap', '山西省')
  4566. that.mapChart.dispose()
  4567. that.centerShow = true
  4568. setTimeout(() => {
  4569. that.initChartC1()
  4570. that.initChartC2()
  4571. that.initChartC3()
  4572. that.initChartC4()
  4573. if (that.versions) {
  4574. that.centerPenetrateOne('investmentMap', params.name, 3, '', '')
  4575. } else {
  4576. that.initProvinceChart()
  4577. }
  4578. that.initProjectList()
  4579. })
  4580. }
  4581. })
  4582. tools.loopShowTooltip(this.mapChart, option, {
  4583. interval: 2000,
  4584. loopSeries: false,
  4585. });
  4586. this.mapChart.setOption(option)
  4587. },
  4588. initChartC3 () {
  4589. this.center3Chart = echarts.init(this.$refs['echartC3'])
  4590. let option = {
  4591. tooltip: {
  4592. trigger: 'axis',
  4593. formatter: '{a0}:{c0}' + '亿', //+ '<br/>'+ '{a1}:{c1}' + '%',
  4594. axisPointer: {
  4595. // type: 'cross',',
  4596. },
  4597. textStyle: {
  4598. color: '#FFF', // 文字的颜色
  4599. fontSize: '20', // 文字字体大小
  4600. fontFamily: 'Microsoft YaHei'
  4601. },
  4602. },
  4603. grid: {
  4604. top: '8%',
  4605. right: '3%',
  4606. left: '7%',
  4607. bottom: '10%',
  4608. },
  4609. // legend: {
  4610. // top: '1',
  4611. // textStyle: {
  4612. // color: 'rgba(250,250,250,0.6)',
  4613. // },
  4614. // },
  4615. xAxis: {
  4616. data: center6.map(item => item.name),
  4617. axisLine: {
  4618. show: true, //隐藏X轴轴线
  4619. lineStyle: {
  4620. color: '#005094',
  4621. width: 1,
  4622. },
  4623. },
  4624. axisTick: {
  4625. show: false, //隐藏X轴刻度
  4626. },
  4627. axisLabel: {
  4628. show: true,
  4629. rotate: 20,
  4630. textStyle: {
  4631. color: '#fff',//'rgba(255,255,255,0.6)', //X轴文字颜色
  4632. fontSize: '20',
  4633. fontFamily: 'Microsoft YaHei'
  4634. },
  4635. },
  4636. },
  4637. yAxis: [
  4638. {
  4639. type: 'value',
  4640. name: '亿',
  4641. splitLine: {
  4642. show: true,
  4643. lineStyle: {
  4644. color: '#68b4dd66',
  4645. type: 'dashed',
  4646. },
  4647. },
  4648. axisLine: {
  4649. show: true,
  4650. lineStyle: {
  4651. color: '#3D7495',
  4652. },
  4653. },
  4654. axisLabel: {
  4655. show: true,
  4656. textStyle: {
  4657. color: '#fff',
  4658. fontSize: '20',
  4659. fontFamily: 'Microsoft YaHei'
  4660. },
  4661. },
  4662. nameTextStyle: {
  4663. color: '#fff',
  4664. fontSize: 20,
  4665. fontFamily: 'Microsoft YaHei'
  4666. },
  4667. },
  4668. {
  4669. type: 'value',
  4670. axisLine: {
  4671. show: false,
  4672. },
  4673. splitLine: {
  4674. show: false,
  4675. },
  4676. axisLabel: {
  4677. show: true,
  4678. formatter: '{value} %',
  4679. textStyle: {
  4680. color: 'rgba(250,250,250,0.6)',
  4681. },
  4682. },
  4683. },
  4684. ],
  4685. series: [
  4686. {
  4687. type: 'bar',
  4688. name: '投资金额',
  4689. barWidth: 15,
  4690. itemStyle: {
  4691. normal: {
  4692. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  4693. {
  4694. offset: 0,
  4695. color: '#69c0ff',
  4696. },
  4697. {
  4698. offset: 1,
  4699. color: '#082550',
  4700. },
  4701. ]),
  4702. },
  4703. },
  4704. data: center6.map(item => item.value),
  4705. },
  4706. ],
  4707. }
  4708. let that = this
  4709. that.center3Chart.on('click', function (param) {
  4710. if (param.name == '煤炭和煤电') {
  4711. that.showChartLTipSingle(param.name, 'center', 'keyIndicators', 'ceiamount', '', '', '', '', 'five', '1', 2)
  4712. } else if (param.name == '煤电和新能源') {
  4713. that.showChartLTipSingle(param.name, 'center', 'keyIndicators', 'cpneiamount', '', '', '', '', 'five', '2', 2)
  4714. } else if (param.name == '煤炭和化工') {
  4715. that.showChartLTipSingle(param.name, 'center', 'keyIndicators', 'ccheiamount', '', '', '', '', 'five', '3', 2)
  4716. } else if (param.name == '煤炭和数字') {
  4717. that.showChartLTipSingle(param.name, 'center', 'keyIndicators', 'cdiamount', '', '', '', '', 'five', '4', 2)
  4718. } else if (param.name == '煤炭和降炭') {
  4719. that.showChartLTipSingle(param.name, 'center', 'keyIndicators', 'cciamount', '', '', '', '', 'five', '5', 2)
  4720. }
  4721. })
  4722. that.center3Chart.setOption(option)
  4723. tools.loopShowTooltip(that.center3Chart, option, {
  4724. nterval: 2000,
  4725. loopSeries: true,
  4726. })
  4727. },
  4728. initChartC4 () {
  4729. var chartData = []
  4730. var timer = null;
  4731. var timer2 = null;
  4732. var i = 0;
  4733. center7.forEach((item, index) => {
  4734. let obj = {
  4735. name: item.name,
  4736. y: item.value2,
  4737. num: item.value,
  4738. typeno: item.typeno,
  4739. sliced: false,
  4740. selected: false,
  4741. color: index == 0 ? '#064F78' : '#BDB35D'
  4742. }
  4743. chartData.push(obj)
  4744. })
  4745. let that = this
  4746. that.center4Chart = Highcharts.chart('echartC4', {
  4747. chart: {
  4748. type: 'pie',
  4749. backgroundColor: 'rgba(0,0,0,0)',
  4750. options3d: {
  4751. enabled: true,
  4752. alpha: 60,
  4753. //beta: 0
  4754. },
  4755. events: {
  4756. // load,图表加载完成时触发
  4757. load: function () {
  4758. var chart = this;
  4759. var points = chart.series[0].points;
  4760. var len = points.length;
  4761. timer && clearInterval(timer);
  4762. timer = setInterval(function () {
  4763. autoTooltip(points[i]);
  4764. chartData.forEach((item, index) => {
  4765. item.sliced = false
  4766. item.selected = false
  4767. if (index == i) {
  4768. item.sliced = true
  4769. item.selected = true
  4770. }
  4771. })
  4772. that.center4Chart.update({
  4773. series: [{
  4774. type: 'pie',
  4775. name: '占比',
  4776. point: {
  4777. events: {
  4778. click: function (e) {
  4779. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4780. }
  4781. }
  4782. },
  4783. data: chartData
  4784. }]
  4785. })
  4786. i++;
  4787. if (i === len) {
  4788. i = 0;
  4789. chartData.forEach((item, index) => {
  4790. item.sliced = false
  4791. item.selected = false
  4792. })
  4793. that.center4Chart.update({
  4794. series: [{
  4795. type: 'pie',
  4796. name: '占比',
  4797. point: {
  4798. events: {
  4799. click: function (e) {
  4800. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4801. }
  4802. }
  4803. },
  4804. data: chartData
  4805. }]
  4806. })
  4807. }
  4808. }, 2000);
  4809. },
  4810. legendItemClick: function (event) {
  4811. console.log(event);
  4812. return true;
  4813. }
  4814. }
  4815. },
  4816. credits: {
  4817. enabled: false //去掉hightchats水印
  4818. },
  4819. title: {
  4820. text: null
  4821. },
  4822. tooltip: {
  4823. crosshairs: true,
  4824. backgroundColor: 'rgba(0,0,0,0.5)',
  4825. // positioner: function(e){
  4826. // console.log(e, this)
  4827. // },
  4828. useHTML: false, //开启html模式
  4829. style: {
  4830. color: '#fff',
  4831. fontSize: '20',
  4832. fontFamily: 'Microsoft YaHei'
  4833. },
  4834. formatter: function (e) {
  4835. //console.log(this)
  4836. let num = chartData[this.colorIndex].num
  4837. this.percentage = Math.round(this.percentage)
  4838. return `${this.key}:<b>${this.percentage}%</b><br/>投资完成额:<b>${this.y}</b>亿<br/>投资数量:<b>${num}个</b>`
  4839. },
  4840. //pointFormat:
  4841. },
  4842. legend: {
  4843. layout: 'vertical',
  4844. align: 'right',
  4845. y: -10,
  4846. verticalAlign: 'bottom',
  4847. itemStyle: {
  4848. fontSize: '20px',
  4849. color: '#fff',
  4850. fontWeight: 0,
  4851. fontFamily: 'Microsoft YaHei'
  4852. }
  4853. },
  4854. plotOptions: {
  4855. pie: {
  4856. allowPointSelect: true,
  4857. showInLegend: true, // 图例
  4858. cursor: 'pointer',
  4859. size: 500,
  4860. // innerSize: 330, //环形图中间空白,0为饼图
  4861. innerSize: 0, //环形图中间空白,0为饼图
  4862. depth: 75, //立体高度
  4863. slicedOffset: 40, //动画距离
  4864. dataLabels: {
  4865. enabled: false, // 是否展示指示线
  4866. format: '{point.name}: {point.percentage}'
  4867. }
  4868. },
  4869. },
  4870. series: [{
  4871. type: 'pie',
  4872. name: '占比',
  4873. center: ['60%', '50%'],
  4874. y: -10,
  4875. point: {
  4876. events: {
  4877. click: function (e) { //点击事件
  4878. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4879. },
  4880. mouseOver: function (e) { //鼠标移入停止轮播并且找到移入的当前数据设为选中
  4881. //console.log(e)
  4882. chartData.forEach((item, index) => {
  4883. item.sliced = false
  4884. item.selected = false
  4885. })
  4886. chartData[e.target.index].sliced = true
  4887. chartData[e.target.index].selected = true
  4888. that.center4Chart.update({
  4889. series: [{
  4890. type: 'pie',
  4891. name: '占比',
  4892. point: {
  4893. events: {
  4894. click: function (e) {
  4895. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4896. }
  4897. }
  4898. },
  4899. data: chartData
  4900. }]
  4901. })
  4902. timer && clearInterval(timer);
  4903. },
  4904. mouseOut: function () { // 鼠标移出后需要继续执行轮播
  4905. var points = that.center4Chart.series[0].points;
  4906. var len = points.length;
  4907. timer && clearInterval(timer);
  4908. timer = setInterval(function () {
  4909. autoTooltip(points[i]);
  4910. chartData.forEach((item, index) => {
  4911. item.sliced = false
  4912. item.selected = false
  4913. if (index == i) {
  4914. item.sliced = true
  4915. item.selected = true
  4916. }
  4917. })
  4918. that.center4Chart.update({
  4919. series: [{
  4920. type: 'pie',
  4921. name: '占比',
  4922. point: {
  4923. events: {
  4924. click: function (e) {
  4925. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4926. }
  4927. }
  4928. },
  4929. data: chartData
  4930. }]
  4931. })
  4932. i++;
  4933. if (i === len) {
  4934. i = 0;
  4935. chartData.forEach((item, index) => {
  4936. item.sliced = false
  4937. item.selected = false
  4938. })
  4939. that.center4Chart.update({
  4940. series: [{
  4941. type: 'pie',
  4942. name: '占比',
  4943. point: {
  4944. events: {
  4945. click: function (e) {
  4946. that.showChartLTipDouble(e.point.name, 'center', '', '', '', '', 'keyIndicators', e.point.options.typeno, 'state', e.point.name == '新建' ? 'new' : 'renew', 1)
  4947. }
  4948. }
  4949. },
  4950. data: chartData
  4951. }]
  4952. })
  4953. }
  4954. }, 2000);
  4955. }
  4956. }
  4957. },
  4958. data: chartData
  4959. }]
  4960. });
  4961. function autoTooltip (point) {
  4962. that.center4Chart.tooltip.refresh(point);
  4963. }
  4964. },
  4965. initProjectList () {
  4966. let dataList = []
  4967. center8.map(item => {
  4968. if (this.versions) {
  4969. dataList.push([item.office, item.name, this.yuanChange(item.value) + '亿', item.typeno])
  4970. } else {
  4971. dataList.push([item.office, item.name, item.value + '亿'])
  4972. }
  4973. })
  4974. this.storageRecordConfig2.data = dataList
  4975. this.storageRecordConfig2 = { ...this.storageRecordConfig2 }
  4976. },
  4977. // 大屏三
  4978. initChartR1 () {
  4979. let that = this
  4980. that.right1Chart = echarts.init(this.$refs['echartR1'])
  4981. that.right1Chart.on('showTip', (params) => {
  4982. // 如果是7或者15并且满足防抖则切换
  4983. if ((params.dataIndex == 5 || params.dataIndex == 11) && that.echartR1Fd) {
  4984. that.echartR1Fd = false
  4985. setTimeout(() => {
  4986. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  4987. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  4988. that.right1Chart.setOption(option);
  4989. // 防止勿刷新做的防抖
  4990. setTimeout(() => {
  4991. that.echartR1Fd = true
  4992. }, 2000)
  4993. }, 1900);
  4994. // 如果是17表示到了最后一个,那么重新来一遍
  4995. } else if (params.dataIndex == 17 && that.echartR1Fd) {
  4996. that.echartR1Fd = false
  4997. setTimeout(() => {
  4998. option.dataZoom[0].endValue = 0
  4999. option.dataZoom[0].startValue = 5
  5000. that.right1Chart.setOption(option);
  5001. // 防止勿刷新做的防抖
  5002. setTimeout(() => {
  5003. that.echartR1Fd = true
  5004. }, 2000)
  5005. }, 1900)
  5006. }
  5007. })
  5008. let option = {
  5009. tooltip: {
  5010. formatter: data => {
  5011. return `${data[0].name}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color.colorStops[0].color}"></span> ${data[0].seriesName}:${data[0].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color.colorStops[0].color}"></span> ${data[1].seriesName}:${data[1].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[2].color.colorStops[0].color}"></span> ${data[2].seriesName}:${data[2].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[3].color.colorStops[0].color}"></span> ${data[3].seriesName}:${data[3].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[4].color.colorStops[0].color}"></span> ${data[4].seriesName}:${data[4].value}亿`
  5012. },
  5013. textStyle: {
  5014. color: '#FFF', // 文字的颜色
  5015. fontSize: '20', // 文字字体大小
  5016. fontFamily: 'Microsoft YaHei'
  5017. },
  5018. trigger: 'axis',
  5019. axisPointer: {
  5020. // type: 'cross',',
  5021. },
  5022. },
  5023. dataZoom: [
  5024. {
  5025. // start: 9,//默认为@
  5026. // end: 100,//黑认认为1@0
  5027. type: "slider",
  5028. show: false,
  5029. // xAxisIndex: [0]
  5030. handlesize: 0,//滑动条的 左右2个滑动条的大小
  5031. startValue: 5,// 初始显示值
  5032. endValue: 0,// 结束显示值
  5033. height: 10,//组件高度
  5034. left: "5%",
  5035. right: "4%",//右边的距离
  5036. bottom: "25%",//底边的距离
  5037. borderColor: "#939",
  5038. fillerColor: "#269cdb",
  5039. borderRadius: 5,
  5040. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  5041. showDataShadow: false,//是否显示数据阴影
  5042. showDetail: false,//即拖拽时候是否显示详细数值信息
  5043. truerealtime: true,//是否实时更新
  5044. filterMode: "filter"
  5045. }, {
  5046. type: 'inside',
  5047. show: true,
  5048. start: 1,
  5049. end: 100,
  5050. zoomOnMouseWheel: false, //滚轮是否触发缩放
  5051. moveOnMouseMove: false, //鼠标滚轮触发滚动
  5052. }
  5053. ],
  5054. grid: {
  5055. top: '10%',
  5056. right: '3%',
  5057. left: '5%',
  5058. bottom: '5%',
  5059. },
  5060. legend: {
  5061. data: ["预算额", "已签合同额", '产值认定额', '结算额', '付款额'],
  5062. x: 'center',
  5063. y: '0px',
  5064. textStyle: {
  5065. color: '#fff',
  5066. fontSize: "20",
  5067. fontFamily: 'Microsoft YaHei'
  5068. },
  5069. },
  5070. xAxis: {
  5071. data: commonCompany,
  5072. // data: right4.map(item => item.name),
  5073. axisLine: {
  5074. show: true, //隐藏X轴轴线
  5075. lineStyle: {
  5076. color: '#005094',
  5077. width: 1,
  5078. },
  5079. },
  5080. axisTick: {
  5081. show: false, //隐藏X轴刻度
  5082. },
  5083. axisLabel: {
  5084. show: true,
  5085. // rotate: 40,
  5086. textStyle: {
  5087. color: '#fff',//'rgba(255,255,255,0.6)', //X轴文字颜色
  5088. fontSize: "20",
  5089. fontFamily: 'Microsoft YaHei'
  5090. },
  5091. },
  5092. },
  5093. yAxis: [
  5094. {
  5095. type: 'value',
  5096. name: '亿',
  5097. nameTextStyle: {
  5098. color: 'rgba(255,255,255,0.6)',
  5099. },
  5100. splitLine: {
  5101. show: true,
  5102. lineStyle: {
  5103. color: '#68b4dd66',
  5104. type: 'dashed',
  5105. },
  5106. },
  5107. axisLine: {
  5108. show: true,
  5109. lineStyle: {
  5110. color: '#3D7495',
  5111. },
  5112. },
  5113. axisLabel: {
  5114. show: true,
  5115. textStyle: {
  5116. color: '#fff',
  5117. fontSize: "20",
  5118. fontFamily: 'Microsoft YaHei'
  5119. },
  5120. },
  5121. nameTextStyle: {
  5122. color: '#fff',
  5123. fontSize: 20,
  5124. fontFamily: 'Microsoft YaHei'
  5125. },
  5126. },
  5127. ],
  5128. series: [
  5129. {
  5130. name: '预算额',
  5131. type: 'bar',
  5132. barWidth: 10,
  5133. itemStyle: {
  5134. normal: {
  5135. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5136. {
  5137. offset: 0,
  5138. color: '#064F78',
  5139. },
  5140. {
  5141. offset: 1,
  5142. color: '#082550',
  5143. },
  5144. ]),
  5145. },
  5146. },
  5147. data: right4.map(item => item.value),
  5148. },
  5149. {
  5150. name: '已签合同额',
  5151. type: 'bar',
  5152. barWidth: 10,
  5153. itemStyle: {
  5154. normal: {
  5155. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5156. {
  5157. offset: 0,
  5158. color: '#BDB35D',
  5159. },
  5160. {
  5161. offset: 1,
  5162. color: '#082550',
  5163. },
  5164. ]),
  5165. },
  5166. },
  5167. data: right4.map(item => item.value2),
  5168. },
  5169. {
  5170. name: '产值认定额',
  5171. type: 'bar',
  5172. barWidth: 10,
  5173. itemStyle: {
  5174. normal: {
  5175. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5176. {
  5177. offset: 0,
  5178. color: '#623726',
  5179. },
  5180. {
  5181. offset: 1,
  5182. color: '#082550',
  5183. },
  5184. ]),
  5185. },
  5186. },
  5187. data: right4.map(item => item.value3),
  5188. },
  5189. {
  5190. name: '结算额',
  5191. type: 'bar',
  5192. barWidth: 10,
  5193. itemStyle: {
  5194. normal: {
  5195. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5196. {
  5197. offset: 0,
  5198. color: '#13400B',
  5199. },
  5200. {
  5201. offset: 1,
  5202. color: '#082550',
  5203. },
  5204. ]),
  5205. },
  5206. },
  5207. data: right4.map(item => item.value4),
  5208. },
  5209. {
  5210. name: '付款额',
  5211. type: 'bar',
  5212. barWidth: 10,
  5213. itemStyle: {
  5214. normal: {
  5215. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5216. {
  5217. offset: 0,
  5218. color: '#B57C63',
  5219. },
  5220. {
  5221. offset: 1,
  5222. color: '#082550',
  5223. },
  5224. ]),
  5225. },
  5226. },
  5227. data: right4.map(item => item.value5),
  5228. },
  5229. ],
  5230. }
  5231. that.right1Chart.on('click', function (param) {
  5232. if (that.versions) {
  5233. that.rightPenetrateTwo(2, '', that.findCode(param.name), 'right')
  5234. } else {
  5235. that.projectListTipShow = true
  5236. }
  5237. })
  5238. that.right1Chart.setOption(option)
  5239. tools.loopShowTooltip(that.right1Chart, option, {
  5240. interval: 2000,
  5241. loopSeries: true,
  5242. })
  5243. },
  5244. initChartR2 () {
  5245. let that = this
  5246. const itemStyle = {
  5247. // opacity: 0.8,
  5248. shadowBlur: 10,
  5249. shadowOffsetX: 0,
  5250. shadowOffsetY: 0,
  5251. shadowColor: 'rgba(0,0,0,0.3)'
  5252. };
  5253. that.right2Chart = echarts.init(this.$refs['echartR2'])
  5254. that.right2Chart.on('showTip', (params) => {
  5255. // 如果是7或者15并且满足防抖则切换
  5256. if ((params.dataIndex == 5 || params.dataIndex == 11) && that.echartR2Fd) {
  5257. that.echartR2Fd = false
  5258. setTimeout(() => {
  5259. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  5260. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  5261. that.right2Chart.setOption(option);
  5262. // 防止勿刷新做的防抖
  5263. setTimeout(() => {
  5264. that.echartR2Fd = true
  5265. }, 2000)
  5266. }, 1900);
  5267. // 如果是17表示到了最后一个,那么重新来一遍
  5268. } else if (params.dataIndex == 17 && that.echartR2Fd) {
  5269. that.echartR2Fd = false
  5270. setTimeout(() => {
  5271. option.dataZoom[0].endValue = 0
  5272. option.dataZoom[0].startValue = 5
  5273. that.right2Chart.setOption(option);
  5274. // 防止勿刷新做的防抖
  5275. setTimeout(() => {
  5276. that.echartR2Fd = true
  5277. }, 2000)
  5278. }, 1900)
  5279. }
  5280. })
  5281. let option = {
  5282. color: ['#04635E', '#697143', '#4A3042'],
  5283. dataZoom: [
  5284. {
  5285. // start: 9,//默认为@
  5286. // end: 100,//黑认认为1@0
  5287. type: "slider",
  5288. show: false,
  5289. // xAxisIndex: [0]
  5290. handlesize: 0,//滑动条的 左右2个滑动条的大小
  5291. startValue: 5,// 初始显示值
  5292. endValue: 0,// 结束显示值
  5293. height: 10,//组件高度
  5294. left: "5%",
  5295. right: "4%",//右边的距离
  5296. bottom: "25%",//底边的距离
  5297. borderColor: "#939",
  5298. fillerColor: "#269cdb",
  5299. borderRadius: 5,
  5300. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  5301. showDataShadow: false,//是否显示数据阴影
  5302. showDetail: false,//即拖拽时候是否显示详细数值信息
  5303. truerealtime: true,//是否实时更新
  5304. filterMode: "filter"
  5305. }, {
  5306. type: 'inside',
  5307. show: true,
  5308. start: 1,
  5309. end: 100,
  5310. zoomOnMouseWheel: false, //滚轮是否触发缩放
  5311. moveOnMouseMove: false, //鼠标滚轮触发滚动
  5312. }
  5313. ],
  5314. legend: {
  5315. top: 10,
  5316. data: ['正偏差', '容差', '负偏差'],
  5317. textStyle: {
  5318. fontSize: 20,
  5319. color: '#fff',
  5320. fontFamily: 'Microsoft YaHei'
  5321. }
  5322. },
  5323. textStyle: {
  5324. color: '#fff',
  5325. },
  5326. tooltip: {
  5327. show: true,
  5328. trigger: "axis",
  5329. textStyle: {
  5330. color: '#FFF', // 文字的颜色
  5331. fontSize: '20', // 文字字体大小
  5332. fontFamily: 'Microsoft YaHei'
  5333. },
  5334. formatter: data => {
  5335. return `${data[0].value[0]}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color}"></span> ${data[0].seriesName}:${data[0].data[2]}亿<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color}"></span> ${data[1].seriesName}:${data[1].data[2]}亿<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[2].color}"></span> ${data[2].seriesName}:${data[2].data[2]}亿`
  5336. },
  5337. axisPointer: {
  5338. // // type: 'cross',',
  5339. },
  5340. },
  5341. grid: {
  5342. top: '10%',
  5343. right: '4%',
  5344. left: '5%',
  5345. bottom: '5%',
  5346. },
  5347. yAxis: {
  5348. name: '',
  5349. splitLine: {
  5350. show: true,
  5351. lineStyle: {
  5352. color: '#68b4dd66',
  5353. type: 'dashed',
  5354. },
  5355. },
  5356. axisLine: {
  5357. show: false
  5358. },
  5359. axisLabel: {
  5360. show: true,
  5361. formatter: '{value}%',
  5362. textStyle: {
  5363. color: '#fff',
  5364. fontSize: '20',
  5365. fontFamily: 'Microsoft YaHei'
  5366. },
  5367. },
  5368. nameTextStyle: {
  5369. color: '#fff',
  5370. fontSize: 20,
  5371. fontFamily: 'Microsoft YaHei'
  5372. },
  5373. },
  5374. xAxis: {
  5375. data: commonCompany,
  5376. // data: right5[0].map(item => item[0]),
  5377. axisLine: {
  5378. show: true, //隐藏X轴轴线
  5379. lineStyle: {
  5380. color: '#005094',
  5381. width: 1,
  5382. },
  5383. },
  5384. splitLine: {
  5385. show: true,
  5386. lineStyle: {
  5387. color: '#68b4dd66',
  5388. type: 'dashed',
  5389. },
  5390. },
  5391. axisTick: {
  5392. show: false, //隐藏X轴刻度
  5393. },
  5394. axisLabel: {
  5395. show: true,
  5396. // rotate: 40,
  5397. padding: [0, 0, 0, 0],
  5398. textStyle: {
  5399. color: '#fff', //X轴文字颜色
  5400. fontSize: 20,
  5401. fontFamily: 'Microsoft YaHei'
  5402. },
  5403. },
  5404. },
  5405. series: [
  5406. {
  5407. name: '正偏差',
  5408. type: 'scatter',
  5409. itemStyle: itemStyle,
  5410. data: right5[0],
  5411. symbolSize: function (data) {
  5412. return Math.sqrt(Math.abs(data[2])) * 9;
  5413. },
  5414. },
  5415. {
  5416. name: '容差',
  5417. type: 'scatter',
  5418. itemStyle: itemStyle,
  5419. data: right5[1],
  5420. symbolSize: function (data) {
  5421. return Math.sqrt(Math.abs(data[2])) * 9;
  5422. },
  5423. },
  5424. {
  5425. name: '负偏差',
  5426. type: 'scatter',
  5427. itemStyle: itemStyle,
  5428. data: right5[2],
  5429. symbolSize: function (data) {
  5430. return Math.sqrt(Math.abs(data[2])) * 9;
  5431. },
  5432. }
  5433. ]
  5434. }
  5435. that.right2Chart.on('click', function (param) {
  5436. if (that.versions) {
  5437. that.rightPenetrateTwo(1, param.seriesName == '正偏差' ? 1 : param.seriesName == '容差' ? 2 : 3, that.findCode(param.name), 'right')
  5438. } else {
  5439. that.projectListTipShow = true
  5440. }
  5441. })
  5442. that.right2Chart.setOption(option)
  5443. tools.loopShowTooltip(that.right2Chart, option, {
  5444. interval: 2000,
  5445. loopSeries: true,
  5446. })
  5447. },
  5448. initChartR3 () {
  5449. let that = this
  5450. that.right3Chart = echarts.init(this.$refs['echartR3'])
  5451. that.right3Chart.on('showTip', (params) => {
  5452. this.echartR4Chart ? this.echartR4Chart.dispose() : ''
  5453. this.echartR5Chart ? this.echartR5Chart.dispose() : ''
  5454. that.initChartR4(params.dataIndex)
  5455. that.initChartR5(params.dataIndex)
  5456. // 如果是7或者15并且满足防抖则切换
  5457. if ((params.dataIndex == 5 || params.dataIndex == 11) && that.echartR3Fd) {
  5458. that.echartR3Fd = false
  5459. setTimeout(() => {
  5460. option.dataZoom[0].endValue = option.dataZoom[0].endValue + 6
  5461. option.dataZoom[0].startValue = option.dataZoom[0].startValue + 6
  5462. that.right3Chart.setOption(option);
  5463. // 防止勿刷新做的防抖
  5464. setTimeout(() => {
  5465. that.echartR3Fd = true
  5466. }, 2000)
  5467. }, 7900);
  5468. // 如果是17表示到了最后一个,那么重新来一遍
  5469. } else if (params.dataIndex == 17 && that.echartR3Fd) {
  5470. that.echartR3Fd = false
  5471. setTimeout(() => {
  5472. option.dataZoom[0].endValue = 0
  5473. option.dataZoom[0].startValue = 5
  5474. that.right3Chart.setOption(option);
  5475. // 防止勿刷新做的防抖
  5476. setTimeout(() => {
  5477. that.echartR3Fd = true
  5478. }, 2000)
  5479. }, 7900)
  5480. }
  5481. })
  5482. let option = {
  5483. tooltip: {
  5484. formatter: data => {
  5485. return `${data[0].name}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color.colorStops[0].color}"></span> ${data[0].seriesName}:${data[0].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color.colorStops[0].color}"></span> ${data[1].seriesName}:${data[1].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[2].color.colorStops[0].color}"></span> ${data[2].seriesName}:${data[2].value}亿`
  5486. },
  5487. trigger: 'axis',
  5488. axisPointer: {
  5489. // type: 'cross',',
  5490. },
  5491. position: (params) => {
  5492. return [params[0] + 10, 60]
  5493. },
  5494. textStyle: {
  5495. color: '#FFF', // 文字的颜色
  5496. fontSize: '20', // 文字字体大小
  5497. fontFamily: 'Microsoft YaHei'
  5498. },
  5499. confine: true
  5500. },
  5501. dataZoom: [
  5502. {
  5503. // start: 9,//默认为@
  5504. // end: 100,//黑认认为1@0
  5505. type: "slider",
  5506. show: false,
  5507. // xAxisIndex: [0]
  5508. handlesize: 0,//滑动条的 左右2个滑动条的大小
  5509. startValue: 5,// 初始显示值
  5510. endValue: 0,// 结束显示值
  5511. height: 10,//组件高度
  5512. left: "5%",
  5513. right: "4%",//右边的距离
  5514. bottom: "25%",//底边的距离
  5515. borderColor: "#939",
  5516. fillerColor: "#269cdb",
  5517. borderRadius: 5,
  5518. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  5519. showDataShadow: false,//是否显示数据阴影
  5520. showDetail: false,//即拖拽时候是否显示详细数值信息
  5521. truerealtime: true,//是否实时更新
  5522. filterMode: "filter"
  5523. }, {
  5524. type: 'inside',
  5525. show: true,
  5526. start: 1,
  5527. end: 100,
  5528. zoomOnMouseWheel: false, //滚轮是否触发缩放
  5529. moveOnMouseMove: false, //鼠标滚轮触发滚动
  5530. }
  5531. ],
  5532. grid: {
  5533. top: '25%',
  5534. right: '3%',
  5535. left: '10%',
  5536. bottom: '20%',
  5537. },
  5538. legend: {
  5539. data: ["低风险", "中风险", '高风险'],
  5540. x: 'center',
  5541. y: '15px',
  5542. textStyle: {
  5543. // color: 'rgba(250,250,250,0.6)',
  5544. color: '#fff',
  5545. fontSize: "20",
  5546. fontFamily: 'Microsoft YaHei'
  5547. },
  5548. },
  5549. xAxis: {
  5550. data: commonCompany,
  5551. // data: right4.map(item => item.name),
  5552. axisLine: {
  5553. show: true, //隐藏X轴轴线
  5554. lineStyle: {
  5555. color: '#005094',
  5556. width: 1,
  5557. },
  5558. },
  5559. axisTick: {
  5560. show: false, //隐藏X轴刻度
  5561. },
  5562. axisLabel: {
  5563. show: true,
  5564. rotate: 40,
  5565. textStyle: {
  5566. color: '#fff',//'rgba(255,255,255,0.6)', //X轴文字颜色
  5567. fontSize: '20',
  5568. fontFamily: 'Microsoft YaHei'
  5569. },
  5570. },
  5571. },
  5572. yAxis: [
  5573. {
  5574. type: 'value',
  5575. name: '亿',
  5576. nameTextStyle: {
  5577. color: 'rgba(255,255,255,0.6)',
  5578. },
  5579. splitLine: {
  5580. show: true,
  5581. lineStyle: {
  5582. color: '#68b4dd66',
  5583. type: 'dashed',
  5584. },
  5585. },
  5586. axisLine: {
  5587. show: true,
  5588. lineStyle: {
  5589. color: '#3D7495',
  5590. },
  5591. },
  5592. axisLabel: {
  5593. show: true,
  5594. textStyle: {
  5595. color: '#fff',
  5596. fontSize: '20',
  5597. fontFamily: 'Microsoft YaHei'
  5598. },
  5599. },
  5600. nameTextStyle: {
  5601. color: '#fff',
  5602. fontSize: 20,
  5603. fontFamily: 'Microsoft YaHei'
  5604. },
  5605. },
  5606. ],
  5607. series: [
  5608. {
  5609. name: '高风险',
  5610. type: 'bar',
  5611. stack: 'Ad',
  5612. barWidth: 10,
  5613. itemStyle: {
  5614. normal: {
  5615. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5616. {
  5617. offset: 0,
  5618. color: '#4A3042',
  5619. },
  5620. {
  5621. offset: 1,
  5622. color: '#4A3042',
  5623. },
  5624. ]),
  5625. },
  5626. },
  5627. data: right6.map(item => item.value),
  5628. },
  5629. {
  5630. name: '中风险',
  5631. type: 'bar',
  5632. stack: 'Ad',
  5633. barWidth: 10,
  5634. itemStyle: {
  5635. normal: {
  5636. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5637. {
  5638. offset: 0,
  5639. color: '#697143',
  5640. },
  5641. {
  5642. offset: 1,
  5643. color: '#697143',
  5644. },
  5645. ]),
  5646. },
  5647. },
  5648. data: right6.map(item => item.value2),
  5649. },
  5650. {
  5651. name: '低风险',
  5652. type: 'bar',
  5653. stack: 'Ad',
  5654. barWidth: 10,
  5655. itemStyle: {
  5656. normal: {
  5657. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5658. {
  5659. offset: 0,
  5660. color: '#04635E',
  5661. },
  5662. {
  5663. offset: 1,
  5664. color: '#04635E',
  5665. },
  5666. ]),
  5667. },
  5668. },
  5669. data: right6.map(item => item.value3),
  5670. },
  5671. ],
  5672. }
  5673. that.right3Chart.on('click', function (param) {
  5674. if (that.versions) {
  5675. that.rightPenetrateTwo('', '', that.findCode(param.name), 'right')
  5676. } else {
  5677. that.projectListTipShow = true
  5678. }
  5679. })
  5680. that.right3Chart.setOption(option)
  5681. tools.loopShowTooltip(that.right3Chart, option, {
  5682. interval: 8000,
  5683. loopSeries: true,
  5684. })
  5685. },
  5686. initChartR4 (indexValue) {
  5687. this.echartR4Chart = echarts.init(this.$refs['echartR4'])
  5688. option = {
  5689. title: {
  5690. text: ''
  5691. },
  5692. radar: {
  5693. center: ['50%', '50%'],
  5694. radius: 135,
  5695. indicator: [
  5696. { name: '安全风险', max: 100000 },
  5697. { name: '付款风险', max: 100000 },
  5698. { name: '合同风险', max: 100000 },
  5699. { name: '结算风险', max: 100000 },
  5700. { name: '进度风险', max: 100000 },
  5701. { name: '质量风险', max: 100000 },
  5702. ],
  5703. axisLine: { // 设置雷达图中间射线的颜色
  5704. lineStyle: {
  5705. color: '#887d33',
  5706. },
  5707. },
  5708. splitLine: { //网格颜色设置
  5709. show: true,
  5710. lineStyle: {
  5711. width: 1,
  5712. color: ['#871b1a', '#638f41', '#d29e35', '#b6802b']
  5713. },
  5714. },
  5715. name: { //修改indicator文字的颜色
  5716. textStyle: {
  5717. color: "#fff",
  5718. fontSize: '20',
  5719. fontFamily: 'Microsoft YaHei'
  5720. }
  5721. },
  5722. splitNumber: 4, //有几个圈
  5723. splitArea: { //设置图表颜色,show的值为true
  5724. show: true,
  5725. areaStyle: {
  5726. // color:"#c1ddf8", //一般设置方式
  5727. //设置渐变背景色 new echarts.graphic.LinearGradient(a,b,c,d,arr)
  5728. //a ,b,c,d值可为0,1 a:1表示arr中的颜色右到左;c:1 arr中的颜色左到右
  5729. //b:1表示arr中的颜色下到上;d:1表示arr中的颜色上到下
  5730. // color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
  5731. // { offset: 0, color: '#887D33' }, // 0% 处的颜色
  5732. // { offset: 0.75, color: '#7D4216' }, // 0% 处的颜色
  5733. // { offset: 1, color: '#430705' }// 100% 处的颜色
  5734. // ], false)
  5735. color: ['#638f41', '#887d33', '#7d4216', '#430705'],
  5736. }
  5737. }
  5738. },
  5739. series: [
  5740. {
  5741. name: '',
  5742. type: 'radar',
  5743. symbol: 'circle', // 单个数值点的样式,还可以取值'rect','angle'等
  5744. symbolSize: 0, // 数值点的大小
  5745. data: [
  5746. {
  5747. value: right7[indexValue],
  5748. name: '安全风险',
  5749. itemStyle: { //该数值区域样式设置
  5750. normal: {
  5751. color: 'rgb(44,198,255,0.8)', //背景颜色,还需设置areaStyle
  5752. lineStyle: {
  5753. color: 'rgb(44,198,255,0.8)', //边框颜色
  5754. },
  5755. },
  5756. },
  5757. label: { //显示value中具体的数值
  5758. normal: {
  5759. show: false,
  5760. textStyle: { //更改数值样式
  5761. color: '#43EDE3'
  5762. }
  5763. },
  5764. },
  5765. areaStyle: { //设置区域背景颜色透明度
  5766. normal: {
  5767. width: 1,
  5768. opacity: 0.8,
  5769. },
  5770. },
  5771. }
  5772. ]
  5773. }
  5774. ]
  5775. };
  5776. // tools.loopShowTooltip(myChart, option, {
  5777. // interval: 2000,
  5778. // loopSeries: true,
  5779. // });
  5780. this.echartR4Chart.setOption(option)
  5781. },
  5782. initChartR5 () {
  5783. this.echartR5Chart = echarts.init(this.$refs['echartR5'])
  5784. let option = {
  5785. tooltip: {
  5786. formatter: data => {
  5787. return `${data[0].name}<br /><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[0].color.colorStops[0].color}"></span> ${data[0].seriesName}:${data[0].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[1].color.colorStops[0].color}"></span> ${data[1].seriesName}:${data[1].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[2].color.colorStops[0].color}"></span> ${data[2].seriesName}:${data[2].value}亿<br/><span style="display:inline-block;border-radius:50%; width:7px;height:7px;background-color:${data[3].color.colorStops[0].color}"></span> ${data[3].seriesName}:${data[3].value}亿`
  5788. },
  5789. trigger: 'axis',
  5790. axisPointer: {
  5791. // type: 'cross',',
  5792. },
  5793. textStyle: {
  5794. color: '#FFF', // 文字的颜色
  5795. fontSize: '20', // 文字字体大小
  5796. fontFamily: 'Microsoft YaHei'
  5797. },
  5798. },
  5799. grid: {
  5800. top: '15%',
  5801. right: '3%',
  5802. left: '5%',
  5803. bottom: '35',
  5804. },
  5805. legend: {
  5806. data: ["预算额", "合同额", "结算额", "支付额"],
  5807. x: 'center',
  5808. y: '10px',
  5809. textStyle: {
  5810. // color: 'rgba(250,250,250,0.6)',
  5811. color: '#fff',
  5812. fontSize: "20",
  5813. fontFamily: 'Microsoft YaHei'
  5814. },
  5815. },
  5816. xAxis: {
  5817. data: ['设备费', '设计费', '施工费', '材料费'],
  5818. axisLine: {
  5819. show: true, //隐藏X轴轴线
  5820. lineStyle: {
  5821. color: '#005094',
  5822. width: 1,
  5823. },
  5824. },
  5825. axisTick: {
  5826. show: false, //隐藏X轴刻度
  5827. },
  5828. axisLabel: {
  5829. show: true,
  5830. // rotate: 40,
  5831. textStyle: {
  5832. color: '#fff',//'rgba(255,255,255,0.6)', //X轴文字颜色
  5833. fontSize: '20', // 文字字体大小
  5834. fontFamily: 'Microsoft YaHei'
  5835. },
  5836. },
  5837. },
  5838. yAxis: [
  5839. {
  5840. type: 'value',
  5841. name: '亿',
  5842. nameTextStyle: {
  5843. color: 'rgba(255,255,255,0.6)',
  5844. },
  5845. splitLine: {
  5846. show: true,
  5847. lineStyle: {
  5848. color: '#68b4dd66',
  5849. type: 'dashed',
  5850. },
  5851. },
  5852. axisLine: {
  5853. show: true,
  5854. lineStyle: {
  5855. color: '#3D7495',
  5856. },
  5857. },
  5858. axisLabel: {
  5859. show: true,
  5860. textStyle: {
  5861. color: '#fff',
  5862. fontSize: '20', // 文字字体大小
  5863. fontFamily: 'Microsoft YaHei'
  5864. },
  5865. },
  5866. nameTextStyle: {
  5867. color: '#fff',
  5868. fontSize: 20,
  5869. fontFamily: 'Microsoft YaHei'
  5870. },
  5871. },
  5872. ],
  5873. series: [
  5874. {
  5875. name: '预算额',
  5876. type: 'bar',
  5877. barWidth: 10,
  5878. itemStyle: {
  5879. normal: {
  5880. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5881. {
  5882. offset: 0,
  5883. color: '#064F78',
  5884. },
  5885. {
  5886. offset: 1,
  5887. color: '#082550',
  5888. },
  5889. ]),
  5890. },
  5891. },
  5892. data: right8.map(item => item.value),
  5893. },
  5894. {
  5895. name: '合同额',
  5896. type: 'bar',
  5897. barWidth: 10,
  5898. itemStyle: {
  5899. normal: {
  5900. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5901. {
  5902. offset: 0,
  5903. color: '#BDB35D',
  5904. },
  5905. {
  5906. offset: 1,
  5907. color: '#082550',
  5908. },
  5909. ]),
  5910. },
  5911. },
  5912. data: right8.map(item => item.value2),
  5913. },
  5914. {
  5915. name: '结算额',
  5916. type: 'bar',
  5917. barWidth: 10,
  5918. itemStyle: {
  5919. normal: {
  5920. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5921. {
  5922. offset: 0,
  5923. color: '#623726',
  5924. },
  5925. {
  5926. offset: 1,
  5927. color: '#082550',
  5928. },
  5929. ]),
  5930. },
  5931. },
  5932. data: right8.map(item => item.value3),
  5933. },
  5934. {
  5935. name: '支付额',
  5936. type: 'bar',
  5937. barWidth: 10,
  5938. itemStyle: {
  5939. normal: {
  5940. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  5941. {
  5942. offset: 0,
  5943. color: '#955773',
  5944. },
  5945. {
  5946. offset: 1,
  5947. color: '#082550',
  5948. },
  5949. ]),
  5950. },
  5951. },
  5952. data: right8.map(item => item.value4),
  5953. },
  5954. ],
  5955. }
  5956. this.echartR5Chart.setOption(option)
  5957. tools.loopShowTooltip(this.echartR5Chart, option, {
  5958. interval: 2000,
  5959. loopSeries: true,
  5960. })
  5961. },
  5962. },
  5963. })