doum
2026-03-05 e77e096fbfcc1bf525b9ea3382a26abe111c957d
admin/src/views/business/dangerStatic.vue
@@ -77,13 +77,13 @@
</template>
<script>
import QueryForm from '@/components/common/QueryForm'
// import QueryForm from '@/components/common/QueryForm'
import * as echarts from 'echarts'
import { hiddenDangerDataPost } from '@/api/business/hiddenDanger'
import dayjs from 'dayjs'
export default {
  components: {
    QueryForm,
    // QueryForm,
  },
  data() {
    return {
@@ -101,7 +101,7 @@
            options: [
              { label: '待处理', value: '0' },
              { label: '已处理', value: '1' },
              { label: '已退回', value: '2' },
              { label: '已退回', value: '2' }
            ]
          },
          {
@@ -163,10 +163,8 @@
            this.initDept()
            this.initDept3()
          })
        }
      })
    },
    changeForm(e) {
      this.getData()
@@ -177,8 +175,8 @@
      this.typeList.forEach(i => {
        total += i.total
      })
      let colors = ['#d75a44', '#e39f4d', '#f0d05f', '#7ac7f6', '#4469ee', '#698af0','#86a2f1','#a1b4f6','#a0b5f5', '#9fb5f4', '#b6c7f7', '#c8d5f8']
      let option = {
      const colors = ['#d75a44', '#e39f4d', '#f0d05f', '#7ac7f6', '#4469ee', '#698af0', '#86a2f1', '#a1b4f6', '#a0b5f5', '#9fb5f4', '#b6c7f7', '#c8d5f8']
      const option = {
        grid: {
          left: '0%',
          right: '0%',
@@ -193,8 +191,8 @@
            left: '45%',
            textStyle: {
              color: '#666666',
              fontSize: 13,
            },
              fontSize: 13
            }
          }, {
            text: total,
            top: '50%',
@@ -202,8 +200,8 @@
            textStyle: {
              color: '#080404',
              fontSize: 16,
              fontWeight: 'bold',
            },
              fontWeight: 'bold'
            }
          }],
        legend: {
          left: 'center',
@@ -226,7 +224,7 @@
            type: 'pie',
            radius: ['34%', '50%'],
            label: {
              formatter: "{a|{b}}\n\n{c} | {d}%",
              formatter: '{a|{b}}\n\n{c} | {d}%',
              rich: {
                a: {
                  color: '#333333',
@@ -264,7 +262,7 @@
    initDept() {
      const myChart = echarts.init(document.querySelector('.echart2'))
      let option = {
      const option = {
        grid: {
          left: '10%',
          right: '10%',
@@ -286,7 +284,7 @@
          name: '隐患数',
          minInterval: 1,
          axisLine: {
            show: true,
            show: true
          }
        },
        series: [
@@ -305,7 +303,7 @@
              show: true,      // 显示标签
              position: 'top', // 让标签显示在柱子顶部
              color: '#666666',   // 文字颜色
              fontSize: 14,    // 文字大小
              fontSize: 14 // 文字大小
            }
          }
        ]
@@ -320,10 +318,10 @@
      const myChart = echarts.init(document.querySelector('#echart3'))
      let names = this.yearList.map(item => item.name)
      let datas = this.yearList.map(item => item.total)
      const names = this.yearList.map(item => item.name)
      const datas = this.yearList.map(item => item.total)
      let option = {
      const option = {
        tooltip: {
          trigger: 'axis',
          axisPointer: {
@@ -349,7 +347,7 @@
          axisLabel: {
            formatter: function (value) {
              // 四舍五入到最近的整数
              return Math.round(value);
              return Math.round(value)
            }
          }
        },
@@ -478,7 +476,7 @@
  .main_table {
    display: flex;
    align-items: start;
    align-items: flex-start;
    justify-content: space-between;
    .main_table_echart {
      width: 64%;
@@ -554,7 +552,7 @@
  .main_content {
    display: flex;
    align-items: start;
    align-items: flex-start;
    justify-content: space-between;
    height: 500px;
    margin-bottom: 10px;