Home.vue 39 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295
  1. <template>
  2. <div class="home">
  3. <Row type="flex" style="height: 55vh">
  4. <div class="top-left-panel">
  5. <Row type="flex" class="weather">
  6. <Col :span="24">
  7. <com-panel
  8. :title="tqmap.name || 'yc'"
  9. :sub-title="nowTime + ' 实况'"
  10. icon="fa fa-map-marker"
  11. >
  12. <weather :data="tqmap" />
  13. </com-panel>
  14. </Col>
  15. </Row>
  16. <Row type="flex" class="plan">
  17. <Col :span="24">
  18. <com-panel title="预测电量" sub-title="(单位:万kWh)">
  19. <list-bar-chart-2 :list="ForecastPower" height="15.7407vh" />
  20. </com-panel>
  21. </Col>
  22. </Row>
  23. <Row type="flex" class="power">
  24. <Col :span="24">
  25. <com-panel title="功率负荷" sub-title="(单位:MW)">
  26. <power-review
  27. :data="powerData"
  28. :id="wpId"
  29. @chartClick="showPowerChart"
  30. />
  31. </com-panel>
  32. </Col>
  33. </Row>
  34. </div>
  35. <div class="top-mid-panel">
  36. <Map
  37. :wpId="wpId"
  38. :day="String(jczbmap.aqts || '---')"
  39. :data="fcmap"
  40. :xtData="xtmap"
  41. @mapClick="changeShowType"
  42. @backStation="onBackStation"
  43. ></Map>
  44. </div>
  45. <div class="top-right-panel">
  46. <Row type="flex">
  47. <Col :span="24">
  48. <com-panel title="电量分析" sub-title="(单位:万kWh)">
  49. <!-- 避免故障、提升率、降低率、风能利用率、设备可利用率、综合场用电率、存在隐患风机 -->
  50. <coulometric-analysis :bmgz="gxkmap.tjsl" :tsl="30" :jdl="gxkmap.tjl" :fnlyl="wxssmap.yfnlyl" :sbklyl="gxkmap.ysbklyl" :zhcydl="gxkmap.yzhcydl" :yhfj="gxkmap.sjtjsl" />
  51. </com-panel>
  52. </Col>
  53. </Row>
  54. <Row type="flex">
  55. <Col :span="24">
  56. <com-panel title="计划电量完成情况" sub-title="(单位:万kWh)">
  57. <power-plan
  58. :data="planData"
  59. :title="planBtnName"
  60. :showSingle="powerplanShowSingle"
  61. :id="wpId"
  62. @chartClick="showDoneChart"
  63. />
  64. </com-panel>
  65. </Col>
  66. </Row>
  67. </div>
  68. </Row>
  69. <Row type="flex" style="height: calc(40vh - 236px); margin-top: 20px">
  70. <Col :span="12">
  71. <toolbar-panel title="日发电量">
  72. <!-- <template v-slot:tools>
  73. <div class="tools">
  74. <div class="tool-block">
  75. <div class="legend bg-green"></div>
  76. <div class="legend-text">日发电量(单位:万kWh)</div>
  77. </div>
  78. <div class="tool-block">
  79. <div class="legend bg-purple"></div>
  80. <div class="legend-text">上网电量(单位:万kWh)</div>
  81. </div>
  82. <div class="tool-block">
  83. <div class="legend bg-orange"></div>
  84. <div class="legend-text">购网电量(单位:万kWh)</div>
  85. </div>
  86. </div>
  87. </template> -->
  88. <template v-slot:default>
  89. <!-- 日发电量 -->
  90. <multiple-bar-chart
  91. :list="DayPower.value"
  92. :units="DayPower.units"
  93. height="100%"
  94. :showLegend="true"
  95. @click="
  96. showDoneChart({
  97. data: DayPower,
  98. dialogTitle: '日发电量',
  99. dialogType: 'doneLineChart',
  100. })
  101. "
  102. />
  103. </template>
  104. </toolbar-panel>
  105. </Col>
  106. <Col :span="12">
  107. <toolbar-panel title="72小时功率趋势图">
  108. <!-- <template v-slot:tools>
  109. <div class="tools">
  110. <div class="tools">
  111. <div class="tool-block">
  112. <div class="legend long bg-green"></div>
  113. <div class="legend-text">应发功率</div>
  114. </div>
  115. <div class="tool-block">
  116. <div class="legend long bg-yellow"></div>
  117. <div class="legend-text">实发功率</div>
  118. </div>
  119. <div class="tool-block">
  120. <div class="legend long bg-purple"></div>
  121. <div class="legend-text">理论功率</div>
  122. </div>
  123. </div>
  124. </div>
  125. </template> -->
  126. <template v-slot:default>
  127. <multiple-line-chart
  128. height="100%"
  129. :list="Powertrend"
  130. units="(MW)"
  131. :showLegend="true"
  132. :hoverType="'axis'"
  133. @click="
  134. showPowerChart({
  135. data: Powertrend,
  136. dialogTitle: '72小时功率趋势图',
  137. dialogType: 'powerLineChart',
  138. })
  139. "
  140. />
  141. </template>
  142. </toolbar-panel>
  143. </Col>
  144. </Row>
  145. <Row type="flex" style="margin-top: 20px">
  146. <!-- 下方 table -->
  147. <Col :span="16" class="table-card-panel">
  148. <row>
  149. <Col>
  150. <com-panel>
  151. <table class="table-card">
  152. <tr class="">
  153. <td class="text gray">装机容量</td>
  154. <td class="value green">{{ jczbmap.zjrl }}</td>
  155. <td class="unit gray">MW</td>
  156. </tr>
  157. <tr class="">
  158. <td class="text gray">上网电量(日)</td>
  159. <td class="value green">{{ jczbmap.swdl }}</td>
  160. <td class="unit gray">万kWh</td>
  161. </tr>
  162. <tr class="">
  163. <td class="text gray">
  164. {{ wpId === "0" ? "减排二氧化硫" : "年运行小时" }}
  165. </td>
  166. <td class="value green">
  167. {{ wpId === "0" ? jczbmap.jpeyhl : gxkmap.nyxxs }}
  168. </td>
  169. <td class="unit gray">
  170. {{ wpId === "0" ? "万吨" : "小时" }}
  171. </td>
  172. </tr>
  173. <tr class="">
  174. <td class="text gray">
  175. {{ wpId === "0" ? "减排二氧化碳" : "年等效科利用系数" }}
  176. </td>
  177. <td class="value green">
  178. {{ wpId === "0" ? jczbmap.jpeyht : gxkmap.ndxkyss }}
  179. </td>
  180. <td class="unit gray">{{ wpId === "0" ? "万吨" : "%" }}</td>
  181. </tr>
  182. <tr class="">
  183. <td class="text gray">
  184. {{ wpId === "0" ? "节约用水" : "年故障小时" }}
  185. </td>
  186. <td class="value green">
  187. {{ wpId === "0" ? jczbmap.jys : gxkmap.ngzxs }}
  188. </td>
  189. <td class="unit gray">
  190. {{ wpId === "0" ? "万吨" : "小时" }}
  191. </td>
  192. </tr>
  193. <tr class="">
  194. <td class="text gray">
  195. {{ wpId === "0" ? "节约标煤" : "年待机小时" }}
  196. </td>
  197. <td class="value green">
  198. {{ wpId === "0" ? jczbmap.jybm : gxkmap.ndjxs }}
  199. </td>
  200. <td class="unit gray">
  201. {{ wpId === "0" ? "万吨" : "小时" }}
  202. </td>
  203. </tr>
  204. </table>
  205. </com-panel>
  206. </Col>
  207. <Col>
  208. <com-panel>
  209. <table class="table-card">
  210. <tr class="">
  211. <td class="text gray">利用小时(月)</td>
  212. <td class="value green">{{ jczbmap.ylyxs }}</td>
  213. <td class="unit gray">小时</td>
  214. </tr>
  215. <tr class="">
  216. <td class="text gray">利用小时(年)</td>
  217. <td class="value green">{{ jczbmap.nlyxs }}</td>
  218. <td class="unit gray gray">小时</td>
  219. </tr>
  220. <tr class="">
  221. <td class="text gray">等效可用系数</td>
  222. <td class="value green">{{ gxkmap.ydxkyss }}</td>
  223. <td class="unit gray">%</td>
  224. </tr>
  225. <tr class="">
  226. <td class="text gray">MTBF(月)</td>
  227. <td class="value green">{{ jczbmap.mtbf }}</td>
  228. <td class="unit gray">小时</td>
  229. </tr>
  230. <tr class="">
  231. <td class="text gray">MTTR(月)</td>
  232. <td class="value green">{{ jczbmap.mttr }}</td>
  233. <td class="unit gray">小时</td>
  234. </tr>
  235. <tr class="">
  236. <td class="text gray">MTTF(月)</td>
  237. <td class="value green">{{ jczbmap.mttf }}</td>
  238. <td class="unit gray">小时</td>
  239. </tr>
  240. </table>
  241. </com-panel>
  242. </Col>
  243. <Col>
  244. <com-panel>
  245. <table class="table-card">
  246. <tr
  247. class="curP"
  248. @click="
  249. openDialog(
  250. '日发电量详情',
  251. 'genreset/findDayInfo',
  252. 'rfdl',
  253. 'table'
  254. )
  255. "
  256. >
  257. <td class="text gray">日发电量</td>
  258. <td class="value green">{{ jczbmap.rfdl }}</td>
  259. <td class="unit gray">万kWh</td>
  260. </tr>
  261. <tr
  262. class="curP"
  263. @click="
  264. openDialog(
  265. '日故障损失详情',
  266. 'genreset/findDayInfo',
  267. 'rgzssdl',
  268. 'table'
  269. )
  270. "
  271. >
  272. <td class="text gray">日故障损失电量</td>
  273. <td class="value green">{{ wxssmap.rgzssdl }}</td>
  274. <td class="unit gray">万kWh</td>
  275. </tr>
  276. <tr
  277. class="curP"
  278. @click="
  279. openDialog(
  280. '日维护损失详情',
  281. 'genreset/findDayInfo',
  282. 'rjxssdl',
  283. 'table'
  284. )
  285. "
  286. >
  287. <td class="text gray">日维护损失电量</td>
  288. <td class="value green">{{ wxssmap.rjxssdl }}</td>
  289. <td class="unit gray">万kWh</td>
  290. </tr>
  291. <tr
  292. class="curP"
  293. @click="
  294. openDialog(
  295. '日限电损失详情',
  296. 'genreset/findDayInfo',
  297. 'rxdssdl',
  298. 'table'
  299. )
  300. "
  301. >
  302. <td class="text gray">日限电损失电量</td>
  303. <td class="value green">{{ wxssmap.rxdssdl }}</td>
  304. <td class="unit gray gray">万kWh</td>
  305. </tr>
  306. <tr
  307. class="curP"
  308. @click="
  309. openDialog(
  310. '日受累损失详情',
  311. 'genreset/findDayInfo',
  312. 'rslssdl',
  313. 'table'
  314. )
  315. "
  316. >
  317. <td class="text gray">日受累损失电量</td>
  318. <td class="value green">{{ wxssmap.rslssdl }}</td>
  319. <td class="unit gray">万kWh</td>
  320. </tr>
  321. <tr
  322. class="curP"
  323. @click="
  324. openDialog(
  325. '日性能损失详情',
  326. 'genreset/findDayInfo',
  327. 'rxnssdl',
  328. 'table'
  329. )
  330. "
  331. >
  332. <td class="text gray">日性能损失电量</td>
  333. <td class="value green">{{ wxssmap.rqfssdl }}</td>
  334. <td class="unit gray">万kWh</td>
  335. </tr>
  336. </table>
  337. </com-panel>
  338. </Col>
  339. <Col>
  340. <com-panel>
  341. <table class="table-card">
  342. <tr
  343. class="curP"
  344. @click="
  345. openDialog(
  346. '月发电量详情',
  347. 'genreset/findMonthInfo',
  348. 'yfdl',
  349. 'table'
  350. )
  351. "
  352. >
  353. <td class="text gray">月发电量</td>
  354. <td class="value green">{{ jczbmap.yfdl }}</td>
  355. <td class="unit gray gray">万kWh</td>
  356. </tr>
  357. <tr
  358. class="curP"
  359. @click="
  360. openDialog(
  361. '月故障损失详情',
  362. 'genreset/findMonthInfo',
  363. 'ygzssdl',
  364. 'table'
  365. )
  366. "
  367. >
  368. <td class="text gray">月故障损失</td>
  369. <td class="value green">{{ wxssmap.ygzssdl }}</td>
  370. <td class="unit gray">万kWh</td>
  371. </tr>
  372. <tr
  373. class="curP"
  374. @click="
  375. openDialog(
  376. '月维护损失详情',
  377. 'genreset/findMonthInfo',
  378. 'yjxssdl',
  379. 'table'
  380. )
  381. "
  382. >
  383. <td class="text gray">月维护损失</td>
  384. <td class="value green">{{ wxssmap.yjxssdl }}</td>
  385. <td class="unit gray">万kWh</td>
  386. </tr>
  387. <tr
  388. class="curP"
  389. @click="
  390. openDialog(
  391. '月限电损失详情',
  392. 'genreset/findMonthInfo',
  393. 'yxdssdl',
  394. 'table'
  395. )
  396. "
  397. >
  398. <td class="text gray">月限电损失</td>
  399. <td class="value green">{{ wxssmap.yxdssdl }}</td>
  400. <td class="unit gray gray">万kWh</td>
  401. </tr>
  402. <tr
  403. class="curP"
  404. @click="
  405. openDialog(
  406. '月受累损失详情',
  407. 'genreset/findMonthInfo',
  408. 'yslssdl',
  409. 'table'
  410. )
  411. "
  412. >
  413. <td class="text gray">月受累损失</td>
  414. <td class="value green">{{ wxssmap.yslssdl }}</td>
  415. <td class="unit gray">万kWh</td>
  416. </tr>
  417. <tr
  418. class="curP"
  419. @click="
  420. openDialog(
  421. '月性能损失详情',
  422. 'genreset/findMonthInfo',
  423. 'yxnssdl',
  424. 'table'
  425. )
  426. "
  427. >
  428. <td class="text gray">月性能损失</td>
  429. <td class="value green">{{ wxssmap.yqfssdl }}</td>
  430. <td class="unit gray">万kWh</td>
  431. </tr>
  432. </table>
  433. </com-panel>
  434. </Col>
  435. <Col>
  436. <com-panel>
  437. <table class="table-card">
  438. <tr
  439. class="curP"
  440. @click="
  441. openDialog(
  442. '年发电量详情',
  443. 'genreset/findYearInfo',
  444. 'nfdl',
  445. 'table'
  446. )
  447. "
  448. >
  449. <td class="text gray">年发电量</td>
  450. <td class="value green">{{ jczbmap.nfdl }}</td>
  451. <td class="unit gray">万kWh</td>
  452. </tr>
  453. <tr
  454. class="curP"
  455. @click="
  456. openDialog(
  457. '年故障损失详情',
  458. 'genreset/findYearInfo',
  459. 'ngzssdl',
  460. 'table'
  461. )
  462. "
  463. >
  464. <td class="text gray">年故障损失</td>
  465. <td class="value green">{{ wxssmap.ngzssdl }}</td>
  466. <td class="unit gray">万kWh</td>
  467. </tr>
  468. <tr
  469. class="curP"
  470. @click="
  471. openDialog(
  472. '年维护损失详情',
  473. 'genreset/findYearInfo',
  474. 'njxssdl',
  475. 'table'
  476. )
  477. "
  478. >
  479. <td class="text gray">年维护损失</td>
  480. <td class="value green">{{ wxssmap.njxssdl }}</td>
  481. <td class="unit gray">万kWh</td>
  482. </tr>
  483. <tr
  484. class="curP"
  485. @click="
  486. openDialog(
  487. '年限电损失详情',
  488. 'genreset/findYearInfo',
  489. 'nxdssdl',
  490. 'table'
  491. )
  492. "
  493. >
  494. <td class="text gray">年限电损失</td>
  495. <td class="value green">{{ wxssmap.nxdssdl }}</td>
  496. <td class="unit gray gray">万kWh</td>
  497. </tr>
  498. <tr
  499. class="curP"
  500. @click="
  501. openDialog(
  502. '年受累损失详情',
  503. 'genreset/findYearInfo',
  504. 'nslssdl',
  505. 'table'
  506. )
  507. "
  508. >
  509. <td class="text gray">年受累损失</td>
  510. <td class="value green">{{ wxssmap.nslssdl }}</td>
  511. <td class="unit gray">万kWh</td>
  512. </tr>
  513. <tr
  514. class="curP"
  515. @click="
  516. openDialog(
  517. '年性能损失详情',
  518. 'genreset/findYearInfo',
  519. 'nxnssdl',
  520. 'table'
  521. )
  522. "
  523. >
  524. <td class="text gray">年性能损失</td>
  525. <td class="value green">{{ wxssmap.nqfssdl }}</td>
  526. <td class="unit gray">万kWh</td>
  527. </tr>
  528. </table>
  529. </com-panel>
  530. </Col>
  531. </row>
  532. </Col>
  533. <!-- 右下角 panel -->
  534. <Col :span="8">
  535. <panel-3 class="situation">
  536. <div class="situation-body">
  537. <row align="middle">
  538. <div class="situation-item fengji">
  539. <div class="icon fengji-icon svg-icon svg-icon-white">
  540. <svg-icon class="" svgid="svg-风机" />
  541. </div>
  542. <div class="info">
  543. <div class="title green">接入设备</div>
  544. <div class="value">{{ mxztmap.jrts }}</div>
  545. </div>
  546. </div>
  547. <div class="situation-item">
  548. <div class="icon svg-icon svg-icon-green">
  549. <svg-icon class="" svgid="svg-待机图标" />
  550. </div>
  551. <div class="info">
  552. <div class="title green">待机</div>
  553. <div class="value">
  554. <span class="text gray">待风</span>
  555. <span>{{ mxztmap.djts }}</span>
  556. </div>
  557. <div class="value">
  558. <span class="text gray">手动停机</span>
  559. <span>{{ mxztmap.sdtjts }}</span>
  560. </div>
  561. </div>
  562. </div>
  563. <div class="situation-item">
  564. <div class="icon svg-icon svg-icon-purple">
  565. <svg-icon class="" svgid="svg-运行图标" />
  566. </div>
  567. <div class="info">
  568. <div class="title green">运行</div>
  569. <div class="value">
  570. <span class="text gray">正常发电</span>
  571. <span>{{ mxztmap.yxts }}</span>
  572. </div>
  573. <div class="value">
  574. <span class="text gray">降出力运行</span>
  575. <span>{{ mxztmap.fdjclts }}</span>
  576. </div>
  577. </div>
  578. </div>
  579. <div class="situation-item">
  580. <div class="icon svg-icon svg-icon-pink">
  581. <svg-icon class="" svgid="svg-限电图标" />
  582. </div>
  583. <div class="info">
  584. <div class="title green">限电</div>
  585. <div class="value">
  586. <span class="text gray">限电降出力</span>
  587. <span>{{ mxztmap.xdjclts }}</span>
  588. </div>
  589. <div class="value">
  590. <span class="text gray">停机</span>
  591. <span>{{ mxztmap.xdtjts }}</span>
  592. </div>
  593. </div>
  594. </div>
  595. </row>
  596. <row align="middle">
  597. <div class="situation-item">
  598. <div class="icon svg-icon svg-icon-red">
  599. <svg-icon class="" svgid="svg-故障图标" />
  600. </div>
  601. <div class="info">
  602. <div class="title green">故障</div>
  603. <div class="value">
  604. <span class="text gray">故障停机</span>
  605. <span>{{ mxztmap.gzts }}</span>
  606. </div>
  607. <div class="value">
  608. <span class="text gray">场内受累</span>
  609. <span>{{ mxztmap.cnslgzts }}</span>
  610. </div>
  611. </div>
  612. </div>
  613. <div class="situation-item">
  614. <div class="icon svg-icon svg-icon-orange">
  615. <svg-icon class="" svgid="svg-检修图标" />
  616. </div>
  617. <div class="info">
  618. <div class="title green">检修</div>
  619. <div class="value">
  620. <span class="text gray">检修停机</span>
  621. <span>{{ mxztmap.jxts }}</span>
  622. </div>
  623. <div class="value">
  624. <span class="text gray">场内受累</span>
  625. <span>{{ mxztmap.cnsljxts }}</span>
  626. </div>
  627. </div>
  628. </div>
  629. <div class="situation-item">
  630. <div class="icon svg-icon svg-icon-white">
  631. <svg-icon class="" svgid="svg-受累图标" />
  632. </div>
  633. <div class="info">
  634. <div class="title green">受累</div>
  635. <div class="value">
  636. <span class="text gray">电网</span>
  637. <span>{{ mxztmap.dwslts }}</span>
  638. </div>
  639. <div class="value">
  640. <span class="text gray">环境</span>
  641. <span>{{ mxztmap.hjslts }}</span>
  642. </div>
  643. </div>
  644. </div>
  645. <div class="situation-item">
  646. <div class="icon svg-icon svg-icon-gray">
  647. <svg-icon class="" svgid="svg-离线图标" />
  648. </div>
  649. <div class="info">
  650. <div class="title green">离线</div>
  651. <div class="value">
  652. <span class="text gray">离线</span>
  653. <span>{{ mxztmap.lxts }}</span>
  654. </div>
  655. <div class="value">
  656. <span class="text gray">未知</span>
  657. <span>---</span>
  658. </div>
  659. </div>
  660. </div>
  661. </row>
  662. </div>
  663. </panel-3>
  664. </Col>
  665. </Row>
  666. <el-dialog
  667. :title="dialogTitle"
  668. v-model="dialogShow"
  669. width="70%"
  670. top="10vh"
  671. custom-class="modal"
  672. :close-on-click-modal="true"
  673. @closed="dialogType = ''"
  674. >
  675. <Table :data="dialogData" v-if="dialogType === 'table'" />
  676. <MultipleLineChart
  677. height="500px"
  678. unit="(MW)"
  679. :list="powerLineChartData"
  680. :showLegend="true"
  681. v-if="dialogType === 'powerLineChart'"
  682. />
  683. <multiple-bar-chart
  684. height="500px"
  685. :units="doneLineChartData.units"
  686. :list="doneLineChartData.value"
  687. v-if="dialogType === 'doneLineChart'"
  688. />
  689. </el-dialog>
  690. </div>
  691. </template>
  692. <script>
  693. // @ is an alias to /src
  694. import Row from "../../components/coms/grid/row.vue";
  695. import Col from "../../components/coms/grid/col.vue";
  696. import ComPanel from "../../components/coms/panel/panel";
  697. // import ListBarChart from "../../components/chart/bar/list-bar-chart.vue";
  698. import ToolbarPanel from "../../components/coms/panel/toolbar-panel.vue";
  699. import MultipleBarChart from "../../components/chart/bar/multiple-bar-chart.vue";
  700. import MultipleLineChart from "../../components/chart/line/double-line-chart.vue";
  701. import Panel3 from "../../components/coms/panel/panel3.vue";
  702. import SvgIcon from "../../components/coms/icon/svg-icon.vue";
  703. import CoulometricAnalysis from "./components/coulometric-analysis.vue";
  704. import Weather from "./components/weather.vue";
  705. import PowerReview from "./components/power-review.vue";
  706. import PowerPlan from "./components/power-plan.vue";
  707. import Map from "./components/map.vue";
  708. import ListBarChart2 from "../../components/chart/bar/list-bar-chart2.vue";
  709. import Table from "./dialog/table.vue";
  710. export default {
  711. name: "Home",
  712. components: {
  713. Row,
  714. Col,
  715. ComPanel,
  716. Weather,
  717. CoulometricAnalysis,
  718. // ListBarChart,
  719. PowerReview,
  720. ToolbarPanel,
  721. PowerPlan,
  722. MultipleBarChart,
  723. MultipleLineChart,
  724. Panel3,
  725. SvgIcon,
  726. Map,
  727. ListBarChart2,
  728. Table,
  729. },
  730. data() {
  731. return {
  732. timmer: null, // 计时器
  733. timmer2: null,
  734. timmer3: null,
  735. jczbmap: {},
  736. wxssmap: {},
  737. gxkmap: {},
  738. mxztmap: {},
  739. planData: {},
  740. powerData: {},
  741. tqmap: {},
  742. nowTime: "",
  743. planBtnName: "全部",
  744. powerLineChartData: {
  745. // 图表所用单位
  746. units: [""],
  747. value: [
  748. {
  749. title: "",
  750. yAxisIndex: 0, // 使用单位
  751. value: [],
  752. },
  753. ],
  754. },
  755. doneLineChartData: {
  756. // 图表所用单位
  757. units: [""],
  758. value: [
  759. {
  760. title: "",
  761. yAxisIndex: 0, // 使用单位
  762. value: [],
  763. },
  764. ],
  765. },
  766. dialogType: null,
  767. wpId: "0",
  768. wpName: "", //安全天数下面的场站名
  769. fcmap: {},
  770. xtmap: {},
  771. dialogShow: false,
  772. dialogTitle: "",
  773. dialogData: {},
  774. // 预测电量
  775. ForecastPower: [],
  776. // 日发电量
  777. DayPower: {
  778. // 图表所用单位
  779. units: [""],
  780. value: [
  781. {
  782. title: "",
  783. yAxisIndex: 0, // 使用单位
  784. value: [],
  785. },
  786. ],
  787. },
  788. // 72小时功率趋势图
  789. Powertrend: [
  790. {
  791. title: "",
  792. yAxisIndex: 0, // 使用单位
  793. value: [],
  794. },
  795. ],
  796. };
  797. },
  798. methods: {
  799. // 请求服务
  800. requestData(showLoading) {
  801. let that = this;
  802. that.API.requestData({
  803. showLoading,
  804. method: "POST",
  805. subUrl: "genreset/findBasicDataInfo",
  806. timeout: 60000,
  807. data: {
  808. id: that.wpId,
  809. },
  810. success(res) {
  811. that.powerData = [
  812. {
  813. title: "风速",
  814. value: res.data.jczbmap.ssfs,
  815. dialogTitle: "风速详情",
  816. subUrl: "genreset/findGLDetail",
  817. targetName: "ssfs",
  818. dialogType: "powerLineChart",
  819. max: 30,
  820. },
  821. {
  822. title: "保证功率",
  823. value: res.data.jczbmap.bzgl,
  824. dialogTitle: "保证功率详情",
  825. subUrl: "genreset/findGLDetail",
  826. targetName: "bzgl",
  827. dialogType: "powerLineChart",
  828. max: res.data.jczbmap.zjts,
  829. },
  830. {
  831. title: "应发功率",
  832. value: res.data.jczbmap.yfgl,
  833. dialogTitle: "应发功率详情",
  834. subUrl: "genreset/findGLDetail",
  835. targetName: "yfgl",
  836. dialogType: "powerLineChart",
  837. max: res.data.jczbmap.zjts,
  838. },
  839. {
  840. title: "实际功率",
  841. value: res.data.jczbmap.sjgl,
  842. dialogTitle: "实际功率详情",
  843. subUrl: "genreset/findGLDetail",
  844. targetName: "sjgl",
  845. dialogType: "powerLineChart",
  846. max: res.data.jczbmap.zjts,
  847. },
  848. ];
  849. that.jczbmap = res.data.jczbmap;
  850. that.wxssmap = res.data.wxssmap;
  851. that.gxkmap = res.data.gxkmap;
  852. that.mxztmap = res.data.mxztmap;
  853. that.fcmap = res.data.fcmap;
  854. that.xtmap = res.data.xtmap;
  855. that.tqmap = res.data.tqmap;
  856. that.ForecastPower = [
  857. {
  858. name: "当日预测电量",
  859. value: res.data.jczbmap.rycfdl,
  860. total: res.data.jczbmap.rfdlsx,
  861. },
  862. {
  863. name: "实际发电量",
  864. value: res.data.jczbmap.rfdl,
  865. total: res.data.jczbmap.rfdlsx,
  866. },
  867. {
  868. name: "当月预测电量",
  869. value: res.data.jczbmap.yycfdl,
  870. total: res.data.jczbmap.yfdlsx,
  871. },
  872. {
  873. name: "实际发电量",
  874. value: res.data.jczbmap.yfdl,
  875. total: res.data.jczbmap.yfdlsx,
  876. },
  877. ];
  878. that.planData = {
  879. yfdl: res.data.jczbmap.yfdl,
  880. nfdl: res.data.jczbmap.nfdl,
  881. yfdljh: res.data.gxkmap.yfdljh,
  882. nfdljh: res.data.gxkmap.nfdljh,
  883. ywcl: res.data.gxkmap.ywcl,
  884. nwcl: res.data.gxkmap.nwcl,
  885. };
  886. },
  887. });
  888. },
  889. getCharts() {
  890. let that = this;
  891. that.API.requestData({
  892. method: "POST",
  893. subUrl: "genreset/findPowerInfo",
  894. timeout: 60000,
  895. data: {
  896. id: that.wpId,
  897. },
  898. success(res) {
  899. let rdlKey = ["value1", "value2", "value3", "speed"];
  900. let DayPower = {
  901. // 图表所用单位
  902. units: ["(万kWh)", "(m/s)"],
  903. value: [
  904. {
  905. title: "发电量",
  906. yAxisIndex: 0,
  907. value: [],
  908. },
  909. {
  910. title: "上网电量",
  911. yAxisIndex: 0,
  912. value: [],
  913. },
  914. {
  915. title: "购网电量",
  916. yAxisIndex: 0,
  917. value: [],
  918. },
  919. {
  920. title: "风速",
  921. yAxisIndex: 1,
  922. value: [],
  923. },
  924. ],
  925. };
  926. let glKey = [
  927. "value1",
  928. "value2",
  929. "value3",
  930. "value4",
  931. "value5",
  932. "value6",
  933. "value7",
  934. ];
  935. let Powertrend = [
  936. {
  937. title: "应发功率",
  938. smooth: true,
  939. value: [],
  940. },
  941. {
  942. title: "实发功率",
  943. smooth: true,
  944. value: [],
  945. },
  946. {
  947. title: "理论功率",
  948. smooth: true,
  949. value: [],
  950. },
  951. {
  952. title: "4小时预测功率",
  953. smooth: true,
  954. value: [],
  955. },
  956. {
  957. title: "保证功率",
  958. smooth: true,
  959. value: [],
  960. },
  961. {
  962. title: "平均风速",
  963. smooth: true,
  964. value: [],
  965. },
  966. {
  967. title: "24小时预测功率",
  968. smooth: true,
  969. value: [],
  970. },
  971. ];
  972. rdlKey.forEach((keyEle, keyIndex) => {
  973. res.data.rdlvos.forEach((cEle) => {
  974. DayPower.value[keyIndex].value.push({
  975. text: cEle.timestr,
  976. value: cEle[keyEle],
  977. });
  978. });
  979. });
  980. glKey.forEach((keyEle, keyIndex) => {
  981. res.data.glvos.forEach((cEle) => {
  982. Powertrend[keyIndex].value.push({
  983. text: new Date(cEle.time).formatDate("hh:mm"),
  984. value: cEle[keyEle],
  985. });
  986. });
  987. });
  988. that.DayPower = DayPower;
  989. that.Powertrend = Powertrend;
  990. },
  991. });
  992. },
  993. // 点击地图展示类型
  994. changeShowType(wpId, planBtnName) {
  995. this.wpName = planBtnName;
  996. this.planBtnName = planBtnName;
  997. this.jczbmap = {};
  998. clearInterval(this.timmer);
  999. this.timmer = null;
  1000. this.wpId = wpId;
  1001. this.requestData(false);
  1002. this.getCharts();
  1003. this.timmer = setInterval(() => {
  1004. this.requestData(false);
  1005. }, this.$store.state.websocketTimeSec);
  1006. },
  1007. // 打开弹窗
  1008. openDialog(dialogTitle, subUrl, targetName, dialogType) {
  1009. this.dialogTitle = dialogTitle;
  1010. let that = this;
  1011. that.API.requestData({
  1012. method: "POST",
  1013. subUrl,
  1014. data: {
  1015. id: that.wpId,
  1016. targetName,
  1017. },
  1018. success(res) {
  1019. that.dialogShow = true;
  1020. that.dialogData = res.data;
  1021. that.dialogType = dialogType;
  1022. },
  1023. });
  1024. },
  1025. // 点击安全天数下的场站按钮重置数据
  1026. onBackStation(){
  1027. if (this.wpId.indexOf("FDC") == -1){
  1028. clearInterval(this.timmer);
  1029. this.timmer = null;
  1030. this.wpId = this.wpId.substring(0, this.wpId.indexOf("0")) + "_FDC";
  1031. this.requestData(false);
  1032. this.timmer = setInterval(() => {
  1033. this.requestData(false);
  1034. }, this.$store.state.websocketTimeSec);
  1035. }
  1036. },
  1037. // 显示功率复核图表
  1038. showPowerChart(res) {
  1039. this.dialogTitle = res.dialogTitle;
  1040. this.dialogType = res.dialogType;
  1041. this.powerLineChartData = res.data;
  1042. this.dialogShow = true;
  1043. },
  1044. // 显示计划电量完成情况图表
  1045. showDoneChart(res) {
  1046. this.dialogTitle = res.dialogTitle;
  1047. this.dialogType = res.dialogType;
  1048. this.doneLineChartData = res.data;
  1049. this.dialogShow = true;
  1050. },
  1051. // 地图进入事件
  1052. onEnter() {
  1053. this.powerplanShowSingle = true;
  1054. },
  1055. // 地图退出事件
  1056. onBack() {
  1057. this.powerplanShowSingle = false;
  1058. },
  1059. },
  1060. created() {
  1061. let that = this;
  1062. that.nowTime = new Date().formatDate("hh:mm:ss");
  1063. that.$nextTick(() => {
  1064. that.requestData(false);
  1065. this.getCharts();
  1066. that.timmer = setInterval(() => {
  1067. that.requestData(false);
  1068. }, that.$store.state.websocketTimeSec);
  1069. that.timmer2 = setInterval(() => {
  1070. that.nowTime = new Date().formatDate("hh:mm:ss");
  1071. }, 1000);
  1072. that.timmer3 = setInterval(() => {
  1073. this.getCharts();
  1074. }, 360000);
  1075. });
  1076. },
  1077. unmounted() {
  1078. clearInterval(this.timmer);
  1079. clearInterval(this.timmer2);
  1080. clearInterval(this.timmer3);
  1081. this.timmer = null;
  1082. this.timmer2 = null;
  1083. this.timmer3 = null;
  1084. },
  1085. };
  1086. </script>
  1087. <style lang="less">
  1088. .home {
  1089. .grid-content {
  1090. background: #333;
  1091. height: 1.111vh;
  1092. }
  1093. .table-card-panel {
  1094. .col + .col {
  1095. margin-left: 8px;
  1096. }
  1097. }
  1098. .table-card {
  1099. background: rgba(255, 255, 255, 0.1);
  1100. border-collapse: collapse;
  1101. width: 100%;
  1102. outline: 1px solid @gray;
  1103. .curP {
  1104. cursor: pointer;
  1105. }
  1106. tr {
  1107. font-size: 12px;
  1108. td {
  1109. border: 0.093vh solid fade(@gray, 20);
  1110. line-height: 27px;
  1111. padding: 0 4px;
  1112. &.text {
  1113. }
  1114. &.value {
  1115. text-align: right;
  1116. font-family: @font-family-num;
  1117. }
  1118. &.unit {
  1119. }
  1120. }
  1121. }
  1122. }
  1123. .tools {
  1124. display: flex;
  1125. .tool-block {
  1126. display: flex;
  1127. align-items: center;
  1128. margin-left: 0.741vh;
  1129. .legend {
  1130. flex: auto;
  1131. width: 6px;
  1132. height: 6px;
  1133. margin-right: 0.741vh;
  1134. &.long {
  1135. width: 2.963vh;
  1136. height: 0.37vh;
  1137. }
  1138. }
  1139. .legend-text {
  1140. color: #ffffff4d;
  1141. }
  1142. }
  1143. }
  1144. .situation {
  1145. width: 100%;
  1146. height: 100%;
  1147. .situation-body {
  1148. display: flex;
  1149. flex-direction: column;
  1150. justify-content: space-around;
  1151. height: 100%;
  1152. .situation-item {
  1153. display: flex;
  1154. align-content: center;
  1155. flex: 1 1 25%;
  1156. align-items: center;
  1157. .icon {
  1158. svg {
  1159. width: 40px;
  1160. height: 40px;
  1161. }
  1162. }
  1163. &.fengji {
  1164. flex: 0 1 25%;
  1165. .info {
  1166. margin-left: 16px;
  1167. .value {
  1168. font-size: 24px;
  1169. display: inline-block;
  1170. }
  1171. }
  1172. }
  1173. .fengji-icon {
  1174. padding: 12px;
  1175. border-radius: 50%;
  1176. box-shadow: inset 1.5px -1px 1px 0px @green;
  1177. svg {
  1178. width: 24px;
  1179. height: 24px;
  1180. }
  1181. }
  1182. .info {
  1183. display: flex;
  1184. flex-direction: column;
  1185. justify-content: center;
  1186. margin-left: 0.741vh;
  1187. .title {
  1188. font-size: 12px;
  1189. font-weight: bold;
  1190. margin-bottom: 0.7407vh;
  1191. }
  1192. .text {
  1193. display: inline-block;
  1194. width: 64px;
  1195. text-align: left;
  1196. }
  1197. .value {
  1198. text-align: left;
  1199. font-size: 12px;
  1200. display: flex;
  1201. justify-content: space-between;
  1202. align-items: center;
  1203. }
  1204. }
  1205. }
  1206. }
  1207. }
  1208. .com-panel {
  1209. height: 100%;
  1210. .panel-body {
  1211. height: calc(100% - 32px);
  1212. }
  1213. }
  1214. .top-left-panel {
  1215. display: flex;
  1216. flex-direction: column;
  1217. justify-content: space-between;
  1218. flex: 0 0 380px;
  1219. .row {
  1220. flex: 0 0 auto;
  1221. }
  1222. .plan {
  1223. flex: 0 0 auto;
  1224. .com-panel {
  1225. height: 100%;
  1226. .panel-body {
  1227. height: calc(100% - 32px);
  1228. }
  1229. }
  1230. }
  1231. }
  1232. .top-mid-panel {
  1233. flex: 1 1 auto;
  1234. }
  1235. .top-right-panel {
  1236. display: flex;
  1237. flex-direction: column;
  1238. justify-content: space-between;
  1239. flex: 0 0 380px;
  1240. }
  1241. }
  1242. </style>