Health1.vue 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498
  1. <template>
  2. <div class="health-1">
  3. <div class="selections mg-b-16">
  4. <div class="item" @click="tabSelect(0)" :class="{ active: tabIndex == 0 }">未确认缺陷</div>
  5. <div class="item" @click="tabSelect(1)" :class="{ active: tabIndex == 1 }">未确认缺陷</div>
  6. <div class="item" @click="tabSelect(2)" :class="{ active: tabIndex == 2 }">未确认缺陷</div>
  7. <div class="item" @click="tabSelect(3)" :class="{ active: tabIndex == 3 }">未确认缺陷</div>
  8. </div>
  9. <div v-if="tabIndex == 0">
  10. <div class="power-info mg-b-16">
  11. <div class="info-tab">
  12. <div class="tab active">
  13. <i class="svg-icon svg-icon svg-icon-sm">
  14. <svg-icon :svgid="'svg-24-houre'" />
  15. </i>
  16. <span> 24小时健康趋势 </span>
  17. </div>
  18. <div class="tab">
  19. <i class="svg-icon svg-icon svg-icon-sm">
  20. <svg-icon :svgid="'svg-h-day'" />
  21. </i>
  22. <span> 7日健康趋势 </span>
  23. </div>
  24. <div class="tab">
  25. <i class="svg-icon svg-icon svg-icon-sm">
  26. <svg-icon :svgid="'svg-h-month'" />
  27. </i>
  28. <span>30日健康趋势</span>
  29. </div>
  30. <div class="empty"></div>
  31. <div class="tab">
  32. <span>全部风场健康趋势</span>
  33. </div>
  34. </div>
  35. <div class="info-chart">
  36. <panel class="info-chart-panel" :title="'损失电量分析'">
  37. <vertival-bar-line-chart :height="'250px'" />
  38. </panel>
  39. </div>
  40. </div>
  41. <div class="health-report">
  42. <panel class="health-report-panel" :title="'健康报告'" :showLine="false">
  43. <div class="actions mg-b-16">
  44. <div class="item green">当日内推荐</div>
  45. <div class="item purple">三日内推荐</div>
  46. <div class="item gray">超三日推荐</div>
  47. </div>
  48. <el-scrollbar>
  49. <div class="report-items">
  50. <div class="item">
  51. <div class="title">风机编号:QG01_04</div>
  52. <div class="info">
  53. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  54. <p>推荐检修时间:2021-06-04 16:00:00</p>
  55. <p>推荐时间对应风速:2.4</p>
  56. <p>判断时间:2021-05-27 08:20:00</p>
  57. <div class="actions mg-t-16">
  58. <button class="btn success">
  59. <i class="fa fa-check"></i>
  60. 提交
  61. </button>
  62. <button class="btn">
  63. <i class="fa fa-close"></i>
  64. 取消
  65. </button>
  66. </div>
  67. </div>
  68. </div>
  69. <div class="item">
  70. <div class="title">风机编号:QG01_04</div>
  71. <div class="info">
  72. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  73. <p>推荐检修时间:2021-06-04 16:00:00</p>
  74. <p>推荐时间对应风速:2.4</p>
  75. <p>判断时间:2021-05-27 08:20:00</p>
  76. <div class="actions mg-t-16">
  77. <button class="btn success">
  78. <i class="fa fa-check"></i>
  79. 提交
  80. </button>
  81. <button class="btn">
  82. <i class="fa fa-close"></i>
  83. 取消
  84. </button>
  85. </div>
  86. </div>
  87. </div>
  88. <div class="item">
  89. <div class="title">风机编号:QG01_04</div>
  90. <div class="info">
  91. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  92. <p>推荐检修时间:2021-06-04 16:00:00</p>
  93. <p>推荐时间对应风速:2.4</p>
  94. <p>判断时间:2021-05-27 08:20:00</p>
  95. <div class="actions mg-t-16">
  96. <button class="btn success">
  97. <i class="fa fa-check"></i>
  98. 提交
  99. </button>
  100. <button class="btn">
  101. <i class="fa fa-close"></i>
  102. 取消
  103. </button>
  104. </div>
  105. </div>
  106. </div>
  107. <div class="item">
  108. <div class="title">风机编号:QG01_04</div>
  109. <div class="info">
  110. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  111. <p>推荐检修时间:2021-06-04 16:00:00</p>
  112. <p>推荐时间对应风速:2.4</p>
  113. <p>判断时间:2021-05-27 08:20:00</p>
  114. <div class="actions mg-t-16">
  115. <button class="btn success">
  116. <i class="fa fa-check"></i>
  117. 提交
  118. </button>
  119. <button class="btn">
  120. <i class="fa fa-close"></i>
  121. 取消
  122. </button>
  123. </div>
  124. </div>
  125. </div>
  126. <div class="item">
  127. <div class="title">风机编号:QG01_04</div>
  128. <div class="info">
  129. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  130. <p>推荐检修时间:2021-06-04 16:00:00</p>
  131. <p>推荐时间对应风速:2.4</p>
  132. <p>判断时间:2021-05-27 08:20:00</p>
  133. <div class="actions mg-t-16">
  134. <button class="btn success">
  135. <i class="fa fa-check"></i>
  136. 提交
  137. </button>
  138. <button class="btn">
  139. <i class="fa fa-close"></i>
  140. 取消
  141. </button>
  142. </div>
  143. </div>
  144. </div>
  145. <div class="item">
  146. <div class="title">风机编号:QG01_04</div>
  147. <div class="info">
  148. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  149. <p>推荐检修时间:2021-06-04 16:00:00</p>
  150. <p>推荐时间对应风速:2.4</p>
  151. <p>判断时间:2021-05-27 08:20:00</p>
  152. <div class="actions mg-t-16">
  153. <button class="btn success">
  154. <i class="fa fa-check"></i>
  155. 提交
  156. </button>
  157. <button class="btn">
  158. <i class="fa fa-close"></i>
  159. 取消
  160. </button>
  161. </div>
  162. </div>
  163. </div>
  164. <div class="item">
  165. <div class="title">风机编号:QG01_04</div>
  166. <div class="info">
  167. <p>推荐理由:大风额定出力曲线偏差大于基准 值同时等级评估级别过低</p>
  168. <p>推荐检修时间:2021-06-04 16:00:00</p>
  169. <p>推荐时间对应风速:2.4</p>
  170. <p>判断时间:2021-05-27 08:20:00</p>
  171. <div class="actions mg-t-16">
  172. <button class="btn success">
  173. <i class="fa fa-check"></i>
  174. 提交
  175. </button>
  176. <button class="btn">
  177. <i class="fa fa-close"></i>
  178. 取消
  179. </button>
  180. </div>
  181. </div>
  182. </div>
  183. </div>
  184. </el-scrollbar>
  185. </panel>
  186. </div>
  187. </div>
  188. <div v-if="tabIndex == 1">
  189. <health-2 />
  190. </div>
  191. <div v-if="tabIndex == 2">
  192. <button class="btn" @click="dialogVisible = true">点击弹窗</button>
  193. <button class="btn" @click="dialog2Visible = true">消缺跟踪弹窗</button>
  194. <button class="btn" @click="dialog3Visible = true">指标排行弹窗</button>
  195. <button class="btn" @click="dialog4Visible = true">故障诊断弹窗</button>
  196. <button class="btn" @click="showMessage">消息提醒</button>
  197. <button class="btn" @click="showComfirm">操作确认</button>
  198. <el-dialog title="日信息对比" v-model="dialogVisible" width="70%" top="10vh" custom-class="modal" :close-on-click-modal="false">
  199. <dayinfo />
  200. </el-dialog>
  201. <el-dialog title="消缺跟踪" v-model="dialog2Visible" width="1400px" top="10vh" custom-class="modal" :close-on-click-modal="false">
  202. <Track />
  203. </el-dialog>
  204. <el-dialog title="风功率曲线" v-model="dialog3Visible" width="1400px" top="10vh" custom-class="modal" :close-on-click-modal="false">
  205. <RankingPop />
  206. </el-dialog>
  207. <el-dialog title="故障诊断" v-model="dialog4Visible" width="1400px" top="10vh" custom-class="modal hide-header" :close-on-click-modal="false">
  208. <FaultDiagnosis />
  209. </el-dialog>
  210. </div>
  211. <div v-if="tabIndex == 3">
  212. tab4
  213. </div>
  214. </div>
  215. </template>
  216. <script>
  217. import VertivalBarLineChart from "../../components/chart/combination/vertival-bar-line-chart.vue";
  218. import SvgIcon from "../../components/coms/icon/svg-icon.vue";
  219. import Panel from "../../components/coms/panel/panel.vue";
  220. import Dayinfo from "./dayinfo.vue";
  221. import Health2 from "./Health2.vue";
  222. import Track from "./track.vue";
  223. import RankingPop from "./ranking-pop.vue";
  224. import FaultDiagnosis from "./fault-diagnosis.vue";
  225. export default {
  226. setup() {},
  227. components: { SvgIcon, Panel, VertivalBarLineChart, Health2, Dayinfo, Track, RankingPop, FaultDiagnosis },
  228. data() {
  229. return {
  230. tabIndex: 0,
  231. dialogVisible: false,
  232. dialog2Visible: false,
  233. dialog3Visible: false,
  234. dialog4Visible: false,
  235. };
  236. },
  237. methods: {
  238. tabSelect(state) {
  239. this.tabIndex = state;
  240. },
  241. showMessage() {
  242. this.$alert("这是一段内容", "标题名称", {
  243. confirmButtonText: "确定",
  244. callback: (action) => {
  245. this.$message({
  246. type: "info",
  247. message: `action: ${action}`,
  248. });
  249. // this.$message({
  250. // type: "warning",
  251. // message: `action: ${action}`,
  252. // });
  253. // this.$message({
  254. // type: "success",
  255. // message: `action: ${action}`,
  256. // });
  257. // this.$message({
  258. // type: "error",
  259. // message: `action: ${action}`,
  260. // });
  261. },
  262. });
  263. },
  264. showComfirm() {
  265. this.$confirm("此操作将永久删除该文件, 是否继续?", "提示", {
  266. confirmButtonText: "确定",
  267. cancelButtonText: "取消",
  268. type: "warning",
  269. center: true,
  270. })
  271. .then(() => {
  272. this.$message({
  273. type: "success",
  274. message: "删除成功!",
  275. });
  276. })
  277. .catch(() => {
  278. this.$message({
  279. type: "info",
  280. message: "已取消删除",
  281. });
  282. });
  283. },
  284. },
  285. };
  286. </script>
  287. <style lang="less">
  288. .health-1 {
  289. .selections {
  290. display: flex;
  291. .item {
  292. flex: 0 0 128px;
  293. text-align: center;
  294. height: 33px;
  295. line-height: 33px;
  296. margin-right: 8px;
  297. color: @font-color;
  298. font-size: @fontsize-s;
  299. background: fade(@gray, 20);
  300. border: 1px solid fade(@gray, 20);
  301. &:hover,
  302. &.active {
  303. background: fade(@green, 20);
  304. border: 1px solid @green;
  305. color: @green;
  306. cursor: pointer;
  307. }
  308. }
  309. }
  310. .power-info {
  311. display: flex;
  312. .info-tab {
  313. flex: 0 0 156px;
  314. display: flex;
  315. flex-direction: column;
  316. height: 287px;
  317. margin-right: 1.4815vh;
  318. .tab {
  319. position: relative;
  320. flex: 0 0 auto;
  321. text-align: center;
  322. height: 33px;
  323. line-height: 33px;
  324. margin-right: 8px;
  325. color: @gray-l;
  326. font-size: 12px;
  327. background: fade(@gray, 20);
  328. border: 1px solid fade(@gray, 20);
  329. display: flex;
  330. align-items: center;
  331. i {
  332. margin: 0 1.4815vh;
  333. svg use {
  334. fill: @gray-l;
  335. }
  336. }
  337. &:hover,
  338. &.active {
  339. background: fade(@green, 20);
  340. border: 1px solid @green;
  341. color: @green;
  342. cursor: pointer;
  343. i svg use {
  344. fill: @green;
  345. }
  346. }
  347. &.active::after {
  348. box-sizing: content-box;
  349. width: 0px;
  350. height: 0px;
  351. position: absolute;
  352. right: -19px;
  353. padding: 0;
  354. border-bottom: 9px solid @green;
  355. border-top: 9px solid transparent;
  356. border-left: 9px solid transparent;
  357. border-right: 9px solid transparent;
  358. display: block;
  359. content: "";
  360. z-index: 10;
  361. transform: rotate(90deg);
  362. }
  363. &.active::before {
  364. box-sizing: content-box;
  365. width: 0px;
  366. height: 0px;
  367. position: absolute;
  368. right: -17px;
  369. padding: 0;
  370. border-bottom: 9px solid #063319;
  371. border-top: 9px solid transparent;
  372. border-left: 9px solid transparent;
  373. border-right: 9px solid transparent;
  374. display: block;
  375. content: "";
  376. z-index: 12;
  377. transform: rotate(90deg);
  378. }
  379. & + .tab {
  380. margin-top: 0.7407vh;
  381. }
  382. &:last-child {
  383. text-align: center;
  384. justify-content: center;
  385. }
  386. }
  387. .empty {
  388. flex: 1 0 auto;
  389. }
  390. }
  391. .info-chart {
  392. flex: 1 0 auto;
  393. }
  394. }
  395. .health-report {
  396. // 健康报告 按钮样式
  397. .actions {
  398. display: flex;
  399. .item {
  400. flex: 0 0 102px;
  401. text-align: center;
  402. line-height: 33px;
  403. margin-right: 8px;
  404. color: fade(@white, 75);
  405. font-size: @fontsize-s;
  406. &.green {
  407. background: @green;
  408. }
  409. &.purple {
  410. background: @purple;
  411. }
  412. &.gray {
  413. background: @gray;
  414. }
  415. }
  416. }
  417. .report-items {
  418. display: flex;
  419. flex-wrap: wrap;
  420. height: calc(100vh - 500px);
  421. .item {
  422. flex: 0 0 calc(100% / 6 - 16px);
  423. margin-bottom: 16px;
  424. & + .item {
  425. margin-left: 16px;
  426. }
  427. &:nth-child(6n + 1) {
  428. margin-left: 0px;
  429. }
  430. .title {
  431. background: fade(@gray, 40);
  432. // color: fade(@white, 75);
  433. color: @gray-l;
  434. line-height: 37px;
  435. padding-left: 16px;
  436. font-size: @fontsize-s;
  437. }
  438. .info {
  439. background: fade(@gray, 20);
  440. padding: 16px;
  441. font-size: @fontsize-s;
  442. color: @font-color;
  443. line-height: 1.5;
  444. p {
  445. margin: 0;
  446. line-height: 2;
  447. }
  448. .actions {
  449. display: flex;
  450. align-items: center;
  451. justify-content: center;
  452. .success {
  453. border-color: #05bb4c;
  454. color: #05bb4c;
  455. background: rgba(5, 187, 76, 0.2);
  456. }
  457. }
  458. }
  459. }
  460. }
  461. }
  462. }
  463. </style>