<template>
  <div v-show="visible">
    <div class="infoWindowBox">
      <div class="inner">
        <div>液体流速≥500</div>
        <div><span>16:55:55</span> 预警</div>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  data() {
    return {
      infoWindow: null,
      visible:false,
      irrigateModel:"1",
      switchVal:true,
      show:true,
      form:{
        val:1
      },
      options: [{
        value: '选项1',
        label: '液位'
      }, {
        value: '选项2',
        label: '累计流量'
      }],

      currEquip: {
        device_type_id:null,
        device_id:null,
        device_name:null,
        city:null,
        addtime:0,
      }
    };
  },
  methods: {
    initialize(e) {
      this.visible = e.visible;
      this.currEquip = e.currEquip;
      this.infoWindow = e.infoWindow;
    },
    //关闭
    close() {
      this.infoWindow.close();
    },
    switchShow(falg){
      this.show = falg
    }
  },
  mounted(){
    let infoWindow = new AMap.InfoWindow({
        isCustom: true,
        content: '',
        offset: new AMap.Pixel(-225, -11),
    });
    this.initialize({
        currEquip: {},
        visible: false,
        infoWindow: infoWindow,
    })
  }
};
</script>
 
<style  scoped lang="less">
.infoWindowBox{
  background: url('../../../../../static/images/irrigate/wranBj.png') no-repeat;
  width: 225px;
  height: 69px;
  background-size: 100%;
  color: #fff;
  .inner{
    width: 137px;
    text-align: right;
    line-height: 27px;
    padding: 6px 0;
    font-size: 14px;
     >div{
      span{
        font-size: 20px;
      }
    }
  }
 
}

</style>
