This commit is contained in:
lcw
2026-01-26 23:34:58 +08:00
8 changed files with 215 additions and 136 deletions

View File

@ -73,8 +73,8 @@ const qxkz = reactive({
const searchConfiger = ref([
{ label: "情报标题", prop: 'qbmc', placeholder: "请输入情报标题", showType: "input" },
// { label: "情报来源", prop: 'cjLx', placeholder: "请选择情报来源", showType: "select", options: D_BZ_CJLX },
// { label: "来源单位", prop: 'ssbmdm', placeholder: "请选择来源单位", showType: "department" }
{ label: "时间", prop: 'times', placeholder: "请输入时间", showType: "datetimerange" },
{ label: "部门", prop: 'ssbmdm', placeholder: "请选择来源单位", showType: "department" }
]);
const pageData = reactive({
@ -105,16 +105,9 @@ const queryFrom = ref({});
// 搜索
const onSearch = (val) => {
const { lrkssj, zxkssj } = val
const promes = {
...val,
...pageData.pageConfiger,
lrkssj: lrkssj ? lrkssj[0] : '',
lrjssj: lrkssj ? lrkssj[1] : '',
zxkssj: zxkssj ? zxkssj[0] : '',
zxjssj: zxkssj ? zxkssj[1] : '',
}
queryFrom.value = { ...promes }
queryFrom.value = { ...val }
queryFrom.value.startTime = val.times ? val.times[0] : ''
queryFrom.value.endTime = val.times ? val.times[1] : ''
pageData.pageConfiger.pageCurrent = 1;
getList()
}
@ -132,6 +125,7 @@ const changeSize = (val) => {
const getList = () => {
pageData.tableConfiger.loading = true;
let data = { ...pageData.pageConfiger, ...queryFrom.value };
delete data.times;
xxcjZxsSelectPage(data).then(res => {
pageData.tableData = res.records || [];
pageData.total = res.total;

View File

@ -1,25 +1,27 @@
<template>
<div>
<!-- 搜索 -->
<div ref="searchBox" class="mt10">
<Search :searchArr="searchConfiger" @submit="onSearch" :key="pageData.keyCount" />
<Search :searchArr="searchConfiger" @submit="onSearch" />
</div>
<PageTitle :malginLeft="10" :height="35" backgroundColor="#ffff" :marginBottom="5" :marginTop="5">
<template #left>
<el-button size="small" type="primary" @click="getDataById('add', '')">
<el-icon style="vertical-align: middle">
<CirclePlus />
</el-icon>
<el-icon style="vertical-align: middle"><CirclePlus /></el-icon>
<span style="vertical-align: middle">新增</span>
</el-button>
</template>
</PageTitle>
<!-- 表格 -->
<div class="tabBox">
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :tableHeight="pageData.tableHeight"
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
@chooseData="chooseData">
<MyTable
:tableData="pageData.tableData"
:tableColumn="pageData.tableColumn"
:tableHeight="pageData.tableHeight"
:key="pageData.keyCount"
:tableConfiger="pageData.tableConfiger"
:controlsWidth="pageData.controlsWidth"
@chooseData="chooseData"
>
<template #wjdx="{ row }">
{{ row.wjdx }}MB
</template>
@ -30,16 +32,17 @@
<template #controls="{ row }">
<el-link size="small" type="primary" @click="getDataById('edit', row)">修改</el-link>
<el-link size="small" type="primary" @click="getDataById('detail', row)">详情</el-link>
<el-link size="small" type="primary" @click="previewFile(row)"
v-if="row.wjlx == '.png' || row.wjlx == '.jpg' || row.wjlx == '.jpeg'">预览</el-link>
<el-link size="small" type="primary" @click="previewFile(row)" v-if="row.wjlx == '.png' || row.wjlx == '.jpg' || row.wjlx == '.jpeg'">预览</el-link>
<el-link size="small" type="primary" @click="downloadFile(row)">下载</el-link>
<el-link size="small" type="danger" @click="deleteFile(row)">删除</el-link>
</template>
</MyTable>
<Pages @changeNo="changeNo" @changeSize="changeSize" :tableHeight="pageData.tableHeight" :pageConfiger="{
...pageData.pageConfiger,
total: pageData.total
}"></Pages>
<Pages
@changeNo="changeNo"
@changeSize="changeSize"
:tableHeight="pageData.tableHeight"
:pageConfiger="{ ...pageData.pageConfiger, total: pageData.total }"
/>
</div>
</div>
<AddForm ref="addForm" @getList="getList" />
@ -51,47 +54,22 @@ import MyTable from "@/components/aboutTable/MyTable.vue";
import Pages from "@/components/aboutTable/Pages.vue";
import Search from "@/components/aboutTable/Search.vue";
import { useRoute } from 'vue-router'
import { qbcjZxsSelectPage } from "@/api/qbcj.js";
import { reactive, ref, onMounted, getCurrentInstance, watch } from "vue";
import { reactive, ref, onMounted, getCurrentInstance } from "vue";
import { getItem } from '@//utils/storage.js'
import { deleteWjZzzAddEntity, getWjZzzAddEntity } from '@//api/qbcj.js'
import AddForm from "./components/addForm.vue";
const { proxy } = getCurrentInstance();
// const { D_BZ_CJLX, D_GS_XS_LX } = proxy.$dict("D_BZ_CJLX", "D_GS_XS_LX"); //获取字典数据
const detailDiloag = ref();
const searchBox = ref(); //搜索框
const ids = ref([])
const tableList = ref([]);
onMounted(() => {
const { deptBizType, deptLevel } = getItem('deptId')[0]
const Jb = deptLevel[0] == '2' ? '01' : deptLevel[0] == '3' ? '02' : '03'
qxkz.deptBizType = deptBizType
qxkz.deptLevel = Jb
getRouter()
tabHeightFn()
if (route.query.id) {
detailDiloag.value.init('edit', {
id: route.query.id
});
return
}
getList()
});
const chooseData = (val) => {
ids.value = val.map(item => {
return item.id
})
tableList.value = val
}
const qxkz = reactive({
deptBizType: "",
deptLevel: ""
})
const searchConfiger = ref([
{ label: "文件名称", prop: 'wjmc', placeholder: "请输入文件名称", showType: "input" },
// { label: "情报来源", prop: 'cjLx', placeholder: "请选择情报来源", showType: "select", options: D_BZ_CJLX },
// { label: "来源单位", prop: 'ssbmdm', placeholder: "请选择来源单位", showType: "department" }
]);
const pageData = reactive({
@ -117,6 +95,26 @@ const pageData = reactive({
]
});
const queryFrom = ref({});
const addForm = ref(null)
const route = useRoute()
const routerMate = ref({})
onMounted(() => {
const { deptBizType, deptLevel } = getItem('deptId')[0]
qxkz.deptBizType = deptBizType
qxkz.deptLevel = deptLevel[0] == '2' ? '01' : deptLevel[0] == '3' ? '02' : '03'
routerMate.value = route.meta;
getList()
tabHeightFn()
if (route.query.id) return detailDiloag.value.init('edit', { id: route.query.id });
});
const chooseData = (val) => {
if(Array.isArray(val)){
ids.value = val.map(item => item.id)
tableList.value = val
}
}
// 搜索
const onSearch = (val) => {
@ -162,67 +160,48 @@ const tabHeightFn = () => {
tabHeightFn();
};
};
const route = useRoute()
const routerMate = ref({})
const getRouter = () => {
routerMate.value = route.meta
}
const addForm = ref(null)
const getDataById = (type, row) => {
addForm.value.init(type, row, '01');
}
const previewFile = (item) => {
window.open(item.wjdz);
}
const downloadFile = async (item) => {
console.log(item);
try {
const dataList =JSON.parse(item.wjdz)
if (dataList.length === 0) {
proxy.$message.warning('没有文件可下载');
return;
}
console.log(dataList);
const downloadFile = async (item) => {
try {
const dataList = JSON.parse(item.wjdz)
if (dataList.length === 0) return proxy.$message.warning('没有文件可下载');
const downloadCount = dataList.length;
let successCount = 0;
let failCount = 0;
proxy.$message.info(`开始下载${downloadCount}个文件...`);
// 并行下载所有文件
const downloadPromises = dataList.map(async (fileData, index) => {
try {
// fileData.url = "http://47.108.232.77:9000/image/2025-01-06/081102a5418e4146beea277d18018e07.jpeg";
// 使用fetch获取文件内容
const response = await fetch(fileData.url);
if (!response.ok) {
throw new Error('文件下载失败');
}
const downloadUrl = fileData.url.replace(/^https?:\/\/[^/]+/, '/zyminio');
const response = await fetch(downloadUrl);
if (!response.ok) throw new Error('文件下载失败');
// 将响应转换为Blob对象
const blob = await response.blob();
// 创建下载链接
const downloadLink = document.createElement('a');
downloadLink.href = URL.createObjectURL(blob);
// 设置下载文件的名称,避免冲突
const fileName = dataList.length > 1
? `${item.wjmc}_${index + 1}`
: item.wjmc;
const fileName = dataList.length > 1 ? `${item.wjmc}_${index + 1}` : item.wjmc;
downloadLink.download = fileName;
// 触发下载
document.body.appendChild(downloadLink);
downloadLink.click();
// 清理
setTimeout(() => {
document.body.removeChild(downloadLink);
URL.revokeObjectURL(downloadLink.href);
}, 100);
successCount++;
} catch (error) {
console.error(`文件${index + 1}下载失败:`, error);
@ -242,16 +221,12 @@ console.log(dataList);
proxy.$message.warning(`成功下载${successCount}个文件,失败${failCount}个文件`);
}
} catch (error) {
console.error('文件下载失败:', error);
proxy.$message.error('文件下载失败,请稍后重试');
}
}
const deleteFile = (row) => {
proxy.$confirm('确定删除选中文件吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
proxy.$confirm('确定删除选中文件吗?', '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(() => {
deleteWjZzzAddEntity({ ids: [row.id] }).then(res => {
proxy.$message.success('删除成功');
getList();

View File

@ -1,12 +1,7 @@
/** 积分类型 */
export const jflylxTypes = {
'01': '信息采集',
'02': '肯定',
'03': '转会商',
'04': '转合成',
'05': '转线索',
'06': '建模型',
'07': '战术研判',
'08': '战略研判'
'01': '采纳',
'02': '转线索',
'03': '研判',
};

View File

@ -1,5 +1,5 @@
<template>
<el-dialog :model-value="modelValue" title="预警总数" width="70%" @close="closeDialog" destroy-on-close append-to-body>
<el-dialog :model-value="modelValue" :title="title" width="70%" @close="closeDialog" destroy-on-close append-to-body>
<div style="height: 60vh; overflow: auto;">
<Search :searchArr="searchConfiger" @submit="onSearch" :key="pageData.keyCount"></Search>
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :tableHeight="pageData.tableHeight"
@ -61,13 +61,16 @@ import { qcckGet, qcckPost } from "@/api/qcckApi.js";
import { ref, reactive, getCurrentInstance, watch } from "vue";
import {timeValidate} from '@/utils/tools.js'
const { proxy } = getCurrentInstance()
const { D_BZ_YJJB, D_GS_ZDQT_YJLB, D_BZ_YJLX } = proxy.$dict("D_BZ_YJJB", "D_GS_ZDQT_YJLB", "D_BZ_YJLX"); //获取字典数据
const props = defineProps({
modelValue: {
type: Boolean,
default: false
},
type: {
type: String,
default: ''
},
dict: {
type: Object,
default: () => ({})
@ -89,9 +92,10 @@ const searchConfiger = ref([
},
]);
const emit = defineEmits(['update:modelValue'])
let today = new Date();
let startOfDay = new Date(today.getFullYear(), today.getMonth(), today.getDate());
let endOfDay = new Date(today.getFullYear(), today.getMonth(), today.getDate(), 23, 59, 59, 999);
const title = ref('')
let today = new Date();
let startOfDay = new Date(today.getFullYear(), today.getMonth(), today.getDate());
let endOfDay = new Date(today.getFullYear(), today.getMonth(), today.getDate(), 23, 59, 59, 999);
const closeDialog = () => {
emit('update:modelValue', false)
}
@ -138,6 +142,7 @@ const onSearch = (val) => {
}
watch(() => props.modelValue, (val) => {
if (val) {
title.value = props.type == 'wqs' ? '未签收预警' : props.type == 'yfk' ? '已反馈预警' : '预警总数'
// 获取今天的开始时间和结束时间
parameter.value = {startTime:timeValidate(startOfDay), endTime:timeValidate(endOfDay)}
changePage()
@ -150,10 +155,14 @@ pageData.tableConfiger.loading = true;
const promes = {
...parameter.value,
yjjbList:parameter.value.yjjbList? [parameter.value.yjjbList] : [],
yjlxList: ['01'],
yjlxList: ['01'],
pageCurrent: pageData.pageConfiger.pageCurrent,
pageSize: pageData.pageConfiger.pageSize
}
if(props.type == 'wqs') promes.czzt = '01';
if(props.type == 'yfk') promes.czzt = '03';
qcckPost(promes, '/mosty-gsxt/tbYjxx/getPageAllList').then((res) => {
pageData.total = res.total || 0;
pageData.tableConfiger.loading = false;

View File

@ -0,0 +1,78 @@
<template>
<div>
<el-dialog title="人员详情" v-model="dialogVisible" width="80%">
<MyTable
customClass="zdy_bkcz_table"
:tableData="pageData.tableData"
:tableColumn="pageData.tableColumn"
:tableHeight="pageData.tableHeight"
:key="pageData.keyCount"
:tableConfiger="pageData.tableConfiger"
>
<template #yjjb="{ row }">
<DictTag :value="row.yjjb" :tag="false" :color="bqYs(row.yjjb)" :options="D_BZ_YJJB" />
</template>
<template #yjLylx="{ row }">
<DictTag :value="row.yjLylx" :tag="false" :options="D_BZ_YJLY" />
</template>
<template #yjlb="{ row }">
<DictTag :value="row.yjlb" :options="D_BZ_YJLX" />
</template>
</MyTable>
</el-dialog>
</div>
</template>
<script setup>
import MyTable from "@/components/aboutTable/MyTable.vue";
import { ref, reactive,getCurrentInstance } from 'vue'
const { proxy } = getCurrentInstance();
const { D_BZ_YJJB, D_BZ_YJLX,D_BZ_YJLY } = proxy.$dict("D_BZ_YJJB","D_BZ_YJLX",'D_BZ_YJLY'); //获取字典数据
const dialogVisible = ref(false)
const pageData = reactive({
tableData: [],
keyCount: 0,
tableConfiger: {
loading: false,
rowHieght: 61,
haveControls: false,
showSelectType: "null",
showIndex: false,
stripe: true
},
tableHeight: 500,
tableColumn: [
{ label: "预警标签", prop: "yjbq", width: 120 },
{ label: "预警地址", prop: "yjdz" },
{ label: "预警级别", prop: "yjjb", showSolt: true, width: 85 },
{ label: "预警类别", prop: "yjlb", showSolt: true },
{ label: "来源类型", prop: "yjLylx", showSolt: true,width: 100 },
{ label: "预警时间", prop: "yjsj", width: 200 },
{ label: "所属部门", prop: "ssbm" },
{ label: "姓名", prop: "ryxm",width: 100 },
{ label: "身份证号", prop: "rysfzh", width: 170 },
{ label: "车牌号", prop: "cph" ,width: 100},
]
});
const bqYs = (val) => {
if (val == '01') {
return '#ff0202'
} else if (val == '02') {
return '#ff8c00'
} else if (val == '03') {
return '#ffd325'
} else if (val == '04') {
return '#0000ff'
}
}
const init = (list) => {
pageData.tableData = list || [];
dialogVisible.value = true;
}
defineExpose({
init
})
</script>

View File

@ -72,6 +72,19 @@
</el-icon>
</el-tooltip>
</div>
<div class="flex" style="position: absolute;z-index: 100;left: 70px;background-color: #07274d;height: 30px;text-align: center;line-height:30px;">
<div style="width: 30px;">
<el-icon :size="20" @click="showSeatch = !showSeatch" style="top: 3px;"><Search /></el-icon>
</div>
<div :style="{'width': showSeatch ? '270px' : '0'}" class="trnsitinForm">
<el-input v-model="searchText" placeholder="请输入身份证" clearable>
<template #append>
<el-button type="primary" @click="handleSearch">搜索</el-button>
</template>
</el-input>
</div>
<!-- 搜索 -->
</div>
<div style="width: 100%;border: 1px sienna;position: relative">
<GdMap></GdMap>
</div>
@ -108,12 +121,14 @@
</div>
<!-- 左边弹窗 -->
<LeftDialog></LeftDialog>
<!-- 人员弹窗 -->
<PeoDialog ref="peoDialogRef"></PeoDialog>
</template>
<script setup>
import { qcckGet ,qcckPost} from "@/api/qcckApi.js";
import { ref, onMounted, onUnmounted,getCurrentInstance } from 'vue'
import PeoDialog from './components/peoDialog.vue'
import LeftDialog from './dialog/leftDialog'
import GdMap from "@/components/GdMap/index.vue";
import Head from './layout/head.vue'
@ -146,6 +161,9 @@ const { proxy } = getCurrentInstance();
const { D_BZ_JQDJ } = proxy.$dict('D_BZ_JQDJ')
const webSoket = new WebSoketClass()
const modelWarning = ref(true)
const searchText = ref('')
const peoDialogRef = ref()
const showSeatch = ref(false)
const changeXzqh = (val, trg) => {
setTimeout(() => {
// 先移除已有的边界
@ -348,6 +366,17 @@ onMounted(() => {
})
})
// 搜索
const handleSearch = () => {
if(!searchText.value){
proxy.$message.warning('请输入身份证号')
}else{
qcckPost({ rysfzh: searchText.value },'/mosty-gsxt/tbYjxx/getPageAllList').then(res => {
peoDialogRef.value.init(res.records || [])
})
}
}
// 布控预警上图
const getTbYjxxGetList = () => {
// 设置为当天时间范围00:00:00 到 23:59:59
@ -556,4 +585,9 @@ onUnmounted(() => {
backface-visibility: hidden;
perspective: 1000px;
}
.trnsitinForm {
overflow: hidden;
transition: all 0.3s ease;
}
</style>

View File

@ -42,8 +42,8 @@ const checkData = reactive({
hasChoose: ["一级", "二级", "三级", "四级"]
});
const checkDatas = reactive({
list: ["布控", "行为", "身份", "组合"],
hasChoose: ["布控"]
list: ['七类重点人','布控','无人机'],
hasChoose: ['七类重点人']
});
const total = ref(0);
const yjJb = ref(['01', '02', '03', '04']);
@ -88,21 +88,10 @@ function changeDatas(val) {
personList.value = [];
checkDatas.hasChoose = val;
let ids = [];
if (val.includes('布控')) {
typeS.value = true
yjJb.value = ['01', '02', '03', '04']
} else {
yjJb.value = []
typeS.value = false
}
val.forEach(it => {
if (it == '布控') {
ids.push('01')
typeS.value = true
};
if (it == '行为') ids.push('02');
if (it == '身份') ids.push('03');
if (it == '组合') ids.push('04');
if (it == '七类重点人') ids.push('01');
if (it == '布控') ids.push('02');
if (it == '无人机') ids.push('03');
});
yjLx.value = ids
if (val.length == 0) personList.value = [];
@ -169,8 +158,9 @@ const loadList = () => {
}
const ORDIMG = 'https://89.40.7.122:38496/image'
const IMGYM = 'https://sg.lz.dsj.xz/dhimage'
const getList = (type) => {
let data = { pageSize: 30, pageCurrent: pageNum.value, yjjbList: yjJb.value, yjlxList: yjLx.value };
let data = { pageSize: 30, pageCurrent: pageNum.value, yjjbList: yjJb.value, lylxList: yjLx.value };
loading.value = !type ? true : false;
getPageAllList(data).then(res => {
loading.value = false;

View File

@ -1,38 +1,36 @@
<template>
<div class="ww100 h80 flex just-between align-center pl10 pr10">
<div class="flex align-center" v-for="(item, idx) in contentItem" :key="idx" @click="openTc(item.type)">
<div class="flex align-center" v-for="(item, idx) in contentItem" :key="idx">
<div class="mr10"><img :src="item.icon" alt=""></div>
<div class="vountItem">
<div style="color:#ffffff" class="f16 lh20">{{ item.label }}</div>
<div style="color:#ffffff" class="f16 lh20">{{ item.label }} <span @click="openTc(item.type,'zs')" v-if="item.type == 'yjzs'">{{ item.value }}</span></div>
<div v-if="!item.isChild" class="mt4 f12" style="color: #ffffff;font-size: 24px;">{{ item.value }}</div>
<div v-else class="mt4 flex align-center just-between" style="color: #ffffff;">
<!-- 未处置 -->
<span class="f24" style="color: #ff0000;" title="未处置">0</span>
<!-- 已处置 -->
<span class="f24" style="color: #4cf35d;" title="已处置">0</span>
<span class="f12" style="color: #ff0000;" @click="openTc(item.type,'wqs')">未签收:{{ item.wqsyj }}</span>
<span class="f12" style="color: #4cf35d;" @click="openTc(item.type,'yfk')">已反馈:{{ item.yfkyj }}</span>
</div>
</div>
</div>
</div>
<PoliceReports v-model="openJqzs"/>
<NumberWarnings v-model="openYjzs"/>
<NumberWarnings v-model="openYjzs" :type="yjType" />
<keyPerson v-model="openZdry"/>
<keyGroups v-model="openZdqt"/>
</template>
<script setup>
import { qcckPost } from "@/api/qcckApi.js";
import { ref, onMounted } from "vue";
import { ref, onMounted, reactive } from "vue";
import PoliceReports from '@/views/home/components/policeReports.vue'
import NumberWarnings from '@/views/home/components/numberWarnings.vue'
import keyPerson from "@/views/home/components/keyPerson.vue";
import keyGroups from "@/views/home/components/keyGroups.vue";
const contentItem = ref([
const contentItem = reactive([
{ type:"jqzs", label: "今日警情", value: "0" ,icon:require('@/assets/images/top-1.png')},
{ type:"yjzs", label: "今日预警", value: "0",wqsyj:"0",yfkyj:"0",isChild:true,icon:require('@/assets/images/top-2.png') },
{ type:"zdry", label: "重点人员总数", value: "0",icon:require('@/assets/images/top-3.png') },
{ type:"zdqt", label: "重点群体总数", value: "0" ,icon:require('@/assets/images/top-4.png')},
{ type:"yjzs", label: "今日预警", value: "0",isChild:true,icon:require('@/assets/images/top-2.png') },
]);
onMounted(() => {
@ -42,8 +40,12 @@ onMounted(() => {
const getCount = () =>{
qcckPost({},'/mosty-gsxt/qbcj/getXscjTjForZs').then(res=>{
for(let key in res){
let index = contentItem.value.findIndex(v=>key == v.type)
if(index != -1) contentItem.value[index].value = res[key];
let index = contentItem.findIndex(v=>key == v.type)
if(index != -1) contentItem[index].value = res[key];
if(key == 'wqsyj' || key == 'yfkyj') {
let inx = contentItem.findIndex(v=> v.type == 'yjzs' )
contentItem[inx][key] = res[key];
}
}
})
}
@ -54,12 +56,14 @@ const openJqzs = ref(false)
const openYjzs = ref(false)
const openZdry = ref(false)
const openZdqt = ref(false)
const openTc = (val) => {
const yjType = ref('')
const openTc = (val,type) => {
switch (val) {
case 'jqzs':
openJqzs.value = true
break;
case 'yjzs':
yjType.value = type
openYjzs.value = true
break;
case 'zdry':