派生自 wuyushui/SewerAndRainNetwork

ChenZeping
2021-04-29 219f8c029a2abc029e34f079f6ae43bea929500a
src/components/LayerController/service/WmsLayerService.js
@@ -45,14 +45,13 @@
  }
  add (config) {
    const code = config.code
    for (var k in this.layersConfig) {
      if (code === k) {
        return false
    const wmsLayers = config.wmsLayers
    if (wmsLayers) {
      if (this.layers.indexOf(wmsLayers) < 0) {
        this.layers.push(config.wmsLayers)
        this.wmsLayer.setParams({ layers: this.layers.join(',') })
      }
    }
    this.layers.push(config.wmsLayers)
    this.wmsLayer.setParams({ layers: this.layers.join(',') })
  }
  remove (config) {