index.vue 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966
  1. <template>
  2. <div class="draught-fan-list">
  3. <div class="form-wrapper">
  4. <div class="search mg-b-8">
  5. <div class="search-items">
  6. <div class="search-item">
  7. <div class="lable">电站:</div>
  8. <div class="search-content">
  9. <el-select
  10. v-model="station"
  11. clearable
  12. size="mini"
  13. placeholder="请选择"
  14. popper-class="select"
  15. @change="
  16. (station) => {
  17. getWt(station, true);
  18. }
  19. "
  20. >
  21. <el-option
  22. v-for="item in wpArray"
  23. :key="item.id"
  24. :value="item.id"
  25. :label="item.name"
  26. />
  27. </el-select>
  28. </div>
  29. </div>
  30. <div class="search-item">
  31. <div class="lable">设备:</div>
  32. <div class="search-content">
  33. <el-select
  34. v-model="inverters"
  35. clearable
  36. :multiple="isMultiple"
  37. collapse-tags
  38. collapse-tags-tooltip
  39. size="mini"
  40. placeholder="请选择"
  41. popper-class="select"
  42. >
  43. <el-checkbox
  44. v-if="isMultiple"
  45. v-model="checked"
  46. :indeterminate="indeterminate"
  47. @change="selectAll"
  48. >全选</el-checkbox
  49. >
  50. <el-option
  51. v-for="item in wtArray"
  52. :key="item.id"
  53. :value="item.id"
  54. :label="item.name"
  55. />
  56. </el-select>
  57. </div>
  58. </div>
  59. <div class="search-item">
  60. <div class="lable">开始时间:</div>
  61. <div class="search-content">
  62. <el-date-picker
  63. v-model="startdate"
  64. type="datetime"
  65. size="mini"
  66. :disabled-date="disabledDate"
  67. placeholder="选择日期时间"
  68. popper-class="date-select"
  69. >
  70. </el-date-picker>
  71. </div>
  72. </div>
  73. <div class="search-item">
  74. <div class="lable">结束时间:</div>
  75. <div class="search-content">
  76. <el-date-picker
  77. v-model="enddate"
  78. type="datetime"
  79. :disabled-date="disabledDate2"
  80. size="mini"
  81. placeholder="选择日期时间"
  82. popper-class="date-select"
  83. >
  84. </el-date-picker>
  85. </div>
  86. </div>
  87. <div class="search-item custom">
  88. <div class="lable">等间隔:</div>
  89. <div class="search-content" style="width: 530px">
  90. <el-radio-group v-model="interval">
  91. <el-radio
  92. v-for="item in radioList"
  93. :key="item.code"
  94. size="mini"
  95. :label="item.code"
  96. >{{ item.name }}</el-radio
  97. >
  98. </el-radio-group>
  99. </div>
  100. </div>
  101. </div>
  102. <div class="search-actions">
  103. <el-button size="mini" class="btn-search" @click="search"
  104. >曲线拟合</el-button
  105. >
  106. <!-- <el-button
  107. size="mini"
  108. :class="{ 'btn-active': isChartArea }"
  109. :disabled="!seriesData?.length"
  110. @click="funChartArea"
  111. >区域划分</el-button
  112. > -->
  113. </div>
  114. </div>
  115. <div class="search mg-b-8">
  116. <div class="search-items">
  117. <div class="search-item">
  118. <div class="lable">最大辐照强度:</div>
  119. <div class="search-content">
  120. <el-input-number
  121. v-model="maxs"
  122. size="mini"
  123. clearable
  124. :min="mins + 1"
  125. :max="5000"
  126. placeholder="请选择"
  127. popper-class="select"
  128. >
  129. </el-input-number>
  130. </div>
  131. </div>
  132. <div class="search-item">
  133. <div class="lable">最小辐照强度:</div>
  134. <div class="search-content">
  135. <el-input-number
  136. v-model="mins"
  137. size="mini"
  138. clearable
  139. :min="0"
  140. :max="maxs - 1"
  141. placeholder="请选择"
  142. popper-class="select"
  143. >
  144. </el-input-number>
  145. </div>
  146. </div>
  147. <div class="search-item">
  148. <div class="lable">最大功率:</div>
  149. <div class="search-content">
  150. <el-input-number
  151. v-model="maxpower"
  152. size="mini"
  153. clearable
  154. :min="minpower + 1"
  155. placeholder="请选择"
  156. popper-class="select"
  157. >
  158. </el-input-number>
  159. </div>
  160. </div>
  161. <div class="search-item">
  162. <div class="lable">最小功率:</div>
  163. <div class="search-content">
  164. <el-input-number
  165. v-model="minpower"
  166. size="mini"
  167. :min="0"
  168. clearable
  169. placeholder="请选择"
  170. popper-class="select"
  171. >
  172. </el-input-number>
  173. </div>
  174. </div>
  175. <div class="search-item">
  176. <div class="lable">多项式:</div>
  177. <div class="search-content">
  178. <el-select v-model="dimension" size="mini">
  179. <el-option
  180. v-for="item in 10"
  181. :key="item"
  182. :value="item"
  183. :label="item"
  184. />
  185. </el-select>
  186. </div>
  187. </div>
  188. <div class="search-item">
  189. <div class="lable">拟合方式:</div>
  190. <div class="search-content">
  191. <el-select v-model="mode" size="mini">
  192. <el-option
  193. v-for="item in selectList"
  194. :key="item.code"
  195. size="mini"
  196. :value="item.code"
  197. :label="item.name"
  198. />
  199. </el-select>
  200. </div>
  201. </div>
  202. </div>
  203. </div>
  204. </div>
  205. <div style="height: calc(100% - 40px); padding-bottom: 10px">
  206. <el-tabs v-model="activeTab">
  207. <el-tab-pane label="图表展示" name="2"> </el-tab-pane>
  208. <div style="height: 100%">
  209. <CurrentScatterChart
  210. ref="chartRef"
  211. width="100%"
  212. height="100%"
  213. :chartTitle="''"
  214. :xAxisData="xAxisData"
  215. :yAxisData="{ splitLine: { show: false } }"
  216. :seriesData="seriesData"
  217. :showLegend="true"
  218. :brushSelected="isChartArea"
  219. :dataSet="dataSet"
  220. @getSelected="funChartSelect"
  221. @closeBrush="
  222. (val) => {
  223. isChartArea = val;
  224. }
  225. "
  226. />
  227. </div>
  228. </el-tabs>
  229. </div>
  230. <el-dialog v-model="wtDialog" width="60%" top="120px" draggable>
  231. <template #title>
  232. <div class="dialog-title">
  233. <div class="title">设备功率点位</div>
  234. </div>
  235. </template>
  236. <el-tabs v-model="wtTab">
  237. <el-tab-pane label="数据" name="table">
  238. <el-table :data="wtData" row-key="id" :max-height="550">
  239. <el-table-column property="inverter" align="center" label="设备" />
  240. <el-table-column
  241. property="datetime"
  242. sortable
  243. width="200"
  244. align="center"
  245. label="时间"
  246. />
  247. <el-table-column
  248. property="S"
  249. sortable
  250. width="140"
  251. align="center"
  252. label="光照(W/m²)"
  253. />
  254. <el-table-column
  255. property="actualP"
  256. sortable
  257. width="140"
  258. align="center"
  259. label="功率(kW)"
  260. />
  261. <el-table-column
  262. property="T"
  263. sortable
  264. width="140"
  265. align="center"
  266. label="温度(℃)"
  267. />
  268. <el-table-column
  269. property="filter"
  270. sortable
  271. width="140"
  272. align="center"
  273. label="是否有用点"
  274. />
  275. </el-table>
  276. </el-tab-pane>
  277. <el-tab-pane label="故障" name="problem" disabled> </el-tab-pane>
  278. <el-tab-pane label="预警" name="warning" disabled> </el-tab-pane>
  279. </el-tabs>
  280. </el-dialog>
  281. </div>
  282. </template>
  283. <script>
  284. // import ScatterLineChart from "@com/chart/combination/scatter-line-chart.vue";
  285. import tableCop from "./components/table.vue";
  286. import CurrentScatterChart from "./components/current-scatter-chart.vue";
  287. import api1 from "@api/economic/index.js";
  288. // import api from "@api/wisdomOverhaul/energy/index.js";
  289. import dayjs from "dayjs";
  290. import {
  291. getIntervers,
  292. getPowerFittingGF,
  293. getPowerHotChartGF,
  294. getPowerFittingChart,
  295. getPowerFittingTable,
  296. getPowerFittingSelectedChartGF,
  297. } from "@/api/powerAnalyse.js";
  298. export default {
  299. // 名称
  300. name: "powerHotAnalyse",
  301. // 使用组件
  302. components: {
  303. // ScatterLineChart,
  304. CurrentScatterChart,
  305. tableCop,
  306. },
  307. // 数据
  308. data() {
  309. return {
  310. activeTab: "2",
  311. checkList: [
  312. { name: "非并网", code: "isfbw" },
  313. { name: "非合理值", code: "isfhl" },
  314. { name: "并网后十分钟", code: "isbw" },
  315. { name: "停机前十分钟", code: "istj" },
  316. { name: "功率曲线偏差", code: "isglpc" },
  317. ],
  318. selectList: [
  319. { name: "单台拟合", code: 0 },
  320. { name: "合并拟合", code: 1 },
  321. // { name: "同名拟合", code: 2 },
  322. ],
  323. radioList: [
  324. { name: "一秒钟", code: 1 },
  325. { name: "一分钟", code: 60 },
  326. { name: "十分钟", code: 600 },
  327. { name: "十五分钟", code: 900 },
  328. ],
  329. isAsc: "asc",
  330. wpArray: [],
  331. wtArray: [],
  332. station: "",
  333. inverters: "",
  334. startdate: dayjs()
  335. // .add(-1, "month")
  336. .startOf("month")
  337. .format("YYYY-MM-DD HH:mm:ss"),
  338. enddate: dayjs().startOf("day").format("YYYY-MM-DD HH:mm:ss"),
  339. interval: 600,
  340. maxs: 5000,
  341. mins: 0,
  342. maxpower: 2500,
  343. minpower: 0,
  344. checkedList: ["isfbw", "isfhl", "isbw", "istj", "isglpc"],
  345. dimension: 10,
  346. mode: 0,
  347. fittingId: "",
  348. seriesData: [],
  349. avgObj: {
  350. //平均cpz等
  351. title: "",
  352. cpavg: "",
  353. frequency: "",
  354. pcratio: "",
  355. },
  356. markDot: {
  357. //3-5 point点等
  358. pcl5: null,
  359. pcl10: null,
  360. pcl12: null,
  361. pcl25: null,
  362. },
  363. xAxisData: [],
  364. dataSet: "",
  365. isChartArea: true,
  366. tableShowId: "",
  367. tableColumn: [],
  368. tableLoading: false,
  369. tableName: "",
  370. tableData: [],
  371. wtTab: "table",
  372. wtDialog: false,
  373. wtData: [],
  374. isMultiple: false,
  375. checked: false,
  376. indeterminate: false,
  377. };
  378. },
  379. created() {
  380. this.getWp();
  381. },
  382. watch: {
  383. mode(val) {
  384. if (val == 0) {
  385. this.isMultiple = false;
  386. this.inverters =
  387. typeof this.inverters == "string"
  388. ? this.inverters
  389. : this.inverters.length
  390. ? this.inverters[0]
  391. : [];
  392. } else {
  393. this.isMultiple = true;
  394. this.inverters =
  395. typeof this.inverters == "string"
  396. ? [this.inverters]
  397. : [...this.inverters];
  398. }
  399. },
  400. inverters: {
  401. handler(newVal, oldVal) {
  402. this.$nextTick(() => {
  403. if (this.isMultiple) {
  404. this.inverters = newVal;
  405. if (this.wtArray.length && this.inverters) {
  406. if (this.inverters.length === this.wtArray.length) {
  407. this.checked = true;
  408. this.indeterminate = false;
  409. } else if (this.inverters.length < this.wtArray.length) {
  410. this.checked = false;
  411. if (this.inverters.length != 0) {
  412. this.indeterminate = true;
  413. }
  414. if (newVal.length == 0) {
  415. this.$message.error("必须至少选择一项");
  416. this.inverters = oldVal;
  417. }
  418. }
  419. }
  420. }
  421. });
  422. },
  423. immediate: true,
  424. },
  425. },
  426. // 函数
  427. methods: {
  428. selectAll() {
  429. if (this.checked) {
  430. this.wtArray.forEach((item) => {
  431. this.inverters.push(item.id);
  432. });
  433. this.inverters = [...new Set(this.inverters)];
  434. this.indeterminate = false;
  435. } else {
  436. this.inverters = [this.wtArray[0].id];
  437. }
  438. },
  439. // 时间选择器第一个禁用
  440. disabledDate(time) {
  441. if (this.enddate) {
  442. return time.getTime() > Date.parse(this.enddate);
  443. } else {
  444. return null;
  445. }
  446. },
  447. // 时间选择器第二个禁用
  448. disabledDate2(time) {
  449. if (this.startdate) {
  450. return time.getTime() < Date.parse(this.startdate);
  451. } else {
  452. return null;
  453. }
  454. },
  455. // 获取风场
  456. getWp(reGetWp) {
  457. api1
  458. .getWpList({
  459. type: "-2",
  460. })
  461. .then((res) => {
  462. if (res.data.code === 200) {
  463. this.wpArray = res.data.data;
  464. this.station = res.data.data[0].id;
  465. this.getWt(this.station, reGetWp);
  466. }
  467. });
  468. },
  469. // 获取风机
  470. getWt(wpid, reGetWp) {
  471. if (wpid) {
  472. getIntervers({
  473. wpids: wpid,
  474. }).then(({ data: res }) => {
  475. if (res.code === 200) {
  476. this.wtArray = res.data;
  477. this.inverters = res.data.length
  478. ? this.isMultiple
  479. ? [res.data[0].id]
  480. : res.data[0].id
  481. : "";
  482. if (!reGetWp) {
  483. this.search();
  484. }
  485. }
  486. });
  487. }
  488. },
  489. //获取拟合id
  490. getChartId() {
  491. this.BASE.showLoading();
  492. this.activeTab = "2";
  493. let params = {
  494. station: this.station,
  495. inverters: this.isMultiple ? this.inverters.join(",") : this.inverters,
  496. startdate: dayjs(this.startdate).valueOf(),
  497. enddate: dayjs(this.enddate).valueOf(),
  498. interval: this.interval,
  499. maxs: this.maxs,
  500. mins: this.mins,
  501. maxpower: this.maxpower,
  502. minpower: this.minpower,
  503. };
  504. this.getChartData(params);
  505. },
  506. //清空数据
  507. clear() {
  508. this.fittingId = "";
  509. this.seriesData = [];
  510. this.avgObj = {
  511. //平均cpz等
  512. title: "",
  513. cpavg: "",
  514. frequency: "",
  515. pcratio: "",
  516. };
  517. this.markDot = {
  518. //3-5 point点等
  519. pcl5: null,
  520. pcl10: null,
  521. pcl12: null,
  522. pcl25: null,
  523. };
  524. this.xAxisData = [];
  525. this.dataSet = "";
  526. },
  527. //是否区域划分
  528. funChartArea() {
  529. this.BASE.showLoading();
  530. if (this.seriesData.length) {
  531. if (!this.isChartArea) {
  532. // 请求一下
  533. this.seriesData[0] = {
  534. ...this.seriesData[0],
  535. markLine: {
  536. symbol: "none",
  537. label: {
  538. show: false,
  539. },
  540. lineStyle: {
  541. color: "rgba(96,174,255, 1)",
  542. },
  543. data: [
  544. {
  545. xAxis: 3,
  546. valueIndex: 0,
  547. },
  548. {
  549. xAxis: 5,
  550. valueIndex: 0,
  551. },
  552. {
  553. xAxis: 10,
  554. valueIndex: 0,
  555. },
  556. {
  557. xAxis: 12,
  558. valueIndex: 0,
  559. },
  560. {
  561. xAxis: 25,
  562. valueIndex: 0,
  563. },
  564. ],
  565. },
  566. markArea: {
  567. label: {
  568. fontSize: 13,
  569. color: "#ccc",
  570. fontWeight: "normal",
  571. fontFamily: "Arial",
  572. },
  573. itemStyle: {
  574. color: "rgba(236,245,255, 0)",
  575. },
  576. emphasis: {
  577. itemStyle: {
  578. color: "rgba(96,174,255, 0.5)",
  579. },
  580. },
  581. data: [
  582. [
  583. {
  584. name: `3~5m 偏差率: ${this.markDot.pcl5}%`,
  585. xAxis: 3,
  586. },
  587. {
  588. xAxis: 5,
  589. },
  590. ],
  591. [
  592. {
  593. name: `5~10m 偏差率: ${this.markDot.pcl10}%`,
  594. xAxis: 5,
  595. },
  596. {
  597. xAxis: 10,
  598. },
  599. ],
  600. [
  601. {
  602. name: `10~12m 偏差率: ${this.markDot.pcl12}%`,
  603. xAxis: 10,
  604. },
  605. {
  606. xAxis: 12,
  607. },
  608. ],
  609. [
  610. {
  611. name: `12~25m 偏差率: ${this.markDot.pcl25}%`,
  612. xAxis: 12,
  613. },
  614. {
  615. xAxis: 25,
  616. },
  617. ],
  618. ],
  619. },
  620. };
  621. this.isChartArea = true;
  622. this.BASE.closeLoading();
  623. } else {
  624. this.seriesData[0] = {
  625. ...this.seriesData[0],
  626. markLine: null,
  627. markArea: null,
  628. };
  629. this.isChartArea = false;
  630. this.BASE.closeLoading();
  631. }
  632. }
  633. },
  634. // // 获取表格数据
  635. // getTableData() {
  636. // this.tableLoading = true;
  637. // getPowerFittingTable({
  638. // id: this.fittingId,
  639. // }).then((res) => {
  640. // if (res.code == 200) {
  641. // this.tableColumn = res.data.title.map((o) => {
  642. // return {
  643. // prop: o.key,
  644. // width: o.des === "时间" ? 100 : 80,
  645. // label: o.des,
  646. // };
  647. // });
  648. // this.tableData = res.data.data;
  649. // this.$message.success(res.msg);
  650. // }
  651. // this.tableLoading = false;
  652. // });
  653. // },
  654. // 获取图表数据
  655. getChartData(params) {
  656. getPowerHotChartGF(params).then((res) => {
  657. this.tableData = [];
  658. let chartRes = {};
  659. if (res.code == 200) {
  660. chartRes = res.data;
  661. this.dataSet = JSON.stringify([
  662. {
  663. source: chartRes.wyd,
  664. },
  665. {
  666. source: chartRes.yyd,
  667. },
  668. ]);
  669. this.seriesData = [
  670. {
  671. name: "拟合功率",
  672. type: "line",
  673. lineStyle: {
  674. width: 3,
  675. color: "#3d54be",
  676. },
  677. symbol: "line", //设定为实心点
  678. symbolSize: 0, //设定实心点的大小
  679. smooth: true, //这个是把线变成曲线
  680. data: chartRes.yydnh,
  681. xAxisIndex: 0,
  682. },
  683. {
  684. type: "effectScatter",
  685. showEffectOn: "emphasis",
  686. rippleEffect: {
  687. scale: 1,
  688. },
  689. itemStyle: {
  690. color: "#ccc",
  691. },
  692. name: "无用点",
  693. symbolSize: (data) => {
  694. return data.s ? (data.s > 10 ? 10 : data.s) : 4;
  695. },
  696. datasetIndex: 0,
  697. encode: {
  698. x: "x",
  699. y: "y",
  700. },
  701. xAxisIndex: 0,
  702. yAxisIndex: 0,
  703. },
  704. {
  705. type: "effectScatter",
  706. showEffectOn: "emphasis",
  707. rippleEffect: {
  708. scale: 1,
  709. },
  710. itemStyle: {
  711. color: [
  712. {
  713. type: "linear",
  714. colorStops: [
  715. { offset: 0, color: "#000" },
  716. { offset: 0.2, color: "rgb(75,11,106)" },
  717. { offset: 0.4, color: "rgb(210,70,69)" },
  718. { offset: 0.6, color: "rgb(247,126,21)", },
  719. { offset: 1, color: "rgb(249,252,156)" },
  720. ],
  721. globalCoord: false,
  722. },
  723. ],
  724. },
  725. name: "有用点",
  726. symbolSize: (data) => {
  727. return data.s ? (data.s > 10 ? 10 : data.s) : 4;
  728. },
  729. datasetIndex: 1,
  730. encode: {
  731. x: "x",
  732. y: "y",
  733. },
  734. xAxisIndex: 0,
  735. yAxisIndex: 0,
  736. },
  737. ];
  738. this.$message.success(res.msg);
  739. } else {
  740. this.xAxisData = {};
  741. this.seriesData = {};
  742. }
  743. this.BASE.closeLoading();
  744. });
  745. },
  746. //拟合按钮
  747. search() {
  748. this.isChartArea = true;
  749. if (!this.station || !this.inverters) {
  750. this.BASE.showMsg({
  751. msg: "场站与风机为必选项",
  752. });
  753. } else {
  754. this.getChartId();
  755. }
  756. },
  757. async funChartSelect(batch) {
  758. const wDataArr = [];
  759. const yDataArr = [];
  760. let scatterls = [];
  761. let scatterhs = [];
  762. let dataSetObj = [];
  763. this.wtData = [];
  764. if (batch?.length && this.dataSet) {
  765. scatterls = batch[0].selected[1].dataIndex;
  766. scatterhs = batch[0].selected[2].dataIndex;
  767. if (scatterls?.length || scatterhs?.length) {
  768. dataSetObj = JSON.parse(this.dataSet);
  769. if (scatterls?.length) {
  770. for (const scatterIndex of scatterls) {
  771. wDataArr.push(dataSetObj[0].source[scatterIndex].k);
  772. }
  773. }
  774. if (scatterhs?.length) {
  775. for (const scatterIndex1 of scatterhs) {
  776. yDataArr.push(dataSetObj[1].source[scatterIndex1].k);
  777. }
  778. }
  779. const wtRes = await getPowerFittingSelectedChartGF({
  780. yk: yDataArr.join(","),
  781. wk: wDataArr.join(","),
  782. });
  783. if (wtRes.code === 200) {
  784. let id = 1;
  785. const tempArr = []; //用于以风机id 聚合dataArr
  786. if (wtRes.data?.length) {
  787. for (const data of wtRes.data) {
  788. if (tempArr.length) {
  789. const findIndex = tempArr.findIndex(
  790. (o) => o.wtId === data.wtId
  791. );
  792. if (findIndex !== -1) {
  793. if (!tempArr[findIndex].children) {
  794. tempArr[findIndex].children = [];
  795. }
  796. tempArr[findIndex].children.push({
  797. ...data,
  798. id: id,
  799. filter: data.filter === 0 ? "是" : "否",
  800. });
  801. id++;
  802. } else {
  803. tempArr.push({
  804. ...data,
  805. id: id,
  806. filter: data.filter === 0 ? "是" : "否",
  807. });
  808. id++;
  809. }
  810. } else {
  811. tempArr.push({
  812. ...data,
  813. id: id,
  814. filter: data.filter === 0 ? "是" : "否",
  815. });
  816. id++;
  817. }
  818. }
  819. this.wtDialog = true;
  820. this.$nextTick(() => {
  821. this.wtTab = "table";
  822. this.wtData = tempArr;
  823. });
  824. }
  825. }
  826. }
  827. }
  828. },
  829. },
  830. unmounted() {},
  831. };
  832. </script>
  833. <style lang="less" scoped>
  834. .draught-fan-list {
  835. width: 100%;
  836. height: 100%;
  837. display: flex;
  838. flex-direction: column;
  839. padding: 10px 20px;
  840. .form-wrapper ::v-deep {
  841. .el-checkbox__input {
  842. display: block;
  843. }
  844. .el-input-number {
  845. width: 100%;
  846. .el-input-number__decrease,
  847. .el-input-number__increase {
  848. background: rgba(67, 81, 107, 0.2) !important;
  849. position: absolute;
  850. z-index: 10;
  851. border: 0;
  852. // height: 33px;
  853. // line-height: 33px;
  854. &:hover {
  855. color: #05be4c;
  856. }
  857. }
  858. }
  859. .el-date-editor {
  860. width: 100%;
  861. }
  862. .el-select {
  863. width: 100%;
  864. .el-select__tags {
  865. max-width: 140px !important;
  866. .el-select__tags-text {
  867. max-width: 62px !important;
  868. }
  869. }
  870. }
  871. .el-radio-group {
  872. width: 100%;
  873. display: flex;
  874. .el-radio {
  875. flex: 1;
  876. }
  877. }
  878. .search {
  879. display: flex;
  880. align-items: center;
  881. .search-items {
  882. display: flex;
  883. align-items: center;
  884. .search-item {
  885. width: 296px;
  886. display: flex;
  887. align-items: center;
  888. margin-right: 10px;
  889. .lable {
  890. font-size: 14px;
  891. font-family: Microsoft YaHei;
  892. font-weight: 400;
  893. color: #b3b3b3;
  894. margin-right: 5px;
  895. width: 84px;
  896. text-align: right;
  897. white-space: nowrap;
  898. }
  899. .search-content {
  900. flex: 1;
  901. }
  902. &:nth-last-child(1) {
  903. margin-right: 0;
  904. }
  905. }
  906. .custom {
  907. width: auto;
  908. }
  909. }
  910. .search-actions {
  911. top: 152px;
  912. right: 75px;
  913. position: absolute;
  914. z-index: 88;
  915. .el-button {
  916. background-color: rgba(5, 187, 76, 0.3);
  917. border: 1px solid #3b6c53;
  918. color: #b3b3b3;
  919. font-size: 14px;
  920. border: none;
  921. width: 108px;
  922. min-height: 25px !important;
  923. &.btn-search:hover {
  924. background-color: rgba(5, 187, 76, 0.6);
  925. color: #ffffff;
  926. }
  927. }
  928. .btn-active {
  929. background-color: rgba(5, 187, 76, 0.6);
  930. color: #ffffff;
  931. }
  932. }
  933. &:nth-last-child(1) {
  934. justify-content: space-between;
  935. }
  936. }
  937. }
  938. .el-tabs ::v-deep {
  939. height: 100%;
  940. .el-tabs__item {
  941. color: #b3b3b3;
  942. }
  943. .el-tabs__nav-wrap::after {
  944. background-color: #14221f;
  945. }
  946. .el-tabs__active-bar {
  947. background-color: #05bb4c;
  948. }
  949. .el-tabs__item.is-active,
  950. .el-tabs__item:hover {
  951. color: #05bb4c;
  952. }
  953. .el-tabs__content {
  954. height: calc(100% - 40px);
  955. }
  956. }
  957. }
  958. </style>