home.vue 167 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883
  1. <template>
  2. <div class="common-layout">
  3. <el-container>
  4. <el-header>
  5. <myheader />
  6. </el-header>
  7. <el-main>
  8. <div class="main_container padding_gg">
  9. <div class="heder_tabs">
  10. <el-tabs v-model="activeName" type="card" class="demo-tabs" @tab-click="handleClick">
  11. <!-- 开始 -->
  12. <el-tab-pane label="首页" name="User">
  13. <!-- <router-link to="/"> </router-link> -->
  14. </el-tab-pane>
  15. <el-tab-pane label="问题设定" name="Role">
  16. <div class="imgzong Role">
  17. <!-- <div class="listitem lbg_color3 bkcolor3 ">
  18. <div class="threelist">
  19. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist" :key="'Role' + index"
  20. :class="{ activeOrange: active == 'Role' + index }"
  21. @click="clickgeometry($event, index, 'Role' + index, item.titlie)">
  22. <el-image :src="getImgPath(item.url)" fit="cover" />
  23. <span>{{ item.titlie }}</span>
  24. </div>
  25. </div>
  26. </div> -->
  27. <!-- <div class="item2 margr" @click="clickgeometry($event, index, 'Role-' + '2', undmodel)">
  28. <el-image :src="getImgPath('tow1.png')" fit="cover" />
  29. <span>{{ f4ce }}</span>
  30. <el-select v-model="f4ce" class="no-border headersele" :suffix-icon="CaretBottom">
  31. <el-option v-for="item in optiongroup1" :key="item.value" :label="item.label" :value="item.value">
  32. </el-option>
  33. </el-select>
  34. </div> -->
  35. <div class="listitem lbg_color3 bkcolor3 threelist">
  36. <div class="item2 margr" @click="clickgeometry($event, index, 'Role-' + '2', undmodel)">
  37. <el-image :src="getImgPath('tow1.png')" fit="cover" />
  38. <span>{{ f4ce }}</span>
  39. <!-- <el-select v-model="f4ce" class="no-border headersele" :suffix-icon="CaretBottom">
  40. <el-option v-for="item in optiongroup1" :key="item.value" :label="item.label" :value="item.value">
  41. <div style="display: flex; align-items: center;">
  42. <img :src="getflowImgPath(item.img)" style="width: 20px; height: 20px; margin-right: 10px;" />
  43. <span>{{ item.label }}</span>
  44. </div>
  45. </el-option>
  46. </el-select> -->
  47. <el-dropdown
  48. trigger="click"
  49. >
  50. <!-- 下拉触发区域(只显示图标) -->
  51. <span class="dropdown-trigger">
  52. <el-icon :size="12" style="width:78px;top:-4px"><arrow-down /></el-icon> <!-- 自定义图标 -->
  53. </span>
  54. <!-- 下拉菜单选项 -->
  55. <template #dropdown>
  56. <el-dropdown-menu>
  57. <el-dropdown-item
  58. v-for="item in optiongroup1"
  59. :key="item.value"
  60. :command="item.value"
  61. >
  62. <div style="display: flex; align-items: center;">
  63. <img
  64. :src="getflowImgPath(item.img)"
  65. style="width: 20px; height: 20px; margin-right: 10px;"
  66. />
  67. <span>{{ item.label }}</span>
  68. </div>
  69. </el-dropdown-item>
  70. </el-dropdown-menu>
  71. </template>
  72. </el-dropdown>
  73. </div>
  74. <div class="item2 margr" @click="clickgeometry($event, index, 'Role-' + '1', modelban)">
  75. <el-image :src="getImgPath('tow2.png')" fit="cover" />
  76. <span>{{ modelban }}</span>
  77. <!-- <el-select v-model="modelban" class="no-border headersele" :suffix-icon="CaretBottom">
  78. <el-option v-for="item in optiongroup" :key="item.value" :label="item.label" :value="item.value">
  79. <div style="display: flex; align-items: center;">
  80. <img :src="getflowImgPath(item.img)" style="width: 20px; height: 20px; margin-right: 10px;" />
  81. <span>{{ item.label }}</span>
  82. </div>
  83. </el-option>
  84. </el-select> -->
  85. <el-dropdown
  86. trigger="click"
  87. >
  88. <!-- 下拉触发区域(只显示图标) -->
  89. <span class="dropdown-trigger">
  90. <el-icon :size="12" style="width:78px;top:-4px"><arrow-down /></el-icon> <!-- 自定义图标 -->
  91. </span>
  92. <!-- 下拉菜单选项 -->
  93. <template #dropdown>
  94. <el-dropdown-menu>
  95. <el-dropdown-item
  96. v-for="item in optiongroup"
  97. :key="item.value"
  98. :command="item.value"
  99. >
  100. <div style="display: flex; align-items: center;">
  101. <img
  102. :src="getflowImgPath(item.img)"
  103. style="width: 20px; height: 20px; margin-right: 10px;"
  104. />
  105. <span>{{ item.label }}</span>
  106. </div>
  107. </el-dropdown-item>
  108. </el-dropdown-menu>
  109. </template>
  110. </el-dropdown>
  111. </div>
  112. <div class="item2 margr" @click="clickgeometry($event, index, 'Role-' + '2', undmodel)">
  113. <el-image :src="getImgPath('tow3.png')" fit="cover" />
  114. <span>{{ undmodel }}</span>
  115. <!-- <el-select v-model="undmodel" class="no-border headersele" :suffix-icon="CaretBottom">
  116. <el-option v-for="item in options4" :key="item.value" :label="item.label" :value="item.value">
  117. <div style="display: flex; align-items: center;">
  118. <img :src="item.icon" style="width: 20px; height: 20px; margin-right: 10px;" />
  119. <span>{{ item.label }}</span>
  120. </div>
  121. </el-option>
  122. </el-select> -->
  123. <el-dropdown
  124. trigger="click"
  125. >
  126. <!-- 下拉触发区域(只显示图标) -->
  127. <span class="dropdown-trigger">
  128. <el-icon :size="12" style="width:78px;top:-4px"><arrow-down /></el-icon> <!-- 自定义图标 -->
  129. </span>
  130. <!-- 下拉菜单选项 -->
  131. <template #dropdown>
  132. <el-dropdown-menu>
  133. <el-dropdown-item
  134. v-for="item in options4"
  135. :key="item.value"
  136. :command="item.value"
  137. >
  138. <div style="display: flex; align-items: center;">
  139. <img
  140. :src="item.icon"
  141. style="width: 20px; height: 20px; margin-right: 10px;"
  142. />
  143. <span>{{ item.label }}</span>
  144. </div>
  145. </el-dropdown-item>
  146. </el-dropdown-menu>
  147. </template>
  148. </el-dropdown>
  149. </div>
  150. </div>
  151. <!-- -->
  152. <div class="listitem lbg_color3 bkcolor3 ">
  153. <div class="threelist">
  154. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist1" :key="'Role1' + index"
  155. :class="{ activeOrange: active == 'Role1' + index }"
  156. @click="clickgeometry($event, index, 'Role1' + index, item.titlie)">
  157. <el-image :src="getImgPath(item.url)" fit="cover" />
  158. <span>{{ item.titlie }}</span>
  159. </div>
  160. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist11" :key="'Role11' + index"
  161. :class="{ activeOrange: active == 'Role11' + index }"
  162. @click="clickgeometry($event, index, 'Role11' + index, item.titlie)">
  163. <el-image :src="getImgPath(item.url)" fit="cover" />
  164. <el-color-picker v-model="color1" @change="colorpicker()"
  165. :class="{ 'is-show-panel': showTrigger }" />
  166. <span>{{ item.titlie }}</span>
  167. </div>
  168. </div>
  169. </div>
  170. <!-- -->
  171. <div class="listitem lbg_color3 bkcolor3 ">
  172. <div class="threelist">
  173. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist2" :key="'Role2' + index"
  174. :class="{ activeOrange: active == 'Role2' + index }"
  175. @click="clickgeometry($event, index, 'Role2' + index, item.titlie)">
  176. <el-image :src="getImgPath(item.url)" fit="cover" />
  177. <span>{{ item.titlie }}</span>
  178. </div>
  179. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist22" :key="'Role22' + index"
  180. :class="{ activeOrange: active == 'Role22' + index }"
  181. @click="clickgeometry($event, index, 'Role22' + index, item.titlie)">
  182. <el-image :src="getImgPath(item.url)" fit="cover" />
  183. <el-color-picker v-model="colortier" color-format="rgba" show-alpha @change="colorpickertier()"
  184. :class="{ 'is-show-panel': showTrigger }" />
  185. <span>{{ item.titlie }}</span>
  186. </div>
  187. </div>
  188. </div>
  189. <!-- -->
  190. <div class="listitem lbg_color3 bkcolor3 ">
  191. <div class="threelist">
  192. <div class="item2 floatitem wentsd" v-for="(item, index) in Rolelist3" :key="'Role3' + index"
  193. :class="{ activeOrange: active == 'Role3' + index }"
  194. @click="clickgeometry($event, index, 'Role3' + index, item.titlie)">
  195. <el-image :src="getImgPath(item.url)" fit="cover" />
  196. <span>{{ item.titlie }}</span>
  197. </div>
  198. </div>
  199. </div>
  200. </div>
  201. </el-tab-pane>
  202. <el-tab-pane label="优化运行" name="Three">
  203. <div class="imgzong">
  204. <div class="listitem lbg_color3 bkcolor3 threelist">
  205. <div class="item2 floatitem" v-for="(item, index) in Threelist" :key="'Three-' + index"
  206. :class="{ activeOrange: active == 'Three-' + index }"
  207. @click="clickgeometry($event, index, 'Three-' + index, item.titlie)">
  208. <el-image :src="getImgPath(item.url)" fit="cover" />
  209. <span>{{ item.titlie }}</span>
  210. </div>
  211. </div>
  212. <!-- <div class="listitem lbg_color3 bkcolor3" v-for="(item, index) in Threelist1" :key="'Three1-' + index"
  213. :class="{ activeOrange: active == 'Three1' + index }"
  214. @click="clickgeometry($event, index, 'Three1' + index,item.titlie )">
  215. <div class="item2 ">
  216. <el-image :src="getImgPath(item.url)" fit="cover" />
  217. <span>{{ item.titlie }}</span>
  218. </div>
  219. </div> -->
  220. <div class="listitem lbg_color3 bkcolor3 ">
  221. <div class="threelist">
  222. <div class="item2 floatitem wentsd1" v-for="(item, index) in Threelist1" :key="'Three1' + index"
  223. :class="{ activeOrange: active == 'Three1' + index }"
  224. @click="clickgeometry($event, index, 'Three1' + index, item.titlie)">
  225. <el-image :src="getImgPath(item.url)" fit="cover" />
  226. <span>{{ item.titlie }}</span>
  227. </div>
  228. </div>
  229. </div>
  230. </div>
  231. </el-tab-pane>
  232. <el-tab-pane label="可视化" name="Config">
  233. <div class="imgzong">
  234. <!-- <button @click="etImgPath()"></button> -->
  235. <div class="listitem lbg_color3 bkcolor3 threelist" v-for="(item, index) in question" :key="'Config-' + index"
  236. :class="{ activeOrange: active == 'Config-' + index }"
  237. @click="clickgeometry($event, index, 'Config-' + index, item.titlie)">
  238. <div class="item2 ">
  239. <el-image :src="getImgPath(item.url)" fit="cover" />
  240. <span>{{ item.titlie }}</span>
  241. </div>
  242. </div>
  243. </div>
  244. </el-tab-pane>
  245. <el-tab-pane label="数据库管理" name="Seven">
  246. <div class="imgzong">
  247. <div class="listitem lbg_color3 bkcolor3 threelist" v-for="(item, index) in Sevenlist" :key="'Seven' + index"
  248. :class="{ activeOrange: active == 'Seven' + index }"
  249. @click="clickgeometry($event, index, 'Seven' + index, item.titlie)">
  250. <div class="item2 ">
  251. <el-image :src="getImgPath(item.url)" fit="cover" />
  252. <span>{{ item.titlie }}</span>
  253. </div>
  254. </div>
  255. </div>
  256. </el-tab-pane>
  257. <el-tab-pane label="帮助" name="eight">
  258. <div class="imgzong">
  259. <div class="listitem lbg_color3 bkcolor3 threelist" v-for="(item, index) in eightlist" :key="'eight' + index"
  260. :class="{ activeOrange: active == 'eight' + index }"
  261. @click="clickgeometry($event, index, 'eight' + index, item.titlie)">
  262. <div class="item2 ">
  263. <el-image :src="getImgPath(item.url)" fit="cover" />
  264. <span>{{ item.titlie }}</span>
  265. </div>
  266. </div>
  267. </div>
  268. </el-tab-pane>
  269. </el-tabs>
  270. </div>
  271. <!-- 新建任务 -->
  272. <el-dialog v-model="dialog.newdialog" v-if="tabactive == '新建任务'" align-center :modal="false"
  273. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  274. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  275. class="dialog_class bgcolor tianjia">
  276. <template #header="{ titleId, titleClass }">
  277. <div class="my-header ">
  278. <el-image :src="getImgPath('s0.png')" fit="contain"></el-image>
  279. <h4 :id="titleId" :class="titleClass">新建任务</h4>
  280. </div>
  281. </template>
  282. <div>
  283. <el-form>
  284. <el-form-item label="任务编号:" :label-width="formLabelWidth6">
  285. <el-input v-model="name" maxlength="18"
  286. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  287. placeholder="请输入" />
  288. </el-form-item>
  289. <el-form-item label="任务名称:" :label-width="formLabelWidth6">
  290. <el-input v-model="name" maxlength="18"
  291. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  292. placeholder="请输入" />
  293. </el-form-item>
  294. <el-form-item label="任务类型:" :label-width="formLabelWidth6">
  295. <el-input v-model="name" maxlength="18"
  296. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  297. placeholder="请输入" />
  298. </el-form-item>
  299. <el-form-item label="备注:" :label-width="formLabelWidth6">
  300. <el-input v-model="name" maxlength="18" type="textarea"
  301. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  302. placeholder="请输入" />
  303. </el-form-item>
  304. </el-form>
  305. </div>
  306. <template #footer>
  307. <div class="dialog-footer">
  308. <el-button @click="dialog.newdialog = false">取消</el-button>
  309. <el-button type="primary" @click="dialog.newdialog = false">
  310. 确定
  311. </el-button>
  312. </div>
  313. </template>
  314. </el-dialog>
  315. <!-- 问题设定 -->
  316. <el-dialog v-model="dialog.setdialog" v-if="tabactive == '问题设定'" align-center :modal="false"
  317. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  318. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  319. class="dialog_class bgcolor tianjia">
  320. <template #header="{ titleId, titleClass }">
  321. <div class="my-header ">
  322. <el-image :src="getImgPath('q0.png')" fit="contain"></el-image>
  323. <h4 :id="titleId" :class="titleClass">问题设定</h4>
  324. </div>
  325. </template>
  326. <div class="numberinput">
  327. <el-form>
  328. <el-form-item label="目标函数个数:" :label-width="formLabelWidth1">
  329. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  330. </el-form-item>
  331. <el-form-item label="建立代理模型约束个数:" :label-width="formLabelWidth1">
  332. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  333. </el-form-item>
  334. <el-form-item label="不建立代理模型约束个数:" :label-width="formLabelWidth1">
  335. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  336. </el-form-item>
  337. </el-form>
  338. </div>
  339. <template #footer>
  340. <div class="dialog-footer">
  341. <el-button @click="dialog.setdialog = false">取消</el-button>
  342. <el-button type="primary" @click="dialog.setdialog = false">
  343. 确定
  344. </el-button>
  345. </div>
  346. </template>
  347. </el-dialog>
  348. <!-- 外形参数化 -->
  349. <el-dialog v-model="dialog.parameter" v-if="tabactive == 'Task-11'" align-center :modal="false"
  350. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  351. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  352. class="dialog_class bgcolor tianjia sel">
  353. <template #header="{ titleId, titleClass }">
  354. <div class="my-header ">
  355. <el-image :src="getImgPath('t0.png')" fit="contain"></el-image>
  356. <h4 :id="titleId" :class="titleClass">外形参数化</h4>
  357. </div>
  358. </template>
  359. <div class="numberinput">
  360. <el-form>
  361. <el-form-item label="参数化方法:" :label-width="formLabelWidth6">
  362. <el-select v-model="canshu" :suffix-icon="CaretBottom" placeholder="请选择">
  363. <el-option v-for="item in canshulist" :key="item.value" :label="item.label" :value="item.value">
  364. </el-option>
  365. </el-select>
  366. </el-form-item>
  367. </el-form>
  368. </div>
  369. <template #footer>
  370. <div class="dialog-footer">
  371. <el-button @click="dialog.parameter = false">取消</el-button>
  372. <el-button type="primary" @click="dialog.parameter = false">
  373. 确定
  374. </el-button>
  375. </div>
  376. </template>
  377. </el-dialog>
  378. <!-- 代理模型 -->
  379. <el-dialog v-model="dialog.agency" v-if="tabactive == '代理模型'" align-center :modal="false"
  380. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  381. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  382. class="dialog_class bgcolor tianjia sel">
  383. <template #header="{ titleId, titleClass }">
  384. <div class="my-header ">
  385. <el-image :src="getImgPath('t2.png')" fit="contain"></el-image>
  386. <h4 :id="titleId" :class="titleClass">代理模型</h4>
  387. </div>
  388. </template>
  389. <div class="numberinput">
  390. <el-form>
  391. <el-form-item label="代理模型类型:" :label-width="formLabelWidth2">
  392. <el-select v-model="agval" :suffix-icon="CaretBottom" placeholder="请选择">
  393. <el-option v-for="item in agelist" :key="item.value" :label="item.label" :value="item.value">
  394. </el-option>
  395. </el-select>
  396. </el-form-item>
  397. <el-form-item label="设计空间类型:" :label-width="formLabelWidth2">
  398. <el-select v-model="agval1" :suffix-icon="CaretBottom" placeholder="请选择">
  399. <el-option v-for="item in agelist1" :key="item.value" :label="item.label" :value="item.value">
  400. </el-option>
  401. </el-select>
  402. </el-form-item>
  403. <el-form-item label="试验设计方法:" :label-width="formLabelWidth2">
  404. <el-select v-model="agval2" :suffix-icon="CaretBottom" placeholder="请选择">
  405. <el-option v-for="item in agelist2" :key="item.value" :label="item.label" :value="item.value">
  406. </el-option>
  407. </el-select>
  408. </el-form-item>
  409. <el-form-item label="初始样本点数:" :label-width="formLabelWidth2">
  410. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  411. </el-form-item>
  412. </el-form>
  413. </div>
  414. <template #footer>
  415. <div class="dialog-footer">
  416. <el-button @click="dialog.agency = false">取消</el-button>
  417. <el-button type="primary" @click="dialog.agency = false">
  418. 确定
  419. </el-button>
  420. </div>
  421. </template>
  422. </el-dialog>
  423. <!-- 终止条件 -->
  424. <el-dialog v-model="dialog.enddialog" v-if="tabactive == '终止条件 '" align-center :modal="false"
  425. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  426. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  427. class="dialog_class bgcolor tianjia sel">
  428. <template #header="{ titleId, titleClass }">
  429. <div class="my-header ">
  430. <el-image :src="getImgPath('t4.png')" fit="contain"></el-image>
  431. <h4 :id="titleId" :class="titleClass">终止条件</h4>
  432. </div>
  433. </template>
  434. <div class="numberinput">
  435. <el-form>
  436. <el-form-item label="EI最小值:" :label-width="formLabelWidth1">
  437. <el-input v-model="name" maxlength="18"
  438. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  439. placeholder="请输入" />
  440. </el-form-item>
  441. <el-form-item label="目标函数收敛误差:" :label-width="formLabelWidth1">
  442. <el-input v-model="name" maxlength="18"
  443. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  444. placeholder="请输入" />
  445. </el-form-item>
  446. <el-form-item label="优化解收敛精度:" :label-width="formLabelWidth1">
  447. <el-input v-model="name" maxlength="18"
  448. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  449. placeholder="请输入" />
  450. </el-form-item>
  451. <el-form-item label="真实函数约束精度:" :label-width="formLabelWidth1">
  452. <el-input v-model="name" maxlength="18"
  453. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  454. placeholder="请输入" />
  455. </el-form-item>
  456. <el-form-item label="代理模型约束精度:" :label-width="formLabelWidth1">
  457. <el-input v-model="name" maxlength="18"
  458. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  459. placeholder="请输入" />
  460. </el-form-item>
  461. </el-form>
  462. </div>
  463. <template #footer>
  464. <div class="dialog-footer">
  465. <el-button @click="dialog.enddialog = false">取消</el-button>
  466. <el-button type="primary" @click="dialog.enddialog = false">
  467. 确定
  468. </el-button>
  469. </div>
  470. </template>
  471. </el-dialog>
  472. <!-- 优化算法 -->
  473. <!-- <el-dialog v-model="dialog.sufun" v-if="tabactive == '优化算法'" align-center :modal="false"
  474. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  475. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  476. class="dialog_class sel bgcolor tianjia sel">
  477. <template #header="{ titleId, titleClass }">
  478. <div class="my-header ">
  479. <el-image :src="getImgPath('Framem.png')" fit="contain"></el-image>
  480. <h4 :id="titleId" :class="titleClass">优化算法</h4>
  481. </div>
  482. </template>
  483. <div class="numberinput">
  484. <div>
  485. <el-form-item label="优化算法" :label-width="formLabelWidth1">
  486. <el-select v-model="youhua.algorithm" :suffix-icon="CaretBottom" placeholder="请选择">
  487. <el-option v-for="item in yslist" :key="item.value" :label="item.label" :value="item.value">
  488. </el-option>
  489. </el-select>
  490. </el-form-item>
  491. <el-form-item label="种群规模:" :label-width="formLabelWidth1">
  492. <el-input-number v-model="youhua.popsize" :min="1" :max="10" controls-position="right" />
  493. </el-form-item>
  494. <el-form-item label="进化代数:" :label-width="formLabelWidth1">
  495. <el-input-number v-model="youhua.epoch" :min="1" :max="10" controls-position="right" />
  496. </el-form-item>
  497. <el-form-item label="交叉概率:" :label-width="formLabelWidth1">
  498. <el-input-number v-model="youhua.probcrossover" :min="1" :max="10" controls-position="right" />
  499. </el-form-item>
  500. <el-form-item label="变异概率:" :label-width="formLabelWidth1">
  501. <el-input-number v-model="youhua.probmut" :min="1" :max="10" controls-position="right" />
  502. </el-form-item>
  503. <el-form-item label="交叉算子:" :label-width="formLabelWidth1">
  504. <el-select v-model="youhua.proboperator" :suffix-icon="CaretBottom" placeholder="请选择">
  505. <el-option v-for="item in addlist2" :key="item.value" :label="item.label" :value="item.value">
  506. </el-option>
  507. </el-select>
  508. </el-form-item>
  509. <el-form-item label="竞赛规模:" :label-width="formLabelWidth1">
  510. <el-input-number v-model="youhua.probscale" :min="1" :max="10" controls-position="right" />
  511. </el-form-item>
  512. <el-form-item label="保留优选策略:" :label-width="formLabelWidth1">
  513. <el-select v-model="youhua.strategy" :suffix-icon="CaretBottom" placeholder="请选择">
  514. <el-option v-for="item in addlist3" :key="item.value" :label="item.label" :value="item.value">
  515. </el-option>
  516. </el-select>
  517. </el-form-item>
  518. <el-form-item label="变异算子选择:" :label-width="formLabelWidth1">
  519. <el-select v-model="youhua.operator" :suffix-icon="CaretBottom" placeholder="请选择">
  520. <el-option v-for="item in addlist4" :key="item.value" :label="item.label" :value="item.value">
  521. </el-option>
  522. </el-select>
  523. </el-form-item>
  524. <el-form-item label="GPU" :label-width="formLabelWidth1">
  525. <el-select v-model="youhua.gpu" :suffix-icon="CaretBottom" placeholder="请选择">
  526. <el-option v-for="item in addlist8" :key="item.value" :label="item.label" :value="item.value">
  527. </el-option>
  528. </el-select>
  529. </el-form-item>
  530. </div>
  531. </div>
  532. <template #footer>
  533. <div class="dialog-footer">
  534. <el-button @click="dialog.sufun = false">取消</el-button>
  535. <el-button type="primary" @click="dialog.sufun = false">
  536. 确定
  537. </el-button>
  538. </div>
  539. </template>
  540. </el-dialog> -->
  541. <!-- 加点方法 -->
  542. <el-dialog v-model="dialog.addfun" v-if="tabactive == '加点方法'" align-center :modal="false"
  543. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  544. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="480"
  545. class="dialog_class sel bgcolor tianjia sel">
  546. <template #header="{ titleId, titleClass }">
  547. <div class="my-header ">
  548. <el-image :src="getImgPath('t3.png')" fit="contain"></el-image>
  549. <h4 :id="titleId" :class="titleClass">加点方法</h4>
  550. </div>
  551. </template>
  552. <div class="numberinput">
  553. <el-form>
  554. <el-form-item label="最大样本点数:" :label-width="formLabelWidth1">
  555. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  556. </el-form-item>
  557. <el-form-item label="加点准则:" :label-width="formLabelWidth1">
  558. <el-select v-model="addval" :suffix-icon="CaretBottom" placeholder="请选择">
  559. <el-option v-for="item in addlist" :key="item.value" :label="item.label" :value="item.value">
  560. </el-option>
  561. </el-select>
  562. </el-form-item>
  563. <el-form-item label="单次迭代新增样本点数:" :label-width="formLabelWidth1">
  564. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  565. </el-form-item>
  566. <el-form-item label="约束处理方法:" :label-width="formLabelWidth1">
  567. <el-select v-model="addval1" :suffix-icon="CaretBottom" placeholder="请选择">
  568. <el-option v-for="item in addlist1" :key="item.value" :label="item.label" :value="item.value">
  569. </el-option>
  570. </el-select>
  571. </el-form-item>
  572. </el-form>
  573. </div>
  574. <template #footer>
  575. <div class="dialog-footer">
  576. <el-button @click="dialog.addfun = false">取消</el-button>
  577. <el-button type="primary" @click="dialog.addfun = false">
  578. 确定
  579. </el-button>
  580. </div>
  581. </template>
  582. </el-dialog>
  583. <!-- 任务管理 -->
  584. <el-dialog v-model="dialog.task" v-if="tabactive == '任务管理'" align-center :modal="false"
  585. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  586. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="800px"
  587. class="dialog_class bgcolor tianjia">
  588. <template #header="{ titleId, titleClass }">
  589. <div class="my-header ">
  590. <el-image :src="getImgPath('s11.png')" fit="contain"></el-image>
  591. <h4 :id="titleId" :class="titleClass">任务管理</h4>
  592. </div>
  593. </template>
  594. <div>
  595. <el-table :data="tasktable" stripe style="width: 100%">
  596. <el-table-column prop="id" label="任务编号" />
  597. <el-table-column prop="name" label="任务名称" />
  598. <el-table-column prop="state" label="任务类型" />
  599. <el-table-column prop="time" label="备注" />
  600. </el-table>
  601. <div class="sev_ruwu sev">
  602. <div class="disflex">
  603. <el-form-item label="关键字:">
  604. <el-select v-model="seval4" :suffix-icon="CaretBottom" placeholder="请选择">
  605. <el-option v-for="item in sevlist" :key="item.value" :label="item.label" :value="item.value">
  606. </el-option>
  607. </el-select>
  608. </el-form-item>
  609. <el-input v-model="name" maxlength="18"
  610. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  611. placeholder="请输入" />
  612. <el-button class="btncolor">查询</el-button>
  613. <el-button class="btncolor">添加</el-button>
  614. <el-button class="btncolor">删除</el-button>
  615. <el-button class="btncolor">提交</el-button>
  616. </div>
  617. </div>
  618. </div>
  619. <template #footer>
  620. <div class="dialog-footer">
  621. <el-button @click="dialog.task = false">取消</el-button>
  622. <el-button type="primary" @click="dialog.task = false">
  623. 确定
  624. </el-button>
  625. </div>
  626. </template>
  627. </el-dialog>
  628. <!-- 任务检索 -->
  629. <el-dialog v-model="dialog.guanli" v-if="tabactive == '任务检索'" align-center :modal="false"
  630. :close-on-click-modal="true" :append-to-body="true" draggable :fullscreen="false"
  631. :modal-append-to-body="false" modal-class="summary-dlg" :before-close="handleClose" width="800px"
  632. class="dialog_class bgcolor tianjia">
  633. <template #header="{ titleId, titleClass }">
  634. <div class="my-header ">
  635. <el-image :src="getImgPath('s11.png')" fit="contain"></el-image>
  636. <h4 :id="titleId" :class="titleClass">任务检索</h4>
  637. </div>
  638. </template>
  639. <div>
  640. <div class="sev_ruwu">
  641. <div class="disflex">
  642. <el-form-item label="关键字:">
  643. <el-select v-model="seval4" :suffix-icon="CaretBottom" placeholder="请选择">
  644. <el-option v-for="item in sevlist" :key="item.value" :label="item.label" :value="item.value">
  645. </el-option>
  646. </el-select>
  647. </el-form-item>
  648. <el-input v-model="name" maxlength="18"
  649. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  650. placeholder="请输入关键字" />
  651. <el-checkbox class="magright" label="范围" v-model="checkbox" />
  652. <el-button class="btncolor">查询</el-button>
  653. </div>
  654. </div>
  655. <el-table :data="tasktable" stripe style="width: 100%">
  656. <el-table-column prop="id" label="任务编号" />
  657. <el-table-column prop="name" label="任务名称" />
  658. <el-table-column prop="state" label="任务类型" />
  659. <el-table-column prop="time" label="备注" />
  660. </el-table>
  661. </div>
  662. <template #footer>
  663. <div class="dialog-footer">
  664. <el-button @click="dialog.guanli = false">取消</el-button>
  665. <el-button type="primary" @click="dialog.guanli = false">
  666. 确定
  667. </el-button>
  668. </div>
  669. </template>
  670. </el-dialog>
  671. <!-- 优化器 -->
  672. <el-dialog v-model="dialog.optimizer" align-center :modal="false" :close-on-click-modal="false"
  673. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  674. :before-close="handleClose" width="430" class="dialog_class bgcolor tianjia sel">
  675. <template #header="{ titleId, titleClass }">
  676. <div class="my-header ">
  677. <el-image :src="getImgPath('t2.png')" fit="contain"></el-image>
  678. <h4 :id="titleId" :class="titleClass">优化器</h4>
  679. </div>
  680. </template>
  681. <div class="numberinput lefttext">
  682. <el-form>
  683. <span>代理模型</span>
  684. <el-form-item label="代理模型类型:" :label-width="formLabelWidth1">
  685. <el-select v-model="agval" :suffix-icon="CaretBottom" placeholder="请选择">
  686. <el-option v-for="item in agelist" :key="item.value" :label="item.label" :value="item.value">
  687. </el-option>
  688. </el-select>
  689. </el-form-item>
  690. <el-form-item label="设计空间类型:" :label-width="formLabelWidth1">
  691. <el-select v-model="agval1" :suffix-icon="CaretBottom" placeholder="请选择">
  692. <el-option v-for="item in agelist1" :key="item.value" :label="item.label" :value="item.value">
  693. </el-option>
  694. </el-select>
  695. </el-form-item>
  696. <el-form-item label="试验设计方法:" :label-width="formLabelWidth1">
  697. <el-select v-model="agval2" :suffix-icon="CaretBottom" placeholder="请选择">
  698. <el-option v-for="item in agelist2" :key="item.value" :label="item.label" :value="item.value">
  699. </el-option>
  700. </el-select>
  701. </el-form-item>
  702. <el-form-item label="初始样本点数:" :label-width="formLabelWidth1">
  703. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  704. </el-form-item>
  705. <span>加点准则</span>
  706. <el-form-item label="最大样本点数:" :label-width="formLabelWidth1">
  707. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  708. </el-form-item>
  709. <el-form-item label="加点准则:" :label-width="formLabelWidth1">
  710. <el-select v-model="addval" :suffix-icon="CaretBottom" placeholder="请选择">
  711. <el-option v-for="item in addlist" :key="item.value" :label="item.label" :value="item.value">
  712. </el-option>
  713. </el-select>
  714. </el-form-item>
  715. <el-form-item label="单次迭代新增样本点数:" :label-width="formLabelWidth1">
  716. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  717. </el-form-item>
  718. <el-form-item label="约束处理方法:" :label-width="formLabelWidth1">
  719. <el-select v-model="addval1" :suffix-icon="CaretBottom" placeholder="请选择">
  720. <el-option v-for="item in addlist1" :key="item.value" :label="item.label" :value="item.value">
  721. </el-option>
  722. </el-select>
  723. </el-form-item>
  724. <span>优化算法</span>
  725. <el-form-item label="优化算法:" :label-width="formLabelWidth1">
  726. <el-select v-model="ys" :suffix-icon="CaretBottom" placeholder="请选择">
  727. <el-option v-for="item in yslist" :key="item.value" :label="item.label" :value="item.value">
  728. </el-option>
  729. </el-select>
  730. </el-form-item>
  731. <el-form-item label="种群规模:" :label-width="formLabelWidth1">
  732. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  733. </el-form-item>
  734. <el-form-item label="最大迭代次数:" :label-width="formLabelWidth1">
  735. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  736. </el-form-item>
  737. <el-form-item label="交叉概率:" :label-width="formLabelWidth1">
  738. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  739. </el-form-item>
  740. <el-form-item label="变异概率:" :label-width="formLabelWidth1">
  741. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  742. </el-form-item>
  743. <el-form-item label="交叉算子:" :label-width="formLabelWidth1">
  744. <el-select v-model="addval2" :suffix-icon="CaretBottom" placeholder="请选择">
  745. <el-option v-for="item in addlist2" :key="item.value" :label="item.label" :value="item.value">
  746. </el-option>
  747. </el-select>
  748. </el-form-item>
  749. <el-form-item label="竞赛规模:" :label-width="formLabelWidth1">
  750. <el-input-number v-model="num" :min="1" :max="10" controls-position="right" />
  751. </el-form-item>
  752. <el-form-item label="保留优选策略:" :label-width="formLabelWidth1">
  753. <el-select v-model="addval3" :suffix-icon="CaretBottom" placeholder="请选择">
  754. <el-option v-for="item in addlist3" :key="item.value" :label="item.label" :value="item.value">
  755. </el-option>
  756. </el-select>
  757. </el-form-item>
  758. <el-form-item label="变异算子选择:" :label-width="formLabelWidth1">
  759. <el-select v-model="addval4" :suffix-icon="CaretBottom" placeholder="请选择">
  760. <el-option v-for="item in addlist4" :key="item.value" :label="item.label" :value="item.value">
  761. </el-option>
  762. </el-select>
  763. </el-form-item>
  764. <el-form-item label="precision:" :label-width="formLabelWidth1">
  765. <el-select v-model="addval7" :suffix-icon="CaretBottom" placeholder="请选择">
  766. <el-option v-for="item in addlist7" :key="item.value" :label="item.label" :value="item.value">
  767. </el-option>
  768. </el-select>
  769. </el-form-item>
  770. <el-form-item label="GPU" :label-width="formLabelWidth1">
  771. <el-select v-model="addval8" :suffix-icon="CaretBottom" placeholder="请选择">
  772. <el-option v-for="item in addlist8" :key="item.value" :label="item.label" :value="item.value">
  773. </el-option>
  774. </el-select>
  775. </el-form-item>
  776. </el-form>
  777. </div>
  778. <template #footer>
  779. <div class="dialog-footer">
  780. <el-button @click="dialog.optimizer = false">取消</el-button>
  781. <el-button type="primary" @click="dialog.optimizer = false">
  782. 确定
  783. </el-button>
  784. </div>
  785. </template>
  786. </el-dialog>
  787. <!-- Xfiol改版后的 -->
  788. <el-dialog v-model="dialog.Xfiol" align-center :modal="false" :close-on-click-modal="false"
  789. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false"
  790. modal-class="summary-dlg2 summary-dlg" :before-close="handleClose" width="540"
  791. class="dialog_class bgcolor tianjia colortext sel">
  792. <template #header="{ titleId, titleClass }">
  793. <div class="my-header ">
  794. <el-image :src="getImgPath('xuek9.png')" fit="contain"></el-image>
  795. <h4 :id="titleId" :class="titleClass">Xfoil</h4>
  796. </div>
  797. </template>
  798. <Xfoil ref="Xfoilref"/>
  799. <template #footer>
  800. <div class="dialog-footer">
  801. <!-- <el-button type="info" @click="newxfoil">新建 </el-button> -->
  802. <el-button type="info" @click="dialog.Xfiol = false">取消</el-button>
  803. <el-button type="primary" @click="xfoilok();dialog.Xfiol = false">
  804. 确定
  805. </el-button>
  806. </div>
  807. </template>
  808. </el-dialog>
  809. <!-- 列表 -->
  810. <el-dialog v-model="dialog.listdialog" align-center :modal="false" :close-on-click-modal="false"
  811. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  812. :before-close="handleClose" width="537" class="dialog_style sel" style="max-height: 70%;">
  813. <template #header="{ titleId, titleClass }">
  814. <div class="my-header ">
  815. <h4 :id="titleId" :class="titleClass">列表</h4>
  816. </div>
  817. </template>
  818. <div>
  819. <ListSE :isList="true" @update="handleUpdate"/>
  820. <!-- <el-form>
  821. <el-form-item label="设计集:" >
  822. <el-select v-model="listval" :suffix-icon="CaretBottom" placeholder="请选择">
  823. <el-option v-for="item in listoptions" :key="item.value" :label="item.label" :value="item.value">
  824. </el-option>
  825. </el-select>
  826. </el-form-item>
  827. <el-form-item label="选择要在表中显示的一个或者多个变量和响应" >
  828. </el-form-item>
  829. <el-card shadow="hover" style="width: 100%">
  830. <el-checkbox-group v-model="listcbval">
  831. <el-checkbox v-for="item in Listcheckbox" :key="item.value" :label="item.value" style="display: block">{{ item.label }}</el-checkbox>
  832. </el-checkbox-group>
  833. </el-card>
  834. </el-form> -->
  835. </div>
  836. <template #footer>
  837. <div class="dialog-footer">
  838. <el-button @click="dialog.listdialog = false">取消</el-button>
  839. <el-button type="primary" @click="selectshujuto();dialog.listdialog = false">
  840. 确定
  841. </el-button>
  842. </div>
  843. </template>
  844. </el-dialog>
  845. <!-- 散点图 -->
  846. <el-dialog v-model="dialog.scatterdialog" align-center :modal="false" :close-on-click-modal="false"
  847. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  848. :before-close="handleClose" width="500" class="dialog_style bgcolor tianjia sel" style="max-height: 70%;">
  849. <template #header="{ titleId, titleClass }">
  850. <div class="my-header ">
  851. <h4 :id="titleId" :class="titleClass">散点图</h4>
  852. </div>
  853. </template>
  854. <div>
  855. <ListSE :isList="false" @update="handleUpdate"/>
  856. </div>
  857. <template #footer>
  858. <div class="dialog-footer">
  859. <el-button @click="dialog.scatterdialog = false">取消</el-button>
  860. <el-button type="primary" @click="selectshujuto();dialog.scatterdialog = false">
  861. 确定
  862. </el-button>
  863. </div>
  864. </template>
  865. </el-dialog>
  866. <!-- 折线图 -->
  867. <el-dialog v-model="dialog.echartLinedialog" align-center :modal="false" :close-on-click-modal="false"
  868. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  869. :before-close="handleClose" width="500" class="dialog_style bgcolor tianjia sel" style="max-height: 70%;">
  870. <template #header="{ titleId, titleClass }">
  871. <div class="my-header ">
  872. <h4 :id="titleId" :class="titleClass">折线图</h4>
  873. </div>
  874. </template>
  875. <div>
  876. <ListSE :isList="false" @update="handleUpdate"/>
  877. </div>
  878. <template #footer>
  879. <div class="dialog-footer">
  880. <el-button @click="dialog.echartLinedialog = false">取消</el-button>
  881. <el-button type="primary" @click="selectshujuto();dialog.echartLinedialog = false">
  882. 确定
  883. </el-button>
  884. </div>
  885. </template>
  886. </el-dialog>
  887. <!-- 帕雷托图 -->
  888. <el-dialog v-model="dialog.paretodialog" align-center :modal="false" :close-on-click-modal="false"
  889. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  890. :before-close="handleClose" width="500" class="dialog_style bgcolor tianjia sel" style="max-height: 70%;">
  891. <template #header="{ titleId, titleClass }">
  892. <div class="my-header ">
  893. <h4 :id="titleId" :class="titleClass">帕雷托图</h4>
  894. </div>
  895. </template>
  896. <div>
  897. <el-form>
  898. <el-form-item label="选择在X轴显示的一个变量和响应" >
  899. </el-form-item>
  900. <el-card>
  901. <el-checkbox-group v-model="paretocbval">
  902. <el-checkbox v-for="item in paretocheckbox" :key="item.value" :label="item.value" style="display: block">{{ item.label }}</el-checkbox>
  903. </el-checkbox-group>
  904. </el-card>
  905. <el-form-item label="选择在Y轴显示的一个变量和响应" >
  906. </el-form-item>
  907. <el-card shadow="hover" style="width: 100%">
  908. <el-checkbox-group v-model="paretocbval">
  909. <el-checkbox v-for="item in paretocheckbox" :key="item.value" :label="item.value" style="display: block">{{ item.label }}</el-checkbox>
  910. </el-checkbox-group>
  911. </el-card>
  912. </el-form>
  913. </div>
  914. <template #footer>
  915. <div class="dialog-footer">
  916. <el-button @click="dialog.paretodialog = false">取消</el-button>
  917. <el-button type="primary" @click="dialog.paretodialog = false">
  918. 确定
  919. </el-button>
  920. </div>
  921. </template>
  922. </el-dialog>
  923. <!-- 云图/等值线图 -->
  924. <cloundCharts
  925. v-model="dialog.clouddialog"
  926. />
  927. <el-dialog v-model="dialog.paretodialog" align-center :modal="false" :close-on-click-modal="false"
  928. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  929. :before-close="handleClose" width="700" class="dialog_style bgcolor tianjia sel cloudChart" style="height: 500px;overflow: auto;">
  930. <template #header>
  931. <div class="my-header ">
  932. <h4 :id="titleId" :class="titleClass">云图/等值线显示</h4>
  933. </div>
  934. </template>
  935. <div>
  936. <div class="cloudbox">
  937. <el-row gutter="20">
  938. <el-col :span="2"></el-col>
  939. <el-col v-for="(item,index) in cloudbtnbox" :key="index" :span="4">
  940. <el-button style="width: 100%;" @click="openSeconddialog(item.btnname)">
  941. <el-image :src="getImgPath(item.url)" alt="img" fit="cover" style="width: 20px;margin-right: 4px;" />
  942. {{ item.btnname }}
  943. </el-button>
  944. </el-col>
  945. </el-row>
  946. </div>
  947. <div style="height: 400px;overflow: auto;">
  948. <cloudChart/>
  949. </div>
  950. </div>
  951. </el-dialog>
  952. <!-- 云图二级弹窗 -->
  953. <el-dialog v-model="seconddialogshow"
  954. align-center
  955. :modal="false"
  956. :close-on-click-modal="false"
  957. :append-to-body="true"
  958. draggable
  959. :fullscreen="false"
  960. :modal-append-to-body="false"
  961. modal-class="summary-dlg"
  962. :before-close="handleClose"
  963. width="500"
  964. class="dialog_class bgcolor tianjia "
  965. >
  966. <template #header="{ titleId, titleClass }">
  967. <div class="my-header">
  968. <h4 :id="titleId" :class="titleClass">{{ cloudsedtitle }}</h4>
  969. </div>
  970. </template>
  971. <cloudsecond :activesd="activesd"/>
  972. <template #footer>
  973. <div class="dialog-footer">
  974. <el-button @click="seconddialogshow = false">取消</el-button>
  975. <el-button type="primary" @click="seconddialogshow = false">
  976. 确定
  977. </el-button>
  978. </div>
  979. </template>
  980. </el-dialog>
  981. <!-- 查看报告 -->
  982. <el-dialog v-model="dialog.lookover" align-center :modal="false" :close-on-click-modal="false"
  983. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlgPdf"
  984. :before-close="handleClose" width="580px" height="800px">
  985. <template #header="{ titleId, titleClass }">
  986. <div class="my-header ">
  987. <el-image :src="getImgPath('k8.png')" fit="contain"></el-image>
  988. <h4 :id="titleId" :class="titleClass">查看报告:</h4>
  989. </div>
  990. </template>
  991. <pdfReportView/>
  992. <!-- <div class="numberinput lefttext">
  993. <el-form>
  994. <el-image :src="getImgPath('baog.png')" fit="contain"></el-image>
  995. </el-form>
  996. </div> -->
  997. <template #footer>
  998. <div class="dialog-footer">
  999. <el-button @click="dialog.lookover = false">取消</el-button>
  1000. <el-button type="primary" @click="dialog.lookover = false">
  1001. 确定
  1002. </el-button>
  1003. </div>
  1004. </template>
  1005. </el-dialog>
  1006. <!-- 导出报告 -->
  1007. <el-dialog v-model="dialog.exportreport" align-center :modal="false" :close-on-click-modal="false"
  1008. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1009. :before-close="handleClose" width="600" class="dialog_class bgcolor tianjia sel" style="max-height: 70%;">
  1010. <template #header="{ titleId, titleClass }">
  1011. <div class="my-header ">
  1012. <h4 :id="titleId" :class="titleClass">导出报告:</h4>
  1013. </div>
  1014. </template>
  1015. <Exreport />
  1016. <template #footer>
  1017. <div class="dialog-footer">
  1018. <el-button @click="dialog.exportreport = false">取消</el-button>
  1019. <el-button type="primary" @click="dialog.exportreport = false">
  1020. 确定
  1021. </el-button>
  1022. </div>
  1023. </template>
  1024. </el-dialog>
  1025. <!-- 气动分析Xfoil、ADflow -->
  1026. <el-dialog v-model="dialog.XfAD" align-center :modal="false" :close-on-click-modal="false"
  1027. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1028. :before-close="handleClose" width="700" class="dialog_class bgcolor tianjia sel colortext">
  1029. <template #header="{ titleId, titleClass }">
  1030. <div class="my-header ">
  1031. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1032. <h4 :id="titleId" :class="titleClass">气动分析</h4>
  1033. </div>
  1034. </template>
  1035. <div class="numberinput lefttext ">
  1036. <el-form>
  1037. <el-tabs tab-position="left" class="demo-tabs" v-model="activeadf" @tab-click="adfhandleClick3">
  1038. <el-tab-pane label="Xfoil" name="Xfoil">
  1039. <Xfoil ref="Xfoilref"/>
  1040. </el-tab-pane>
  1041. <!-- ADflow -->
  1042. <el-tab-pane label="ADflow" name="ADflow">
  1043. <ADflow ref="ADflowref"/>
  1044. </el-tab-pane>
  1045. </el-tabs>
  1046. </el-form>
  1047. </div>
  1048. <template #footer>
  1049. <div class="dialog-footer">
  1050. <el-button @click="dialog.XfAD = false">取消</el-button>
  1051. <el-button type="primary" @click="getXfoilAdflowsave(activeadf);dialog.XfAD = false;">
  1052. 确定
  1053. </el-button>
  1054. </div>
  1055. </template>
  1056. </el-dialog>
  1057. <!-- CST -->
  1058. <el-dialog v-model="dialog.CSTt" align-center :modal="false" :close-on-click-modal="false"
  1059. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1060. :before-close="handleClose" width="730" class="dialog_class bgcolor colortext tianjia sel">
  1061. <template #header="{ titleId, titleClass }">
  1062. <div class="my-header ">
  1063. <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image>
  1064. <h4 :id="titleId" :class="titleClass">CST</h4>
  1065. </div>
  1066. </template>
  1067. <csts ref="Cstref"/>
  1068. <template #footer>
  1069. <div class="dialog-footer">
  1070. <el-button @click="dialog.CSTt = false">取消</el-button>
  1071. <el-button type="primary" @click="cstok()">
  1072. 确定
  1073. </el-button>
  1074. </div>
  1075. </template>
  1076. </el-dialog>
  1077. <!-- FFD -->
  1078. <el-dialog v-model="dialog.ffdt" align-center :modal="false" :close-on-click-modal="false"
  1079. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1080. :before-close="handleClose" width="730" class="dialog_class bgcolor colortext tianjia sel">
  1081. <template #header="{ titleId, titleClass }">
  1082. <div class="my-header ">
  1083. <el-image :src="getImgPath('ffd.png')" fit="contain"></el-image>
  1084. <h4 :id="titleId" :class="titleClass">FFD</h4>
  1085. </div>
  1086. </template>
  1087. <ffds ref="Ffdref"/>
  1088. <template #footer>
  1089. <div class="dialog-footer">
  1090. <el-button @click="dialog.ffdt = false">取消</el-button>
  1091. <el-button type="primary" @click="ffdok()">
  1092. 确定
  1093. </el-button>
  1094. </div>
  1095. </template>
  1096. </el-dialog>
  1097. <!-- 气动分析CST、FFD -->
  1098. <el-dialog v-model="dialog.cstffd" align-center :modal="false" :close-on-click-modal="false"
  1099. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1100. :before-close="handleClose" width="900" class="dialog_class bgcolor tianjia sel colortext">
  1101. <template #header="{ titleId, titleClass }">
  1102. <div class="my-header ">
  1103. <h4 :id="titleId" :class="titleClass">参数化</h4>
  1104. </div>
  1105. </template>
  1106. <div class="numberinput lefttext ">
  1107. <el-form>
  1108. <!-- CST -->
  1109. <el-tabs tab-position="left" class="demo-tabs" v-model="activeadf" @tab-click="adfhandleClick2">
  1110. <el-tab-pane label="CST" name="CST">
  1111. <csts ref="Cstref"/>
  1112. </el-tab-pane>
  1113. <!-- FFD -->
  1114. <el-tab-pane label="FFD" name="FFD">
  1115. <ffds ref="Ffdref"/>
  1116. </el-tab-pane>
  1117. </el-tabs>
  1118. </el-form>
  1119. </div>
  1120. <template #footer>
  1121. <div class="dialog-footer">
  1122. <el-button @click="dialog.cstffd = false">取消</el-button>
  1123. <el-button type="primary" @click="getCstFfdsave(activeadf);dialog.cstffd = false">
  1124. 确定
  1125. </el-button>
  1126. </div>
  1127. </template>
  1128. </el-dialog>
  1129. <!-- TACS -->
  1130. <el-dialog v-model="dialog.Taxs" align-center :modal="false" :close-on-click-modal="false"
  1131. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1132. :before-close="handleClose" width="700" class="dialog_class bgcolor tianjia sel colortext ">
  1133. <template #header="{ titleId, titleClass }">
  1134. <div class="my-header ">
  1135. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1136. <h4 :id="titleId" :class="titleClass">TACS</h4>
  1137. </div>
  1138. </template>
  1139. <TACS ref="Tacsref" />
  1140. <template #footer>
  1141. <div class="dialog-footer">
  1142. <el-button @click="dialog.Taxs = false">取消</el-button>
  1143. <el-button type="primary" @click="gettacstosave();dialog.Taxs = false">
  1144. 确定
  1145. </el-button>
  1146. </div>
  1147. </template>
  1148. </el-dialog>
  1149. <!-- 优化器 -->
  1150. <el-dialog v-model="dialog.optgroup" align-center :modal="false" :close-on-click-modal="false"
  1151. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1152. :before-close="handleClose" width="700" class="dialog_class bgcolor tianjia sel colortext">
  1153. <template #header="{ titleId, titleClass }">
  1154. <div class="my-header ">
  1155. <h4 :id="titleId" :class="titleClass">优化器</h4>
  1156. </div>
  1157. </template>
  1158. <div class="numberinput lefttext ">
  1159. <el-form>
  1160. <el-tabs tab-position="left" class="demo-tabs" v-model="activeadf" @tab-click="adfhandleClick">
  1161. <!-- 代理优化器 -->
  1162. <el-tab-pane label="代理优化器" name="代理优化器">
  1163. <Doptimize ref='Doptimizeref'/>
  1164. </el-tab-pane>
  1165. <!-- 进步优化器 -->
  1166. <el-tab-pane label="进化优化器" name="进化优化器">
  1167. <Joptimize ref='Joptimizeref'/>
  1168. </el-tab-pane>
  1169. <!-- 梯度优化器 -->
  1170. <el-tab-pane label="梯度优化器" name="梯度优化器">
  1171. <Toptimize ref='Toptimizeref'/>
  1172. </el-tab-pane>
  1173. </el-tabs>
  1174. </el-form>
  1175. </div>
  1176. <template #footer>
  1177. <div class="dialog-footer">
  1178. <el-button @click="dialog.optgroup = false">取消</el-button>
  1179. <el-button type="primary" @click="getSave(activeadf);dialog.optgroup = false">
  1180. 确定
  1181. </el-button>
  1182. </div>
  1183. </template>
  1184. </el-dialog>
  1185. <!-- 单独的进步优化器 -->
  1186. <el-dialog v-model="dialog.jboptimizer" align-center :modal="false" :close-on-click-modal="false"
  1187. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1188. :before-close="handleClose" width="430" class="dialog_class bgcolor tianjia sel colortext">
  1189. <template #header="{ titleId, titleClass }">
  1190. <div class="my-header ">
  1191. <!-- <el-image :src="getImgPath('t2.png')" fit="contain"></el-image> -->
  1192. <h4 :id="titleId" :class="titleClass">优化算法:</h4>
  1193. </div>
  1194. </template>
  1195. <Joptimize ref='Joptimizeref'/>
  1196. <template #footer>
  1197. <div class="dialog-footer">
  1198. <el-button @click="dialog.jboptimizer = false">取消</el-button>
  1199. <el-button type="primary" @click="getaddsave(); dialog.jboptimizer = false">
  1200. 确定
  1201. </el-button>
  1202. </div>
  1203. </template>
  1204. </el-dialog>
  1205. <!-- 单独的代理优化器 -->
  1206. <el-dialog v-model="dialog.dboptimizer" align-center :modal="false" :close-on-click-modal="false"
  1207. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1208. :before-close="handleClose" width="530" class="dialog_class bgcolor tianjia sel colortext">
  1209. <template #header="{ titleId, titleClass }">
  1210. <div class="my-header ">
  1211. <!-- <el-image :src="getImgPath('t2.png')" fit="contain"></el-image> -->
  1212. <h4 :id="titleId" :class="titleClass">代理优化器</h4>
  1213. </div>
  1214. </template>
  1215. <Doptimize ref="Doptimizeref"/>
  1216. <template #footer>
  1217. <div class="dialog-footer">
  1218. <el-button @click="dialog.dboptimizer = false">取消</el-button>
  1219. <el-button type="primary" @click="getDaddsave(); dialog.dboptimizer = false">
  1220. 确定
  1221. </el-button>
  1222. </div>
  1223. </template>
  1224. </el-dialog>
  1225. <!-- 单独的梯度优化器 -->
  1226. <el-dialog v-model="dialog.tboptimizer" align-center :modal="false" :close-on-click-modal="false"
  1227. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1228. :before-close="handleClose" width="430" class="dialog_class bgcolor tianjia sel colortext">
  1229. <template #header="{ titleId, titleClass }">
  1230. <div class="my-header ">
  1231. <!-- <el-image :src="getImgPath('t2.png')" fit="contain"></el-image> -->
  1232. <h4 :id="titleId" :class="titleClass">梯度优化器:</h4>
  1233. </div>
  1234. </template>
  1235. <Toptimize ref="Toptimizeref"/>
  1236. <template #footer>
  1237. <div class="dialog-footer">
  1238. <el-button @click="dialog.tboptimizer = false">取消</el-button>
  1239. <el-button type="primary" @click="getTaddsave(); dialog.tboptimizer = false">
  1240. 确定
  1241. </el-button>
  1242. </div>
  1243. </template>
  1244. </el-dialog>
  1245. <!-- 单独的ADflow -->
  1246. <el-dialog v-model="dialog.isADflow" align-center :modal="false" :close-on-click-modal="false"
  1247. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1248. :before-close="handleClose" width="540" class="dialog_class bgcolor tianjia sel colortext">
  1249. <template #header="{ titleId, titleClass }">
  1250. <div class="my-header ">
  1251. <!-- <el-image :src="getImgPath('t2.png')" fit="contain"></el-image> -->
  1252. <h4 :id="titleId" :class="titleClass">ADflow</h4>
  1253. </div>
  1254. </template>
  1255. <ADflow ref="ADflowref"/>
  1256. <template #footer>
  1257. <div class="dialog-footer">
  1258. <el-button @click="dialog.isADflow = false">取消</el-button>
  1259. <el-button type="primary" @click=" adflowok();dialog.isADflow = false">
  1260. 确定
  1261. </el-button>
  1262. </div>
  1263. </template>
  1264. </el-dialog>
  1265. <!-- Python -->
  1266. <el-dialog v-model="dialog.Pythonshow" align-center :modal="false" :close-on-click-modal="false"
  1267. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1268. :before-close="handleClose" width="700" class="dialog_class bgcolor colortext tianjia sel">
  1269. <template #header="{ titleId, titleClass }">
  1270. <div class="my-header ">
  1271. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1272. <h4 :id="titleId" :class="titleClass">Python</h4>
  1273. </div>
  1274. </template>
  1275. <div class="footerp" style="height:525px;padding:15px">
  1276. <div>
  1277. <!-- <el-input
  1278. v-model="textarea1"
  1279. style="width: 100%"
  1280. :autosize="{ minRows: 2, maxRows: 4 }"
  1281. type="textarea"
  1282. placeholder="Please input"
  1283. /> -->
  1284. <PythonEdit v-show="pythoneditorshow" v-model:value="textarea1" language="python" @change="handleEditorChange"/>
  1285. </div>
  1286. <div class="pythfoter">
  1287. <div class="span active" >
  1288. <el-image :src="xin" style="width: 25px;height: 25px;margin-right: 5px;"></el-image>
  1289. <span>信息栏 </span>
  1290. </div>
  1291. <el-input
  1292. v-model="textarea2"
  1293. style="width: 100%"
  1294. :autosize="{ minRows: 2, maxRows: 4 }"
  1295. type="textarea"
  1296. placeholder=""
  1297. />
  1298. </div>
  1299. </div>
  1300. <template #footer>
  1301. <div class="dialog-footer">
  1302. <el-button @click="dialog.Pythonshow = false">检查</el-button>
  1303. <el-button type="primary" @click="pythonSubmit(); dialog.Pythonshow = false">
  1304. 保存
  1305. </el-button>
  1306. </div>
  1307. </template>
  1308. </el-dialog>
  1309. <!-- MathFunc -->
  1310. <el-dialog v-model="dialog.MathFuncdialog" align-center :modal="false" :close-on-click-modal="false"
  1311. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1312. :before-close="handleClose" width="500" class="dialog_class bgcolor colortext tianjia sel">
  1313. <template #header="{ titleId, titleClass }">
  1314. <div class="my-header ">
  1315. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1316. <h4 :id="titleId" :class="titleClass">MathFunc</h4>
  1317. </div>
  1318. </template>
  1319. <MathFunc ref="MathFuncref" @selectTab="MathFunctabchange"/>
  1320. <template #footer>
  1321. <div style="display: flex;justify-content: space-between;">
  1322. <div>
  1323. <el-button v-show="MathFuncxinjian" @click="mathfuncxinjian()">新建</el-button>
  1324. </div>
  1325. <div class="dialog-footer">
  1326. <el-button @click="dialog.MathFuncdialog = false">取消</el-button>
  1327. <el-button type="primary" @click="getmathfunctosave(); dialog.MathFuncdialog = false">
  1328. 确定
  1329. </el-button>
  1330. </div>
  1331. </div>
  1332. </template>
  1333. </el-dialog>
  1334. <!-- FSI -->
  1335. <el-dialog v-model="dialog.fsidialog" align-center :modal="false" :close-on-click-modal="false"
  1336. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1337. :before-close="handleClose" width="570" class="dialog_class bgcolor tianjia sel colortext">
  1338. <template #header="{ titleId, titleClass }">
  1339. <div class="my-header ">
  1340. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1341. <h4 :id="titleId" :class="titleClass">FUN to FEM</h4>
  1342. </div>
  1343. </template>
  1344. <FSI ref="Fsiref"/>
  1345. <template #footer>
  1346. <div class="dialog-footer">
  1347. <el-button @click="dialog.fsidialog = false">取消</el-button>
  1348. <el-button type="primary" @click="getfsitosave();dialog.fsidialog = false">
  1349. 确定
  1350. </el-button>
  1351. </div>
  1352. </template>
  1353. </el-dialog>
  1354. <!-- Flight -->
  1355. <el-dialog v-model="dialog.flightdialog" align-center :modal="false" :close-on-click-modal="false"
  1356. :append-to-body="true" draggable :fullscreen="false" :modal-append-to-body="false" modal-class="summary-dlg"
  1357. :before-close="handleClose" width="630" class="dialog_class bgcolor tianjia sel colortext">
  1358. <template #header="{ titleId, titleClass }">
  1359. <div class="my-header ">
  1360. <!-- <el-image :src="getImgPath('xuek0.png')" fit="contain"></el-image> -->
  1361. <h4 :id="titleId" :class="titleClass">Flight</h4>
  1362. </div>
  1363. </template>
  1364. <Flight ref="Flightref"/>
  1365. <template #footer>
  1366. <div class="dialog-footer">
  1367. <el-button @click="dialog.flightdialog = false">取消</el-button>
  1368. <el-button type="primary" @click=" dialog.flightdialog = false">
  1369. 确定
  1370. </el-button>
  1371. </div>
  1372. </template>
  1373. </el-dialog>
  1374. <!-- 内容区 -->
  1375. <div class="main mianflex">
  1376. <!--left菜单栏 -->
  1377. <Sidebar ref="Sidebarref" />
  1378. <!-- 放图形 -->
  1379. <div class="right_container">
  1380. <div class="main_model">
  1381. <div class="jindutiao" v-show="progressshow">
  1382. <!-- 进度条 -->
  1383. <span style="width: 150px;">运行进度</span>
  1384. <!-- <el-progress :text-inside="true" :stroke-width="26" :percentage="70" /> -->
  1385. <div class="demo-progress">
  1386. <el-progress :percentage="percentage" :color="customColor">
  1387. <!-- <template #default="{ percentage }">
  1388. <span class="percentage-value">当前进度:{{ percentage }}%</span>
  1389. </template> -->
  1390. </el-progress>
  1391. <!-- <button @click="tbn">点我</button> -->
  1392. </div>
  1393. </div>
  1394. <div class="main_model" v-show='flowshow'>
  1395. <vuefindex ref="vuefval" @optimizerfalse="optimizerfalse($event)"></vuefindex>
  1396. </div>
  1397. <div class="maxh221">
  1398. <!-- 中间部分 -->
  1399. <!-- 列表监控 -->
  1400. <div class="conter_mian classtable " v-show="jiankong" style="width:100%; height: 100%;">
  1401. <el-table :data="tableDatalieb"
  1402. border
  1403. style=" overflow: auto; height: 100%;"
  1404. :header-cell-class-name="lbjkheaderCellClassName"
  1405. :key="tableKey"
  1406. >
  1407. <el-table-column type="index" label="编号" width="100"></el-table-column>
  1408. <el-table-column v-for="(header, index) in tableHeaders" :key="index" :prop="header.prop" show-overflow-tooltip
  1409. :label="header.label" >
  1410. </el-table-column>
  1411. </el-table>
  1412. </div>
  1413. <!-- 曲线监控 -->
  1414. <div class="conter_mian classtable " v-if="echartshow" style="width:100%; height: 100%;">
  1415. <!-- <el-form-item label="" >
  1416. <el-select v-model="quval" :suffix-icon="CaretBottom" placeholder="请选择">
  1417. <el-option v-for="item in quxian" :key="item.value" :label="item.label" :value="item.value">
  1418. </el-option>
  1419. </el-select>
  1420. </el-form-item> -->
  1421. <optmonitor ref="optmonitor1" :echartdata="echartdata" :selval="quval" :curvedata="curvedata" />
  1422. </div>
  1423. <!-- 过程监控 -->
  1424. <div class="conter_mian classtable conter_flex" v-if="echartshow2" style="width:100%; height: 100%;">
  1425. <div class="echart_left ech">
  1426. <processMonitor1 ref="processMonitor1ref" :echartdata="echartdata" :selval="quval" :curvedata="curvedata"/>
  1427. </div>
  1428. <div class="echart_right ech">
  1429. <processMonitor2 ref="processMonitor2ref" :echartdata="echartdata" :selval="quval" :curvedata="curvedata"/>
  1430. </div>
  1431. </div>
  1432. <!-- 可视化开始 -->
  1433. <div class="conter_mian classtable echartcont" v-show="echartzongshow">
  1434. <tablelist ref="tablelistref" v-show="tablelistshow" :tablelistshow="tablelistshow"
  1435. :tabledataliebiao="datatotabledata" :tableHeaders="datatotableheader"/>
  1436. <echartarea ref="arearef" v-show="areashow" :areashow="areashow"/>
  1437. <bargraph ref="bargraphref" v-show="bargraphshow" :bargraphshow="bargraphshow"/>
  1438. <echartLine ref="echartLineref" v-show="echartLineshow" :echartLineshow="echartLineshow"/>
  1439. <BarChart ref="BarChartref" v-show="BarChartshow" :BarChartshow="BarChartshow"/>
  1440. <scatter ref="scatterref" v-show="scattershow" :scattershow="scattershow"/>
  1441. <radar ref="radarref" v-show="radarshow" :radarshow="radarshow"/>
  1442. <pie ref="pieref" v-show="pieshow" :pieshow="pieshow" />
  1443. <pareto ref="paretoref" v-show="paretoshow" :paretoshow="paretoshow" />
  1444. </div>
  1445. <!-- 可视化结束 -->
  1446. <!-- 右侧边栏开始 -->
  1447. <!-- 结束 -->
  1448. </div>
  1449. <el-footer class="femFooter">
  1450. <div class="gooterpading">
  1451. <div class="footerTitle el-tag--primary">
  1452. <div>
  1453. <div class="span" v-for="(tab, index) in tabs" :key="index" :class="{ 'active': activeIndex === index }"
  1454. @click="xxclick(index)">
  1455. <el-image :src="tab.img" fit="contain"></el-image>
  1456. <span>{{ tab.name }} </span></div>
  1457. </div>
  1458. <div>
  1459. <!-- <li
  1460. class="exloadbox"
  1461. v-show="elodingfalse"
  1462. >
  1463. <span>正在求解中</span>
  1464. <i class="el-icon-loading"></i>
  1465. </li> -->
  1466. <!-- <li>
  1467. <span >清空</span>
  1468. </li> -->
  1469. <li>
  1470. <span @click="footerShows('foot')">&#9650;&#9660;</span>
  1471. </li>
  1472. </div>
  1473. </div>
  1474. <div v-if="footerShow">
  1475. <div class="footerTextBox" v-if="activeIndex == 0">
  1476. <el-input class="footerText" type="textarea" id="textarea_id" v-model="logs"></el-input>
  1477. </div>
  1478. <div class="youhualog" v-if="activeIndex == 1">
  1479. <ul>
  1480. <template v-for="(tab, index) in listli" :key="index">
  1481. <el-divider v-if="index !== 0" direction="vertical" class="custom-divider"></el-divider>
  1482. <li @click="issueclick(index)" :class="{ 'active2': activeIndex2 === index }">
  1483. <el-image v-if="activeIndex2 === index" :src="tab.isimg" fit="contain"></el-image>
  1484. <el-image v-else :src="tab.noimg" fit="contain"></el-image>
  1485. <span>{{ tab.name }}</span>
  1486. </li>
  1487. </template>
  1488. </ul>
  1489. <div class="footer-content">
  1490. <div class="eldesign classtable" v-if="activeIndex2 == 0">
  1491. <el-table :data="designtable" border style="width: 100%" height="100">
  1492. <el-table-column type="index" label="编号" width="70" />
  1493. <el-table-column prop="name" label="变量名称">
  1494. <template #default="{ row }">
  1495. <el-input v-model="row.name" @change="handleEdit(row)" />
  1496. </template>
  1497. </el-table-column>
  1498. <el-table-column prop="upper" label="上限值">
  1499. <template #default="{ row }">
  1500. <el-input type="text" v-model="row.upper"
  1501. @change="handleEdit(row)" />
  1502. </template>
  1503. </el-table-column>
  1504. <el-table-column prop="lower" label="下限值">
  1505. <template #default="{ row }">
  1506. <el-input v-model="row.lower"
  1507. @change="handleEdit(row)" />
  1508. </template>
  1509. </el-table-column>
  1510. <el-table-column prop="reference" label="基准值" >
  1511. <template #default="{ row }">
  1512. <el-input v-model="row.reference"
  1513. @change="handleEdit(row)" />
  1514. </template>
  1515. </el-table-column>
  1516. <el-table-column prop="remark" label="说明">
  1517. <template #default="{ row }">
  1518. <el-input v-model="row.remark" @change="handleEdit(row)" />
  1519. </template>
  1520. </el-table-column>
  1521. <!-- <el-table-column label="操作" width="140">
  1522. <template #default="scope">
  1523. <el-button size="small" type="danger"
  1524. @click.stop="sjdelete(scope.$index, scope.row)">删除</el-button>
  1525. </template>
  1526. </el-table-column> -->
  1527. </el-table>
  1528. </div>
  1529. <div class="elconstraint classtable" v-if="activeIndex2 == 1">
  1530. <el-table :data="tableData" border style="width: 100%" height="100">
  1531. <el-table-column type="index" label="编号" width="100" />
  1532. <el-table-column prop="name" label="约束名称">
  1533. <template #default="{ row }">
  1534. <el-input v-model="row.name" @change="handleEdit(row)" />
  1535. </template>
  1536. </el-table-column>
  1537. <!-- <el-table-column prop="con" label="约束关系">
  1538. <template v-slot="scope">
  1539. <el-select class="no-border " v-model.number="scope.row.con" :suffix-icon="CaretBottom"
  1540. placeholder="请选择">
  1541. <el-option v-for="item in options3" :key="item.value" :label="item.label"
  1542. :value="item.value">
  1543. </el-option>
  1544. </el-select>
  1545. </template>
  1546. </el-table-column> -->
  1547. <el-table-column prop="reference" label="约束基准值">
  1548. <template #default="{ row }">
  1549. <el-input v-model="row.reference"
  1550. @change="handleEdit(row)" />
  1551. </template>
  1552. </el-table-column>
  1553. <el-table-column prop="upper" label="上限值">
  1554. <template #default="{ row }">
  1555. <el-input v-model="row.upper"
  1556. @change="handleEdit(row)" />
  1557. </template>
  1558. </el-table-column>
  1559. <el-table-column prop="lower" label="下限值">
  1560. <template #default="{ row }">
  1561. <el-input v-model="row.lower"
  1562. @change="handleEdit(row)" />
  1563. </template>
  1564. </el-table-column>
  1565. <!-- <el-table-column label="操作" width="140">
  1566. <template #default="scope">
  1567. <el-button size="small" type="danger"
  1568. @click.stop="ysdelete(scope.$index, scope.row)">删除</el-button>
  1569. </template>
  1570. </el-table-column> -->
  1571. </el-table>
  1572. </div>
  1573. <div class="eloptimize classtable" v-if="activeIndex2 == 2">
  1574. <el-table :data="eloptimize" border style="width: 100%" height="100">
  1575. <el-table-column type="index" label="编号" width="70" />
  1576. <el-table-column prop="name" label="目标名称">
  1577. <template #default="{ row }">
  1578. <el-input v-model="row.name" />
  1579. </template>
  1580. </el-table-column>
  1581. <el-table-column prop="optdir" label="优化方向">
  1582. <template v-slot="scope">
  1583. <el-select class="no-border " v-model="scope.row.optdir" :suffix-icon="CaretBottom"
  1584. placeholder="请选择">
  1585. <el-option v-for="item in options1" :key="item.value" :label="item.label"
  1586. :value="item.value">
  1587. </el-option>
  1588. </el-select>
  1589. </template>
  1590. </el-table-column>
  1591. <el-table-column prop="weight" label="权重系数">
  1592. <template #default="{ row }">
  1593. <el-input v-model="row.weight"
  1594. @change="handleEdit(row)" />
  1595. </template>
  1596. </el-table-column>
  1597. <!-- <el-table-column prop="scaling" label="数据缩放">
  1598. <template v-slot="scope">
  1599. <el-checkbox :false-label="0" :true-label="1" v-model="scope.row.scaling" />
  1600. </template>
  1601. </el-table-column>
  1602. <el-table-column prop="factor" label="缩放因子">
  1603. <template #default="{ row }">
  1604. <el-input v-model.number="row.factor" oninput="value=value.replace(/^|[^0-9]/g,'')"
  1605. @change="handleEdit(row)" />
  1606. </template>
  1607. </el-table-column> -->
  1608. <el-table-column prop="reference" label="约束基准值">
  1609. <template #default="{ row }">
  1610. <el-input v-model="row.reference"
  1611. @change="handleEdit(row)" />
  1612. </template>
  1613. </el-table-column>
  1614. <el-table-column prop="remark" label="说明">
  1615. <template #default="{ row }">
  1616. <el-input v-model="row.remark" @change="handleEdit(row)" />
  1617. </template>
  1618. </el-table-column>
  1619. <!-- <el-table-column label="操作" width="140">
  1620. <template #default="scope">
  1621. <el-button size="small" type="danger"
  1622. @click.stop="mbdelete(scope.$index, scope.row)">删除</el-button>
  1623. </template>
  1624. </el-table-column> -->
  1625. </el-table>
  1626. </div>
  1627. </div>
  1628. <div class="dibu">
  1629. <div class="footer-add">
  1630. <div class="sev_ruwu">
  1631. <div class="disflex flexend">
  1632. <el-form-item label="新增变量数:" v-if="activeIndex2 === 0">
  1633. <el-input v-model="tableval" maxlength="6"
  1634. oninput="value=value.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5]/g,'')" class="w-50 m-2"
  1635. />
  1636. </el-form-item>
  1637. <el-button class="btncolor" v-if="activeIndex2 === 0">导入</el-button>
  1638. <el-button class="btncolor" @click="onAddItem">新建</el-button>
  1639. <el-button class="btncolor" @click="onokItem">确定</el-button>
  1640. </div>
  1641. </div>
  1642. </div>
  1643. </div>
  1644. </div>
  1645. </div>
  1646. <div class="pading_foter">
  1647. </div>
  1648. </div>
  1649. </el-footer>
  1650. </div>
  1651. </div>
  1652. </div>
  1653. </div>
  1654. </el-main>
  1655. </el-container>
  1656. </div>
  1657. </template>
  1658. <script setup>
  1659. import { ref, onMounted, reactive, provide, nextTick } from "vue";
  1660. import { RouterView, RouterLink, useRouter, useRoute } from "vue-router"
  1661. import myheader from "@/components/header.vue"
  1662. import { request, uploadFile } from "@/utils/request";
  1663. import { ElMessage, ElButton, ElDialog, ElSelect } from 'element-plus'
  1664. import { Edit, CaretBottom } from '@element-plus/icons-vue'
  1665. // import '@/utils/flexible'
  1666. import { ArrowDown } from '@element-plus/icons-vue';
  1667. import s0 from "@/assets/img/s0.png"
  1668. import gc1 from "@/assets/img/gc1.png"
  1669. import gc2 from "@/assets/img/gc2.png"
  1670. import gc3 from "@/assets/img/gc3.png"
  1671. import wen from "@/assets/img/wen.png"
  1672. import q2 from "@/assets/img/q2.png"
  1673. import f21 from "@/assets/img/f21.png"
  1674. import f22 from "@/assets/img/f22.png"
  1675. import f41 from "@/assets/img/f41.png"
  1676. import xin from "@/assets/img/xin.png"
  1677. import xin2 from "@/assets/img/xin2.png"
  1678. import s from "@/assets/img/s.png"
  1679. import y from "@/assets/img/y.png"
  1680. import y2 from "@/assets/img/y2.png"
  1681. import nos from "@/assets/img/nos.png"
  1682. import zy from "@/assets/img/zy.png"
  1683. import zy2 from "@/assets/img/zy2.png"
  1684. import xuek10 from '@/assets/flowimg/xuek10.png'
  1685. import xuek11 from '@/assets/flowimg/xuek11.png'
  1686. import xuek12 from '@/assets/flowimg/xuek12.png'
  1687. import optmonitor from './echart/optimize_monitor.vue'
  1688. import processMonitor1 from "./echart/process-monitor1.vue"
  1689. import processMonitor2 from "./echart/process-monitor2.vue"
  1690. import echartindex from './echart/index.vue'
  1691. import sixtop from './echart/six_top.vue'
  1692. import sixbottom from './echart/six_bottom.vue'
  1693. import sixindex from './demo/index.vue'
  1694. import sixchine from './demo/chine.vue'
  1695. import vuefindex from './vuetree/index.vue'
  1696. import Sidebar from './vuetree/Sidebar.vue'
  1697. // 可视化echart
  1698. import tablelist from './echart/tablelist.vue'
  1699. import echartarea from './echart/area.vue'
  1700. import bargraph from './echart/bargraph.vue'
  1701. import echartLine from './echart/echartLine.vue'
  1702. import BarChart from './echart/BarChart.vue'
  1703. import scatter from './echart/scatter.vue'
  1704. import radar from './echart/radar.vue'
  1705. import pie from './echart/pie.vue'
  1706. import pareto from './echart/pareto.vue'
  1707. import Doptimize from './titlecomponent/Doptimize.vue'
  1708. import Joptimize from './titlecomponent/Joptimize.vue'
  1709. import Toptimize from './titlecomponent/Toptimize.vue'
  1710. import ADflow from './titlecomponent/ADflow.vue'
  1711. import Xfoil from './titlecomponent/Xfoil.vue'
  1712. import csts from './titlecomponent/csts.vue'
  1713. import ffds from './titlecomponent/ffds.vue'
  1714. import cloudsecond from "./titlecomponent/Cloudsecond.vue";
  1715. import FSI from './titlecomponent/FSI.vue'
  1716. import Flight from './titlecomponent/Flight.vue'
  1717. import MathFunc from './titlecomponent/MathFunc.vue'
  1718. import ListSE from "./titlecomponent/ListSE.vue";
  1719. import TACS from "./titlecomponent/TACS.vue";
  1720. import fileUploads from './components/fileuploads.vue'
  1721. import Exreport from "./titlecomponent/Exreport.vue";
  1722. import PythonEdit from '@/components/PythonEditor/index.vue'; // python编辑器
  1723. import pdfReportView from '@/components/pdfReportView/index.vue'; //报告查看
  1724. import cloudChart from './threejsView/index.vue'; // 云图
  1725. import emitter from "@/utils/emitter";
  1726. import cloundCharts from '@/components/cloudChart/index.vue';
  1727. let Sidebarref = ref();
  1728. let resource=ref(0);
  1729. let cstnum=ref('');
  1730. let textarea2=ref()
  1731. let textarea1 = ref(`import os
  1732. import numpy as np
  1733. from surromdao.solver import BaseSolver
  1734. class Branin(BaseSolver):
  1735. def __init__(self, filename=os.path):
  1736. super().__init__(filename)
  1737. def compute(self, xdict):
  1738. x = np.zeros(2)
  1739. # x[0] = xdict['x1']
  1740. # x[1] = xdict['x2']`);
  1741. let Cstref = ref();
  1742. let Ffdref = ref();
  1743. let Xfoilref = ref();
  1744. let ADflowref = ref();
  1745. let Joptimizeref=ref();
  1746. let Doptimizeref=ref();
  1747. let Toptimizeref=ref();
  1748. let Fsiref=ref();
  1749. let Flightref=ref();
  1750. let MathFuncref=ref();
  1751. let Tacsref=ref();
  1752. let f4ce = ref("优化问题组件");
  1753. let modelban = ref("学科分析组件");
  1754. let undmodel=ref('优化器组件');
  1755. let optiongroup1 = ref([
  1756. { label: '优化问题', value: '优化问题',img:'wen.png' }
  1757. ])
  1758. let options4 = ref([
  1759. { label: '进化优化器', value: '进化优化器', icon:xuek10 },
  1760. { label: '代理优化器', value: '代理优化器', icon:xuek11 },
  1761. { label: '梯度优化器', value: '梯度优化器', icon:xuek12 },
  1762. ])
  1763. let formLabelWidth3=ref(100)
  1764. let formLabelWidth200=ref(200)
  1765. let tablecstHeaders=ref([]);
  1766. let treeitem = ref({});
  1767. let treeitem2 = ref({});
  1768. let treeitem3 = ref({});
  1769. let percentage = ref(0);
  1770. let percentageTotalstep = ref(100);
  1771. let progressshow = ref(false);
  1772. let flowshow = ref(true);
  1773. let jiankong = ref(false);
  1774. let echartshow = ref(false);
  1775. let echartshow2 = ref(false);
  1776. let tablelistshow = ref(false);
  1777. let areashow = ref(false);
  1778. let echartLineshow = ref(false);
  1779. let BarChartshow = ref(false);
  1780. let bargraphshow = ref(false);
  1781. let scattershow = ref(false);
  1782. let radarshow = ref(false);
  1783. let pieshow = ref(false);
  1784. let paretoshow = ref(false);
  1785. let bargraphref = ref();
  1786. let echartLineref = ref();
  1787. let BarChartref = ref();
  1788. let radarref = ref();
  1789. let pieref = ref();
  1790. let paretoref = ref();
  1791. let scatterref = ref();
  1792. let echartzongshow = ref(false);
  1793. const router = useRouter();
  1794. const route = useRoute();
  1795. let tablelistref = ref();
  1796. let echartdata = ref(null);
  1797. let optmonitor1 = ref();
  1798. let processMonitor1ref = ref()
  1799. let processMonitor2ref = ref()
  1800. let arearef = ref();
  1801. let tableHeaders = ref([
  1802. { label: '参数1', prop: 'value1' },
  1803. { label: '参数2', prop: 'value2' },
  1804. { label: '参数3', prop: 'value3' },
  1805. { label: '参数4', prop: 'value4' },
  1806. { label: '参数5', prop: 'value5' },
  1807. ])
  1808. let varsobj = ref({});
  1809. let valsobj = ref({});
  1810. let tabarr = ref([]);
  1811. let arrobj = ref([]);
  1812. let tableDatalieb = ref([
  1813. { value1: '0.00', value2: '0.00', value3:'0.00', value4:'0.00', value5:'0.00'},
  1814. { value1: '0.00', value2: '0.00', value3:'0.00', value4:'0.00', value5:'0.00'},
  1815. { value1: '0.00', value2: '0.00', value3:'0.00', value4:'0.00', value5:'0.00'},
  1816. { value1: '0.00', value2: '0.00', value3:'0.00', value4:'0.00', value5:'0.00'},
  1817. { value1: '0.00', value2: '0.00', value3:'0.00', value4:'0.00', value5:'0.00'},
  1818. ])
  1819. let curvedata = ref('');
  1820. let websock = ref(null);
  1821. let times = ref({
  1822. lockReconnect: false, //是否真正建立连接
  1823. timeout: 28 * 1000, //30秒一次心跳
  1824. timeoutObj: null, //心跳倒计时
  1825. serverTimeoutObj: null, //
  1826. timeoutnum: null, //断开重连倒计时
  1827. })
  1828. let input3=ref()
  1829. let eid = ref('');//进步优化器的eid
  1830. let logs = ref("");
  1831. let pid = ref("");
  1832. let pythonwid = ref();
  1833. let youhuaqiwid = ref();
  1834. let canshuhuawid = ref();
  1835. let qidongyouhuawid = ref();
  1836. let fid = ref('');
  1837. let conid = ref('');
  1838. let tableval = ref();
  1839. let vuefval = ref();
  1840. let elodingfalse = ref(false);
  1841. let footerShow = ref(true);
  1842. let zhixing = ref('Rosenbrock');
  1843. let tabName = ref("one")
  1844. const tabs = [{
  1845. name:'信息栏',
  1846. img:xin,
  1847. },{
  1848. name:'优化问题',
  1849. img:xin2,
  1850. }]
  1851. const listli=[{
  1852. name:'设计变量',
  1853. noimg:nos,
  1854. isimg:s
  1855. },{
  1856. name:'约束条件',
  1857. noimg:y2,
  1858. isimg:zy2
  1859. },
  1860. {
  1861. name:'优化目标',
  1862. noimg:y,
  1863. isimg:zy
  1864. }
  1865. ]
  1866. const xfoil = ['输入', '执行', '输出'];
  1867. const newxfoil = ['输入参数', '输出参数', '中间参数'];
  1868. let srtable = ref([]);
  1869. let radio1=ref(0);
  1870. let srnewtable = ref([
  1871. {
  1872. date: '2016-05-04',
  1873. name: 'Aleyna Kutzner',
  1874. },
  1875. {
  1876. date: '2016-05-03',
  1877. name: 'Helen Jacobi',
  1878. },
  1879. ]);
  1880. let scnewtable = ref([
  1881. {
  1882. date: '2016-05-04',
  1883. name: 'Aleyna Kutzner',
  1884. con:-1
  1885. },
  1886. {
  1887. date: '2016-05-03',
  1888. name: 'Helen Jacobi',
  1889. con:1
  1890. },
  1891. ]);
  1892. let sctable = ref([]);
  1893. // let quxian=ref([{
  1894. // val:'1',name:"设计变量",
  1895. // val:'2',name:"约束条件",
  1896. // val:'3',name:"约束条件",
  1897. // }])
  1898. // let quval=ref('1')
  1899. let currentTab=ref(0);
  1900. // let tabslist = ref([
  1901. // { id: '0', name: '来流参数' },
  1902. // { id: '1', name: '设置参数' },
  1903. // { id: '2', name: '分析参数' },
  1904. // ])
  1905. let yslist = ref([
  1906. { label: 'GA', value: 'GA' },
  1907. { label: 'PSO', value: 'PSO' },
  1908. { label: 'NSGA2', value: 'NSGA2' },
  1909. ])
  1910. let lailiutable=ref([
  1911. {
  1912. data: 1,
  1913. name: '结构质量',
  1914. con:-1
  1915. },
  1916. {
  1917. data: 23,
  1918. name: 'KS失效',
  1919. con:1
  1920. },
  1921. {
  1922. data: 0.0,
  1923. name: '最大变形',
  1924. con: -1
  1925. }
  1926. ])
  1927. let quxian = ref([
  1928. { label: '设计变量', value: '设计变量' },
  1929. { label: '约束条件', value: '约束条件' },
  1930. { label: '目标函数', value: '目标函数' },
  1931. ])
  1932. let quval = ref("")
  1933. const activeIndex = ref(0);
  1934. const activeIndex2 = ref(0);
  1935. const activeIndex3 = ref(0);
  1936. const color1 = ref('');
  1937. const colortier = ref('rgba(16, 185, 129, 0.5)');
  1938. let showTrigger = ref(false);
  1939. let activeadf=ref('Xfoil');
  1940. const datatree = ref([
  1941. {
  1942. id: 1,
  1943. label: '工程',
  1944. children: [
  1945. {
  1946. id: '1-1',
  1947. label: '优化问题',
  1948. img: gc1,
  1949. },
  1950. {
  1951. id: '1-2',
  1952. label: '分析流程',
  1953. img: gc2,
  1954. },
  1955. {
  1956. id: '1-3',
  1957. label: '优化器',
  1958. img: gc3
  1959. },
  1960. ],
  1961. },
  1962. ])
  1963. let options1 = ref([
  1964. { label: '最大化', value: "-1" },
  1965. { label: '最小化', value: "1" },
  1966. ])
  1967. let options2 = ref([
  1968. { label: '升力系数', value: '升力系数' },
  1969. { label: '翼型面积', value: '翼型面积' },
  1970. ])
  1971. let options3 = ref([
  1972. { label: '大于', value: -1 },
  1973. { label: '小于', value: 1 },
  1974. ])
  1975. let shuxingopt = ref([
  1976. { label: '约束条件', value: -1 },
  1977. { label: '优化目标', value: 1 },
  1978. ])
  1979. let defaultExpandedArr = ref([]);
  1980. const defaultProps = {
  1981. children: 'children',
  1982. label: 'label',
  1983. }
  1984. let svarlist = ref('');
  1985. let conlist = ref('');
  1986. let funlist = ref('');
  1987. let looktext=ref('');
  1988. // treeData.value.forEach((item) => {
  1989. // defaultExpandedArr.value.push(item.id);
  1990. // });
  1991. const activeName = ref('Role')
  1992. const activeName1 = ref('message')
  1993. let active = ref('Role10');
  1994. let tabactive = ref("");
  1995. let checkbox = ref(false)
  1996. let formLabelWidth6 = ref(100)
  1997. let formLabelWidth1 = ref(170)
  1998. let formLabelWidth2 = ref(130)
  1999. let canshu = ref();
  2000. let question = ref([
  2001. { url: 'kk1.png', titlie: "列表" },
  2002. { url: 'kk2.png', titlie: "散点图" },
  2003. { url: 'kk4.png', titlie: "折线图" },
  2004. { url: 'kk8.png', titlie: "帕雷托图" },
  2005. { url: 'kk3.png', titlie: "面积图" },
  2006. { url: 'kk5.png', titlie: "柱状图" },
  2007. { url: 'k3.png', titlie: "饼状图" },
  2008. { url: 'kk6.png', titlie: "横条图" },
  2009. { url: 'kk7.png', titlie: "雷达图" },
  2010. { url: 'kk9.png', titlie: "云图/等值线" },
  2011. { url: 'kk10.png', titlie: "查看报告" },
  2012. { url: 'kk11.png', titlie: "导出报告" },
  2013. ])
  2014. let roletion = ref([
  2015. { url: 'f41.png', titlie: "测试函数模板" },
  2016. { url: 'r1.png', titlie: "工程优化模板" },
  2017. { url: 'r2.png', titlie: "自定义" },
  2018. ])
  2019. let tasktion = ref([
  2020. { url: 't0.png', titlie: "外形参数化" },
  2021. ])
  2022. let Rolelist = ref([
  2023. { url: 'tow1.png', titlie: "优化问题组件" },
  2024. { url: 'tow2.png', titlie: "学科分析组件" },
  2025. { url: 'tow3.png', titlie: "优化器组件" },
  2026. ])
  2027. let Rolelist1 = ref([
  2028. { url: 'l1.png', titlie: "逻辑流连线" },
  2029. { url: 'l2.png', titlie: "数据流连线" },
  2030. ])
  2031. let Rolelist11 = ref([{ url: 'w6.png', titlie: "选择连线颜色" }])
  2032. let Rolelist2 = ref([
  2033. { url: 'cai1.png', titlie: "模块组合" },
  2034. { url: 'cai2.png', titlie: "模块拆分" },
  2035. ])
  2036. let Rolelist22 = ref([{ url: 'w9.png', titlie: "选择图框颜色" }])
  2037. let Rolelist3 = ref([
  2038. { url: 'w10.png', titlie: "添加注释" },
  2039. ])
  2040. let Threelist = ref([
  2041. { url: 'you1.png', titlie: "开始" },
  2042. { url: 'you2.png', titlie: "暂停" },
  2043. { url: 'you3.png', titlie: "续算" },
  2044. { url: 'tts.png', titlie: "结束" },
  2045. ])
  2046. let Threelist1 = ref([
  2047. { url: 'yh1.png', titlie: "列表监控" },
  2048. { url: 'yh2.png', titlie: "曲线监控" },
  2049. { url: 'yh3.png', titlie: "过程监控" },
  2050. ])
  2051. let Sevenlist = ref([
  2052. { url: 'rr2.png', titlie: '任务检索' },
  2053. { url: 'rr1.png', titlie: '任务管理' },
  2054. { url: 'rr3.png', titlie: '备份' },
  2055. ])
  2056. let eightlist = ref([
  2057. { url: 'e1.png', titlie: '用户手册' },
  2058. { url: 'e2.png', titlie: '帮助文档' },
  2059. { url: 'e3.png', titlie: '关于软件' },
  2060. ])
  2061. let canshulist = ref([
  2062. { label: 'CST参数化', value: 'CST参数化' },
  2063. { label: 'FFD参数化', value: 'FFD参数化' },
  2064. ])
  2065. let sevlist = ref([
  2066. { label: '任务编号', value: '任务编号' },
  2067. { label: '任务名称', value: '任务名称' },
  2068. { label: '任务类型', value: '任务类型' },
  2069. { label: '创建时间', value: '创建时间' },
  2070. ])
  2071. let seval4 = ref('任务名称');
  2072. let agelist = ref([
  2073. { label: 'Kriging模型', value: 'Kriging模型' },
  2074. { label: '相关函数类型', value: '相关函数类型' },
  2075. { label: '超参数优化方法', value: '超参数优化方法' },
  2076. { label: 'Hooke Jeeves方法循环次数', value: 'Hooke Jeeves方法循环次数' },
  2077. ])
  2078. let agval = ref("Kriging模型")
  2079. let agval1 = ref("固定设计空间")
  2080. let agval2 = ref("拉丁超立方")
  2081. let agelist1 = ref([
  2082. { label: '固定设计空间', value: '固定设计空间' },
  2083. ])
  2084. let agelist2 = ref([
  2085. { label: '拉丁超立方', value: '拉丁超立方' },
  2086. ])
  2087. let addval = ref("EI + MSP")
  2088. let addlist = ref([
  2089. { label: 'EI + MSP', value: 'EI + MSP' },
  2090. ])
  2091. let addval1 = ref("概率相乘法")
  2092. let addlist1 = ref([
  2093. { label: '概率相乘法', value: '概率相乘法' },
  2094. ])
  2095. let addval2 = ref("SBX交叉")
  2096. let addlist2 = ref([
  2097. { label: 'SBX交叉', value: 'SBX交叉' },
  2098. ])
  2099. let addval3 = ref("最佳保留策略")
  2100. let ys = ref("GA")
  2101. let addlist3 = ref([
  2102. { label: '最佳保留策略', value: '最佳保留策略' },
  2103. ])
  2104. let addval4 = ref("倒位变异")
  2105. let addlist4 = ref([
  2106. { label: '倒位变异', value: '倒位变异' },
  2107. ])
  2108. let addval7 = ref("1e-7")
  2109. let addlist7 = ref([
  2110. { label: '1e-7', value: '1e-7' },
  2111. ])
  2112. let addval8 = ref("NO")
  2113. let addlist8 = ref([
  2114. { label: 'YES', value: 'YES' },
  2115. { label: 'NO', value: 'NO' },
  2116. ])
  2117. let paretocbval = ref([])
  2118. let paretocheckbox = ref([
  2119. {label:'-cl',value:'-cl'},
  2120. {label:'cd',value:'cd'},
  2121. ])
  2122. let cloudbtnbox = ref([
  2123. {url:'meshFile.png',btnname:'文件选择'},
  2124. {url:'yu.png',btnname:'域'},
  2125. {url:'kk9.png',btnname:'云图'},
  2126. {url:'seka.png',btnname:'色卡'},
  2127. {url:'dengzx.png',btnname:'等值线'},
  2128. ])
  2129. let dialog = ref({
  2130. newdialog: false,
  2131. setdialog: false,
  2132. targetdialog: false,
  2133. design: false,
  2134. constraint: false,
  2135. parameter: false,
  2136. agency: false,
  2137. optimizer: false,
  2138. jboptimizer: false,
  2139. dboptimizer: false,
  2140. tboptimizer: false,
  2141. isADflow:false,
  2142. lookover:false,
  2143. exportreport:false,
  2144. Xfiol: false,
  2145. tidu:false,
  2146. CSTt:false,
  2147. ffdt:false,
  2148. XfAD:false,
  2149. cstffd:false,
  2150. Taxs:false,
  2151. enddialog: false,
  2152. addfun: false,
  2153. sufun: false,
  2154. task: false,
  2155. guanli: false,
  2156. optgroup:false,
  2157. Pythonshow:false,
  2158. MathFuncdialog:false,
  2159. listdialog:false,
  2160. scatterdialog:false,
  2161. echartLinedialog:false,
  2162. paretodialog:false,
  2163. clouddialog:false,
  2164. fsidialog:false,
  2165. flightdialog:false,
  2166. })
  2167. // let columns=ref[{
  2168. // columns: [
  2169. // { label: '上表面', prop: 'sbiao' },
  2170. // { label: '下表面', prop: 'xbiao' },
  2171. // // 动态添加更多列
  2172. // ]
  2173. // }]
  2174. let options = ref([
  2175. { label: '升阻比', value: '升阻比' },
  2176. { label: 'RCS', value: 'RCS' },
  2177. ])
  2178. let tasklist = ref([
  2179. { label: '气动', value: '气动' },
  2180. { label: '结构', value: '结构' },
  2181. { label: '隐身', value: '隐身' },
  2182. { label: '噪声', value: '噪声' },
  2183. ])
  2184. const optiongroup = ref([
  2185. { label: 'CST', value: 'CST', img:'xuek0.png' },
  2186. { label: 'FFD', value: 'FFD', img:'ffd.png' },
  2187. { label: 'Xfoil', value: 'Xfoil', img:'xuek9.png' },
  2188. { label: 'ADflow', value: 'ADflow', img:'ADflow.png' },
  2189. { label: 'TACS', value: 'TACS', img:'TACS.png' },
  2190. { label: 'CATIA', value: 'CATIA', img:'xuek1.png' },
  2191. { label: 'Python', value: 'Python', img:'xuek8.png' },
  2192. { label: 'Excel', value: 'Excel', img:'xuek2.png' },
  2193. { label: 'Feko', value: 'Feko', img:'xuek3.png' },
  2194. { label: 'Fluent', value: 'Fluent', img:'xuek4.png' },
  2195. { label: 'HCFD', value: 'HCFD', img:'xuek5.png' },
  2196. { label: 'Matlab', value: 'Matlab', img:'xuek6.png' },
  2197. { label: 'Nastran', value: 'Nastran', img:'xuek7.png' },
  2198. { label: 'FUN to FEM', value: 'FSI', img:'fsi.png' },
  2199. { label: 'Flight', value: 'Flight', img:'flight.png' },
  2200. ])
  2201. const eloptimize = ref([])
  2202. const tableData = ref([])
  2203. const designtable = ref([])
  2204. const tasktable = ref([
  2205. // {
  2206. // id: "01",
  2207. // time: '2016-05-03',
  2208. // name: '升阻比',
  2209. // state: '增大',
  2210. // },
  2211. // {
  2212. // id: "02",
  2213. // time: '2016-05-03',
  2214. // name: '升阻比',
  2215. // state: '增大',
  2216. // },
  2217. ])
  2218. const customColor = ref('#2267B1')
  2219. const customColors = [
  2220. { color: '#f56c6c', percentage: 20 },
  2221. { color: '#f56c6c', percentage: 40 },
  2222. { color: '#5cb87a', percentage: 60 },
  2223. { color: '#5cb87a', percentage: 80 },
  2224. { color: '#5cb87a', percentage: 100 },
  2225. ]
  2226. let name = ref("1")
  2227. let num = ref(1)
  2228. const getImgPath = (url) => {
  2229. return new URL(`../assets/img/${url}`, import.meta.url).href
  2230. }
  2231. const getflowImgPath = (url) => {
  2232. return new URL(`../assets/flowimg/${url}`, import.meta.url).href
  2233. }
  2234. onMounted(() => {
  2235. //console.log( Sidebarref.value.datatree);
  2236. setTimeout(function () {
  2237. init();
  2238. initWebSocket();
  2239. logsget();
  2240. // vuefval.value.getroter()
  2241. }, 1500);
  2242. // childfun();
  2243. emitter.on("stepfromyouhuaqi",handlePercentage);
  2244. });
  2245. onUnmounted(() => {
  2246. emitter.off("stepfromyouhuaqi", handlePercentage);
  2247. });
  2248. const sjdelete = (index, row) => {
  2249. console.log(index);
  2250. designtable.value.splice(index, 1)
  2251. }
  2252. const ysdelete = (index, row) => {
  2253. tableData.value.splice(index, 1)
  2254. }
  2255. const mbdelete = (index, row) => {
  2256. eloptimize.value.splice(index, 1)
  2257. }
  2258. // 初始值
  2259. const init = () => {
  2260. pid.value = route.query.pid;
  2261. console.log(route.query.pid);
  2262. }
  2263. const handleClick = (tab, event) => {
  2264. console.log('标签页:',tab.props.name);
  2265. tabactive.value = tab.props.name;
  2266. if (tabactive.value == 'User') {
  2267. vuefval.value.logToObject1().then(() => {
  2268. router.replace({ path: '/' });
  2269. console.log('跳转到首页');
  2270. });
  2271. } else {
  2272. }
  2273. if (tabactive.value == 'Role') {
  2274. flowshow.value = true;
  2275. console.log(11111)
  2276. } else {
  2277. flowshow.value = false;
  2278. console.log(flowshow.value)
  2279. }
  2280. ifjiankong();
  2281. dialogcolse()
  2282. // 可视化标签页
  2283. if (tabactive.value == 'Config') {
  2284. echartzongshow.value = true;
  2285. curveLine4();
  2286. } else {
  2287. echartzongshow.value = false;
  2288. }
  2289. }
  2290. const validateInput = (row) => {
  2291. // 允许输入 None / none / 负数 / 小数
  2292. if (/^(none|None|-?\d*\.?\d*)$/.test(row.upper)) {
  2293. row.upper = row.upper; // 允许输入
  2294. } else {
  2295. row.upper = row.upper.slice(0, -1); // 删除最后输入的非法字符
  2296. }
  2297. }
  2298. const validateInput1 = (row) => {
  2299. // 允许输入 None / none / 小数
  2300. if (/^(none|None|\d*\.?\d*)$/.test(row.upper)) {
  2301. row.upper = row.upper; // 允许输入
  2302. } else {
  2303. row.upper = row.upper.slice(0, -1); // 删除最后输入的非法字符
  2304. }
  2305. }
  2306. //表格点击事件
  2307. const handleEdit = (row) => {
  2308. // console.log('编辑后的数据:', row);
  2309. // 在这里处理数据保存逻辑,例如发送请求到后端更新数据
  2310. };
  2311. const footerClick = (tab, event) => {
  2312. }
  2313. // 关闭所有弹窗
  2314. const dialogcolse = () => {
  2315. dialog.value.newdialog = false;
  2316. dialog.value.setdialog = false;
  2317. dialog.value.targetdialog = false;
  2318. dialog.value.design = false;
  2319. dialog.value.constraint = false;
  2320. dialog.value.parameter = false;
  2321. dialog.value.agency = false;
  2322. dialog.value.addfun = false;
  2323. dialog.value.sufun = false;
  2324. dialog.value.enddialog = false;
  2325. dialog.value.task = false;
  2326. dialog.value.guanli = false;
  2327. }
  2328. // Tree的点击事件
  2329. const handleNodeClick = (data) => {
  2330. console.log(data)
  2331. tabactive.value = data.label;
  2332. dialogbolen();
  2333. }
  2334. const optimizerfalse = (val) => {
  2335. console.log('双击',val);
  2336. const name = val.name;
  2337. const wid = val.wid;
  2338. if (name == '优化器') {
  2339. // dialog.value.optimizer = true;
  2340. activeadf.value='代理优化器';
  2341. initoptimize(wid);
  2342. dialog.value.optgroup = true;
  2343. } else if (name == '参数化') {
  2344. activeadf.value='CST';
  2345. initcstffds(wid);
  2346. dialog.value.cstffd = true;
  2347. }else if (name == '气动分析') {
  2348. activeadf.value='Xfoil'
  2349. intxfoiladflow(wid);
  2350. dialog.value.XfAD = true;
  2351. } else if (name == '进化优化器') {
  2352. activeadf.value='进化优化器';
  2353. dialog.value.jboptimizer = true;
  2354. nextTick(() => {
  2355. // 确保 ref 已经初始化
  2356. if (Joptimizeref.value) {
  2357. // 调用 Joptimize 的 getoptimize 方法
  2358. Joptimizeref.value.getoptimize(pid.value,wid);
  2359. }
  2360. });
  2361. } else if (name == '代理优化器') {
  2362. activeadf.value='代理优化器';
  2363. // dialog.value.optgroup = true;
  2364. dialog.value.dboptimizer = true;
  2365. nextTick(() => {
  2366. // 确保 ref 已经初始化
  2367. if (Doptimizeref.value) {
  2368. Doptimizeref.value.getDoptimize(pid.value,wid);
  2369. }
  2370. });
  2371. }
  2372. // else if (val == 'Xfiol' || val == 'Rosenbrock') {
  2373. // importget();
  2374. // dialog.value.Xfiol = true;
  2375. // }
  2376. else if(name == '梯度优化器'){
  2377. activeadf.value='梯度优化器';
  2378. dialog.value.tboptimizer = true;
  2379. nextTick(() => {
  2380. // 确保 ref 已经初始化
  2381. if (Toptimizeref.value) {
  2382. Toptimizeref.value.getToptimize(pid.value,wid);
  2383. }
  2384. });
  2385. }else if(name == 'CST'){
  2386. /// dialog.value.CSTt = true;
  2387. activeadf.value='CST';
  2388. dialog.value.CSTt = true;
  2389. nextTick(() => {
  2390. // 确保 ref 已经初始化
  2391. if (Cstref.value) {
  2392. Cstref.value.getcst(pid.value,wid);
  2393. }
  2394. });
  2395. }else if(name == 'FFD'){
  2396. /// dialog.value.CSTt = true;
  2397. activeadf.value='FFD';
  2398. dialog.value.ffdt = true;
  2399. nextTick(() => {
  2400. // 确保 ref 已经初始化
  2401. if (Ffdref.value) {
  2402. Ffdref.value.getffds(pid.value,wid);
  2403. }
  2404. });
  2405. }
  2406. else if(name == 'ADflow'){
  2407. // adfhandleClick();
  2408. activeadf.value='ADflow';
  2409. dialog.value.isADflow = true;
  2410. nextTick(() => {
  2411. // 确保 ref 已经初始化
  2412. if (ADflowref.value) {
  2413. ADflowref.value.getadflow(pid.value,wid);
  2414. }
  2415. });
  2416. }else if(name == 'Xfoil'){
  2417. // activeadf.value='Xfiol';
  2418. dialog.value.Xfiol = true;
  2419. nextTick(() => {
  2420. // 确保 ref 已经初始化
  2421. if (Xfoilref.value) {
  2422. Xfoilref.value.getxfoil(pid.value,wid);
  2423. }
  2424. });
  2425. }else if(name == 'TACS'){
  2426. dialog.value.Taxs = true;
  2427. nextTick(() => {
  2428. // 确保 ref 已经初始化
  2429. if (Tacsref.value) {
  2430. Tacsref.value.gettacs(pid.value,wid);
  2431. }
  2432. });
  2433. }else if(name == '模版'){
  2434. dialog.value.optgroup = true;
  2435. activeadf.value='代理优化器';
  2436. }else if(name == 'Python'){
  2437. dialog.value.Pythonshow = true;
  2438. initPython(wid);
  2439. }else if(name == 'FSI'){
  2440. dialog.value.fsidialog = true;
  2441. nextTick(() => {
  2442. // 确保 ref 已经初始化
  2443. if (Fsiref.value) {
  2444. Fsiref.value.getfsi(pid.value,wid);
  2445. }
  2446. });
  2447. }else if(name == 'Flight'){
  2448. dialog.value.flightdialog = true;
  2449. }else if(name == 'MathFunc'){
  2450. dialog.value.MathFuncdialog = true;
  2451. nextTick(() => {
  2452. // 确保 ref 已经初始化
  2453. if (MathFuncref.value) {
  2454. MathFuncref.value.getmathfunc(pid.value,wid);
  2455. }
  2456. });
  2457. }
  2458. else {
  2459. dialog.value.optimizer = false;
  2460. dialog.value.jboptimizer = false;
  2461. dialog.value.Xfiol = false;
  2462. dialog.value.lookover = false;
  2463. dialog.value.tidu = false;
  2464. dialog.value.CSTt = false;
  2465. dialog.value.XfAD = false;
  2466. dialog.value.cstffd = false;
  2467. dialog.value.Pythonshow = false;
  2468. dialog.value.MathFuncdialog = false;
  2469. dialog.value.fsidialog = false;
  2470. dialog.value.flightdialog = false;
  2471. }
  2472. }
  2473. // 优化器窗口初始化
  2474. const initoptimize = (nowid) => {
  2475. youhuaqiwid.value = nowid;
  2476. const params1 = {
  2477. transCode:'MDO0018',
  2478. pid: pid.value,
  2479. wid: youhuaqiwid.value
  2480. }
  2481. const params2 = {
  2482. transCode:'MDO0031',
  2483. pid: pid.value,
  2484. wid: youhuaqiwid.value
  2485. }
  2486. const params3 = {
  2487. transCode:'MDO0033',
  2488. pid: pid.value,
  2489. wid: youhuaqiwid.value
  2490. }
  2491. Promise.all([
  2492. request(params1),
  2493. request(params2),
  2494. request(params3)
  2495. ]).then(([res1, res2, res3]) => {
  2496. console.log('1:', res1.checked);
  2497. console.log('2:', res2.checked);
  2498. console.log('3:', res3.checked);
  2499. if(res1.hasOwnProperty('eid')){
  2500. Joptimizeref.value.getoptimizeAssign(res1);
  2501. console.log('fuz1:');
  2502. }
  2503. if(res3.hasOwnProperty('grid')){
  2504. Toptimizeref.value.getToptimizeAssign(res3);
  2505. console.log('fuz2:');
  2506. }
  2507. if(res2.hasOwnProperty('suid')){
  2508. Doptimizeref.value.getDoptimizeAssign(res2);
  2509. console.log('fuz3:');
  2510. }
  2511. // 根据返回值来设置 activeadf
  2512. if (res1.checked === 1) {
  2513. activeadf.value = '进化优化器';
  2514. } else if (res2.checked === 1) {
  2515. activeadf.value = '代理优化器';
  2516. } else if (res3.checked === 1) {
  2517. activeadf.value = '梯度优化器';
  2518. }
  2519. console.log('Updated activeadf:', activeadf.value);
  2520. }).catch((err) => {
  2521. console.error('请求失败:', err);
  2522. });
  2523. }
  2524. // CST/FFD窗口初始化
  2525. const initcstffds = (nowid) => {
  2526. canshuhuawid.value = nowid;
  2527. const params1 = {
  2528. transCode:'MDO0040',
  2529. pid: pid.value,
  2530. wid: canshuhuawid.value
  2531. }
  2532. const params2 = {
  2533. transCode:'MDO0043',
  2534. pid: pid.value,
  2535. wid: canshuhuawid.value
  2536. }
  2537. Promise.all([
  2538. request(params1),
  2539. request(params2),
  2540. ]).then(([res1, res2]) => {
  2541. console.log('1:', res1.checked);
  2542. console.log('2:', res2.checked);
  2543. if(res1.hasOwnProperty('cstid')){
  2544. Cstref.value.getcstAssign(res1);
  2545. }else if(res2.hasOwnProperty("ffdid")){
  2546. Ffdref.value.getffdsAssign(res2);
  2547. }
  2548. // 根据返回值来设置 activeadf
  2549. if (res1.checked === 1) {
  2550. activeadf.value = 'CST';
  2551. } else if (res2.checked === 1) {
  2552. activeadf.value = 'FFD';
  2553. }
  2554. console.log('Updated activeadf:', activeadf.value);
  2555. }).catch((err) => {
  2556. console.error('请求失败:', err);
  2557. });
  2558. }
  2559. // Xfoil/ADflow窗口初始化
  2560. const intxfoiladflow = (nowid) => {
  2561. qidongyouhuawid.value = nowid;
  2562. const params1 = {
  2563. transCode:'MDO0046',
  2564. pid: pid.value,
  2565. wid: qidongyouhuawid.value
  2566. }
  2567. const params2 = {
  2568. transCode:'MDO0049',
  2569. pid: pid.value,
  2570. wid: qidongyouhuawid.value
  2571. }
  2572. Promise.all([
  2573. request(params1),
  2574. request(params2),
  2575. ]).then(([res1, res2]) => {
  2576. console.log('1:', res1.checked);
  2577. console.log('2:', res2.checked);
  2578. if(res1.hasOwnProperty("xfid")){
  2579. Xfoilref.value.getxfoilAssign(res1);
  2580. }else if(res2.hasOwnProperty("adid")){
  2581. ADflowref.value.getadflowAssign(res2);
  2582. }
  2583. // 根据返回值来设置 activeadf
  2584. if (res1.checked === 1) {
  2585. activeadf.value = 'Xfoil';
  2586. } else if (res2.checked === 1) {
  2587. activeadf.value = 'ADflow';
  2588. }
  2589. console.log('Updated activeadf:', activeadf.value);
  2590. }).catch((err) => {
  2591. console.error('请求失败:', err);
  2592. });
  2593. }
  2594. let pythoneditorshow = ref(false)
  2595. // Python窗口初始化
  2596. const initPython = (nowid) => {
  2597. console.log('Pythonchushihua');
  2598. pythoneditorshow.value = true; // 显示编辑器
  2599. pythonwid.value = nowid;
  2600. const param = {
  2601. transCode: 'MDO0036',
  2602. pid: pid.value,
  2603. wid: pythonwid.value
  2604. };
  2605. request(param).then((res) => {
  2606. console.log('Python:', res);
  2607. // 判断 res.ptython 是否为空,若不为空则赋值
  2608. if (res.ptython) {
  2609. console.log('Python内容:', res.ptython);
  2610. textarea1.value = res.ptython;
  2611. }
  2612. }).catch((err) => {
  2613. console.error('Python内容初始化失败');
  2614. });
  2615. };
  2616. // Python确认按钮提交
  2617. const pythonSubmit = () => {
  2618. console.log('Python确认按钮提交');
  2619. pythoneditorshow.value = false; // 隐藏编辑器
  2620. const param = {
  2621. transCode:'MDO0037',
  2622. pid: pid.value,
  2623. wid: pythonwid.value,
  2624. python: textarea1.value,
  2625. }
  2626. request(param).then((res) => {
  2627. ElMessage({
  2628. message: '保存成功',
  2629. type: 'success',
  2630. })
  2631. }).catch((err) => {
  2632. ElMessage.error('保存失败')
  2633. });
  2634. }
  2635. let MathFuncxinjian = ref(false)
  2636. const MathFunctabchange = (val) => {
  2637. // console.log('MathFunctabchange:',val);
  2638. if(val == '2'){
  2639. MathFuncxinjian.value = true;
  2640. }else{
  2641. MathFuncxinjian.value = false;
  2642. }
  2643. }
  2644. // 模块选择
  2645. const clickgeometry = (e, index, key, name) => {
  2646. // console.log(key);
  2647. // console.log('模块选择:',name);
  2648. tabactive.value = name;
  2649. // 逻辑流数据流增加选中
  2650. if(key==='Role10' || key==='Role11'){
  2651. active.value = key;
  2652. }
  2653. dialogbolen();
  2654. }
  2655. const dialogbolen = () => {
  2656. switch (tabactive.value) {
  2657. case "新建任务":
  2658. dialog.value.newdialog = true;
  2659. break;
  2660. case "问题设定":
  2661. dialog.value.setdialog = true;
  2662. break;
  2663. case "优化目标":
  2664. dialog.value.targetdialog = true;
  2665. break;
  2666. case "设计变量":
  2667. dialog.value.design = true;
  2668. break;
  2669. case "约束条件":
  2670. dialog.value.constraint = true;
  2671. break;
  2672. case "外形参数化":
  2673. dialog.value.parameter = true;
  2674. break;
  2675. case "代理模型":
  2676. dialog.value.agency = true;
  2677. break;
  2678. case "加点方法":
  2679. dialog.value.addfun = true;
  2680. break;
  2681. case "优化算法":
  2682. dialog.value.sufun = true;
  2683. break;
  2684. case "终止条件":
  2685. dialog.value.enddialog = true;
  2686. break;
  2687. case "任务管理":
  2688. dialog.value.task = true;
  2689. break;
  2690. case "任务检索":
  2691. dialog.value.guanli = true;
  2692. break;
  2693. case "选择连线颜色":
  2694. showTrigger.value = true;
  2695. break;
  2696. case "逻辑流连线":
  2697. vuefval.value.linestrokeWidth('process');
  2698. break;
  2699. case "数据流连线":
  2700. vuefval.value.linestrokeWidth('data');
  2701. break;
  2702. case "模块组合":
  2703. vuefval.value.bgcolorfunc(colortier.value);
  2704. vuefval.value.onSelection();
  2705. break;
  2706. case "开始":
  2707. // optmonitor1.value.echatinit();
  2708. // processMonitor1ref.value.echatinit();
  2709. // processMonitor1ref.value.echatinit();
  2710. runok();
  2711. break;
  2712. case "列表监控":
  2713. ifjiankong();
  2714. listtableInit();
  2715. break;
  2716. case "曲线监控":
  2717. ifjiankong()
  2718. curveLine();
  2719. break;
  2720. case "过程监控":
  2721. ifjiankong()
  2722. curveLine2();
  2723. curveLine3();
  2724. break;
  2725. case "列表":
  2726. echatsfunc();
  2727. dialog.value.listdialog = true;
  2728. nextTick(() => {
  2729. initListSe();
  2730. });
  2731. break;
  2732. case "面积图":
  2733. echatsfunc();
  2734. // curveLine4();
  2735. break;
  2736. case "饼状图":
  2737. echatsfunc();
  2738. break;
  2739. case "柱状图":
  2740. echatsfunc();
  2741. break;
  2742. case "折线图":
  2743. dialog.value.echartLinedialog = true;
  2744. echatsfunc();
  2745. // curveLine4();
  2746. nextTick(() => {
  2747. initListSe();
  2748. });
  2749. break;
  2750. case "散点图":
  2751. // logsget();
  2752. dialog.value.scatterdialog = true;
  2753. echatsfunc();
  2754. // curveLine4();
  2755. nextTick(() => {
  2756. initListSe();
  2757. });
  2758. break;
  2759. case "横条图":
  2760. echatsfunc();
  2761. break;
  2762. case "雷达图":
  2763. //logsget();
  2764. echatsfunc();
  2765. break;
  2766. case "帕雷托图":
  2767. dialog.value.paretodialog = true;
  2768. echatsfunc();
  2769. break;
  2770. case "云图/等值线":
  2771. dialog.value.clouddialog = true;
  2772. break;
  2773. case "查看报告":
  2774. echatsfunc();
  2775. dialog.value.lookover = true;
  2776. break;
  2777. case "导出报告":
  2778. dialog.value.exportreport = true;
  2779. break;
  2780. default:
  2781. }
  2782. }
  2783. // 可视化清空
  2784. const echartclear = () => {
  2785. arearef.value.echatinit();
  2786. bargraphref.value.echatinit();
  2787. echartLineref.value.echatinit();
  2788. BarChartref.value.echatinit();
  2789. radarref.value.echatinit();
  2790. scatterref.value.echatinit();
  2791. pieref.value.echatinit();
  2792. paretoref.value.echatinit();
  2793. }
  2794. const echatsfunc = () => {
  2795. //echartzongshow.value=true;
  2796. // echartclear();
  2797. switch (tabactive.value) {
  2798. case "列表":
  2799. tablelistshow.value = true;
  2800. areashow.value = false;
  2801. bargraphshow.value = false;
  2802. echartLineshow.value = false;
  2803. BarChartshow.value = false;
  2804. radarshow.value = false;
  2805. scattershow.value = false;
  2806. pieshow = false;
  2807. paretoshow =false;
  2808. break;
  2809. case "面积图":
  2810. tablelistshow.value = false;
  2811. areashow.value = true;
  2812. bargraphshow.value = false;
  2813. echartLineshow.value = false;
  2814. BarChartshow.value = false;
  2815. radarshow.value = false;
  2816. scattershow.value = false;
  2817. pieshow = false;
  2818. paretoshow =false;
  2819. break;
  2820. case "柱状图":
  2821. tablelistshow.value = false;
  2822. areashow.value = false;
  2823. bargraphshow.value = true;
  2824. echartLineshow.value = false;
  2825. BarChartshow.value = false;
  2826. radarshow.value = false;
  2827. scattershow.value = false;
  2828. pieshow = false;
  2829. paretoshow = false;
  2830. break;
  2831. case "饼状图":
  2832. tablelistshow.value = false;
  2833. areashow.value = false;
  2834. bargraphshow.value = false;
  2835. echartLineshow.value = false;
  2836. BarChartshow.value = false;
  2837. radarshow.value = false;
  2838. scattershow.value = false;
  2839. pieshow = true;
  2840. paretoshow = false;
  2841. break;
  2842. case "折线图":
  2843. tablelistshow.value = false;
  2844. areashow.value = false;
  2845. bargraphshow.value = false;
  2846. echartLineshow.value = true;
  2847. BarChartshow.value = false;
  2848. radarshow.value = false;
  2849. scattershow.value = false;
  2850. pieshow = false;
  2851. paretoshow = false;
  2852. break;
  2853. case "散点图":
  2854. tablelistshow.value = false;
  2855. areashow.value = false;
  2856. bargraphshow.value = false;
  2857. echartLineshow.value = false;
  2858. BarChartshow.value = false;
  2859. radarshow.value = false;
  2860. scattershow.value = true;
  2861. pieshow = false;
  2862. paretoshow = false;
  2863. break
  2864. case "横条图":
  2865. tablelistshow.value = false;
  2866. areashow.value = false;
  2867. bargraphshow.value = false;
  2868. echartLineshow.value = false;
  2869. BarChartshow.value = true;
  2870. radarshow.value = false;
  2871. scattershow.value = false;
  2872. pieshow = false;
  2873. paretoshow = false;
  2874. break
  2875. case "雷达图":
  2876. tablelistshow.value = false;
  2877. areashow.value = false;
  2878. bargraphshow.value = false;
  2879. echartLineshow.value = false;
  2880. BarChartshow.value = false;
  2881. radarshow.value = true;
  2882. scattershow.value = false;
  2883. pieshow = false;
  2884. paretoshow = false;
  2885. break
  2886. case "帕雷托图":
  2887. tablelistshow.value = false;
  2888. areashow.value = false;
  2889. bargraphshow.value = false;
  2890. echartLineshow.value = false;
  2891. BarChartshow.value = false;
  2892. radarshow.value = false;
  2893. scattershow.value = false;
  2894. pieshow = false;
  2895. paretoshow = true;
  2896. break
  2897. default:
  2898. tablelistshow.value = false;
  2899. areashow.value = false;
  2900. bargraphshow.value = false;
  2901. echartLineshow.value = false;
  2902. BarChartshow.value = false;
  2903. radarshow.value = false;
  2904. scattershow.value = false;
  2905. pieshow = false;
  2906. paretoshow = false;
  2907. break
  2908. }
  2909. }
  2910. // 可视化结束
  2911. // ||activeName.value=='Three'&&tabactive.value=='开始'
  2912. const ifjiankong = () => {
  2913. if (activeName.value == 'Three' && tabactive.value == '列表监控' || activeName.value == 'Three' && tabactive.value == '开始') {
  2914. jiankong.value = true;
  2915. } else {
  2916. jiankong.value = false;
  2917. }
  2918. if (activeName.value == 'Three' && tabactive.value == '曲线监控' ) {
  2919. echartshow.value = true;
  2920. } else {
  2921. echartshow.value = false;
  2922. }
  2923. if (activeName.value == 'Three' && tabactive.value == '过程监控' ) {
  2924. echartshow2.value = true;
  2925. } else {
  2926. echartshow2.value = false;
  2927. }
  2928. }
  2929. // 求解
  2930. const runok = () => {
  2931. if(echartshow.value){
  2932. optmonitor1.value.echatinit();
  2933. }else if(echartshow2.value){
  2934. processMonitor1ref.value.echatinit();
  2935. processMonitor2ref.value.echatinit();
  2936. }
  2937. const params = {
  2938. transCode: 'MDO0039',
  2939. pid: pid.value,
  2940. }
  2941. request(params)
  2942. .then((res) => {
  2943. logs.value = '';
  2944. arrobj.value = [];
  2945. tabarr.value = [];
  2946. tableDatalieb.value = [];
  2947. tableHeaders.value = [];
  2948. ElMessage({
  2949. message: "开始运行",
  2950. type: 'success',
  2951. })
  2952. })
  2953. .catch((err) => {
  2954. ElMessage.error('运行失败')
  2955. })
  2956. }
  2957. const tableKey = ref(0);
  2958. const listtableInit = () => {
  2959. const params = {
  2960. transCode: 'MDO0021',
  2961. pid: pid.value,
  2962. type: 1,
  2963. }
  2964. request(params)
  2965. .then((res) => {
  2966. tableDatalieb.value = [];
  2967. tableKey.value++;
  2968. if (res.rows && res.rows.length > 0) {
  2969. // 遍历所有返回的条目
  2970. res.rows.forEach((row) => {
  2971. const { vars, vals } = row; // 获取每一行的 vars 和 vals
  2972. // 调用 tablefun 函数更新表格
  2973. tablefun1(vars, vals);
  2974. });
  2975. }
  2976. })
  2977. .catch((err) => {
  2978. ElMessage.error(err.returnMsg)
  2979. })
  2980. }
  2981. /**
  2982. * 解析 vals 数据,将 [ ] 解析成数组,其他数据保持原样
  2983. */
  2984. function parseVals(vals) {
  2985. let result = [];
  2986. let temp = "";
  2987. let inArray = false;
  2988. for (let char of vals) {
  2989. if (char === "[") {
  2990. inArray = true;
  2991. temp += char;
  2992. } else if (char === "]") {
  2993. inArray = false;
  2994. temp += char;
  2995. result.push(JSON.parse(temp.trim())); // 确保去除首尾空格后转换
  2996. temp = "";
  2997. } else if (char === " " && !inArray) {
  2998. if (temp.trim() !== "") { // 避免空字符串被加入
  2999. result.push(temp.trim());
  3000. }
  3001. temp = "";
  3002. } else {
  3003. temp += char;
  3004. }
  3005. }
  3006. if (temp.trim() !== "") {
  3007. result.push(temp.trim());
  3008. }
  3009. return result.filter(item => item !== ""); // 过滤掉空字符串
  3010. }
  3011. //曲线监控
  3012. const curveLine = () => {
  3013. const params = {
  3014. transCode: 'MDO0021',
  3015. pid: pid.value,
  3016. type: 1,
  3017. }
  3018. request(params)
  3019. .then((res) => {
  3020. curvedata.value = JSON.stringify(res.rows);
  3021. // console.log(curvedata.value);
  3022. optmonitor1.value.getshuju(curvedata.value);
  3023. // optmonitor1.value.getsockechart();
  3024. // arearef.value.getsockechart(curvedata.value);
  3025. // bargraphref.value.getsockechart(curvedata.value);
  3026. // echartLineref.value.getsockechart(curvedata.value);
  3027. // BarChartref.value.getsockechart(curvedata.value);
  3028. // radarref.value.getsockechart(curvedata.value);
  3029. // scatterref.value.getsockechart(curvedata.value);
  3030. // pieref.value.getsockechart(curvedata.value);
  3031. // paretoref.value.getsockechart(curvedata.value);
  3032. // optmonitor1.value.getecharts();
  3033. })
  3034. .catch((err) => {
  3035. ElMessage.error(err.returnMsg)
  3036. })
  3037. }
  3038. // 过程监控1
  3039. const curveLine2 = () => {
  3040. const params = {
  3041. transCode: 'MDO0021',
  3042. pid: pid.value,
  3043. type: 2,
  3044. }
  3045. request(params)
  3046. .then((res) => {
  3047. if (res.rows && res.rows.length > 0) {
  3048. curvedata.value = JSON.stringify(res.rows);
  3049. // console.log(curvedata.value);
  3050. processMonitor1ref.value.getshuju(curvedata.value);
  3051. }
  3052. })
  3053. .catch((err) => {
  3054. ElMessage.error(err.returnMsg)
  3055. })
  3056. }
  3057. // 过程监控2
  3058. const curveLine3 = () => {
  3059. const params = {
  3060. transCode: 'MDO0021',
  3061. pid: pid.value,
  3062. type: 3,
  3063. }
  3064. request(params)
  3065. .then((res) => {
  3066. // 检查返回的数据是否为空
  3067. if (res.rows && res.rows.length > 0) {
  3068. curvedata.value = JSON.stringify(res.rows);
  3069. // console.log(curvedata.value);
  3070. processMonitor2ref.value.getshuju(curvedata.value);
  3071. }
  3072. })
  3073. .catch((err) => {
  3074. // 错误处理
  3075. ElMessage.error(err.returnMsg);
  3076. })
  3077. }
  3078. // 可视化页数据
  3079. const curveLine4 = () => {
  3080. const params = {
  3081. transCode: 'MDO0021',
  3082. pid: pid.value,
  3083. type: 1,
  3084. }
  3085. request(params)
  3086. .then((res) => {
  3087. // curvedata.value = JSON.stringify(res.rows);
  3088. // console.log('数据形式:',curvedata.value);
  3089. // echartLineref.value.getshuju(curvedata.value);
  3090. // scatterref.value.getshuju(curvedata.value);
  3091. if (res.rows && res.rows.length > 0) {
  3092. // 清空数据
  3093. datatotabledata.value = [];
  3094. datatotableheader.value = [];
  3095. // 遍历返回的所有行数据
  3096. res.rows.forEach((row) => {
  3097. const { vars, vals } = row; // 解析 vars 和 vals
  3098. datatotable(vars, vals);
  3099. });
  3100. }
  3101. console.log("表格数据:", datatotabledata.value);
  3102. console.log("表头数据:", datatotableheader.value);
  3103. })
  3104. .catch((err) => {
  3105. ElMessage.error(err.returnMsg)
  3106. })
  3107. }
  3108. const initListSe = () => {
  3109. emitter.emit('update:datatotableheader', datatotableheader.value);
  3110. emitter.emit('update:datatotabledata', datatotabledata.value);
  3111. }
  3112. let datatotableheader = ref([]);
  3113. let datatotabledata = ref([]);
  3114. // 解析数据到表格
  3115. const datatotable = (vars, vals) => {
  3116. console.log("表格更新");
  3117. // 解析列名,vars 以空格分隔
  3118. let headers = vars.split(" ");
  3119. // 解析 vals 数据
  3120. let values = vals.split(" ");
  3121. // 构造表格数据对象
  3122. let rowData = {};
  3123. let newHeaders = [];
  3124. headers.forEach((key, index) => {
  3125. let val = values[index];
  3126. // 处理数组数据,解析为 JSON 或直接填充
  3127. if (val.startsWith("[") && val.endsWith("]")) {
  3128. try {
  3129. let parsedArray = JSON.parse(val); // 解析数组
  3130. // 解析数组数据并拆分为多个列
  3131. parsedArray.forEach((item, subIndex) => {
  3132. let newKey = `${key}_${subIndex + 1}`; // 生成列名:原列名_1, _2, _3...
  3133. rowData[newKey] = item;
  3134. // 只在第一次时添加新列
  3135. if (
  3136. datatotableheader.value.length === 0 ||
  3137. !datatotableheader.value.some((h) => h.prop === newKey)
  3138. ) {
  3139. newHeaders.push({ label: newKey, prop: newKey });
  3140. }
  3141. });
  3142. } catch (e) {
  3143. rowData[key] = val; // 解析失败,保留原始字符串
  3144. }
  3145. } else {
  3146. rowData[key] = val !== undefined ? val : ""; // 处理数据长度不匹配情况
  3147. // 只在第一次时添加原始列
  3148. if (
  3149. datatotableheader.value.length === 0 ||
  3150. !datatotableheader.value.some((h) => h.prop === key)
  3151. ) {
  3152. newHeaders.push({ label: key, prop: key });
  3153. }
  3154. }
  3155. });
  3156. // 更新表头:防止重复添加
  3157. if (datatotableheader.value.length === 0) {
  3158. datatotableheader.value = newHeaders;
  3159. } else {
  3160. newHeaders.forEach((header) => {
  3161. if (!datatotableheader.value.some((h) => h.prop === header.prop)) {
  3162. datatotableheader.value.push(header);
  3163. }
  3164. });
  3165. }
  3166. // 更新表格数据
  3167. datatotabledata.value.push(rowData);
  3168. };
  3169. let listcbval = ref([]);
  3170. let listcbval2 = ref([]);
  3171. // 选择框值更新
  3172. const handleUpdate = (name, value) => {
  3173. if (name === 'listcbval') {
  3174. listcbval.value = value;
  3175. console.log("listcbval:",listcbval.value);
  3176. } else if (name === 'listcbval2') {
  3177. listcbval2.value = value;
  3178. console.log("listcbval2:",listcbval2.value);
  3179. }
  3180. };
  3181. // 列表,散点,折线图选择数据==>曲线绘制
  3182. const selectshujuto = () => {
  3183. console.log("确认:",tabactive.value);
  3184. if(tabactive.value === '散点图'){
  3185. scatterref.value.selectshuju(listcbval.value,listcbval2.value,datatotableheader.value,datatotabledata.value);
  3186. }else if(tabactive.value === '折线图'){
  3187. echartLineref.value.selectshuju(listcbval.value,listcbval2.value,datatotableheader.value,datatotabledata.value);
  3188. }else if(tabactive.value === '列表'){
  3189. tablelistref.value.selectshuju(listcbval2.value)
  3190. }
  3191. }
  3192. //选择颜色改变线的颜色
  3193. const colorpicker = (e) => {
  3194. console.log("color change:",vuefval.value);
  3195. vuefval.value.changeAllEdgesColor(color1.value);
  3196. }
  3197. //选择颜色改变tuceng的颜色
  3198. const colorpickertier = (e) => {
  3199. //vuefval.value.changeAllEdgesColor(color1.value);
  3200. vuefval.value.bgcolorfunc(colortier.value);
  3201. }
  3202. const deviceSelectChange = () => {
  3203. }
  3204. const handleClose = (done) => {
  3205. console.log(111)
  3206. dialog.value.newdialog = false;
  3207. done();
  3208. };
  3209. const targetclick = () => {
  3210. console.log(tableData.value)
  3211. }
  3212. // 模块组合
  3213. const modelgroup=()=>{
  3214. }
  3215. //新增
  3216. const onAddItem = () => {
  3217. let tablevalnum = Number(tableval.value) > 1 ? Number(tableval.value) : 1
  3218. if (activeIndex2.value == 0) {
  3219. for (let i = 0; i < tablevalnum; i++) {
  3220. designtable.value.push({
  3221. name: `x${i + 1}`,
  3222. upper: null,
  3223. lower: null,
  3224. reference: null,
  3225. remark: ''
  3226. })
  3227. }
  3228. } else if (activeIndex2.value == 1) {
  3229. for (let i = 0; i < tablevalnum; i++) {
  3230. tableData.value.push({
  3231. name: `g${i + 1}`,
  3232. con: -1,
  3233. reference: null,
  3234. upper: 0,
  3235. lower: 0,
  3236. })
  3237. }
  3238. } else if (activeIndex2.value == 2) {
  3239. for (let i = 0; i < tablevalnum; i++) {
  3240. eloptimize.value.push({
  3241. name: `c${i + 1}`,
  3242. optdir: '1',
  3243. weight: 0,
  3244. scaling: 0,
  3245. factor: 0,
  3246. reference: null,
  3247. remark: '',
  3248. })
  3249. }
  3250. }
  3251. }
  3252. const xxclick = (index) => {
  3253. activeIndex.value = index
  3254. if (activeIndex.value == 0) {
  3255. } else if (activeIndex.value == 1) {
  3256. getissue();
  3257. }
  3258. }
  3259. //底部优化问题
  3260. const issueclick = (index) => {
  3261. activeIndex2.value = index;
  3262. if (activeIndex2.value == 0) {
  3263. getissue();
  3264. } else if (activeIndex2.value == 1) {
  3265. getyueshu();
  3266. } else if (activeIndex2.value == 2) {
  3267. getmub();
  3268. }
  3269. }
  3270. //设计变量查询
  3271. const getissue = () => {
  3272. //let childernarr=[];
  3273. const params = {
  3274. transCode: 'MDO0022',
  3275. pid: pid.value,
  3276. }
  3277. request(params)
  3278. .then((res) => {
  3279. if (res.rows.length === 0) {
  3280. } else {
  3281. let item1 = {
  3282. id: "1-1-" + 1,
  3283. label: '设计变量',
  3284. img: q2,
  3285. children: []
  3286. }
  3287. let arr = Sidebarref.value.datatree[0].children[0].children;
  3288. let result = arr.find(element => element.id === item1.id);
  3289. console.log(result);
  3290. if (!result) {
  3291. Sidebarref.value.datatree[0].children[0].children.push(item1);
  3292. }
  3293. let childernarr=Sidebarref.value.datatree[0].children[0].children
  3294. Sidebarref.value.datatree[0].children[0].children.forEach((item,index)=>{
  3295. if(item.label=='设计变量'){
  3296. Sidebarref.value.datatree[0].children[0].children[index].children=[];
  3297. }
  3298. })
  3299. res.rows = res.rows.map((item, index) => {
  3300. item.lower = item.lower ?? 'none'
  3301. item.upper = item.upper ?? 'none'
  3302. item.reference = item.reference ?? 'none'
  3303. item.name = item.name ?? 'none'
  3304. item.remark = item.remark ?? 'none'
  3305. treeitem.value = {
  3306. id: "1-1-1-" + index,
  3307. label: item.name,
  3308. img: f21,
  3309. }
  3310. // console.log(Sidebarref.value.datatree[0].children[0].children[0].children)
  3311. childernarr.forEach((item,index)=>{
  3312. if(item.label=='设计变量'){
  3313. let addnode = Sidebarref.value.datatree[0].children[0].children[index].children.push(treeitem.value);
  3314. }
  3315. })
  3316. return item;
  3317. })
  3318. designtable.value = res.rows;
  3319. }
  3320. })
  3321. .catch((err) => {
  3322. ElMessage.error(err.returnMsg)
  3323. })
  3324. // }
  3325. // })
  3326. }
  3327. //约束条件查询
  3328. const getyueshu = () => {
  3329. const params = {
  3330. transCode: 'MDO0023',
  3331. pid: pid.value,
  3332. }
  3333. request(params)
  3334. .then((res) => {
  3335. if (res.rows.length === 0) {
  3336. } else {
  3337. let item2 = {
  3338. id: "1-2-" + 2,
  3339. label: '约束条件',
  3340. img: f22,
  3341. children: []
  3342. }
  3343. let arr = Sidebarref.value.datatree[0].children[0].children;
  3344. let result = arr.find(element => element.id === item2.id);
  3345. if (!result) {
  3346. Sidebarref.value.datatree[0].children[0].children.push(item2);
  3347. }
  3348. Sidebarref.value.datatree[0].children[0].children.forEach((item, index) => {
  3349. if (item.label == '约束条件') {
  3350. Sidebarref.value.datatree[0].children[0].children[index].children = [];
  3351. }
  3352. });
  3353. let childernarr = Sidebarref.value.datatree[0].children[0].children;
  3354. res.rows = res.rows.map((item, index) => {
  3355. // 确保转换为数字
  3356. item.con = item.con ?? 'none';
  3357. item.reference = item.reference ?? 'none';
  3358. item.upper =item.upper ?? 'none';
  3359. item.lower = item.lower ?? 'none';
  3360. console.log('item:', item);
  3361. treeitem2.value = {
  3362. id: "1-2-2-" + index,
  3363. label: item.name,
  3364. img: f21,
  3365. }
  3366. childernarr.forEach((item, index) => {
  3367. if (item.label == '约束条件') {
  3368. let addnode = Sidebarref.value.datatree[0].children[0].children[index].children.push(treeitem2.value);
  3369. }
  3370. });
  3371. return item;
  3372. });
  3373. tableData.value = res.rows; // 更新表格数据
  3374. }
  3375. })
  3376. .catch((err) => {
  3377. ElMessage.error(err.returnMsg);
  3378. })
  3379. }
  3380. //目标函数查询
  3381. const getmub = () => {
  3382. const params = {
  3383. transCode: 'MDO0024',
  3384. pid: pid.value,
  3385. }
  3386. request(params)
  3387. .then((res) => {
  3388. if (res.rows.length === 0) {
  3389. } else {
  3390. let item2 = {
  3391. id: "1-3-" + 3,
  3392. label: '目标函数',
  3393. img: f41,
  3394. children: []
  3395. }
  3396. let arr = Sidebarref.value.datatree[0].children[0].children;
  3397. let result = arr.find(element => element.id === item2.id);
  3398. if (!result) {
  3399. Sidebarref.value.datatree[0].children[0].children.push(item2);
  3400. }
  3401. Sidebarref.value.datatree[0].children[0].children.forEach((item,index)=>{
  3402. if(item.label=='目标函数'){
  3403. Sidebarref.value.datatree[0].children[0].children[index].children=[];
  3404. }
  3405. })
  3406. let childernarr=Sidebarref.value.datatree[0].children[0].children
  3407. res.rows = res.rows.map((item, index) => {
  3408. item.optdir = item.optdir ?? 'none';
  3409. item.weight = item.weight ?? 'none';
  3410. item.scaling = item.scaling ?? 'none';
  3411. item.factor = item.factor ?? 'none';
  3412. item.reference = item.reference ?? 'none';
  3413. item.remark = item.remark ?? 'none';
  3414. item.name = item.name ?? 'none';
  3415. treeitem3.value = {
  3416. id: "1-3-3-" + index,
  3417. label: item.name,
  3418. img: f21,
  3419. }
  3420. childernarr.forEach((item,index)=>{
  3421. if(item.label=='目标函数'){
  3422. let addnode = Sidebarref.value.datatree[0].children[0].children[index].children.push(treeitem3.value);
  3423. }
  3424. })
  3425. // console.log(11111)
  3426. // let addnode = Sidebarref.value.datatree[0].children[0].children[3].children.push(treeitem3.value);
  3427. return item;
  3428. })
  3429. eloptimize.value = res.rows;
  3430. }
  3431. })
  3432. .catch((err) => {
  3433. ElMessage.error(err.returnMsg)
  3434. })
  3435. }
  3436. //对象数组转化字符串
  3437. const getarr = (name, arrays) => {
  3438. console.log(arrays)
  3439. for (let i = 0; i < arrays.length; i++) {
  3440. let arr = [];
  3441. let att = [];
  3442. for (const key in arrays[i]) {
  3443. if (arrays[i].hasOwnProperty(key)) {
  3444. arr.push(arrays[i][key]);
  3445. }
  3446. }
  3447. for (let j = 0; j < arr.length; j++) {
  3448. if (typeof arr[j] === 'string' && arr[j] == "") {
  3449. console.log(11111)
  3450. arr[j] = " ";
  3451. }
  3452. }
  3453. if (arrays[i].hasOwnProperty('pid') == true) {
  3454. att = arr.slice(1, -1);
  3455. } else {
  3456. att = arr;
  3457. }
  3458. const valuesWithSemiColons = att.join(',');
  3459. name += valuesWithSemiColons + ';';
  3460. }
  3461. console.log('conlist',name)
  3462. return name;
  3463. }
  3464. const convertToStringArray = (result, Data) => {
  3465. console.log('Data:', Data);
  3466. result = Data.map(row => {
  3467. const vid = row.vid || ' ';
  3468. const name = row.name || ' ';
  3469. const upper = row.upper ?? ' ';
  3470. const lower = row.lower ?? ' ';
  3471. const reference = row.reference ?? ' ';
  3472. const remark = row.remark || ' ';
  3473. // 将字段连接为一个以逗号分隔的字符串
  3474. return `${vid},${name},${upper},${lower},${reference},${remark}`;
  3475. }).join(';'); // 每行之间用分号分隔
  3476. return result;
  3477. }
  3478. const convertToStringArray1 = (result, Data) => {
  3479. console.log('Data:', Data);
  3480. result = Data.map(row => {
  3481. const conid = row.conid || ' ';
  3482. const name = row.name || ' ';
  3483. const upper = row.upper ?? ' ';
  3484. const lower = row.lower ?? ' ';
  3485. const reference = row.reference ?? ' ';
  3486. // 将字段连接为一个以逗号分隔的字符串
  3487. return `${conid},${name},${reference},${upper},${lower}`;
  3488. }).join(';'); // 每行之间用分号分隔
  3489. return result;
  3490. }
  3491. const convertToStringArray2 = (result, Data) => {
  3492. console.log('Data:', Data);
  3493. result = Data.map(row => {
  3494. const fid = row.fid || ' ';
  3495. const name = row.name || ' ';
  3496. const optdir = row.optdir ?? ' ';
  3497. const weight = row.weight ?? ' ';
  3498. const reference = row.reference ?? ' ';
  3499. const remark = row.remark || ' ';
  3500. // 将字段连接为一个以逗号分隔的字符串
  3501. return `${fid},${name},${optdir},${weight},${reference},${remark}`;
  3502. }).join(';'); // 每行之间用分号分隔
  3503. return result;
  3504. }
  3505. //保存优化问题
  3506. const onokItem = () => {
  3507. console.log(activeIndex2.value);
  3508. if (activeIndex2.value == 0) {
  3509. svarlist.value = '';
  3510. console.log("designtable:",designtable.value)
  3511. svarlist.value = convertToStringArray(svarlist.value, designtable.value)
  3512. devise();
  3513. } else if (activeIndex2.value == 1) {
  3514. conlist.value = '';
  3515. console.log("tabledata:",tableData.value)
  3516. conlist.value = convertToStringArray1(conlist.value, tableData.value)
  3517. restrain();
  3518. } else if (activeIndex2.value == 2) {
  3519. funlist.value = '';
  3520. console.log("eloptimize:",eloptimize.value)
  3521. funlist.value = convertToStringArray2(funlist.value, eloptimize.value)
  3522. funlistaa();
  3523. }
  3524. }
  3525. //设计变量的添加
  3526. const devise = () => {
  3527. const params = {
  3528. transCode: 'MDO0054',
  3529. pid: pid.value,
  3530. vartr: svarlist.value
  3531. }
  3532. request(params)
  3533. .then((res) => {
  3534. ElMessage({
  3535. message: '设计变量保存成功',
  3536. type: 'success',
  3537. })
  3538. getissue();
  3539. })
  3540. .catch((err) => {
  3541. ElMessage.error('设计变量保存失败')
  3542. })
  3543. }
  3544. //约束的添加restrain
  3545. const restrain = () => {
  3546. const params = {
  3547. transCode: 'MDO0055',
  3548. pid: pid.value,
  3549. vartr: conlist.value
  3550. }
  3551. request(params)
  3552. .then((res) => {
  3553. ElMessage({
  3554. message: '约束条件保存成功',
  3555. type: 'success',
  3556. })
  3557. getyueshu();
  3558. })
  3559. .catch((err) => {
  3560. ElMessage.error('约束条件保存失败')
  3561. })
  3562. }
  3563. //优化目标接口
  3564. const funlistaa = () => {
  3565. const params = {
  3566. transCode: 'MDO0056',
  3567. pid: pid.value,
  3568. vartr: funlist.value
  3569. }
  3570. request(params)
  3571. .then((res) => {
  3572. ElMessage({
  3573. message: '优化目标保存成功',
  3574. type: 'success',
  3575. })
  3576. getmub();
  3577. })
  3578. .catch((err) => {
  3579. ElMessage.error('优化目标保存失败')
  3580. })
  3581. }
  3582. //初始化
  3583. const initialize = () => {
  3584. const params = {
  3585. transCode: 'MDO0011',
  3586. pid: pid.value,
  3587. }
  3588. request(params)
  3589. .then((res) => {
  3590. // ElMessage({
  3591. // message: res.returnMsg,
  3592. // type: 'success',
  3593. // })
  3594. importget();
  3595. })
  3596. .catch((err) => {
  3597. ElMessage.error(err.returnMsg)
  3598. })
  3599. }
  3600. // new输入参数
  3601. const changecheck = (val,row) => {
  3602. console.log(val);
  3603. console.log(row);
  3604. }
  3605. //输入参数查询
  3606. const importget = () => {
  3607. const params = {
  3608. transCode: 'MDO0012',
  3609. pid: pid.value,
  3610. }
  3611. request(params)
  3612. .then((res) => {
  3613. srtable.value = res.rows;
  3614. })
  3615. .catch((err) => {
  3616. ElMessage.error(err.returnMsg)
  3617. })
  3618. }
  3619. //输入保存
  3620. const susave = (index, row) => {
  3621. console.log(row);
  3622. const params = {
  3623. transCode: 'MDO0013',
  3624. pid: pid.value,
  3625. inid: row.inid,
  3626. vid: row.vid,
  3627. enable: row.enable,
  3628. name: row.name,
  3629. v1: row.v1,
  3630. v2: row.v2
  3631. }
  3632. request(params)
  3633. .then((res) => {
  3634. ElMessage({
  3635. message: '保存成功',
  3636. type: 'success',
  3637. })
  3638. })
  3639. .catch((err) => {
  3640. ElMessage.error(err.returnMsg)
  3641. })
  3642. }
  3643. // 输入的删除
  3644. const sudelete = (index, row) => {
  3645. if (row.hasOwnProperty('outid') == false) {
  3646. srtable.value.splice(index, 1)
  3647. } else {
  3648. const params = {
  3649. transCode: 'MDO0014',
  3650. inid: row.inid,
  3651. }
  3652. request(params)
  3653. .then((res) => {
  3654. importget();
  3655. ElMessage({
  3656. message: " 删除成功",
  3657. type: 'success',
  3658. })
  3659. })
  3660. .catch((err) => {
  3661. ElMessage.error(err.returnMsg)
  3662. })
  3663. }
  3664. }
  3665. //输入输出的新建
  3666. const newxfiol = () => {
  3667. if (activeIndex3.value == 0) {
  3668. srtable.value.push({
  3669. name: "",
  3670. v1: '0',
  3671. v2: '0',
  3672. enable: '0'
  3673. })
  3674. } else if (activeIndex3.value == 2) {
  3675. sctable.value.push({
  3676. name: "",
  3677. v1: '',
  3678. v2: '',
  3679. enable: '0'
  3680. })
  3681. }
  3682. }
  3683. // 点击掉查询接口
  3684. const dianjia = (index) => {
  3685. activeIndex3.value = index;
  3686. if (activeIndex3.value == 0) {
  3687. importget()
  3688. } else if (activeIndex3.value == 2) {
  3689. console.log(11111)
  3690. exportget();
  3691. }
  3692. }
  3693. //输出参数查询
  3694. const exportget = () => {
  3695. const params = {
  3696. transCode: 'MDO0015',
  3697. pid: pid.value,
  3698. }
  3699. request(params)
  3700. .then((res) => {
  3701. sctable.value = res.rows;
  3702. })
  3703. .catch((err) => {
  3704. ElMessage.error(err.returnMsg)
  3705. })
  3706. }
  3707. // 输出保存
  3708. const scsave = (index, row) => {
  3709. if (row.hasOwnProperty('fid') == true) {
  3710. fid.value = row.fid;
  3711. }
  3712. if (row.hasOwnProperty('conid') == true) {
  3713. conid.value = row.conid;
  3714. }
  3715. const params = {
  3716. transCode: 'MDO0016',
  3717. pid: pid.value,
  3718. outid: row.outid,
  3719. fid: fid.value,
  3720. conid: conid.value,
  3721. enable: row.enable,
  3722. name: row.name,
  3723. v1: row.v1,
  3724. v2: row.v2
  3725. }
  3726. request(params)
  3727. .then((res) => {
  3728. ElMessage({
  3729. message: '保存成功',
  3730. type: 'success',
  3731. })
  3732. exportget();
  3733. })
  3734. .catch((err) => {
  3735. ElMessage.error(err.returnMsg)
  3736. })
  3737. }
  3738. //输出删除scdelete
  3739. const scdelete = (index, row) => {
  3740. console.log(row);
  3741. if (row.hasOwnProperty('outid') == false) {
  3742. sctable.value.splice(index, 1)
  3743. } else {
  3744. const params = {
  3745. transCode: 'MDO0017',
  3746. outid: row.outid,
  3747. }
  3748. request(params)
  3749. .then((res) => {
  3750. exportget();
  3751. ElMessage({
  3752. message: " 删除成功",
  3753. type: 'success',
  3754. })
  3755. })
  3756. .catch((err) => {
  3757. ElMessage.error(err.returnMsg)
  3758. })
  3759. }
  3760. }
  3761. // 用于实时更新表格数据
  3762. function tablefun(vars, vals) {
  3763. console.log('表格更新');
  3764. // 解析列名,vars 以空格分隔
  3765. let headers = vars.split(" ");
  3766. // 更新表头
  3767. tableHeaders.value = headers.map(item => ({ label: item, prop: item }));
  3768. // 构造表格数据对象
  3769. let rowData = {};
  3770. headers.forEach((key, index) => {
  3771. rowData[key] = vals[index] !== undefined ? vals[index] : ""; // 处理数据长度不匹配情况
  3772. });
  3773. // 更新表格数据
  3774. tableDatalieb.value.push(rowData);
  3775. }
  3776. // 用于更新表格数据
  3777. const tablefun1 = (vars, vals) => {
  3778. console.log('表格更新');
  3779. // 解析列名,vars 以空格分隔
  3780. let headers = vars.split(" ");
  3781. // 更新表头
  3782. tableHeaders.value = headers.map(item => ({ label: item, prop: item }));
  3783. // 解析 vals 为数组(假设 vals 是一个字符串)
  3784. let values = vals.split(" ");
  3785. // 构造表格数据对象
  3786. let rowData = {};
  3787. headers.forEach((key, index) => {
  3788. rowData[key] = values[index] !== undefined ? values[index] : ""; // 处理数据长度不匹配情况
  3789. });
  3790. // 更新表格数据
  3791. tableDatalieb.value.push(rowData);
  3792. };
  3793. //获取日志
  3794. const logsget = () => {
  3795. const params = {
  3796. transCode: 'MDO0025',
  3797. pid: pid.value,
  3798. }
  3799. request(params)
  3800. .then((res) => {
  3801. // 去除空行
  3802. console.log('日志接口赋值')
  3803. logs.value = res.logs.split('\n').filter(line => line.trim() !== '').join('\n');
  3804. const results = extractBracesContent(logs.value);
  3805. for (let i = 0; i < results.length; i++) {
  3806. arrobj.value.push(results[i]);
  3807. let vals = (results[i].vals).split(" ");
  3808. tablefun(vals);
  3809. let echarr = [];
  3810. echarr.push(results[i])
  3811. optmonitor1.value.getsockechart(echarr);
  3812. processMonitor1ref.value.getsockechart(echarr);
  3813. processMonitor2ref.value.getsockechart(echarr);
  3814. // arearef.value.getsockechart(echarr);
  3815. // bargraphref.value.getsockechart(echarr);
  3816. // echartLineref.value.getsockechart(echarr);
  3817. // BarChartref.value.getsockechart(echarr);
  3818. // radarref.value.getsockechart(echarr);
  3819. // scatterref.value.getsockechart(echarr);
  3820. }
  3821. })
  3822. .catch((err) => {
  3823. ElMessage.error(err.returnMsg)
  3824. })
  3825. }
  3826. // 字符串截取
  3827. function extractBracesContent(str) {
  3828. const objectRegex = /\{[^}]+\}/g; // 匹配大括号对象
  3829. const matches = str.match(objectRegex);
  3830. if (!matches) return [];
  3831. return matches.map(match => {
  3832. try {
  3833. return JSON.parse(match);
  3834. } catch (e) {
  3835. console.error('Failed to parse object:', match);
  3836. return null;
  3837. }
  3838. }).filter(Boolean); // 过滤掉解析失败的对象
  3839. }
  3840. function convertToPercentage(number) {
  3841. return (number * 100);
  3842. }
  3843. const handlePercentage = (val) => {
  3844. console.log("步数设置:",val),
  3845. percentageTotalstep.value = val;
  3846. }
  3847. //websockct的连接
  3848. function initWebSocket() {
  3849. //初始化weosocket
  3850. // const wsuri = "ws://192.168.0.43:8087//websocket?projectId="+this.pid; ws://192.168.0.131/diswebsocket?projectId=5
  3851. // const wsurl = "ws://192.168.108:8188//websocket?projectId=" + pid.value;
  3852. const wsurl = import.meta.env.VITE_WEBSOCKET_URL + pid.value;
  3853. // const wsurl =
  3854. // "ws://" +
  3855. // process.env.VUE_APP_BASE_websokt +
  3856. // "/diswebsocket?projectId=" +'5'
  3857. // aid.value;
  3858. websock = new WebSocket(wsurl);
  3859. websock.onopen = websocketonopen;
  3860. websock.onmessage = websocketonmessage;
  3861. websock.onerror = websocketonerror;
  3862. websock.onclose = websocketclose;
  3863. }
  3864. // Websoket连接成功事件
  3865. const websocketonopen = (res) => {
  3866. console.log("WebSocket连接成功", res);
  3867. console.log()
  3868. start();
  3869. };
  3870. // Websoket接收消息事件
  3871. const websocketonmessage = (res) => {
  3872. // console.log('websocket接受消息:',res.data)
  3873. arrobj.value = [];
  3874. if (res.data.indexOf('{') !== -1) {
  3875. progressshow.value = true;
  3876. console.log('websocket接受消息:',res.data)
  3877. // 解析 WebSocket 接收到的消息数据
  3878. let parsedData = JSON.parse(res.data);
  3879. let step = Number(parsedData.step);
  3880. console.log('步数:',step)
  3881. if(parsedData.type === 1){
  3882. console.log('总步数:',percentageTotalstep.value)
  3883. percentage.value = Math.round((step / percentageTotalstep.value) * 100);
  3884. }
  3885. console.log("进度:", percentage.value);
  3886. echartdata.value = res.data;
  3887. arrobj.value.push(parsedData);
  3888. console.log('tabactive:',tabactive.value)
  3889. if(jiankong.value && parsedData.type === 1){
  3890. console.log('列表监控')
  3891. tablefun1(parsedData.vars, parsedData.vals); // 传递 vars 和 vals 更新表格
  3892. }else if(echartshow.value&&parsedData.type === 1){
  3893. optmonitor1.value.getsockechart(arrobj.value);
  3894. }else if(echartshow2.value&&parsedData.type === 2){
  3895. processMonitor1ref.value.getsockechart(arrobj.value);
  3896. }else if(echartshow2.value&&parsedData.type === 3){
  3897. processMonitor2ref.value.getsockechart(arrobj.value);
  3898. }
  3899. // 新增:记录结构化 JSON 数据到日志
  3900. const cleanedJsonLog = res.data.split('\n').filter(line => line.trim() !== '').join('\n');
  3901. logs.value = logs.value + '\n' + cleanedJsonLog;
  3902. // 自动滚动日志到底部
  3903. let textarea = document.getElementById("textarea_id");
  3904. textarea.scrollTop = textarea.scrollHeight;
  3905. } else {
  3906. if (res.data.indexOf('——成功') !== -1) {
  3907. const timer = setTimeout(function () {
  3908. progressshow.value = false;
  3909. console.log('关闭定时器')
  3910. }, 10000)
  3911. // console.log(22222)
  3912. // clearTimeout(timer);
  3913. }
  3914. if (res.data.indexOf('msg=heartChec') == -1) {
  3915. // 去除空行
  3916. const cleanedLog = res.data.split('\n').filter(line => line.trim() !== '').join('\n');
  3917. logs.value = logs.value + '\n' + cleanedLog;
  3918. let textarea = document.getElementById("textarea_id");
  3919. textarea.scrollTop = textarea.scrollHeight;
  3920. }
  3921. }
  3922. reset();
  3923. };
  3924. // Websoket连接错误事件
  3925. const websocketonerror = (res) => {
  3926. console.log("连接错误", res);
  3927. websock.close();
  3928. reconnect();
  3929. };
  3930. // Websoket断开事件
  3931. const websocketclose = (res) => {
  3932. console.log("断开连接", res);
  3933. };
  3934. // 创建 websocket 的实例
  3935. // 心跳包
  3936. const reconnect = () => {
  3937. if (times.value.lockReconnect) return;
  3938. times.value.lockReconnect = true;
  3939. //没连接上会一直重连,设置延迟避免请求过多
  3940. times.value.timeoutnum && clearTimeout(times.value.timeoutnum);
  3941. times.value.timeoutnum = setTimeout(function () {
  3942. //新连接
  3943. initWebSocket();
  3944. times.value.lockReconnect = false;
  3945. }, 10000);
  3946. }
  3947. const reset = () => {
  3948. //重置心跳
  3949. clearTimeout(times.value.timeoutObj);
  3950. clearTimeout(times.value.serverTimeoutObj);
  3951. start();
  3952. }
  3953. const start = () => {
  3954. //开启心跳
  3955. times.value.timeoutObj && clearTimeout(times.value.timeoutObj);
  3956. times.value.serverTimeoutObj && clearTimeout(times.value.serverTimeoutObj);
  3957. times.value.timeoutObj = setTimeout(function () {
  3958. //这里发送一个心跳,后端收到后,返回一个心跳消息
  3959. if (websock.readyState == 1) {
  3960. //如果连接正常
  3961. websock.send("heartCheck");
  3962. } else {
  3963. //否则重连
  3964. reconnect();
  3965. }
  3966. times.value.serverTimeoutObj = setTimeout(function () {
  3967. // 超时关闭
  3968. websock.close(); //如果onclose会执行reconnect,我们执行ws.close()就行了.如果直接执行reconnect 会触发onclose导致重连两次
  3969. }, times.value.timeout);
  3970. }, times.value.timeout);
  3971. }
  3972. // 日志框
  3973. // 日志的文本框
  3974. const footerShows = (evt) => {
  3975. if (evt == "claer") {
  3976. logs.value = "";
  3977. } else {
  3978. footerShow.value = !footerShow.value;
  3979. }
  3980. }
  3981. // watch(() =>echartdata.value, (newValue, oldValue) => {
  3982. // // 这里处理 echartData 变化的逻辑
  3983. // console.log('echartData changed:', newValue);
  3984. // // console.log(optmonitor1.value);
  3985. // });
  3986. // 选项卡
  3987. const selectTab=(index)=>{
  3988. currentTab.value = index;
  3989. }
  3990. const adfhandleClick=(tab,event)=>{
  3991. console.log('表单切换',tab.props.label);
  3992. activeadf.value=tab.props.label;
  3993. if(tab.props.name === '进化优化器'){
  3994. nextTick(() => {
  3995. // 确保 ref 已经初始化
  3996. if (Joptimizeref.value) {
  3997. // 调用 Joptimize 的 getoptimize 方法
  3998. Joptimizeref.value.getoptimize(pid.value,youhuaqiwid.value);
  3999. }
  4000. });
  4001. }else if(tab.props.name === '代理优化器'){
  4002. nextTick(() => {
  4003. // 确保 ref 已经初始化
  4004. if (Doptimizeref.value) {
  4005. Doptimizeref.value.getDoptimize(pid.value,youhuaqiwid.value);
  4006. }
  4007. });
  4008. }else if(tab.props.name === '梯度优化器'){
  4009. nextTick(() => {
  4010. // 确保 ref 已经初始化
  4011. if (Toptimizeref.value) {
  4012. Toptimizeref.value.getToptimize(pid.value,youhuaqiwid.value);
  4013. }
  4014. });
  4015. }
  4016. }
  4017. const getaddsave = (nowid) => {
  4018. if (Joptimizeref.value && typeof Joptimizeref.value.getaddsave === 'function') {
  4019. if(nowid){
  4020. Joptimizeref.value.getaddsave(pid.value,nowid);
  4021. }else{
  4022. Joptimizeref.value.getaddsave(pid.value);
  4023. }
  4024. }
  4025. }
  4026. const getDaddsave = (nowid) => {
  4027. if (Doptimizeref.value && typeof Doptimizeref.value.getaddDsave === 'function') {
  4028. if(nowid){
  4029. Doptimizeref.value.getaddDsave(pid.value,nowid);
  4030. }else{
  4031. Doptimizeref.value.getaddDsave(pid.value);
  4032. }
  4033. }
  4034. }
  4035. const getTaddsave = (nowid) => {
  4036. if (Toptimizeref.value && typeof Toptimizeref.value.getaddTsave === 'function') {
  4037. if(nowid){
  4038. Toptimizeref.value.getaddTsave(pid.value,nowid);
  4039. }else{
  4040. Toptimizeref.value.getaddTsave(pid.value);
  4041. }
  4042. }
  4043. }
  4044. const getSave = (ref) => {
  4045. if (ref == '进化优化器'){
  4046. getaddsave(youhuaqiwid.value);
  4047. }else if(ref == '代理优化器'){
  4048. getDaddsave(youhuaqiwid.value);
  4049. }else if(ref == '梯度优化器'){
  4050. getTaddsave(youhuaqiwid.value);
  4051. }
  4052. }
  4053. // 参数化
  4054. const adfhandleClick2=(tab,event)=>{
  4055. console.log('表单切换',tab.props.label);
  4056. activeadf.value=tab.props.label;
  4057. if(tab.props.name === 'CST'){
  4058. nextTick(() => {
  4059. // 确保 ref 已经初始化
  4060. if (Cstref.value) {
  4061. Cstref.value.getcst(pid.value,canshuhuawid.value);
  4062. }
  4063. });
  4064. }else if(tab.props.name === 'FFD'){
  4065. nextTick(() => {
  4066. // 确保 ref 已经初始化
  4067. if (Ffdref.value) {
  4068. Ffdref.value.getffds(pid.value,canshuhuawid.value);
  4069. }
  4070. });
  4071. }
  4072. }
  4073. // 单独cst保存
  4074. const cstok=(nowid)=>{
  4075. // cstnum.value='';
  4076. if(Cstref.value){
  4077. if(nowid){
  4078. Cstref.value.getcstsave(pid.value,nowid);
  4079. }else{
  4080. Cstref.value.getcstsave(pid.value);
  4081. }
  4082. }
  4083. dialog.value.CSTt = false;
  4084. }
  4085. // 单独ffd保存
  4086. const ffdok=(nowid)=>{
  4087. if(Ffdref.value){
  4088. if(nowid){
  4089. Ffdref.value.getffdsave(pid.value,nowid);
  4090. }else{
  4091. Ffdref.value.getffdsave(pid.value);
  4092. }
  4093. }
  4094. dialog.value.ffdt = false;
  4095. }
  4096. // cstffd保存
  4097. const getCstFfdsave = (activeadf) => {
  4098. if (activeadf == 'CST') {
  4099. cstok(canshuhuawid.value);
  4100. } else if (activeadf == 'FFD') {
  4101. ffdok(canshuhuawid.value);
  4102. }
  4103. }
  4104. const adfhandleClick3=(tab,event)=>{
  4105. console.log('表单切换',tab.props.label);
  4106. activeadf.value=tab.props.label;
  4107. if(tab.props.name === 'Xfoil'){
  4108. nextTick(() => {
  4109. // 确保 ref 已经初始化
  4110. if (Xfoilref.value) {
  4111. Xfoilref.value.getxfoil(pid.value,qidongyouhuawid.value);
  4112. }
  4113. });
  4114. }else if(tab.props.name === 'ADflow'){
  4115. nextTick(() => {
  4116. // 确保 ref 已经初始化
  4117. if (ADflowref.value) {
  4118. ADflowref.value.getadflow(pid.value,qidongyouhuawid.value);
  4119. }
  4120. });
  4121. }
  4122. }
  4123. // xfoil保存
  4124. const xfoilok=(nowid)=>{
  4125. if(Xfoilref.value){
  4126. if(nowid){
  4127. Xfoilref.value.getxfoilsave(pid.value,nowid);
  4128. }else{
  4129. Xfoilref.value.getxfoilsave(pid.value);
  4130. }
  4131. }
  4132. }
  4133. // adflow保存
  4134. const adflowok=(nowid)=>{
  4135. if(ADflowref.value){
  4136. if(nowid){
  4137. ADflowref.value.getadflowsave(pid.value,nowid);
  4138. }else{
  4139. ADflowref.value.getadflowsave(pid.value);
  4140. }
  4141. }
  4142. }
  4143. // 气动优化xfoiladflow保存
  4144. const getXfoilAdflowsave = (activeadf) => {
  4145. if (activeadf == 'Xfoil') {
  4146. xfoilok(qidongyouhuawid.value);
  4147. } else if (activeadf == 'ADflow') {
  4148. adflowok(qidongyouhuawid.value);
  4149. }
  4150. }
  4151. // Fsi保存
  4152. const getfsitosave = () => {
  4153. if (Fsiref.value) {
  4154. Fsiref.value.getfsisave(pid.value);
  4155. }
  4156. }
  4157. const mathfuncxinjian = () => {
  4158. if(MathFuncref.value) {
  4159. MathFuncref.value.mathfuncnew();
  4160. }
  4161. }
  4162. // MathFunc保存
  4163. const getmathfunctosave = () => {
  4164. if (MathFuncref.value) {
  4165. MathFuncref.value.getmathfuncsave(pid.value);
  4166. }
  4167. }
  4168. // TACS保存
  4169. const gettacstosave = () => {
  4170. if (Tacsref.value) {
  4171. Tacsref.value.gettacssave(pid.value);
  4172. }
  4173. }
  4174. // 云图打开二级弹窗
  4175. let seconddialogshow = ref(false)
  4176. let activesd = ref ({
  4177. fileselect:false,
  4178. domain:false,
  4179. cloud:false,
  4180. colorchart:false,
  4181. isoline:false
  4182. })
  4183. let cloudsedtitle = ref('')
  4184. const openSeconddialog = (name) => {
  4185. // 设置 activesd 中的值来控制不同内容的显示
  4186. activesd.value.fileselect = false;
  4187. activesd.value.domain = false;
  4188. activesd.value.cloud = false;
  4189. activesd.value.colorchart = false;
  4190. activesd.value.isoline = false;
  4191. switch (name) {
  4192. case '文件选择':
  4193. activesd.value.fileselect = true;
  4194. cloudsedtitle.value = "文件选择";
  4195. break;
  4196. case '域':
  4197. activesd.value.domain = true;
  4198. cloudsedtitle.value = "域";
  4199. break;
  4200. case '云图':
  4201. activesd.value.cloud = true;
  4202. cloudsedtitle.value = "云图";
  4203. break;
  4204. case '色卡':
  4205. activesd.value.colorchart = true;
  4206. cloudsedtitle.value = "色卡";
  4207. break;
  4208. case '等值线':
  4209. activesd.value.isoline = true;
  4210. cloudsedtitle.value = "等值线";
  4211. break;
  4212. default:
  4213. break;
  4214. }
  4215. seconddialogshow.value = true
  4216. };
  4217. const lbjkheaderCellClassName = ({ columnIndex }) => {
  4218. if( columnIndex === 0 ) return '';
  4219. let dynamicColumnIndex = columnIndex - 1;
  4220. let totalColumns = tableHeaders.value.length;
  4221. let partsize = Math.ceil( totalColumns/3 );
  4222. if( dynamicColumnIndex < partsize ) {
  4223. return 'header-first';
  4224. }else if( dynamicColumnIndex < partsize*2 ) {
  4225. return 'header-second';
  4226. }else {
  4227. return 'header-third';
  4228. }
  4229. }
  4230. </script>
  4231. <style lang="scss" scoped>
  4232. .conter_flex {
  4233. display: flex;
  4234. .ech {
  4235. flex: 1;
  4236. }
  4237. }
  4238. //有子节点 且未展开
  4239. .left_main_content :deep(.el-icon svg) {
  4240. display: block;
  4241. }
  4242. .footerTitle {
  4243. display: flex;
  4244. justify-content: space-between;
  4245. padding: 5px 0px;
  4246. font-size: 20px;
  4247. height: 32px !important;
  4248. z-index: 99;;
  4249. // border-radius: 5px 5px 0px 0px;
  4250. // overflow: hidden;
  4251. border-top: 1px solid #B3B3B3;
  4252. border-bottom: 1px solid #B3B3B3;
  4253. }
  4254. .footerTitle .el-image{
  4255. width:24px;
  4256. }
  4257. .footerTitle div {
  4258. display: flex;
  4259. // justify-content:center ;
  4260. align-items: center;
  4261. font-size: 14px;
  4262. }
  4263. .kongzhit {
  4264. position: absolute;
  4265. bottom: 0;
  4266. width: 100%;
  4267. }
  4268. .footerTitle p {
  4269. margin: 0;
  4270. }
  4271. .footerTitle .span {
  4272. width: 130px;
  4273. height: 32px;
  4274. line-height: 40px;
  4275. padding: 0 10px;
  4276. box-sizing: border-box;
  4277. cursor: default;
  4278. position: relative;
  4279. font-size: 14px;
  4280. color: #333333;
  4281. font-family: 'Microsoft YaHei';
  4282. }
  4283. .footerTitle .span .el-image {
  4284. margin-left: 10px;
  4285. }
  4286. .footerTitle .span span{
  4287. padding-left:10px;
  4288. }
  4289. .footerText .el-textarea__inner {
  4290. width: 100%;
  4291. height: 178px !important;
  4292. border: 0;
  4293. font-size: 12px;
  4294. color: #333;
  4295. padding: 2px;
  4296. box-shadow:none;
  4297. }
  4298. .custom-button{
  4299. color: #333333;
  4300. background-color: #DCEAFF;
  4301. border: 1px solid #2267B1 ;
  4302. }
  4303. //没有子节点
  4304. </style>
  4305. <style>
  4306. .wentsd {
  4307. padding: 0 8px;
  4308. }
  4309. /* .el-treeicon .el-tree-node__expand-icon.is-leaf{
  4310. display: none !important;
  4311. } */
  4312. .custom-text {
  4313. font-family: 'Microsoft YaHei';
  4314. font-size: 16px;
  4315. color: rgba(51, 51, 51, 1);
  4316. /* line-height: 24px; */
  4317. text-align: left;
  4318. font-style: normal;
  4319. text-transform: none;
  4320. padding-left: 8px;
  4321. }
  4322. .el-tree .el-tree-node__children .custom-text {
  4323. font-family: 'Microsoft YaHei';
  4324. font-size: 14px;
  4325. /* 这里设置为20px,你可以根据需求调整大小 */
  4326. color: rgba(51, 51, 51, 0.8);
  4327. }
  4328. /* .el-tree .el-tree-node.is-current>.el-tree-node__content img{
  4329. display: none;
  4330. } */
  4331. .custom-tree {
  4332. overflow: auto;
  4333. }
  4334. .custom-tree1>.el-tree-node>.el-tree-node__content>div img {
  4335. /* display: none; */
  4336. /* 隐藏一级节点复选框 */
  4337. }
  4338. .footerTitle {
  4339. background: #eee;
  4340. border-radius: 0px 0px 0px 0px;
  4341. }
  4342. .footer-tab .el-tabs__item {
  4343. color: #333333;
  4344. }
  4345. .footerTitle .active {
  4346. background-color: #fff;
  4347. border-left:1px solid #B3B3B3;
  4348. border-right:1px solid #B3B3B3;
  4349. /* border-bottom:4px solid #fff; */
  4350. }
  4351. .footerTitle .active::before{
  4352. content: "";
  4353. display: block;
  4354. width: 100%;
  4355. height: 2px;
  4356. background: #2267B1;
  4357. border-radius: 0px 0px 0px 0px;
  4358. top: 0px;
  4359. left:0px;
  4360. position: absolute;
  4361. }
  4362. .footerTitle .active::after{
  4363. content: "";
  4364. display: block;
  4365. width: 100%;
  4366. height:4px;
  4367. background: #fff;
  4368. border-radius: 0px 0px 0px 0px;
  4369. bottom: 0px;
  4370. left:0px;
  4371. position: absolute;
  4372. }
  4373. .youhualog {
  4374. width: 100%;
  4375. height: 195px;
  4376. overflow-y: auto;
  4377. background: #fff;
  4378. }
  4379. .youhualog .active2 {
  4380. color: #2267B1;
  4381. }
  4382. .youhualog ul {
  4383. /* width:482px; */
  4384. display: flex;
  4385. align-items: center;
  4386. }
  4387. .youhualog ul li {
  4388. font-family: 'Microsoft YaHei';
  4389. /* flex: 1; */
  4390. /* border-left: 1px solid #B3B3B3; */
  4391. font-size: 14px;
  4392. height: 32px;
  4393. /* line-height: 40px; */
  4394. width: 120px;
  4395. display: flex;
  4396. /* justify-content: center; */
  4397. align-items: center;
  4398. padding:0 10px;
  4399. cursor: default;
  4400. }
  4401. .youhualog ul li span {
  4402. margin-left: 10px;
  4403. }
  4404. .footer-content {
  4405. /* // padding: 15px 24px; */
  4406. padding: 5px;
  4407. border: 1px solid #B3B3B3;
  4408. /* margin-right: 119px; */
  4409. }
  4410. .footer-add {
  4411. width: 600px;
  4412. }
  4413. .flexend {
  4414. display: flex;
  4415. justify-content: flex-end;
  4416. }
  4417. .dibu {
  4418. margin-top: 5px;
  4419. display: flex;
  4420. justify-content: flex-end;
  4421. height: 35px;
  4422. overflow: hidden;
  4423. }
  4424. .dibu .el-input__wrapper {
  4425. width: 226px;
  4426. }
  4427. .dibu .el-form-item_label {
  4428. color: #333333;
  4429. font-size: 14px;
  4430. font-family: 'Microsoft YaHei';
  4431. }
  4432. .dibu .btncolor {
  4433. margin-top: 2px;
  4434. height: 27px;
  4435. width: 70px;
  4436. background: #FFFFFF;
  4437. box-shadow: 0px 2px 2px 0px #B3B3B3;
  4438. border-radius: 0px 0px 0px 0px;
  4439. border: 1px solid #B3B3B3;
  4440. }
  4441. .classtable .el-table td.el-table__cell div .el-input__wrapper {
  4442. box-shadow: none !important;
  4443. padding: 0;
  4444. }
  4445. .classtable .el-table .el-table__cell {
  4446. padding: 0;
  4447. }
  4448. .gooterpading {
  4449. /* border: 1px solid #2267B1; */
  4450. }
  4451. .classtable .el-table th .cell {
  4452. /* background: #fff; */
  4453. line-height: 31px;
  4454. }
  4455. .classtable .el-table td.el-table__cell, .classtable .el-table th.el-table__cell{
  4456. color: #333333;
  4457. font-size: 14px;
  4458. font-family: 'Microsoft YaHei';
  4459. }
  4460. .footer-content .classtable .el-table td.el-table__cell,.footer-content .classtable .el-table th.el-table__cell {
  4461. color: #333333;
  4462. font-size: 14px;
  4463. font-family: 'Microsoft YaHei';
  4464. }
  4465. .classtable .el-table td.el-table__cell div {
  4466. height: 31px;
  4467. overflow: hidden;
  4468. display: flex;
  4469. align-items: center; /* 垂直居中 */
  4470. justify-content: center; /* 水平居中 */
  4471. }
  4472. .classtable .el-table td.el-table__cell,
  4473. .el-table th.el-table__cell.is-leaf,
  4474. .eldesign {
  4475. /* border: 1px solid #000000; */
  4476. }
  4477. /* .el-color-picker__trigger {
  4478. //display: none;
  4479. } */
  4480. /* 使颜色选择器的触发器可点击,但不显示 */
  4481. .el-color-picker__trigger.is-show-panel {
  4482. display: block;
  4483. }
  4484. .conter_mian {
  4485. padding: 1px;
  4486. }
  4487. .summary-dlg2 .el-dialog__body {
  4488. padding: 0;
  4489. }
  4490. .summary-dlg .el-dialog__wrapper {
  4491. pointer-events: none;
  4492. }
  4493. .summary-dlg .el-dialog {
  4494. pointer-events: auto;
  4495. }
  4496. .summary-dlgPdf .el-dialog__body{
  4497. padding: 5px;
  4498. }
  4499. .el-table--enable-row-hover .el-table__body tr:hover>td.el-table__cell {
  4500. background-color: #fff;
  4501. }
  4502. .youhualog1 {
  4503. position: relative;
  4504. }
  4505. .chushij {
  4506. position: absolute;
  4507. right: 13px;
  4508. top: 5px;
  4509. }
  4510. .jindutiao {
  4511. margin: 20px;
  4512. width: 60%;
  4513. padding: 0 0 2px 0px;
  4514. /* background: #9FCDFF; */
  4515. display: flex;
  4516. justify-content: center;
  4517. align-items: center;
  4518. }
  4519. .jindutiao .demo-progress {
  4520. width: 100%;
  4521. }
  4522. .jindutiao .demo-progress .el-progress__text {
  4523. font-size: 13px;
  4524. color: #333333;
  4525. font-family: 'Microsoft YaHei';
  4526. }
  4527. .jindutiao .percentage-value {
  4528. font-size: 13px;
  4529. color: #333333;
  4530. font-family: 'Microsoft YaHei';
  4531. }
  4532. .cstleft{
  4533. width:50%;
  4534. flex: 1;
  4535. }
  4536. .XFpdding{
  4537. /* height: 425px; */
  4538. }
  4539. .dialog_class {
  4540. padding: 0px ;
  4541. color: #333333;
  4542. font-size: 16px;
  4543. font-family: 'Microsoft YaHei';
  4544. }
  4545. </style>