-
裙楼供暖出水阀:
+
裙楼供暖出水阀:
- 客房供暖出水阀:
+ 客房供暖出水阀:
+
+
+
手自动切换
+
手动控制
+
+ 频率手自动切换
+
+
+ 频率反馈
+
+
+ 频率调节
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ item.frequency }}Hz
+
+
+
+
+
+
+
+
@@ -750,6 +938,7 @@ import {
} from "@/api/centerairC/sysMonitor";
import LineChildren from "./components/lineChildren.vue";
import { alarmRecordList } from "@/api/alarm/alarmRecord";
+import { policyListData } from "@/api/centerairC/strategy";
import { getDay } from "@/utils/datetime";
export default {
components: { LineChildren },
@@ -827,6 +1016,14 @@ export default {
nowTimer: null,
isShowWarning: false, //是否有报警
dayData: "", //监测天数
+
+ // 控制弹框
+ controlTitle: "",
+ openControlDialog: false,
+ controlArr: [],
+
+ hostAddTime: "", //主机加载时间
+ hostReduceTime: "", //主机减载时间
};
},
computed: {
@@ -862,6 +1059,7 @@ export default {
this.getMonitorList();
this.getAlarnStatus();
this.getDayData();
+ this.getPolicyList();
// 设置定时器,每 10 秒执行一次
this.timer = setInterval(() => {
@@ -1082,6 +1280,43 @@ export default {
})
.catch(() => {});
},
+ // 主机加减载时间min
+ getPolicyList() {
+ return new Promise((resolve, reject) => {
+ let data = {
+ systemType: "0",
+ funPolicyType: "1",
+ };
+ policyListData(data)
+ .then((res) => {
+ console.log("策略返回res", res);
+ if (res.code == 200) {
+ let dataList = res.rows;
+ // 筛选出主机->加减载时间
+ dataList.forEach((val) => {
+ if (val.name === "主机策略") {
+ val.values.forEach((child) => {
+ if (child.pointName === "主机加载时间") {
+ this.hostAddTime = child.curValue;
+ }
+ if (child.pointName === "主机减载时间") {
+ this.hostReduceTime = child.curValue;
+ }
+ });
+ }
+ });
+ } else {
+ this.policyList = [];
+ }
+ // 成功时解析 Promise
+ resolve(res);
+ })
+ .catch((error) => {
+ // 失败时拒绝 Promise
+ reject(error);
+ });
+ });
+ },
// 系统监测数据
getMonitorList() {
monitorList({ systemType: 0 }).then((res) => {
@@ -1304,7 +1539,11 @@ export default {
// 遍历 properties 数组,如果当前对象paramType === 2并且item.collectValue !== "0.00"则便是启停控制中的开启
for (let i = 0; i < properties.length; i++) {
const item = properties[i];
- if (item.paramType === "2" && Number(item.collectValue) !== 0 && item.collectName.includes('启停')) {
+ if (
+ item.paramType === "2" &&
+ Number(item.collectValue) !== 0 &&
+ item.collectName.includes("启停")
+ ) {
return true;
}
}
@@ -2057,6 +2296,284 @@ export default {
// this.exitFullscreen();
this.$router.push("/alarm/alarmRecord");
},
+ // 控制
+ goControlList(item, index, name) {
+ console.log("item1111111111111111111", item, index, name);
+ // 处理properties值,
+ this.controlArr = [];
+ this.controlTitle = "";
+ // 初始化一个空对象来存储非蝶阀处理后的结果
+ let deviceItem = {};
+ let properties;
+ if (index !== undefined && index !== null && index !== "") {
+ // 从 item 中查找 deviceName 包含与 index 相同数字的对象
+ let targetDevice = null;
+ for (let i = 0; i < item.length; i++) {
+ const device = item[i];
+ const indexStr = index.toString();
+ const deviceName = device.deviceName.toString();
+ for (let j = 0; j < indexStr.length; j++) {
+ if (deviceName.includes(indexStr[j])) {
+ this.controlTitle = deviceName;
+ deviceItem.name = deviceName;
+ console.log("this.controlTitle", this.controlTitle);
+ targetDevice = device;
+ break;
+ }
+ }
+ if (targetDevice) {
+ break;
+ }
+ }
+ // 如果未找到匹配的设备,返回 false
+ if (!targetDevice) {
+ return false;
+ }
+ // 获取匹配设备的 properties 数组
+ properties = targetDevice.properties;
+ console.log("匹配的当前的设备数据", properties);
+ } else {
+ // 如果 index 未传值,直接将 item 当作 properties
+ properties = item;
+ this.controlTitle = name;
+ deviceItem.name = name;
+ console.log("index 未传值,直接处理 item 作为 properties", properties);
+ }
+ console.log("匹配的当前的设备数据", properties);
+
+ properties.forEach((child) => {
+ if (child.collectName) {
+ // 手动控制
+ if (
+ child.paramType === "2" &&
+ !child.collectName.includes("阀") &&
+ child.collectName.includes("启停")
+ ) {
+ deviceItem.controlText =
+ Number(child.collectValue) == 0 ? false : true;
+ deviceItem.controlId = child.id;
+ }
+ // 阀门的-手动控制
+ else if (
+ child.paramType === "2" &&
+ child.collectName.includes("阀")
+ ) {
+ deviceItem.controlText =
+ Number(child.collectValue) == 0 ? false : true;
+ deviceItem.controlId = child.id;
+ }
+ // 手自动切换 0自动1手动
+ else if (
+ child.paramType === "6" &&
+ !child.collectName.includes("阀")
+ ) {
+ deviceItem.automaticText =
+ Number(child.collectValue) == 0 ? false : true;
+ deviceItem.automaticId = child.id;
+ }
+ // 阀门的-手自动切换
+ else if (
+ child.paramType === "6" &&
+ child.collectName.includes("阀")
+ ) {
+ deviceItem.automaticText =
+ Number(child.collectValue) == 0 ? false : true;
+ deviceItem.automaticId = child.id;
+ }
+ // 频率-手自动切换
+ else if (
+ child.paramType === "40" &&
+ !child.collectName.includes("阀")
+ ) {
+ deviceItem.frequencyAutotext =
+ Number(child.collectValue) == 0 ? false : true;
+ deviceItem.frequencyAutotextId = child.id;
+ }
+ // 频率调节
+ else if (
+ child.paramType === "3" &&
+ !child.collectName.includes("阀")
+ ) {
+ deviceItem.frequencySet =
+ Number(child.collectValue) == 0 ? "0" : child.collectValue;
+ deviceItem.frequencyId = child.id;
+ }
+ // 频率反馈
+ else if (
+ child.paramType === "4" &&
+ child.collectName.includes("频率反馈")
+ ) {
+ deviceItem.frequency = child.collectValue;
+ }
+ }
+ });
+ // 将处理后的对象添加到 deviceList 中
+ if (Object.keys(deviceItem).length > 1) {
+ this.controlArr.push(deviceItem);
+ }
+ console.log("处理后的this.controlArr", this.controlArr);
+ this.openControlDialog = true;
+ },
+ hasFrequencySet(item, name) {
+ return (
+ item &&
+ item.hasOwnProperty(name) &&
+ item[name] !== null &&
+ item[name] !== ""
+ );
+ },
+ // 处理输入事件,过滤非数字字符
+ handleInput(item) {
+ console.log("校验");
+ // 实时校验并过滤非数字字符
+ item.frequencySet = String(item.frequencySet).replace(/[^\d]/g, "");
+ },
+ // 失去焦点
+ handleBlur() {
+ // this.currentFocusIndex = "";
+ },
+ handleEnter(item, event) {
+ console.log("请求后端", item);
+ // 失去焦点
+ event.target.blur();
+ this.$confirm(
+ `确定要修改"${item.name}"的频率为:${item.frequencySet} Hz吗?`,
+ "提示",
+ {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ type: "warning",
+ }
+ )
+ .then(() => {
+ this.operationConrol(item.frequencyId, item.frequencySet);
+ })
+ .catch(() => {
+ // 用户取消操作,需要更新原来的频率
+ // this.$emit("upList");
+ });
+ },
+ //手动控制
+ handleControlText(item) {
+ this.$confirm(
+ `确定要切换设备"${item.name}"的状态为:${
+ item.controlText ? "开启" : "停止 吗?"
+ }`,
+ "提示",
+ {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ type: "warning",
+ }
+ )
+ .then(() => {
+ // 这里调用请求函数
+ console.log("请求后台", item.controlText);
+ let param = null;
+ if (item.controlText) {
+ param = 1;
+ } else {
+ param = 0;
+ }
+ this.operationConrol(item.controlId, param);
+ })
+ .catch(() => {
+ // 用户取消操作,恢复开关状态
+ item.controlText = !item.controlText;
+ console.log("不请求后台");
+ });
+ },
+ // 手自动切换
+ handleAutomaticText(item) {
+ this.$confirm(
+ `确定要切换设备"${item.name}"的状态为:${
+ item.automaticText ? "手动" : "自动 吗?"
+ }`,
+ "提示",
+ {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ type: "warning",
+ }
+ )
+ .then(() => {
+ // 这里调用请求函数
+ console.log("请求后台", item.automaticText);
+ let param = null;
+ if (item.automaticText) {
+ param = 1;
+ } else {
+ param = 0;
+ }
+ this.operationConrol(item.automaticId, param);
+ })
+ .catch(() => {
+ // 用户取消操作,恢复开关状态
+ item.automaticText = !item.automaticText;
+ 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.operationConrol(item.frequencyAutotextId, param);
+ })
+ .catch(() => {
+ // 用户取消操作,恢复开关状态
+ item.frequencyAutotext = !item.frequencyAutotext;
+ console.log("不请求后台");
+ });
+ },
+ // 操作
+ hadleOperationConrol(id, param) {
+ let data = {
+ id: id,
+ param: param,
+ };
+ console.log("操作参数", data);
+ operationConrol([data])
+ .then((res) => {
+ if (res.code == 200) {
+ this.$modal.msgSuccess("指令下发成功!");
+ // 开启 loading 效果
+ this.loading = true;
+ // 更新所有设备状态;
+ setTimeout(() => {
+ this.getMonitorList();
+ this.loading = false;
+ }, 5000);
+ } else {
+ // this.$modal.msgError("操作失败");
+ console.log("应该更新状态的");
+ // 更新所有设备状态;
+ this.getMonitorList();
+ }
+ })
+ .catch((error) => {
+ console.log("请求发生错误,更新设备状态", error);
+ // 更新所有设备状态;
+ this.getMonitorList();
+ });
+ },
},
};
@@ -2246,6 +2763,7 @@ export default {
}
}
.towerValve1 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 1.43rem;
@@ -2256,6 +2774,7 @@ export default {
border-radius: 50%;
}
.towerValve2 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 1.37rem;
@@ -2266,6 +2785,7 @@ export default {
border-radius: 50%;
}
.towerValve3 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 1.3rem;
@@ -2276,6 +2796,7 @@ export default {
border-radius: 50%;
}
.towerValve4 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 2.35rem;
@@ -2286,6 +2807,7 @@ export default {
border-radius: 50%;
}
.towerValve5 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 2.27rem;
@@ -2296,6 +2818,7 @@ export default {
border-radius: 50%;
}
.towerValve6 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 2.2rem;
@@ -2398,6 +2921,7 @@ export default {
z-index: 10;
}
.hostName1 {
+ cursor: pointer;
border-bottom: 1px solid rgba(0, 255, 255, 1);
z-index: 10;
font-size: 0.22rem;
@@ -2411,6 +2935,7 @@ export default {
text-shadow: 0.02rem 0.02rem 0.04rem rgba(0, 0, 0, 0.9); /* 添加文字阴影增强立体感 */
}
.hostName2 {
+ cursor: pointer;
border-bottom: 1px solid rgba(0, 255, 255, 1);
z-index: 10;
font-size: 0.22rem;
@@ -2424,6 +2949,7 @@ export default {
text-shadow: 0.02rem 0.02rem 0.04rem rgba(0, 0, 0, 0.9);
}
.hostName3 {
+ cursor: pointer;
border-bottom: 1px solid rgba(0, 255, 255, 1);
z-index: 10;
font-size: 0.22rem;
@@ -2480,11 +3006,12 @@ export default {
.host-main1 {
z-index: 100;
position: absolute;
- top: 5.4rem;
+ top: 5.39rem;
left: 4.15rem;
width: 1.6rem;
- height: 1.4rem;
+ // height: 1.2rem;
// background-color: #007bff;
+ border-top-right-radius: 0.3rem;
cursor: pointer;
opacity: 0.4;
transform-style: preserve-3d;
@@ -2493,11 +3020,12 @@ export default {
.host-main2 {
z-index: 100;
position: absolute;
- top: 4.8rem;
- left: 6rem;
- width: 1.55rem;
- height: 1.3rem;
+ top: 4.9rem;
+ left: 5.9rem;
+ width: 1.5rem;
+ height: 1.05rem;
// background-color: #007bff;
+ border-top-right-radius: 0.3rem;
cursor: pointer;
opacity: 0.4;
transform-style: preserve-3d;
@@ -2506,15 +3034,16 @@ export default {
.host-main3 {
z-index: 100;
position: absolute;
- top: 4.4rem;
+ top: 4.55rem;
left: 7.7rem;
width: 1.5rem;
- height: 1rem;
+ height: 0.8rem;
// background-color: #007bff;
+ border-top-right-radius: 0.3rem;
cursor: pointer;
opacity: 0.4;
transform-style: preserve-3d;
- transform: translateX(-50%) rotateY(0deg) rotateX(0deg) rotateZ(30deg);
+ transform: translateX(-50%) rotateY(0deg) rotateX(0deg) rotateZ(25deg);
}
.hostLoad1 {
z-index: 10;
@@ -2625,6 +3154,7 @@ export default {
border-radius: 50%;
}
.coolingPump1 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2634,6 +3164,7 @@ export default {
left: 7.23rem;
}
.coolingPump2 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2643,6 +3174,7 @@ export default {
left: 7.68rem;
}
.coolingPump3 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2652,6 +3184,7 @@ export default {
left: 8.22rem;
}
.coolingPump4 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2661,6 +3194,7 @@ export default {
left: 8.68rem;
}
.coolingPump5 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2760,6 +3294,7 @@ export default {
font-weight: bold;
}
.freezingPump1 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2769,6 +3304,7 @@ export default {
left: 6.2rem;
}
.freezingPump2 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2778,6 +3314,7 @@ export default {
left: 6.96rem;
}
.freezingPump3 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2787,6 +3324,7 @@ export default {
left: 8.6rem;
}
.freezingPump4 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2796,6 +3334,7 @@ export default {
left: 9.15rem;
}
.freezingPump5 {
+ cursor: pointer;
z-index: 10;
font-size: 0.15rem;
font-weight: bold;
@@ -2895,6 +3434,7 @@ export default {
font-weight: bold;
}
.coolingTower3 {
+ cursor: pointer;
z-index: 10;
font-size: 0.18rem;
color: #46f1e3;
@@ -2905,6 +3445,7 @@ export default {
transform: rotateX(20deg) rotateY(-25deg) rotateZ(0deg);
}
.coolingTower2 {
+ cursor: pointer;
z-index: 10;
font-size: 0.18rem;
color: #46f1e3;
@@ -2915,6 +3456,7 @@ export default {
transform: rotateX(20deg) rotateY(-25deg) rotateZ(0deg);
}
.coolingTower1 {
+ cursor: pointer;
z-index: 10;
font-size: 0.18rem;
color: #46f1e3;
@@ -2967,6 +3509,7 @@ export default {
}
}
.frozenValve1 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 6.27rem;
@@ -2977,6 +3520,7 @@ export default {
border-radius: 50%;
}
.frozenValve2 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 5.61rem;
@@ -2987,6 +3531,7 @@ export default {
border-radius: 50%;
}
.frozenValve3 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 4.88rem;
@@ -2997,6 +3542,7 @@ export default {
border-radius: 50%;
}
.coolingValue1 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 5.37rem;
@@ -3007,6 +3553,7 @@ export default {
border-radius: 50%;
}
.coolingValue2 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 4.85rem;
@@ -3017,6 +3564,7 @@ export default {
border-radius: 50%;
}
.coolingValue3 {
+ cursor: pointer;
z-index: 10;
position: absolute;
top: 4.35rem;
@@ -3097,7 +3645,7 @@ export default {
z-index: 10;
position: absolute;
top: 0.2rem;
- left: 1.1rem;
+ left: -0.5rem;
display: flex;
flex-direction: column;
align-items: flex-start;
@@ -3413,9 +3961,22 @@ export default {
transform: scale(0.9);
}
}
+.detail-data-bottom {
+ position: absolute;
+ top: 1rem;
+ left: 2.3rem;
+ width: 4rem;
+ padding: 0rem 0.3rem;
+ z-index: 0;
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ align-items: flex-start;
+ justify-content: center;
+}
diff --git a/src/views/centerairC/sysMonitor/performance.vue b/src/views/centerairC/sysMonitor/performance.vue
index aa3f206..2de3015 100644
--- a/src/views/centerairC/sysMonitor/performance.vue
+++ b/src/views/centerairC/sysMonitor/performance.vue
@@ -714,153 +714,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;
diff --git a/src/views/hotWater/waterControl/index.vue b/src/views/hotWater/waterControl/index.vue
index 0ced23a..6bf7e13 100644
--- a/src/views/hotWater/waterControl/index.vue
+++ b/src/views/hotWater/waterControl/index.vue
@@ -508,7 +508,7 @@
{{ item.pressure }}bar