Riku
2025-06-09 2547159bbd781c8e1a41ecc939385396c85f9766
2025.6.9(功能编写中)
已修改12个文件
已添加1个文件
156 ■■■■ 文件已修改
src/api/index.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components.d.ts 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/BaseCard.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/search/OptionTime.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/stores/subtask.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/echart/chart-option.js 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/ProChangeTrack.vue 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/ProblemTrack.vue 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/component/ProblemChangeChart.vue 27 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/component/ProblemSummary.vue 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/component/ProblemTable.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/inspection/problem/component/ProblemType.vue 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/main/MonitorView.vue 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/index.js
@@ -6,7 +6,8 @@
var IP = '47.100.191.150'
var PORT = '9005'
if (debug) {
  IP = '192.168.0.103'
  // IP = '192.168.0.103'
  IP = 'localhost'
  PORT = '9001'
}
src/components.d.ts
@@ -16,11 +16,9 @@
    ElCard: typeof import('element-plus/es')['ElCard']
    ElCascader: typeof import('element-plus/es')['ElCascader']
    ElCol: typeof import('element-plus/es')['ElCol']
    ElCollapseTransition: typeof import('element-plus/es')['ElCollapseTransition']
    ElConfigProvider: typeof import('element-plus/es')['ElConfigProvider']
    ElDatePicker: typeof import('element-plus/es')['ElDatePicker']
    ElDivider: typeof import('element-plus/es')['ElDivider']
    ElEmpty: typeof import('element-plus/es')['ElEmpty']
    ElIcon: typeof import('element-plus/es')['ElIcon']
    ElImage: typeof import('element-plus/es')['ElImage']
    ElLink: typeof import('element-plus/es')['ElLink']
src/components/BaseCard.vue
@@ -63,7 +63,7 @@
  border-radius: 8px;
  padding: 4px;
  /* background: linear-gradient(#14428be8, #14428b8f); */
  background: #0034888f;
  background: #14428be8;
}
.close-icon {
src/components/search/OptionTime.vue
@@ -1,8 +1,8 @@
<template>
  <!-- <el-form-item label="时间" :prop="prop"> -->
  <el-date-picker
    v-model="date"
    @change="handleChange"
    :model-value="modelValue"
    @update:model-value="handleChange"
    :type="type"
    placeholder="选择时间"
    :disabled-date="disabledDate"
src/stores/subtask.js
@@ -111,11 +111,11 @@
  }
  function getSummaryMap(callback) {
    if (summaryMap.value.size === 0) {
      onFetchMap.push(callback)
    } else {
    if (summaryMap.value.size > 0) {
      callback(summaryMap.value)
    }
    onFetchMap.push(callback)
  }
  return {
src/utils/echart/chart-option.js
@@ -31,7 +31,7 @@
    //   }
    // },
    grid: {
      left: '3%',
      left: '10%',
      right: '4%',
      bottom: '3%',
      containLabel: true
@@ -44,7 +44,7 @@
        name: name,
        type: 'pie',
        // radius: '55%',
        center: ['50%', '50%'],
        // center: ['50%', '50%'],
        data: _data,
        roseType: 'radius',
        percentPrecision: 0,
src/views/inspection/problem/ProChangeTrack.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
<template>
    <BaseCard title="整改跟踪">
    <el-row justify="space-between" align="middle">
      <!-- <div class="font-large">问题整改跟踪</div> -->
      <el-button></el-button>
      <OptionTime v-model="time" type="date"></OptionTime>
    </el-row>
    <div>
      <ProblemSummary :data="subtaskList" :proStatistic="proStatistic"></ProblemSummary>
      <ProblemTable :data="subtaskList"></ProblemTable>
    </div>
  </BaseCard>
</template>
<script setup>
import { ref } from "vue";
import ProblemTable from './component/ProblemTable.vue'
import ProblemSummary from './component/ProblemSummary.vue'
</script>
src/views/inspection/problem/ProblemTrack.vue
@@ -1,30 +1,34 @@
<template>
  <!-- <div class="border-r-small"> -->
  <BaseCard>
    <el-row justify="space-between" align="middle">
      <div class="font-large">问题整改跟踪</div>
  <BaseCard title="整改跟踪">
    <el-row justify="space-evenly" align="middle">
      <!-- <div class="font-large">问题整改跟踪</div> -->
      <el-button size="small" type="primary" icon="CaretLeft" @click="previousDay"
        >前一天</el-button
      >
      <OptionTime v-model="time" type="date"></OptionTime>
      <el-button size="small" type="primary" icon="CaretRight" @click="nextDay">后一天</el-button>
    </el-row>
    <div>
      <ProblemSummary :data="subtaskList" :proStatistic="proStatistic"></ProblemSummary>
      <ProblemTable :data="subtaskList"></ProblemTable>
    </div>
  </BaseCard>
  <BaseCard>
    <el-row justify="space-between" align="middle">
      <div class="font-large">分期趋势</div>
      <OptionTime v-model="time"></OptionTime>
  <BaseCard title="问题分布">
    <!-- <el-row justify="space-between" align="middle">
      <div class="font-large">问题分布</div>
    </el-row> -->
    <div>
      <ProblemType ref="pTypeRef"></ProblemType>
    </div>
  </BaseCard>
  <BaseCard title="分期趋势">
    <el-row justify="end" align="middle">
      <!-- <div class="font-large">分期趋势</div> -->
      <!-- <OptionTime v-model="time"></OptionTime> -->
    </el-row>
    <div>
      <ProblemChangeChart ref="pChangeRef"></ProblemChangeChart>
    </div>
  </BaseCard>
  <BaseCard>
    <el-row justify="space-between" align="middle">
      <div class="font-large">问题分布</div>
    </el-row>
    <div>
      <ProblemType ref="pTypeRef"></ProblemType>
    </div>
  </BaseCard>
  <!-- <BaseCard>
@@ -86,6 +90,12 @@
    ...mapStores(useSubtaskStore)
  },
  methods: {
    nextDay() {
      this.time = dayjs(this.time).add(1, 'day').toDate()
    },
    previousDay() {
      this.time = dayjs(this.time).add(-1, 'day').toDate()
    },
    fetchSubtask() {
      // taskApi.fetchSubtaskSummaryByArea(this.area).then((res) => {
      //   this.subtaskList = res.data
src/views/inspection/problem/component/ProblemChangeChart.vue
@@ -1,20 +1,35 @@
<template>
  <el-row justify="space-between">
    <el-col :span="24">
      <el-text size="small">
      <el-row justify="space-between" class="p-h-16">
        <el-statistic title="场景数" :value="sceneNum" />
        <el-statistic title="问题数" :value="proNum" />
        <!-- <el-statistic title="单场景问题均值" :value="proEachSceneNum" /> -->
        <el-statistic title="整改数" :value="changeNum" />
        <el-statistic title="整改通过数" :value="changePassNum" />
        <el-statistic title="问题整改率" :value="changePer" />
        <el-statistic title="整改通过率" :value="changePassPer" />
      </el-row>
      <!-- <el-row justify="space-between" class="p-h-16">
        <el-statistic title="整改通过数" :value="changePassNum" />
        <el-statistic title="问题整改率" :value="changePer" />
        <el-statistic title="整改通过率" :value="changePassPer" />
      </el-row> -->
      <!-- <el-text size="small">
        åœºæ™¯æ•°ï¼š{{ sceneNum }},问题总数:{{ proNum }},单场景问题均值:{{ proEachSceneNum }},
      </el-text>
      <el-text size="small">
        æ•´æ”¹æ€»æ•°ï¼š{{ changeNum }},有效整改数:{{ changePassNum }},问题整改率:{{
          changePer
        }},有效整改率:{{ changePassPer }}
      </el-text>
      </el-text> -->
    </el-col>
    <!-- <el-col :span="6">
      <el-row justify="end">
    <!-- <el-col :span="6"> -->
      <!-- <el-statistic title="有效整改率" :value="changePassPer" /> -->
      <!-- <el-row justify="end">
        <OptionTime v-model="time"></OptionTime>
      </el-row>
    </el-col> -->
      </el-row> -->
    <!-- </el-col> -->
  </el-row>
  <div ref="echart" class="line-chart"></div>
</template>
src/views/inspection/problem/component/ProblemSummary.vue
@@ -154,6 +154,7 @@
<style scoped>
.pie-chart {
  /* width: 200px; */
  height: 70px;
  height: 100px;
  /* background-color: aliceblue; */
}
</style>
src/views/inspection/problem/component/ProblemTable.vue
@@ -29,7 +29,7 @@
    </el-table-column>
  </el-table>
  <div v-if="showMoreBtn" class="btn-more font-small">
    <el-link type="primary" @click="showMore = !showMore">
    <el-link type="success" @click="showMore = !showMore">
      {{ showMore ? '收起更多' : '查看更多' }}
    </el-link>
  </div>
@@ -61,9 +61,9 @@
const tableData = computed(() => {
  const l = props.data.map((value) => {
    const time = value.subtask.executionendtime
      ? value.subtask.executionendtime
      : value.subtask.executionstarttime
    const time = value.subtask.executionstarttime
      ? value.subtask.executionstarttime
      : value.subtask.executionendtime
    value.updateTime = time
    return value
  })
src/views/inspection/problem/component/ProblemType.vue
@@ -1,13 +1,18 @@
<template>
  <el-row justify="space-between">
    <el-col :span="18">
      <el-text v-if="mainProType">
    <el-col :span="24">
      <el-row v-if="mainProType" justify="space-between" class="p-h-16">
        <el-statistic title="突出问题" :value="mainProType.name" />
        <el-statistic title="问题数" :value="mainProType.count" />
        <el-statistic title="占比" :value="mainProType.per" />
      </el-row>
      <!-- <el-text v-if="mainProType">
        çªå‡ºé—®é¢˜ï¼š{{ mainProType.name }},问题数:{{ mainProType.count }},占比{{ mainProType.per }}
      </el-text>
      </el-text> -->
    </el-col>
    <el-col :span="6">
      <el-row justify="end">
        <OptionTime v-model="time"></OptionTime>
        <!-- <OptionTime v-model="time"></OptionTime> -->
      </el-row>
    </el-col>
  </el-row>
@@ -63,6 +68,14 @@
      return res
    }
  },
  watch: {
    'areaStore.area': {
      handler(nV, oV) {
        this.fetchProblemsStatistic()
      },
      deep: true
    }
  },
  methods: {
    fetchProblemsStatistic() {
      const param = unref(this.areaStore.area)
@@ -93,7 +106,8 @@
  },
  mounted() {
    this.echart = echarts.init(this.$refs.echart)
    this.fetchProblemsStatistic()
    // this.area = this.areaStore.area
    // this.fetchProblemsStatistic()
  }
}
</script>
src/views/main/MonitorView.vue
@@ -1,6 +1,6 @@
<template>
  <BaseMap></BaseMap>
  <el-row class="overlay-container" v-if="false">
  <el-row class="overlay-container" v-if="true">
    <el-col :span="7" class="page-right">
      <el-scrollbar height="var(--fy-body-height)" class="p-events-auto">
        <ManagementView></ManagementView>
@@ -8,7 +8,7 @@
    </el-col>
    <el-col :span="17">
      <el-scrollbar class="page-left-top">
        <VisualizationView></VisualizationView>
        <!-- <VisualizationView></VisualizationView> -->
      </el-scrollbar>
      <el-scrollbar class="page-left-bottom p-events-auto">
        <!-- <InspectionView></InspectionView> -->
@@ -23,6 +23,7 @@
  <SupervisionVisual class="supervision-view"></SupervisionVisual>
  <TaskStats class="task-stats"></TaskStats>
  <WorkStream class="work-stream"></WorkStream>
  <!-- <ProblemTrack class="problem-track"></ProblemTrack> -->
</template>
<script setup>
@@ -41,6 +42,8 @@
import ManagementView from '@/views/management/ManagementView.vue'
import StatisticView from '@/views/management/StatisticView.vue'
import VisualizationView from '@/views/visualization/VisualizationView.vue'
import ProblemTrack from '@/views/inspection/problem/ProblemTrack.vue'
import SupervisionVisual from '@/views/visualization/SupervisionVisual.vue'
import WorkStream from '@/views/inspection/WorkStream.vue'
import TaskStats from '@/views/management/TaskStats.vue'
@@ -117,7 +120,7 @@
.task-stats {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
}
.supervision-view {
@@ -126,4 +129,7 @@
  left: 0;
  right: 0;
}
.problem-track {
}
</style>