zengh
2021-07-20 eb6374fd3670ac6fec2725e5f3ccb708ea76f22c
public/map/widgets/alertSecurity/AlertSecurity.js
@@ -198,29 +198,6 @@
      var oneId = that.getQueryStringByKey('oneId');
      var baid = that.getQueryStringByKey('baid');
      that.addPoint(that.addEntitys, lgtd, lttd, './images/jingbaored.png');
      that.createEntitys(that.addEntitys, lgtd, lttd, './images/real-time-callPolice-opcity.png');
      that.createTwinkleEntitys(that.addEntitys, lgtd, lttd, './images/real-time-callPolice-opcity.png');
      // console.log(deptId,153454)
      $.ajax({
        url: "http://s16s652780.51mypc.cn/api/blade-user/pages?current=1&size=9999&work_status=&deptId=" + deptId,
        type: 'get',
        dataType: 'JSON',
        success: function (res) {
          // console.log(res.data.records, oneId)
          res.data.records.forEach((item) => {
            if (item.id == oneId) {
              that.addPoints(that.addEntitys, item.jd, item.wd, './images/security.png')
            }
          });
          res.data.records.forEach((item) => {
            if (item.roleName == "处警员" && item.id != oneId) {
              that.addPoints(that.addEntitys, item.jd, item.wd, './images/security.png')
            }
          });
          if (baid != null && baid != ""){
            $.ajax({
              url: "http://localhost:82/routeIn/routein/selectList?id=" + baid,
@@ -236,19 +213,17 @@
                  entityData = entityData[1].split(',');
                  for (var j = 0; j < entityData.length; j++) {
                    entityArr.push([Number(entityData[j].split(' ')[0]), Number(entityData[j].split(' ')[1])]);
                entityArr.push([Number(entityData[j].split(' ')[0]), Number(entityData[j].split(' ')[1])]);
                    // entityArr.push([Number(b[0]), Number(b[1])]);
                  }
                }
                that.addPolygonAll(that.addEntitys, entityArr);
            that._map.centerAndZoom(new esri.geometry.Point(entityArr[Math.ceil(entityArr.length / 2 )][0],entityArr[Math.ceil(entityArr.length / 2 )][1], new esri.SpatialReference({ wkid: 4326 })), 14);
              }
            })
          }
        }
      });
    },
    close: function () {