|
@@ -12,7 +12,7 @@
|
|
|
<div class="home-contents">
|
|
|
<div class="left-content">
|
|
|
<!-- 主通风机 -->
|
|
|
- <div class="monitor-box ">
|
|
|
+ <div class="monitor-box">
|
|
|
<mainMonitor :maindata="mainList" @goDetail="goDetail" />
|
|
|
</div>
|
|
|
<!-- 局部通风机 -->
|
|
@@ -130,8 +130,8 @@
|
|
|
// Modal.destroyAll();
|
|
|
// },
|
|
|
// });
|
|
|
- pageType.value = deviceType
|
|
|
- changeModalBox()
|
|
|
+ pageType.value = deviceType;
|
|
|
+ changeModalBox();
|
|
|
}
|
|
|
function goHome() {
|
|
|
pageType.value = 'home';
|
|
@@ -166,18 +166,29 @@
|
|
|
fanLocalList.push(res.fanlocal);
|
|
|
mainList.value = res.fanmain;
|
|
|
centerList = res.midinfo[0].sysdata;
|
|
|
- navList[0].valList = centerList.zongfengliang.split('').map((el) => {
|
|
|
- return { val: el };
|
|
|
- });
|
|
|
+ navList[0].valList = centerList.zongfengliang
|
|
|
+ ? centerList.zongfengliang.split('').map((el) => {
|
|
|
+ return { val: el };
|
|
|
+ })
|
|
|
+ : [];
|
|
|
navList[1].valList = centerList.xufengliang
|
|
|
- .toString()
|
|
|
- .split('')
|
|
|
- .map((el) => {
|
|
|
- return { val: el };
|
|
|
- });
|
|
|
- navList[3].val =
|
|
|
- (((parseFloat(centerList.zongfengliang) - parseFloat(centerList.zonghuifeng)) / parseFloat(centerList.zonghuifeng)) * 100).toFixed(2) + '%';
|
|
|
- navList[4].val = ((centerList.xufengliang / parseFloat(centerList.zongfengliang)) * 100).toFixed(2) + '%';
|
|
|
+ ? centerList.xufengliang
|
|
|
+ .toString()
|
|
|
+ .split('')
|
|
|
+ .map((el) => {
|
|
|
+ return { val: el };
|
|
|
+ })
|
|
|
+ : [];
|
|
|
+
|
|
|
+ if (centerList.zongfengliang && centerList.zonghuifeng) {
|
|
|
+ navList[3].val =
|
|
|
+ (((parseFloat(centerList.zongfengliang) - parseFloat(centerList.zonghuifeng)) / parseFloat(centerList.zonghuifeng)) * 100).toFixed(2) + '%';
|
|
|
+ navList[4].val = ((centerList.xufengliang / parseFloat(centerList.zongfengliang)) * 100).toFixed(2) + '%';
|
|
|
+ } else {
|
|
|
+ navList[3].val = '0%';
|
|
|
+ navList[4].val = '0%';
|
|
|
+ }
|
|
|
+
|
|
|
flList.value = res.windrect;
|
|
|
lineList.value = res.sys_majorpath;
|
|
|
workList.value = res.sys_surface_caimei;
|
|
@@ -214,9 +225,9 @@
|
|
|
let nowTime = computed(() => {
|
|
|
return moment().format('YYYY/MM/DD');
|
|
|
});
|
|
|
- let timeDate=computed(()=>{
|
|
|
- return moment().format('HH:MM:SS')
|
|
|
- })
|
|
|
+ let timeDate = computed(() => {
|
|
|
+ return moment().format('HH:MM:SS');
|
|
|
+ });
|
|
|
onMounted(() => {
|
|
|
getList();
|
|
|
changeModalBox();
|