Newer
Older
ganzhou-feidu / src / pages / csdz / videoCloud / eventPop.vue
<template>
  <div class="bottom" :style="{left: `${windowPostion.x}px`, top: `${windowPostion.y}px`}">
    <i class="el-icon-close close-pop" @click="$emit('close')"/>
    <div class="children-item" style="width:100%;">
      <div style="width: 100%; display: flex; justify-content: space-between;">
        <span>
          <el-tag v-if="gdInfo.eventStatusName === '待立案'" size="mini">{{ gdInfo.eventStatusName }}</el-tag>
          <el-tag v-if="gdInfo.eventStatusName === '解决中'" type="warning" size="mini">{{ gdInfo.eventStatusName }}</el-tag>
          <el-tag v-if="gdInfo.eventStatusName === '已解决'" type="success" size="mini">{{ gdInfo.eventStatusName }}</el-tag>
          <el-tag v-if="gdInfo.eventStatusName === '未解决'" type="info" size="mini">{{ gdInfo.eventStatusName }}</el-tag>
          <span style="font-size: 1.15rem;font-weight: 700;margin-left: 10px;">{{ gdInfo.eventName }}
          </span>
        </span>
        <span>
          <el-tag v-if="gdInfo.urgencyName === '紧急高'" type="danger" size="mini">{{ gdInfo.urgencyName }}</el-tag>
          <el-tag v-else type="warning" size="mini">{{ gdInfo.urgencyName }}</el-tag>
        </span>
      </div>
      <div style="width: 100%;text-align: left;padding-left: 60px;">
        {{ `统一编码:${gdInfo.code}` }}
      </div>
      <div style="width: 100%;">
        <el-row :gutter="24">
          <el-col :span="10">
            <!-- <img :src="item.imgUrl" alt="" srcset="" > -->
            <img style="width: 100%; height: 6.8rem;" :src="gdInfo.imgUrl" fit="cover" />
          </el-col>
          <el-col :span="14" style="padding: 0;text-align: left;">
            <el-row :gutter="24">
              <el-col :span="12">事件来源:{{ gdInfo.report }}</el-col>
              <el-col :span="12">事件类别:{{ gdInfo.evenTypeName }}</el-col>
            </el-row>
            <el-row :gutter="24">
              <el-col :span="12">识别设备:{{ gdInfo.deviceName }}</el-col>
              <el-col :span="12">责任部门:{{ gdInfo.dutyDeptName }}</el-col>
            </el-row>
            <el-row :gutter="24">
              <el-col :span="24">时间:{{ gdInfo.createTime }}</el-col>
            </el-row>
            <el-row :gutter="24">
              <el-col :span="24">位置:{{ gdInfo.location }}</el-col>
            </el-row>
          </el-col>
        </el-row>
      </div>
  </div>
</div>
</template>

<script>
import { showPositin } from '@/utils/freedo/index'
export default {
  name: 'videoPop',
  data() {
    return {
      titleImg: require('@/assets/images/popup/title.png'), // 背景图片
      titleAll: require('@/assets/images/popup/title-all.png'),// 背景图片
      list: ['', '', '', ''],
      gdInfo: {},
      windowPostion: {x: window.innerWidth - 165, y: window.innerHeight }, // 弹窗的位置
    }
  },
  methods: {
    initData(item) {
      showPositin(item.lon, item.lat)
      // 弹窗位置
      if(window.localStorage.getItem('mousePosition')){
      this.windowPostion = {
          x: window.innerWidth / 2 - 165,
          y: window.innerHeight / 2
        }
      }
      else {
        this.windowPostion = {
          x: window.innerWidth / 2  - 165,
          y: window.innerHeight/ 2
        }
      }
      this.gdInfo = item
      // window.addEventListener('mousemove', (event) => {
      //   this.windowPostion = {
      //     x: event.clientX - 165,
      //     y: event.clientY - 250
      //   }
      // })
    }
  },
  // mounted(){

  // }
}
</script>

<style rel="stylesheet/scss" lang="scss" scoped>
.children-item {
  width: 96% !important;
  margin: 10px auto !important;
  color: #fff !important;
  // border: 1px solid #fff;
  border-radius: 6px;
  padding: 10px;
  box-sizing: border-box;

}
.bottom{
  z-index: 111111111111;
  width: 100%;
  height: 180px;
  width: 35rem;
  position: absolute;
  bottom: 10px;
  left: 0px;
  display: flex;
  overflow: hidden;
  padding: 10px;
  padding-right: 20px;
  background: url("../../../assets/images/popup/case/事件看板背景.png") !important;
  background-size: 100% 100% !important;

  .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: 25%;
    height: 32%;
    display: flex;
    justify-content: left;
    align-items: center;
  }
}
</style>