From ec015f30e83d523cbe0b423bc1ef5c56b3fb1bed Mon Sep 17 00:00:00 2001
From: buaixuexideshitongxue <2936013465@qq.com>
Date: Thu, 26 Feb 2026 15:59:31 +0800
Subject: [PATCH] =?UTF-8?q?fix--=E5=AE=A1=E8=AE=A1=E5=A4=A7=E5=B1=8F?=
=?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=B7=A5=E4=BD=9C=E8=B6=8B=E5=8A=BF=E3=80=81?=
=?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AE=A1=E8=AE=A1=E9=A1=B9=E7=9B=AE=E7=B1=BB?=
=?UTF-8?q?=E5=9E=8B=E3=80=81=E6=B7=BB=E5=8A=A0=E9=97=AE=E9=A2=98=E9=87=91?=
=?UTF-8?q?=E9=A2=9D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/data/aduit.ts | 34 ++++++
src/views/datav/AuditSuper.vue | 192 ++++++++++++++++++++-------------
2 files changed, 151 insertions(+), 75 deletions(-)
diff --git a/src/api/data/aduit.ts b/src/api/data/aduit.ts
index c7c1e40..4289c3a 100644
--- a/src/api/data/aduit.ts
+++ b/src/api/data/aduit.ts
@@ -14,6 +14,19 @@ export function getAuditNegativeVo(times){
}
+/**
+ * 获取一级审计督察地图数据
+ * @param times
+ */
+export function getOverview(body){
+ return request.post({
+ url: `/datav/audit/getOverview`,
+ body
+ })
+}
+
+
+
/**
* 获取一级审计督察地图数据
* @param times
@@ -23,4 +36,25 @@ export function getAuditMap(body){
url: `/datav/audit/getAuditMap`,
body
})
+}
+
+/**
+ * 获取审计项目类型
+ * @param body
+ */
+export function getAuditType(body) {
+ return request.post({
+ url: `/datav/audit/getAuditType`,
+ body
+ });
+}
+
+
+/**
+ * 审计工作趋势
+ */
+export function getAuditTrend(year) {
+ return request.get({
+ url: `/datav/audit/getAuditTrend?year=${year}`
+ });
}
\ No newline at end of file
diff --git a/src/views/datav/AuditSuper.vue b/src/views/datav/AuditSuper.vue
index 543b86b..f4e6c9a 100644
--- a/src/views/datav/AuditSuper.vue
+++ b/src/views/datav/AuditSuper.vue
@@ -65,8 +65,8 @@
style="width: 20%"
/>
@@ -91,7 +91,32 @@
style="height: 300px"
:option="option1"
autoresize
+ ref="auditTrend"
/>
+
+
+
+ {{ selectedYear + " 年" }}
+
+
+
+ {{ year + " 年" }}
+
+
+
+
+
@@ -133,7 +158,13 @@ import vCharts from "vue-echarts";
import changshaMap from "@/assets/data/changsha.json";
import * as echarts from "echarts/core";
import moment from "moment/moment.js";
-import {getWorkDynamics, getAuditNegativeVo, getAuditMap} from "@/api/data/aduit.ts";
+import {
+ getWorkDynamics,
+ getAuditNegativeVo,
+ getAuditMap,
+ getAuditType,
+ getAuditTrend, getOverview
+} from "@/api/data/aduit.ts";
import { workDynamicColorMapping } from "@/enums/workDynamicColorMapping.js";
import { getAuditOverview, getAuditProblems } from '@/api/datav'
import { onMounted } from "vue";
@@ -154,6 +185,7 @@ const overview = ref({
projectNumber: 0,
auditAmount: 0,
auditSjAmount: 0,
+ auditWtAmount: 0,
});
const problemOptions = ref({
@@ -177,13 +209,7 @@ onMounted(() => {
})
function getData() {
- getAuditOverview(time.value).then(data => {
- debugger
- overview.value = data;
- // overview.value.projectNumber = 496;
- // overview.value.auditAmount = 12169.83
- // overview.value.auditSjAmount =1096.89
- });
+ getOverviewFun();
getAuditProblems(time.value).then(data => {
console.log(data)
problemOptions.value.series[0].data = data
@@ -191,6 +217,8 @@ function getData() {
getWorkDynamicsData();
getAuditNegativeVoFun();
getAuditMapData();
+ getAuditTypeFun();
+ getAuditTrendFun();
}
@@ -202,75 +230,69 @@ const getAuditNegativeVoFun =async ()=>{
if(res){
fxData.value=res.fxData;
jsData.value=res.jsData;
+ }
+}
+
+/**
+ * 项目类型
+ * @returns {Promise}
+ */
+const getAuditTypeFun = async ()=>{
+ const body = {
+ beginTime: time.value[0],
+ endTime: time.value[1]
+ }
+ const res = await getAuditType(body);
+ if(res){
option2.value.series[0].data = res.barData;
}
}
+
+/**
+ * 总览数据
+ * @returns {Promise}
+ */
+const getOverviewFun = async()=>{
+ const body = {
+ beginTime: time.value[0],
+ endTime: time.value[1]
+ }
+ overview.value = await getOverview(body);
+}
+
+
+
+const auditTrend = ref(null);
+const currentYear = new Date().getFullYear();
+const years = ref([
+ currentYear.toString(),
+ (currentYear - 1).toString(),
+ (currentYear - 2).toString(),
+]); // 年份列表
+const selectedYear = ref(currentYear); // 当前选中的年份
+// 更换年份事件
+const handleCommand = (year) => {
+ selectedYear.value = year; // 更新当前选中的年份
+ // 这里可以添加获取对应年份数据的逻辑
+ getAuditTrendFun();
+};
+
+/**
+ * 审计工作趋势
+ * @type {Ref, UnwrapRef | string>}
+ */
+const getAuditTrendFun = async (year = selectedYear.value) => {
+ const res = await getAuditTrend(year);
+ // // 更新图表数据
+ option1.value.xAxis.data = res.auditTrend.map((item) => item.name);
+ option1.value.series[0].data = res.auditTrend.map((item) => item.value);
+}
+
+
+
+
const auditSuperRankTab = ref('1');
-// let auditMapData = [
-// {
-// name: "天心分局",
-// reviewOrg: 0,
-// checkPro: 0,
-// rushPro: 0,
-// changed: 0,
-// },
-// {
-// name: "开福分局",
-// reviewOrg: 0,
-// checkPro: 186,
-// rushPro: 0,
-// changed: 137,
-// },
-// {
-// name: "湘江新区",
-// reviewOrg: 0,
-// checkPro: 11,
-// rushPro: 0,
-// changed: 0,
-// },
-// {
-// name: "望城分局",
-// reviewOrg: 0,
-// checkPro: 0,
-// rushPro: 0,
-// changed: 0,
-// },
-// {
-// name: "浏阳市局",
-// reviewOrg: 0,
-// checkPro: 0,
-// rushPro: 0,
-// changed: 0,
-// },
-// {
-// name: "长沙县局",
-// reviewOrg: 0,
-// checkPro: 0,
-// rushPro: 0,
-// changed: 0,
-// },
-// {
-// name: "芙蓉分局",
-// reviewOrg: 0,
-// checkPro: 1,
-// rushPro: 0,
-// changed: 1,
-// },
-// {
-// name: "雨花分局",
-// reviewOrg: 0,
-// checkPro: 240,
-// rushPro: 0,
-// changed: 220,
-// },
-// {
-// name: "宁乡市局",
-// reviewOrg: 0,
-// checkPro: 232,
-// rushPro: 194,
-// changed: 194,
-// },
-// ];
+
const auditMapData = ref([
{
originalName: "浏阳市局",
@@ -710,6 +732,26 @@ const getAuditMapData = async ()=>{
}
}
+
+.test {
+ width: 95px;
+ height: 25px;
+ background: #1c3472;
+}
+
+.gobal-dropdown-container {
+ position: absolute;
+ right: 20px;
+ top: 15px;
+}
+
+.my-gobal-yearselect {
+ font-size: 14px;
+ padding-top: 6px;
+ padding-left: 20px;
+ width: 90px;
+ color: #fff;
+}