Health1.vue 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484
  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="'310px'" />
  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. <el-dialog title="日信息对比" v-model="dialogVisible" width="70%" top="10vh" custom-class="modal" :close-on-click-modal="false">
  195. <dayinfo />
  196. </el-dialog>
  197. <el-dialog title="消缺跟踪" v-model="dialog2Visible" width="1400px" top="10vh" custom-class="modal" :close-on-click-modal="false">
  198. <Track />
  199. </el-dialog>
  200. <button class="btn" @click="showMessage">消息提醒</button>
  201. <button class="btn" @click="showComfirm">操作确认</button>
  202. </div>
  203. <div v-if="tabIndex == 3">
  204. tab4
  205. </div>
  206. </div>
  207. </template>
  208. <script>
  209. import VertivalBarLineChart from "../../components/chart/combination/vertival-bar-line-chart.vue";
  210. import SvgIcon from "../../components/coms/icon/svg-icon.vue";
  211. import Panel from "../../components/coms/panel/panel.vue";
  212. import Dayinfo from "./dayinfo.vue";
  213. import Health2 from "./Health2.vue";
  214. import Track from "./track.vue";
  215. export default {
  216. setup() {},
  217. components: { SvgIcon, Panel, VertivalBarLineChart, Health2, Dayinfo, Track },
  218. data() {
  219. return {
  220. tabIndex: 0,
  221. dialogVisible: false,
  222. dialog2Visible: false,
  223. };
  224. },
  225. methods: {
  226. tabSelect(state) {
  227. this.tabIndex = state;
  228. },
  229. showMessage() {
  230. this.$alert("这是一段内容", "标题名称", {
  231. confirmButtonText: "确定",
  232. callback: (action) => {
  233. this.$message({
  234. type: "info",
  235. message: `action: ${action}`,
  236. });
  237. // this.$message({
  238. // type: "warning",
  239. // message: `action: ${action}`,
  240. // });
  241. // this.$message({
  242. // type: "success",
  243. // message: `action: ${action}`,
  244. // });
  245. // this.$message({
  246. // type: "error",
  247. // message: `action: ${action}`,
  248. // });
  249. },
  250. });
  251. },
  252. showComfirm() {
  253. this.$confirm("此操作将永久删除该文件, 是否继续?", "提示", {
  254. confirmButtonText: "确定",
  255. cancelButtonText: "取消",
  256. type: "warning",
  257. center: true,
  258. })
  259. .then(() => {
  260. this.$message({
  261. type: "success",
  262. message: "删除成功!",
  263. });
  264. })
  265. .catch(() => {
  266. this.$message({
  267. type: "info",
  268. message: "已取消删除",
  269. });
  270. });
  271. },
  272. },
  273. };
  274. </script>
  275. <style lang="less">
  276. .health-1 {
  277. .selections {
  278. display: flex;
  279. .item {
  280. flex: 0 0 128px;
  281. text-align: center;
  282. line-height: 33px;
  283. margin-right: 8px;
  284. color: @font-color;
  285. font-size: @fontsize-s;
  286. background: fade(@gray, 20);
  287. border: 1px solid fade(@gray, 20);
  288. &:hover,
  289. &.active {
  290. background: fade(@green, 20);
  291. border: 1px solid @green;
  292. color: @green;
  293. cursor: pointer;
  294. }
  295. }
  296. }
  297. .power-info {
  298. display: flex;
  299. .info-tab {
  300. flex: 0 0 156px;
  301. display: flex;
  302. flex-direction: column;
  303. height: 350px;
  304. margin-right: 1.4815vh;
  305. .tab {
  306. position: relative;
  307. flex: 0 0 auto;
  308. text-align: center;
  309. line-height: 33px;
  310. margin-right: 8px;
  311. color: @gray-l;
  312. font-size: 12px;
  313. background: fade(@gray, 20);
  314. border: 1px solid fade(@gray, 20);
  315. display: flex;
  316. align-items: center;
  317. i {
  318. margin: 0 1.4815vh;
  319. svg use {
  320. fill: @gray-l;
  321. }
  322. }
  323. &:hover,
  324. &.active {
  325. background: fade(@green, 20);
  326. border: 1px solid @green;
  327. color: @green;
  328. cursor: pointer;
  329. i svg use {
  330. fill: @green;
  331. }
  332. }
  333. &.active::after {
  334. box-sizing: content-box;
  335. width: 0px;
  336. height: 0px;
  337. position: absolute;
  338. right: -19px;
  339. padding: 0;
  340. border-bottom: 9px solid @green;
  341. border-top: 9px solid transparent;
  342. border-left: 9px solid transparent;
  343. border-right: 9px solid transparent;
  344. display: block;
  345. content: "";
  346. z-index: 10;
  347. transform: rotate(90deg);
  348. }
  349. &.active::before {
  350. box-sizing: content-box;
  351. width: 0px;
  352. height: 0px;
  353. position: absolute;
  354. right: -17px;
  355. padding: 0;
  356. border-bottom: 9px solid #063319;
  357. border-top: 9px solid transparent;
  358. border-left: 9px solid transparent;
  359. border-right: 9px solid transparent;
  360. display: block;
  361. content: "";
  362. z-index: 12;
  363. transform: rotate(90deg);
  364. }
  365. & + .tab {
  366. margin-top: 0.7407vh;
  367. }
  368. &:last-child {
  369. text-align: center;
  370. justify-content: center;
  371. }
  372. }
  373. .empty {
  374. flex: 1 0 auto;
  375. }
  376. }
  377. .info-chart {
  378. flex: 1 0 auto;
  379. }
  380. }
  381. .health-report {
  382. // 健康报告 按钮样式
  383. .actions {
  384. display: flex;
  385. .item {
  386. flex: 0 0 102px;
  387. text-align: center;
  388. line-height: 33px;
  389. margin-right: 8px;
  390. color: fade(@white, 75);
  391. font-size: @fontsize-s;
  392. &.green {
  393. background: @green;
  394. }
  395. &.purple {
  396. background: @purple;
  397. }
  398. &.gray {
  399. background: @gray;
  400. }
  401. }
  402. }
  403. .report-items {
  404. display: flex;
  405. flex-wrap: wrap;
  406. height: calc(100vh - 592px);
  407. .item {
  408. flex: 0 0 calc(100% / 6 - 16px);
  409. margin-bottom: 16px;
  410. & + .item {
  411. margin-left: 16px;
  412. }
  413. &:nth-child(6n + 1) {
  414. margin-left: 0px;
  415. }
  416. .title {
  417. background: fade(@gray, 40);
  418. // color: fade(@white, 75);
  419. color: @gray-l;
  420. line-height: 37px;
  421. padding-left: 16px;
  422. font-size: @fontsize-s;
  423. }
  424. .info {
  425. background: fade(@gray, 20);
  426. padding: 16px;
  427. font-size: @fontsize-s;
  428. color: @font-color;
  429. line-height: 1.5;
  430. p {
  431. margin: 0;
  432. line-height: 2;
  433. }
  434. .actions {
  435. display: flex;
  436. align-items: center;
  437. justify-content: center;
  438. .success {
  439. border-color: #05bb4c;
  440. color: #05bb4c;
  441. background: rgba(5, 187, 76, 0.2);
  442. }
  443. }
  444. }
  445. }
  446. }
  447. }
  448. }
  449. </style>