From 4a80ef5544ff210d9e0aaa4cb1eaf3dba8c39645 Mon Sep 17 00:00:00 2001 From: chenyabin <Chenab123!> Date: 星期四, 13 五月 2021 11:14:14 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/develop' into develop --- src/components/LayerController/logic/SourcesPollution.js | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/components/LayerController/logic/SourcesPollution.js b/src/components/LayerController/logic/SourcesPollution.js index 6cec839..a701f1c 100644 --- a/src/components/LayerController/logic/SourcesPollution.js +++ b/src/components/LayerController/logic/SourcesPollution.js @@ -2,11 +2,9 @@ * 姹℃煋婧� * */ -// 浣跨敤灏佽鏂规硶 // 璇锋眰鎺ュ彛鏁版嵁 -// import { getSourcesPoll } from '../../../api/request' - const mapApi = require('../../../api/mapApi').default +// 浣跨敤灏佽鏂规硶 const AnimalService = require('../service/AnimalService').default module.exports = function () { @@ -15,10 +13,10 @@ L: L, layer: layer }) - // getSourcesPoll().then(res => { - // console.log(res) - // }) const result = await mapApi.getSourcesPoll() console.log(result) + const resultData = result.Result.DataInfo || [] + const polygon = L.polygon(resultData, { color: 'yellow' }) + polygon.addTo(layer) } } -- Gitblit v1.8.0