()
| 145 | } |
| 146 | |
| 147 | initWebMap() { |
| 148 | this.clean(); |
| 149 | this.serverUrl = this.serverUrl && this.webMapService.handleServerUrl(this.serverUrl); |
| 150 | if (this.webMapInfo) { |
| 151 | // 传入是webmap对象 |
| 152 | const mapInfo = this.webMapInfo; |
| 153 | mapInfo.mapParams = { |
| 154 | title: this.webMapInfo.title, |
| 155 | description: this.webMapInfo.description |
| 156 | }; |
| 157 | this.mapParams = mapInfo.mapParams; |
| 158 | this._getMapInfo(mapInfo); |
| 159 | return; |
| 160 | } else if (!this.mapId || !this.serverUrl) { |
| 161 | this._createMap(); |
| 162 | return; |
| 163 | } |
| 164 | this._taskID = new Date(); |
| 165 | this.getMapInfo(this._taskID); |
| 166 | } |
| 167 | |
| 168 | getMapInfo(_taskID) { |
| 169 | this.serverUrl = this.serverUrl && this.webMapService.handleServerUrl(this.serverUrl); |
no test coverage detected