Home.vue 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904
  1. <template>
  2. <div class="home">
  3. <Row type="flex">
  4. <Col :span="6">
  5. <Row type="flex">
  6. <Col :span="24">
  7. <com-panel title="银川" sub-title="AM 10:52 实况" icon="fa fa-map-marker">
  8. <weather />
  9. </com-panel>
  10. </Col>
  11. </Row>
  12. <Row type="flex">
  13. <Col :span="24">
  14. <com-panel title="预测电量" sub-title="(单位:万KWh)">
  15. <list-bar-chart-2 :list="ForecastPower" height="16.6667vh" />
  16. </com-panel>
  17. </Col>
  18. </Row>
  19. <Row type="flex">
  20. <Col :span="24">
  21. <com-panel title="功率复核" sub-title="(单位:万KW)">
  22. <power-review :data="powerData" :id="wpId" @chartClick="showPowerChart" />
  23. </com-panel>
  24. </Col>
  25. </Row>
  26. </Col>
  27. <Col :span="12">
  28. <Map :wpId="wpId" :day="String(jczbmap.aqts || '---')" :data="fcmap" @mapClick="changeShowType"></Map>
  29. </Col>
  30. <Col :span="6">
  31. <Row type="flex">
  32. <Col :span="24">
  33. <com-panel title="电量分析" sub-title="(单位:万KWh)">
  34. <coulometric-analysis />
  35. </com-panel>
  36. </Col>
  37. </Row>
  38. <Row type="flex">
  39. <Col :span="24">
  40. <com-panel title="计划电量完成情况" sub-title="(单位:万KWh)">
  41. <power-plan :data="planData" :showSingle="powerplanShowSingle" :id="wpId" @chartClick="showDownChart" />
  42. </com-panel>
  43. </Col>
  44. </Row>
  45. </Col>
  46. </Row>
  47. <Row type="flex">
  48. <Col :span="12">
  49. <toolbar-panel title="日发电量">
  50. <template v-slot:tools>
  51. <div class="tools">
  52. <div class="tool-block">
  53. <div class="legend bg-green"></div>
  54. <div class="legend-text">日发电量(单位:万KWh)</div>
  55. </div>
  56. <div class="tool-block">
  57. <div class="legend bg-purple"></div>
  58. <div class="legend-text">上网电量(单位:万KWh)</div>
  59. </div>
  60. <div class="tool-block">
  61. <div class="legend bg-orange"></div>
  62. <div class="legend-text">购网电量(单位:万KWh)</div>
  63. </div>
  64. <div class="tool-block">
  65. <div class="legend bg-yellow"></div>
  66. <div class="legend-text">风速</div>
  67. </div>
  68. </div>
  69. </template>
  70. <template v-slot:default>
  71. <!-- 日发电量 -->
  72. <multiple-bar-chart :list="DayPower.value" :units="DayPower.units" height="12.963vh" />
  73. </template>
  74. </toolbar-panel>
  75. </Col>
  76. <Col :span="12">
  77. <toolbar-panel title="72小时功率趋势图">
  78. <template v-slot:tools>
  79. <div class="tools">
  80. <div class="tools">
  81. <div class="tool-block">
  82. <div class="legend long bg-green"></div>
  83. <div class="legend-text">应发功率</div>
  84. </div>
  85. <div class="tool-block">
  86. <div class="legend long bg-yellow"></div>
  87. <div class="legend-text">实发功率</div>
  88. </div>
  89. <div class="tool-block">
  90. <div class="legend long bg-purple"></div>
  91. <div class="legend-text">理论功率</div>
  92. </div>
  93. </div>
  94. </div>
  95. </template>
  96. <template v-slot:default>
  97. <multiple-line-chart :list="Powertrend.value" :units="Powertrend.units" height="12.963vh" />
  98. </template>
  99. </toolbar-panel>
  100. </Col>
  101. </Row>
  102. <Row type="flex">
  103. <!-- 下方 table -->
  104. <Col :span="16">
  105. <row>
  106. <Col>
  107. <com-panel>
  108. <table class="table-card">
  109. <tr class="">
  110. <td class="text gray">装机容量</td>
  111. <td class="value green">{{jczbmap.zjrl}}</td>
  112. <td class="unit gray">万kw</td>
  113. </tr>
  114. <tr class="">
  115. <td class="text gray">装机台数</td>
  116. <td class="value green">{{jczbmap.zjts}}</td>
  117. <td class="unit gray">台</td>
  118. </tr>
  119. <tr class="" @click="openDialog('日发电量详情', 'genreset/findDayInfo', 'rfdl', 'table')">
  120. <td class="text gray">日发电量</td>
  121. <td class="value green">{{jczbmap.rfdl}}</td>
  122. <td class="unit gray">万kwh</td>
  123. </tr>
  124. <tr class="" @click="openDialog('月发电量详情', 'genreset/findMonthInfo', 'yfdl', 'table')">
  125. <td class="text gray">月发电量</td>
  126. <td class="value green">{{jczbmap.yfdl}}</td>
  127. <td class="unit gray gray">万kwh</td>
  128. </tr>
  129. <tr class="" @click="openDialog('年发电量详情', 'genreset/findYearInfo', 'nfdl', 'table')">
  130. <td class="text gray">年发电量</td>
  131. <td class="value green">{{jczbmap.nfdl}}</td>
  132. <td class="unit gray">万kwh</td>
  133. </tr>
  134. <tr class="">
  135. <td class="text gray">年设备可利用率</td>
  136. <td class="value green">{{gxkmap.nsbklyl}}</td>
  137. <td class="unit gray">%</td>
  138. </tr>
  139. </table>
  140. </com-panel>
  141. </Col>
  142. <Col>
  143. <com-panel>
  144. <table class="table-card">
  145. <tr class="">
  146. <td class="text gray">MTTR</td>
  147. <td class="value green">{{jczbmap.mttr}}</td>
  148. <td class="unit gray">小时</td>
  149. </tr>
  150. <tr class="">
  151. <td class="text gray">MTBF</td>
  152. <td class="value green">{{jczbmap.mtbf}}</td>
  153. <td class="unit gray">小时</td>
  154. </tr>
  155. <tr class="">
  156. <td class="text gray">上网电量</td>
  157. <td class="value green">{{jczbmap.swdl}}</td>
  158. <td class="unit gray">万kwh</td>
  159. </tr>
  160. <tr class="">
  161. <td class="text gray">月利用小时</td>
  162. <td class="value green">{{jczbmap.ylyxs}}</td>
  163. <td class="unit gray">%</td>
  164. </tr>
  165. <tr class="">
  166. <td class="text gray">年利用小时</td>
  167. <td class="value green">{{jczbmap.nlyxs}}</td>
  168. <td class="unit gray gray">%</td>
  169. </tr>
  170. <tr class="">
  171. <td class="text gray">{{wpId === "0" ? "节约二氧化碳" : "年等效科利用系数"}}</td>
  172. <td class="value green">{{wpId === "0" ? jczbmap.jpeyht : gxkmap.ndxkyss}}</td>
  173. <td class="unit gray">{{wpId === "0" ? "万吨" : "%"}}</td>
  174. </tr>
  175. </table>
  176. </com-panel>
  177. </Col>
  178. <Col>
  179. <com-panel>
  180. <table class="table-card">
  181. <tr class="" @click="openDialog('日性能损失详情', 'genreset/findDayInfo', 'rxnssdl', 'table')">
  182. <td class="text gray">日性能损失</td>
  183. <td class="value green">{{wxssmap.rqfssdl}}</td>
  184. <td class="unit gray">万kwh</td>
  185. </tr>
  186. <tr class="" @click="openDialog('日故障损失详情', 'genreset/findDayInfo', 'rgzssdl', 'table')">
  187. <td class="text gray">日故障损失</td>
  188. <td class="value green">{{wxssmap.rgzssdl}}</td>
  189. <td class="unit gray">万kwh</td>
  190. </tr>
  191. <tr class="" @click="openDialog('日检修损失详情', 'genreset/findDayInfo', 'rjxssdl', 'table')">
  192. <td class="text gray">日检修损失</td>
  193. <td class="value green">{{wxssmap.rjxssdl}}</td>
  194. <td class="unit gray">万kwh</td>
  195. </tr>
  196. <tr class="" @click="openDialog('日限电损失详情', 'genreset/findDayInfo', 'rxdssdl', 'table')">
  197. <td class="text gray">日限电损失</td>
  198. <td class="value green">{{wxssmap.rxdssdl}}</td>
  199. <td class="unit gray gray">万kwh</td>
  200. </tr>
  201. <tr class="" @click="openDialog('日受累损失详情', 'genreset/findDayInfo', 'rslssdl', 'table')">
  202. <td class="text gray">日受累损失</td>
  203. <td class="value green">{{wxssmap.rslssdl}}</td>
  204. <td class="unit gray">万kwh</td>
  205. </tr>
  206. <tr class="">
  207. <td class="text gray">{{wpId === "0" ? "节约标煤" : "年待机小时"}}</td>
  208. <td class="value green">{{wpId === "0" ? jczbmap.jybm : gxkmap.ndjxs}}</td>
  209. <td class="unit gray">{{wpId === "0" ? "万吨" : "小时"}}</td>
  210. </tr>
  211. </table>
  212. </com-panel>
  213. </Col>
  214. <Col>
  215. <com-panel>
  216. <table class="table-card">
  217. <tr class="" @click="openDialog('月性能损失详情', 'genreset/findMonthInfo', 'yxnssdl', 'table')">
  218. <td class="text gray">月性能损失</td>
  219. <td class="value green">{{wxssmap.yqfssdl}}</td>
  220. <td class="unit gray">万kwh</td>
  221. </tr>
  222. <tr class="" @click="openDialog('月故障损失详情', 'genreset/findMonthInfo', 'ygzssdl', 'table')">
  223. <td class="text gray">月故障损失</td>
  224. <td class="value green">{{wxssmap.ygzssdl}}</td>
  225. <td class="unit gray">万kwh</td>
  226. </tr>
  227. <tr class="" @click="openDialog('月检修损失详情', 'genreset/findMonthInfo', 'yjxssdl', 'table')">
  228. <td class="text gray">月检修损失</td>
  229. <td class="value green">{{wxssmap.yjxssdl}}</td>
  230. <td class="unit gray">万kwh</td>
  231. </tr>
  232. <tr class="" @click="openDialog('月限电损失详情', 'genreset/findMonthInfo', 'yxdssdl', 'table')">
  233. <td class="text gray">月限电损失</td>
  234. <td class="value green">{{wxssmap.yxdssdl}}</td>
  235. <td class="unit gray gray">万kwh</td>
  236. </tr>
  237. <tr class="" @click="openDialog('月受累损失详情', 'genreset/findMonthInfo', 'yslssdl', 'table')">
  238. <td class="text gray">月受累损失</td>
  239. <td class="value green">{{wxssmap.yslssdl}}</td>
  240. <td class="unit gray">万kwh</td>
  241. </tr>
  242. <tr class="">
  243. <td class="text gray">{{wpId === "0" ? "节约二氧化硫" : "年运行小时"}}</td>
  244. <td class="value green">{{wpId === "0" ? jczbmap.jpeyhl : gxkmap.nyxxs}}</td>
  245. <td class="unit gray">{{wpId === "0" ? "万吨" : "小时"}}</td>
  246. </tr>
  247. </table>
  248. </com-panel>
  249. </Col>
  250. <Col>
  251. <com-panel>
  252. <table class="table-card">
  253. <tr class="" @click="openDialog('年性能损失详情', 'genreset/findYearInfo', 'nxnssdl', 'table')">
  254. <td class="text gray">年性能损失</td>
  255. <td class="value green">{{wxssmap.nqfssdl}}</td>
  256. <td class="unit gray">万kwh</td>
  257. </tr>
  258. <tr class="" @click="openDialog('年故障损失详情', 'genreset/findYearInfo', 'ngzssdl', 'table')">
  259. <td class="text gray">年故障损失</td>
  260. <td class="value green">{{wxssmap.ngzssdl}}</td>
  261. <td class="unit gray">万kwh</td>
  262. </tr>
  263. <tr class="" @click="openDialog('年检修损失详情', 'genreset/findYearInfo', 'njxssdl', 'table')">
  264. <td class="text gray">年检修损失</td>
  265. <td class="value green">{{wxssmap.njxssdl}}</td>
  266. <td class="unit gray">万kwh</td>
  267. </tr>
  268. <tr class="" @click="openDialog('年限电损失详情', 'genreset/findYearInfo', 'nxdssdl', 'table')">
  269. <td class="text gray">年限电损失</td>
  270. <td class="value green">{{wxssmap.nxdssdl}}</td>
  271. <td class="unit gray gray">万kwh</td>
  272. </tr>
  273. <tr class="" @click="openDialog('年受累损失详情', 'genreset/findYearInfo', 'nslssdl', 'table')">
  274. <td class="text gray">年受累损失</td>
  275. <td class="value green">{{wxssmap.nslssdl}}</td>
  276. <td class="unit gray">万kwh</td>
  277. </tr>
  278. <tr class="">
  279. <td class="text gray">{{wpId === "0" ? "节约用水" : "年故障小时"}}</td>
  280. <td class="value green">{{wpId === "0" ? jczbmap.jys : gxkmap.ngzxs}}</td>
  281. <td class="unit gray">{{wpId === "0" ? "万吨" : "小时"}}</td>
  282. </tr>
  283. </table>
  284. </com-panel>
  285. </Col>
  286. </row>
  287. </Col>
  288. <!-- 右下角 panel -->
  289. <Col :span="8">
  290. <panel-3 class="situation">
  291. <div class="situation-body">
  292. <row align="middle">
  293. <div class="situation-item fengji">
  294. <div class="icon fengji-icon svg-icon svg-icon-white">
  295. <svg-icon class="" svgid="svg-风机" />
  296. </div>
  297. <div class="info">
  298. <div class="title green">接入风机</div>
  299. <div class="value">{{mxztmap.jrts}}</div>
  300. </div>
  301. </div>
  302. <div class="situation-item">
  303. <div class="icon svg-icon svg-icon-purple">
  304. <svg-icon class="" svgid="svg-待机图标" />
  305. </div>
  306. <div class="info">
  307. <div class="title green">待机</div>
  308. <div class="value">
  309. <span class="text gray">待风</span>
  310. <span>{{mxztmap.djts}}</span>
  311. </div>
  312. <div class="value">
  313. <span class="text gray">手动停机</span>
  314. <span>{{mxztmap.sdtjts}}</span>
  315. </div>
  316. </div>
  317. </div>
  318. <div class="situation-item">
  319. <div class="icon svg-icon svg-icon-green">
  320. <svg-icon class="" svgid="svg-运行图标" />
  321. </div>
  322. <div class="info">
  323. <div class="title green">运行</div>
  324. <div class="value">
  325. <span class="text gray">正常发电</span>
  326. <span>{{mxztmap.yxts}}</span>
  327. </div>
  328. <div class="value">
  329. <span class="text gray">降出力运行</span>
  330. <span>{{mxztmap.fdjclts}}</span>
  331. </div>
  332. </div>
  333. </div>
  334. <div class="situation-item">
  335. <div class="icon svg-icon svg-icon-yellow">
  336. <svg-icon class="" svgid="svg-限电图标" />
  337. </div>
  338. <div class="info">
  339. <div class="title green">限电</div>
  340. <div class="value">
  341. <span class="text gray">限电降出力</span>
  342. <span>{{mxztmap.xdjclts}}</span>
  343. </div>
  344. <div class="value">
  345. <span class="text gray">停机</span>
  346. <span>{{mxztmap.xdtjts}}</span>
  347. </div>
  348. </div>
  349. </div>
  350. </row>
  351. <row align="middle">
  352. <div class="situation-item">
  353. <div class="icon svg-icon svg-icon-red">
  354. <svg-icon class="" svgid="svg-故障图标" />
  355. </div>
  356. <div class="info">
  357. <div class="title green">故障</div>
  358. <div class="value">
  359. <span class="text gray">故障停机</span>
  360. <span>{{mxztmap.gzts}}</span>
  361. </div>
  362. <div class="value">
  363. <span class="text gray">场内受累</span>
  364. <span>{{mxztmap.cnslgzts}}</span>
  365. </div>
  366. </div>
  367. </div>
  368. <div class="situation-item">
  369. <div class="icon svg-icon svg-icon-orange">
  370. <svg-icon class="" svgid="svg-检修图标" />
  371. </div>
  372. <div class="info">
  373. <div class="title green">检修</div>
  374. <div class="value">
  375. <span class="text gray">检修停机</span>
  376. <span>{{mxztmap.jxts}}</span>
  377. </div>
  378. <div class="value">
  379. <span class="text gray">场内受累</span>
  380. <span>{{mxztmap.cnsljxts}}</span>
  381. </div>
  382. </div>
  383. </div>
  384. <div class="situation-item">
  385. <div class="icon svg-icon svg-icon-darkblue">
  386. <svg-icon class="" svgid="svg-受累图标" />
  387. </div>
  388. <div class="info">
  389. <div class="title green">受累</div>
  390. <div class="value">
  391. <span class="text gray">电网</span>
  392. <span>{{mxztmap.dwslts}}</span>
  393. </div>
  394. <div class="value">
  395. <span class="text gray">环境</span>
  396. <span>{{mxztmap.hjslts}}</span>
  397. </div>
  398. </div>
  399. </div>
  400. <div class="situation-item">
  401. <div class="icon svg-icon svg-icon-gray">
  402. <svg-icon class="" svgid="svg-离线图标" />
  403. </div>
  404. <div class="info">
  405. <div class="title green">离线</div>
  406. <div class="value">
  407. <span class="text gray">离线</span>
  408. <span>{{mxztmap.lxts}}</span>
  409. </div>
  410. <div class="value">
  411. <span class="text gray">未知</span>
  412. <span>---</span>
  413. </div>
  414. </div>
  415. </div>
  416. </row>
  417. </div>
  418. </panel-3>
  419. </Col>
  420. </Row>
  421. <el-dialog :title="dialogTitle" v-model="dialogShow" width="70%" top="10vh" custom-class="modal" :close-on-click-modal="true" @closed="dialogType = ''">
  422. <Table :data="dialogData" v-if="dialogType === 'table'" />
  423. <MultipleLineChart height="500px" :units="powerLineChartData.units" :list="powerLineChartData.value" :showLegend="true" v-if="dialogType === 'powerLineChart'" />
  424. <multiple-bar-chart height="500px" :list="doneLineChartData.value" :units="doneLineChartData.units" v-if="dialogType === 'doneLineChart'" />
  425. </el-dialog>
  426. </div>
  427. </template>
  428. <script>
  429. // @ is an alias to /src
  430. import Row from "../../components/coms/grid/row.vue";
  431. import Col from "../../components/coms/grid/col.vue";
  432. import ComPanel from "../../components/coms/panel/panel";
  433. // import ListBarChart from "../../components/chart/bar/list-bar-chart.vue";
  434. import ToolbarPanel from "../../components/coms/panel/toolbar-panel.vue";
  435. import MultipleBarChart from "../../components/chart/bar/multiple-bar-chart.vue";
  436. import MultipleLineChart from "../../components/chart/line/multiple-line-chart.vue";
  437. import Panel3 from "../../components/coms/panel/panel3.vue";
  438. import SvgIcon from "../../components/coms/icon/svg-icon.vue";
  439. import CoulometricAnalysis from "./components/coulometric-analysis.vue";
  440. import Weather from "./components/weather.vue";
  441. import PowerReview from "./components/power-review.vue";
  442. import PowerPlan from "./components/power-plan.vue";
  443. import Map from "./components/map.vue";
  444. import ListBarChart2 from '../../components/chart/bar/list-bar-chart2.vue';
  445. import Table from "./dialog/table.vue";
  446. export default {
  447. name: "Home",
  448. components: {
  449. Row,
  450. Col,
  451. ComPanel,
  452. Weather,
  453. CoulometricAnalysis,
  454. // ListBarChart,
  455. PowerReview,
  456. ToolbarPanel,
  457. PowerPlan,
  458. MultipleBarChart,
  459. MultipleLineChart,
  460. Panel3,
  461. SvgIcon,
  462. Map,
  463. ListBarChart2,
  464. Table
  465. },
  466. data () {
  467. return {
  468. timmer: null, // 计时器
  469. jczbmap: {},
  470. wxssmap: {},
  471. gxkmap: {},
  472. mxztmap: {},
  473. planData: {},
  474. powerData: {},
  475. powerLineChartData: {
  476. // 图表所用单位
  477. units: [""],
  478. value: [
  479. {
  480. title: "",
  481. yAxisIndex: 0, // 使用单位
  482. value: [],
  483. },
  484. ],
  485. },
  486. doneLineChartData: {
  487. // 图表所用单位
  488. units: [""],
  489. value: [
  490. {
  491. title: "",
  492. yAxisIndex: 0, // 使用单位
  493. value: [],
  494. },
  495. ],
  496. },
  497. dialogType: null,
  498. wpId: "0",
  499. fcmap:{},
  500. dialogShow: false,
  501. dialogTitle: "",
  502. dialogData:{},
  503. // 预测电量
  504. ForecastPower: [],
  505. // 日发电量
  506. DayPower: {
  507. // 图表所用单位
  508. units: [""],
  509. value: [
  510. {
  511. title: "",
  512. yAxisIndex: 0, // 使用单位
  513. value: [],
  514. },
  515. ],
  516. },
  517. // 72小时功率趋势图
  518. Powertrend: {
  519. // 图表所用单位
  520. units: [""],
  521. value: [
  522. {
  523. title: "",
  524. yAxisIndex: 0, // 使用单位
  525. value: [],
  526. },
  527. ],
  528. },
  529. };
  530. },
  531. methods: {
  532. // 请求服务
  533. requestData (showLoading) {
  534. let that = this;
  535. that.API.requestData({
  536. showLoading,
  537. method: "POST",
  538. subUrl: "genreset/findBasicDataInfo",
  539. timeout: 60000,
  540. data: {
  541. id: that.wpId,
  542. },
  543. success (res) {
  544. let glvos = [];
  545. let rdlKey = ["value1", "value2", "value3"];
  546. let DayPower = {
  547. // 图表所用单位
  548. units: ["(万KWh)"],
  549. value: [{
  550. title: "发电量",
  551. yAxisIndex: 0,
  552. value: []
  553. }, {
  554. title: "上网电量",
  555. yAxisIndex: 0,
  556. value: []
  557. }, {
  558. title: "购网电量",
  559. yAxisIndex: 0,
  560. value: []
  561. }]
  562. };
  563. let glKey = ["value1", "value2", "value3", "value4", "value5", "value6"];
  564. let Powertrend = {
  565. // 图表所用单位
  566. units: ["(万KWh)", "(m/s)"],
  567. value: [{
  568. title: "应发功率",
  569. yAxisIndex: 0,
  570. value: []
  571. }, {
  572. title: "实发功率",
  573. yAxisIndex: 0,
  574. value: []
  575. }, {
  576. title: "理论功率",
  577. yAxisIndex: 0,
  578. value: []
  579. }, {
  580. title: "预测功率",
  581. yAxisIndex: 0,
  582. value: []
  583. }, {
  584. title: "保证功率",
  585. yAxisIndex: 0,
  586. value: []
  587. }, {
  588. title: "平均风速",
  589. yAxisIndex: 1,
  590. value: []
  591. }]
  592. };
  593. rdlKey.forEach((keyEle, keyIndex) => {
  594. res.data.rdlvos.forEach(cEle => {
  595. DayPower.value[keyIndex].value.push({
  596. text: cEle.timestr,
  597. value: cEle[keyEle]
  598. });
  599. });
  600. });
  601. glKey.forEach((keyEle, keyIndex) => {
  602. res.data.glvos.forEach(cEle => {
  603. Powertrend.value[keyIndex].value.push({
  604. text: new Date(cEle.time).formatDate("hh:mm:ss"),
  605. value: cEle[keyEle]
  606. });
  607. });
  608. });
  609. that.powerData = [{
  610. title: "风速",
  611. value: res.data.jczbmap.ssfs,
  612. dialogTitle: "风速详情",
  613. subUrl: "genreset/findGLDetail",
  614. targetName: "ssfs",
  615. dialogType: "powerLineChart"
  616. }, {
  617. title: "保证功率",
  618. value: res.data.jczbmap.bzgl,
  619. dialogTitle: "保证功率详情",
  620. subUrl: "genreset/findGLDetail",
  621. targetName: "bzgl",
  622. dialogType: "powerLineChart"
  623. }, {
  624. title: "应发功率",
  625. value: res.data.jczbmap.yfgl,
  626. dialogTitle: "应发功率详情",
  627. subUrl: "genreset/findGLDetail",
  628. targetName: "yfgl",
  629. dialogType: "powerLineChart"
  630. }, {
  631. title: "实际功率",
  632. value: res.data.jczbmap.sjgl,
  633. dialogTitle: "实际功率详情",
  634. subUrl: "genreset/findGLDetail",
  635. targetName: "sjgl",
  636. dialogType: "powerLineChart"
  637. }];
  638. that.DayPower = DayPower;
  639. that.Powertrend = Powertrend;
  640. that.jczbmap = res.data.jczbmap;
  641. that.wxssmap = res.data.wxssmap;
  642. that.gxkmap = res.data.gxkmap;
  643. that.mxztmap = res.data.mxztmap;
  644. that.fcmap = res.data.fcmap;
  645. that.ForecastPower = [{
  646. name: "当日预测电量",
  647. value: res.data.jczbmap.rycfdl,
  648. total: res.data.jczbmap.rfdlsx
  649. },{
  650. name: "实际发电量",
  651. value: res.data.jczbmap.rfdl,
  652. total: res.data.jczbmap.rfdlsx
  653. },{
  654. name: "当月预测电量",
  655. value: res.data.jczbmap.yycfdl,
  656. total: res.data.jczbmap.yfdlsx
  657. },{
  658. name: "实际发电量",
  659. value: res.data.jczbmap.yfdl,
  660. total: res.data.jczbmap.yfdlsx
  661. }];
  662. that.planData = {
  663. yfdl: res.data.jczbmap.yfdl,
  664. nfdl: res.data.jczbmap.nfdl,
  665. yfdljh: res.data.gxkmap.yfdljh,
  666. nfdljh: res.data.gxkmap.nfdljh,
  667. ywcl: res.data.gxkmap.ywcl,
  668. nwcl: res.data.gxkmap.nwcl
  669. };
  670. },
  671. });
  672. },
  673. // 点击地图展示类型
  674. changeShowType(wpId){
  675. clearInterval(this.timmer);
  676. this.timmer = null;
  677. this.wpId = wpId;
  678. this.requestData(false);
  679. this.timmer = setInterval(() => {
  680. this.requestData(false);
  681. }, this.$store.state.websocketTimeSec);
  682. },
  683. // 打开弹窗
  684. openDialog(dialogTitle, subUrl, targetName, dialogType){
  685. console.log(123123,dialogType)
  686. this.dialogTitle = dialogTitle;
  687. let that = this;
  688. that.API.requestData({
  689. method: "POST",
  690. subUrl,
  691. data: {
  692. id:that.wpId,
  693. targetName
  694. },
  695. success (res) {
  696. that.dialogShow = true;
  697. that.dialogData = res.data;
  698. that.dialogType = dialogType;
  699. }
  700. });
  701. },
  702. // 显示功率复核图表
  703. showPowerChart(res){
  704. this.dialogTitle = res.dialogTitle;
  705. this.dialogType = res.dialogType;
  706. let powerLineChartData = {
  707. // 图表所用单位
  708. units: [""],
  709. value: [],
  710. };
  711. res.data.forEach((pEle,pIndex)=>{
  712. powerLineChartData.value.push({
  713. title: pEle[0].name,
  714. yAxisIndex: 0,
  715. value: [],
  716. });
  717. pEle.forEach(cEle=>{
  718. powerLineChartData.value[pIndex].value.push({
  719. text: new Date(cEle.time).formatDate("hh:mm:ss"),
  720. value: cEle.value1
  721. });
  722. });
  723. });
  724. this.powerLineChartData = powerLineChartData;
  725. this.dialogShow = true;
  726. },
  727. // 显示计划电量完成情况图表
  728. showDownChart(res){
  729. this.dialogTitle = res.dialogTitle;
  730. this.dialogType = res.dialogType;
  731. this.doneLineChartData = res.data;
  732. this.dialogShow = true;
  733. },
  734. // 地图进入事件
  735. onEnter() {
  736. this.powerplanShowSingle = true;
  737. },
  738. // 地图退出事件
  739. onBack() {
  740. this.powerplanShowSingle = false;
  741. },
  742. },
  743. created () {
  744. let that = this;
  745. that.$nextTick(() => {
  746. that.requestData(false);
  747. that.timmer = setInterval(() => {
  748. that.requestData(false);
  749. }, that.$store.state.websocketTimeSec);
  750. });
  751. },
  752. unmounted () {
  753. clearInterval(this.timmer);
  754. this.timmer = null;
  755. }
  756. };
  757. </script>
  758. <style lang="less" scoped>
  759. .grid-content {
  760. background: #333;
  761. height: 1.111vh;
  762. }
  763. .table-card {
  764. background: rgba(255, 255, 255, 0.1);
  765. border-collapse: collapse;
  766. width: 100%;
  767. tr {
  768. font-size: @fontsize-s;
  769. td {
  770. border: 0.093vh solid @darkgray;
  771. padding: 0.556vh 0.741vh;
  772. &.text {
  773. }
  774. &.value {
  775. text-align: right;
  776. font-family: @font-family-num;
  777. }
  778. &.unit {
  779. }
  780. }
  781. }
  782. }
  783. .tools {
  784. display: flex;
  785. .tool-block {
  786. display: flex;
  787. align-items: center;
  788. margin-left: 0.741vh;
  789. .legend {
  790. flex: auto;
  791. width: 0.741vh;
  792. height: 0.741vh;
  793. margin-right: 0.741vh;
  794. &.long {
  795. width: 2.963vh;
  796. height: 0.37vh;
  797. }
  798. }
  799. .legend-text {
  800. color: #ffffff4d;
  801. }
  802. }
  803. }
  804. .situation {
  805. width: 100%;
  806. height: 100%;
  807. .situation-body {
  808. display: flex;
  809. flex-direction: column;
  810. justify-content: center;
  811. height: 100%;
  812. .situation-item {
  813. display: flex;
  814. align-content: center;
  815. flex: 1 1 auto;
  816. align-items: center;
  817. .icon {
  818. svg {
  819. width: 4.167vh;
  820. height: 4.167vh;
  821. }
  822. }
  823. &.fengji {
  824. flex: 0 1 7.99vw;
  825. .info .value {
  826. font-size: 1.852vh;
  827. }
  828. }
  829. .fengji-icon {
  830. padding: 1.111vh;
  831. border-radius: 50%;
  832. box-shadow: inset 1.5px -1px 1px 0px @green;
  833. svg {
  834. width: 2.593vh;
  835. height: 2.593vh;
  836. }
  837. }
  838. .info {
  839. display: flex;
  840. flex-direction: column;
  841. justify-content: center;
  842. margin-left: 0.741vh;
  843. .title {
  844. font-size: @fontsize;
  845. margin-bottom: 0.741vh;
  846. }
  847. .text {
  848. margin-right: 0.741vh;
  849. }
  850. .value {
  851. text-align: right;
  852. font-size: @fontsize-s;
  853. }
  854. }
  855. }
  856. }
  857. }
  858. </style>