更新大屏

This commit is contained in:
2025-07-14 18:15:09 +08:00
parent 694ad9a54c
commit 446304ae1b
6 changed files with 18 additions and 30 deletions

View File

@ -38,6 +38,7 @@ export function resetForm(refName) {
//当type=1时获取出生日期,type=2时获取性别,type=3时获取年龄
export function IdCard(IdCard, type) {
//获取出生日期
if(!IdCard) return;
if (type === 1) {
return IdCard.substring(6, 10) + "-" + IdCard.substring(10, 12) + "-" + IdCard.substring(12, 14)
}

View File

@ -1,7 +1,7 @@
<template>
<div class="warning-card flex align-center" :class="changeBG(item.yjjb)">
<div class="warning-image">
<img :src="item.yjTp" alt="预警图片" />
<img :src="item.yjTp" width="80" height="120" alt="" />
</div>
<div class="warning-info">
<div class="flex just-between align-center">

View File

@ -1,10 +1,10 @@
<template>
<DialogDragger :title="props.data.type" top="150px" v-model="props.show" @close="close">
<ul class="warningList" ref="gjyjList" v-loading="loading">
<li v-for="item in warningList" :key="item.id">
<DialogDragger title="预警详情" top="150px" v-model="props.show" @close="close">
<ul class="warningList" ref="gjyjList">
<li v-for="item in props.data" :key="item.id">
<YjItem :data="item"/>
</li>
<MOSTY.Empty :show="!loading && warningList.length <= 0" :imgSize="150"></MOSTY.Empty>
<MOSTY.Empty :show="props.data.length <= 0" :imgSize="150"></MOSTY.Empty>
</ul>
</DialogDragger>
</template>
@ -12,46 +12,34 @@
import * as MOSTY from "@/components/MyComponents/index";
import DialogDragger from "@/views/home/layout/dialogDragger.vue";
import YjItem from "@/views/home/components/yjItem.vue";
import { ref, onMounted, getCurrentInstance, defineProps, watch } from "vue";
import { ref, defineProps } from "vue";
import emitter from "@/utils/eventBus.js";
const { proxy } = getCurrentInstance();
const warningList = ref([]); //预警列表数据
const pageCurrent = ref(1);
const gjyjList = ref(null); //预警列表数据
const loading = ref(false);
//参数传递
const props = defineProps({
//某条预警详情
data: {
type:Object,
default:{}
type:Array,
default:[]
},
show: {
type:Boolean,
default:false
},
//标题数据
title: String
});
onMounted(() => {
});
// 监听视频地址变化
watch(() => props.data,(val) => {
pageCurrent.value = 1;
},{ immediate: true, deep: true });
//关闭
function close() {
emitter.emit('deletePointArea','home_yj_map');
emitter.emit("showHomeYJ",false);
}
</script>
<style lang="scss" scoped>
@import "@/assets/css/homeScreen.scss";
.dialogBox {
z-index: 999;
ul.warningList{
height: calc(100vh - 198px);
overflow: hidden;

View File

@ -1,12 +1,11 @@
<template>
<div class="noScollLine">
<!-- 预警信息弹框 -->
<Home_YJ v-if="isShow.showYj" :show="isShow.showYj" :data="list.yjxqInfo" />
<Home_YJ v-if="isShow.showYj" :show="isShow.showYj" :data="list.Info_YJ" />
</div>
</template>
<script setup>
import { qcckPost, qcckGet } from "@/api/qcckApi.js";
import emitter from "@/utils/eventBus.js";
import Home_YJ from "./components/home_yj.vue";
import { ref, onMounted, onUnmounted, reactive, getCurrentInstance } from "vue";
@ -22,8 +21,7 @@ onMounted(() => {
// 展示预警
emitter.on("showHomeYJ", (res) => {
isShow.value.showYj = res ? true : false;
console.log(res,'====');
// if (res) list.Info_YJ = res;
if (res) list.Info_YJ = res;
});
});
onUnmounted(() => {

View File

@ -30,11 +30,11 @@
</div>
<!-- 左边弹窗 -->
<!-- <LeftDialog></LeftDialog> -->
<LeftDialog></LeftDialog>
</template>
<script setup>
// import LeftDialog from './dialog/leftDialog'
import LeftDialog from './dialog/leftDialog'
import GdMap from "@/components/GdMap/index.vue";
import Head from './layout/head.vue'
import DbCount from './model/dbCount.vue'

View File

@ -4,7 +4,7 @@
</div>
<div class="comom-cnt zdryBox">
<div style="height:33px;">
<CheckBox :data="checkData" @changeData="changeData"></CheckBox>
<CheckBox :data="checkData" @changeData="changeData"></CheckBox>
</div>
<ul class="ryBox" v-loading="loading" v-infinite-scroll="loadList" style="overflow: auto">
<li v-for="item in personList" :key="item.id" @click="chooseItem(item)">
@ -72,8 +72,8 @@ const getList = () =>{
}
const chooseItem = (item) =>{
emitter.emit('showHomeYJ',[item]);
emitter.emit('deletePointArea','home_yj_map');
console.log(item.jd,item.wd);
if(!item.jd || !item.jd) return proxy.$message({ type: "warning", message: "该预警没有坐标!" });
let icon = require('@/assets/point/yj.png');
if(item.yjjb == '20') icon = require('@/assets/point/yj1.png');
@ -94,6 +94,7 @@ const chooseItem = (item) =>{
@import "@/assets/css/homeScreen.scss";
.zdryBox{
background: #052249;
height: 100%;
.ryBox{
height: calc(100% - 33px);
overflow: hidden;