2025-04-15 14:38:12 +08:00
|
|
|
|
<template>
|
2025-05-20 16:06:20 +08:00
|
|
|
|
<div class="ww100 h80 flex just-between align-center pl10 pr10">
|
2025-12-26 09:39:22 +08:00
|
|
|
|
<div class="flex align-center" v-for="(item, idx) in contentItem" :key="idx" @click="openTc(item.type)">
|
2025-04-15 14:38:12 +08:00
|
|
|
|
<div class="mr10"><img :src="item.icon" alt=""></div>
|
|
|
|
|
|
<div class="vountItem">
|
2025-07-12 18:34:34 +08:00
|
|
|
|
<div style="color:#ffffff" class="f16 lh20">{{ item.label }}</div>
|
2026-01-26 14:38:32 +08:00
|
|
|
|
<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>
|
|
|
|
|
|
</div>
|
2025-04-15 14:38:12 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2025-12-26 09:39:22 +08:00
|
|
|
|
<PoliceReports v-model="openJqzs"/>
|
|
|
|
|
|
<NumberWarnings v-model="openYjzs"/>
|
|
|
|
|
|
<keyPerson v-model="openZdry"/>
|
|
|
|
|
|
<keyGroups v-model="openZdqt"/>
|
2025-04-15 14:38:12 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script setup>
|
2025-07-14 10:09:55 +08:00
|
|
|
|
import { qcckPost } from "@/api/qcckApi.js";
|
|
|
|
|
|
import { ref, onMounted } from "vue";
|
2025-12-26 09:39:22 +08:00
|
|
|
|
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";
|
|
|
|
|
|
|
2025-04-15 14:38:12 +08:00
|
|
|
|
const contentItem = ref([
|
2025-12-27 11:10:31 +08:00
|
|
|
|
{ type:"jqzs", label: "今日警情", value: "0" ,icon:require('@/assets/images/top-1.png')},
|
2025-11-22 21:59:58 +08:00
|
|
|
|
{ type:"zdry", label: "重点人员总数", value: "0",icon:require('@/assets/images/top-3.png') },
|
|
|
|
|
|
{ type:"zdqt", label: "重点群体总数", value: "0" ,icon:require('@/assets/images/top-4.png')},
|
2026-01-26 14:38:32 +08:00
|
|
|
|
{ type:"yjzs", label: "今日预警", value: "0",isChild:true,icon:require('@/assets/images/top-2.png') },
|
2025-04-15 14:38:12 +08:00
|
|
|
|
]);
|
2025-07-14 10:09:55 +08:00
|
|
|
|
|
|
|
|
|
|
onMounted(() => {
|
|
|
|
|
|
getCount()
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
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];
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
2025-12-26 09:39:22 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 打开警情总数
|
|
|
|
|
|
const openJqzs = ref(false)
|
|
|
|
|
|
const openYjzs = ref(false)
|
|
|
|
|
|
const openZdry = ref(false)
|
|
|
|
|
|
const openZdqt = ref(false)
|
|
|
|
|
|
const openTc = (val) => {
|
|
|
|
|
|
switch (val) {
|
|
|
|
|
|
case 'jqzs':
|
|
|
|
|
|
openJqzs.value = true
|
|
|
|
|
|
break;
|
|
|
|
|
|
case 'yjzs':
|
|
|
|
|
|
openYjzs.value = true
|
|
|
|
|
|
break;
|
|
|
|
|
|
case 'zdry':
|
|
|
|
|
|
openZdry.value = true
|
|
|
|
|
|
break;
|
|
|
|
|
|
case 'zdqt':
|
|
|
|
|
|
openZdqt.value = true
|
|
|
|
|
|
break;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2025-04-15 14:38:12 +08:00
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
|
.vountItem{
|
|
|
|
|
|
width: 128px;
|
|
|
|
|
|
height: 50px;
|
|
|
|
|
|
background: url('~@/assets/images/line.png') no-repeat bottom center;
|
|
|
|
|
|
}
|
2025-08-01 17:16:03 +08:00
|
|
|
|
</style>
|