|
|
@@ -39,7 +39,20 @@
|
|
|
margin-bottom: 30px;
|
|
|
position: relative;
|
|
|
span{
|
|
|
- position: absolute;
|
|
|
+ // position: absolute;
|
|
|
+ top: 15px;
|
|
|
+ width: 80%;
|
|
|
+ text-align: center;
|
|
|
+ left: 0;
|
|
|
+ right: 0;
|
|
|
+ margin: auto;
|
|
|
+ font-size: 22px;
|
|
|
+ line-height: inherit;
|
|
|
+ font-weight:300;
|
|
|
+ // position: absolute;
|
|
|
+ }
|
|
|
+ .normal{
|
|
|
+ // position: absolute;
|
|
|
top: 15px;
|
|
|
width: 80%;
|
|
|
text-align: center;
|
|
|
@@ -49,6 +62,13 @@
|
|
|
font-size: 22px;
|
|
|
line-height: inherit;
|
|
|
font-weight:300;
|
|
|
+ position: absolute;
|
|
|
+ }
|
|
|
+ .el-dropdown{
|
|
|
+ position: absolute;
|
|
|
+ left:33%;
|
|
|
+ top:15px;
|
|
|
+ color:#fff;
|
|
|
}
|
|
|
}
|
|
|
.datas{
|
|
|
@@ -182,7 +202,15 @@
|
|
|
<img @click="min" class="min" src="../images/min.png" alt="">
|
|
|
<h1 class="title">
|
|
|
<img height="90px" width="100%" src="../images/bg_1.jpg" alt="">
|
|
|
- <span>{{info.name}}<br>可视化系统</span>
|
|
|
+ <el-dropdown v-if="data.enterprise_children" >
|
|
|
+ <span>{{info.name}} <i class="el-icon-arrow-down"></i><br>可视化系统</span>
|
|
|
+ <el-dropdown-menu slot="dropdown">
|
|
|
+ <div v-for='(item,i) in data.enterprise_children' :key='i' @click='getDataAgain(item)'>
|
|
|
+ <el-dropdown-item>{{item.name}}</el-dropdown-item>
|
|
|
+ </div>
|
|
|
+ </el-dropdown-menu>
|
|
|
+ </el-dropdown>
|
|
|
+ <span class="normal" v-else>{{info.name}}<br>可视化系统</span>
|
|
|
</h1>
|
|
|
<ul class="datas">
|
|
|
<li style="width:30%;">
|
|
|
@@ -234,7 +262,7 @@
|
|
|
<table cellpadding='0' cellspacing='0'>
|
|
|
<!-- <thead><td>序号</td><td>企业名称</td><td>告警次数</td></thead> -->
|
|
|
<tr v-for="(item,index) in data.latest_warning" :key='index'>
|
|
|
- <td style="width:40px">{{item.riskpoint_name}}</td>
|
|
|
+ <td style="width:100px">{{item.riskpoint_name}}</td>
|
|
|
<td>{{item.monit_name}}</td><td>{{item.ctime}}</td></tr>
|
|
|
</table>
|
|
|
</div>
|
|
|
@@ -259,12 +287,14 @@ export default {
|
|
|
fullscreen:'',
|
|
|
info:{},
|
|
|
count:0,
|
|
|
- data:{}
|
|
|
+ data:{},
|
|
|
+ enterprise_id:null
|
|
|
}
|
|
|
},
|
|
|
methods:{
|
|
|
getData(){
|
|
|
- this.$api.getChartData({type:'qy'}).then(res=>{
|
|
|
+ // enterprise_id
|
|
|
+ this.$api.getChartData({type:'qy',enterprise_id:this.enterprise_id}).then(res=>{
|
|
|
this.data=res.data.data
|
|
|
var data=res.data.data;
|
|
|
let count=0;
|
|
|
@@ -394,6 +424,7 @@ export default {
|
|
|
for(let i=0;i<data.riskpoint_count_data.length;i++){
|
|
|
fxd_name.push(data.riskpoint_count_data[i].name)
|
|
|
}
|
|
|
+ //风险点任务
|
|
|
var option4 = {
|
|
|
backgroundColor:'rgba(0,0,0,0)',
|
|
|
// color:['#3398dc'],
|
|
|
@@ -569,6 +600,11 @@ export default {
|
|
|
},
|
|
|
goTo(path){
|
|
|
this.$router.push(path)
|
|
|
+ },
|
|
|
+ getDataAgain(item){
|
|
|
+ this.enterprise_id = item.id
|
|
|
+ this.getData()
|
|
|
+ this.info.name = item.name
|
|
|
}
|
|
|
},
|
|
|
mounted(){
|