guanqb
2023-03-31 9c6dc1b100a7a878e4fc2543f5c2d12e5d004566
src/views/home/components/leftContainer.vue
@@ -45,10 +45,10 @@
                <defs>
                    <path id="border-box-8-path-974b4d7cfafa444396861ca1d1173c8c"
                        d="M0.27,0.03c52.66,0,105.34,0,158,0c1.67,2,3.33,4,5,6c1,0.33,2,0.67,3,1c1.33,1.67,2.67,3.33,4,5
                                                                                                                                                                                                                            c16,0,32,0,48,0c53.66,0,107.34,0,161,0c1.13,1.72,0.63,1.36,3,2c0,0.67,0,1.33,0,2c0.67,0,1.33,0,2,0
                                                                                                                                                                                                                            c0.01,104.58,0.01,206.44,0,309c-1.43,0.78-4.01,2.77-5,4c-12,0-24,0-36,0c-2.67-3.33-5.33-6.67-8-10c-21,0-42,0-63,0
                                                                                                                                                                                                                            c-1.08,2.32-2.35,4.25-4,6c-0.67,0.33-1.33,0.67-2,1c-0.33,1-0.67,2-1,3c-20,0-40,0-60,0c-66.66,0-133.34,0-200,0
                                                                                                                                                                                                                            c-1.28-1.57-2.76-2.25-4-4c-0.33,0-0.67,0-1,0c0-8.67,0-17.33,0-26c0-19.66,0-39.34,0-59C0.27,160.04,0.27,80.02,0.27,0.03z"
                                                                                                                                                                                                                                                                                        c16,0,32,0,48,0c53.66,0,107.34,0,161,0c1.13,1.72,0.63,1.36,3,2c0,0.67,0,1.33,0,2c0.67,0,1.33,0,2,0
                                                                                                                                                                                                                                                                                        c0.01,104.58,0.01,206.44,0,309c-1.43,0.78-4.01,2.77-5,4c-12,0-24,0-36,0c-2.67-3.33-5.33-6.67-8-10c-21,0-42,0-63,0
                                                                                                                                                                                                                                                                                        c-1.08,2.32-2.35,4.25-4,6c-0.67,0.33-1.33,0.67-2,1c-0.33,1-0.67,2-1,3c-20,0-40,0-60,0c-66.66,0-133.34,0-200,0
                                                                                                                                                                                                                                                                                        c-1.28-1.57-2.76-2.25-4-4c-0.33,0-0.67,0-1,0c0-8.67,0-17.33,0-26c0-19.66,0-39.34,0-59C0.27,160.04,0.27,80.02,0.27,0.03z"
                        fill="transparent" />
                    <radialGradient id="border-box-8-gradient-974b4d7cfafa444396861ca1d1173c8c" cx="50%" cy="50%" r="50%">
                        <stop offset="0%" stop-color="#fff" stop-opacity="1" />
@@ -58,10 +58,10 @@
                        <circle cx="0" cy="0" r="150" fill="url(#border-box-8-gradient-974b4d7cfafa444396861ca1d1173c8c)">
                            <animateMotion dur="8s"
                                path="M0.27,0.03c52.66,0,105.34,0,158,0c1.67,2,3.33,4,5,6c1,0.33,2,0.67,3,1c1.33,1.67,2.67,3.33,4,5
                                                                                                                                                                                                                                    c16,0,32,0,48,0c53.66,0,107.34,0,161,0c1.13,1.72,0.63,1.36,3,2c0,0.67,0,1.33,0,2c0.67,0,1.33,0,2,0
                                                                                                                                                                                                                                    c0.01,104.58,0.01,206.44,0,309c-1.43,0.78-4.01,2.77-5,4c-12,0-24,0-36,0c-2.67-3.33-5.33-6.67-8-10c-21,0-42,0-63,0
                                                                                                                                                                                                                                    c-1.08,2.32-2.35,4.25-4,6c-0.67,0.33-1.33,0.67-2,1c-0.33,1-0.67,2-1,3c-20,0-40,0-60,0c-66.66,0-133.34,0-200,0
                                                                                                                                                                                                                                    c-1.28-1.57-2.76-2.25-4-4c-0.33,0-0.67,0-1,0c0-8.67,0-17.33,0-26c0-19.66,0-39.34,0-59C0.27,160.04,0.27,80.02,0.27,0.03z"
                                                                                                                                                                                                                                                                                                c16,0,32,0,48,0c53.66,0,107.34,0,161,0c1.13,1.72,0.63,1.36,3,2c0,0.67,0,1.33,0,2c0.67,0,1.33,0,2,0
                                                                                                                                                                                                                                                                                                c0.01,104.58,0.01,206.44,0,309c-1.43,0.78-4.01,2.77-5,4c-12,0-24,0-36,0c-2.67-3.33-5.33-6.67-8-10c-21,0-42,0-63,0
                                                                                                                                                                                                                                                                                                c-1.08,2.32-2.35,4.25-4,6c-0.67,0.33-1.33,0.67-2,1c-0.33,1-0.67,2-1,3c-20,0-40,0-60,0c-66.66,0-133.34,0-200,0
                                                                                                                                                                                                                                                                                                c-1.28-1.57-2.76-2.25-4-4c-0.33,0-0.67,0-1,0c0-8.67,0-17.33,0-26c0-19.66,0-39.34,0-59C0.27,160.04,0.27,80.02,0.27,0.03z"
                                rotate="auto" repeatCount="indefinite" />
                        </circle>
                    </mask>
@@ -130,34 +130,15 @@
            </svg>
        </div>
        <el-dialog title="学校" :modal="false" :visible.sync="xxPopupShow" :before-close="landBeforeClose"
            :close-on-click-modal="true" class="land-details-box" v-loading="landLoading" element-loading-text="拼命加载中"
            element-loading-spinner="el-icon-loading" element-loading-background="rgba(0, 0, 0, 0.2)">
            <el-table :data="xxArr" style="width: 100%"
                :header-cell-style="{ 'text-align': 'center', 'background-color': '#203c60', 'borderColor': '#324e75' }"
                :cell-style="{ 'text-align': 'center', 'borderColor': '#324e75', 'cursor': 'default' }">
                <el-table-column :show-overflow-tooltip="true" prop="XSQ" label="县(市、区)"></el-table-column>
                <el-table-column :show-overflow-tooltip="true" prop="name" label="学校名称"></el-table-column>
                <el-table-column :show-overflow-tooltip="true" prop="DZ" label="地址"></el-table-column>
                <el-table-column label="操作" align="center">
                    <template slot-scope="scope">
                        <el-button @click="rowClick(scope.row)" type="text" size="small" title="定位">
                            <i class="el-icon-location"></i>
                        </el-button>
                    </template>
                </el-table-column>
            </el-table>
        </el-dialog>
    </div>
</template>
<script>
import { fontSize } from '@/utils/fontSize.js'
import { getAreaStatisticInfo } from "@/api/home/index.js"
import { schoolJSON } from '../homeleft/school'
import { getVillagePersonStatisticInfo, getVillagePersonStatisticInfoByPoliceStationId, getPersonInfo, getPersonInfoPage, getHouseStatisticInfo } from "@/api/dept"
import { schoolJSON } from '../homeleft/school.js'
let homePersonmyChart = null
let keyPersonmyChart = null
@@ -176,7 +157,6 @@
    data () {
        return {
            tabType: 0,
            landLoading: false,
            peopletype: 0,
            tabTypeTwo: 0,
            tabTypeThree: 0,
@@ -197,8 +177,6 @@
            personAll: '',
            // 记录当前选中派出所的ID
            policeStaionID: '',
            xxPopupShow: false,
            xxArr: [],
            peopleLoading: false,
        }
    },
@@ -218,45 +196,10 @@
        this.$nextTick(() => {
            window.addEventListener("resize", this.echartsResize)
            if (this.userInfo.dept_id == '1596020515064381442') {
                schoolJSON.forEach(item => {
                    if (item.x && item.x != '' && item.y && item.y != '') {
                        this.$EventBus.$emit('layerPointAdd', {
                            layerName: 'schoolJSONlayer',
                            type: "billboard",
                            layerType: 'ClusterLayer',
                            params: {
                                lng: Number(item.x),
                                lat: Number(item.y),
                                url: '/img/icon/school.png'
                            }
                        })
                    }
                })
            }
        })
    },
    methods: {
        rowClick (row) {
            if (row.x == '' || row.y == '') {
                this.$message({
                    message: '暂无位置信息',
                    type: 'warning'
                })
                return
            }
            this.$EventBus.$emit('toPosition', {
                layerName: 'carLayers',
                siteJd: row.x,
                siteWd: row.y
            })
            this.xxPopupShow = false
        },
        /**
         * @description: 获取首页的所有数据
         * @return {*}
@@ -668,7 +611,7 @@
                        // barWidth: '10%',
                        barCategoryGap: '80%',
                        zlevel: 2,
                        // cursor: 'default',
                        cursor: this.userInfo.dept_id != '1596020515064381442' ? 'default' : 'pointer',
                        itemStyle: {
                            normal: {
                                // barBorderRadius: [0, 30, 30, 0],
@@ -865,11 +808,12 @@
            houseMyChart.on('click', params => {
                console.log('clickHouseChart', params)
                if (params.name == '学校') {
                    this.xxPopupShow = true
                    this.landLoading = true
                    this.$parent.xxPopupShow = true
                    this.$parent.houseArr = []
                    this.$parent.houseLoading = true
                    setTimeout(() => {
                        this.landLoading = false
                        this.xxArr = schoolJSON
                        this.$parent.houseLoading = false
                        this.$parent.houseArr = schoolJSON
                    }, 1000)
                }
            })