quanyawei
2023-10-09 3c485604bcc08a2fbcf7f60c8669bdf9cc77d7dd
src/views/UVA/index.vue
@@ -45,8 +45,6 @@
          <el-collapse
            v-show="shou1 === true"
            v-loading="loading"
            accordion
            style="box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1)"
          >
            <el-collapse-item
              style="text-indent: 2em; position: relative; padding-botton: 10px"
@@ -146,8 +144,6 @@
                <span>无人机飞行高度范围(米): </span>
                <el-input
                  ref="uvas"
                  v-model="tallone"
                  class="inputtu"
                />
                --
                <el-input
@@ -1226,8 +1222,8 @@
      this.abc += 1
      const that = this
      if (!res) {
        that.map = new BMap.Map('map_container')
        console.log('BMap', BMap)
        that.map = new BMapGL.Map('map_container')
        console.log('BMapGL', BMapGL)
        console.log('BMapGL', BMapGL)
        console.log('window', window.BMapGL)
        that.map.enableScrollWheelZoom(true) // 开启鼠标滚轮,地图可以进行放大、缩小s
@@ -1308,7 +1304,7 @@
            // lat = GPS.bd_encrypt(lat, lng).lat
            // lng = GPS.bd_decrypt(lat, lng).lon
            // lat = GPS.bd_decrypt(lat, lng).lat
            var point = new BMap.Point(lng, lat)
            var point = new BMapGL.Point(lng, lat)
            point.a34004 = parseInt(value.a34004)
            point.a34002 = parseInt(value.a34002)
            point.a21026 = parseInt(value.a21026)
@@ -1330,7 +1326,7 @@
        // 已有地图,避免再次请求
        // if (!that.showPoints) {
        //   console.log(111)
        //   that.map = new BMapGL.Map('map_container')
        //   that.map = new window.BMapGL.Map('map_container')
        // }
        // that.map.enableScrollWheelZoom(true) // 开启鼠标滚轮,地图可以进行放大、缩小s
        // that.map.setMapType(BMAP_EARTH_MAP) // 设置地图类型为地球模式
@@ -1351,7 +1347,7 @@
        //   building: true, // 不显示建筑物
        //   poiText: false, // 显示poi文字
        // })
        // that.map.addControl(new BMapGL.NavigationControl3D()) // 添加3d控件
        // that.map.addControl(new window.BMapGL.NavigationControl3D()) // 添加3d控件
        if (this.responseJSON.length === 0) {
          showNoPoints()
        }
@@ -1419,12 +1415,12 @@
          var data = point[sensor]
          // 根据因子浓度变换方块颜色
          var color = getColorAndLevel(sensor, data).color
          var polygon = new BMap.Polygon(
          var polygon = new BMapGL.Polygon(
            [
              new BMap.Point(sw.lng, sw.lat), // 左下角
              new BMap.Point(ne.lng, sw.lat), // 左上角
              new BMap.Point(ne.lng, ne.lat), // 右上角
              new BMap.Point(sw.lng, ne.lat) // 右下角
              new BMapGL.Point(sw.lng, sw.lat), // 左下角
              new BMapGL.Point(ne.lng, sw.lat), // 左上角
              new BMapGL.Point(ne.lng, ne.lat), // 右上角
              new BMapGL.Point(sw.lng, ne.lat) // 右下角
            ],
            {
              strokeWeight: 0.1, // 边框线的宽度,以像素为单位
@@ -1443,24 +1439,24 @@
      // 起点和终点标注
      function drawStartAndEnd() {
        var startIcon = new BMap.Icon(
        var startIcon = new BMapGL.Icon(
          require('@/assets/images/start.png'),
          new BMap.Size(48, 48)
          new BMapGL.Size(48, 48)
        )
        var startMark = new BMap.Marker(that.showPoints[0], {
        var startMark = new BMapGL.Marker(that.showPoints[0], {
          icon: startIcon,
          offset: new BMap.Size(0, -20)
          offset: new BMapGL.Size(0, -20)
        })
        that.map.addOverlay(startMark)
        var endIcon = new BMap.Icon(
        var endIcon = new BMapGL.Icon(
          require('@/assets/images/end.png'),
          new BMap.Size(48, 48)
          new BMapGL.Size(48, 48)
        )
        var endMark = new BMap.Marker(
        var endMark = new BMapGL.Marker(
          that.showPoints[that.showPoints.length - 1],
          {
            icon: endIcon,
            offset: new BMap.Size(0, -20)
            offset: new BMapGL.Size(0, -20)
          }
        )
        that.map.addOverlay(endMark)
@@ -1540,7 +1536,7 @@
        lng = (lng * 180) / Math.PI
        lat = (lat * 180) / Math.PI
        // console.log(lng, lat)
        return new BMap.Point(lng, lat)
        return new BMapGL.Point(lng, lat)
      }
      function getGrading(sensor, type, carMac) {
@@ -1891,14 +1887,14 @@
      // point上添加label文本
      function setLabelStyle(content, point) {
        var label = new BMap.Label(
        var label = new BMapGL.Label(
          "<span class='my-maptip'>" + content + '<br /><span>', // 为lable填写内容
          {
            offset: new BMap.Size(-8, -10), // label的偏移量,为了让label的中心显示在点上
            offset: new BMapGL.Size(-8, -10), // label的偏移量,为了让label的中心显示在点上
            position: point
          } // label的位置
        )
        var offsetSize = new BMap.Size(0, 0)
        var offsetSize = new BMapGL.Size(0, 0)
        var size = '10px'
        if (that.map.getZoom() <= 15.5) {
          size = '0px'
@@ -2198,20 +2194,7 @@
/deep/.inputNum {
  width: 4% !important;
}
.dateArrClass {
  position: relative;
}
.dateArrClass > div ::after {
  content: '';
  position: absolute;
  right: 8px;
  top: 23px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  z-index: 999;
  background-color: #f40;
}
.numss {
  width: 700px;
  background-color: white;
@@ -2258,13 +2241,7 @@
    width: 20%;
  }
}
.jlpMySelectPopper.el-picker-panel {
  width: 280px;
  height: 330px;
}
.jlpMySelectPopper.el-date-picker table {
  width: 88%;
}
.BMap_cpyCtrl {
  display: none;
}
@@ -2283,3 +2260,26 @@
  overflow-x: hidden;
}
</style>
<style >
.jlpMySelectPopper.el-picker-panel {
  width: 280px;
  height: 330px;
}
.jlpMySelectPopper.el-date-picker table {
  width: 88%;
}
.dateArrClass {
  position: relative;
}
.dateArrClass > div ::after {
  content: '';
  position: absolute;
  right: 8px;
  top: 23px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  z-index: 999;
  background-color: #f40;
}
</style>