<template> <div class="bottom"> <i class="el-icon-close close-pop" @click="$emit('close')"/> <div class="block" style="padding: 10px"> <div style="display: flex;flex-wrap: wrap;flex-direction: row;justify-content: center"> <div class="num" style="text-align: left;width:100%;font-size: 20px;font-weight: bold">{{schoolName}}</div> <div class="num" style="color: #B3F3F6;width:100%;word-break: break-all;text-align: left;">位置:{{ schoolPosition }}</span></div> <div class="item" style="width: 51%"> <el-image :src="require('@/assets/images/function/教育/专项数据看板图标/在校生总数.png')" class="base-map-image" mode="fill" /> <div class="item-text"> <div class="num">{{list[0]}}<span class="unit">人</span></div> <div style="color: #B3F3F6;">在校生总数</div> </div> </div> <div class="item"> <el-image :src="require('@/assets/images/function/教育/专项数据看板图标/教师总数.png')" class="base-map-image" mode="fill" /> <div class="item-text"> <div class="num">{{list[1]}}<span class="unit">人</span></div> <div style="color: #B3F3F6;">教师总数</div> </div> </div> <div class="item"> <el-image :src="require('@/assets/images/function/教育/专项数据看板图标/教职工总数.png')" class="base-map-image" mode="fill" /> <div class="item-text"> <div class="num">{{list[2]}}<span class="unit">人</span></div> <div style="color: #B3F3F6;">教职工总数</div> </div> </div> </div> </div> <div class="block"> <div :style="{backgroundImage:'url('+titleImg+')'}" class="title">学生占比分析</div> <student-bar style="flex:1;" ref="studentBar"/> </div> <div class="block"> <div :style="{backgroundImage:'url('+titleImg+')'}" class="title">学生年龄分析</div> <age-pie style="flex:1;" ref="agePie"/> </div> <div class="block"> <div :style="{backgroundImage:'url('+titleImg+')'}" class="title">学生性别分析</div> <sex-pie style="flex:1;" ref="sexPie"/> </div> <div class="block"> <div :style="{backgroundImage:'url('+titleImg+')'}" class="title">近一年师生比分析</div> <ts-line-bar style="flex:1;" ref="tsLine"/> </div> <div class="block"> <div :style="{backgroundImage:'url('+titleImg+')'}" class="title">近一年教职工数量趋势</div> <teacher-line style="flex:1;" ref="teacherLine"/> </div> </div> </template> <script> import TeacherLine from "./components/teacherLine"; import TsLineBar from "./components/tsLineBar"; import StudentBar from "./components/studentBar"; import AgePie from "./components/agePie"; import SexPie from "./components/sexPie"; import {getPointInfo} from "../../../../api/ywts/shms/jy"; export default { name: 'SchoolPop', components: {SexPie, AgePie, StudentBar, TsLineBar, TeacherLine}, data() { return { titleImg: require('@/assets/images/popup/title.png'), // 背景图片 titleAll: require('@/assets/images/popup/title-all.png'),// 背景图片 list: ['', '', ''], schoolName: '', schoolPosition: '', } }, methods: { initData(item) { this.schoolName = item.name getPointInfo(item.id).then(res => { const data = res.data.value[0] if(res.code === 200) { this.schoolPosition = data.location this.list = [data.student, data.teacher, data.staff] } }) this.$refs.studentBar.fetchData(item.id) this.$refs.agePie.fetchData(item.id) this.$refs.sexPie.fetchData(item.id) this.$refs.tsLine.fetchData(item.id) this.$refs.teacherLine.fetchData(item.id) } } } </script> <style rel="stylesheet/scss" lang="scss" scoped> .bottom{ z-index: 111111111111; width: 100%; height: 220px; position: absolute; bottom: 10px; left: 0px; display: flex; overflow: hidden; padding: 0px 0px; .block{ flex: 1; height: 100%; display: flex; flex-wrap: wrap; background: linear-gradient(to top left, rgba(5, 30, 61, 0.62), #0D3F7E9D); border-radius: 5px; box-shadow: 4px 4px 40px rgba(0, 0, 0, .05); border-color: rgba(0, 0, 0, .05); margin: 0px 5px; flex-direction: column; } .block1{ width: 500px; height: 100%; display: flex; flex-wrap: wrap; background: linear-gradient(to top left, rgba(5, 30, 61, 0.62), #0D3F7E9D); border-radius: 5px; box-shadow: 4px 4px 40px rgba(0, 0, 0, .05); border-color: rgba(0, 0, 0, .05); margin: 0px 10px; flex-direction: column; } .title{ text-shadow: 0 0 5px #d1ffff; height: 35px; float: left; text-align: left; background-repeat: no-repeat; -webkit-background-size: 100% 100%; background-size: 100% 100% !important; color: white; font-weight: bold; padding-top: 4px; padding-left: 30px; font-family: 黑体; letter-spacing: 1px; } .item-text{ text-shadow: 0 0 2px #d1ffff; flex: 1; font-weight: bold; text-align: center; font-size: 18px; } .base-map-image{ width: 60px; height: 60px; } .num{ text-shadow: 0 0 5px #ffb441; color: #ffb441; font-size: 20px; padding-top: 2px; } .unit{ color: #B3F3F6; font-size: 14px; margin-left: 1px; } .item{ width: 50%; height: 35%; display: flex; justify-content: left; align-items: center; } } </style>