shuishen
2023-01-11 99294494dced6f985ad7cbe1b36c1003a6327637
删除多余代码,报警信息准备接入
2 files modified
133 ■■■■■ changed files
src/styles/media/index.scss 3 ●●●● patch | view | raw | blame | history
src/views/house/index.vue 130 ●●●●● patch | view | raw | blame | history
src/styles/media/index.scss
@@ -775,8 +775,7 @@
                                    }
                                }
                                .police-info,
                                .warning-info {
                                .police-info {
                                    .tableClass {
                                        width: countSizeVw(600, 1920);
                                        height: countSizeVh(400);
src/views/house/index.vue
@@ -2,7 +2,7 @@
 * @Author: shuishen 1109946754@qq.com
 * @Date: 2022-08-18 16:18:17
 * @LastEditors: shuishen 1109946754@qq.com
 * @LastEditTime: 2023-01-11 17:09:36
 * @LastEditTime: 2023-01-11 17:41:19
 * @FilePath: \srs-police-affairs\src\views\house\index.vue
 * @Description: 小区-栋-层-房屋
 * 
@@ -70,7 +70,6 @@
                <div class="nav-tab">
                    <div class="nav" :class="navType == 0 ? 'choosed' : ''" @click="navClick" data-type="0">基本信息</div>
                    <div class="nav" :class="navType == 1 ? 'choosed' : ''" @click="navClick" data-type="1">报警信息</div>
                    <div class="nav" :class="navType == 2 ? 'choosed' : ''" @click="navClick" data-type="2">出警信息</div>
                </div>
                <div class="base-info" v-show="navType == 0">
@@ -309,7 +308,7 @@
                </div>
                <div class="police-info" v-show="navType == 1">
                    <el-table :data="arr" style="width: 100%"
                    <el-table :data="callPoliceData" style="width: 100%"
                        :header-cell-style="{ 'text-align': 'center', 'background-color': '#203c60', 'borderColor': '#324e75' }"
                        :cell-style="{ 'text-align': 'center', 'borderColor': '#324e75' }"
                        :row-class-name="tableRowClassName" @row-click="clickData">
@@ -317,17 +316,12 @@
                        <el-table-column prop="time" label="时间" width="150"></el-table-column>
                        <el-table-column prop="type" label="类别" width="120"></el-table-column>
                    </el-table>
                </div>
                <div class="warning-info" v-show="navType == 2">
                    <el-table :data="warningArray" style="width: 100%"
                        :header-cell-style="{ 'text-align': 'center', 'background-color': '#203c60', 'borderColor': '#324e75' }"
                        :cell-style="{ 'text-align': 'center', 'borderColor': '#324e75' }"
                        :row-class-name="tableRowClassName" @row-click="clickData">
                        <el-table-column prop="name" label="名称" width="130"></el-table-column>
                        <el-table-column prop="time" label="时间" width="150"></el-table-column>
                        <el-table-column prop="type" label="类别" width="120"></el-table-column>
                    </el-table>
                    <div class="pages" ref="ElPagination" v-if="policeSituationHistoryArr.length > 0">
                        <el-pagination background layout="prev, pager, next" :page-size="callPolicePage.pageSize"
                            :page-count="callPolicePage.count" :current-page="callPolicePage.currentPage"
                            @current-change="handleCurrentChange"></el-pagination>
                    </div>
                </div>
            </div>
        </div>
@@ -433,6 +427,8 @@
import { listQuery, accurateSearch } from "@/utils/search.js"
import housingData from '@/assets/data/housingData.js'
import { getResidentialQuartersList, getResidentialQuartersInfo, getSearchExtensively, getAoiByPt, getUnitbuild, getHouses, getSearchExtensivelyBgAoiDeepdata } from '@/api/dept/index.js'
import { getAlarmList } from "@/api/home/index.js"
export default {
    data () {
@@ -442,70 +438,7 @@
            unitValue: 1,
            searchHouse: '',
            navType: 0,
            arr: [
                {
                    name: '物品遗失',
                    time: '2022-1-2',
                    type: '入室盗窃',
                    person: '张志强',
                    money: '1000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '12小时',
                    rank: '一般'
                },
                {
                    name: '狗狗互咬',
                    time: '2022-2-3',
                    type: '宠物殴打',
                    person: '张志强',
                    money: '1000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '16小时',
                    rank: '一般'
                },
                {
                    name: '打群架',
                    time: '2022-3-4',
                    type: '打架斗殴',
                    person: '张志强',
                    money: '1000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '1小时',
                    rank: '一般'
                }
            ],
            warningArray: [
                {
                    name: '楼层房屋起火',
                    time: '2022-1-2',
                    type: '火灾',
                    person: '张志强',
                    money: '100000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '12小时',
                    rank: '较大'
                },
                {
                    name: '台风过境',
                    time: '2022-2-3',
                    type: '天气',
                    person: '张志强',
                    money: '10000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '16小时',
                    rank: '一般'
                },
                {
                    name: '洪水',
                    time: '2022-3-4',
                    type: '水灾',
                    person: '张志强',
                    money: '1000000元',
                    turnoutArea: 'xxx责任区',
                    handlingTime: '1小时',
                    rank: '一般'
                }
            ],
            comeoutArr: [{ name: '入口1', position: '北门', type: '正门' }, { name: '入口2', position: '南门', type: '后门' }, { name: '入口3', position: '西门', type: '侧门' }],
            parkArr: [{ name: '停车场1', position: '北门', type: '地面停车场' }, { name: '停车场2', position: '南门', type: '地面停车场' }, { name: '停车场3', position: '西门', type: '地下停车场' }],
            businessArr: [{ name: '商铺1', position: '北门', type: '超市' }, { name: '商铺2', position: '南门', type: '水果店' }, { name: '商铺3', position: '西门', type: '快递站' }],
@@ -681,6 +614,15 @@
                }
            ],
            // 报警信息
            policeSituationHistoryArr: [],
            callPolicePage: {
                total: 0,
                pageSize: 15,
                count: 0,
                currentPage: 1
            }
        }
    },
    watch: {
@@ -723,6 +665,9 @@
    methods: {
        navClick (e) {
            this.navType = e.target.dataset.type
            // if (this.navType == 1) {
            // }
        },
        // 获取小区列表
@@ -822,11 +767,6 @@
        clickData (row) {
            this.dialogVisible = true
            if (this.navType == 1) {
                this.JWdetails = this.arr[row.index]
            } else if (this.navType == 2) {
                this.JWdetails = this.warningArray[row.index]
            }
        },
        residentDetailsClick (params) {
@@ -1094,6 +1034,32 @@
        goTOPeopleDetail () {
            this.keyPersonVisible = true
        },
        // 获取历史接警记录
        getAlarmList (params) {
            getAlarmList({ ...params, size: this.pagesize }).then(res => {
                this.callPolicePage.pageCount = res.data.data.pages
                this.callPoliceData = []
                if (res.data.data.records.length > 0) {
                    this.callPoliceData = res.data.data.records.map((item, index) => {
                        return { ...item, index: index + 1, lng: item.ZDDWXZB, lat: item.ZDDWYZB }
                    })
                } else {
                    this.callPoliceData = []
                }
                // this.setTableHeight()
            })
        },
        // 分页选择事件
        handleCurrentChange: function (currentPage) {
            this.callPolicePage.currentPage = currentPage
            this.getAlarmList({ current: this.currentPage })
        },
    },
    destroyed () {