湖里大屏(安全管理):问题占比布局

This commit is contained in:
Jack 2022-08-13 18:40:55 +08:00
parent 008f92cd0a
commit 799264f561
2 changed files with 69 additions and 66 deletions

View File

@ -6,7 +6,7 @@
<leftTop title="待整改" />
</div>
<div class="leftCenter">
<leftCenter title="安全预警" />
<leftCenter title="问题占比" />
</div>
<div class="leftBottom">
<leftBottom title="整改动态" />

View File

@ -1,8 +1,6 @@
<template>
<div class="safety-warning">
<div class="title">{{ title }}</div>
<div class="content">
<div class="table">
<Card :title="title">
<!-- <div class="table">
<div class="thead">
<div class="row">
<div class="td">预警时间</div>
@ -17,41 +15,48 @@
<div class="td">详情</div>
</div>
</div>
</div>
</div>
</div>
</div> -->
<JNestedRingChart :title="{ text: 654, subTitle: '问题总数', y: '35%' }" :series="series" />
</Card>
</template>
<script>
import JRingChart from '../jChart/pie/JRingChart.vue'
import Card from '../components/Card.vue'
import { getNewestSecurityManageDataList2Api } from '@/assets/js/api/dataBoard'
import JNestedRingChart from '../jChart/pie/JNestedRingChart.vue'
export default {
components: { JRingChart },
components: { Card, JNestedRingChart },
props: {
title: {
type: String,
default: 'default title'
default: ''
}
},
mounted() {
getNewestSecurityManageDataList2Api({ projectSn: this.projectSn }).then(res => {
this.alarmList = res.result || []
})
},
data() {
return {}
return {
projectSn: this.$store.state.projectSn,
series: [
{
color: ['#FE6C7F', '#786FF0', '#5CE2F6'],
data: [
{ value: 45, name: '周检' },
{ value: 5, name: '月检' },
{ value: 15, name: '其他' }
]
}
]
}
}
}
</script>
<style lang="less" scoped>
.safety-warning {
width: 100%;
height: 100%;
border: 1px solid #0081c3;
.title {
padding-left: 6px;
height: 30px;
line-height: 30px;
font-size: 18px;
color: #6ee4f0;
}
.content {
height: calc(100% - 30px);
.table {
padding: 0 6px;
height: 100%;
@ -86,6 +91,4 @@ export default {
}
}
}
}
}
</style>