Browse Source

fix: 完善问题画像

main
wxc 1 year ago
parent
commit
8f0f79e630
  1. BIN
      public/imgs/police.jpeg
  2. 18
      src/views/datav/CaseVerif.vue
  3. 245
      src/views/sensitivePerception/DepartNegative.vue
  4. 80
      src/views/sensitivePerception/PoliceNegative.vue
  5. 122
      src/views/work/Fav.vue

BIN
public/imgs/police.jpeg

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

18
src/views/datav/CaseVerif.vue

@ -23,7 +23,6 @@
size="large"
/>
</datav-tab-item>
</datav-tabs>
</datav-card>
<datav-card title="案件问题性质">
@ -181,13 +180,16 @@ function getData() {
watch(time, () => {
getData();
})
});
onMounted(() => {
getData();
});
const zfbaPieOption = computed(() => {
return {
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
@ -203,6 +205,9 @@ const zfbaPieOption = computed(() => {
const fwglPieOption = computed(() => {
return {
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
@ -218,6 +223,9 @@ const fwglPieOption = computed(() => {
const jjjgPieOption = computed(() => {
return {
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
@ -233,6 +241,9 @@ const jjjgPieOption = computed(() => {
const ajlyPieOption = computed(() => {
return {
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",
@ -351,6 +362,9 @@ const option1 = ref({
});
const option4 = {
tooltip: {
trigger: "item",
},
series: [
{
type: "pie",

245
src/views/sensitivePerception/DepartNegative.vue

@ -1,108 +1,115 @@
<template>
<div class="container">
<el-tabs>
<el-tab-pane label="所队">
<header>
<el-form :label-width="114">
<el-row>
<el-col :span="6">
<el-form-item label="三级单位">
<depart-tree-select
v-model="query.departId"
:check-strictly="false"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="单位简称">
<el-input v-model="query.departName" placeholder="请输入" />
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="统计时间">
<date-time-range-picker-ext
v-model="query.crtTime"
/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div class="mb-25 flex end">
<div>
<el-button type="primary" @click="getList">
<template #icon>
<icon name="el-icon-Search" />
</template>
查询</el-button
>
<el-button @click="reset">重置</el-button>
</div>
</div>
</header>
<div class="table-container">
<el-table :data="list">
<el-table-column label="单位名称">
<template #default="{ row }">
<span
>{{ row.parentDepartName }}/{{
row.departName
}}</span
>
</template>
</el-table-column>
<el-table-column
label="民警人数"
prop="policeSize"
align="center"
width="160"
/>
<el-table-column
label="协辅警人数"
prop="auxSize"
align="center"
width="160"
/>
<el-table-column
label="查实问题涉及人数"
prop="verifyPoliceSize"
align="center"
width="160"
/>
<el-table-column
label="查实问题数"
prop="verifySize"
align="center"
width="160"
/>
<header>
<el-form :label-width="114">
<el-row>
<el-col :span="6">
<el-form-item label="单位类型">
<el-select v-model="query.departLevel">
<el-option value="3" label="所队"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="统计时间">
<date-time-range-picker-ext
v-model="query.crtTime"
/>
</el-form-item>
</el-col>
<el-table-column label="操作">
<template #default="{ row }">
<el-button
type="primary"
link
@click="handleShowProfile(row)"
>问题画像</el-button
>
</template>
</el-table-column>
</el-table>
</div>
<div class="flex end mt-8">
<el-pagination
@size-change="getList"
@current-change="getList"
:current-page="query.current"
:page-sizes="[9, 18, 36]"
v-model:page-size="query.size"
v-model:current-page="query.current"
layout="total, sizes, prev, pager, next"
:total="total"
v-if="list.length"
<el-col :span="6">
<el-form-item label="三级单位">
<depart-tree-select
v-model="query.departId"
:check-strictly="false"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="单位简称">
<el-input
v-model="query.departName"
placeholder="请输入"
/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div class="mb-25 flex end">
<div>
<el-button type="primary" @click="getList">
<template #icon>
<icon name="el-icon-Search" />
</template>
查询</el-button
>
</el-pagination>
<el-button @click="reset">重置</el-button>
</div>
</el-tab-pane>
</el-tabs>
</div>
</header>
<div class="table-container" v-loading="mainLoading">
<el-table :data="list">
<el-table-column label="单位名称">
<template #default="{ row }">
<span
>{{ row.parentDepartName }}/{{
row.departName
}}</span
>
</template>
</el-table-column>
<el-table-column
label="民警人数"
prop="policeSize"
align="center"
width="160"
/>
<el-table-column
label="协辅警人数"
prop="auxSize"
align="center"
width="160"
/>
<el-table-column
label="查实问题涉及人数"
prop="verifyPoliceSize"
align="center"
width="160"
/>
<el-table-column
label="查实问题数"
prop="verifySize"
align="center"
width="160"
/>
<el-table-column label="操作">
<template #default="{ row }">
<el-button
type="primary"
link
@click="handleShowProfile(row)"
>问题画像</el-button
>
</template>
</el-table-column>
</el-table>
</div>
<div class="flex end mt-8">
<el-pagination
@size-change="getList"
@current-change="getList"
:current-page="query.current"
:page-sizes="[9, 18, 36]"
v-model:page-size="query.size"
v-model:current-page="query.current"
layout="total, sizes, prev, pager, next"
:total="total"
v-if="list.length"
>
</el-pagination>
</div>
</div>
<el-dialog title="单位问题画像" v-model="show" width="85vw" top="2vh">
@ -115,7 +122,7 @@
style="width: 300px"
/>
</div>
<el-button type="primary">查询</el-button>
<el-button type="primary" @click="getProfileData">查询</el-button>
</header>
<main v-loading="loading">
<el-row class="mb-20">
@ -327,22 +334,31 @@ import vCharts from "vue-echarts";
import {
listDepartNegative,
getDepartProfile,
listNegativeMonthly
listNegativeMonthly,
} from "@/api/sensitivePerception/profileDepart";
import { listNegative } from "@/api/work/negative";
import { InspectCase } from "@/enums/dictEnums";
import moment from "moment";
const query = ref({
current: 1,
size: 10,
departLevel: "3",
crtTime: [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
],
});
const list = ref<any[]>([]);
const total = ref(0);
const mainLoading = ref(false);
function getList() {
mainLoading.value = true;
listDepartNegative(query.value).then((data) => {
list.value = data.records;
total.value = data.total;
mainLoading.value = false;
});
}
@ -350,6 +366,11 @@ function reset() {
query.value = {
current: 1,
size: 10,
departLevel: "3",
crtTime: [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
],
};
getList();
}
@ -413,20 +434,26 @@ const barOption = ref({
],
});
async function handleShowProfile(row) {
activeRow.value = row;
loading.value = true;
show.value = true;
await getProfileData();
listNegativeMonthly(row.departId).then(data => {
barOption.value.xAxis.data = data.months
barOption.value.series[0].data = data.values
})
}
watch(activeRow, async () => {
time.value = [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
];
await getProfileData();
listNegativeMonthly(row.departId).then((data) => {
barOption.value.xAxis.data = data.months;
barOption.value.series[0].data = data.values;
});
});
const time = ref([]);
async function getProfileData() {
loading.value = true;
negativeQuery.value.involveDepartId = activeRow.value.departId;
getNegativeList();
const data = await getDepartProfile(activeRow.value.departId, {

80
src/views/sensitivePerception/PoliceNegative.vue

@ -29,14 +29,13 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="所单位">
<el-form-item label="所单位">
<depart-tree-select
v-model="query.departId"
:check-strictly="false"
/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div class="mb-25 flex end">
@ -59,7 +58,14 @@
<span>{{ getGenderFromIdCode(row.idCode) }}</span>
</template>
</el-table-column>
<el-table-column label="职务" prop="position" />
<el-table-column label="职务">
<template #default="{ row }">
<span v-if="row.position">{{ row.position }}</span>
<span v-else>{{
getDictLable(dict.personType, row.personType)
}}</span>
</template>
</el-table-column>
<el-table-column label="警号" prop="empNo" />
<el-table-column label="任职年限" prop="employmentDate" />
<el-table-column label="所属单位" prop="departName">
@ -124,7 +130,9 @@
<el-col :span="8">
<h5>民警基本情况</h5>
<el-row>
<el-col :span="6"> </el-col>
<el-col :span="6">
<img src="/imgs/police.jpeg" />
</el-col>
<el-col :span="18">
<div class="row">
<div class="col col-12">
@ -272,7 +280,12 @@
/>
<el-table-column label="操作" width="160">
<template #default="{ row }">
<el-button type="primary" link @click="handleAction(row)">查看详情</el-button>
<el-button
type="primary"
link
@click="handleAction(row)"
>查看详情</el-button
>
</template>
</el-table-column>
</el-table>
@ -304,13 +317,23 @@ import {
listPoliceNegative,
getPoliceProfile,
listNegativeByPoliceIdCode,
listNegativeMonthly
listNegativeMonthly,
} from "@/api/sensitivePerception/profilePolice";
import { InspectCase } from "@/enums/dictEnums";
import { getDictLable } from "@/utils/util";
import moment from "moment";
import useCatchStore from "@/stores/modules/catch";
const catchStore = useCatchStore();
const dict = catchStore.getDicts(["personType"]);
const query = ref({
current: 1,
size: 10,
crtTime: [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
],
});
const list = ref<any[]>([]);
const total = ref(0);
@ -326,6 +349,10 @@ function reset() {
query.value = {
current: 1,
size: 10,
crtTime: [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
],
};
getList();
}
@ -391,14 +418,20 @@ const barOption = ref({
async function handleShowProfile(row) {
activeRow.value = row;
show.value = true;
time.value = []
await getProfileData();
listNegativeMonthly(row.idCode).then(data => {
barOption.value.xAxis.data = data.months
barOption.value.series[0].data = data.values
})
}
watch(activeRow, async () => {
time.value = [
moment().startOf("year").format("YYYY-MM-DD HH:mm:ss"),
moment().format("YYYY-MM-DD HH:mm:ss"),
];
await getProfileData();
listNegativeMonthly(row.idCode).then((data) => {
barOption.value.xAxis.data = data.months;
barOption.value.series[0].data = data.values;
});
})
const time = ref([]);
async function getProfileData() {
loading.value = true;
@ -422,12 +455,13 @@ function getNegativeList() {
negativeQuery.value.beginTime = time.value[0];
negativeQuery.value.endTime = time.value[1];
}
listNegativeByPoliceIdCode(activeRow.value.idCode, negativeQuery.value).then(
(data) => {
negativeList.value = data.records;
negativeTotal.value = data.total;
}
);
listNegativeByPoliceIdCode(
activeRow.value.idCode,
negativeQuery.value
).then((data) => {
negativeList.value = data.records;
negativeTotal.value = data.total;
});
}
const radarOption = {
@ -455,12 +489,10 @@ const radarOption = {
],
};
function getGenderFromIdCode(idCode) {
// 18
if (!idCode || idCode.length !== 18) {
return '';
return "";
}
// 17
@ -468,14 +500,14 @@ function getGenderFromIdCode(idCode) {
//
if (isNaN(genderCode)) {
return '';
return "";
}
// 17
return genderCode % 2 === 0 ? "女" : "男";
}
const negativeShow = ref(false)
const activeNegativeId = ref('')
const negativeShow = ref(false);
const activeNegativeId = ref("");
function handleAction(row) {
negativeShow.value = true;
activeNegativeId.value = row.id;

122
src/views/work/Fav.vue

@ -5,27 +5,44 @@
<el-row>
<el-col :span="6">
<el-form-item label="问题发生时间">
<date-time-range-picker-ext v-model="query.happenTime"/>
<date-time-range-picker-ext
v-model="query.happenTime"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="问题来源">
<el-select v-model="query.problemSources">
<el-option v-for="item in dict.problemSources" :key="item.id" :label="item.dictLabel" :value="item.dictValue" />
<el-option
v-for="item in dict.problemSources"
:key="item.id"
:label="item.dictLabel"
:value="item.dictValue"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务类别">
<el-select v-model="query.businessType">
<el-option v-for="item in dict.businessType" :key="item.id" :label="item.dictLabel" :value="item.dictValue" />
<el-option
v-for="item in dict.businessType"
:key="item.id"
:label="item.dictLabel"
:value="item.dictValue"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="涉嫌问题">
<el-select>
<el-option v-for="item in dict.suspectProblem" :key="item.id" :label="item.dictLabel" :value="item.dictValue" />
<el-option
v-for="item in dict.suspectProblem"
:key="item.id"
:label="item.dictLabel"
:value="item.dictValue"
/>
</el-select>
</el-form-item>
</el-col>
@ -36,12 +53,16 @@
</el-col>
<el-col :span="6">
<el-form-item label="涉及单位">
<depart-tree-select v-model="query.involveDepartId" />
<depart-tree-select
v-model="query.involveDepartId"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="办理单位">
<depart-tree-select v-model="query.involveDepartId" />
<depart-tree-select
v-model="query.involveDepartId"
/>
</el-form-item>
</el-col>
<el-col :span="6">
@ -89,7 +110,7 @@
<div class="row mt-10">
<div class="col col-6">
<label>投诉反映人</label>
<span>{{ }}</span>
<span>{{}}</span>
</div>
<div class="col col-6">
<label>联系电话</label>
@ -103,7 +124,7 @@
</div>
<div class="col col-6">
<label>涉嫌问题</label>
<span>{{ }}</span>
<span>{{}}</span>
</div>
</div>
<div class="row mt-10">
@ -120,18 +141,36 @@
</el-table-column>
<el-table-column label="问题发生时间" prop="happenTime" />
<el-table-column label="问题来源" prop="problemSources" />
<el-table-column label="业务类别" prop="" />
<el-table-column label="涉嫌问题" prop="" />
<el-table-column label="问题内容" prop="thingDesc" show-overflow-tooltip />
<el-table-column label="办理单位" prop="" />
<el-table-column label="办理状态" prop="" />
<el-table-column label="办理状态" prop="" />
<el-table-column label="业务类别" prop="businessTypeName" />
<el-table-column label="涉嫌问题">
<template #default="{ row }">
<span>{{ getInvolveProblem(row.involveProblem) }}</span>
</template>
</el-table-column>
<el-table-column
label="问题内容"
prop="thingDesc"
show-overflow-tooltip
/>
<el-table-column label="涉及单位" show-overflow-tooltip>
<template #default="{ row }">
<span>{{ row.involveDepartName }}</span>
</template>
</el-table-column>
<el-table-column label="操作">
<template #default="{ row }">
<el-button type="primary" link @click="handleAction(row)"
<el-button
type="primary"
link
@click="handleAction(row)"
>详情</el-button
>
<el-button type="danger" link @click="handleDelFav(row.negativeId)">取消收藏</el-button>
<el-button
type="danger"
link
@click="handleDelFav(row.negativeId)"
>取消收藏</el-button
>
</template>
</el-table-column>
</el-table>
@ -154,51 +193,56 @@
<negative-dialog v-model="show" :id="activeNegativeId" />
</template>
<script lang="ts" setup>
import { listFav, delFav } from '@/api/work/fav'
import feedback from '@/utils/feedback'
import useCatchStore from '@/stores/modules/catch'
import { listFav, delFav } from "@/api/work/fav";
import feedback from "@/utils/feedback";
import useCatchStore from "@/stores/modules/catch";
import { getDictLable, getInvolveProblem } from "@/utils/util";
const dict = useCatchStore().getDicts(['problemSources', 'businessType', 'suspectProblem'])
console.log(dict)
const dict = useCatchStore().getDicts([
"problemSources",
"businessType",
"suspectProblem",
"processingStatus",
]);
console.log(dict);
const favs = ref([])
const favs = ref([]);
const query = ref({
current: 1,
size: 10
size: 10,
});
const total = ref(0);
function getList() {
listFav().then(data => {
favs.value = data.records
total.value = data.total
})
listFav().then((data) => {
favs.value = data.records;
total.value = data.total;
});
}
onMounted(() => {
getList()
})
getList();
});
function reset() {
query.value = {
current: 1,
size: 10
}
getList()
size: 10,
};
getList();
}
const show = ref(false)
const activeNegativeId = ref('')
const show = ref(false);
const activeNegativeId = ref("");
function handleAction(row) {
show.value = true
activeNegativeId.value = row.negativeId
show.value = true;
activeNegativeId.value = row.negativeId;
}
async function handleDelFav(negativeId) {
await feedback.confirm("确定要取消收藏?");
await delFav(negativeId)
getList()
await delFav(negativeId);
getList();
}
</script>
Loading…
Cancel
Save