fix:singleStat 图表no data显示异常修复

This commit is contained in:
wangwenrui
2020-06-28 18:48:03 +08:00
parent f07747a46a
commit 42f6f3bd2b
2 changed files with 3 additions and 2 deletions

View File

@@ -395,11 +395,12 @@ export default {
this.isError = false; this.isError = false;
this.errorContent = ''; this.errorContent = '';
} }
if(seriesItem){ if(seriesItem||seriesItem == 0){ //0 为false
this.noData=false; this.noData=false;
}else{ }else{
this.noData=true; this.noData=true;
} }
if(area==='showFullScreen'){//全屏按时间查询 if(area==='showFullScreen'){//全屏按时间查询
this.data = chartItem; this.data = chartItem;
this.unit = chartDataFormat.getUnit(this.data.unit); this.unit = chartDataFormat.getUnit(this.data.unit);

View File

@@ -70,7 +70,7 @@
<span >{{formatThreshold(scope.row[item.prop],scope.row.unit)}}</span> <span >{{formatThreshold(scope.row[item.prop],scope.row.unit)}}</span>
</template> </template>
<template v-else-if="item.prop == 'receivers'"> <template v-else-if="item.prop == 'receivers'">
<el-tag effect="dark" v-if="user.userName" :key="index" size="mini" v-for="(user, index) in scope.row[item.prop]" class="alert-rule-tag">{{user.userName}}</el-tag> <el-tag effect="dark" v-if="user.userName" :key="index" size="mini" v-for="(user, index) in scope.row[item.prop]" class="alert-rule-tag">{{user.userName}}&nbsp;</el-tag>
</template> </template>
<span v-else-if="scope.row[item.prop]">{{scope.row[item.prop]}}</span> <span v-else-if="scope.row[item.prop]">{{scope.row[item.prop]}}</span>
<template v-else>-</template> <template v-else>-</template>