Compare commits

..

94 Commits
dev ... meizhou

Author SHA1 Message Date
selia-zx 66070c30e0 修改响应超时时间为15秒 4 days ago
selia-zx f1b163985e 1.修改设备延时开关最后一组数据的定位问题 7 days ago
selia-zx a8ff9d7354 对接热泵运行记录 2 weeks ago
selia-zx f813b951de 1.修改风柜监测系统-新风阀的数据部分样式改为绿色 2 weeks ago
v-lijf43 221b93d7f0 大屏中间图片设置改成0.8 3 weeks ago
selia-zx 355b4b76c8 修改生活热水监控的侧边样式 3 weeks ago
v-lijf43 914dba815c 大屏改成图片可点击返回 3 weeks ago
v-lijf43 2167d233dd 主机详情修改远程启动信号 3 weeks ago
selia-zx a6dac60428 修改图表、input输入框手机端样式 3 weeks ago
v-lijf43 46dbc7a1e4 修改文字标识 3 weeks ago
zx-student 01247b6aa7 主机详情-冷水设定值偏移输入范围校验问题 3 weeks ago
zx-student 3f5dde3aed 主机详情-添加冷水设定值偏移输入范围校验、添加最终出水温度设定值、屏蔽偏移值定时设置 3 weeks ago
v-lijf43 e27df7aab2 冷定值绑点修改 3 weeks ago
selia-zx 7dd6e3591b 修改主机详情-偏移值显示除以10,修改乘以10 3 weeks ago
selia-zx 99789a5a44 1.修改模式选择里面的选择事件 3 weeks ago
v-lijf43 1c2cfafd46 Merge branch 'meizhou' of https://git.mhito.net/lijianfu/eemcs_ui into meizhou 3 weeks ago
v-lijf43 728f3f81bd 优化当出现8quality出现可以控制问题 3 weeks ago
v-lijf43 6ab6c37564 优化 3 weeks ago
selia-zx 16710f719c 修改风柜水阀、风机的远程手自动状态 3 weeks ago
v-lijf43 532698dc42 新风阀新增三种模式、水阀手自动、风机频率手自动 3 weeks ago
v-lijf43 db172a2345 主阀,副阀修改 3 weeks ago
selia-zx c40c0da5a3 修改风柜监测-风阀手动调节的状态 3 weeks ago
selia-zx f931ee6941 修改热泵运行状态 3 weeks ago
selia-zx 30ccdd2779 修改能耗报表查询-图表请求分页问题 3 weeks ago
25604 7dd55779bc 主机详情页优化 3 weeks ago
selia-zx f4d65ef7d5 1.风柜监测系统两个页面-添加每个点位是否正常采集的数据 4 weeks ago
selia-zx e94a6b8c16 1.新增综合能耗报表菜单,可查询系统能耗报表 4 weeks ago
selia-zx 37913a8f71 热水监测修改刷新请求函数 1 month ago
25604 850b7aa51b 风柜系统loading添加修复 1 month ago
selia-zx 7232da0589 修改甲方要求 1 month ago
25604 e941ef8fb3 修改ahu绑定值,以及启停状态 1 month ago
selia-zx dc740bd707 Merge branch 'meizhou' of https://git.mhito.net/lijianfu/eemcs_ui into meizhou 1 month ago
selia-zx 09e837ad12 修改大屏页面-标题添加返回首页事件 1 month ago
v-lijf43 5881fb5a75 火焰百分比添加 1 month ago
selia-zx b7e2a43f55 调整大屏图标的大小 1 month ago
selia-zx 2ba2a398c3 修改热水控制文字表达 1 month ago
selia-zx 1fa123a2f7 1.修改生活热水、风机、温度系统的监测页面改动 1 month ago
selia-zx f20e9edd11 1.进入系统直接大屏展示F11效果 1 month ago
selia-zx 2e6cc09510 1风柜监测系统添加操作loading,修改请求更新数据时间 2 months ago
selia-zx 9146a2c5fe 风柜监测-添加风机频率调节 2 months ago
selia-zx 8efdbb0a83 1.修改风柜监测系统样式、loading问题 2 months ago
selia-zx b5a7b0feaa 1.修改蒸汽锅炉-燃气阀状态 2 months ago
25604 e91b527cf9 蒸汽锅炉界面优化 2 months ago
selia-zx 1d35fb16f5 1.修改风柜监测系统 2 months ago
v-lijf43 277a81df49 添加回风温度设置、ahu水阀调节 2 months ago
selia-zx 950219588d 修改风柜监测系统页面 2 months ago
selia-zx 90b1317425 修改风柜系统流程图 2 months ago
25604 12d0be108b 蒸汽锅炉、热水锅炉数据绑定 2 months ago
selia-zx ab72f8510c 添加热水锅炉静态页面 2 months ago
selia-zx 97f715ea6b 添加蒸汽锅炉监测、采暖泵监测静态页面 2 months ago
selia-zx 13d0d71bd7 生活热水-控制界面,去掉供水温度设定、温度偏差值设置;水箱添加最低液位设置值功能 2 months ago
selia-zx 4fb6d980bf 修改input单位样式 2 months ago
selia-zx 8cdad84735 1.主机参数详情页面冷水设定值便宜可编辑 2 months ago
selia-zx 2e63ef4fea 1.修改主机运行记录导出异常 2 months ago
selia-zx ff44d006db 1.测试修改主机运行记录功能 3 months ago
selia-zx b63bc3ed98 一些图表添加单位 3 months ago
selia-zx a41b7e1cf8 1.主机参数启动停止颜色分别用绿色和蓝色; 3 months ago
selia-zx 54929bc638 修改能耗分析图表参数 4 months ago
selia-zx 1629c56cc5 处理能耗报表报错问题 4 months ago
selia-zx 2c51fbf984 修改大屏数据 4 months ago
selia-zx 61dc4a5d59 修改生活热水-热泵开关机逻辑 4 months ago
selia-zx b422e6e323 1.修改大屏数据 4 months ago
selia-zx b31574e5fd 修改能源分析-能耗报表数据 4 months ago
selia-zx 8416806539 1.修改热水-项目总览,饼图描述 4 months ago
selia-zx 68efeef754 更新2000px以上页面样式变动2.0 4 months ago
selia-zx 56da047b0f 修改设备定时开关匹配数据逻辑 4 months ago
selia-zx b829c8d52d 更新2000px以上页面样式变动 4 months ago
selia-zx 46fe8ea70c 1.生活热水-首页修改热泵总数 4 months ago
selia-zx 7e78020d6e 1.对接生活热水供水监控系统-项目总览-项目概况、当月数据统计 4 months ago
selia-zx eec0e3cabb 1.生活热水供水监控系统添加:项目总览、能源分析(能耗报表、温度变化表、水位变化表)、用能查询(能耗、水表读数、电表读数)、数据分析四个静态页面内容 5 months ago
selia-zx 928427732c 修改首页饼图数据 5 months ago
selia-zx d99ad9947d 修改首页饼图数据 5 months ago
selia-zx bf2640958b 1.首页添加生活热水、温度系统、风柜系统的数据 5 months ago
25604 c90530caad 1、风柜系统添加定时; 5 months ago
selia-zx b71839eba6 1.压缩机排序 5 months ago
selia-zx eb9d523e1e 1.修改风柜系统监测-定时开关机参数问题 5 months ago
selia-zx 027e4d6d7f 1.修改大屏数据 5 months ago
selia-zx 781cc7e59f 1.修改风柜系统监测-定时开关机弹框高亮 5 months ago
selia-zx ad60088e00 1.主机详情页面,图表添加负载y轴,压缩机参数不采用tab形式 5 months ago
selia-zx 8282126f15 1.冷源监控-系统监测添加可点击打开弹窗控制阀门、水泵、风机、主机 5 months ago
mh ee447e1d7f 监控界面、主机详情、温湿度图表优化 5 months ago
selia-zx a9833153fb 1.修改中央空调-系统监测-压缩机参数内容tab分开展示 5 months ago
selia-zx c06ca6002c 1.空调风柜监控系统-系统监控添加定时开关功能 5 months ago
selia-zx e6b93684ae 1.修改生活热水-实时监控的动态图 5 months ago
selia-zx abec1b1416 1.ps修改生活热水-实时监控的动态图,修改添加供水泵1、供水泵2、补水状态、回水状态、热泵等状态 5 months ago
mh ac91f0837c 冷热源界面修改 5 months ago
v-lijf43 f9a2a9b905 阀门开关到位修改 5 months ago
selia-zx 39661b7ba6 1.联调梅州-中央空调-系统监测页面内容,调整样式 5 months ago
selia-zx ccde8e6187 修改主机参数页面数据 6 months ago
selia-zx 4f79f5bac9 1.解决冲突 6 months ago
selia-zx c6b4345766 系统监测采用大屏显示版本 6 months ago
selia-zx a74c3ad306 修改定时任务、表单构建样式 6 months ago
selia-zx 11d131c3ec 1.修改系统监测页面 6 months ago
selia-zx e068a1a14b 梅州分支 6 months ago
  1. 6
      .env.development
  2. 2
      .env.production
  3. 4
      package.json
  4. 29
      src/App.vue
  5. 10
      src/api/boiler/hotwaterBoiler.js
  6. 10
      src/api/boiler/steamBoiler.js
  7. 27
      src/api/centerairC/hostRunReport.js
  8. 27
      src/api/comprehensiveEnergy/hotPumpLog.js
  9. 19
      src/api/comprehensiveEnergy/meterRecord.js
  10. 9
      src/api/comprehensiveEnergy/systemEnergy.js
  11. 6
      src/api/device/gather.js
  12. 7
      src/api/region.js
  13. BIN
      src/assets/flowimg/circulate-move - 副本.gif
  14. BIN
      src/assets/flowimg/circulate-move.gif
  15. BIN
      src/assets/flowimg/circulate-nomove - 副本.png
  16. BIN
      src/assets/flowimg/circulate-nomove.png
  17. BIN
      src/assets/flowimg/supply-move.gif
  18. BIN
      src/assets/flowimg/supply-nomove.png
  19. BIN
      src/assets/flowimg/waterBox - 副本.png
  20. BIN
      src/assets/flowimg/waterBox.png
  21. 1
      src/assets/icons/svg/boilerSys.svg
  22. 1
      src/assets/icons/svg/heatingPump.svg
  23. 1
      src/assets/icons/svg/hotPumpLog.svg
  24. 1
      src/assets/icons/svg/hz-icon.svg
  25. 1
      src/assets/icons/svg/meterRecord.svg
  26. BIN
      src/assets/images/alarm.png
  27. BIN
      src/assets/images/badValve.png
  28. BIN
      src/assets/images/blade1.png
  29. BIN
      src/assets/images/blade2.png
  30. BIN
      src/assets/images/boiler.png
  31. BIN
      src/assets/images/boilerWork.gif
  32. BIN
      src/assets/images/detail-line.png
  33. 0
      src/assets/images/fenggui1.png
  34. BIN
      src/assets/images/fenggui2.png
  35. BIN
      src/assets/images/gasStop.png
  36. BIN
      src/assets/images/gasWork.png
  37. BIN
      src/assets/images/green-out.png
  38. BIN
      src/assets/images/heatingPump.png
  39. BIN
      src/assets/images/hotWater.png
  40. BIN
      src/assets/images/meizhou.png
  41. BIN
      src/assets/images/noalarm (2).png
  42. BIN
      src/assets/images/stopValve.png
  43. BIN
      src/assets/images/whiteFan.png
  44. BIN
      src/assets/images/workValve.png
  45. 4
      src/assets/styles/bigScreen.scss
  46. 15
      src/assets/styles/element-ui.scss
  47. 7
      src/assets/styles/index.scss
  48. 102
      src/permission.js
  49. 128
      src/store/modules/permission.js
  50. 53
      src/utils/fullscreen.js
  51. 2
      src/utils/request.js
  52. 721
      src/views/aircAndWindc/awSysMonitor/asSysMonitorDetails.vue
  53. 3033
      src/views/aircAndWindc/awSysMonitor/components/damperMonitor.vue
  54. 1735
      src/views/aircAndWindc/awSysMonitor/components/normalMonitor.vue
  55. 1676
      src/views/aircAndWindc/awSysMonitor/index.vue
  56. 6
      src/views/alarm/alarmCode/index.vue
  57. 4
      src/views/alarm/alarmRecord/index.vue
  58. 31
      src/views/alarm/alarmRule/index.vue
  59. 13
      src/views/bigScreen/bigScreen.vue
  60. 2
      src/views/bigScreen/components/coldSysEnergy.vue
  61. 1107
      src/views/boilerSys/boilerMonitor/boilerMonitorDetails.vue
  62. 20
      src/views/boilerSys/boilerMonitor/index.vue
  63. 1011
      src/views/boilerSys/heatingPump/heatingPumpDetails.vue
  64. 20
      src/views/boilerSys/heatingPump/index.vue
  65. 703
      src/views/boilerSys/hotWaterBoiler/hotWaterBoilerDetails.vue
  66. 20
      src/views/boilerSys/hotWaterBoiler/index.vue
  67. 32
      src/views/centerairC/delaySwitch/index.vue
  68. 7
      src/views/centerairC/enSourceAnalysis/components/deviceEnergy.vue
  69. 5
      src/views/centerairC/enSourceAnalysis/components/equipment.vue
  70. 40
      src/views/centerairC/energyAnalysis/components/energyAnalysis.vue
  71. 911
      src/views/centerairC/hostRunReport/index.vue
  72. 4
      src/views/centerairC/overview/index.vue
  73. 31
      src/views/centerairC/sysControl/index.vue
  74. 159
      src/views/centerairC/sysControl/listHeader.vue
  75. 107
      src/views/centerairC/sysControl/vavleheader.vue
  76. 48
      src/views/centerairC/sysMonitor/components/hostChart.vue
  77. 8
      src/views/centerairC/sysMonitor/components/loadData.vue
  78. 1396
      src/views/centerairC/sysMonitor/hostDetails.vue
  79. 1579
      src/views/centerairC/sysMonitor/monitorCenter.vue
  80. 185
      src/views/centerairC/sysMonitor/performance.vue
  81. 430
      src/views/centerairC/temHistoryQuery/index.vue
  82. 2
      src/views/centerairC/timeSwitch/index.vue
  83. 228
      src/views/components/viewColdSys.vue
  84. 10
      src/views/components/viewEnergy.vue
  85. 1091
      src/views/comprehensiveEnergy/hotPumpLog/index.vue
  86. 379
      src/views/comprehensiveEnergy/meterRecord/index.vue
  87. 777
      src/views/comprehensiveEnergy/systemEnergy/index.vue
  88. 6
      src/views/device/comm/index.vue
  89. 3
      src/views/device/gateway/index.vue
  90. 14
      src/views/device/gather/index.vue
  91. 12
      src/views/device/ledger/index.vue
  92. 4
      src/views/device/maintenance/index.vue
  93. 15
      src/views/device/qrCode/index.vue
  94. 9
      src/views/device/spareInOut/index.vue
  95. 174
      src/views/hotWater/dataAnalysis/components/analyzeMonth.vue
  96. 218
      src/views/hotWater/dataAnalysis/components/analyzeYear.vue
  97. 162
      src/views/hotWater/energyAnalysis/components/energyReport.vue
  98. 7
      src/views/hotWater/energyAnalysis/components/temReport.vue
  99. 7
      src/views/hotWater/energyAnalysis/components/waterReport.vue
  100. 10
      src/views/hotWater/energyQuery/components/energy.vue
  101. Some files were not shown because too many files have changed in this diff Show More

6
.env.development

@ -7,9 +7,9 @@ ENV = 'development'
# 开发环境
# VUE_APP_BASE_API = '/dev-api'
# 后台
# VUE_APP_BASE_API = 'http://192.168.1.222:8080'
# 海湾酒店-云端
VUE_APP_BASE_API = 'http://106.55.173.225:8090'
VUE_APP_BASE_API = 'http://192.168.1.222:8080'
# 梅州云端
# VUE_APP_BASE_API = 'http://106.55.173.225:8091'
# 路由懒加载
VUE_CLI_BABEL_TRANSPILE_MODULES = true

2
.env.production

@ -7,4 +7,4 @@ ENV = 'production'
# 生产环境
# VUE_APP_BASE_API = '/prod-api'
# 后台
VUE_APP_BASE_API = 'http://106.55.173.225:8090'
VUE_APP_BASE_API = 'http://106.55.173.225:8091'

4
package.json

@ -59,7 +59,8 @@
"vue-meta": "2.4.0",
"vue-router": "3.4.9",
"vuedraggable": "2.24.3",
"vuex": "3.6.0"
"vuex": "3.6.0",
"xlsx": "^0.18.5"
},
"devDependencies": {
"@vue/cli-plugin-babel": "4.4.6",
@ -72,6 +73,7 @@
"connect": "3.6.6",
"eslint": "7.15.0",
"eslint-plugin-vue": "7.2.0",
"html-webpack-plugin": "^5.6.3",
"lint-staged": "10.5.3",
"runjs": "4.4.2",
"sass": "1.32.13",

29
src/App.vue

@ -7,18 +7,37 @@
<script>
import ThemePicker from "@/components/ThemePicker";
import { exitFullscreen, isFullscreen } from "@/utils/fullscreen";
export default {
name: "App",
components: { ThemePicker },
metaInfo() {
return {
title: this.$store.state.settings.dynamicTitle && this.$store.state.settings.title,
titleTemplate: title => {
return title ? `${title} - ${process.env.VUE_APP_TITLE}` : process.env.VUE_APP_TITLE
title:
this.$store.state.settings.dynamicTitle &&
this.$store.state.settings.title,
titleTemplate: (title) => {
return title
? `${title} - ${process.env.VUE_APP_TITLE}`
: process.env.VUE_APP_TITLE;
},
};
},
mounted() {
// Esc 退
window.addEventListener("keydown", this.handleKeyDown);
},
beforeDestroy() {
window.removeEventListener("keydown", this.handleKeyDown);
},
methods: {
handleKeyDown(event) {
if (event.key === "Escape" && isFullscreen()) {
exitFullscreen();
}
}
}
},
},
};
</script>
<style scoped>

10
src/api/boiler/hotwaterBoiler.js

@ -0,0 +1,10 @@
import request from "@/utils/request";
// 热水锅炉设备参数列表
export function hotWaterBoiler(query) {
return request({
url: "/device/hotWaterBoiler/list",
method: "get",
params: query,
});
}

10
src/api/boiler/steamBoiler.js

@ -0,0 +1,10 @@
import request from "@/utils/request";
// 蒸汽锅炉设备参数列表
export function steamBoilerBoiler(query) {
return request({
url: "/device/steamBoiler/list",
method: "get",
params: query,
});
}

27
src/api/centerairC/hostRunReport.js

@ -0,0 +1,27 @@
import request from "@/utils/request";
// 查询运行记录
export function reportSysList(data) {
return request({
url: "/reportSys/list",
method: "post",
data,
});
}
// 编辑运行记录
export function reportSysEdit(data) {
return request({
url: "/reportSys/edit",
method: "put",
data,
});
}
// 导出
export function reportSysExport(data) {
return request({
url: "/reportSys/export",
method: "post",
data,
responseType: 'blob',
});
}

27
src/api/comprehensiveEnergy/hotPumpLog.js

@ -0,0 +1,27 @@
import request from "@/utils/request";
export const hotWaterList = (data) => {
return request({
url: "/reportHotWater/list",
method: "post",
data: data,
});
};
// 导出
export const hotWaterExport = (data) => {
return request({
url: "/reportHotWater/export",
method: "post",
data,
responseType: "blob",
});
};
// 修改
export const hotWaterEdit = (data) => {
return request({
url: "/reportHotWater/edit",
method: "put",
data: data,
});
};

19
src/api/comprehensiveEnergy/meterRecord.js

@ -0,0 +1,19 @@
import request from "@/utils/request";
export const meterReadingsList = (data) => {
return request({
url: "/reportMeterReadings/list",
method: "post",
data: data,
});
};
// 导出
export const meterReadingsExport = (data) => {
return request({
url: "/reportMeterReadings/export",
method: "post",
data,
responseType: "blob",
});
};

9
src/api/comprehensiveEnergy/systemEnergy.js

@ -0,0 +1,9 @@
import request from "@/utils/request";
export const compreReport = (data) => {
return request({
url: "/compre/report",
method: "post",
data,
});
};

6
src/api/device/gather.js

@ -8,6 +8,12 @@ export function cpmList(query) {
params: query,
});
}
export function cpmList2(cpmIds) {
return request({
url: "/device/cpm/list/" + cpmIds,
method: "get",
});
}
// 根据id查询设备采集参数信息
export function getCPM(cpmId) {

7
src/api/region.js

@ -7,6 +7,13 @@ export function spaceTree() {
method: "get",
});
}
export function floorTree() {
return request({
url: "/space/floorTree",
method: "get",
});
}
// 获取区域信息
export function getAreaList(query) {

BIN
src/assets/flowimg/circulate-move - 副本.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
src/assets/flowimg/circulate-move.gif

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 24 KiB

BIN
src/assets/flowimg/circulate-nomove - 副本.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
src/assets/flowimg/circulate-nomove.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 9.5 KiB

BIN
src/assets/flowimg/supply-move.gif

Binary file not shown.

Before

Width:  |  Height:  |  Size: 248 KiB

After

Width:  |  Height:  |  Size: 468 KiB

BIN
src/assets/flowimg/supply-nomove.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 135 KiB

After

Width:  |  Height:  |  Size: 186 KiB

BIN
src/assets/flowimg/waterBox - 副本.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 KiB

BIN
src/assets/flowimg/waterBox.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

After

Width:  |  Height:  |  Size: 188 KiB

1
src/assets/icons/svg/boilerSys.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1757379307805" class="icon" viewBox="0 0 1335 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1517" xmlns:xlink="http://www.w3.org/1999/xlink" width="260.7421875" height="200"><path d="M1233.548986 825.047188V692.461449C1293.801739 651.456928 1335.652174 562.176 1335.652174 458.722319c0-137.676058-73.935768-250.078609-167.179131-257.335652v-0.415537l-165.917681-25.822608V115.533913h-56.750376v50.665739L810.889275 139.664696V75.790841h-60.697971v54.494608L514.285449 87.010319V0h-66.337391v76.636754l-105.768812-16.458203v0.296811c60.549565 8.221681 103.231072 167.045565 96.048232 359.780174-7.182841 192.734609-61.677449 347.863188-122.672232 351.573334l87.188406-2.849392v40.158609l-159.016811 8.102956v66.841971l370.554434-30.660637 1.409855 25.555478-195.628521 13.341681 23.240348 11.353044v113.975652l861.792463-106.733449v-84.027363l-34.934724-4.541217-36.61171 2.700985z m-553.360696-32.218898v-34.489507l160.975768-6.678261v32.085333l-160.975768 9.082435zM528.517565 204.503188l27.870609-13.623652v-0.845913l1.409855 0.148406 0.430377-0.148406v0.281971l147.737971 23.552v295.787594l-145.91258-4.11084-31.551072 3.546898V204.503188z m-53.099594 600.791189l8.310725-39.179131 125.19513-4.11084 2.122203 36.478145-135.642899 6.826666z m204.770319 38.882319l269.148753-24.976696v-40.870957l-43.52742 2.270609 4.927073-31.22458 231.824695-14.766376 15.909102 93.822145-478.133797 42.859594-0.148406-27.098899z m-406.854493-73.579595c-56.008348-2.122203-97.458087-133.179362-99.980985-302.955594l-35.008928-2.700985c-21.563362 8.934029-17.066667 54.895304-17.066667 54.895304H0c0-138.150957 105.160348-144.814377 105.160348-144.814377l70.848927 1.27629c12.184116-180.134957 65.402435-319.280232 123.785276-316.994782 62.033623 2.404174 106.421797 163.528348 99.135072 359.973101-7.271884 196.429913-63.562203 353.740058-125.595826 351.321043zM250.227014 320.853333c-11.620174 0-21.696928 22.973217-26.742724 56.869102l30.942609 0.712348-0.281971 92.620058-30.245102-1.27629c4.897391 32.204058 14.988986 54.168116 26.327188 54.168116 16.384 0 29.681159-45.516058 29.68116-101.539247 0-56.023188-13.297159-101.554087-29.68116-101.554087z" fill="" p-id="1518"></path></svg>

After

Width:  |  Height:  |  Size: 2.3 KiB

1
src/assets/icons/svg/heatingPump.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1757380960233" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3007" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M428.8 704h153.6c236.8-134.4 57.6-339.2 25.6-358.4 12.8 25.6 12.8 64-6.4 76.8-38.4-128-121.6-160-121.6-160 12.8 70.4-38.4 147.2-83.2 204.8 0-25.6-6.4-44.8-19.2-70.4-6.4 44.8-44.8 89.6-51.2 140.8-19.2 64 6.4 115.2 102.4 166.4z m0 0" fill="" p-id="3008"></path><path d="M1024 76.8H512c-57.6 0-115.2 12.8-166.4 32-51.2 25.6-102.4 57.6-140.8 96-38.4 38.4-70.4 83.2-96 140.8-19.2 51.2-32 108.8-32 166.4 0 57.6 12.8 115.2 32 166.4 6.4 19.2 12.8 32 25.6 51.2H0v217.6h512c57.6 0 115.2-12.8 166.4-32s96-51.2 140.8-96c38.4-38.4 70.4-83.2 96-140.8 25.6-51.2 32-108.8 32-166.4 0-76.8-19.2-153.6-57.6-217.6H1024V76.8M460.8 896H51.2v-115.2h185.6c-12.8-12.8-32-32-44.8-51.2-38.4-64-64-134.4-64-217.6 0-211.2 172.8-384 384-384h460.8v115.2h-179.2l32 38.4C870.4 352 896 428.8 896 512c0 211.2-172.8 384-384 384h-51.2z m0 0" fill="" p-id="3009"></path></svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

1
src/assets/icons/svg/hotPumpLog.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1761181457603" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="5548" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M670.208 223.053H193.183v0.017c-24.374 0.412-44.02 20.636-44.02 45.549 0 24.914 19.64 45.139 44.02 45.55v0.016h477.025c24.719 0 44.765-20.402 44.765-45.566 0-25.163-20.046-45.566-44.765-45.566zM395.732 439.798h-202.55v0.023c-24.374 0.406-44.02 20.635-44.02 45.543 0 24.914 19.64 45.143 44.02 45.55v0.015h202.556c24.719 0 44.76-20.395 44.76-45.565 0.001-25.164-20.04-45.566-44.766-45.566zM276.261 658.512h-83.083v0.022c-24.374 0.406-44.014 20.636-44.014 45.544 0 24.913 19.64 45.144 44.014 45.55v0.017h83.083c24.719 0 44.759-20.397 44.759-45.566 0-25.165-20.041-45.567-44.759-45.567z m0 0" p-id="5549"></path><path d="M715.201 1.954H148.93C67.141 1.954 0.84 68.257 0.84 150.043v724.501c0 81.786 66.301 148.09 148.09 148.09h241.713v-0.084c0.695 0.033 1.386 0.049 2.081 0.049 25.164 0 45.566-20.396 45.566-45.566 0-25.163-20.402-45.565-45.566-45.565-0.695 0-1.392 0.023-2.081 0.056v-0.021H148.93c-31.455 0-56.958-25.503-56.958-56.957V150.043c0-31.461 25.503-56.958 56.958-56.958h566.271c31.46 0 56.957 25.497 56.957 56.958V320.46c0 25.164 20.402 45.566 45.566 45.566 25.169 0 45.566-20.402 45.566-45.566V150.043c0.001-81.786-66.302-148.089-148.089-148.089z m0 0" p-id="5550"></path><path d="M676.148 840.226c-7.364 0-14.695-2.041-21.226-6.091-11.942-7.409-19.073-20.219-19.073-34.271V652.755c0-14.056 7.131-26.865 19.073-34.269 11.942-7.41 26.593-8.099 39.181-1.853l128.683 73.556c13.817 6.856 22.405 20.697 22.405 36.121 0 15.417-8.588 29.263-22.405 36.12l-128.683 73.557c-5.707 2.831-11.841 4.239-17.955 4.239z m0 0" p-id="5551"></path><path d="M726.854 430.13c-163.575 0-296.181 132.605-296.181 296.18s132.605 296.18 296.181 296.18c163.574 0 296.179-132.604 296.179-296.18S890.429 430.13 726.854 430.13z m0 501.227c-113.248 0-205.048-91.805-205.048-205.047s91.8-205.047 205.048-205.047c113.241 0 205.047 91.805 205.047 205.047s-91.805 205.047-205.047 205.047z m0 0" p-id="5552"></path></svg>

After

Width:  |  Height:  |  Size: 2.2 KiB

1
src/assets/icons/svg/hz-icon.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1758105515572" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7076" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M480.256 16.384C219.648 16.384 8.192 227.84 8.192 488.448c0 260.608 211.456 472.064 472.064 472.064 260.608 0 472.064-211.456 472.064-472.064 0.512-260.608-210.944-472.064-472.064-472.064z m0 881.664c-225.792 0-409.088-183.296-409.088-409.088 0-225.792 183.296-409.088 409.088-409.088 225.792 0 409.088 183.296 409.088 409.088 0.512 225.792-182.784 409.088-409.088 409.088z" p-id="7077"></path><path d="M203.264 281.088h50.688v160.256h199.68V281.088h50.688v383.488h-50.688V484.864h-199.68v179.712h-50.688V281.088zM562.176 625.664l160.768-199.68h-152.576v-40.448H778.24v40.448l-158.72 198.144h165.888l-7.68 40.448h-215.552v-38.912z" p-id="7078"></path></svg>

After

Width:  |  Height:  |  Size: 990 B

1
src/assets/icons/svg/meterRecord.svg

@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1761011231553" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2521" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M925.425633 514.798111a38.910648 38.910648 0 0 0-25.59911-9.727662 38.398666 38.398666 0 0 0-28.415013 12.543564l-138.747178 153.594662a62.973812 62.973812 0 0 0-62.973812 62.973812 38.398666 38.398666 0 0 0 0 5.631804l-28.926995 31.742897a38.398666 38.398666 0 0 0 56.830026 51.198221l24.319155-26.879066a69.373589 69.373589 0 0 0 10.239644 0 62.973812 62.973812 0 0 0 63.229802-63.229802A66.045705 66.045705 0 0 0 793.590215 716.775092l106.74829-117.243926a214.008563 214.008563 0 1 1-167.674173-80.893189 38.398666 38.398666 0 0 0 0-76.797331 291.061886 291.061886 0 1 0 192.50531 72.701474z" p-id="2522"></path><path d="M365.317097 732.902532a367.859217 367.859217 0 0 1 367.603226-367.603226 112.124104 112.124104 0 0 1 38.398666 6.655769v-207.352795a38.398666 38.398666 0 0 0-38.398666-38.398666H455.681957V63.997776A63.997776 63.997776 0 0 0 391.684181 0H64.015567A63.997776 63.997776 0 0 0 0.017791 63.997776v921.567976A38.398666 38.398666 0 0 0 38.416457 1023.964417h470.51165a366.835252 366.835252 0 0 1-143.61101-291.061885zM293.639588 793.572423H167.179982a38.398666 38.398666 0 0 1 0-76.797331h126.459606a38.398666 38.398666 0 0 1 0 76.797331z m0-255.991104H167.179982a38.398666 38.398666 0 0 1 0-76.797331h126.459606a38.398666 38.398666 0 0 1 0 76.797331z m0-255.991104H167.179982a38.398666 38.398666 0 0 1 0-76.797332h126.459606a38.398666 38.398666 0 0 1 0 76.797332z" p-id="2523"></path></svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
src/assets/images/alarm.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

BIN
src/assets/images/badValve.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

BIN
src/assets/images/blade1.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

BIN
src/assets/images/blade2.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

BIN
src/assets/images/boiler.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

BIN
src/assets/images/boilerWork.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 283 KiB

BIN
src/assets/images/detail-line.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

0
src/assets/images/fenggui.png → src/assets/images/fenggui1.png

Before

Width:  |  Height:  |  Size: 576 KiB

After

Width:  |  Height:  |  Size: 576 KiB

BIN
src/assets/images/fenggui2.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 738 KiB

BIN
src/assets/images/gasStop.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
src/assets/images/gasWork.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
src/assets/images/green-out.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 KiB

BIN
src/assets/images/heatingPump.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 342 KiB

BIN
src/assets/images/hotWater.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

BIN
src/assets/images/meizhou.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 MiB

BIN
src/assets/images/noalarm (2).png

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

BIN
src/assets/images/stopValve.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

BIN
src/assets/images/whiteFan.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

BIN
src/assets/images/workValve.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

4
src/assets/styles/bigScreen.scss

@ -679,10 +679,6 @@
.el-card__header {
padding: 0.14rem 0.15rem 0.07rem !important;
min-height: 0.4rem !important;
}
.el-form-item__error {
font-size: 0.12rem !important;
padding-top: 0.04rem !important;
}
}
@media (min-width: 2000px) {

15
src/assets/styles/element-ui.scss

@ -1430,7 +1430,7 @@
min-width: 50px !important;
z-index: 0;
}
.el-input__suffix{
.el-input__suffix {
z-index: 10;
}
.el-cascader__tags {
@ -1438,4 +1438,17 @@
flex-direction: row;
align-items: center;
flex-wrap: nowrap;
}
.el-table--group,
.el-table--border {
border: 1px solid #00264f !important;
}
.el-table--border .el-table__cell {
border-right: 1px solid #00264f !important;
}
.el-table--border th.el-table__cell {
border-bottom: 1px solid #00264f !important;
}
.el-table__expand-icon{
color: #fff !important;
}

7
src/assets/styles/index.scss

@ -775,3 +775,10 @@ table th {
}
}
}
/* 手机端样式 */
@media (min-width: 0px) and (max-width: 990px) {
.app-main {
height: 100% !important;
overflow-y: hidden !important;
}
}

102
src/permission.js

@ -1,63 +1,87 @@
import router from './router'
import store from './store'
import { Message } from 'element-ui'
import NProgress from 'nprogress'
import 'nprogress/nprogress.css'
import { getToken } from '@/utils/auth'
import { isPathMatch } from '@/utils/validate'
import { isRelogin } from '@/utils/request'
import router from "./router";
import store from "./store";
import { Message } from "element-ui";
import NProgress from "nprogress";
import "nprogress/nprogress.css";
import { getToken } from "@/utils/auth";
import { isPathMatch } from "@/utils/validate";
import { isRelogin } from "@/utils/request";
import {
isFullscreenSupported,
requestFullscreen,
isFullscreen,
} from "@/utils/fullscreen";
NProgress.configure({ showSpinner: false });
NProgress.configure({ showSpinner: false })
const whiteList = ['/login', '/register']
const whiteList = ["/login", "/register"];
const isWhiteList = (path) => {
return whiteList.some(pattern => isPathMatch(pattern, path))
}
return whiteList.some((pattern) => isPathMatch(pattern, path));
};
let userManuallyExitedFullscreen = false;
// 监听全屏状态变化事件
document.addEventListener("fullscreenchange", () => {
if (!isFullscreen()) {
userManuallyExitedFullscreen = true;
}
});
router.beforeEach((to, from, next) => {
NProgress.start()
NProgress.start();
if (getToken()) {
to.meta.title && store.dispatch('settings/setTitle', to.meta.title)
to.meta.title && store.dispatch("settings/setTitle", to.meta.title);
/* has token*/
if (to.path === '/login') {
next({ path: '/' })
NProgress.done()
if (to.path === "/login") {
next({ path: "/" });
NProgress.done();
} else if (isWhiteList(to.path)) {
next()
if (isFullscreenSupported() && !userManuallyExitedFullscreen) {
const element = document.documentElement;
requestFullscreen(element);
}
next();
} else {
if (store.getters.roles.length === 0) {
isRelogin.show = true
isRelogin.show = true;
// 判断当前用户是否已拉取完user_info信息
store.dispatch('GetInfo').then(() => {
isRelogin.show = false
store.dispatch('GenerateRoutes').then(accessRoutes => {
// 根据roles权限生成可访问的路由表
router.addRoutes(accessRoutes) // 动态添加可访问路由表
next({ ...to, replace: true }) // hack方法 确保addRoutes已完成
})
}).catch(err => {
store.dispatch('LogOut').then(() => {
Message.error(err)
next({ path: '/' })
})
store
.dispatch("GetInfo")
.then(() => {
isRelogin.show = false;
store.dispatch("GenerateRoutes").then((accessRoutes) => {
// 根据roles权限生成可访问的路由表
router.addRoutes(accessRoutes); // 动态添加可访问路由表
next({ ...to, replace: true }); // hack方法 确保addRoutes已完成
});
})
.catch((err) => {
store.dispatch("LogOut").then(() => {
Message.error(err);
next({ path: "/" });
});
});
} else {
next()
if (isFullscreenSupported() && !userManuallyExitedFullscreen) {
const element = document.documentElement;
requestFullscreen(element);
}
next();
}
}
} else {
// 没有token
if (isWhiteList(to.path)) {
// 在免登录白名单,直接进入
next()
next();
} else {
next(`/login?redirect=${encodeURIComponent(to.fullPath)}`) // 否则全部重定向到登录页
NProgress.done()
next(`/login?redirect=${encodeURIComponent(to.fullPath)}`); // 否则全部重定向到登录页
NProgress.done();
}
}
})
});
router.afterEach(() => {
NProgress.done()
})
NProgress.done();
});

128
src/store/modules/permission.js

@ -40,6 +40,7 @@ const permission = {
const rewriteRoutes = filterAsyncRouter(rdata, false, true);
const asyncRoutes = filterDynamicRoutes(dynamicRoutes);
rewriteRoutes.push({ path: "*", redirect: "/404", hidden: true });
// 有中央空调
// 如果动态的路由有中央空调-系统监控-系统监测页面,那就添加一个hidden为true非Layout的大屏页面
const result = checkRouteArray(
sidebarRoutes,
@ -90,6 +91,133 @@ const permission = {
// console.log("不满足条件");
}
// 风柜
const result2 = sidebarRoutes.find(
(item) => item.name === "AircAndWindc"
);
if (result2) {
// 定义要添加的多个路由对象数组
const additionalRoutes2 = [
{
path: "/asSysMonitorDetails",
name: "asSysMonitorDetails",
hidden: true,
component: () =>
import(
"@/views/aircAndWindc/awSysMonitor/asSysMonitorDetails"
),
meta: { title: "系统监控", icon: "screen" },
},
// 可以继续添加更多路由对象
];
// 循环添加额外的路由对象到各路由数组
additionalRoutes2.forEach((route) => {
sidebarRoutes.push(route);
rewriteRoutes.push(route);
asyncRoutes.push(route);
});
} else {
// console.log("不满足条件");
}
// 锅炉
const result3 = sidebarRoutes.find(
(item) => item.name === "BoilerSys"
);
if (result3) {
// 定义要添加的多个路由对象数组
const additionalRoutes3 = [
{
path: "/boilerMonitorDetails",
name: "boilerMonitorDetails",
hidden: true,
component: () =>
import(
"@/views/boilerSys/boilerMonitor/boilerMonitorDetails"
),
meta: { title: "锅炉监控", icon: "screen" },
},
{
path: "/hotWaterBoilerDetails",
name: "hotWaterBoilerDetails",
hidden: true,
component: () =>
import(
"@/views/boilerSys/hotWaterBoiler/hotWaterBoilerDetails"
),
meta: { title: "热水锅炉监控", icon: "screen" },
},
{
path: "/heatingPumpDetails",
name: "heatingPumpDetails",
hidden: true,
component: () =>
import("@/views/boilerSys/heatingPump/heatingPumpDetails"),
meta: { title: "采暖泵监控", icon: "screen" },
},
// 可以继续添加更多路由对象
];
// 循环添加额外的路由对象到各路由数组
additionalRoutes3.forEach((route) => {
sidebarRoutes.push(route);
rewriteRoutes.push(route);
asyncRoutes.push(route);
});
} else {
// console.log("不满足条件");
}
// 热水
const result4 = sidebarRoutes.find(
(item) => item.name === "HotWater"
);
if (result4) {
// 定义要添加的多个路由对象数组
const additionalRoutes4 = [
{
path: "/waterMonitorDetails",
name: "waterMonitorDetails",
hidden: true,
component: () =>
import("@/views/hotWater/waterMonitor/waterMonitorDetails"),
meta: { title: "热水监控", icon: "screen" },
},
// 可以继续添加更多路由对象
];
// 循环添加额外的路由对象到各路由数组
additionalRoutes4.forEach((route) => {
sidebarRoutes.push(route);
rewriteRoutes.push(route);
asyncRoutes.push(route);
});
} else {
// console.log("不满足条件");
}
// 温度监测
const result5 = sidebarRoutes.find((item) => item.name === "TemSys");
if (result5) {
// 定义要添加的多个路由对象数组
const additionalRoutes5 = [
{
path: "/temMonitorDeatils",
name: "temMonitorDeatils",
hidden: true,
component: () =>
import("@/views/temSys/temMonitor/temMonitorDeatils"),
meta: { title: "温度监测", icon: "screen" },
},
];
// 循环添加额外的路由对象到各路由数组
additionalRoutes5.forEach((route) => {
sidebarRoutes.push(route);
rewriteRoutes.push(route);
asyncRoutes.push(route);
});
} else {
// console.log("不满足条件");
}
commit("SET_ROUTES", rewriteRoutes);
commit("SET_SIDEBAR_ROUTERS", constantRoutes.concat(sidebarRoutes));
commit("SET_DEFAULT_ROUTES", sidebarRoutes);

53
src/utils/fullscreen.js

@ -0,0 +1,53 @@
// 检查浏览器是否支持全屏 API
function isFullscreenSupported() {
return (
document.fullscreenEnabled ||
document.webkitFullscreenEnabled ||
document.mozFullScreenEnabled ||
document.msFullscreenEnabled
);
}
// 进入全屏模式
function requestFullscreen(element) {
if (element.requestFullscreen) {
element.requestFullscreen();
} else if (element.webkitRequestFullscreen) {
element.webkitRequestFullscreen();
} else if (element.mozRequestFullScreen) {
element.mozRequestFullScreen();
} else if (element.msRequestFullscreen) {
element.msRequestFullscreen();
}
}
// 退出全屏模式
function exitFullscreen() {
if (document.exitFullscreen) {
document.exitFullscreen();
} else if (document.webkitExitFullscreen) {
document.webkitExitFullscreen();
} else if (document.mozCancelFullScreen) {
document.mozCancelFullScreen();
} else if (document.msExitFullscreen) {
document.msExitFullscreen();
}
}
// 检查当前是否处于全屏状态
function isFullscreen() {
return (
document.fullscreenElement ||
document.webkitFullscreenElement ||
document.mozFullScreenElement ||
document.msFullscreenElement
);
}
export {
isFullscreenSupported,
requestFullscreen,
exitFullscreen,
isFullscreen,
};

2
src/utils/request.js

@ -17,7 +17,7 @@ const service = axios.create({
// axios中请求配置有baseURL选项,表示请求URL公共部分
baseURL: process.env.VUE_APP_BASE_API,
// 超时
timeout: 10000
timeout: 15000
})
// request拦截器

721
src/views/aircAndWindc/awSysMonitor/asSysMonitorDetails.vue

@ -0,0 +1,721 @@
<template>
<div class="monitor">
<div class="monitor-top">
<img
class="title-left"
src="../../../assets/images/title-left.png"
alt=""
/>
<img
class="title-center"
src="../../../assets/images/title-center.png"
alt=""
@click="goSys"
/>
<img
class="title-right"
src="../../../assets/images/title-right.png"
alt=""
/>
<div class="sys-title" @click="goSys">空调风柜监控系统</div>
<!-- logo -->
<img src="../../../assets/images/logo-3.png" class="sys-logo" alt="" />
<div class="nowTime">{{ formattedDate }}</div>
<div class="monitor-time">已监测时长:{{ dayData }}</div>
<img
class="icon_warning"
src="../../../assets/images/warning.png"
title="报警记录"
@click="goWarning"
v-if="isShowWarning"
alt=""
/>
<img
class="icon_home"
src="../../../assets/images/icon_home.png"
title="首页"
@click="goSys"
alt=""
/>
<img
class="back-icon"
src="../../../assets/images/back-icon.png"
title="返回"
@click="goBack"
alt=""
/>
</div>
<div class="app-container">
<div class="left-tree">
<!-- el-tree 设置一个固定的高度和滚动条 -->
<div class="tree-div">
<el-tree
ref="tree"
:data="treeData"
node-key="id"
:default-expand-all="false"
:default-expanded-keys="expandedKeys"
:auto-expand-parent="true"
icon-class="none"
@node-expand="handleNodeExpand"
@node-collapse="handleNodeCollapse"
:highlight-current="true"
@node-click="handleNodeClick"
>
<template #default="{ node }">
<span class="custom-tree-node">
<!-- 根据节点状态动态设置图标类名 -->
<div class="tree-left">
<i :class="getIconClass(node)" class="custom-tree-icon"></i>
<span class="tree-label">{{ node.label }}</span>
</div>
</span>
</template>
</el-tree>
</div>
</div>
<damper-monitor
:currentId="currentId"
:currentName="currentName"
ref="damperMonitorRef"
v-if="isShowdamper"
></damper-monitor>
<normal-monitor
:currentId="currentId"
:currentName="currentName"
ref="normalMonitorRef"
v-else
></normal-monitor>
</div>
</div>
</template>
<script>
import { runTime } from "@/api/centerairC/sysMonitor";
import { alarmRecordList } from "@/api/alarm/alarmRecord";
import { getDay } from "@/utils/datetime";
import { spaceTree } from "@/api/region";
import damperMonitor from "./components/damperMonitor.vue";
import normalMonitor from "./components/normalMonitor.vue";
export default {
components: { damperMonitor, normalMonitor },
name: "asSysMonitorDetails",
data() {
return {
currentDate: new Date(),
nowTimer: null,
isShowWarning: false, //
dayData: "", //
treeData: [],
defaultProps: {
children: "children",
label: "label",
},
deviceList: [],
expandedKeys: [],
currentId: "", //id
currentName: "", //
currentLevel: "", //
currentParentId: "", //id
backwaterObj: {}, //
airValveObj: {}, //
airValveBackObj: {}, //
waterValveObj: {}, //
startControlObj: {}, //
runStatusObj: {}, //
airSupplyObj: {}, //
pressureObj: {}, //
automaticObj: {}, //
backAirObj: {}, //
faultAlarmObj: {}, //
waterSupplyObj: {}, //
tableData: [], //
temValue: "℃", //
valvePercent: "%", //
runStatus: false, //
autoStatus: false, //
startStatus: false, //
frequency: "v",
isOpenTimeSwitch: false,
delayList: [],
currentWeekday: "",
isShowdamper: false,
};
},
computed: {
formattedDate() {
const year = this.currentDate.getFullYear();
const month = String(this.currentDate.getMonth() + 1).padStart(2, "0");
const day = String(this.currentDate.getDate()).padStart(2, "0");
const hours = String(this.currentDate.getHours()).padStart(2, "0");
const minutes = String(this.currentDate.getMinutes()).padStart(2, "0");
const seconds = String(this.currentDate.getSeconds()).padStart(2, "0");
const weekDays = [
"星期日",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
];
const weekDay = weekDays[this.currentDate.getDay()];
return `${year}${month}${day}${hours}:${minutes}:${seconds} ${weekDay}`;
},
},
watch: {
temValue(newVal) {
let valueWithoutTem = newVal.replace(/℃/g, "");
if (valueWithoutTem === "") {
this.temValue = "℃";
} else {
this.temValue = valueWithoutTem + "℃";
}
},
valvePercent(newVal) {
// %
let valueWithoutPercent = newVal.replace(/%/g, "");
// %
if (valueWithoutPercent === "") {
this.temValue = "%";
} else {
// %
this.temValue = valueWithoutPercent + "%";
}
},
frequency(newVal) {
let valueWithoutFrequency = newVal.replace(/v/g, "");
if (valueWithoutFrequency === "") {
this.temValue = "v";
} else {
this.temValue = valueWithoutFrequency + "v";
}
},
},
created() {
const weekdays = [
"星期日",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
];
const date = new Date();
const dayIndex = date.getDay();
this.currentWeekday = weekdays[dayIndex];
console.log("今天是星期几", this.currentWeekday);
},
mounted() {
this.requestFullscreen();
//
this.getSysBuild();
this.getAlarnStatus();
this.getDayData();
//
this.nowTimer = setInterval(() => {
this.currentDate = new Date();
}, 1000);
},
beforeDestroy() {
//
if (this.nowTimer) {
clearInterval(this.nowTimer);
}
},
methods: {
//
requestFullscreen() {
const element = document.documentElement;
console.log("全屏了吗");
if (element.requestFullscreen) {
element.requestFullscreen();
} else if (element.mozRequestFullScreen) {
// Firefox
element.mozRequestFullScreen();
} else if (element.webkitRequestFullscreen) {
// Chrome, Safari and Opera
element.webkitRequestFullscreen();
} else if (element.msRequestFullscreen) {
// IE/Edge
element.msRequestFullscreen();
}
},
// 退
exitFullscreen() {
if (document.exitFullscreen) {
document.exitFullscreen();
} else if (document.mozCancelFullScreen) {
// Firefox
document.mozCancelFullScreen();
} else if (document.webkitExitFullscreen) {
// Chrome, Safari and Opera
document.webkitExitFullscreen();
} else if (document.msExitFullscreen) {
// IE/Edge
document.msExitFullscreen();
}
},
//
goSys() {
// this.exitFullscreen();
this.$router.push("/");
},
//
goBack() {
window.history.go(-2);
},
//
getDayData() {
runTime().then((res) => {
if (res.code == 200) {
this.dayData = res.data.runTime;
}
});
},
//
getAlarnStatus() {
let data = {
pageNum: 1,
pageSize: 10,
status: "0",
};
let timeArr = [getDay(0), getDay(0)];
alarmRecordList(this.addDateRange(data, timeArr)).then((res) => {
if (res.code == 200 && res.rows.length > 0) {
this.isShowWarning = true;
} else {
this.isShowWarning = false;
}
});
},
goWarning() {
// this.exitFullscreen();
this.$router.push("/alarm/alarmRecord");
},
// undefined
isObjectValid(obj) {
return obj && Object.keys(obj).length > 0;
},
getSysBuild() {
spaceTree().then((res) => {
if (res.code == 200) {
//
console.log("楼栋返回值", res);
let newRes = { ...res };
if (newRes.data && newRes.data[0] && newRes.data[0].children) {
newRes.data[0].children = newRes.data[0].children.filter((item) => {
// label ""
return item.label && item.label.includes("空调风柜");
});
}
// 1 5
const targetLevel = 5;
// data[0] 1
if (newRes.data[0]) {
this.removeChildrenAfterLevel(newRes.data[0], 1, targetLevel);
}
console.log("筛选后的新结果", newRes);
this.treeData = newRes.data;
this.$nextTick(() => {
//
this.getExpandedKeys(this.treeData, 1);
if (this.treeData.length > 0) {
//
const lastLevelFirstChild = this.findLastLevelFirstChild(
this.treeData[0]
);
// this.$refs.tree.setCurrentKey(
// this.treeData[0].children[0].children[0].children[0].id
// );
// ,
this.$refs.tree.setCurrentKey(lastLevelFirstChild.id);
//
this.currentId = lastLevelFirstChild.id;
this.currentLevel = lastLevelFirstChild.level;
this.currentName = lastLevelFirstChild.label;
console.log("当前选中节点ID", this.currentId);
console.log("当前选中节点层级", this.currentLevel);
console.log("当前选中节点名称", this.currentName);
// ,getWindList()
if (
this.currentName.includes("新风阀") ||
this.currentName.includes("AHU")
) {
this.isShowdamper = true;
this.$nextTick(() => {
this.$refs.damperMonitorRef.getWindList();
});
} else {
this.isShowdamper = false;
this.$nextTick(() => {
this.$refs.normalMonitorRef.getWindList();
});
}
}
});
}
});
},
// children
removeChildrenAfterLevel(obj, currentLevel, targetLevel) {
if (currentLevel >= targetLevel) {
// children
obj.children = [];
return;
}
if (obj.children && obj.children.length > 0) {
// children
for (let i = 0; i < obj.children.length; i++) {
this.removeChildrenAfterLevel(
obj.children[i],
currentLevel + 1,
targetLevel
);
}
}
},
//
findLastLevelFirstChild(node, level = 1) {
if (!node.children || node.children.length === 0) {
return {
id: node.id,
level,
label: node.label,
};
}
return this.findLastLevelFirstChild(node.children[0], level + 1);
},
//
getExpandedKeys(nodes, level) {
nodes.forEach((node) => {
if (level <= this.currentId + 4) {
this.expandedKeys.push(node.id);
}
if (node.children) {
this.getExpandedKeys(node.children, level + 1);
}
});
},
//
getIconClass(node) {
// console.log("", node);
if (node.level === 5) {
// 5
if (node.expanded) {
return "el-icon-document-opened"; // 5
}
return "el-icon-document"; // 5
}
if (node.expanded) {
return "el-icon-folder-opened"; // 5
}
return "el-icon-folder-add"; // 5
},
handleNodeExpand(node) {
//
},
handleNodeCollapse(node) {
//
},
//
handleNodeClick(node, data) {
console.log("点击的当前节点", node, data);
if (data.level !== 5) {
console.log("不是第5层000");
// ,
this.$refs.tree.setCurrentKey(this.currentId);
console.log("当前选中节点ID", this.currentId);
console.log("当前选中节点层级", this.currentLevel);
console.log("当前选中节点名称", this.currentName);
} else {
console.log("第5层111");
this.currentId = node.id;
this.currentLevel = data.level;
this.currentName = node.label;
// ,
this.$refs.tree.setCurrentKey(this.currentId);
console.log("当前选中节点ID", this.currentId);
console.log("当前选中节点层级", this.currentLevel);
console.log("当前选中节点名称", this.currentName);
// ,getWindList()
if (
this.currentName.includes("新风阀") ||
this.currentName.includes("AHU")
) {
this.isShowdamper = true;
this.$nextTick(() => {
this.$refs.damperMonitorRef.getWindList();
});
} else {
this.isShowdamper = false;
this.$nextTick(() => {
this.$refs.normalMonitorRef.getWindList();
});
}
}
},
},
};
</script>
<style lang="scss" scoped>
.monitor {
width: 100%;
min-height: 100vh;
background-color: black;
color: #fff;
.monitor-top {
width: 100%;
display: flex;
flex-direction: row;
align-items: flex-start;
justify-content: space-between;
flex-wrap: nowrap;
padding: 0.1rem 0.2rem;
position: relative;
.title-left {
width: 3.41rem;
height: 0.8rem;
}
.title-center {
width: 9.46rem;
height: 0.8rem;
}
.title-right {
width: 5.04rem;
height: 0.78rem;
}
.sys-title {
position: absolute;
top: 40%;
left: 50%;
transform: translate(-50%, -50%);
font-size: 0.28rem;
color: #ffffff;
font-weight: bold;
z-index: 100;
cursor: pointer;
}
.nowTime {
position: absolute;
top: 0.37rem;
right: 0.6rem;
font-size: 0.18rem;
color: #ffffff;
font-weight: bold;
z-index: 100;
}
.sys-logo {
width: 1.8rem;
height: 0.5rem;
position: absolute;
top: 0.26rem;
left: 0.8rem;
z-index: 10;
}
.monitor-time {
position: absolute;
top: 0.44rem;
left: 4.2rem;
z-index: 10;
font-size: 0.18rem;
color: #ffffff;
font-weight: bold;
}
.icon_warning {
position: absolute;
top: 0.39rem;
right: 4.4rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.25rem 0 0.27rem;
cursor: pointer;
/* 添加闪烁动画 */
animation: blink 1s infinite;
}
@keyframes blink {
100% {
opacity: 1;
}
50% {
opacity: 0;
}
}
.icon_home {
position: absolute;
top: 0.39rem;
right: 4rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.2rem 0 0.27rem;
cursor: pointer;
}
.back-icon {
position: absolute;
top: 0.39rem;
right: 3.7rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
cursor: pointer;
}
}
}
.app-container {
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: stretch;
height: 100%;
padding: 0.3rem 0.2rem 0 0.35rem;
width: 100%;
.left-tree {
width: 256px;
padding: 15px 10px 10px 10px;
border: 1px solid #004b8c;
.tree-div {
height: 7rem;
overflow-y: auto;
}
.status {
display: flex;
flex-direction: row;
justify-content: space-between;
flex-wrap: wrap;
margin-top: 20px;
.status-li {
width: 50%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin-bottom: 15px;
}
.status1,
.status2,
.status3,
.status4 {
display: flex;
flex-direction: row;
align-items: center;
margin-bottom: 5px;
}
.status1::before {
content: "";
width: 10px;
height: 10px;
border-radius: 50%;
background-color: #00d2ff;
margin-right: 5px;
}
.status2::before {
content: "";
width: 10px;
height: 10px;
border-radius: 50%;
background-color: #ff2f2f;
margin-right: 5px;
}
.status3::before {
content: "";
width: 10px;
height: 10px;
border-radius: 50%;
background-color: #ff9908;
margin-right: 5px;
}
.status4::before {
content: "";
width: 10px;
height: 10px;
border-radius: 50%;
background-color: #7398c7;
margin-right: 5px;
}
}
}
.right-monitor {
width: calc(100% - 280px);
display: flex;
flex-direction: column;
justify-content: flex-start;
}
}
.tree-container {
height: 300px; /* 设置固定高度 */
overflow-y: auto; /* 启用垂直滚动条 */
}
//
:-webkit-scrollbar {
width: 10px; /* 滚动条宽度 */
}
::-webkit-scrollbar-track {
background: transparent !important; /* 滚动条轨道背景色 */
}
.custom-tree-node {
flex: 1;
display: flex;
align-items: center;
justify-content: space-between;
font-size: 14px;
padding-right: 8px;
.tree-left {
.custom-tree-icon {
margin-right: 5px;
}
}
}
.highlight {
background-color: #003863 !important; /* 定义高亮的背景颜色 */
color: #ffffff !important;
font-weight: bold;
}
//
@media (min-width: 0px) and (max-width: 990px) {
.app-container {
padding: 0rem 0.2rem 0 0.35rem !important;
}
.app-container .left-tree {
width: 200px !important;
min-height: 340px !important;
padding: 0.15rem 0 !important;
}
.app-container .tree-div {
height: 300px !important;
width: 100%;
overflow-x: hidden !important;
}
.app-container .right-monitor {
width: calc(100% - 210px) !important;
}
.custom-tree-node {
font-size: 12px !important;
}
}
</style>
<style scoped>
/* 自定义高亮颜色 */
.left-tree
>>> .el-tree--highlight-current
.el-tree-node.is-current
> .el-tree-node__content {
background-color: #285b9e !important;
/* color: #f56c6c; */
color: #25f1f8;
}
/* 手机端样式 */
@media (min-width: 0px) and (max-width: 990px) {
.left-tree >>> .el-tree-node__content > .el-tree-node__expand-icon {
padding: 3px !important;
}
}
</style>

3033
src/views/aircAndWindc/awSysMonitor/components/damperMonitor.vue

File diff suppressed because it is too large Load Diff

1735
src/views/aircAndWindc/awSysMonitor/components/normalMonitor.vue

File diff suppressed because it is too large Load Diff

1676
src/views/aircAndWindc/awSysMonitor/index.vue

File diff suppressed because it is too large Load Diff

6
src/views/alarm/alarmCode/index.vue

@ -21,6 +21,7 @@
v-model="queryParams.status"
placeholder="选择采集类别"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_collection_type"
@ -35,6 +36,7 @@
v-model="queryParams.eventType"
placeholder="选择事件类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_event_type"
@ -49,6 +51,7 @@
v-model="queryParams.alarmLevel"
placeholder="选择报警等级"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_level"
@ -226,6 +229,7 @@
v-model="form.collectionType"
placeholder="请选择采集类别"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_collection_type"
@ -244,6 +248,7 @@
v-model="form.eventType"
placeholder="请选择事件类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_event_type"
@ -259,6 +264,7 @@
v-model="form.alarmLevel"
placeholder="请选择报警等级"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_level"

4
src/views/alarm/alarmRecord/index.vue

@ -21,6 +21,7 @@
v-model="queryParams.alarmType"
placeholder="选择报警类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_type"
@ -35,6 +36,7 @@
v-model="queryParams.eventType"
placeholder="选择事件类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_event_type"
@ -49,6 +51,7 @@
v-model="queryParams.alarmLevel"
placeholder="选择报警等级"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_level"
@ -71,6 +74,7 @@
v-model="queryParams.status"
placeholder="选择处理状态"
clearable
filterable
>
<el-option label="未处理" value="0" />
<el-option label="已处理" value="1" />

31
src/views/alarm/alarmRule/index.vue

@ -13,6 +13,7 @@
v-model="queryParams.alarmType"
placeholder="选择报警类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_type"
@ -27,6 +28,7 @@
v-model="queryParams.eventType"
placeholder="选择事件类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_event_type"
@ -41,6 +43,7 @@
v-model="queryParams.alarmLevel"
placeholder="选择报警等级"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_level"
@ -252,6 +255,7 @@
placeholder="请选择设备类型"
clearable
@change="handleDevice"
filterable
>
<el-option
v-for="item in devices"
@ -269,6 +273,7 @@
placeholder="请选择设备类型"
clearable
@change="handleMeter"
filterable
>
<el-option
v-for="item in cpmList"
@ -287,6 +292,7 @@
v-model="form.alarmType"
placeholder="请选择报警类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_type"
@ -314,6 +320,7 @@
v-model="form.eventType"
placeholder="请选择事件类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_event_type"
@ -329,6 +336,7 @@
v-model="form.alarmLevel"
placeholder="请选择报警等级"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_level"
@ -346,6 +354,7 @@
v-model="form.triggerEvent"
placeholder="请选择"
clearable
filterable
>
<el-option label="开" value="0" />
<el-option label="关" value="1" />
@ -358,6 +367,7 @@
v-model="form.timePeriodSet"
placeholder="请选择"
clearable
filterable
>
<el-option label="全时段" value="0" />
<el-option label="自定义时段" value="1" />
@ -432,7 +442,12 @@
<el-row type="flex" justify="flex-start">
<el-col :span="12">
<el-form-item label="状态" prop="status">
<el-select v-model="form.status" placeholder="请选择" clearable>
<el-select
v-model="form.status"
placeholder="请选择"
clearable
filterable
>
<el-option label="已启用" value="0" />
<el-option label="未启用" value="1" />
</el-select>
@ -653,7 +668,8 @@ export default {
this.multiple = !selection.length;
},
//
handleDevice(selectedValue) {
handleDevice(selectedValue, val) {
console.log("选择设备", selectedValue);
// value label
const selectedItem = this.devices.find(
(item) => item.id === selectedValue
@ -668,8 +684,13 @@ export default {
//
this.getCpmIdList(this.form.ledgerId);
}
//
this.form.cpmId = "";
if (!val) {
console.log("非第一次打开弹框-选择设备类型");
//
this.form.cpmId = "";
} else {
console.log("第一次打开弹框-默认采集点位");
}
},
//
getCpmIdList(id) {
@ -760,6 +781,8 @@ export default {
};
this.open = true;
this.title = "修改报警规则";
// handleDevice
this.handleDevice(this.form.ledgerId, true);
});
},
/** 提交按钮 */

13
src/views/bigScreen/bigScreen.vue

@ -10,7 +10,7 @@
class="loginD_img_down"
alt=""
/>
<div class="sys-title">楼宇智慧管理系统平台</div>
<div class="sys-title" @click="goSys">楼宇智慧管理系统平台</div>
<!-- <div class="day">已监测100天</div> -->
<div class="set">
<img src="../../assets/images/icon_time.png" class="icon_time" alt="" />
@ -52,7 +52,7 @@
<div class="special-top">
<div class="special-title">
<div class="title-left">
<div>冷源系统能</div>
<div>冷源系统能</div>
<time-data
v-model="sharedIndex"
:currentIndex="sharedIndex"
@ -153,7 +153,7 @@
src="../../assets/images/message-img5.png"
alt=""
/>
<div class="message-data">{{ viewMes.eleUnitArea }}wkh/</div>
<div class="message-data">{{ viewMes.eleUnitArea }}kwh/</div>
<div>面积电耗</div>
</div>
<div class="message-li">
@ -162,7 +162,7 @@
src="../../assets/images/message-img7.png"
alt=""
/>
<div class="message-data">{{ viewMes.waterUnitArea }}kwh</div>
<div class="message-data">{{ viewMes.waterUnitArea }}t/</div>
<div>面积水耗</div>
</div>
<div class="message-li">
@ -171,7 +171,7 @@
src="../../assets/images/message-img8.png"
alt=""
/>
<div class="message-data">{{ viewMes.coldUnitArea }}kw/lm³</div>
<div class="message-data">{{ viewMes.coldUnitArea }}kw/</div>
<div>面积冷耗</div>
</div>
<div class="message-li">
@ -180,7 +180,7 @@
src="../../assets/images/message-img9.png"
alt=""
/>
<div class="message-data">{{ viewMes.gasUnitArea }}kw/lm³</div>
<div class="message-data">{{ viewMes.gasUnitArea }}t/</div>
<div>面积汽耗</div>
</div>
</div>
@ -394,6 +394,7 @@ export default {
background-clip: text;
-webkit-background-clip: text;
color: transparent;
cursor: pointer;
}
.day {
position: absolute;

2
src/views/bigScreen/components/coldSysEnergy.vue

@ -2,8 +2,8 @@
<div class="energy_content">
<div class="sys_charts" ref="sys_charts"></div>
<div class="eer">
<div>用电量:{{ energyMes.totalEle }}kw/h</div>
<div>产冷量:{{ energyMes.totalCold }}kwh</div>
<div>用电量:{{ energyMes.totalEle }}kw/h</div>
</div>
</div>
</template>

1107
src/views/boilerSys/boilerMonitor/boilerMonitorDetails.vue

File diff suppressed because it is too large Load Diff

20
src/views/boilerSys/boilerMonitor/index.vue

@ -0,0 +1,20 @@
<template>
<div></div>
</template>
<script>
export default {
created() {
this.toPage();
},
methods: {
toPage() {
console.log("需要跳转的")
//
this.$router.push("/boilerMonitorDetails")
},
},
};
</script>
<style></style>

1011
src/views/boilerSys/heatingPump/heatingPumpDetails.vue

File diff suppressed because it is too large Load Diff

20
src/views/boilerSys/heatingPump/index.vue

@ -0,0 +1,20 @@
<template>
<div></div>
</template>
<script>
export default {
created() {
this.toPage();
},
methods: {
toPage() {
console.log("需要跳转的")
//
this.$router.push("/heatingPumpDetails")
},
},
};
</script>
<style></style>

703
src/views/boilerSys/hotWaterBoiler/hotWaterBoilerDetails.vue

@ -0,0 +1,703 @@
<template>
<div class="monitor" v-loading="loading">
<div class="monitor-top">
<img
class="title-left"
src="../../../assets/images/title-left.png"
alt=""
/>
<img
class="title-center"
src="../../../assets/images/title-center.png"
alt=""
@click="goSys"
/>
<img
class="title-right"
src="../../../assets/images/title-right.png"
alt=""
/>
<div class="sys-title" @click="goSys">采暖设备监测</div>
<!-- logo -->
<img src="../../../assets/images/logo-3.png" class="sys-logo" alt="" />
<div class="nowTime">{{ formattedDate }}</div>
<div class="monitor-time">已监测时长:{{ dayData }}</div>
<img
class="icon_warning"
src="../../../assets/images/warning.png"
title="报警记录"
@click="goWarning"
v-if="isShowWarning"
alt=""
/>
<img
class="icon_home"
src="../../../assets/images/icon_home.png"
title="首页"
@click="goSys"
alt=""
/>
<img
class="back-icon"
src="../../../assets/images/back-icon.png"
title="返回"
@click="goBack"
alt=""
/>
</div>
<div class="hotWater-div">
<div
class="hotWater-li"
v-for="(boiler, index) in hotWaterBoilerData"
:key="index"
>
<div class="special-div one">
<div class="special-top">
<div class="special-title">
<div class="title-left">
<div>{{ boiler.name }}</div>
</div>
</div>
</div>
<div class="hotWater">
<img
class="hotWater-img"
src="../../../assets/images/hotWater.png"
alt=""
/>
</div>
<div class="info">
<div class="hotWater-tem">
<div class="pump-data-li">
<div>出水温度:</div>
<div class="pump-data-text">
{{ getTemperatureData(boiler, "出水温度") }}
</div>
</div>
<div class="pump-data-li">
<div>回水温度:</div>
<div class="pump-data-text">
{{ getTemperatureData(boiler, "回水温度") }}
</div>
</div>
<div class="pump-data-li">
<div>炉水温度:</div>
<div class="pump-data-text">
{{ getTemperatureData(boiler, "炉水温度") }}
</div>
</div>
<div class="pump-data-li">
<div>烟道温度:</div>
<div class="pump-data-text">
{{ getTemperatureData(boiler, "烟道温度") }}
</div>
</div>
</div>
<div class="port-right">
<div class="port">
<div :class="['port-li', getFireSignalClass(boiler, '大火')]">
大火控制信号发出
</div>
<div :class="['port-li', getFireSignalClass(boiler, '小火')]">
小火控制信号发出
</div>
<div class="port-li port-close">燃烧机电源</div>
</div>
<div class="bad-div">
故障信息:<span class="bad-text">{{
getFaultInfo(boiler)
}}</span>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- <div class="hotWater-div">
<div class="hotWater-li">
<div class="special-div one">
<div class="special-top">
<div class="special-title">
<div class="title-left">
<div>1号热水锅炉</div>
</div>
</div>
</div>
<div class="hotWater">
<img
class="hotWater-img"
src="../../../assets/images/hotWater.png"
alt=""
/>
</div>
<div class="info">
<div class="hotWater-tem">
<div class="pump-data-li">
<div>出水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>回水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>炉水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>烟道温度:</div>
<div class="pump-data-text">29.7</div>
</div>
</div>
<div class="port-right">
<div class="port">
<div class="port-li port-open">大火控制信号发出</div>
<div class="port-li port-close">小伙控制信号发出</div>
<div class="port-li port-close">燃烧机电源</div>
</div>
<div class="bad-div">
故障信息:<span class="bad-text">炉水温度传感器故障</span>
</div>
</div>
</div>
</div>
</div>
<div class="hotWater-li">
<div class="special-div one">
<div class="special-top">
<div class="special-title">
<div class="title-left">
<div>2号热水锅炉</div>
</div>
</div>
</div>
<div class="hotWater">
<img
class="hotWater-img"
src="../../../assets/images/hotWater.png"
alt=""
/>
</div>
<div class="info">
<div class="hotWater-tem">
<div class="pump-data-li">
<div>出水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>回水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>炉水温度:</div>
<div class="pump-data-text">29.7</div>
</div>
<div class="pump-data-li">
<div>烟道温度:</div>
<div class="pump-data-text">29.7</div>
</div>
</div>
<div class="port-right">
<div class="port">
<div class="port-li port-open">大火控制信号发出</div>
<div class="port-li port-close">小伙控制信号发出</div>
<div class="port-li port-close">燃烧机电源</div>
</div>
<div class="bad-div">
故障信息:<span class="bad-text">炉水温度传感器故障</span>
</div>
</div>
</div>
</div>
</div>
</div> -->
</div>
</template>
<script>
import { runTime } from "@/api/centerairC/sysMonitor";
import { alarmRecordList } from "@/api/alarm/alarmRecord";
import { hotWaterBoiler } from "@/api/boiler/hotwaterBoiler";
import { getDay } from "@/utils/datetime";
export default {
name: "boilerMonitorDetails",
data() {
return {
loading: false,
currentDate: new Date(),
nowTimer: null,
timer: null, // ID
isShowWarning: false, //
dayData: "", //
currentWeekday: "",
//
hotWaterBoilerData: [],
};
},
computed: {
formattedDate() {
const year = this.currentDate.getFullYear();
const month = String(this.currentDate.getMonth() + 1).padStart(2, "0");
const day = String(this.currentDate.getDate()).padStart(2, "0");
const hours = String(this.currentDate.getHours()).padStart(2, "0");
const minutes = String(this.currentDate.getMinutes()).padStart(2, "0");
const seconds = String(this.currentDate.getSeconds()).padStart(2, "0");
const weekDays = [
"星期日",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
];
const weekDay = weekDays[this.currentDate.getDay()];
return `${year}${month}${day}${hours}:${minutes}:${seconds} ${weekDay}`;
},
},
created() {
const weekdays = [
"星期日",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
];
const date = new Date();
const dayIndex = date.getDay();
this.currentWeekday = weekdays[dayIndex];
console.log("今天是星期几", this.currentWeekday);
},
mounted() {
this.getAlarnStatus();
this.getDayData();
//
this.getHotWaterBoiler();
// 10
this.timer = setInterval(() => {
this.getAlarnStatus();
this.getDayData();
//
this.getHotWaterBoiler();
}, 10000);
},
beforeDestroy() {
//
if (this.timer) {
clearInterval(this.timer);
}
//
if (this.nowTimer) {
clearInterval(this.nowTimer);
}
},
methods: {
// Get temperature data by type (keep as is)
getTemperatureData(boiler, type) {
if (!boiler || !boiler.values) return "--";
const item = boiler.values.find(
(v) => v.otherName && v.otherName.includes(type)
);
return item && item.curValue !== null ? item.curValue : "--";
},
// Get fire signal class for individual signals
getFireSignalClass(boiler, signalType) {
if (!boiler || !boiler.values) return "port-close";
// Get fire signal values
const fire1Item = boiler.values.find(
(v) => v.otherName && v.otherName.includes("火力1")
);
const fire2Item = boiler.values.find(
(v) => v.otherName && v.otherName.includes("火力2")
);
const fire1Value =
fire1Item && fire1Item.curValue !== null ? fire1Item.curValue : 0;
const fire2Value =
fire2Item && fire2Item.curValue !== null ? fire2Item.curValue : 0;
// Determine which signal should be open based on the logic:
// : fire1=1 and fire2=1
// : fire1=1 and fire2=0
if (signalType === "大火" && fire1Value == 1 && fire2Value == 1) {
return "port-open";
} else if (signalType === "小火" && fire1Value == 1 && fire2Value == 0) {
return "port-open";
} else {
return "port-close";
}
},
// Get fire status text based on both fire signals (for other uses if needed)
getFireStatusText(boiler) {
if (!boiler || !boiler.values) return "未开机";
const fire1Item = boiler.values.find(
(v) => v.otherName && v.otherName.includes("火力1")
);
const fire2Item = boiler.values.find(
(v) => v.otherName && v.otherName.includes("火力2")
);
const fire1Value =
fire1Item && fire1Item.curValue !== null ? fire1Item.curValue : 0;
const fire2Value =
fire2Item && fire2Item.curValue !== null ? fire2Item.curValue : 0;
// If both are 0, boiler is off
if (fire1Value == 0 && fire2Value == 0) {
return "无火信号";
}
// If fire1 is 1 and fire2 is 0, small fire
else if (fire1Value == 1 && fire2Value == 0) {
return "小火控制信号发出";
}
// If both fire1 and fire2 are 1, big fire
else if (fire1Value == 1 && fire2Value == 1) {
return "大火控制信号发出";
}
// Any other case
else {
return "未开机";
}
},
// Get fault information (placeholder implementation)
// Get fault information based on fault code
getFaultInfo(boiler) {
if (!boiler || !boiler.values) return "无故障";
// Find the fault item - you might need to adjust this based on actual data structure
const faultItem = boiler.values.find(
(v) => v.otherName && v.otherName.includes("故障")
);
if (!faultItem || faultItem.curValue === null) {
return "无故障";
}
// Convert fault code to descriptive text
const faultCode = parseInt(faultItem.curValue);
switch (faultCode) {
case 0:
return "无故障";
case 1:
return "炉水温度传感器故障";
case 2:
return "出水温度传感器故障";
case 3:
return "回水温度传感器故障";
case 4:
return "锅炉水位极低";
case 5:
return "燃烧机故障";
case 6:
return "炉水超温";
case 7:
return "循环水流故障";
case 9:
return "定时时间到关机(正常关机模式)";
case 11:
return "烟道传感器故障";
case 12:
return "烟道超温故障";
case 13:
return "检漏故障";
default:
return "未知故障";
}
},
//
getHotWaterBoiler() {
let queryParams = {
systemType: "3",
type: "0",
};
hotWaterBoiler(queryParams).then((res) => {
if (res.code == 200) {
console.log("热水锅炉数据", res.rows);
if (res.rows.length > 0) {
this.hotWaterBoilerData = res.rows;
} else {
this.hotWaterBoilerData = [];
}
}
});
},
//
goSys() {
this.$router.push("/");
},
//
goBack() {
window.history.go(-2);
},
//
getDayData() {
runTime().then((res) => {
if (res.code == 200) {
this.dayData = res.data.runTime;
}
});
},
//
getAlarnStatus() {
let data = {
pageNum: 1,
pageSize: 10,
status: "0",
};
let timeArr = [getDay(0), getDay(0)];
alarmRecordList(this.addDateRange(data, timeArr)).then((res) => {
if (res.code == 200 && res.rows.length > 0) {
this.isShowWarning = true;
} else {
this.isShowWarning = false;
}
});
},
goWarning() {
this.$router.push("/alarm/alarmRecord");
},
},
};
</script>
<style lang="scss" scoped>
.monitor {
width: 100%;
min-height: 100vh;
background-color: black;
color: #fff;
.monitor-top {
width: 100%;
display: flex;
flex-direction: row;
align-items: flex-start;
justify-content: space-between;
flex-wrap: nowrap;
padding: 0.1rem 0.2rem;
position: relative;
.title-left {
width: 3.41rem;
height: 0.8rem;
}
.title-center {
width: 9.46rem;
height: 0.8rem;
}
.title-right {
width: 5.04rem;
height: 0.78rem;
}
.sys-title {
position: absolute;
top: 40%;
left: 50%;
transform: translate(-50%, -50%);
font-size: 0.28rem;
color: #ffffff;
font-weight: bold;
z-index: 100;
cursor: pointer;
}
.nowTime {
position: absolute;
top: 0.37rem;
right: 0.6rem;
font-size: 0.18rem;
color: #ffffff;
font-weight: bold;
z-index: 100;
}
.sys-logo {
width: 1.8rem;
height: 0.5rem;
position: absolute;
top: 0.26rem;
left: 0.8rem;
z-index: 10;
}
.monitor-time {
position: absolute;
top: 0.44rem;
left: 4.2rem;
z-index: 10;
font-size: 0.18rem;
color: #ffffff;
font-weight: bold;
}
.icon_warning {
position: absolute;
top: 0.39rem;
right: 4.4rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.25rem 0 0.27rem;
cursor: pointer;
/* 添加闪烁动画 */
animation: blink 1s infinite;
}
@keyframes blink {
100% {
opacity: 1;
}
50% {
opacity: 0;
}
}
.icon_home {
position: absolute;
top: 0.39rem;
right: 4rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.2rem 0 0.27rem;
cursor: pointer;
}
.back-icon {
position: absolute;
top: 0.39rem;
right: 3.7rem;
z-index: 10;
width: 0.35rem;
height: 0.32rem;
cursor: pointer;
}
}
.hotWater-div {
width: 100%;
padding: 0.2rem;
display: flex;
flex-direction: row;
align-content: stretch;
justify-content: space-between;
.hotWater-li {
width: 49%;
.hotWater {
width: 100%;
padding: 0.25rem 0.2rem;
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
.hotWater-img {
width: 6.4rem;
height: 3.5rem;
}
}
.info {
display: flex;
flex-direction: row;
justify-content: center; /* Center content horizontally */
align-items: flex-start; /* Align to top */
width: 100%;
padding: 0 0.25rem 0.15rem 0.7rem;
gap: 0.5rem; /* Add space between elements */
.hotWater-tem {
flex: 1; /* Allow to grow */
min-width: 35%; /* Minimum width */
background: #262f58;
border-radius: 0.1rem;
font-size: 0.16rem;
display: flex;
flex-direction: column;
padding: 0.25rem 0;
.pump-data-li {
width: 100%;
padding: 0 0.4rem; /* Increase horizontal padding */
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
margin: 0.25rem 0;
.pump-data-text {
color: #05d120;
font-weight: bold;
}
}
}
.port-right {
flex: 1; /* Allow to grow */
display: flex;
flex-direction: column;
padding: 0.25rem 0.6rem; /* Increase horizontal padding */
min-width: 35%; /* Minimum width */
.port {
display: flex;
flex-direction: column;
gap: 0.3rem; /* Increase spacing between elements */
.port-li {
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: center;
width: 100%;
font-size: 0.16rem;
color: #c9c6c6;
position: relative;
padding-left: 0.3rem; /* Increase left padding for indicator */
}
.port-open::before,
.port-close::before {
content: "";
position: absolute;
left: 0;
top: 50%;
transform: translateY(-50%);
width: 0.18rem; /* Slightly larger indicator */
height: 0.18rem;
border-radius: 50%;
border: 0.02rem solid white;
}
.port-open::before {
background-color: #00ff00; /* Brighter green for active */
}
.port-close::before {
background-color: #666; /* Darker gray for inactive */
}
}
.bad-div {
margin-top: 0.35rem; /* Increase spacing */
font-size: 0.16rem;
color: #db4d4d;
.bad-text {
margin-left: 0.15rem;
background: #5581c4;
border-radius: 0.15rem; /* Slightly larger radius */
padding: 0.15rem 0.2rem; /* More padding */
color: #fff;
display: inline-block; /* Better text wrapping */
}
}
}
}
}
}
}
</style>
<style scoped>
.special-div .special-title {
padding-left: 0.36rem !important;
font-size: 0.2rem !important;
line-height: 0.23rem !important;
background-size: 1.4rem 0.35rem !important;
background-position: 0px -0.03rem !important;
}
.special-div .special-top {
padding: 0.04rem 0.26rem 0.04rem 0px;
min-height: 0.37rem;
}
</style>

20
src/views/boilerSys/hotWaterBoiler/index.vue

@ -0,0 +1,20 @@
<template>
<div></div>
</template>
<script>
export default {
created() {
this.toPage();
},
methods: {
toPage() {
console.log("需要跳转的")
//
this.$router.push("/hotWaterBoilerDetails")
},
},
};
</script>
<style></style>

32
src/views/centerairC/delaySwitch/index.vue

@ -85,7 +85,7 @@
</div>
</div>
<!-- 第一组冷却塔放在冷却泵连接处 -->
<div class="last openLast" v-if="item.name === '自动开机'">
<div class="last closeLast" v-if="item.name === '自动关机'">
<div class="reverse-img">
<img src="../../../assets/images/yuan.png" class="yuan" alt="" />
<img src="../../../assets/images/yuan.png" class="yuan" alt="" />
@ -100,10 +100,10 @@
<div class="delay-input">
<el-input
size="mini"
v-model="openTower.curValue"
@keyup.enter.native="handleEnter(openTower, $event)"
@input="handleInput(openTower)"
@focus="handleFocus('openTower')"
v-model="closeTower.curValue"
@keyup.enter.native="handleEnter(closeTower, $event)"
@input="handleInput(closeTower)"
@focus="handleFocus('closeTower')"
@blur="handleBlur()"
></el-input
>S
@ -117,12 +117,12 @@
class="butterflyValve"
alt=""
/>
<div>{{ openTower.pointName }}</div>
<div>{{ closeTower.pointName }}</div>
</div>
</div>
</div>
<!-- 第二组冷却塔放在主机连接处 -->
<div class="last closeLast" v-if="item.name === '自动关机'">
<div class="last openLast" v-if="item.name === '自动开机'">
<div class="reverse-img">
<img src="../../../assets/images/yuan.png" class="yuan" alt="" />
<img src="../../../assets/images/yuan.png" class="yuan" alt="" />
@ -137,10 +137,10 @@
<div class="delay-input">
<el-input
size="mini"
v-model="closeTower.curValue"
@keyup.enter.native="handleEnter(closeTower, $event)"
@input="handleInput(closeTower)"
@focus="handleFocus('closeTower')"
v-model="openTower.curValue"
@keyup.enter.native="handleEnter(openTower, $event)"
@input="handleInput(openTower)"
@focus="handleFocus('openTower')"
@blur="handleBlur()"
></el-input
>S
@ -154,7 +154,7 @@
class="butterflyValve"
alt=""
/>
<div>{{ closeTower.pointName }}</div>
<div>{{ openTower.pointName }}</div>
</div>
</div>
</div>
@ -198,14 +198,14 @@ export default {
if (res.code == 200) {
// res.rows delayList
this.delayList = JSON.parse(JSON.stringify(res.rows));
// openTower
// closeTower
if (this.delayList[0] && this.delayList[0].values.length > 0) {
// pop delayList values
this.openTower = { ...this.delayList[0].values.pop() };
this.closeTower = { ...this.delayList[0].values.pop() };
}
// closeTower
// openTower
if (this.delayList[1] && this.delayList[1].values.length > 0) {
this.closeTower = { ...this.delayList[1].values.pop() };
this.openTower = { ...this.delayList[1].values.pop() };
}
} else {
this.delayList = [];

7
src/views/centerairC/enSourceAnalysis/components/deviceEnergy.vue

@ -425,6 +425,11 @@ export default {
this.option2.series[0].data = this.electData2;
this.option2.xAxis.data = this.dateList2;
this.option2.yAxis.name = "kwh";
this.option2.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
console.log("x轴", this.dateList2);
console.log("折线图数据", this.electData2);
this.screenAdapter();
@ -500,7 +505,7 @@ export default {
show: false, //
},
grid: {
top: "5%",
top: "6%",
left: "3%",
right: "4.4%",
bottom: "20%",

5
src/views/centerairC/enSourceAnalysis/components/equipment.vue

@ -560,6 +560,11 @@ export default {
console.log("图表数据", this.dataArr);
this.option1.series = this.dataArr;
this.option1.xAxis.data = this.timeData;
this.option1.yAxis.name = "kwh";
this.option1.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
//
this.chartInstance1.clear();
this.screenAdapter();

40
src/views/centerairC/energyAnalysis/components/energyAnalysis.vue

@ -487,7 +487,7 @@ export default {
},
grid: {
top: "5%",
top: "9%",
left: "3%",
right: "4.4%",
bottom: "20%",
@ -696,6 +696,17 @@ export default {
//
screenAdapter2() {
// console.log("checkList:", this.checkList);
//
// const selected = {
// EER: false,
// : false,
// : false,
// };
// const updatedSelected = {
// ...selected,
// [this.checkList]: true,
// };
//
const selected = {
瞬时系统EER: false,
瞬时冷量: false,
@ -705,6 +716,26 @@ export default {
...selected,
[this.checkList]: true,
};
let unit;
// selected
for (const key in updatedSelected) {
if (updatedSelected[key]) {
switch (key) {
case "瞬时系统EER":
unit = "";
break;
case "瞬时冷量":
unit = "kwr";
break;
case "瞬时功率":
unit = "kw";
break;
default:
unit = "";
}
break;
}
}
// console.log(updatedSelected);
//,2.6 mes_ref
const titleFontSize = this.$refs.charts_refs.offsetWidth / 130;
@ -717,6 +748,9 @@ export default {
// data: ["2021", "2022", "2023"],
data: this.dateList2,
},
yAxis: {
name: unit,
},
series: [
{
name: "瞬时系统EER",
@ -756,6 +790,10 @@ export default {
axisLabel: {
fontSize: titleFontSize * 1.5,
},
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: titleFontSize * 1.3,
},
},
};
//.chartInstanceoptiondataoption

911
src/views/centerairC/hostRunReport/index.vue

@ -0,0 +1,911 @@
<template>
<div class="app-container">
<div class="btn-condition">
<div class="condition-left" v-show="showSearch">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
>
<el-form-item label="主机编号" prop="deviceNum">
<el-select
v-model="queryParams.deviceNum"
placeholder="请选择主机编号"
clearable
>
<el-option label="1号主机" value="1" />
<el-option label="2号主机" value="2" />
<el-option label="3号主机" value="3" />
</el-select>
</el-form-item>
<el-form-item label="日期范围" prop="timeArr">
<el-date-picker
style="width: 220px"
v-model="timeArr"
type="daterange"
unlink-panels
range-separator="~"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
@change="dateChange"
>
</el-date-picker>
</el-form-item>
</el-form>
<div class="primary-btn">
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
</div>
<div class="cancel-btn">
<el-button
type="cancel"
icon="el-icon-refresh"
size="mini"
@click="resetQuery"
>重置</el-button
>
</div>
</div>
</div>
<el-row :gutter="10" class="mb8">
<!-- <el-col :span="1.5">
<div class="success-btn">
<el-button
type="success"
@click="leadingPrint"
icon="el-icon-printer"
size="mini"
>打印</el-button
>
</div>
</el-col> -->
<el-col :span="1.5">
<div class="warning-btn">
<el-button
type="warning"
icon="el-icon-download"
size="mini"
@click="handleExport"
>导出</el-button
>
</div>
</el-col>
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="postList" stripe>
<!-- <el-table-column label="主机id" align="center" prop="deviceNum" /> -->
<el-table-column label="时间" align="center" prop="curTime" />
<el-table-column label="蒸发器">
<el-table-column
label="冷冻水进水温度(℃)"
align="center"
prop="tempInChillerWater" />
<el-table-column
label="冷冻水出水温度(℃)"
align="center"
prop="tempOutChillerWater" />
<el-table-column label="设计流量(%)" align="center" prop="designFlow" />
<el-table-column
label="蒸发器压力(kpa)"
align="center"
prop="pressEvapSaturation" />
<el-table-column
label="蒸发器饱和温度(℃)"
align="center"
prop="tempEvapSaturation" />
<el-table-column
label="蒸发器趋近温度(℃)"
align="center"
prop="tempEvapApproaching"
/></el-table-column>
<el-table-column label="冷凝器">
<el-table-column
label="冷却水进水温度(℃)"
align="center"
prop="tempInCoolingWater"
/>
<el-table-column
label="冷却水出水温度(℃)"
align="center"
prop="tempOutCoolingWater"
/>
<el-table-column
label="冷凝器压力(kpa)"
align="center"
prop="pressCondenserSaturation"
/>
<el-table-column
label="冷凝器饱和温度(℃)"
align="center"
prop="tempCondenserSaturation"
/>
<el-table-column
label="冷凝器趋近温度(℃)"
align="center"
prop="tempCondenserApproaching"
/>
</el-table-column>
<el-table-column label="系统">
<el-table-column
label="冷冻水设定值(℃)"
align="center"
prop="setChillerWater"
/>
<el-table-column label="冷水机需求(%)" align="center" prop="setLoad" />
<el-table-column label="总电流(%)" align="center" prop="currentTotal" />
<el-table-column
label="总输入功率(kw)"
align="center"
prop="inputPowerTotal"
/>
<el-table-column
label="压缩机1_压缩比"
align="center"
prop="ratioCompOne"
/>
<el-table-column
label="压缩机2_压缩比"
align="center"
prop="ratioCompTwo"
/>
<el-table-column
label="压缩机3_压缩比"
align="center"
prop="ratioCompThree"
/>
<el-table-column label="膨胀阀开度(%)" align="center" prop="openExv" />
<el-table-column
label="运行中的压缩机数量"
align="center"
prop="runCompNum"
/>
</el-table-column>
<el-table-column label="冷冻泵">
<el-table-column
label="冷冻水泵频率(hz)"
align="center"
prop="frequencyChiller"
/>
<el-table-column
label="冷冻水出水压力(kpa)"
align="center"
prop="pressOutChillerWater"
/>
<el-table-column
label="冷冻水进水压力(kpa)"
align="center"
prop="pressInChillerWater"
/>
</el-table-column>
<el-table-column label="冷却泵">
<el-table-column
label="冷却水泵频率(hz)"
align="center"
prop="frequencyCooling"
/>
<el-table-column
label="冷却水出水压力(kpa)"
align="center"
prop="pressOutCoolingWater"
/>
<el-table-column
label="冷却水进水压力(kpa)"
align="center"
prop="pressInCoolingWater"
/>
</el-table-column>
<el-table-column label="冷却塔">
<el-table-column
label="冷却塔水泵频率(hz)"
align="center"
prop="frequencyCoolingTower"
/>
<el-table-column
label="冷却塔运行数量"
align="center"
prop="runCoolingTower"
/>
</el-table-column>
<el-table-column label="室外温度(℃)" align="center" prop="tempOutdoor" />
<el-table-column
label="室外湿度(%)"
align="center"
prop="humidityOutdoor"
/>
<el-table-column
label="恒压补水罐压力(Mpa)"
align="center"
prop="pressConstantWaterTank"
/>
<el-table-column label="巡查记录人" align="center" prop="recorder" />
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['device:ledger:edit']"
>修改</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改设备台账对话框 -->
<el-dialog :title="title" :visible.sync="open" append-to-body>
<el-form ref="form" :model="form" :rules="rules">
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="主机编号" prop="deviceNum">
<el-select
v-model="form.deviceNum"
placeholder="请选择主机编号"
disabled
>
<el-option label="1号主机" value="1" />
<el-option label="2号主机" value="2" />
<el-option label="3号主机" value="3" />
</el-select> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="设计流量(%)" prop="designFlow">
<el-input v-model="form.designFlow" placeholder="请输入流量(%)" />
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="冷冻水进水温度(℃)" prop="tempInChillerWater">
<el-input
v-model="form.tempInChillerWater"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="冷冻水出水温度(℃)" prop="tempOutChillerWater">
<el-input
v-model="form.tempOutChillerWater"
placeholder="请输入温度(℃)"
/>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="蒸发器饱和温度(℃)" prop="tempEvapSaturation">
<el-input
v-model="form.tempEvapSaturation"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="蒸发器趋近温度(℃)" prop="tempEvapApproaching">
<el-input
v-model="form.tempEvapApproaching"
placeholder="请输入温度(℃)"
/>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="蒸发器压力(kpa)" prop="pressEvapSaturation">
<el-input
v-model="form.pressEvapSaturation"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="冷凝器压力(kpa)"
prop="pressCondenserSaturation"
>
<el-input
v-model="form.pressCondenserSaturation"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="冷却水进水温度(℃)" prop="tempInCoolingWater">
<el-input
v-model="form.tempInCoolingWater"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="冷却水出水温度(℃)" prop="tempOutCoolingWater">
<el-input
v-model="form.tempOutCoolingWater"
placeholder="请输入温度(℃)"
/>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item
label="冷凝器饱和温度(℃)"
prop="tempCondenserSaturation"
>
<el-input
v-model="form.tempCondenserSaturation"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="冷凝器趋近温度(℃)"
prop="tempCondenserApproaching"
>
<el-input
v-model="form.tempCondenserApproaching"
placeholder="请输入温度(℃)"
/>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="冷冻水设定值(℃)" prop="setChillerWater">
<el-input
v-model="form.setChillerWater"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="冷水机需求(%)" prop="setLoad">
<el-input v-model="form.setLoad" placeholder="请输入(%)" />
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="总输入功率(kw)" prop="inputPowerTotal">
<el-input
v-model="form.inputPowerTotal"
placeholder="请输入功率(kw)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="总电流(%)" prop="currentTotal">
<el-input v-model="form.currentTotal" placeholder="请输入(%)" />
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="压缩机1_压缩比" prop="ratioCompOne">
<el-input
v-model="form.ratioCompOne"
placeholder="请输入压缩比"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="压缩机2_压缩比" prop="ratioCompTwo">
<el-input
v-model="form.ratioCompTwo"
placeholder="请输入压缩比"
/>
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="压缩机3_压缩比" prop="ratioCompThree">
<el-input
v-model="form.ratioCompThree"
placeholder="请输入压缩比"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="膨胀阀开度(%)" prop="openExv">
<el-input v-model="form.openExv" placeholder="请输入(%)" />
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="运行中的压缩机数量" prop="runCompNum">
<el-input
v-model="form.runCompNum"
placeholder="请输入数量"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="冷冻水泵频率(hz)" prop="frequencyChiller">
<el-input v-model="form.openExv" placeholder="请输入频率(hz)" />
</el-form-item>
</el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item
label="冷冻水出水压力(kpa)"
prop="pressOutChillerWater"
>
<el-input
v-model="form.pressOutChillerWater"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="冷冻水进水压力(kpa)"
prop="pressInChillerWater"
>
<el-input
v-model="form.pressInChillerWater"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item
label="冷却水出水压力(kpa)"
prop="pressOutCoolingWater"
>
<el-input
v-model="form.pressOutCoolingWater"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="冷却水进水压力(kpa)"
prop="pressInCoolingWater"
>
<el-input
v-model="form.pressInCoolingWater"
placeholder="请输入压力(kpa)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="冷却水泵频率(hz)" prop="frequencyCooling">
<el-input
v-model="form.frequencyCooling"
placeholder="请输入频率(hz)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="冷却塔水泵频率(hz)"
prop="frequencyCoolingTower"
>
<el-input
v-model="form.frequencyCoolingTower"
placeholder="请输入频率(hz)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="冷却塔运行数量" prop="runCoolingTower">
<el-input
v-model="form.runCoolingTower"
placeholder="请输入数量"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item
label="恒压补水罐压力(Mpa)"
prop="pressConstantWaterTank"
>
<el-input
v-model="form.pressConstantWaterTank"
placeholder="请输入压力(Mpa)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="室外温度" prop="tempOutdoor">
<el-input
v-model="form.tempOutdoor"
placeholder="请输入温度(℃)"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="室外湿度(%)" prop="humidityOutdoor">
<el-input
v-model="form.humidityOutdoor"
placeholder="请输入湿度(%)"
/> </el-form-item
></el-col>
</el-row>
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="巡查记录人" prop="recorder">
<el-input
v-model="form.recorder"
placeholder="请输入巡查记录人"
/> </el-form-item
></el-col>
<el-col :span="12">
<el-form-item label="备注" prop="remark">
<el-input
v-model="form.remark"
placeholder="请输入备注"
/> </el-form-item
></el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
<el-button type="primary" @click="submitForm"> </el-button>
</div>
</el-dialog>
<el-dialog
:visible.sync="dialogPrintVisible"
title="打印预览"
class="print-dialog"
>
<div id="report" ref="report" class="report">
<table
border="1"
style="
table-layout: fixed;
width: 100%;
border: 1px solid #e2e6f0;
margin-bottom: 35px;
"
>
<thead>
<tr>
<th rowspan="1" colspan="32">磁悬浮水冷冷水机组数据运行记录表</th>
</tr>
<tr>
<th>主机id</th>
<th>时间</th>
<th colspan="6">蒸发器</th>
<th colspan="5">冷凝器</th>
<th colspan="7">系统</th>
<th colspan="3">冷冻泵</th>
<th colspan="3">冷却泵</th>
<th colspan="2">冷却塔</th>
<th>室外温度()</th>
<th>室外湿度(%)</th>
<th>恒压补水罐压力(Mpa)</th>
<th>巡查记录人</th>
</tr>
<tr>
<th></th>
<th></th>
<th>冷冻水进水温度()</th>
<th>冷冻水出水温度()</th>
<th>设计流量(%)</th>
<th>蒸发器压力(kpa)</th>
<th>蒸发器饱和温度()</th>
<th>蒸发器趋近温度()</th>
<th>冷却水进水温度()</th>
<th>冷却水出水温度()</th>
<th>冷凝器压力(kpa)</th>
<th>冷凝器饱和温度()</th>
<th>冷凝器趋近温度()</th>
<th>冷冻水设定值()</th>
<th>冷水机需求(%)</th>
<th>总电流(%)</th>
<th>总输入功率(kw)</th>
<th>压缩机1_压缩比</th>
<th>膨胀阀开度(%)</th>
<th>运行中的压缩机数量</th>
<th>冷冻水泵频率(hz)</th>
<th>冷冻水出水压力(kpa)</th>
<th>冷冻水进水压力(kpa)</th>
<th>冷却水泵频率(hz)</th>
<th>冷却水出水压力(kpa)</th>
<th>冷却水进水压力(kpa)</th>
<th>冷却塔水泵频率(hz)</th>
<th>冷却塔运行数量</th>
<th></th>
<th></th>
<th></th>
<th></th>
</tr>
</thead>
<tr v-for="(item, index) in postList" :key="index">
<td align="center" v-for="(value, key) in item" :key="key">
{{ value }}
</td>
</tr>
</table>
<div
class="detail"
style="
display: flex;
flex-direction: row;
font-size: 14px;
justify-content: space-between;
flex-wrap: nowrap;
width: 40%;
color: #ffffff;
"
>
<div>操作员: {{ this.userName }}</div>
<div class="print-date">日期 {{ this.operationDate }}</div>
</div>
</div>
<el-row type="flex" justify="end" style="margin-top: 0.2rem">
<el-col :span="2">
<el-button type="info" @click="dialogPrintVisible = false"
>取消</el-button
>
</el-col>
<el-col :span="2" style="margin-left: 60px">
<el-button type="success" @click="surePrint">确认</el-button>
</el-col>
</el-row>
</el-dialog>
</div>
</template>
<script>
import {
reportSysList,
reportSysEdit,
reportSysExport,
} from "@/api/centerairC/hostRunReport";
import { format2, getDay } from "@/utils/datetime";
export default {
name: "ledger",
data() {
return {
timeArr: [],
//
loading: false,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
postList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
deviceNum: "",
params: {
startTime: "",
endTime: "",
},
},
//
form: {},
//
rules: {
deviceName: [
{ required: true, message: "设备名称不能为空", trigger: "blur" },
],
},
dialogPrintVisible: false,
userName: "", //
operationDate: getDay(0), //
titleDate: "",
};
},
created() {
this.userName = sessionStorage.getItem("userName");
this.queryParams.deviceNum = "1";
this.getList();
},
methods: {
//
dateChange() {
// console.log("", this.timeArr);
if (!this.timeArr) {
this.$nextTick(() => {
this.timeArr = [];
this.queryParams.params.startTime = "";
this.queryParams.params.endTime = "";
});
} else {
this.queryParams.params.startTime = this.timeArr[0];
this.queryParams.params.endTime = this.timeArr[1];
}
},
/** 查询设备台账列表 */
getList() {
this.loading = true;
reportSysList(this.queryParams).then((response) => {
if (response.code == 200) {
this.postList = response.rows;
this.total = response.total;
this.loading = false;
} else {
this.postList = [];
this.total = 0;
this.loading = false;
}
});
},
//
cancel() {
this.open = false;
this.reset();
this.form.id = "";
},
//
reset() {
this.form = {
id: "",
deviceNum: "",
curTime: "",
tempInChillerWater: "",
tempOutChillerWater: "",
designFlow: "",
pressEvapSaturation: "",
tempEvapSaturation: "",
tempEvapApproaching: "",
tempInCoolingWater: "",
tempOutCoolingWater: "",
pressCondenserSaturation: "",
tempCondenserSaturation: "",
tempCondenserApproaching: "",
setChillerWater: "",
setLoad: "",
currentTotal: "",
inputPowerTotal: "",
ratioCompOne: "",
openExv: "",
runCompNum: "",
frequencyChiller: "",
pressOutChillerWater: "",
pressInChillerWater: "",
frequencyCooling: "",
pressOutCoolingWater: "",
pressInCoolingWater: "",
frequencyCoolingTower: "",
runCoolingTower: "",
pressConstantWaterTank: "",
tempOutdoor: "",
humidityOutdoor: "",
recorder: "",
remark: "",
ratioCompTwo: "",
ratioCompThree: "",
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
this.form = Object.assign({}, row);
this.open = true;
this.title = "修改主机运行记录";
},
/** 提交按钮 */
submitForm: function () {
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != undefined) {
reportSysEdit(this.form).then((response) => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
console.log("新增参数", this.form);
}
}
});
},
/** 导出按钮操作 */
handleExport() {
reportSysExport(this.queryParams).then((res) => {
console.log("导出返回", res);
//
// blob URL
const url = window.URL.createObjectURL(new Blob([res]));
// <a>hrefdownload
const link = document.createElement("a");
link.href = url;
link.setAttribute("download", "主机运行记录报表.xls"); //
//
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
// blob URL
window.URL.revokeObjectURL(url);
this.$message({
type: "success",
message: "导出成功!",
});
});
},
//
leadingPrint() {
this.dialogPrintVisible = true;
},
//
surePrint() {
const printHTML = document.querySelector("#report").innerHTML;
//
window.document.body.innerHTML = printHTML;
window.print(); // window
window.location.reload(); //
},
},
};
</script>
<style scoped lang="scss">
/* 媒体查询,适配大于2000px分辨率的大屏样式 - element样式 */
@media (max-width: 2000px) {
::v-deep .el-dialog {
width: 800px !important;
}
::v-deep .print-dialog .el-dialog {
width: 1200px !important;
}
::v-deep .el-dialog .el-form-item__label {
width: 150px !important;
}
::v-deep .el-dialog .el-form-item {
display: flex;
flex-direction: row;
align-items: center;
}
}
@media (min-width: 2000px) {
// ::v-deep .el-dialog {
// width: 8rem !important;
// }
// ::v-deep .el-dialog .el-form-item__label {
// width: 1.5rem !important;
// }
// ::v-deep .el-dialog .el-form-item {
// display: flex;
// flex-direction: row;
// align-items: center;
// }
}
</style>

4
src/views/centerairC/overview/index.vue

@ -115,7 +115,7 @@
</el-table-column>
<el-table-column prop="copData" label="EER"> </el-table-column>
</el-table>
<div class="page" >
<div class="page">
<el-pagination
background
style="width: 100%; height: 20%"
@ -991,7 +991,7 @@ export default {
align-items: center;
width: 16rem;
}
.page{
.page {
margin-top: 0.22rem;
}

31
src/views/centerairC/sysControl/index.vue

@ -86,6 +86,7 @@
<list-header
:deviceList="hostList"
:isNoShowHz="true"
:isNoShowlocalRemote="true"
@operationControl="hadleOperationConrol"
@upList="getOperationList"
></list-header>
@ -187,7 +188,8 @@ export default {
//
else if (
child.paramType === "2" &&
!child.name.includes("阀")
!child.name.includes("阀") &&
child.name.includes("启停")
) {
deviceItem.controlText =
Number(child.value) == 0 ? false : true;
@ -217,6 +219,15 @@ export default {
deviceItem.localRemote =
Number(child.value) == 0 ? "本地" : "远程";
}
// -
else if (
child.paramType === "40" &&
!child.name.includes("阀")
) {
deviceItem.frequencyAutotext =
Number(child.value) == 0 ? false : true;
deviceItem.frequencyAutotextId = child.id;
}
//
else if (
child.paramType === "3" &&
@ -258,24 +269,24 @@ export default {
}
//
if (
child.name.includes("关到位") &&
child.name.endsWith("关到位") &&
Number(child.value) == 0
) {
valveClosed = false;
} else if (
child.name.includes("关到位") &&
child.name.endsWith("关到位") &&
Number(child.value) == 1
) {
valveClosed = true;
}
//
if (
child.name.includes("开到位") &&
child.name.endsWith("开到位") &&
Number(child.value) == 0
) {
valveOpened = false;
} else if (
child.name.includes("开到位") &&
child.name.endsWith("开到位") &&
Number(child.value) == 1
) {
valveOpened = true;
@ -414,16 +425,6 @@ export default {
</script>
<style lang="scss" scoped>
/* 设备控制列表样式 */
.device-container {
display: flex;
flex-direction: column;
width: 100%;
background-color: #142c4e;
padding: 10px 10px 30px 10px;
border-radius: 10px;
margin-bottom: 20px;
}
/* 状态统计样式 */
.status-statistics {
margin-bottom: 25px;

159
src/views/centerairC/sysControl/listHeader.vue

@ -7,6 +7,7 @@
<div class="device-name">手动控制</div>
<div class="device-name" v-if="!isNoShowlocalRemote">本地远程状态</div>
<div class="device-name">故障报警</div>
<div class="device-name" v-if="!isNoShowHz">频率手自动切换</div>
<div class="device-name" v-if="!isNoShowHz">频率调节</div>
<div class="device-name" v-if="!isNoShowHz">频率反馈</div>
<div class="device-name">运行时间</div>
@ -55,6 +56,20 @@
{{ item.warnText }}
</div>
</div>
<!-- 频率-手自动切换 -->
<div class="device-name" v-if="!isNoShowHz">
<el-switch
style="display: block"
v-model="item.frequencyAutotext"
active-color="#13ce66"
inactive-color="#ff4949"
active-text="手动"
inactive-text="自动"
v-if="item.frequencySet !== null && item.frequencySet !== undefined"
@change="handleFrequencyAutomaticText(item)"
>
</el-switch>
</div>
<!-- 频率调节 -->
<div class="device-name" v-if="!isNoShowHz">
<el-input
@ -64,7 +79,7 @@
@keyup.enter.native="handleEnter(item, $event)"
@input="handleInput(item)"
@blur="handleBlur()"
:disabled="!item.automaticText"
:disabled="!item.frequencyAutotext"
></el-input>
<div class="device-name" v-else></div>
</div>
@ -108,7 +123,7 @@ export default {
// this.currentFocusIndex = "";
},
handleEnter(item, event) {
console.log("请求后端");
console.log("请求后端", item);
//
event.target.blur();
this.$confirm(
@ -121,7 +136,6 @@ export default {
}
)
.then(() => {
// operationControl
this.$emit("operationControl", item.frequencyId, item.frequencySet);
})
.catch(() => {
@ -189,116 +203,37 @@ export default {
console.log("不请求后台");
});
},
// -
handleFrequencyAutomaticText(item) {
this.$confirm(
`确定要切换"${item.name}"的频率手自动状态为:${
item.frequencyAutotext ? "手动" : "自动 吗?"
}`,
"提示",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}
)
.then(() => {
//
console.log("请求后台", item.frequencyAutotext);
let param = null;
if (item.frequencyAutotext) {
param = 1;
} else {
param = 0;
}
this.$emit("operationControl", item.frequencyAutotextId, param);
})
.catch(() => {
//
item.frequencyAutotext = !item.frequencyAutotext;
console.log("不请求后台");
});
},
},
};
</script>
<style lang="scss" scoped>
.device-li {
flex: 1;
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
padding: 12px 0;
color: #abcdfc;
border-bottom: 1px dashed #0349ac;
.device-name {
flex: 1;
white-space: nowrap;
font-size: 14px;
.el-switch {
width: 120px !important;
}
.run {
display: flex;
flex-direction: row;
align-items: center;
display: block;
}
.run::before {
content: "";
display: inline-block;
width: 10px;
height: 10px;
background-color: rgb(16, 231, 16);
border-radius: 50%;
margin-right: 5px;
}
.no-run {
display: flex;
flex-direction: row;
align-items: center;
display: block;
}
.no-run::before {
content: "";
display: inline-block;
width: 10px;
height: 10px;
background-color: rgb(180, 180, 180);
border-radius: 50%;
margin-right: 5px;
}
.el-input {
width: 100px;
}
.strong-electric {
background-color: rgba(59, 130, 246, 0.2);
color: #60a5fa;
padding: 5px 20px;
border-radius: 10px;
}
.auto-electric {
background-color: rgba(231, 144, 45, 0.2);
color: #e47f21;
padding: 5px 20px;
border-radius: 10px;
}
.good-status {
color: #4ade80;
}
.bad-status {
color: #f05348;
}
}
}
.device-li:nth-child(1) {
color: #9ca3af;
}
// 2000px
@media (min-width: 2000px) {
.device-li {
padding: 0.12rem 0 !important;
border-bottom: 0.01rem dashed #0349ac !important;
.device-name {
font-size: 0.14rem !important;
.el-switch {
width: 1.2rem !important;
}
.run::before {
width: 0.1rem !important;
height: 0.1rem !important;
margin-right: 0.05rem !important;
}
.no-run::before {
width: 0.1rem !important;
height: 0.1rem !important;
margin-right: 0.05rem !important;
}
.el-input {
width: 1rem !important;
}
.strong-electric {
padding: 0.05rem 0.2rem;
border-radius: 0.1rem !important;
}
.auto-electric {
padding: 0.05rem 0.2rem;
border-radius: 0.1rem !important;
}
}
}
}
</style>

107
src/views/centerairC/sysControl/vavleheader.vue

@ -125,111 +125,4 @@ export default {
</script>
<style lang="scss" scoped>
.device-li {
flex: 1;
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
padding: 12px 0;
color: #abcdfc;
border-bottom: 1px dashed #0349ac;
.device-name {
flex: 1;
white-space: nowrap;
font-size: 14px;
.el-switch {
width: 120px !important;
}
.run {
display: flex;
flex-direction: row;
align-items: center;
display: block;
}
.run::before {
content: "";
display: inline-block;
width: 10px;
height: 10px;
background-color: rgb(16, 231, 16);
border-radius: 50%;
margin-right: 5px;
}
.no-run {
display: flex;
flex-direction: row;
align-items: center;
display: block;
}
.no-run::before {
content: "";
display: inline-block;
width: 10px;
height: 10px;
background-color: rgb(180, 180, 180);
border-radius: 50%;
margin-right: 5px;
}
.el-input {
width: 100px;
}
.strong-electric {
background-color: rgba(59, 130, 246, 0.2);
color: #60a5fa;
padding: 5px 20px;
border-radius: 10px;
}
.auto-electric {
background-color: rgba(231, 144, 45, 0.2);
color: #e47f21;
padding: 5px 20px;
border-radius: 10px;
}
.good-status {
color: #4ade80;
}
.bad-status {
color: #f05348;
}
}
}
.device-li:nth-child(1) {
color: #9ca3af;
}
// 2000px
@media (min-width: 2000px) {
.device-li {
padding: 0.12rem 0 !important;
border-bottom: 0.01rem dashed #0349ac !important;
.device-name {
font-size: 0.14rem !important;
.el-switch {
width: 1.2rem !important;
}
.run::before {
width: 0.1rem !important;
height: 0.1rem !important;
margin-right: 0.05rem !important;
}
.no-run::before {
width: 0.1rem !important;
height: 0.1rem !important;
margin-right: 0.05rem !important;
}
.el-input {
width: 1rem !important;
}
.strong-electric {
padding: 0.05rem 0.2rem;
border-radius: 0.1rem !important;
}
.auto-electric {
padding: 0.05rem 0.2rem;
border-radius: 0.1rem !important;
}
}
}
}
</style>

48
src/views/centerairC/sysMonitor/components/hostChart.vue

@ -3,6 +3,7 @@
<div class="historyCharts" ref="chart_ref"></div>
</div>
</template>
<script>
import * as echarts from "echarts";
export default {
@ -40,6 +41,7 @@ export default {
const titleStr = data[1].titleStr;
// dataList
const dataList = data[3].dataList;
// dataList
dataList.forEach((item) => {
// name title
@ -55,15 +57,18 @@ export default {
let name3 = "";
let name4 = "";
let name5 = "";
data.forEach((item) => {
if (item.timeStr) {
this.bottomData = item.timeStr;
}
if (item.dataList) {
// name
const names = [];
// chartData
const chartData = [];
//
let loadDataIndex = -1;
for (let i = 0; i < item.dataList.length; i++) {
@ -77,10 +82,12 @@ export default {
break;
}
}
//
if (loadDataIndex !== -1) {
item.dataList.splice(loadDataIndex, 1);
}
//
item.dataList.slice(0, 4).forEach((val, index) => {
if (val.name) {
@ -88,11 +95,13 @@ export default {
names[index] = val.name;
}
});
// chartData this.chartDataX
this.chartData1 = chartData[0] || "";
this.chartData2 = chartData[1] || "";
this.chartData3 = chartData[2] || "";
this.chartData4 = chartData[3] || "";
// names
name1 = names[0] || "";
name2 = names[1] || "";
@ -100,11 +109,11 @@ export default {
name4 = names[3] || "";
}
});
console.log("this.chartData1", this.chartData1);
console.log("this.chartData2", this.chartData2);
console.log("this.chartData3", this.chartData3);
console.log("this.chartData4", this.chartData4);
console.log("this.chartData5", this.chartData5);
// console.log("this.chartData1", this.chartData1);
// console.log("this.chartData2", this.chartData2);
// console.log("this.chartData3", this.chartData3);
// console.log("this.chartData4", this.chartData4);
// console.log("this.chartData5", this.chartData5);
this.$nextTick(() => {
// y
var Min1 = 0,
@ -264,6 +273,7 @@ export default {
if (chartRef) {
//
this.chartInstance = echarts.init(this.$refs.chart_ref);
const titleFontSize = this.$refs.chart_ref.offsetWidth / 130;
this.option = {
tooltip: {
trigger: "axis",
@ -273,7 +283,7 @@ export default {
for (var i = 0, l = params.length; i < l; i++) {
var seriesName = params[i].seriesName;
var value = params[i].value;
console.log("打印颜色", params[i].color)
// console.log("", params[i].color)
var marker =
'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:' +
params[i].color +
@ -303,12 +313,16 @@ export default {
}
return res;
},
textStyle: {
fontSize: titleFontSize * 1.5,
},
},
legend: {
show: true,
top: 0,
textStyle: {
color: "white",
fontSize: titleFontSize * 1.5,
},
},
grid: {
@ -327,6 +341,9 @@ export default {
// interval: 0, //x
// rotate: 30, //x30
color: "rgba(255, 255, 255, 1)",
textStyle: {
fontSize: titleFontSize * 1.5,
},
},
axisTick: {
show: false, // 线
@ -354,13 +371,16 @@ export default {
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
fontSize: titleFontSize * 2,
},
miniInterval: 5,
type: "value",
// y
axisLabel: {
color: "rgba(255, 255, 255, 1)",
textStyle: {
fontSize: titleFontSize * 1.5,
},
},
// y
axisLine: {
@ -387,18 +407,17 @@ export default {
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
fontSize: titleFontSize * 1.5,
},
miniInterval: 5,
type: "value",
name: "负载", // y
// y
axisLabel: {
color: "#ffffff",
},
// y
axisLabel: {
color: "rgba(255, 255, 255, 1)",
textStyle: {
fontSize: titleFontSize * 1.5,
},
},
// y
axisLine: {
@ -503,9 +522,10 @@ export default {
},
};
</script>
<style lang="scss" scoped>
.historyCharts {
width: 100%;
height: 4rem;
height: 4.4rem;
}
</style>
</style>

8
src/views/centerairC/sysMonitor/components/loadData.vue

@ -6,9 +6,6 @@
<script>
import * as echarts from "echarts";
import { eventBus } from "@/utils/evenBus";
import { overView } from "@/api/bigScreen";
import { getDay, getMonth, getYear } from "@/utils/datetime";
export default {
props: {
hostData: {
@ -99,6 +96,7 @@ export default {
//
const dataArr = this.loadPercent; //
const dataX = 100;
const titleFontSize = this.$refs.sys_charts.offsetWidth / 20;
this.chartInstance = echarts.init(this.$refs.sys_charts);
this.option = {
backgroundStyle: {
@ -108,10 +106,10 @@ export default {
title: [
{
text: `${dataArr} %`,
bottom: "8%",
bottom: titleFontSize,
left: "center",
textStyle: {
fontSize: "16", //
fontSize: titleFontSize * 1.5, //
color: "#ffff",
fontWeight: 800,
},

1396
src/views/centerairC/sysMonitor/hostDetails.vue

File diff suppressed because it is too large Load Diff

1579
src/views/centerairC/sysMonitor/monitorCenter.vue

File diff suppressed because it is too large Load Diff

185
src/views/centerairC/sysMonitor/performance.vue

@ -9,6 +9,7 @@
<img
class="title-center"
src="../../../assets/images/title-center.png"
@click="goSys"
alt=""
/>
<img
@ -16,7 +17,7 @@
src="../../../assets/images/title-right.png"
alt=""
/>
<div class="sys-title">铭汉高效冷源站管理系统</div>
<div class="sys-title" @click="goSys">铭汉高效冷源站管理系统</div>
<!-- logo -->
<img src="../../../assets/images/logo-3.png" class="sys-logo" alt="" />
<div class="nowTime">{{ formattedDate }}</div>
@ -397,7 +398,7 @@ import {
import { alarmRecordList } from "@/api/alarm/alarmRecord";
import titleImg from "./components/titleImg.vue";
import { format } from "@/utils/datetime";
import PerformanceChart from './components/performanceChart.vue';
import PerformanceChart from "./components/performanceChart.vue";
export default {
name: "sysControl",
components: { titleImg, PerformanceChart },
@ -492,7 +493,7 @@ export default {
},
//
goSys() {
this.exitFullscreen();
// this.exitFullscreen();
this.$router.push("/");
},
//
@ -528,7 +529,7 @@ export default {
});
},
goWarning() {
this.exitFullscreen();
// this.exitFullscreen();
this.$router.push("/alarm/alarmRecord");
},
},
@ -557,11 +558,11 @@ export default {
}
.title-center {
width: 9.46rem;
height: 0.69rem;
height: 0.8rem;
}
.title-right {
width: 5.04rem;
height: 0.61rem;
height: 0.78rem;
}
.sys-title {
position: absolute;
@ -572,10 +573,11 @@ export default {
color: #ffffff;
font-weight: bold;
z-index: 100;
cursor: pointer;
}
.nowTime {
position: absolute;
top: 0.3rem;
top: 0.37rem;
right: 0.6rem;
font-size: 0.18rem;
color: #ffffff;
@ -601,11 +603,11 @@ export default {
}
.icon_warning {
position: absolute;
top: 0.33rem;
top: 0.39rem;
right: 4.4rem;
z-index: 10;
width: 0.3rem;
height: 0.27rem;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.25rem 0 0.27rem;
cursor: pointer;
/* 添加闪烁动画 */
@ -621,21 +623,21 @@ export default {
}
.icon_home {
position: absolute;
top: 0.33rem;
top: 0.39rem;
right: 4rem;
z-index: 10;
width: 0.3rem;
height: 0.27rem;
width: 0.35rem;
height: 0.32rem;
margin: 0 0.2rem 0 0.27rem;
cursor: pointer;
}
.back-icon {
position: absolute;
top: 0.33rem;
top: 0.39rem;
right: 3.7rem;
z-index: 10;
width: 0.3rem;
height: 0.27rem;
width: 0.35rem;
height: 0.32rem;
cursor: pointer;
}
}
@ -669,7 +671,7 @@ export default {
height: 2.6rem;
margin-bottom: 0.1rem;
}
.host-name{
.host-name {
position: absolute;
top: 0.8rem;
left: 1.6rem;
@ -714,153 +716,6 @@ export default {
flex-wrap: wrap;
align-items: flex-start;
justify-content: center;
.detail-data-li {
width: 80%;
margin-right: 0.1rem;
position: relative;
color: #89acc4;
font-family: Arial, sans-serif;
letter-spacing: 0.02rem;
font-size: 0.18rem;
position: relative;
margin-bottom: 0.08rem;
border-left: 0.01rem solid #217df5;
border-right: 0.01rem solid #217df5;
background-image: radial-gradient(
circle at left top,
#217df5 0.01rem,
transparent 0.01rem
),
radial-gradient(
circle at right top,
#217df5 0.01rem,
transparent 0.01rem
),
radial-gradient(
circle at left bottom,
#217df5 0.01rem,
transparent 0.01rem
),
radial-gradient(
circle at right bottom,
#217df5 0.01rem,
transparent 0.01rem
);
background-repeat: no-repeat;
background-position: left top, right top, left bottom, right bottom;
}
.detail-data-li::before,
.detail-data-li::after {
content: "";
position: absolute;
left: 0;
right: 0;
height: 0.01rem;
background-image: linear-gradient(
to right,
#217df5 0%,
rgba(41, 128, 185, 0) 50%,
#217df5 100%
) !important;
}
.year-data {
margin-top: 0.1rem;
}
.rightDot {
position: relative;
width: 100%;
height: 100%;
z-index: 999;
}
.leftDot {
position: relative;
width: 100%;
height: 100%;
padding: 0.04rem 0.1rem;
display: flex;
flex-direction: row;
justify-content: space-between;
.dotData {
font-weight: bold;
margin: 0 0.06rem;
color: #3b80ff;
display: flex;
align-items: center;
}
.dotUnit{
width: 0.55rem;
text-align: left;
display: flex;
align-items: center;
}
}
.rightDot::before {
content: "";
position: absolute;
top: -0.03rem;
right: -0.03rem;
width: 0.06rem;
height: 0.06rem;
background-color: #217df5;
box-shadow: 0 0 0.1rem 0.02rem rgba(33, 125, 245, 0.9);
background-image: radial-gradient(
circle at 30% 30%,
rgba(255, 255, 255, 0.8) 0%,
rgba(255, 255, 255, 0) 70%
);
border-radius: 50%;
}
.rightDot::after {
content: "";
position: absolute;
bottom: -0.03rem;
right: -0.03rem;
width: 0.06rem;
height: 0.06rem;
background-color: #217df5;
box-shadow: 0 0 0.1rem 0.02rem rgba(33, 125, 245, 0.9);
background-image: radial-gradient(
circle at 30% 30%,
rgba(255, 255, 255, 0.8) 0%,
rgba(255, 255, 255, 0) 70%
);
border-radius: 50%;
}
.leftDot::before {
content: "";
position: absolute;
top: -0.03rem;
left: -0.03rem;
width: 0.06rem;
height: 0.06rem;
background-color: #217df5;
border-radius: 50%;
box-shadow: 0 0 0.1rem 0.02rem rgba(33, 125, 245, 0.9);
background-image: radial-gradient(
circle at 30% 30%,
rgba(255, 255, 255, 0.8) 0%,
rgba(255, 255, 255, 0) 70%
);
}
.leftDot::after {
content: "";
position: absolute;
bottom: -0.03rem;
left: -0.03rem;
width: 0.06rem;
height: 0.06rem;
background-color: #217df5;
box-shadow: 0 0 0.1rem 0.02rem rgba(33, 125, 245, 0.9);
background-image: radial-gradient(
circle at 30% 30%,
rgba(255, 255, 255, 0.8) 0%,
rgba(255, 255, 255, 0) 70%
);
border-radius: 50%;
}
}
.line1 {
position: absolute;
@ -873,7 +728,7 @@ export default {
display: flex;
flex-direction: row;
justify-content: space-between;
height:3rem;
height: 3rem;
// background-color: #217df5;
}
}

430
src/views/centerairC/temHistoryQuery/index.vue

@ -0,0 +1,430 @@
<template>
<div class="app-container">
<div class="btn-condition">
<div class="condition-left" v-show="showSearch">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
>
<el-form-item label="日期" prop="msgCode">
<el-date-picker
style="width: auto"
v-model="monthValue"
type="month"
placeholder="选择月"
value-format="yyyy-MM"
>
</el-date-picker>
</el-form-item>
</el-form>
<div class="primary-btn">
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
</div>
<div class="warning-btn">
<el-button
type="warning"
icon="el-icon-download"
size="mini"
@click="handleExport"
>导出</el-button
>
</div>
<div class="cancel-btn">
<el-button
type="cancel"
icon="el-icon-refresh"
size="mini"
@click="resetQuery"
>重置</el-button
>
</div>
</div>
</div>
<div class="charts" ref="chart_ref"></div>
<el-table
v-loading="loading"
:data="postList"
stripe
:cell-style="tableRowStyle"
>
<el-table-column label="日期" align="center" prop="dateAndWeek" />
<el-table-column label="最高气温" align="center" prop="maxTemp" />
<el-table-column label="最低气温" align="center" prop="minTemp" />
<el-table-column label="天气" align="center" prop="weatherConditions" />
<el-table-column label="风向" align="center" prop="windDirection" />
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
import { weatherTempData } from "@/api/centerairC/temHistory";
import * as echarts from "echarts";
export default {
name: "temHistoryQuery",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
postList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
startTime: "",
endTime: "",
},
monthValue: "",
chartInstance: null,
option: {},
};
},
created() {
//
const currentDate = new Date();
//
const year = currentDate.getFullYear();
// 0 1
const month = String(currentDate.getMonth() + 1).padStart(2, "0");
// yyyy-MM
this.monthValue = `${year}-${month}`;
},
mounted() {
this.getList();
this.initChart();
window.addEventListener("resize", this.screenAdapter);
this.screenAdapter();
this.getChartData();
},
methods: {
tableRowStyle({ row, column, rowIndex, columnIndex }) {
//
if (columnIndex === 1) {
return "color: #fd1e00;!important;text-align:center";
}
if (columnIndex === 2) {
return "color: #3390ff;!important;text-align:center";
}
if (columnIndex === 4) {
return "color: #75d148;!important;text-align:center";
}
// return "text-align:center";
},
/** 查询报警编码列表 */
getList() {
this.loading = true;
this.queryParams.startTime = this.queryParams.endTime = this.monthValue;
console.log("参数", this.queryParams);
weatherTempData(this.queryParams).then((response) => {
this.postList = response.rows;
this.total = response.total;
this.loading = false;
});
},
getChartData() {
this.loading = true;
this.queryParams.pageNum = 0;
this.queryParams.startTime = this.queryParams.endTime = this.monthValue;
console.log("图表参数", this.queryParams);
weatherTempData(this.queryParams).then((response) => {
console.log("处理值然后渲染");
if (response.rows.length > 0) {
let data = response.rows;
let timeValue = [];
let hightValue = [];
let lowValue = [];
data.forEach((element) => {
timeValue.push(element.weatherDate);
hightValue.push(element.maxTemp);
lowValue.push(element.minTemp);
});
let adapterOption = {};
adapterOption = {
xAxis: {
data: timeValue,
},
yAxis: {
name: "℃",
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
},
series: [
{
data: hightValue,
//线
itemStyle: {
color: "rgb(18, 126, 226)", //线
},
lineStyle: {
color: "rgb(18, 126, 226)", //线
},
},
{
data: lowValue,
//线
itemStyle: {
color: "rgb(250, 169, 19)", //线
},
lineStyle: {
color: "rgb(250, 169, 19)", //线
},
},
],
};
//.chartInstanceoptiondataoption
this.chartInstance.setOption(adapterOption);
//resize
this.chartInstance.resize();
} else {
let adapterOption = {};
adapterOption = {
xAxis: {
data: [],
},
series: [
{
data: [],
},
{
data: [],
},
],
};
//.chartInstanceoptiondataoption
this.chartInstance.setOption(adapterOption);
//resize
this.chartInstance.resize();
}
});
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.getChartData();
},
/** 重置按钮操作 */
resetQuery() {
this.handleQuery();
},
/** 导出按钮操作 */
handleExport() {
this.queryParams.pageNum = 1;
this.queryParams.pageSize = 32;
this.queryParams.startTime = this.queryParams.endTime = this.monthValue;
console.log("参数", this.queryParams);
weatherTempData(this.queryParams).then((response) => {
if (response.code == 200) {
import("@/assets/excel/Export2Excel").then((excel) => {
var tHeader = ["日期", "最高气温", "最低气温", "天气", "风向"]; // excel
var filterVal = [
"dateAndWeek",
"maxTemp",
"minTemp",
"weatherConditions",
"windDirection",
];
const data = this.formatJson(filterVal, response.rows);
const autoWidth = true;
excel.export_json_to_excel({
header: tHeader, //
data, //
filename: "历史天气报表", //
autoWidth: true, //
});
this.$message({
type: "success",
message: "导出成功!",
});
});
} else {
this.$message.error("导出失败!");
}
});
},
//,
formatJson(filterVal, jsonData) {
return jsonData.map((v) =>
filterVal.map((j) => {
if (j === "installDate") {
return format(v[j]);
} else {
return v[j];
}
})
);
},
// 线+ + 线
screenAdapter() {
//,2.6 mes_ref
const titleFontSize = this.$refs.chart_ref.offsetWidth / 130;
//optionoption
const adapterOption = {};
//.chartInstanceoptiondataoption
this.chartInstance.setOption(adapterOption);
//resize
this.chartInstance.resize();
},
//chartInstance
initChart() {
this.chartInstance = echarts.init(this.$refs.chart_ref);
const titleFontSize = this.$refs.chart_ref.offsetWidth / 100;
this.option = {
tooltip: {
// axis x
trigger: "axis",
textStyle: {
//
fontSize: titleFontSize,
},
},
legend: {
show: false,
// textStyle: {
// //
// fontSize: 14
// }
},
grid: {
top: "10%",
left: "4%",
right: "6%",
bottom: "3%",
containLabel: true,
},
xAxis: {
type: "category",
//true
boundaryGap: true,
// x
axisLabel: {
// interval: 0, //x
// rotate: 30, //x30
color: "rgba(255, 255, 255, 1)",
fontSize: titleFontSize, //x
},
axisTick: {
show: false, // 线
},
// x
axisLine: {
show: true,
lineStyle: {
color: "#365576",
},
},
splitLine: {
lineStyle: {
color: "#e2e6f0",
},
}, //x线
},
yAxis: {
min: 0,
// max:20,
// name: "kwh", // y
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12, //y
},
miniInterval: 5,
type: "value",
// y
axisLabel: {
color: "rgba(255, 255, 255, 1)",
fontSize: titleFontSize, //x
},
// y
axisLine: {
show: true,
lineStyle: {
color: "#365576", // y 线
},
},
//y线
// splitNumber: 10,
// y线
splitLine: {
lineStyle: {
color: "#1a3d62", // 线
type: "dashed", // 线线
},
},
},
series: [
{
type: "line",
//
symbolSize: titleFontSize * 0.5,
lineStyle: {
// 线
width: titleFontSize * 0.1,
},
symbol: "circle",
name: "最高气温",
},
{
type: "line",
//
symbolSize: titleFontSize * 0.5,
lineStyle: {
// 线
width: titleFontSize * 0.1,
},
symbol: "circle",
name: "最低气温",
},
],
};
//
this.chartInstance.setOption(this.option, true);
},
},
};
</script>
<style lang="scss" scoped>
.charts {
width: 100%;
height: 300px;
margin-bottom: 0.1rem;
}
// 2000px
@media (min-width: 2000px) {
.charts {
height: 3rem !important;
}
}
</style>

2
src/views/centerairC/timeSwitch/index.vue

@ -102,7 +102,7 @@ export default {
// console.log("child.pointName", child.pointName);
if (child.pointName) {
// -
if (child.pointName.includes(`开_`)) {
if (child.pointName.includes(`开_`)) {
// console.log("-·························");
delayItem.delayOpenHour = child.curValue;
delayItem.delayOpenHourId = child.cpmId;

228
src/views/components/viewColdSys.vue

@ -9,6 +9,12 @@
import * as echarts from "echarts";
import { viewMainParams } from "@/api/index";
export default {
props: {
subData: {
type: Array,
required: true,
},
},
data() {
return {
chartInstance: null,
@ -36,11 +42,24 @@ export default {
},
};
},
watch: {
subData: {
immediate: true, //
handler(newVal) {
// console.log("", this.subData);
if (Object.keys(newVal).length > 0) {
console.log("newval", newVal);
this.$nextTick(() => {
this.echartsData();
});
}
},
},
},
mounted() {
this.initChart();
this.screenAdapter();
window.addEventListener("resize", this.screenAdapter);
this.getChartsData();
},
destroyed() {
//mounted
@ -441,118 +460,114 @@ export default {
this.chartInstance.resize();
},
//
getChartsData() {
viewMainParams().then((res) => {
console.log("系统参数返回", res);
console.log("冷源监控返回", res.rows[0]);
if (res.code == 200) {
this.useForm.maxData = 10;
this.useForm.useData = res.rows[0].values[0].value;
let that = this;
// 使
const axisLineColor = this.getAxisLineColor(
this.useForm.useData,
this.useForm.maxData
);
const titleFontSize = this.$refs.sys_charts.offsetWidth / 30;
const adapterOption = {
series: [
{
name: "内部动态阴影",
axisLine: {
lineStyle: {
color: axisLineColor,
//
// width: 80,
},
echartsData() {
if (this.subData.length > 0) {
this.useForm.maxData = 10;
this.useForm.useData = this.subData[0].value;
let that = this;
// 使
const axisLineColor = this.getAxisLineColor(
this.useForm.useData,
this.useForm.maxData
);
const titleFontSize = this.$refs.sys_charts.offsetWidth / 20;
const adapterOption = {
series: [
{
name: "内部动态阴影",
axisLine: {
lineStyle: {
color: axisLineColor,
//
// width: 80,
},
},
{
name: "内部大边框",
min: 0,
max: this.useForm.maxData,
},
{
name: "指针上的圆",
data: [
{
value: 5,
},
{
name: "内部大边框",
min: 0,
max: this.useForm.maxData,
},
{
name: "指针上的圆",
data: [
{
value: 5,
},
],
},
{
name: "指针上的渐变圆",
label: {
show: true,
position: "center", //
offset: [0, -titleFontSize * 0.6], // 10
formatter: function () {
// HTML 使 rich
return `{line|${that.useForm.useData}}`;
},
rich: {
line: {
color: "#fff", //
fontSize: titleFontSize, //
lineHeight: 5, //
},
],
},
},
{
name: "指针上的渐变圆",
label: {
show: true,
position: "center", //
offset: [0, -titleFontSize * 0.6], // 10
formatter: function () {
// HTML 使 rich
return `{line|${that.useForm.useData}}`;
},
rich: {
line: {
color: "#fff", //
fontSize: titleFontSize, //
lineHeight: 5, //
data: [
{
value: 0,
itemStyle: {
//
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgb(4,112,212)", //
},
{
offset: 0.3,
color: "rgba(0, 46, 93)", //
},
],
global: false, // false
},
},
},
data: [
{
value: 0,
itemStyle: {
//
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgb(4,112,212)", //
},
{
offset: 0.3,
color: "rgba(0, 46, 93)", //
},
],
global: false, // false
},
},
},
],
},
{
//
name: this.energyCostText,
max: this.useForm.maxData, //
axisLabel: {
formatter: (value) => {
// 0
if (value === 0 || value == this.useForm.maxData) {
// 100
return value;
}
return "";
},
],
},
{
//
name: this.energyCostText,
max: this.useForm.maxData, //
axisLabel: {
formatter: (value) => {
// 0
if (value === 0 || value == this.useForm.maxData) {
// 100
return value;
}
return "";
},
data: [
{
name: this.dateUse,
value: this.useForm.useData,
},
],
},
],
};
this.chartInstance.setOption(adapterOption);
//resize
this.chartInstance.resize();
}
});
data: [
{
name: this.dateUse,
value: this.useForm.useData,
},
],
},
],
};
this.chartInstance.setOption(adapterOption);
//resize
this.chartInstance.resize();
}
},
},
};
@ -569,7 +584,7 @@ export default {
.sys_charts {
width: 100%;
height: 1.6rem;
height: 150px;
}
.eer {
font-size: 18px;
@ -578,6 +593,9 @@ export default {
}
// 2000px
@media (min-width: 2000px) {
.sys_charts {
height: 1.5rem !important;
}
.eer {
font-size: 0.18rem !important;
margin-top: 0.25rem !important;

10
src/views/components/viewEnergy.vue

@ -81,16 +81,12 @@ export default {
);
console.log("当前要渲染的数据对象", chartsObj);
console.log("当前要渲染的颜色对象", colorObj);
const titleFontSize = this.$refs.chart_ref.offsetWidth / 100;
const titleFontSize = this.$refs.chart_ref.offsetWidth / 50;
let adapterOption = {};
// 线
adapterOption = {
tooltip: {
trigger: "axis",
textStyle: {
//
fontSize: titleFontSize,
},
// tooltip
formatter: function (params) {
var res = params[0].name + "<br/>";
@ -143,13 +139,9 @@ export default {
{
data: chartsObj.data,
name: event,
//
symbolSize: titleFontSize * 0.5,
//线
itemStyle: {
color: colorObj.color, //线
// 线
width: titleFontSize * 0.1,
},
lineStyle: {
color: colorObj.color, //线

1091
src/views/comprehensiveEnergy/hotPumpLog/index.vue

File diff suppressed because it is too large Load Diff

379
src/views/comprehensiveEnergy/meterRecord/index.vue

@ -0,0 +1,379 @@
<template>
<div class="app-container">
<div class="btn-condition">
<div class="condition-left" v-show="showSearch">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
>
<el-form-item label="日期" prop="msgCode">
<el-date-picker
style="width: auto"
v-model="dayValue"
type="date"
placeholder="选择日"
value-format="yyyy-MM-dd"
>
</el-date-picker>
</el-form-item>
</el-form>
<div class="primary-btn">
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>搜索</el-button
>
</div>
<div class="warning-btn">
<el-button
type="warning"
icon="el-icon-download"
size="mini"
@click="handleExport"
>导出</el-button
>
</div>
</div>
</div>
<div class="meter-Context">
<div class="meter-li">最低气温:{{ lowValue }}</div>
<div class="meter-li">最高气温:{{ heightValue }}</div>
<!-- <div class="meter-li">住房量:108</div> -->
</div>
<el-table
:data="tableData"
:span-method="arraySpanMethod"
:cell-style="tableRowStyle"
border
style="width: 100%"
v-loading="loading"
>
<el-table-column prop="mtType" label="名称" width="180">
<template #default="{ row, $index }">
<!-- 当是第 xx 行时显示 位置 的值 -->
<span
v-if="
$index === 8 ||
$index === 13 ||
$index === 18 ||
$index === 21 ||
$index === 23 ||
$index === 25 ||
$index === 26
"
>{{ row.location }}</span
>
<!-- 否则显示名称的值 -->
<span v-else>{{ row.mtType }}</span>
</template>
</el-table-column>
<el-table-column prop="location" label="位置"> </el-table-column>
<el-table-column prop="mtNum" sortable label="编号"> </el-table-column>
<el-table-column prop="yesterdayReading" sortable label="昨日读数">
</el-table-column>
<el-table-column prop="todayReading" sortable label="今日读数">
</el-table-column>
<el-table-column prop="mtRatio" sortable label="倍率"> </el-table-column>
<el-table-column prop="total" sortable label="合计">
<template #default="{ row, $index }">
<!-- 当是第 27 行时显示 amount7费用 的值 -->
<span v-if="$index === 26">{{ row.cost }}</span>
<!-- 否则显示合计的值 -->
<span v-else>{{ row.total }}</span>
</template>
</el-table-column>
<el-table-column prop="unitPrice" sortable label="单价">
</el-table-column>
<el-table-column prop="cost" sortable label="费用"> </el-table-column>
</el-table>
<el-table
:data="tableData2"
:span-method="objectSpanMethod"
border
style="width: 100%; margin-top: 20px"
>
<el-table-column prop="mtType" label="" width="180"> </el-table-column>
<el-table-column prop="location" label="分项"> </el-table-column>
<el-table-column prop="yesterdayReading" label="昨日流量">
</el-table-column>
<el-table-column prop="todayReading" label="今日流量"> </el-table-column>
<el-table-column prop="total" label="用量"> </el-table-column>
<el-table-column prop="remake" label="备注"> </el-table-column>
</el-table>
</div>
</template>
<script>
import { weatherTempData } from "@/api/centerairC/temHistory";
import {
meterReadingsList,
meterReadingsExport,
} from "@/api/comprehensiveEnergy/meterRecord";
export default {
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
postList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 0,
pageSize: 10,
startTime: "",
endTime: "",
},
dayValue: "",
monthValue: "",
lowValue: "", //
heightValue: "", //
tableData: [],
tableData2: [],
};
},
created() {
//
const currentDate = new Date();
//
const year = currentDate.getFullYear();
// 0 1
const month = String(currentDate.getMonth() + 1).padStart(2, "0");
//
const day = String(currentDate.getDate()).padStart(2, "0");
// yyyy-MM-dd
this.dayValue = `${year}-${month}-${day}`;
this.monthValue = `${year}-${month}`;
},
mounted() {
this.getList();
},
methods: {
tableRowStyle({ row, column, rowIndex, columnIndex }) {
//
// if (columnIndex === 1) {
// return "color: #fd1e00;!important;text-align:center";
// }
// if (columnIndex === 2) {
// return "color: #3390ff;!important;text-align:center";
// }
if (
rowIndex === 8 ||
rowIndex === 13 ||
rowIndex === 18 ||
rowIndex === 21 ||
rowIndex === 23 ||
rowIndex === 25 ||
rowIndex === 26
) {
return "color: #75d148;!important;font-weight: bold;background-color: rgba(0, 71, 125, 0.4)";
}
},
// 1
arraySpanMethod({ row, column, rowIndex, columnIndex }) {
// console.log("", row, column, rowIndex, columnIndex);
// // rowIndexx columnIndexy
// // rowIndex % 2 === 0
// if (rowIndex % 2 === 0) {
// // 0
// if (columnIndex === 0) {
// //
// return [1, 2];
// } else if (columnIndex === 1) {
// // [0, 0]
// return [0, 0];
// }
// }
if (
rowIndex === 8 ||
rowIndex === 13 ||
rowIndex === 18 ||
rowIndex === 21 ||
rowIndex === 23 ||
rowIndex === 25
) {
if (columnIndex === 0) {
// rowIndex 8 columnIndex 0 1 6
return [1, 6];
} else if (columnIndex < 6) {
// rowIndex 8 columnIndex 6
return [0, 0];
}
}
if (rowIndex === 26) {
if (columnIndex < 6) {
if (columnIndex === 0) {
//
return [1, 6];
} else {
//
return [0, 0];
}
} else if (columnIndex >= 6) {
if (columnIndex === 6) {
//
return [1, 3];
} else {
//
return [0, 0];
}
}
}
//
return [1, 1];
},
// 2
objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
if (rowIndex === 0) {
return {
rowspan: 4,
colspan: 1,
};
} else {
return {
rowspan: 0,
colspan: 0,
};
}
}
},
/** 查询表格数据 */
getList() {
this.loading = true;
if (!this.dayValue) {
this.$modal.msgWarning("请选择日期!");
return;
}
let data = {
todayTimestamp: `${this.dayValue} 00:00:00`,
};
meterReadingsList(data).then((res) => {
console.log("列表返回", res);
if (res.code == 200 && res.rows) {
this.tableData = res.rows.slice(0, 27);
this.tableData2 = res.rows.slice(27, 31);
this.loading = false;
} else {
this.tableData = [];
this.tableData2 = [];
this.loading = false;
}
});
//
this.getTemValue();
},
getTemValue() {
if (this.dayValue) {
//
const parts = this.dayValue.split("-");
this.monthValue = `${parts[0]}-${parts[1]}`;
}
this.queryParams.startTime = this.queryParams.endTime = this.monthValue;
console.log("参数", this.queryParams);
weatherTempData(this.queryParams).then((response) => {
let data = response.rows;
// console.log("this.dayValue", this.dayValue);
if (data && data.length > 0) {
data.forEach((item) => {
if (item.dateAndWeek) {
let objectDate = item.dateAndWeek.split(" ")[0];
// console.log(" objectDate", objectDate);
if (objectDate == this.dayValue) {
this.lowValue = item.minTemp;
this.heightValue = item.maxTemp;
console.log("最低气温", this.lowValue);
console.log("最高气温", this.heightValue);
}
}
});
}
});
},
/** 搜索按钮操作 */
handleQuery() {
this.getList();
},
/** 导出按钮操作 */
handleExport() {
let data = {
todayTimestamp: `${this.dayValue} 00:00:00`,
};
console.log("导出数据参数", data);
meterReadingsExport(data).then((res) => {
console.log("导出返回", res);
if (res) {
//
// blob URL
const url = window.URL.createObjectURL(new Blob([res]));
// <a>hrefdownload
const link = document.createElement("a");
link.href = url;
link.setAttribute("download", "水电表抄表记录.xls"); //
//
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
// blob URL
window.URL.revokeObjectURL(url);
this.$message({
type: "success",
message: "导出成功!",
});
} else {
this.$message.error("导出失败!");
}
});
// .catch((err) => {
// this.$message.error('!');
// })
},
},
};
</script>
<style scoped>
.app-container >>> .el-table th.el-table__cell.is-leaf,
.app-container >>> .el-table td.el-table__cell {
border-bottom: 1px solid #000000 !important;
}
.app-container >>> .el-table--border .el-table__cell {
border-right: 1px solid #000000 !important;
}
</style>
<style lang="scss" scoped>
.meter-Context {
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
border: 1px solid #000000 !important;
padding: 0 30px;
.meter-li {
line-height: 23px;
padding: 10px 0;
height: 45px;
color: #ffffff;
font-size: 14px;
margin-right: 30px;
}
}
</style>

777
src/views/comprehensiveEnergy/systemEnergy/index.vue

@ -0,0 +1,777 @@
<template>
<div class="main-body">
<div class="irregular-border">
<div class="main-content">
<div class="condition">
<div class="condition-left">
<div class="time-label">时间类型:</div>
<el-radio-group
v-model="dateType"
style="margin-right: 0.24rem"
@change="updateDateType"
>
<el-radio label="hour">小时</el-radio>
<el-radio label="day"></el-radio>
<el-radio label="month"></el-radio>
<el-radio label="year"></el-radio>
</el-radio-group>
<el-date-picker
v-model="timeDate"
:default-time="['00:00:00', '23:59:59']"
type="datetimerange"
range-separator="至"
v-if="dateType == 'hour'"
placeholder="选择日期"
start-placeholder="开始日期"
end-placeholder="结束日期"
>
</el-date-picker>
<el-date-picker
v-model="dayDate"
type="daterange"
v-if="dateType == 'day'"
:key="this.dateType"
range-separator="至"
value-format="yyyy-MM-dd"
start-placeholder="开始日期"
end-placeholder="结束日期"
@change="dateChange"
>
</el-date-picker>
<el-date-picker
v-model="monthDate"
type="monthrange"
v-if="dateType == 'month'"
:key="this.dateType"
range-separator="至"
start-placeholder="开始月份"
end-placeholder="结束月份"
value-format="yyyy-MM"
@change="dateChange"
>
</el-date-picker>
<div
class="years-div"
v-if="dateType == 'year'"
:key="this.dateType"
>
<el-date-picker
v-model="startYear"
type="year"
placeholder="选择开始年份"
style="width: 180px"
value-format="yyyy"
>
</el-date-picker>
<div class="years-word"></div>
<el-date-picker
v-model="endYear"
type="year"
placeholder="选择结束年份"
style="width: 180px"
value-format="yyyy"
>
</el-date-picker>
</div>
<div class="success-btn" style="margin-left: 0.24rem">
<el-button type="success" @click="findData">查询</el-button>
</div>
<div class="warning-btn">
<el-button type="warning" @click="goExport()">导出</el-button>
</div>
</div>
</div>
<div class="choice">
<div
class="mr20"
v-for="(item, index) in timeData2"
:key="index"
@click="handleEnter(index, $event)"
:class="{ timeStyle: currentIndex == index }"
>
{{ item.title }}
</div>
</div>
<div class="charts" ref="chart_ref"></div>
<el-table :data="tableData" stripe>
<el-table-column label="时间" align="center" prop="time" />
<el-table-column
label="总用电量(kwh)"
align="center"
prop="electValue"
/>
<el-table-column
label="总产冷量(kw)"
align="center"
prop="coldValue"
/>
<el-table-column
label="总热水补水量(t)"
align="center"
prop="hotValue"
/>
<el-table-column
label="总蒸汽流量(t)"
align="center"
prop="steamValue"
/>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getTableData"
/>
</div>
</div>
</div>
</template>
<script>
import { format2 } from "@/utils/datetime";
import * as echarts from "echarts";
import { compreReport } from "@/api/comprehensiveEnergy/systemEnergy";
export default {
data() {
return {
listLoading: false,
dateType: "hour", //
timeDate: [], //
dayDate: [], //
monthDate: [], //
startYear: "", //
endYear: "", //
startTime: "", //
endTime: "", //
//
total: 0,
//
tableData: [],
exportData: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
startTime: "",
endTime: "",
},
brokenInstanc: null,
brokenOption: {},
timeData2: [
{ title: "总用电量" },
{ title: "总产冷量" },
{ title: "总热水补水量" },
{ title: "总蒸汽流量" },
],
currentIndex: 0,
brokenData1: [],
brokenData2: [],
brokenData3: [],
brokenData4: [],
brokenTime: [],
useWater: 0,
useWaterRadio: 0,
useElect: 0,
useElectRadio: 0,
useUnit: 0,
useUnitRadio: 0,
};
},
mounted() {
this.initializeTimeDate();
this.getTableData();
this.initChart();
window.addEventListener("resize", this.screenAdapter);
this.screenAdapter();
},
destroyed() {
//
window.removeEventListener("resize", this.screenAdapter);
},
methods: {
//
initializeTimeDate() {
const start = new Date(new Date().setHours(0, 0, 0, 0));
const end = new Date(new Date().setHours(23, 59, 59, 59));
this.timeDate = [format2(start), format2(end)]; //
this.titleDate = format2(start) + "至" + format2(end);
},
//
updateDateType() {
// this.dateType = this.radio;
console.log(this.dateType);
(this.timeDate = []), //
(this.dayDate = []), //
(this.monthDate = []), //
(this.startYear = ""), //
(this.endYear = ""); //
},
//
dateChange() {
// console.log("", this.timeform.time1);
if (!this.dayDate) {
this.$nextTick(() => {
this.dayDate = [];
});
}
if (!this.monthDate) {
this.$nextTick(() => {
this.monthDate = [];
});
}
},
//
findData() {
console.log("this.dateType", this.dateType);
console.log("this.timeDate", this.timeDate);
switch (this.dateType) {
case "hour":
if (!this.timeDate) {
this.showMessage("请选择时间!", "warning");
} else {
this.titleDate =
format2(this.timeDate[0]) + "至" + format2(this.timeDate[1]);
this.getTableData();
}
break;
case "day":
if (this.dayDate.length === 0) {
this.showMessage("请选择时间!", "warning");
} else {
const newLength =
new Date(this.dayDate[1]).getTime() -
new Date(this.dayDate[0]).getTime();
const dayDiff = Math.floor(newLength / (1000 * 60 * 60 * 24));
if (dayDiff > 31) {
this.showMessage(
"最多只能选择30天区间,请重新选择再查询!",
"warning"
);
} else {
this.titleDate = this.dayDate[0] + "至" + this.dayDate[1];
this.getTableData();
}
}
break;
case "month":
if (this.monthDate.length === 0) {
this.showMessage("请选择时间!", "warning");
} else {
const [start, end] = this.monthDate;
const startDate = new Date(start);
const endDate = new Date(end);
const startYear = startDate.getFullYear();
const startMonth = startDate.getMonth();
const endYear = endDate.getFullYear();
const endMonth = endDate.getMonth();
const monthDiff =
(endYear - startYear) * 12 + (endMonth - startMonth);
if (monthDiff > 12) {
this.showMessage(
"最多只能选择12个月区间,请重新选择再查询!",
"warning"
);
} else {
this.titleDate = this.monthDate[0] + "至" + this.monthDate[1];
this.getTableData();
}
}
break;
case "year":
if (!this.startYear || !this.endYear) {
this.showMessage("请选择全年份区间!", "warning");
} else if (this.startYear > this.endYear) {
this.showMessage("结束年份要大于开始年份!", "warning");
} else {
this.titleDate = this.startYear + "至" + this.endYear;
this.getTableData();
}
break;
default:
break;
}
},
//
showMessage(message, type) {
this.$message({
message: message,
type: type,
});
},
handleEnter(index) {
this.currentIndex = index;
this.renderingBroken();
},
//
getTableData() {
if (this.dateType == "hour") {
this.startTime = format2(this.timeDate[0]);
this.endTime = format2(this.timeDate[1]);
} else if (this.dateType == "day") {
this.startTime = this.dayDate.length > 0 ? this.dayDate[0] : "";
this.endTime = this.dayDate.length > 0 ? this.dayDate[1] : "";
} else if (this.dateType == "month") {
this.startTime = this.monthDate.length > 0 ? this.monthDate[0] : "";
this.endTime = this.monthDate.length > 0 ? this.monthDate[1] : "";
} else if (this.dateType == "year") {
(this.startTime = this.startYear), (this.endTime = this.endYear);
}
let data = {
timeType: this.dateType,
startTime: this.startTime,
endTime: this.endTime,
pageNum: this.queryParams.pageNum,
pageSize: this.queryParams.pageSize,
};
console.log("查询数据参数", data);
this.listLoading = true;
compreReport(data).then((res) => {
console.log("表格返回的数据", res);
if (res.code == 200 && res.rows.length > 0) {
this.tableData = res.rows;
this.total = res.total;
} else {
this.tableData = [];
this.total = 0;
}
this.getChartData();
});
// Just to simulate the time of the request
setTimeout(() => {
this.listLoading = false;
}, 1.0 * 1000);
},
//线
getChartData() {
if ((this.total == 10)) {
//
console.log("不用请求");
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenData4 = [];
this.brokenTime = [];
if (this.tableData.length > 0) {
this.exportData = this.tableData;
this.tableData.forEach((item) => {
this.brokenData1.push(item.electValue);
this.brokenData2.push(item.coldValue);
this.brokenData3.push(item.hotValue);
this.brokenData4.push(item.steamValue);
this.brokenTime.push(item.time);
});
this.renderingBroken();
} else {
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenData4 = [];
this.brokenTime = [];
}
this.renderingBroken();
} else {
console.log("图表参数", this.queryParams);
if (this.dateType == "hour") {
this.startTime = format2(this.timeDate[0]);
this.endTime = format2(this.timeDate[1]);
} else if (this.dateType == "day") {
this.startTime = this.dayDate.length > 0 ? this.dayDate[0] : "";
this.endTime = this.dayDate.length > 0 ? this.dayDate[1] : "";
} else if (this.dateType == "month") {
this.startTime = this.monthDate.length > 0 ? this.monthDate[0] : "";
this.endTime = this.monthDate.length > 0 ? this.monthDate[1] : "";
} else if (this.dateType == "year") {
(this.startTime = this.startYear), (this.endTime = this.endYear);
}
let data = {
timeType: this.dateType,
startTime: this.startTime,
endTime: this.endTime,
pageNum: 1,
pageSize: this.total,
};
compreReport(data).then((res) => {
console.log("图表返回的数据", res);
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenData4 = [];
this.brokenTime = [];
if (res.code == 200 && res.rows.length > 0) {
this.exportData = res.rows;
res.rows.forEach((item) => {
this.brokenData1.push(item.electValue);
this.brokenData2.push(item.coldValue);
this.brokenData3.push(item.hotValue);
this.brokenData4.push(item.steamValue);
this.brokenTime.push(item.time);
});
this.renderingBroken();
} else {
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenData4 = [];
this.brokenTime = [];
}
this.renderingBroken();
});
}
},
renderingBroken() {
if (this.currentIndex === 0) {
this.brokenOption.yAxis.name = "kwh";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData1;
this.brokenOption.series[0].itemStyle.color = "#d48e17";
this.brokenOption.series[0].areaStyle.color.colorStops = [
{
offset: 0,
color: "rgba(212, 142, 23, 0.3)", // 0%
},
{
offset: 0.8,
color: "rgba(212, 142, 23,0)", // 100%
},
];
} else if (this.currentIndex === 1) {
this.brokenOption.yAxis.name = "kw";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData2;
this.brokenOption.series[0].itemStyle.color = "#1ab395";
this.brokenOption.series[0].areaStyle.color.colorStops = [
{
offset: 0,
color: "rgba(26, 179, 149, 0.3)", // 0%
},
{
offset: 0.8,
color: "rgba(26, 179, 149,0)", // 100%
},
];
} else if (this.currentIndex === 2) {
this.brokenOption.yAxis.name = "t";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData3;
this.brokenOption.series[0].itemStyle.color = "#1f8dee";
this.brokenOption.series[0].areaStyle.color.colorStops = [
{
offset: 0,
color: "rgba(31, 141, 238, 0.3)", // 0%
},
{
offset: 0.8,
color: "rgba(31, 141, 238,0)", // 100%
},
];
} else if (this.currentIndex === 3) {
this.brokenOption.yAxis.name = "t";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData4;
this.brokenOption.series[0].itemStyle.color = "#f1f524";
this.brokenOption.series[0].areaStyle.color.colorStops = [
{
offset: 0,
color: "rgba(241, 245, 36, 0.3)", // 0%
},
{
offset: 0.8,
color: "rgba(241, 245, 36,0)", // 100%
},
];
}
//
const currentIndex = this.currentIndex;
// tooltip
this.brokenOption.tooltip = {
trigger: "axis",
formatter: function (params) {
//
const data = params[0];
const month = data.name;
const value = data.value;
//
if (currentIndex === 0) {
return `${month}<br/>总用电量: ${value}`;
} else if (currentIndex === 1) {
return `${month}<br/>总产冷量: ${value} 千瓦`;
} else if (currentIndex === 2) {
return `${month}<br/>总热水补水量: ${value}`;
} else if (currentIndex === 3) {
return `${month}<br/>总蒸汽量: ${value}`;
}
},
};
this.brokenOption.xAxis.data = this.brokenTime;
this.brokenInstanc.setOption(this.brokenOption);
},
//
goExport() {
if (this.exportData) {
import("@/assets/excel/Export2Excel").then((excel) => {
// excel
var tHeader = [
"时间",
"总用电量(kwh)",
"总产冷量(kw)",
"总热水补水量(t)",
"总蒸汽流量(t)",
]; // excel
var filterVal = [
"time",
"electValue",
"coldValue",
"hotValue",
"steamValue",
];
const data = this.formatJson(filterVal, this.exportData);
const autoWidth = true;
excel.export_json_to_excel({
header: tHeader, //
data, //
filename: "系统能耗报表", //
autoWidth: true, //
});
});
this.$message({
type: "success",
message: "导出成功!",
});
} else {
this.$message.error("导出失败!");
}
},
//,
formatJson(filterVal, jsonData) {
return jsonData.map((v) =>
filterVal.map((j) => {
if (j === "perWater") {
return (v[j] * 1000).toFixed(1);
} else {
return v[j];
}
})
);
},
// 线+ + 线
screenAdapter() {
//,2.6 mes_ref
const titleFontSize = this.$refs.chart_ref.offsetWidth / 130;
//optionoption
const adapterOption = {};
//.chartInstanceoptiondataoption
this.brokenInstanc.setOption(adapterOption);
//resize
this.brokenInstanc.resize();
},
//chartInstance
initChart() {
this.brokenInstanc = echarts.init(this.$refs.chart_ref);
this.brokenOption = {
tooltip: {
trigger: "axis",
},
legend: {
show: false,
selectedMode: false, //
icon: "cricle", //
//
textStyle: {
color: "#ffff",
fontSize: 16, //
},
// left: "73%",
left: "66%",
top: "0",
//
itemGap: 5,
itemWidth: 10,
itemHeight: 5,
},
grid: {
top: "10%",
left: "3%",
right: "4%",
bottom: "5%",
containLabel: true,
},
xAxis: {
type: "category",
//true
boundaryGap: true,
// x
axisLabel: {
// interval: 0, //x
// rotate: 30, //x30
color: "rgba(255, 255, 255, 1)",
fontSize: 14, //
},
axisTick: {
show: false, // 线
},
// x
axisLine: {
show: true,
lineStyle: {
color: "#365576",
},
},
splitLine: {
lineStyle: {
color: "#e2e6f0",
},
}, //x线
data: this.brokenTime,
},
yAxis: {
min: 0,
// max:20,
// // // min:'dataMin',
// // // max:'dataMax',
// name: "kwh", // y
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
miniInterval: 5,
type: "value",
// y
axisLabel: {
color: "rgba(255, 255, 255, 1)",
},
// y
axisLine: {
show: true,
lineStyle: {
color: "#365576", // y 线
},
fontSize: 14, //
},
//y线
// splitNumber: 10,
// y线
splitLine: {
lineStyle: {
color: "#1a3d62", // 线
type: "dashed", // 线线
},
},
},
series: [
{
type: "line",
//
symbolSize: 8,
smooth: true,
showSymbol: false,
data: this.brokenData1,
//线
itemStyle: {
color: "#d48e17", //线
lineStyle: {
color: "#d48e17", //线
},
},
areaStyle: {
color: {
//线
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [],
},
},
},
],
};
//
this.brokenInstanc.setOption(this.brokenOption, true);
},
},
};
</script>
<style lang="scss" scoped>
.condition-left {
display: flex;
flex-direction: row;
align-items: center;
flex-wrap: wrap;
.years-div {
display: flex;
flex-direction: row;
align-items: center;
.years-word {
font-size: 14px;
margin: 0 5px;
color: #388ff3;
}
}
.time-label {
font-size: 16px;
line-height: 7px;
margin-right: 12px;
white-space: nowrap;
}
}
.main-content {
min-height: 6.6rem;
}
.choice {
margin: 20px 0;
.mr20 {
padding: 0.05rem 0.2rem;
white-space: nowrap;
width: auto;
}
}
.charts {
width: 100%;
height: 300px;
margin-bottom: 0.1rem;
}
// 2000px
@media (min-width: 2000px) {
.condition {
.condition-left {
.years-div {
.years-word {
font-size: 0.14rem !important;
margin: 0 0.05rem !important;
}
}
.time-label {
font-size: 0.16rem !important;
line-height: 0.07rem !important;
margin-right: 0.12rem !important;
}
}
}
}
</style>

6
src/views/device/comm/index.vue

@ -13,6 +13,7 @@
v-model="queryParams.mtType"
placeholder="请选择仪表类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_mt_type"
@ -176,6 +177,7 @@
v-model="form.mtType"
placeholder="请选择仪表类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_mt_type"
@ -190,6 +192,7 @@
<el-form-item label="波特率" prop="baudRate">
<el-select
clearable
filterable
placeholder="请选择波特率"
v-model="form.baudRate"
>
@ -207,6 +210,7 @@
<el-form-item label="数据位" prop="dataBit">
<el-select
clearable
filterable
placeholder="请选择数据位"
v-model="form.dataBit"
>
@ -219,6 +223,7 @@
<el-form-item label="停止位" prop="stopBit">
<el-select
clearable
filterable
placeholder="请选择停止位"
v-model="form.stopBit"
>
@ -235,6 +240,7 @@
<el-form-item label="校验位" prop="parity">
<el-select
clearable
filterable
placeholder="请选择校验位"
v-model="form.parity"
>

3
src/views/device/gateway/index.vue

@ -21,6 +21,7 @@
v-model="queryParams.status"
placeholder="网关状态"
clearable
filterable
>
<el-option
v-for="dict in dict.type.gateway_status"
@ -255,6 +256,7 @@
v-model="form.operatorType"
placeholder="选择运营商"
clearable
filterable
>
<el-option
v-for="dict in dict.type.operator_type"
@ -270,6 +272,7 @@
v-model="form.communicationType"
placeholder="选择通信方式"
clearable
filterable
>
<el-option
v-for="dict in dict.type.communication_type"

14
src/views/device/gather/index.vue

@ -13,6 +13,7 @@
v-model="queryParams.mtType"
placeholder="请选择仪表类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_mt_type"
@ -27,6 +28,7 @@
v-model="queryParams.systemType"
placeholder="请选择系统类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_type"
@ -41,6 +43,7 @@
v-model="queryParams.paramType"
placeholder="请选择采集参数类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_param_type"
@ -313,6 +316,7 @@
v-model="form.mtType"
placeholder="请选择仪表类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_mt_type"
@ -398,6 +402,7 @@
v-model="form.dataType"
placeholder="请选择数据类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_data_type"
@ -414,6 +419,7 @@
<el-form-item label="是否累计" prop="mtIsSum">
<el-select
clearable
filterable
placeholder="请选择是否"
v-model="form.mtIsSum"
>
@ -466,6 +472,7 @@
v-model="form.protocolType"
placeholder="请选择协议类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_protocol_type"
@ -482,6 +489,7 @@
v-model="form.communicationType"
placeholder="请选择通信类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_communication_type"
@ -497,6 +505,7 @@
<el-form-item label="是否使用" prop="isUse">
<el-select
clearable
filterable
placeholder="请选择是否"
v-model="form.isUse"
>
@ -524,6 +533,7 @@
v-model="form.systemType"
placeholder="请选择系统类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_type"
@ -541,6 +551,7 @@
v-model="form.paramType"
placeholder="请选择参数类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_param_type"
@ -556,6 +567,7 @@
v-model="form.collectionType"
placeholder="请选择采集类别"
clearable
filterable
>
<el-option
v-for="dict in dict.type.alarm_collection_type"
@ -574,6 +586,7 @@
v-model="form.terminalDeviceType"
placeholder="请选择采集设备"
clearable
filterable
@change="handleDeviceType"
>
<el-option
@ -590,6 +603,7 @@
v-model="form.deviceLedgerId"
placeholder="请选择设备名称"
clearable
filterable
>
<el-option
v-for="item in ledgerList"

12
src/views/device/ledger/index.vue

@ -29,6 +29,7 @@
v-model="queryParams.deviceType"
placeholder="请选择设备类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_device_type"
@ -232,6 +233,7 @@
v-model="form.deviceType"
placeholder="请选择设备类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_device_type"
@ -304,7 +306,12 @@
<el-row type="flex" justify="center">
<el-col :span="12">
<el-form-item label="状态" prop="status">
<el-select v-model="form.status" placeholder="请选择" clearable>
<el-select
v-model="form.status"
placeholder="请选择"
clearable
filterable
>
<el-option label="正常" value="0" />
<el-option label="停用" value="1" /> </el-select></el-form-item
></el-col>
@ -314,6 +321,7 @@
v-model="form.isCollection"
placeholder="请选择是否"
clearable
filterable
>
<el-option label="是" value="0" />
<el-option label="否" value="1" />
@ -328,6 +336,7 @@
v-model="form.isCalcEnergy"
placeholder="请选择是否"
clearable
filterable
>
<el-option label="是" value="0" />
<el-option label="否" value="1" />
@ -339,6 +348,7 @@
v-model="form.systemType"
placeholder="请选择系统类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_type"

4
src/views/device/maintenance/index.vue

@ -87,6 +87,7 @@
v-model="queryParams.deviceType"
placeholder="请选择设备类型"
clearable
filterable
>
<el-option
v-for="item in devices"
@ -102,6 +103,7 @@
v-model="queryParams.maintainType"
placeholder="请选择维保类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.maintain_type"
@ -295,6 +297,7 @@
v-model="form.maintainType"
placeholder="请选择维保类型"
clearable
filterable
:disabled="shouldDis"
>
<el-option
@ -312,6 +315,7 @@
v-model="form.deviceType"
placeholder="请选择设备类型"
clearable
filterable
:disabled="shouldDis"
>
<el-option

15
src/views/device/qrCode/index.vue

@ -13,6 +13,7 @@
v-model="queryParams.status"
placeholder="请选择状态"
clearable
filterable
>
<el-option
v-for="dict in dict.type.qrcode_status"
@ -222,6 +223,7 @@
v-model="form.deviceLedgerId"
placeholder="请选择设备名称"
clearable
filterable
@change="handleDeviceChange"
>
<el-option
@ -237,6 +239,7 @@
v-model="form.status"
placeholder="请选择状态"
clearable
filterable
>
<el-option
v-for="dict in dict.type.qrcode_status"
@ -255,11 +258,7 @@
</div>
</el-dialog>
<!-- 二维码预览弹框 -->
<el-dialog
title="二维码预览"
:visible.sync="isCodePreview"
append-to-body
>
<el-dialog title="二维码预览" :visible.sync="isCodePreview" append-to-body>
<div class="dialog-img">
<img class="qrCodeImg" :src="codePreViewUrl" alt="Base64 Image" />
</div>
@ -270,11 +269,7 @@
:visible.sync="isMoreqrCode"
append-to-body
>
<el-form
ref="qrCodeForm"
:model="qrCodeForm"
:rules="qrCodeForms"
>
<el-form ref="qrCodeForm" :model="qrCodeForm" :rules="qrCodeForms">
<el-row type="flex" justify="center">
<el-col :span="24">
<el-form-item label="二维码个数" prop="qrNum">

9
src/views/device/spareInOut/index.vue

@ -29,6 +29,7 @@
v-model="queryParams.operaType"
placeholder="请选择操作类型"
clearable
filterable
>
<el-option
v-for="dict in dict.type.sys_inout_type"
@ -154,6 +155,8 @@
<el-select
v-model="scope.row.sparePartsId"
@change="handleSpare(scope.row, scope.row.sparePartsId)"
filterable
clearable
>
<el-option
v-for="item in spares"
@ -175,7 +178,11 @@
></el-input>
</template>
</el-table-column>
<el-table-column label="当前库存" min-width="150" prop="inventoryLevels">
<el-table-column
label="当前库存"
min-width="150"
prop="inventoryLevels"
>
</el-table-column>
<el-table-column prop="data1" label="操作" min-width="130">
<template slot-scope="scope">

174
src/views/hotWater/dataAnalysis/components/analyzeMonth.vue

@ -153,8 +153,10 @@ export default {
},
methods: {
tableRowStyle({ row, column, rowIndex, columnIndex }) {
// console.log("row",row)
// console.log("column",column)
// 1
if (columnIndex === 0) {
if (columnIndex === 0 || column.label === '合计') {
return "background-color:rgb(11 ,100, 201) !important;";
}
},
@ -293,6 +295,15 @@ export default {
// console.log("Min2", Min2);
// console.log("Max1", Max1);
// console.log("Max2", Max2);
// y+
var yAxisUnit = "";
if (this.chType === 1) {
yAxisUnit = "吨";
} else if (this.chType === 2) {
yAxisUnit = "度";
} else if (this.chType === 3) {
yAxisUnit = "度/吨";
}
this.chartInstance1 = echarts.init(this.$refs.findwater_ref);
const adapterOption = {
legend: {
@ -308,12 +319,24 @@ export default {
max: Max1,
splitNumber: 10,
interval: (Max1 - Min1) / 10,
name: yAxisUnit,
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
},
{
min: Min2,
max: Max2,
splitNumber: 10,
interval: (Max2 - Min2) / 10,
name: "%",
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
},
],
series: [
@ -522,6 +545,62 @@ export default {
width: "1",
},
},
// tooltip
formatter: function (params) {
var res = params[0].name + "<br/>";
for (var i = 0, l = params.length; i < l; i++) {
var seriesName = params[i].seriesName;
var value = params[i].value;
// console.log("", params[i].color.colorStops[0].color)
var marker =
'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:' +
params[i].color.colorStops[0].color +
'"></span>';
// seriesName
if (seriesName.includes("用水量")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"吨" +
"</span><br>";
} else if (seriesName.includes("用电量")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"度" +
"</span><br>";
} else if (seriesName.includes("单耗")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"度/吨" +
"</span><br>";
} else {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"%" +
"</span><br>";
}
}
return res;
},
},
legend: {
// icon
@ -531,7 +610,7 @@ export default {
color: "#ffff",
fontSize: 12, //
},
left: "56%",
left: "center",
top: "5%",
//
itemGap: 5,
@ -638,10 +717,27 @@ export default {
// },
//线
itemStyle: {
color: "#db9215",
lineStyle: {
color: "#db9215", //线
color: "#0b75d3",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgba(1, 102, 251, 1)", //
},
{
offset: 1,
color: "rgba(1, 102, 251, 0)", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0], //
},
},
{
@ -654,10 +750,27 @@ export default {
barWidth: 10, //
//线
itemStyle: {
color: "#1ab395",
lineStyle: {
color: "#1ab395", //线
color: "#0b75d3",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgba(0, 224, 225, 1)", //
},
{
offset: 1,
color: "rgba(0, 224, 225, 0)", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0],
},
},
{
@ -677,10 +790,27 @@ export default {
// data: this.data3,
//线
itemStyle: {
color: "#e23131",
lineStyle: {
color: "#e23131", //线
color: "#db9215",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "#db9215", //
},
{
offset: 1,
color: "#db9215", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0], //
},
},
{
@ -701,9 +831,27 @@ export default {
// data: this.data4,
//线
itemStyle: {
color: "#4a98ff",
color: "#EE5217", //线
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "#EE5217", //
},
{
offset: 1,
color: "#EE5217", //
},
],
global: false, // false
},
lineStyle: {
color: "#4a98ff", //线
color: "#EE5217", //线
},
},
},

218
src/views/hotWater/dataAnalysis/components/analyzeYear.vue

@ -120,7 +120,7 @@ export default {
methods: {
tableRowStyle({ row, column, rowIndex, columnIndex }) {
// 1
if (columnIndex === 0) {
if (columnIndex === 0 || column.label === "合计") {
return "background-color:rgb(11 ,100, 201) !important;";
}
},
@ -240,6 +240,15 @@ export default {
// console.log("Min2", Min2);
// console.log("Max1", Max1);
// console.log("Max2", Max2);
// y+
var yAxisUnit = "";
if (this.chType === 1) {
yAxisUnit = "吨";
} else if (this.chType === 2) {
yAxisUnit = "度";
} else if (this.chType === 3) {
yAxisUnit = "度/吨";
}
this.chartInstance1 = echarts.init(this.$refs.findwater_ref);
const adapterOption = {
legend: {
@ -255,12 +264,24 @@ export default {
max: Max1,
splitNumber: 10,
interval: (Max1 - Min1) / 10,
name: yAxisUnit,
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
},
{
min: Min2,
max: Max2,
splitNumber: 10,
interval: (Max2 - Min2) / 10,
name: "%",
// name
nameTextStyle: {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
},
},
],
series: [
@ -431,6 +452,62 @@ export default {
width: "1",
},
},
// tooltip
formatter: function (params) {
var res = params[0].name + "<br/>";
for (var i = 0, l = params.length; i < l; i++) {
var seriesName = params[i].seriesName;
var value = params[i].value;
// console.log("", params[i].color.colorStops[0].color)
var marker =
'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:' +
params[i].color.colorStops[0].color +
'"></span>';
// seriesName
if (seriesName.includes("用水量")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"吨" +
"</span><br>";
} else if (seriesName.includes("用电量")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"度" +
"</span><br>";
} else if (seriesName.includes("单耗")) {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"度/吨" +
"</span><br>";
} else {
res +=
marker +
seriesName +
":" +
'<span style="color: #000000; font-weight: bold;margin-left:5px">' +
value +
" " +
"%" +
"</span><br>";
}
}
return res;
},
},
legend: {
// icon
@ -440,7 +517,7 @@ export default {
color: "#ffff",
fontSize: 12, //
},
left: "56%",
left: "center",
top: "5%",
//
itemGap: 5,
@ -542,67 +619,55 @@ export default {
barWidth: 10, //
//线
itemStyle: {
color: "#db9215",
lineStyle: {
color: "#db9215", //线
color: "#0b75d3",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgba(1, 102, 251, 1)", //
},
{
offset: 1,
color: "rgba(1, 102, 251, 0)", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0], //
},
},
{
type: "bar",
// tooltip: {
// valueFormatter: function (value) {
// return value + "";
// },
// },
tooltip: {
trigger: "axis",
formatter: function (params) {
//
var relVal = params[0].name; //x
if (params[0].seriesName == "2022年用水量") {
relVal =
params[0].name +
"<br/>" +
params[0].seriesName +
" : " +
params[0].value +
" 吨";
} else if (params[0].seriesName == "用电量") {
relVal =
params[0].name +
"<br/>" +
params[0].seriesName +
" : " +
params[0].value +
" 度";
} else if (params[0].seriesName == "耗能") {
relVal =
params[0].name +
"<br/>" +
params[0].seriesName +
" : " +
params[0].value +
" 度/吨";
} else {
relVal =
params[0].name +
"<br/>" +
params[0].seriesName +
" : " +
params[0].value +
" 次";
}
return relVal;
},
},
barWidth: 10, //
//线
itemStyle: {
color: "#1ab395",
lineStyle: {
color: "#1ab395", //线
color: "#0b75d3",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "rgba(0, 224, 225, 1)", //
},
{
offset: 1,
color: "rgba(0, 224, 225, 0)", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0],
},
},
{
@ -622,10 +687,27 @@ export default {
// data: this.data3,
//线
itemStyle: {
color: "#e23131",
lineStyle: {
color: "#e23131", //线
color: "#db9215",
// 使
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "#db9215", //
},
{
offset: 1,
color: "#db9215", //
},
],
global: false, // false
},
borderRadius: [5, 5, 0, 0], //
},
},
{
@ -646,9 +728,27 @@ export default {
// data: this.data4,
//线
itemStyle: {
color: "#4a98ff",
color: "#EE5217", //线
color: {
type: "linear",
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [
{
offset: 0,
color: "#EE5217", //
},
{
offset: 1,
color: "#EE5217", //
},
],
global: false, // false
},
lineStyle: {
color: "#4a98ff", //线
color: "#EE5217", //线
},
},
},

162
src/views/hotWater/energyAnalysis/components/energyReport.vue

@ -11,13 +11,13 @@
<div v-if="dateType === 'day'">与昨日相比</div>
<div v-if="dateType === 'month'">与上月相比</div>
<div v-if="dateType === 'year'">与上年相比</div>
<div class="upText" v-if="useWaterRadio > 0">
<i class="el-icon-bottom"></i>
<span>+{{ useWaterRadio }}</span>
<div class="upText" v-if="isPositive(useWaterRadio)">
<i class="el-icon-top"></i>
<span>{{ useWaterRadio }}</span>
</div>
<div class="downText" v-else>
<i class="el-icon-bottom"></i>
<span>-{{ useWaterRadio }}</span>
<span>{{ useWaterRadio }}</span>
</div>
</div>
<img
@ -36,13 +36,13 @@
<div v-if="dateType === 'day'">与昨日相比</div>
<div v-if="dateType === 'month'">与上月相比</div>
<div v-if="dateType === 'year'">与上年相比</div>
<div class="upText" v-if="useElectRadio > 0">
<i class="el-icon-bottom"></i>
<span>+{{ useElectRadio }}</span>
<div class="upText" v-if="isPositive(useElectRadio)">
<i class="el-icon-top"></i>
<span>{{ useElectRadio }}</span>
</div>
<div class="downText" v-else>
<i class="el-icon-bottom"></i>
<span>-{{ useElectRadio }}</span>
<span>{{ useElectRadio }}</span>
</div>
</div>
<img
@ -61,13 +61,13 @@
<div v-if="dateType === 'day'">与昨日相比</div>
<div v-if="dateType === 'month'">与上月相比</div>
<div v-if="dateType === 'year'">与上年相比</div>
<div class="upText" v-if="useUnitRadio > 0">
<i class="el-icon-bottom"></i>
<span>+{{ useUnitRadio }}</span>
<div class="upText" v-if="isPositive(useUnitRadio)">
<i class="el-icon-top"></i>
<span>{{ useUnitRadio }}</span>
</div>
<div class="downText" v-else>
<i class="el-icon-bottom"></i>
<span>-{{ useUnitRadio }}</span>
<span>{{ useUnitRadio }}</span>
</div>
</div>
<img
@ -250,6 +250,20 @@ export default {
window.removeEventListener("resize", this.screenAdapter);
},
methods: {
isPositive(value) {
// value
if (typeof value === "string") {
//
const numberPart = value.replace("%", "");
//
const num = parseFloat(numberPart);
return num > 0;
} else {
//
// console.error(":", value);
return false;
}
},
handleEnter(index) {
this.currentIndex = index;
this.renderingBroken();
@ -462,42 +476,12 @@ export default {
},
//线
getChartData() {
console.log("图表参数", this.queryParams);
let timeType = null;
if (this.dateType == "day") {
timeType = 1;
this.queryParams.startTime =
this.dayDate.length > 0 ? this.dayDate[0] : "";
this.queryParams.endTime =
this.dayDate.length > 0 ? this.dayDate[1] : "";
} else if (this.dateType == "month") {
timeType = 2;
this.queryParams.startTime =
this.monthDate.length > 0 ? this.monthDate[0] : "";
this.queryParams.endTime =
this.monthDate.length > 0 ? this.monthDate[1] : "";
} else if (this.dateType == "year") {
timeType = 3;
this.queryParams.startTime = this.startYear;
this.queryParams.endTime = this.endYear;
}
let data = {
type: timeType,
page: this.queryParams.pageNum,
limit: this.total,
startDate: this.queryParams.startTime,
endDate: this.queryParams.endTime,
buildingId: this.building,
};
hotEnergyQuery(data).then((res) => {
console.log("图表返回的数据", res);
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenTime = [];
if (res.code == 200 && res.rows.length > 0) {
this.exportData = res.rows;
res.rows.forEach((item) => {
if ((this.total == 10)) {
//
console.log("不用请求");
if (this.tableData.length > 0) {
this.exportData = this.tableData;
this.exportData.forEach((item) => {
this.brokenData1.push(item.useHotWater);
this.brokenData2.push(item.electValue);
this.brokenData3.push(item.electWater);
@ -516,10 +500,71 @@ export default {
this.brokenTime = [];
}
this.renderingBroken();
});
} else {
console.log("图表参数", this.queryParams);
let timeType = null;
if (this.dateType == "day") {
timeType = 1;
this.queryParams.startTime =
this.dayDate.length > 0 ? this.dayDate[0] : "";
this.queryParams.endTime =
this.dayDate.length > 0 ? this.dayDate[1] : "";
} else if (this.dateType == "month") {
timeType = 2;
this.queryParams.startTime =
this.monthDate.length > 0 ? this.monthDate[0] : "";
this.queryParams.endTime =
this.monthDate.length > 0 ? this.monthDate[1] : "";
} else if (this.dateType == "year") {
timeType = 3;
this.queryParams.startTime = this.startYear;
this.queryParams.endTime = this.endYear;
}
let data = {
type: timeType,
page: 1,
limit: this.total,
startDate: this.queryParams.startTime,
endDate: this.queryParams.endTime,
buildingId: this.building,
};
hotEnergyQuery(data).then((res) => {
console.log("图表返回的数据", res);
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenTime = [];
if (res.code == 200 && res.rows.length > 0) {
this.exportData = res.rows;
res.rows.forEach((item) => {
this.brokenData1.push(item.useHotWater);
this.brokenData2.push(item.electValue);
this.brokenData3.push(item.electWater);
this.brokenTime.push(item.curDate);
});
//
this.brokenData1.reverse();
this.brokenData2.reverse();
this.brokenData3.reverse();
this.brokenTime.reverse();
this.renderingBroken();
} else {
this.brokenData1 = [];
this.brokenData2 = [];
this.brokenData3 = [];
this.brokenTime = [];
}
this.renderingBroken();
});
}
},
renderingBroken() {
if (this.currentIndex === 0) {
this.brokenOption.yAxis.name = "吨";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData1;
this.brokenOption.series[0].itemStyle.color = "#d48e17";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -533,6 +578,11 @@ export default {
},
];
} else if (this.currentIndex === 1) {
this.brokenOption.yAxis.name = "度";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData2;
this.brokenOption.series[0].itemStyle.color = "#1ab395";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -546,6 +596,11 @@ export default {
},
];
} else if (this.currentIndex === 2) {
this.brokenOption.yAxis.name = "度/吨";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData3;
this.brokenOption.series[0].itemStyle.color = "#1f8dee";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -620,12 +675,7 @@ export default {
import("@/assets/excel/Export2Excel").then((excel) => {
// excel
if (this.building == "所有") {
var tHeader = [
"日期",
"用水量(吨)",
"用电量(度)",
"单耗(度/吨)",
]; // excel
var tHeader = ["日期", "用水量(吨)", "用电量(度)", "单耗(度/吨)"]; // excel
var filterVal = [
"curDate",
"useHotWater",
@ -714,7 +764,7 @@ export default {
},
grid: {
top: "4%",
top: "10%",
left: "3%",
right: "4%",
bottom: "5%",

7
src/views/hotWater/energyAnalysis/components/temReport.vue

@ -224,6 +224,11 @@ export default {
},
//
renderingBroken() {
this.brokenOption.yAxis.name = "℃";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData1;
this.brokenOption.series[0].itemStyle.color = "#1f8dee";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -432,7 +437,7 @@ export default {
},
grid: {
top: "4%",
top: "10%",
left: "3%",
right: "4%",
bottom: "5%",

7
src/views/hotWater/energyAnalysis/components/waterReport.vue

@ -223,6 +223,11 @@ export default {
},
//
renderingBroken() {
this.brokenOption.yAxis.name = "%";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData1;
this.brokenOption.series[0].itemStyle.color = "#1f8dee";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -432,7 +437,7 @@ export default {
},
grid: {
top: "4%",
top: "10%",
left: "3%",
right: "4%",
bottom: "5%",

10
src/views/hotWater/energyQuery/components/energy.vue

@ -160,6 +160,11 @@ export default {
//
getChartData() {
if (this.currentIndex === 0) {
this.brokenOption.yAxis.name = "吨";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData1;
this.brokenOption.series[0].itemStyle.color = "#1f8dee";
this.brokenOption.series[0].areaStyle.color.colorStops = [
@ -173,6 +178,11 @@ export default {
},
];
} else if (this.currentIndex === 1) {
this.brokenOption.yAxis.name = "度";
this.brokenOption.yAxis.nameTextStyle = {
color: "rgba(255, 255, 255, 1)",
fontSize: 12,
};
this.brokenOption.series[0].data = this.brokenData2;
this.brokenOption.series[0].itemStyle.color = "#1ab395";
this.brokenOption.series[0].areaStyle.color.colorStops = [

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save