<template> <div class="zqindex"> <!--标题--> <header-title /> <div class="content"> <div class="center-bottom"> <!-- <map3d />--> </div> <!--左半--> <div v-if="chartShow" class="left"> <device-installed /> <device-alarm-sum /> <handling-alarm /> </div> <!--右半--> <div v-if="chartShow" class="right"> <seven-days-operation-status /> <line-department /> <device-alarm /> </div> </div> </div> </template> <script> import DeviceInstalled from '@/views/zhangqiu/components/deviceInstalled/deviceInstalled' import DeviceAlarmSum from '@/views/zhangqiu/components/deviceAlarmSum/deviceAlarmSum' import HandlingAlarm from '@/views/zhangqiu/components/handlingAlarm/handlingAlarm' import SevenDaysOperationStatus from '@/views/zhangqiu/components/sevenDaysOperationStatus/sevenDaysOperationStatus' import LineDepartment from '@/views/zhangqiu/components/lineDepartment/lineDepartment' import DeviceAlarm from '@/views/zhangqiu/components/deviceAlarm/deviceAlarm' import headerTitle from '@/views/zhangqiu/components/headerTitle.vue' import Map3d from '@/views/zhangqiu/components/map3d' export default { name: 'Zqindex', components: { Map3d, DeviceAlarm, LineDepartment, SevenDaysOperationStatus, HandlingAlarm, DeviceAlarmSum, DeviceInstalled, headerTitle }, data() { return { chartShow: true } } } </script> <style rel="stylesheet/scss" lang="scss" scoped> $titleHeight: 70px; .zqindex{ width: 100%; height: 100%; } .content{ width: 100%; height: 100%; // 总高度减去标题高度 position: relative; .left{ height: calc( 100vh - #{$titleHeight} ); position: absolute; left:0px; top:$titleHeight; z-index: 1001; flex:1; padding: 15px 60px 15px 20px ; background-image: linear-gradient(to right, rgba(19,19,32,1), rgba(19,19,32,0.7) 70%, rgba(19,19,32,0.0) ); } .right{ height: calc( 100vh - #{$titleHeight} ); position: absolute; right:0px; top:$titleHeight; z-index: 1001; flex:1; display: flex; justify-content: right; flex-direction: column; align-items: end; padding: 15px 20px 15px 60px; background-image: linear-gradient(to left, rgba(19,19,32,1), rgba(19,19,32,0.7) 70%, rgba(19,19,32,0.0) ); } } .full-container{ width:100%; //height: 100%; position: relative; .charts{ position: absolute; width: 100%; height: 100%; z-index: 1; left: 0px; top: 0px; //background-color: #1a2126; } } </style>