Browse Source

各种动画完成

main
parent
commit
2b79c806f9
  1. 7
      src/api/data/aduit.ts
  2. 6
      src/api/screen/subScreen/subOneSupervisionNotify.ts
  3. 56
      src/components/datav/date-picker.vue
  4. 8
      src/components/datav/message.vue
  5. 807
      src/components/negativeInfo/depart-dialog.vue
  6. 524
      src/components/negativeInfo/police-dialog.vue
  7. 15
      src/enums/workDynamicColorMapping.js
  8. 85
      src/views/datav/AuditSuper.vue
  9. 2
      src/views/datav/CaseVerif.vue
  10. 156
      src/views/datav/Lmgz.vue
  11. 431
      src/views/datav/MailVisits.vue
  12. 1
      src/views/datav/RightsComfort.vue
  13. 24
      src/views/datav/SceneInsp.vue
  14. 9
      src/views/datav/subonedatav/SubOneGlobal.vue
  15. 192
      src/views/datav/subonedatav/SubOneMailVisits.vue
  16. 90
      src/views/datav/subonedatav/SubOneSceneInsp.vue

7
src/api/data/aduit.ts

@ -0,0 +1,7 @@
import request from "@/api/request";
export function getWorkDynamics(times) {
return request.get({
url: `/datav/audit/getWorkDynamics?beginTime=${times[0]}&endTime=${times[1]}`
});
}

6
src/api/screen/subScreen/subOneSupervisionNotify.ts

@ -63,5 +63,11 @@ export function getSubOneCheckBeer(departId, times) {
});
}
export function getSubOneWorkDynamics(departId, times) {
return request.get({
url: `/datav/sub1/supervisonNotify/getSubOneWorkDynamics?departId=${departId}&beginTime=${times[0]}&endTime=${times[1]}`
});
}
// export

56
src/components/datav/date-picker.vue

@ -1,44 +1,46 @@
<template>
<div class="datav-col">
<label for="">统计周期</label>
<el-date-picker
v-model="value"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
format="YYYY年MM月DD日"
value-format="YYYY-MM-DD"
:clearable="false"
@change="handleChange"
style="--el-input-bg-color: transparent; box-shadow: none; --el-text-color-regular: #fff; --el-text-color-primary: #fff"
/>
</div>
<div class="datav-col">
<label for="">统计周期</label>
<el-date-picker
v-model="value"
type="daterange"
start-placeholder="开始日期"
range-separator="-"
end-placeholder="结束日期"
format="YYYY年MM月DD日"
value-format="YYYY-MM-DD"
:clearable="false"
@change="handleChange"
unlink-panels
style="--el-input-bg-color: transparent; box-shadow: none; --el-text-color-regular: #fff; --el-text-color-primary: #fff"
/>
</div>
</template>
<script setup>
import moment from 'moment'
const props = defineProps({
modelValue: {
type: Array,
required: true
}
modelValue: {
type: Array,
required: true
}
})
const emit = defineEmits(['update:modelValue', 'change'])
const value = ref(props.modelValue)
function handleChange() {
emit('update:modelValue', value.value)
emit('change', value.value)
emit('update:modelValue', value.value)
emit('change', value.value)
}
</script>
<style lang="scss" scoped>
.datav-col {
font-size: 14px;
text-align: center;
margin-bottom: 16px;
label {
color: #859DEC;
}
font-size: 14px;
text-align: center;
margin-bottom: 16px;
label {
color: #859DEC;
}
}
</style>

8
src/components/datav/message.vue

@ -1,6 +1,6 @@
<!-- Message.vue -->
<template>
<div class="message" :class="type">
<div class="message" :type="type">
<div class="message-title">{{ title }}</div>
<div class="message-content">{{ content }}</div>
<div class="message-footer flex end">
@ -13,7 +13,7 @@
const props = defineProps( {
type: {
type: String,
default: 'success'
default: 'default'
},
title: {
type: String,
@ -36,7 +36,9 @@ const messageClass = computed(() => `message ${props.type}`);
.message {
padding: 10px;
margin-bottom: 10px;
background: linear-gradient(270deg, rgba(16, 151, 255, 0.1) 0%, rgba(0, 55, 236, 0.87) 100%);
&[type=default] {
background: linear-gradient(270deg, rgba(16, 151, 255, 0.1) 0%, rgba(0, 55, 236, 0.87) 100%);
}
&[type=warning] {
background: linear-gradient(270deg, rgba(255, 190, 16, 0.1) 0%, rgba(236, 84, 0, 0.87) 100%);

807
src/components/negativeInfo/depart-dialog.vue

@ -1,334 +1,335 @@
<template>
<el-dialog
title="单位问题详情"
v-model="show"
width="85vw"
top="1vh"
style="margin: 1vh auto"
<el-dialog
title="单位问题详情"
v-model="show"
width="85vw"
top="1vh"
style="margin: 1vh auto"
>
<header class="flex center v-center gap">
<label>统计范围</label>
<div style="width: 320px">
<date-time-range-picker-ext
v-model="time"
@change="getProfileData"
style="width: 300px"
/>
</div>
<el-button type="primary" @click="getProfileData">查询</el-button>
</header>
<el-scrollbar
max-height="calc(98vh - 120px)"
v-loading="loading"
element-loading-text="单位问题详情加载中..."
>
<header class="flex center v-center gap">
<label>统计范围</label>
<div style="width: 320px">
<date-time-range-picker-ext
v-model="time"
@change="getProfileData"
style="width: 300px"
/>
</div>
<el-button type="primary" @click="getProfileData">查询</el-button>
</header>
<el-scrollbar
max-height="calc(98vh - 120px)"
v-loading="loading"
element-loading-text="单位问题详情加载中..."
>
<main>
<el-row class="mb-20">
<el-col :span="8">
<h5>单位情况</h5>
<el-row>
<el-col :span="12">
<div class="row">
<div class="col col-24">
<label>单位名称</label>
<span>{{ departInfo.name }}</span>
</div>
<div class="col col-24">
<label>所长</label>
<span>{{ departInfo.mainRole }}</span>
</div>
<div class="col col-24">
<label>副所长</label>
<span>
<main>
<el-row class="mb-20">
<el-col :span="8">
<h5>单位情况</h5>
<el-row>
<el-col :span="12">
<div class="row">
<div class="col col-24">
<label>单位名称</label>
<span>{{ departInfo.name }}</span>
</div>
<div class="col col-24">
<label>所长</label>
<span>{{ departInfo.mainRole }}</span>
</div>
<div class="col col-24">
<label>副所长</label>
<span>
<span
v-for="item in departInfo.deputyRole"
:key="item"
class="mr-10"
>{{ item }}</span
>{{ item }}</span
>
</span>
</div>
</div>
</el-col>
<el-col :span="12" v-if="departInfo.departImg">
<img
:src="`${BASE_PATH}/file/stream/${departInfo.departImg}`"
style="max-height: 96px"
/>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<description-pair
label1="民警总人数"
label2="问题涉及民警数"
:value1="departInfo.negativePoliceSize"
:value2="departInfo.negativePoliceSize"
size="large"
/>
</el-col>
<el-col :span="12">
<description-pair
label1="协辅警人数"
label2="问题涉及协辅警数"
:value1="departInfo.negativeAuxSize"
:value2="departInfo.negativeAuxSize"
size="large"
/>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5>问题情况</h5>
<el-row
class="flex v-center"
style="height: calc(100% - 76px)"
>
<el-col :span="6" class="text-center">
<div
class="text-primary"
style="font-size: 34px"
>
{{ negativeInfo.size }}
</div>
<div>问题总数</div>
</el-col>
<el-col :span="18">
<el-row>
<el-col
:span="12"
class="mb-20"
v-if="
</div>
</div>
</el-col>
<el-col :span="12" v-if="departInfo.departImg">
<img
:src="`${BASE_PATH}/file/stream/${departInfo.departImg}`"
style="max-height: 96px"
/>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<description-pair
label1="民警总人数"
label2="问题涉及民警数"
:value1="departInfo.negativePoliceSize"
:value2="departInfo.negativePoliceSize"
size="large"
/>
</el-col>
<el-col :span="12">
<description-pair
label1="协辅警人数"
label2="问题涉及协辅警数"
:value1="departInfo.negativeAuxSize"
:value2="departInfo.negativeAuxSize"
size="large"
/>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5>问题情况</h5>
<el-row
class="flex v-center"
style="height: calc(100% - 76px)"
>
<el-col :span="6" class="text-center">
<div
class="text-primary"
style="font-size: 34px"
>
{{ negativeInfo.size }}
</div>
<div>问题总数</div>
</el-col>
<el-col :span="18">
<el-row>
<el-col
:span="12"
class="mb-20"
v-if="
negativeInfo.jcj110BusinessSize ||
negativeInfo.jcj110Size
"
>
<description-pair
label1="110接处警量"
label2="110接处警问题数"
:value1="
>
<description-pair
label1="110接处警量"
label2="110接处警问题数"
:value1="
negativeInfo.jcj110BusinessSize
"
:value2="negativeInfo.jcj110Size"
/>
</el-col>
<el-col
:span="12"
v-if="
:value2="negativeInfo.jcj110Size"
/>
</el-col>
<el-col
:span="12"
v-if="
negativeInfo.jcj122BusinessSize ||
negativeInfo.jcj122Size
"
>
<description-pair
label1="122接处警量"
label2="122接处警问题数"
:value1="
>
<description-pair
label1="122接处警量"
label2="122接处警问题数"
:value1="
negativeInfo.jcj122BusinessSize
"
:value2="negativeInfo.jcj122Size"
/>
</el-col>
<el-col :span="12">
<description-pair
label1="执法办案"
label2="执法办案问题数"
:value1="
:value2="negativeInfo.jcj122Size"
/>
</el-col>
<el-col :span="12">
<description-pair
label1="执法办案"
label2="执法办案问题数"
:value1="
negativeInfo.zfbaBusinessSize
"
:value2="negativeInfo.zfbaSize"
/>
</el-col>
</el-row>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5 style="margin-bottom: 0">风险指数</h5>
<div class="flex center">
<el-progress
type="dashboard"
:percentage="score"
:stroke-width="16"
:width="220"
:color="colors2"
>
<div class="score-progress-body">
<div v-if="score">
<div>
:value2="negativeInfo.zfbaSize"
/>
</el-col>
</el-row>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5 style="margin-bottom: 0">风险指数</h5>
<div class="flex center">
<el-progress
type="dashboard"
:percentage="score"
:stroke-width="16"
:width="220"
:color="colors2"
>
<div class="score-progress-body">
<div v-if="score">
<div>
<span
class="score-progress_score score-theme text-bold"
:type="getType(score)"
>{{ score }}</span
>{{ score }}</span
>
<span></span>
</div>
<div
style="font-size: 14px"
class="mb-16"
>
分险指标值
</div>
</div>
<div
v-else
style="
<span></span>
</div>
<div
style="font-size: 14px"
class="mb-16"
>
分险指标值
</div>
</div>
<div
v-else
style="
font-size: 60px;
line-height: 84px;
color: #999;
"
>
-
</div>
<div
class="score-progress_title score-theme"
:type="getType(score)"
>
{{ getScoreLabel() }}
</div>
</div>
</el-progress>
</div>
</el-col>
</el-row>
<el-row class="mb-20">
<el-col :span="8">
<h5>问题来源占比</h5>
<v-charts
style="height: 320px"
:option="problemSourcesPieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5>业务类型占比</h5>
<v-charts
style="height: 320px"
:option="businessTypePieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5>风险问题构成</h5>
<v-charts
style="height: 320px"
:option="radarOption"
autoresize
/>
</el-col>
</el-row>
<el-row class="mb-20" :gutter="20">
<el-col :span="8">
<h5>个人问题排名</h5>
<el-scrollbar max-height="300px">
<datav-chart-bar
size="small"
:data="policeBarList"
:color="colors"
/>
<el-empty v-if="policeBarList.length === 0" />
</el-scrollbar>
</el-col>
<el-col :span="8">
<h5>突出问题排名</h5>
<el-scrollbar max-height="300px">
<datav-chart-bar
size="small"
:data="problemTypeBarList"
:color="colors"
labelPosition="top"
/>
<el-empty v-if="problemTypeBarList.length === 0" />
</el-scrollbar>
</el-col>
</el-row>
<div style="margin-top: 60px">
<h5>问题变化趋势</h5>
<v-charts
style="height: 320px"
:option="barOption"
autoresize
/>
<div></div>
>
-
</div>
<div
class="score-progress_title score-theme"
:type="getType(score)"
>
{{ getScoreLabel() }}
</div>
</div>
<h5>问题清单</h5>
<el-table :data="negativeList">
<el-table-column label="发现时间" prop="discoveryTime" />
<el-table-column label="问题来源" prop="problemSources" />
<el-table-column label="业务类别" prop="businessTypeName" />
<el-table-column
label="涉及单位"
prop="involveDepartName"
/>
<el-table-column
label="核查情况"
prop="checkStatusName"
width="140"
align="center"
/>
<el-table-column label="操作" width="160">
<template #default="{ row }">
<el-button
type="primary"
link
@click="handleAction(row)"
>查看详情</el-button
>
</template>
</el-table-column>
</el-table>
<div class="flex end mt-8 mb-20">
<el-pagination
@size-change="getNegativeList"
@current-change="getNegativeList"
:page-sizes="[10, 20, 50, 100]"
v-model:page-size="negativeQuery.size"
v-model:current-page="negativeQuery.current"
layout="total, sizes, prev, pager, next"
:total="negativeTotal"
>
</el-pagination>
</div>
</main>
</el-scrollbar>
</el-progress>
</div>
</el-col>
</el-row>
<el-row class="mb-20">
<el-col :span="8">
<h5>问题来源占比</h5>
<v-charts
style="height: 320px"
:option="problemSourcesPieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5>业务类型占比</h5>
<v-charts
style="height: 320px"
:option="businessTypePieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5>风险问题构成</h5>
<v-charts
style="height: 320px"
:option="radarOption"
autoresize
/>
</el-col>
</el-row>
<el-row class="mb-20" :gutter="20">
<el-col :span="8">
<h5>个人问题排名</h5>
<el-scrollbar max-height="300px">
<datav-chart-bar
size="small"
:data="policeBarList"
:color="colors"
/>
<el-empty v-if="policeBarList.length === 0"/>
</el-scrollbar>
</el-col>
<el-col :span="8">
<h5>突出问题排名</h5>
<el-scrollbar max-height="300px">
<datav-chart-bar
size="small"
:data="problemTypeBarList"
:color="colors"
labelPosition="top"
/>
<el-empty v-if="problemTypeBarList.length === 0"/>
</el-scrollbar>
</el-col>
</el-row>
<div style="margin-top: 60px">
<h5>问题变化趋势</h5>
<v-charts
style="height: 320px"
:option="barOption"
autoresize
/>
<div></div>
</div>
<h5>问题清单</h5>
<el-table :data="negativeList">
<el-table-column label="发现时间" prop="discoveryTime"/>
<el-table-column label="问题来源" prop="problemSources"/>
<el-table-column label="业务类别" prop="businessTypeName"/>
<el-table-column
label="涉及单位"
prop="involveDepartName"
/>
<el-table-column
label="核查情况"
prop="checkStatusName"
width="140"
align="center"
/>
<el-table-column label="操作" width="160">
<template #default="{ row }">
<el-button
type="primary"
link
@click="handleAction(row)"
>查看详情
</el-button
>
</template>
</el-table-column>
</el-table>
<div class="flex end mt-8 mb-20">
<el-pagination
@size-change="getNegativeList"
@current-change="getNegativeList"
:page-sizes="[10, 20, 50, 100]"
v-model:page-size="negativeQuery.size"
v-model:current-page="negativeQuery.current"
layout="total, sizes, prev, pager, next"
:total="negativeTotal"
>
</el-pagination>
</div>
</main>
</el-scrollbar>
<negative-dialog
v-model="negativeShow"
:id="activeNegativeId"
@close="negativeShow = false"
/>
<negative-dialog
v-model="negativeShow"
:id="activeNegativeId"
@close="negativeShow = false"
/>
</el-dialog>
</el-dialog>
</template>
<script setup>
import vCharts from "vue-echarts";
import { BASE_PATH } from "@/api/request";
import { InspectCase } from "@/enums/dictEnums";
import {BASE_PATH} from "@/api/request";
import {InspectCase} from "@/enums/dictEnums";
import {
getDepartProfile,
listNegativeMonthly,
getDepartProfile,
listNegativeMonthly,
} from "@/api/sensitivePerception/profileDepart";
import { listNegative } from "@/api/work/negative";
import {listNegative} from "@/api/work/negative";
import moment from "moment";
const props = defineProps({
departId: {
type: String,
},
departId: {
type: String,
},
});
const time = ref([
moment().subtract(12, "month").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
moment().subtract(12, "month").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
]);
const colors = [
{ color: "#5AD8A6", percentage: 40 },
{ color: "#F6BD16", percentage: 60 },
{ color: "#E8684A ", percentage: 80 },
{color: "#5AD8A6", percentage: 40},
{color: "#F6BD16", percentage: 60},
{color: "#E8684A ", percentage: 80},
];
const colors2 = [
{ color: "var(--success-color)", percentage: 60 },
{ color: "#DC6231", percentage: 80 },
{ color: "var(--danger-color)", percentage: 100 },
{color: "var(--success-color)", percentage: 60},
{color: "#DC6231", percentage: 80},
{color: "var(--danger-color)", percentage: 100},
];
const loading = ref(false);
@ -336,7 +337,7 @@ const loading = ref(false);
const departInfo = ref({});
const negativeInfo = ref({});
const negativeQuery = ref({
checkStatusList: [InspectCase.TRUE, InspectCase.TRUE],
checkStatusList: [InspectCase.TRUE, InspectCase.TRUE],
});
const negativeList = ref([]);
const negativeTotal = ref(0);
@ -345,168 +346,176 @@ const problemTypeBarList = ref([]);
const score = ref(0);
async function getProfileData() {
loading.value = true;
negativeQuery.value.involveDepartId = props.departId;
getNegativeList();
const data = await getDepartProfile(props.departId, {
beginTime: time.value.length ? time.value[0] : "",
endTime: time.value.length ? time.value[1] : "",
});
score.value = Math.round(data.score);
console.log(data.expression);
console.log(data.remarks);
departInfo.value = data.departInfo;
negativeInfo.value = data.negativeInfo;
problemSourcesPieOptions.value.series[0].data = data.problemSourcesList;
businessTypePieOptions.value.series[0].data = data.businessTypeList;
loading.value = true;
negativeQuery.value.involveDepartId = props.departId;
getNegativeList();
const data = await getDepartProfile(props.departId, {
beginTime: time.value.length ? time.value[0] : "",
endTime: time.value.length ? time.value[1] : "",
});
score.value = Math.round(data.score);
console.log(data.expression);
console.log(data.remarks);
departInfo.value = data.departInfo;
negativeInfo.value = data.negativeInfo;
problemSourcesPieOptions.value.series[0].data = data.problemSourcesList;
businessTypePieOptions.value.series[0].data = data.businessTypeList;
policeBarList.value = data.policeBarList;
policeBarList.value = data.policeBarList;
radarOption.value.radar.indicator = data.problemTypeRadarIndicator;
radarOption.value.series[0].data[0].value = data.problemTypeRadarData;
radarOption.value.radar.indicator = data.problemTypeRadarIndicator;
radarOption.value.series[0].data[0].value = data.problemTypeRadarData;
problemTypeBarList.value = data.problemTypeBarList;
loading.value = false;
problemTypeBarList.value = data.problemTypeBarList;
loading.value = false;
}
const barOption = ref({
xAxis: {
type: "category",
data: [],
},
yAxis: {
type: "value",
xAxis: {
type: "category",
data: [],
},
yAxis: {
type: "value",
},
series: [
{
data: [],
type: "bar",
color: "#5B8FF9 ",
},
series: [
{
data: [],
type: "bar",
color: "#5B8FF9 ",
},
],
],
});
watch(
() => props.departId,
() => {
getProfileData();
listNegativeMonthly(props.departId).then((data) => {
barOption.value.xAxis.data = data.months;
barOption.value.series[0].data = data.values;
});
getProfileData();
listNegativeMonthly(props.departId).then((data) => {
barOption.value.xAxis.data = data.months;
barOption.value.series[0].data = data.values;
});
}
);
function getNegativeList() {
listNegative(negativeQuery.value).then((data) => {
negativeList.value = data.records;
negativeTotal.value = data.total;
});
listNegative(negativeQuery.value).then((data) => {
negativeList.value = data.records;
negativeTotal.value = data.total;
});
}
const radarOption = ref({
radar: {
indicator: [],
},
series: [
radar: {
indicator: [],
},
series: [
{
type: "radar",
data: [
{
type: "radar",
data: [
{
value: [],
},
],
label: {
show: true,
},
value: [],
},
],
],
label: {
show: true,
},
},
],
});
const problemSourcesPieOptions = ref({
tooltip: {
trigger: "item",
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
],
],
});
const businessTypePieOptions = ref({
tooltip: {
trigger: "item",
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
],
],
});
const policeBarList = ref([]);
function getType(val) {
if (val < 60) {
return "success";
}
if (val < 80) {
return "warning";
}
return "danger";
if (val < 60) {
return "success";
}
if (val < 80) {
return "warning";
}
return "danger";
}
function getScoreLabel() {
if (score.value === 0) {
return "无法预测";
}
if (score.value < 60) {
return "低风险";
}
if (score.value < 80) {
return "中风险";
}
return "高风险";
if (score.value === 0) {
return "无法预测";
}
if (score.value < 60) {
return "低风险";
}
if (score.value < 80) {
return "中风险";
}
return "高风险";
}
const negativeShow = ref(false);
const activeNegativeId = ref("");
function handleAction(row) {
negativeShow.value = true;
activeNegativeId.value = row.id;
negativeShow.value = true;
activeNegativeId.value = row.id;
}
</script>
<style lang="scss" scoped>
main {
overflow: hidden;
overflow: hidden;
}
.col {
--label-width: 60px;
--label-width: 60px;
}
.score-progress-body {
text-align: center;
font-size: 18px;
.score-progress_score {
font-size: 60px;
line-height: 84px;
}
.score-progress_title {
font-size: 26px;
line-height: 22px;
}
text-align: center;
font-size: 18px;
.score-progress_score {
font-size: 60px;
line-height: 84px;
}
.score-progress_title {
font-size: 26px;
line-height: 22px;
}
}
.score-theme {
&[type="success"] {
color: var(--success-color);
}
&[type="warning"] {
color: #e87749;
}
&[type="danger"] {
color: var(--danger-color);
}
&[type="success"] {
color: var(--success-color);
}
&[type="warning"] {
color: #e87749;
}
&[type="danger"] {
color: var(--danger-color);
}
}
</style>

524
src/components/negativeInfo/police-dialog.vue

@ -0,0 +1,524 @@
<template>
<el-dialog
title="个人问题详情"
v-model="show"
width="85vw"
top="1vh"
style="margin: 1vh auto"
>
<header class="flex center v-center gap">
<label>统计范围</label>
<div style="width: 320px">
<date-time-range-picker-ext
v-model="time"
style="width: 300px"
@change="getProfileData"
/>
</div>
<el-button type="primary" @click="getProfileData">查询</el-button>
</header>
<el-scrollbar
max-height="calc(98vh - 120px)"
v-loading="loading"
element-loading-text="个人问题详情加载中..."
>
<main>
<el-row class="mb-20">
<el-col :span="8">
<h5>民警基本情况</h5>
<el-row>
<el-col :span="6">
<img v-if="policeInfo.avatarUrl" :src="`${BASE_PATH}/file/stream/${policeInfo.avatarUrl}`"
class="police-avatar" style="width: 94px"/>
<icon name="local-icon-police" :size="120" v-else/>
</el-col>
<el-col :span="18">
<div class="row">
<div class="col col-12">
<label>姓名</label>
<span>{{ policeInfo.name }}</span>
</div>
<div class="col col-12">
<label>性别</label>
<span>{{
getGenderFromIdCode(
policeInfo.idCode
)
}}</span>
</div>
<div class="col col-24">
<label>所属单位</label>
<span>
<span
>{{
activeRow.parentDepartName
? activeRow.parentDepartName +
"/"
: activeRow.parentDepartName
}}{{
activeRow.departName
}}</span
>
</span>
</div>
<div class="col col-12">
<label>警号</label>
<span>{{ policeInfo.empNo }}</span>
</div>
<div class="col col-12">
<label>身份证号</label>
<span>{{ policeInfo.idCode }}</span>
</div>
<div class="col col-12">
<label>入职时间</label>
<span>{{
policeInfo.employmentDate || "/"
}}</span>
</div>
<div class="col col-12">
<label>手机号</label>
<span>{{
policeInfo.mobile || "/"
}}</span>
</div>
</div>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5>问题情况</h5>
<el-row
class="flex v-center"
style="height: calc(100% - 76px)"
>
<el-col :span="6" class="text-center">
<div
class="text-primary"
style="font-size: 34px"
>
{{ negativeInfo.size }}
</div>
<div class="mb-10">问题总数</div>
<div
class="text-danger"
style="font-size: 34px"
>
{{ negativeInfo.score }}
</div>
<div>风险值</div>
</el-col>
<el-col :span="18">
<el-row>
<el-col
:span="12"
class="mb-20"
v-if="
negativeInfo.jcj110BusinessSize ||
negativeInfo.jcj110Size
"
>
<description-pair
label="110接处警"
label1="量"
label2="问题数"
:value1="
negativeInfo.jcj110BusinessSize
"
:value2="negativeInfo.jcj110Size"
/>
</el-col>
<el-col
:span="12"
v-if="
negativeInfo.jcj122BusinessSize ||
negativeInfo.jcj122Size
"
>
<description-pair
label="122接处警"
label1="量"
label2="问题数"
:value1="
negativeInfo.jcj122BusinessSize
"
:value2="negativeInfo.jcj122Size"
/>
</el-col>
<el-col :span="12">
<description-pair
label="执法办案"
label2="问题数"
:value1="
negativeInfo.zfbaBusinessSize
"
:value2="negativeInfo.zfbaSize"
/>
</el-col>
</el-row>
</el-col>
</el-row>
</el-col>
<el-col :span="8">
<h5 style="margin-bottom: 0">风险指数</h5>
<div class="flex center">
<el-progress
type="dashboard"
:percentage="score"
:stroke-width="16"
:width="220"
:color="colors"
>
<div class="score-progress-body">
<div v-if="score">
<div>
<span
class="score-progress_score score-theme text-bold"
:type="getType(score)"
>{{ score }}</span
>
<span></span>
</div>
<div
style="font-size: 14px"
class="mb-16"
>
风险指数
</div>
</div>
<div
v-else
style="
font-size: 60px;
line-height: 84px;
color: #999;
"
>
-
</div>
<div
class="score-progress_title score-theme"
:type="getType(score)"
>
{{ getScoreLabel() }}
</div>
</div>
</el-progress>
</div>
</el-col>
</el-row>
<el-row class="mb-20">
<el-col :span="8">
<h5>问题来源占比</h5>
<v-charts
style="height: 320px"
:option="problemSourcesPieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5>问题类型占比</h5>
<v-charts
style="height: 320px"
:option="problemTypePieOptions"
autoresize
/>
</el-col>
<el-col :span="8">
<h5 style="margin-bottom: 0">风险构成</h5>
<div class="flex center">
<v-charts
style="height: 340px; width: 280px"
:option="radarOption"
autoresize
/>
</div>
</el-col>
</el-row>
<h5>问题变化趋势</h5>
<v-charts
style="height: 320px"
:option="barOption"
autoresize
/>
<div></div>
<h5>问题清单</h5>
<el-table :data="negativeList">
<el-table-column label="发现时间" prop="discoveryTime"/>
<el-table-column label="问题来源" prop="problemSources"/>
<el-table-column label="业务类别" prop="businessTypeName"/>
<el-table-column
label="涉及单位"
prop="involveDepartName"
/>
<el-table-column
label="核查情况"
prop="checkStatusName"
width="140"
align="center"
/>
<el-table-column label="操作" width="160">
<template #default="{ row }">
<el-button
type="primary"
link
@click="handleAction(row)"
>查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<div class="flex end mt-8">
<el-pagination
@size-change="getNegativeList"
@current-change="getNegativeList"
:current-page="negativeQuery.current"
:page-sizes="[10, 20, 50]"
:page-size="negativeQuery.size"
v-model:current-page="negativeQuery.current"
layout="total, sizes, prev, pager, next"
:total="negativeTotal"
>
</el-pagination>
</div>
</main>
</el-scrollbar>
</el-dialog>
</template>
<script setup>
import vCharts from "vue-echarts";
import {BASE_PATH} from "@/api/request";
import {InspectCase} from "@/enums/dictEnums";
import {
getDepartProfile,
listNegativeMonthly,
} from "@/api/sensitivePerception/profileDepart";
import {listNegative} from "@/api/work/negative";
import moment from "moment";
import {getGenderFromIdCode} from "@/utils/util.ts";
import {getPoliceProfile, listNegativeByPoliceIdCode} from "@/api/sensitivePerception/profilePolice.ts";
const props = defineProps({
empNo: {
type: String,
default: 0,
},
});
const activeRow = ref({});
const policeInfo = ref({});
const time = ref([
moment().subtract(12, "month").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
]);
const colors = [
{color: "#5AD8A6", percentage: 40},
{color: "#F6BD16", percentage: 60},
{color: "#E8684A ", percentage: 80},
];
const colors2 = [
{color: "var(--success-color)", percentage: 60},
{color: "#DC6231", percentage: 80},
{color: "var(--danger-color)", percentage: 100},
];
const loading = ref(false);
const departInfo = ref({});
const negativeInfo = ref({});
const negativeQuery = ref({
checkStatusList: [InspectCase.TRUE, InspectCase.TRUE],
});
const negativeList = ref([]);
const negativeTotal = ref(0);
const problemTypeBarList = ref([]);
const score = ref(0);
const problemTypePieOptions = ref({
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
],
});
async function getProfileData() {
loading.value = true;
negativeQuery.value.idCode = props.empNo;
getNegativeList();
const data = await getPoliceProfile(props.empNo, {
beginTime: time.value.length ? time.value[0] : "",
endTime: time.value.length ? time.value[1] : "",
});
score.value = Math.round(data.score);
console.log(data.expression);
console.log(data.remarks);
policeInfo.value = data.policeInfo;
negativeInfo.value = data.negativeInfo;
problemSourcesPieOptions.value.series[0].data = data.problemSourcesList;
problemTypePieOptions.value.series[0].data = data.problemTypeList;
radarOption.value.radar.indicator = data.businessTypeRadarIndicator;
radarOption.value.series[0].data[0].value = data.businessTypeScoreRadarData;
radarOption.value.series[0].data[1].value = data.businessTypeWeightRadarData;
loading.value = false;
}
function getNegativeList() {
if (time.value.length === 2) {
negativeQuery.value.beginTime = time.value[0];
negativeQuery.value.endTime = time.value[1];
}
listNegativeByPoliceIdCode(
props.empNo,
negativeQuery.value
).then((data) => {
negativeList.value = data.records;
negativeTotal.value = data.total;
});
}
const barOption = ref({
xAxis: {
type: "category",
data: [],
},
yAxis: {
type: "value",
},
series: [
{
data: [],
type: "bar",
color: "#5B8FF9 ",
},
],
});
watch(
() => props.empNo,
() => {
getProfileData();
listNegativeMonthly(props.empNo).then((data) => {
barOption.value.xAxis.data = data.months;
barOption.value.series[0].data = data.values;
});
});
const radarOption = ref({
radar: {
indicator: [],
},
series: [
{
type: "radar",
data: [
{
value: [],
},
{
value: [],
},
],
label: {
show: true,
},
},
],
});
const problemSourcesPieOptions = ref({
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
],
});
const businessTypePieOptions = ref({
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
radius: ["40%", "70%"],
data: [],
},
],
});
const policeBarList = ref([]);
function getType(val) {
if (val < 60) {
return "success";
}
if (val < 80) {
return "warning";
}
return "danger";
}
function getScoreLabel() {
if (score.value === 0) {
return "无法预测";
}
if (score.value < 60) {
return "低风险";
}
if (score.value < 80) {
return "中风险";
}
return "高风险";
}
const negativeShow = ref(false);
const activeNegativeId = ref("");
function handleAction(row) {
negativeShow.value = true;
activeNegativeId.value = row.id;
}
</script>
<style lang="scss" scoped>
main {
overflow: hidden;
}
.col {
--label-width: 60px;
}
.score-progress-body {
text-align: center;
font-size: 18px;
.score-progress_score {
font-size: 60px;
line-height: 84px;
}
.score-progress_title {
font-size: 26px;
line-height: 22px;
}
}
.score-theme {
&[type="success"] {
color: var(--success-color);
}
&[type="warning"] {
color: #e87749;
}
&[type="danger"] {
color: var(--danger-color);
}
}
</style>

15
src/enums/workDynamicColorMapping.js

@ -0,0 +1,15 @@
export const colorMapping = {
'工作部署': 'success',
'督察通报': 'warning',
'工作简报': '',
};
export function workDynamicColorMapping(backendData) {
return backendData.map(item => {
const mappedName = colorMapping[item.workType] || "default";
return {
...item,
type: mappedName,
};
});
}

85
src/views/datav/AuditSuper.vue

@ -34,7 +34,6 @@
</datav-card>
</el-col>
<el-col :span="12">
<datav-date-picker v-model="time"/>
<div class="flex gap-42">
@ -79,7 +78,6 @@
/>
</datav-card>
</el-col>
<el-col :span="6">
<datav-card title="审计项目类型">
@ -115,37 +113,15 @@
</datav-card>
<datav-card title="审计工作动态">
<el-scrollbar height="470px">
<div class="message">
<div class="message-title">审计公示</div>
<div class="message-content">
食药环支队
警务督察支队审计处派出审计组对食药环支队2022年1月至2023年12月办理的刑事行政案件执法活动财物管理情况进行了审计形成了食药环支队2022年1月至2023年12月执法活动财物管理情况专项审计报告
</div>
<div class="message-footer flex end">
<span>2024年8月26日</span>
</div>
</div>
<div class="message" type="warning">
<div class="message-title">审计公示</div>
<div class="message-content">
刑侦支队
警务督察支队审计处派出审计组对刑侦支队2022年1月至2023年12月办理的刑事行政案件执法活动财物管理情况进行了审计形成了刑侦支队2022年1月至2023年12月执法活动财物管理情况专项审计报告
</div>
<div class="message-footer flex end">
<span>2024年8月26日</span>
</div>
</div>
<div class="message" type="success">
<div class="message-title">审计公示</div>
<div class="message-content">高新分局
警务督察支队审计处派出审计组对高新分局2022年1月至2023年12月办理的刑事行政案件执法活动财物管理情况进行了审计形成了高新分局2022年1月至2023年12月执法活动财物管理情况专项审计报告
</div>
<div class="message-footer flex end">
<span>2024年8月26日</span>
</div>
</div>
<datav-message
v-for="(msg, index) in messages"
:key="index"
:type="msg.type"
:title="msg.workType"
:content="msg.contentTxt"
:date="msg.releaseTime"
/>
</el-scrollbar>
</datav-card>
</el-col>
@ -161,36 +137,29 @@ 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} from "@/api/data/aduit.ts";
import {workDynamicColorMapping} from "@/enums/workDynamicColorMapping.js";
const messages = ref([]);
const time = ref([
moment().subtract(1, "year").format("YYYY-MM-DD"),
moment().format("YYYY-MM-DD"),
]);
const temp = ref({
tempTotal: 0,
tempTotalMon: 0,
tempReviewMon: 0,
tempCheckPro: 0,
tempPro:0
tempPro: 0
})
setTimeout(() => {
temp.value={
temp.value = {
tempTotal: 462,
tempTotalMon: 79224.59,
tempReviewMon: 3544.01,
tempCheckPro: 1192,
tempPro:389
tempPro: 389
}
}, 1000);
let gobalTempMapVoList = [
{
"name": "天心分局",
@ -257,7 +226,6 @@ let gobalTempMapVoList = [
}
];
echarts.registerMap("changsha", changshaMap);
const option = ref({
geo: {
@ -342,7 +310,6 @@ const option = ref({
}
],
})
const option1 = ref({
xAxis: {
type: "category",
@ -394,7 +361,6 @@ const option1 = ref({
},
],
});
const data1 = [
{
label: "芙蓉分局",
@ -451,7 +417,6 @@ const data1 = [
// console.log(item.label);
// });
// }, 1000);
const data2 = [
{
name: "开福分局",
@ -482,7 +447,6 @@ const data2 = [
value: 6221
},
];
const option2 = {
series: [
{
@ -505,7 +469,6 @@ const option2 = {
trigger: "item",
},
};
const option3 = {
series: [
{
@ -530,8 +493,6 @@ const option3 = {
trigger: "item",
},
};
const option4 = {
series: [
{
@ -555,8 +516,6 @@ const option4 = {
trigger: "item",
},
};
const option5 = {
series: [
{
@ -577,8 +536,6 @@ const option5 = {
trigger: "item",
},
};
const option22 = {
series: [
{
@ -598,8 +555,6 @@ const option22 = {
trigger: "item",
},
};
const colors = [
{
// 绿
@ -619,6 +574,18 @@ const colors = [
},
];
const getWorkDynamicsData = async () => {
const res = await getWorkDynamics(time.value);
const colorNewsVoList = workDynamicColorMapping(res.newsVoList);
messages.value = colorNewsVoList;
}
const getData = () => {
getWorkDynamicsData();
}
onMounted(() => {
getData();
});
</script>

2
src/views/datav/CaseVerif.vue

@ -704,7 +704,7 @@ const caseVerifJbclSituationAnimation = () => {
temp?.dispatchAction({type: 'showTip', seriesIndex: 0, dataIndex: randomNum});
}
caseVerifJbclSituationIntervalId = setInterval(caseVerifJbclSituationAnimation, 2000);
// region
// endregion
// region ||

156
src/views/datav/Lmgz.vue

@ -9,8 +9,8 @@
<span style="font-size: 22px">执法监督灵敏感知体系</span>
</div>
<div class="datav-col">
<datav-date-picker v-model="time"/>
</div>
<datav-date-picker v-model="time"/>
</div>
<div class="flex gap-42">
<datav-statistic
:value="statisticsTotal.aTotal"
@ -61,6 +61,8 @@
</div>
<datav-tabs
type="bottom-button"
ref="rxsjTabs"
v-model="selectedFxsjTabs"
>
<datav-tab-item label="高业务量" name="1">
<el-scrollbar height="200px">
@ -108,8 +110,10 @@
</div>
<datav-tabs
type="bottom-button"
ref="pcsTabs"
v-model="selectedPcsTabs"
>
<datav-tab-item label="高业务量" name="4">
<datav-tab-item label="高业务量" name="1">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="pcsRiskList"
@ -118,7 +122,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="中业务量" name="5">
<datav-tab-item label="中业务量" name="2">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="orgNegativeList"
@ -128,7 +132,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="低业务量" name="6">
<datav-tab-item label="低业务量" name="3">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="orgRateList"
@ -155,8 +159,10 @@
</div>
<datav-tabs
type="bottom-button"
ref="jjddTabs"
v-model="selectedJjddTabs"
>
<datav-tab-item label="高业务量" name="7">
<datav-tab-item label="高业务量" name="1">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="carRiskList"
@ -165,7 +171,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="中业务量" name="8">
<datav-tab-item label="中业务量" name="2">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="orgCarNegativeList"
@ -175,7 +181,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="低业务量" name="9">
<datav-tab-item label="低业务量" name="3">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="orgCarRateList"
@ -204,8 +210,10 @@
</div>
<datav-tabs
type="bottom-button"
ref="ldTabs"
v-model="selectedLdTabs"
>
<datav-tab-item label="问题数" name="14">
<datav-tab-item label="问题数" name="1">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="leaderRiskList"
@ -214,7 +222,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="问题涉及人数" name="15">
<datav-tab-item label="问题涉及人数" name="2">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="leaderNegativeList"
@ -240,8 +248,10 @@
</div>
<datav-tabs
type="bottom-button"
ref="mjTabs"
v-model="selectedMjTabs"
>
<datav-tab-item label="问题数" name="10">
<datav-tab-item label="问题数" name="1">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="policeANegativeList"
@ -250,7 +260,7 @@
/>
</el-scrollbar>
</datav-tab-item>
<datav-tab-item label="问题发生率" name="11">
<datav-tab-item label="问题发生率" name="2">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="policeARiskList"
@ -276,8 +286,10 @@
</div>
<datav-tabs
type="bottom-button"
ref="xfjTabs"
v-model="selectedXfjTabs"
>
<datav-tab-item label="问题数" name="12">
<datav-tab-item label="问题数" name="1">
<el-scrollbar height="200px">
<datav-chart-bar-fixbug
:data="policeBRiskList"
@ -286,7 +298,6 @@
/>
</el-scrollbar>
</datav-tab-item>
</datav-tabs>
</datav-card>
</el-col>
@ -315,6 +326,7 @@ import {
orgCarRateStatistics
} from '@/api/data/risk';
import moment from "moment";
let selectedMetric = ref('problemNumber');
let selectedMetricPCS = ref('problemNumber');
let selectedMetricJJDD = ref('problemNumber');
@ -470,7 +482,6 @@ const getLeaderNegativeData = (type) => {
})
}
const getAreaRateData = (type) => {
areaRateStatistics(time.value, type).then(res => {
areaRateList.value = eachData(res)
@ -514,27 +525,142 @@ const colors = [
percentage: 40,
},
];
// region
const rxsjTabs = ref(null);
const pcsTabs = ref(null);
const jjddTabs = ref(null);
const ldTabs = ref(null);
const mjTabs = ref(null);
const xfjTabs = ref(null);
const selectedFxsjTabs = ref("1");
const selectedPcsTabs = ref("1");
const selectedJjddTabs = ref("1");
const selectedLdTabs = ref("1");
const selectedMjTabs = ref("1");
const selectedXfjTabs = ref("1");
let rxsjTabsIntervalId;
let pcsTabsIntervalId;
let jjddTabsIntervalId;
let ldTabsIntervalId;
let mjTabsIntervalId;
let xfjTabsIntervalId;
const rxsjTabsAnimation = () => {
selectedFxsjTabs.value = (parseInt(selectedFxsjTabs.value) % 3 + 1).toString();
};
rxsjTabsIntervalId = setInterval(rxsjTabsAnimation, 3000);
const pcsTabsAnimation = () => {
selectedPcsTabs.value = (parseInt(selectedPcsTabs.value) % 3 + 1).toString();
};
pcsTabsIntervalId = setInterval(pcsTabsAnimation, 3000);
const jjddTabsAnimation = () => {
selectedJjddTabs.value = (parseInt(selectedJjddTabs.value) % 3 + 1).toString();
};
jjddTabsIntervalId = setInterval(jjddTabsAnimation, 3000);
const ldTabsAnimation = () => {
selectedLdTabs.value = (parseInt(selectedLdTabs.value) % 2 + 1).toString();
};
ldTabsIntervalId = setInterval(ldTabsAnimation, 3000);
const mjTabsAnimation = () => {
selectedMjTabs.value = (parseInt(selectedMjTabs.value) % 2 + 1).toString();
};
mjTabsIntervalId = setInterval(mjTabsAnimation, 3000);
// endregion
// region
onMounted(() => {
setupEventListeners();
});
const setupEventListeners = () => {
rxsjTabsAnimationStop();
pcsTabsAnimationStop();
jjddTabsAnimationStop();
ldTabsAnimationStop();
mjTabsAnimationStop();
};
const rxsjTabsAnimationStop = () => {
const temp = rxsjTabs.value?.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(rxsjTabsIntervalId)
});
temp.addEventListener('mouseleave', () => {
rxsjTabsIntervalId = setInterval(rxsjTabsAnimation, 3000);
});
}
const pcsTabsAnimationStop = () => {
const temp = pcsTabs.value?.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(pcsTabsIntervalId)
});
temp.addEventListener('mouseleave', () => {
pcsTabsIntervalId = setInterval(pcsTabsAnimation, 3000);
});
}
const jjddTabsAnimationStop = () => {
const temp = jjddTabs.value?.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(jjddTabsIntervalId)
});
temp.addEventListener('mouseleave', () => {
jjddTabsIntervalId = setInterval(jjddTabsAnimation, 3000);
});
}
const ldTabsAnimationStop = () => {
const temp = ldTabs.value?.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(ldTabsIntervalId)
});
temp.addEventListener('mouseleave', () => {
ldTabsIntervalId = setInterval(ldTabsAnimation, 3000);
});
}
const mjTabsAnimationStop = () => {
const temp = mjTabs.value?.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(mjTabsIntervalId)
});
temp.addEventListener('mouseleave', () => {
mjTabsIntervalId = setInterval(mjTabsAnimation, 3000);
});
}
// endregion
</script>
<style lang="scss" scoped>
@import "@/style/datav.scss";
.card-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px;
}
.card-title {
font-size: 23px;
font-weight: bold;
}
.select-container {
width: 150px;
margin-left: auto;
}
:deep(.el-select__wrapper) {
background-color: #041a75;
box-shadow: #0a113b 0px 0px 0px 1px;
}
:deep(.el-select__placeholder ) {
color: #fff;
}

431
src/views/datav/MailVisits.vue

@ -10,7 +10,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.firstMail }}
{{ currentLeftOverview.firstMail }}
</div>
<div class="descriptions_label">
初信初访
@ -20,7 +20,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.repeatMail }}
{{ currentLeftOverview.repeatMail }}
</div>
<div class="descriptions_label">
重复信访
@ -30,7 +30,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.leaderMail }}
{{ currentLeftOverview.leaderMail }}
</div>
<div class="descriptions_label">
领导接访数
@ -39,10 +39,10 @@
</el-col>
</el-row>
<datav-card>
<datav-tabs v-model="activeTab">
<datav-tabs v-model="activeTab" ref="firstAndRepeat">
<datav-tab-item label="分县市局" name="1">
<datav-tabs
v-model="activeMailTab"
v-model="fxsjFirstAndRepeatTab"
type="bottom-button"
>
<datav-tab-item label="初信初访" name="1">
@ -169,10 +169,11 @@
:option="option"
autoresize
@click="handleClick"
ref="mailMap"
/>
<datav-card title="信访趋势">
<datav-tabs v-model="activeMailTrend" @change="handleTabChange">
<datav-card title="信访趋势" ref="mailTrendCard">
<datav-tabs v-model="mailTrendTabs" @change="handleTabChange">
<datav-tab-item label="国家信访" name="1">
<v-charts
style="width: 105%; height: 300px;"
@ -254,10 +255,11 @@
</el-col>
</el-row>
<datav-card>
<datav-tabs v-model="activeTabRight">
<datav-tabs v-model="activeTabRight" ref="entanglement">
<datav-tab-item label="分县市局" name="1">
<datav-tabs
type="bottom-button"
v-model="fxsjEntanglementTab"
>
<datav-tab-item label="领导督办" name="1">
<el-scrollbar height="300px">
@ -364,12 +366,12 @@ import {
//region
let timer;
const router = useRouter();
const activeTab = ref("1");
const bwzdActiveTab = ref("1"); // tab
const activeMailTrend = ref("1"); // 访tab
const activeMailTab = ref("1");
const activeTabRight = ref("1");
const overview = ref({
totalMail: 0,
@ -447,141 +449,19 @@ const leaderViewColors = [
},
];
//endregion
// region
const getFirstAndRepeatMailRank = async (timeValue = time.value) => {
const res = await getFirstAndRepeatMail(timeValue)
fxjsFirstAndRepeatOverview.value = res.fxjsFirstAndRepeatOverview;
bwzdFirstAndRepeatOverview.value = res.bwzdFirstAndRepeatOverview
fxsjFirstMailList.value = res.fxsjFirstRankList;
fxsjRepeatMailList.value = res.fxsjRepeatRankList;
fxsjLeaderViewMailList.value = res.fxsjLeaderViewRankList;
bwzdFirstMailList.value = res.bwzdFirstRankList;
bwzdRepeatMailList.value = res.bwzdRepeatRankList;
bwzdLeaderViewMailList.value = res.bwzdLeaderViewRankList;
}
const getOverview = async (timeValue = time.value) => {
const res = await getAllMailCount(timeValue)
overview.value = res.overview;
}
const getTrend = async (year = selectedYear.value) => {
const res = await getMailTrend(year);
const policeList = res.policeList;
const commissionerList = res.commissionerList;
const numberList = res.numberList;
const countryList = res.countryList;
const policecategories = policeList.map(item => item.name);
const policevalues = policeList.map(item => item.value);
const managecategories = commissionerList.map(item => item.name);
const managevalues = commissionerList.map(item => item.value);
const numbercategories = numberList.map(item => item.name);
const numbervalues = numberList.map(item => item.value);
const countrycategories = countryList.map(item => item.name);
const countryvalues = countryList.map(item => item.value);
//
policeTrend.value.xAxis.data = policecategories;
policeTrend.value.series[0].data = policevalues;
manageTrend.value.xAxis.data = managecategories;
manageTrend.value.series[0].data = managevalues;
numberTrend.value.xAxis.data = numbercategories;
numberTrend.value.series[0].data = numbervalues;
countryTrend.value.xAxis.data = countrycategories;
countryTrend.value.series[0].data = countryvalues;
}
const getEntangleMassRank = async (timeValue = time.value) => {
const res = await getEntanglementAndMassMail(timeValue)
fxsjMailEntanglementMassOverview.value = res.fxsjMailEntanglementMassOverview;
bwzdMailEntanglementMassOverview.value = res.bwzdMailEntanglementMassOverview;
fxsjEntanglementMailList.value = res.fxsjEntanglementList;
fxsjMassMailList.value = res.fxsjMassList;
fxsjLeaderReviewMailList.value = res.fxsjLeaderReviewList;
bwzdLeaderReviewMailList.value = res.bwzdLeaderReviewList;
bwzdEntanglementMailList.value = res.bwzdEntanglementList;
bwzdMassMailList.value = res.bwzdMassList;
}
const mailMapIconList = ref([]);
const getMailMapIconList = async (timeValue = time.value) => {
const res = await getMailMapIcon(timeValue);
const mappedData = res.mailMapIconList.map(item => {
let name;
switch (item.name) {
case '长沙县局':
name = '长沙县';
break;
case '芙蓉分局':
name = '芙蓉区';
break;
case '天心分局':
name = '天心区';
break;
case '岳麓分局':
name = '岳麓区';
break;
case '开福分局':
name = '开福区';
break;
case '雨花分局':
name = '雨花区';
break;
case '望城分局':
name = '望城区';
break;
case '宁乡市局':
name = '宁乡市';
break;
case '浏阳市局':
name = '浏阳市';
break;
case '高新分局':
name = '高新区';
break;
default:
name = item.name;
break;
}
return {
...item,
originalName: item.name, //
name: name,
value: item.total,
};
});
mailMapIconList.value = mappedData;
console.log(mailMapIconList)
const total = mappedData.reduce((sum, item) => sum + Number(item.value), 0);
const avg = total / mappedData.length; //
const range30Percent = avg * 0.3 //
option.value.series[0].data = mappedData;
option.value.visualMap.pieces = [
{gte: 0, lte: avg - range30Percent, label: "低于平均问题30%", color: "#4987F6"},
{gte: avg - range30Percent, lte: avg + range30Percent + 0.1, label: `平均问题上下浮动30%内`, color: "#F6A149"},
{gte: avg + range30Percent, label: "高于平均问题30%", color: "#D34343"},
];
}
const getData = () => {
getFirstAndRepeatMailRank();
getOverview();
getMailMapIconList()
getTrend();
getEntangleMassRank();
}
const currentOverview = computed(() => {
return activeTab.value === '1' ? fxjsFirstAndRepeatOverview.value : bwzdFirstAndRepeatOverview.value;
});
const currentRightOverview = computed(() => {
return activeTabRight.value === '1' ? fxsjMailEntanglementMassOverview.value : bwzdMailEntanglementMassOverview.value;
});
// endregion
const fxsjFirstAndRepeatTab = ref("1");
const firstAndRepeat = ref(null)
const mailMap = ref(null);
const mailTrendTabs = ref("1");
const mailTrendCard = ref(null)
const fxsjEntanglementTab = ref("1");
const entanglement = ref(null)
let fxsjFirstAndRepeatIntervalId;
let fxsjEntanglementIntervalId;
let mailTrendIntervalId;
let mailMapIntervalId;
//endregion
// region
echarts.registerMap("changsha", changshaMap);
@ -591,7 +471,7 @@ const gobalTempMapVoList = [
"total": 0,
"countryTotal": 0,
"policeTotal": 0,
"commissionerTotal":0,
"commissionerTotal": 0,
"numTotal": 0,
}
];
@ -603,6 +483,7 @@ const option = ref({
},
tooltip: {
trigger: 'item',
position: 'bottom',
formatter: function (params) {
console.log(params)
const dataItem = mailMapIconList.value.find(item => item.name.includes(params.name.substring(0, 2)));
@ -947,7 +828,6 @@ const option2 = {
{value: 72, name: "慢作为"},
{value: 24, name: "意见建议"},
{value: 5, name: "纪律作风"},
],
},
],
@ -977,23 +857,217 @@ const option3 = {
};
// endregion
// region
// region |
const handleCommand = (year) => {
selectedYear.value = year;
getTrend()
const getFirstAndRepeatMailRank = async (timeValue = time.value) => {
const res = await getFirstAndRepeatMail(timeValue)
fxjsFirstAndRepeatOverview.value = res.fxjsFirstAndRepeatOverview;
bwzdFirstAndRepeatOverview.value = res.bwzdFirstAndRepeatOverview
fxsjFirstMailList.value = res.fxsjFirstRankList;
fxsjRepeatMailList.value = res.fxsjRepeatRankList;
fxsjLeaderViewMailList.value = res.fxsjLeaderViewRankList;
bwzdFirstMailList.value = res.bwzdFirstRankList;
bwzdRepeatMailList.value = res.bwzdRepeatRankList;
bwzdLeaderViewMailList.value = res.bwzdLeaderViewRankList;
}
const getOverview = async (timeValue = time.value) => {
const res = await getAllMailCount(timeValue)
overview.value = res.overview;
}
const getTrend = async (year = selectedYear.value) => {
const res = await getMailTrend(year);
const policeList = res.policeList;
const commissionerList = res.commissionerList;
const numberList = res.numberList;
const countryList = res.countryList;
const policecategories = policeList.map(item => item.name);
const policevalues = policeList.map(item => item.value);
const managecategories = commissionerList.map(item => item.name);
const managevalues = commissionerList.map(item => item.value);
const numbercategories = numberList.map(item => item.name);
const numbervalues = numberList.map(item => item.value);
const countrycategories = countryList.map(item => item.name);
const countryvalues = countryList.map(item => item.value);
//
policeTrend.value.xAxis.data = policecategories;
policeTrend.value.series[0].data = policevalues;
manageTrend.value.xAxis.data = managecategories;
manageTrend.value.series[0].data = managevalues;
numberTrend.value.xAxis.data = numbercategories;
numberTrend.value.series[0].data = numbervalues;
countryTrend.value.xAxis.data = countrycategories;
countryTrend.value.series[0].data = countryvalues;
}
const getEntangleMassRank = async (timeValue = time.value) => {
const res = await getEntanglementAndMassMail(timeValue)
fxsjMailEntanglementMassOverview.value = res.fxsjMailEntanglementMassOverview;
bwzdMailEntanglementMassOverview.value = res.bwzdMailEntanglementMassOverview;
fxsjEntanglementMailList.value = res.fxsjEntanglementList;
fxsjMassMailList.value = res.fxsjMassList;
fxsjLeaderReviewMailList.value = res.fxsjLeaderReviewList;
bwzdLeaderReviewMailList.value = res.bwzdLeaderReviewList;
bwzdEntanglementMailList.value = res.bwzdEntanglementList;
bwzdMassMailList.value = res.bwzdMassList;
}
const mailMapIconList = ref([]);
const getMailMapIconList = async (timeValue = time.value) => {
const res = await getMailMapIcon(timeValue);
const mappedData = res.mailMapIconList.map(item => {
let name;
switch (item.name) {
case '长沙县局':
name = '长沙县';
break;
case '芙蓉分局':
name = '芙蓉区';
break;
case '天心分局':
name = '天心区';
break;
case '岳麓分局':
name = '岳麓区';
break;
case '开福分局':
name = '开福区';
break;
case '雨花分局':
name = '雨花区';
break;
case '望城分局':
name = '望城区';
break;
case '宁乡市局':
name = '宁乡市';
break;
case '浏阳市局':
name = '浏阳市';
break;
case '高新分局':
name = '高新区';
break;
default:
name = item.name;
break;
}
return {
...item,
originalName: item.name, //
name: name,
value: item.total,
};
});
mailMapIconList.value = mappedData;
console.log(mailMapIconList)
const total = mappedData.reduce((sum, item) => sum + Number(item.value), 0);
const avg = total / mappedData.length; //
const range30Percent = avg * 0.3 //
option.value.series[0].data = mappedData;
option.value.visualMap.pieces = [
{gte: 0, lte: avg - range30Percent, label: "低于平均问题30%", color: "#4987F6"},
{gte: avg - range30Percent, lte: avg + range30Percent + 0.1, label: `平均问题上下浮动30%内`, color: "#F6A149"},
{gte: avg + range30Percent, label: "高于平均问题30%", color: "#D34343"},
];
}
const getData = () => {
getFirstAndRepeatMailRank();
getOverview();
getMailMapIconList()
getTrend();
getEntangleMassRank();
}
const currentLeftOverview = computed(() => {
return activeTab.value === '1' ? fxjsFirstAndRepeatOverview.value : bwzdFirstAndRepeatOverview.value;
});
const currentRightOverview = computed(() => {
return activeTabRight.value === '1' ? fxsjMailEntanglementMassOverview.value : bwzdMailEntanglementMassOverview.value;
});
// endregion
// region
const fxsjFirstAndRepeatAnimation = () => {
fxsjFirstAndRepeatTab.value = (parseInt(fxsjFirstAndRepeatTab.value) % 3 + 1).toString();
};
fxsjFirstAndRepeatIntervalId = setInterval(fxsjFirstAndRepeatAnimation, 3000);
//
// const ywlxzbCircularAnimation = () => {
// const ywlxzbOptionTemp = ywlxzbOption?.value?.chart;
// if (!ywlxzbOptionTemp) return;
// const length = ywlxPieOption.value.series[0].data.length;
// const randomNum = Math.floor(Math.random() * length);
// ywlxzbOptionTemp?.dispatchAction({type: 'downplay', seriesIndex: 0});
// ywlxzbOptionTemp?.dispatchAction({type: 'highlight', seriesIndex: 0, dataIndex: randomNum}); //
// ywlxzbOptionTemp?.dispatchAction({type: 'showTip', seriesIndex: 0, dataIndex: randomNum});
// };
// ywlxPieCircularIntervalId = setInterval(ywlxzbCircularAnimation, 2000);
//
const mailMapAnimation = () => {
const mapTemp = mailMap?.value?.chart;
if (!mapTemp) return;
// 9 0~8ok
const randomNum = Math.floor(Math.random() * 9);
mapTemp.dispatchAction({
type: "downplay", //downplay
seriesIndex: 0,
});
mapTemp.dispatchAction({
type: "highlight", //highLight
seriesIndex: 0, //index
dataIndex: randomNum, //index
});
mapTemp.dispatchAction({
type: "showTip", //showTip
seriesIndex: 0,
dataIndex: randomNum,
});
};
mailMapIntervalId = setInterval(mailMapAnimation, 2000);
//
const mailTrendAnimation = () => {
mailTrendTabs.value = (parseInt(mailTrendTabs.value) % 4 + 1).toString();
}
mailTrendIntervalId = setInterval(mailTrendAnimation, 2000);
// 访访
const fxsjEntanglementAnimation = () => {
fxsjEntanglementTab.value = (parseInt(fxsjEntanglementTab.value) % 3 + 1).toString();
};
fxsjEntanglementIntervalId = setInterval(fxsjEntanglementAnimation, 3000);
// //
// const wtlxzbCircularAnimation = () => {
// const wtlxzbOptionTemp = wtlxzbOption?.value?.chart;
// if (!wtlxzbOptionTemp) return;
// const length = ywlxPieOption.value.series[0].data.length;
// const randomNum = Math.floor(Math.random() * length);
// wtlxzbOptionTemp?.dispatchAction({type: 'downplay', seriesIndex: 0});
// wtlxzbOptionTemp?.dispatchAction({type: 'highlight', seriesIndex: 0, dataIndex: randomNum}); //
// wtlxzbOptionTemp?.dispatchAction({type: 'showTip', seriesIndex: 0, dataIndex: randomNum});
// };
// wtlxPieCircularIntervalId = setInterval(wtlxzbCircularAnimation, 2000);
// endregion
// region |
// 访tab
watch(time, () => {
getData();
})
onMounted(() => {
getData();
timer = setInterval(() => {
activeMailTab.value = (parseInt(activeMailTab.value) % 3 + 1).toString();
console.log("Active Tab: ", activeMailTab.value);
}, 3000); // 3
setupEventListeners();
});
const handleCommand = (year) => {
selectedYear.value = year;
getTrend()
};
const handleClick = (params) => {
const departId = params.data.departId;
const url = router.resolve({
@ -1002,6 +1076,53 @@ const handleClick = (params) => {
}).href;
window.open(url, "_blank");
}
const setupEventListeners = () => {
firstAndRepeatAnimationStop();
mailMapAnimationStop();
mailTrendAnimationStop();
fxsjEntanglementAnimationStop();
};
const firstAndRepeatAnimationStop = () => {
const temp = firstAndRepeat.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(fxsjFirstAndRepeatIntervalId)
});
temp.addEventListener('mouseleave', () => {
fxsjFirstAndRepeatIntervalId = setInterval(fxsjFirstAndRepeatAnimation, 3000);
});
}
const mailMapAnimationStop = () => {
const mapTemp = mailMap?.value?.chart;
mapTemp.on('mousemove', (e) => {
clearInterval(mailMapIntervalId);
mapTemp.dispatchAction({type: "downplay", seriesIndex: 0,});
mapTemp.dispatchAction({type: "highlight", seriesIndex: 0, dataIndex: e.dataIndex,});
mapTemp.dispatchAction({type: "showTip", seriesIndex: 0, dataIndex: e.dataIndex,});
});
mapTemp.on('mouseout', () => {
clearInterval(mailMapIntervalId); //
mailMapIntervalId = setInterval(mailMapAnimation, 2000);
});
}
const mailTrendAnimationStop = () => {
const temp = mailTrendCard?.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(mailTrendIntervalId);
});
temp.addEventListener('mouseleave', () => {
clearInterval(mailTrendIntervalId);
mailTrendIntervalId = setInterval(mailTrendAnimation, 2000);
});
}
const fxsjEntanglementAnimationStop = () => {
const temp = entanglement.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(fxsjEntanglementIntervalId)
});
temp.addEventListener('mouseleave', () => {
fxsjEntanglementIntervalId = setInterval(fxsjEntanglementAnimation, 3000);
});
}
// endregion
</script>

1
src/views/datav/RightsComfort.vue

@ -214,7 +214,6 @@
import vCharts from "vue-echarts";
import changshaMap from "@/assets/data/changsha.json";
import * as echarts from "echarts/core";
import moment from "moment";
import {
getALlComfortCount,

24
src/views/datav/SceneInsp.vue

@ -804,7 +804,7 @@ import {
} from "@/api/data/supervisionNotify.ts";
import router from "@/router/index.ts";
import {circularChart, workDynamics} from "@/views/datav/simulateData/AnimationTestData.js";
import {workDynamicColorMapping} from "@/enums/workDynamicColorMapping.js";
// region
const time = ref([
@ -904,14 +904,7 @@ const jsdwCheckBeerOverview = ref({
const fxsjCheckBeerRankList = ref([]) //
const jsdwCheckBeerRankList = ref([]) //
const messages = ref([
{
type: '',
workType: '工作简报',
contentTxt: '为强化队伍纪律作风监督,给严打整治“雷霆行动”及即将到来的国庆节安保维稳工作提供强有力的纪律监督保障,9月25日20时至23时,市局警务督察支队安排6个现场督察组,对干部、民警共计119人开展集中酒精吹气测试。',
releaseTime: '2024-09-27 10:32'
}
]);
const messages = ref([]);
const rcdcProRankTab = ref("1"); // tab
const zxdcProRankTab = ref("1"); // tab
const sceneInspRcdcProRankTabs = ref(null)
@ -1257,13 +1250,12 @@ const getCheckBeerData = async () => {
}
const getWorkDynamicsData = async () => {
const res = await getWorkDynamics(time.value);
//
// messages.value = workDynamics;
messages.value = res.newsVoList;
const colorNewsVoList = workDynamicColorMapping(res.newsVoList);
messages.value = colorNewsVoList;
}
getWorkDynamicsData()
const getData = async () => {
const getData = () => {
getChangedRankData();
getProblemTypeRateData();
getSupervisionNotifyCountData();
@ -1274,12 +1266,12 @@ const getData = async () => {
getCompanyProblemData();
getHandleCaseData();
getCheckBeerData();
getWorkDynamicsData();
}
// endregion
// region
//
const sceneInspRcdxRankAnimation = () => {
rcdcProRankTab.value = (parseInt(rcdcProRankTab.value) % 2 + 1).toString();
};
@ -1347,10 +1339,8 @@ const sceneWorkDynamicsAnimation = () => {
}
}
sceneWorkDynamicsIntervalId = setInterval(sceneWorkDynamicsAnimation, 50);
// endregion
// region
watch(time, () => {
getData();

9
src/views/datav/subonedatav/SubOneGlobal.vue

@ -137,8 +137,8 @@
</el-row>
</main>
</div>
<negative-info-depart-dialog v-model="showDialog" :departId="tempDepartId"/>
<negative-info-depart-dialog v-model="showDialog" :departId="tempDepartId"/>
<!-- <negative-info-police-dialog v-model="showDialog" :emp-no="tempPolice"/>-->
</el-scrollbar>
</template>
@ -160,6 +160,10 @@ import {
// region
const showDialog = ref(false); //
const tempDepartId = ref(0); // id
const tempPolice = ref(0)
// setTimeout(() => {
// tempPolice.value = 430426
// }, 3000);
const route = useRoute();
const currentMapData = ref({})
const subOneGlobalMap = ref(null); //
@ -617,6 +621,7 @@ const handleClick = (params) => {
const departId = params.data.departId;
showDialog.value = true;
tempDepartId.value = departId
// tempPolice.value = 430426;
clearInterval(subOneGlobalMapIntervalId);
}

192
src/views/datav/subonedatav/SubOneMailVisits.vue

@ -10,7 +10,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.firstMail }}
{{ currentLeftOverview.firstMail }}
</div>
<div class="descriptions_label">
初信初访
@ -20,7 +20,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.repeatMail }}
{{ currentLeftOverview.repeatMail }}
</div>
<div class="descriptions_label">
重复信访
@ -30,7 +30,7 @@
<el-col :span="8">
<div class="descriptions_cell text-center">
<div class="descriptions_content">
{{ currentOverview.leaderMail }}
{{ currentLeftOverview.leaderMail }}
</div>
<div class="descriptions_label">
领导接访数
@ -39,10 +39,10 @@
</el-col>
</el-row>
<datav-card>
<datav-tabs v-model="activeTab">
<datav-tabs v-model="activeTab" ref="subOneFirstAndRepeat">
<datav-tab-item label="派出所" name="1">
<datav-tabs
v-model="activeMailTab"
v-model="subOneFxsjFirstAndRepeatTab"
type="bottom-button"
>
<datav-tab-item label="初信初访" name="1">
@ -120,8 +120,6 @@
</datav-tabs>
</datav-card>
</datav-card>
<datav-card title="信访问题类型">
<v-charts
style="height: 300px"
@ -133,7 +131,6 @@
</div>
</div>
</datav-card>
</el-col>
<el-col :span="12">
@ -174,11 +171,12 @@
style="height: 450px"
:option="option"
autoresize
ref="chart"
ref="subOneMailMap"
@click="handleClick"
/>
<datav-card title="信访趋势">
<datav-tabs v-model="activeMailTrend" @change="handleTabChange">
<datav-card title="信访趋势" ref="subOneMailTrendCard">
<datav-tabs v-model="subOneMailTrendTabs" @change="handleTabChange">
<datav-tab-item label="国家信访" name="1">
<v-charts
style="width: 105%; height: 300px;"
@ -193,6 +191,13 @@
autoresize
/>
</datav-tab-item>
<datav-tab-item label="局长信箱" name="3">
<v-charts
style="width: 105%; height: 300px; "
:option="manageTrend"
autoresize
/>
</datav-tab-item>
<datav-tab-item label="12337信访" name="4">
<v-charts
style="width: 105%; height: 300px; "
@ -253,10 +258,11 @@
</el-col>
</el-row>
<datav-card>
<datav-tabs v-model="activeTabRight">
<datav-tabs v-model="activeTabRight" ref="subOneEntanglement">
<datav-tab-item label="派出所" name="1">
<datav-tabs
type="bottom-button"
v-model="subOneFxsjEntanglementTab"
>
<datav-tab-item label="领导督办" name="1">
<el-scrollbar height="300px">
@ -350,7 +356,7 @@
</main>
</div>
</el-scrollbar>
<negative-info-depart-dialog v-model="showDialog" :departId="tempDepartId"/>
</template>
@ -372,7 +378,6 @@ import {
getSubOneAllMailCount, getSubOneMailTrend, getSubOneMailMapIcon
} from "@/api/screen/subScreen/subOneMailVisits.ts";
//region
let timer;
const activeTab = ref("1");
@ -428,7 +433,6 @@ const years = ref([currentYear.toString(), (currentYear - 1).toString(), (curren
const selectedYear = ref(currentYear); //
const route = useRoute();
const currentMapData = ref({})
const chart = ref(null); //
const currentDepartId = route.query.departId;
const colors = [
{
@ -444,7 +448,6 @@ const colors = [
percentage: 40,
},
];
const leaderViewColors = [
{
color: "linear-gradient( 270deg, #63E700 0%, #19674C 100%)",
@ -460,6 +463,20 @@ const leaderViewColors = [
},
];
const subOneFxsjFirstAndRepeatTab = ref("1");
const subOneFirstAndRepeat = ref(null)
const subOneMailMap = ref(null);
const subOneMailTrendTabs = ref("1");
const subOneMailTrendCard = ref(null)
const subOneFxsjEntanglementTab = ref("1");
const subOneEntanglement = ref(null)
let subOneFxsjFirstAndRepeatIntervalId;
let subOneFxsjEntanglementIntervalId;
let subOneMailTrendIntervalId;
let subOneMailMapIntervalId;
const tempDepartId = ref(0); // id
const showDialog = ref(false); //
//endregion
// region
@ -467,7 +484,7 @@ const getMapJSON = async (departId = currentDepartId) => {
const res = await getSubOneStreetMap(departId);
currentMapData.value = res;
echarts.registerMap("changsha", res);
chart.value.chart.setOption(option.value);
subOneMailMap.value.chart.setOption(option.value);
}
const getSubOneFirstAndRepeatMailRankData = async (depart = currentDepartId, timeValue = time.value) => {
@ -557,28 +574,19 @@ const getData = () => {
// endregion
// region
echarts.registerMap("changsha", changshaMap);
const globalTempMapVoList = [
{
"name": "芙蓉分局",
"total": 0,
"countryTotal": 0,
"policeTotal": 0,
"commissionerTotal":0,
"numTotal": 0,
}
];
const globalTempMapVoList = [];
const option = ref({
tooltip: {
trigger: 'item',
position: 'bottom',
formatter: function (params) {
const dataItem = mailMapIconList.value.find(item => item.name === params.name) || {}; //
// console.log("Data item:", dataItem);
console.log("Data item:", mailMapIconList.value);
//
if (dataItem.name===params.name ) {
if (dataItem.name === params.name) {
return `
<div class="tooltip">
<div class="tooltip-title">${params.name}</div>
@ -953,6 +961,56 @@ const option3 = {
};
// endregion
// region
const subOneFxsjFirstAndRepeatAnimation = () => {
subOneFxsjFirstAndRepeatTab.value = (parseInt(subOneFxsjFirstAndRepeatTab.value) % 3 + 1).toString();
};
subOneFxsjFirstAndRepeatIntervalId = setInterval(subOneFxsjFirstAndRepeatAnimation, 3000);
//
const subOneMailMapAnimation = () => {
const mapTemp = subOneMailMap?.value?.chart;
if (!mapTemp) return;
// 9 0~8ok
const length = mailMapIconList.value.length;
const randomNum = Math.floor(Math.random() * length);
mapTemp.dispatchAction({
type: "downplay", //downplay
seriesIndex: 0,
});
mapTemp.dispatchAction({
type: "highlight", //highLight
seriesIndex: 0, //index
dataIndex: randomNum, //index
});
mapTemp.dispatchAction({
type: "showTip", //showTip
seriesIndex: 0,
dataIndex: randomNum,
});
};
subOneMailMapIntervalId = setInterval(subOneMailMapAnimation, 2000);
//
const subOneMailTrendAnimation = () => {
subOneMailTrendTabs.value = (parseInt(subOneMailTrendTabs.value) % 4 + 1).toString();
}
subOneMailTrendIntervalId = setInterval(subOneMailTrendAnimation, 2000);
// 访访
const subOneFxsjEntanglementAnimation = () => {
subOneFxsjEntanglementTab.value = (parseInt(subOneFxsjEntanglementTab.value) % 3 + 1).toString();
};
subOneFxsjEntanglementIntervalId = setInterval(subOneFxsjEntanglementAnimation, 3000);
// //
// const wtlxzbCircularAnimation = () => {
// const wtlxzbOptionTemp = wtlxzbOption?.value?.chart;
// if (!wtlxzbOptionTemp) return;
// const length = ywlxPieOption.value.series[0].data.length;
// const randomNum = Math.floor(Math.random() * length);
// wtlxzbOptionTemp?.dispatchAction({type: 'downplay', seriesIndex: 0});
// wtlxzbOptionTemp?.dispatchAction({type: 'highlight', seriesIndex: 0, dataIndex: randomNum}); //
// wtlxzbOptionTemp?.dispatchAction({type: 'showTip', seriesIndex: 0, dataIndex: randomNum});
// };
// wtlxPieCircularIntervalId = setInterval(wtlxzbCircularAnimation, 2000);
// endregion
// region ||||
const handleCommand = (year) => {
@ -965,20 +1023,69 @@ watch(time, () => {
})
onMounted(() => {
getData();
// timer = setInterval(() => {
// activeMailTab.value = (parseInt(activeMailTab.value) % 3 + 1).toString();
// console.log("Active Tab: ", activeMailTab.value);
// }, 3000); // 3
setupEventListeners();
});
const currentOverview = computed(() => {
const currentLeftOverview = computed(() => {
return activeTab.value === '1' ? fxjsFirstAndRepeatOverview.value : bwzdFirstAndRepeatOverview.value;
});
const currentRightOverview = computed(() => {
return activeTabRight.value === '1' ? fxsjMailEntanglementMassOverview.value : bwzdMailEntanglementMassOverview.value;
});
// endregion
const handleClick = (params) => {
const departId = params.data.departId;
showDialog.value = true;
tempDepartId.value = departId
clearInterval(subOneMailMapIntervalId);
}
const setupEventListeners = () => {
subOneFirstAndRepeatAnimationStop();
subOneMailMapAnimationStop();
subOneMailTrendAnimationStop();
subOneFxsjEntanglementAnimationStop();
};
const subOneFirstAndRepeatAnimationStop = () => {
const temp = subOneFirstAndRepeat.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(subOneFxsjFirstAndRepeatIntervalId)
});
temp.addEventListener('mouseleave', () => {
subOneFxsjFirstAndRepeatIntervalId = setInterval(subOneFxsjFirstAndRepeatAnimation, 3000);
});
}
const subOneMailMapAnimationStop = () => {
const mapTemp = subOneMailMap?.value?.chart;
mapTemp.on('mousemove', (e) => {
clearInterval(subOneMailMapIntervalId);
mapTemp.dispatchAction({type: "downplay", seriesIndex: 0,});
mapTemp.dispatchAction({type: "highlight", seriesIndex: 0, dataIndex: e.dataIndex,});
mapTemp.dispatchAction({type: "showTip", seriesIndex: 0, dataIndex: e.dataIndex,});
});
mapTemp.on('mouseout', () => {
clearInterval(subOneMailMapIntervalId); //
subOneMailMapIntervalId = setInterval(subOneMailMapAnimation, 2000);
});
}
const subOneMailTrendAnimationStop = () => {
const temp = subOneMailTrendCard?.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(subOneMailTrendIntervalId);
});
temp.addEventListener('mouseleave', () => {
clearInterval(subOneMailTrendIntervalId);
subOneMailTrendIntervalId = setInterval(subOneMailTrendAnimation, 2000);
});
}
const subOneFxsjEntanglementAnimationStop = () => {
const temp = subOneEntanglement?.value.$el;
temp.addEventListener('mouseenter', () => {
clearInterval(subOneFxsjEntanglementIntervalId)
});
temp.addEventListener('mouseleave', () => {
subOneFxsjEntanglementIntervalId = setInterval(subOneFxsjEntanglementAnimation, 3000);
});
}
// endregion
</script>
@ -997,7 +1104,6 @@ const currentRightOverview = computed(() => {
align-items: center;
}
:deep() {
//
.tooltip {
@ -1054,7 +1160,6 @@ const currentRightOverview = computed(() => {
}
.test {
width: 95px;
height: 25px;
@ -1074,15 +1179,6 @@ const currentRightOverview = computed(() => {
width: 90px;
color: #fff;
}
</style>
<!--
<datav-tab-item label="局长信箱" name="3">
<v-charts
style="width: 105%; height: 300px; "
:option="manageTrend"
autoresize
/>
</datav-tab-item>-->

90
src/views/datav/subonedatav/SubOneSceneInsp.vue

@ -176,6 +176,7 @@
:option="option"
autoresize
ref="subOneSceneInspMapChart"
@click="handleClick"
/>
<datav-card title="问题趋势">
<v-charts
@ -204,8 +205,7 @@
<datav-card>
<datav-tabs v-model="subOneZxdcProRankTab" size="small" ref="subOneSceneInspZxdcProRankTabs">
<datav-tab-item label="黄赌毒" name="1">
<datav-tabs
type="bottom-button">
<datav-tabs type="bottom-button">
<datav-tab-item label="派出所" name="1">
<el-row class="mb-32">
<el-col :span="6">
@ -314,7 +314,6 @@
/>
</el-scrollbar>
</datav-tab-item>
</datav-tabs>
</datav-tab-item>
<datav-tab-item label="枪支管理" name="2">
@ -775,8 +774,9 @@
v-for="(msg, index) in messages"
:key="index"
:type="msg.type"
:title="msg.title"
:content="msg.content" :date="msg.date"
:title="msg.workType"
:content="msg.contentTxt"
:date="msg.releaseTime"
/>
</el-scrollbar>
</datav-card>
@ -786,6 +786,7 @@
</main>
</div>
</el-scrollbar>
<negative-info-depart-dialog v-model="showDialog" :departId="tempDepartId"/>
</template>
<script setup>
@ -798,9 +799,9 @@ import {getSubOneStreetMap} from "@/api/screen/subScreen/subOneGlobal.ts";
import {
getSubOneChangedRank, getSubOneCheckBeer, getSubOneCompanyProblem, getSubOneGunController, getSubOneHandleCase,
getSubOneProblemTypeRate, getSubOneSupervisionMap, getSubOneSupervisionNotifyCount,
getSubOneSupervisionTrend, getSubOneYellowBetDrug
getSubOneSupervisionTrend, getSubOneWorkDynamics, getSubOneYellowBetDrug
} from "@/api/screen/subScreen/subOneSupervisionNotify.ts";
import {circularChart} from "@/views/datav/simulateData/AnimationTestData.js";
import {workDynamicColorMapping} from "@/enums/workDynamicColorMapping.js";
// region
const time = ref([
@ -902,14 +903,7 @@ const jsdwCheckBeerOverview = ref({
const fxsjCheckBeerRankList = ref([]) //
const jsdwCheckBeerRankList = ref([]) //
const messages = ref([
{
type: '',
workType: '工作简报',
contentTxt: '为强化队伍纪律作风监督,给严打整治“雷霆行动”及即将到来的国庆节安保维稳工作提供强有力的纪律监督保障,9月25日20时至23时,市局警务督察支队安排6个现场督察组,对干部、民警共计119人开展集中酒精吹气测试。',
releaseTime: '2024-09-27 10:32'
}
]);
const messages = ref([]);
const subOneZxdcProRankTab = ref("1"); // tab
const subOneRcdcProRankTab = ref("1")
@ -927,6 +921,8 @@ let subOneSceneInspTrendIntervalId;
let subOneSceneInspZxdxIntervalId;
let subOneSceneWorkDynamicsIntervalId;
const tempDepartId = ref(0); // id
const showDialog = ref(false); //
const colors = [
{
@ -960,7 +956,6 @@ const dayTimeColors = [
// endregion
// region
echarts.registerMap("changsha", changshaMap);
const option = ref({
@ -1127,7 +1122,6 @@ const proTrend = ref({
});
// endregion
// region
const getMapJSON = async (departId = currentDepartId) => {
const res = await getSubOneStreetMap(departId)
@ -1221,6 +1215,12 @@ const getSubOneCheckBeerData = async (departId, times) => {
fxsjCheckBeerRankList.value = res.fxsjCheckBeerRankList
jsdwCheckBeerRankList.value = res.jsdwCheckBeerRankList
}
const getSubOneWorkDynamicsData = async (departId, times) => {
const res = await getSubOneWorkDynamics(departId, times);
const colorNewsVoList = workDynamicColorMapping(res.newsVoList);
messages.value = colorNewsVoList;
}
const getData = async () => {
getMapJSON(currentDepartId);
getSubOneChangedRankData(currentDepartId, time.value);
@ -1233,6 +1233,7 @@ const getData = async () => {
getSubOneCompanyProblemData(currentDepartId, time.value);
getSubOneHandleCaseData(currentDepartId, time.value);
getSubOneCheckBeerData(currentDepartId, time.value);
getSubOneWorkDynamicsData(currentDepartId, time.value);
}
// endregion
@ -1296,20 +1297,19 @@ const subOneSceneInspZxdxRankAnimation = () => {
};
subOneSceneInspZxdxIntervalId = setInterval(subOneSceneInspZxdxRankAnimation, 3000);
//
// const subOneSceneWorkDynamicsAnimation = () => {
// const sceneScrollTemp = subOneSceneScrollbar?.value;
// const maxScroll = sceneScrollTemp?.wrapRef?.scrollHeight - sceneScrollTemp?.wrapRef?.clientHeight;
// currentIndex.value > maxScroll ? currentIndex.value = 0 : currentIndex.value += 1;
// if (currentIndex.value === 0) {
// sceneScrollTemp?.scrollTo({top: currentIndex.value});
// } else {
// sceneScrollTemp?.scrollTo({top: currentIndex.value});
// }
// }
// subOneSceneWorkDynamicsIntervalId = setInterval(subOneSceneWorkDynamicsAnimation, 50);
const subOneSceneWorkDynamicsAnimation = () => {
const sceneScrollTemp = subOneSceneScrollbar?.value;
const maxScroll = sceneScrollTemp?.wrapRef?.scrollHeight - sceneScrollTemp?.wrapRef?.clientHeight;
currentIndex.value > maxScroll ? currentIndex.value = 0 : currentIndex.value += 1;
if (currentIndex.value === 0) {
sceneScrollTemp?.scrollTo({top: currentIndex.value});
} else {
sceneScrollTemp?.scrollTo({top: currentIndex.value});
}
}
subOneSceneWorkDynamicsIntervalId = setInterval(subOneSceneWorkDynamicsAnimation, 50);
// endregion
// region
watch(time, () => {
getData();
@ -1322,6 +1322,12 @@ const handleCommand = (year) => {
selectedYear.value = year; //
getSubOneSupervisionTrendData(currentDepartId, selectedYear.value);
};
const handleClick = (params) => {
const departId = params.data.departId;
showDialog.value = true;
tempDepartId.value = departId
clearInterval(subOneGlobalMapIntervalId);
}
//
const setupEventListeners = () => {
@ -1330,7 +1336,7 @@ const setupEventListeners = () => {
subOneSceneInspMapAnimationStop();
subOneSceneInspTrendAnimationStop();
subOneSceneInspZxdxRankAnimationStop();
// subOneSceneWorkDynamicsAnimationStop();
subOneSceneWorkDynamicsAnimationStop();
};
const subOneSceneInspRcdxRankAnimationStop = () => {
const temp = subOneSceneInspRcdcProRankTabs.value?.$el;
@ -1390,21 +1396,19 @@ const subOneSceneInspZxdxRankAnimationStop = () => {
subOneSceneInspZxdxIntervalId = setInterval(subOneSceneInspZxdxRankAnimation, 3000);
});
}
// const sceneWorkDynamicsAnimationStop = () => {
// const temp = sceneScrollbar.value?.$el;
// temp.addEventListener('mouseenter', () => {
// // alert(1);
// clearInterval(sceneWorkDynamicsIntervalId)
// });
// temp.addEventListener('mouseleave', () => {
// clearInterval(sceneWorkDynamicsIntervalId);
// sceneWorkDynamicsIntervalId = setInterval(sceneWorkDynamicsAnimation, 50);
// });
// }
const subOneSceneWorkDynamicsAnimationStop = () => {
const temp = subOneSceneScrollbar.value?.$el;
temp.addEventListener('mouseenter', () => {
// alert(1);
clearInterval(subOneSceneWorkDynamicsIntervalId)
});
temp.addEventListener('mouseleave', () => {
clearInterval(subOneSceneWorkDynamicsIntervalId);
subOneSceneWorkDynamicsIntervalId = setInterval(subOneSceneWorkDynamicsAnimation, 50);
});
}
// endregion
</script>
<style lang="scss" scoped>

Loading…
Cancel
Save