派生自 wuyushui/SewerAndRainNetwork

chenzeping
2021-04-01 1602bcb0af9757e6d3af0b509060c4c0a40e1ba8
src/components/LayerController/logic/WasteGas.js
@@ -18,13 +18,10 @@
   * @param L leaflet对象
   */
  this.init = async (layer, L) => {
    this.animalService = new AnimalService({
      L: L,
      layer: layer
    })
    const res = await mapApi.GetWasteGas()
    this.animalService = new AnimalService({ L: L, layer: layer })
    const res = await mapApi.getWasteGas()
    const data = res.Result.DataInfo || {}
    console.log(data)
    // console.log(data)
    for (let i = 0; i < data.length; i++) {
      // 经纬度 位置
      const positionX = data[i].Latitude
@@ -53,13 +50,13 @@
  this.clickListener = async (e) => {
    // console.log(e)
    this.animalService.pulseEffect(e.latlng)
    const dataValue = {
      StoragePlaceId: e.layer.options.test.StoragePlaceId
    }
    const result = await mapApi.GetWasteGas(dataValue)
    // const dataValue = {
    //   StoragePlaceId: e.layer.options.test.StoragePlaceId
    // }
    // const result = await mapApi.getWasteGas(dataValue)
    const PublicBounced = window.Vue.extend(publicBounced)
    const instance = new PublicBounced()
    instance.setData(result)
    instance.setData(e.layer.options.test)
    instance.$mount()
    document.body.appendChild(instance.$el)
  }