Loading go-apps/meep-gis-engine/server/gis-engine.go +2 −7 Original line number Diff line number Diff line Loading @@ -1632,7 +1632,7 @@ func geUpdateGeoDataByName(w http.ResponseWriter, r *http.Request) { func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { // Retrieve coordinates to work with from request body var coordinates Coordinates var coordinates []am.Coordinate if r.Body == nil { err := errors.New("Request body is missing") log.Error(err.Error()) Loading @@ -1646,11 +1646,6 @@ func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } var amCoordinates []am.Coordinate jsonString, _ := json.Marshal(coordinates) json.Unmarshal([]byte(jsonString), &amCoordinates) // Make sure scenario is active if ge.activeModel.GetScenarioName() == "" { err := errors.New("No active scenario") Loading @@ -1659,7 +1654,7 @@ func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { return } coordinatesPower, err := ge.assetMgr.GetPowerValuesForCoordinates(amCoordinates) coordinatesPower, err := ge.assetMgr.GetPowerValuesForCoordinates(coordinates) if err != nil { log.Error(err.Error()) http.Error(w, err.Error(), http.StatusInternalServerError) Loading Loading
go-apps/meep-gis-engine/server/gis-engine.go +2 −7 Original line number Diff line number Diff line Loading @@ -1632,7 +1632,7 @@ func geUpdateGeoDataByName(w http.ResponseWriter, r *http.Request) { func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { // Retrieve coordinates to work with from request body var coordinates Coordinates var coordinates []am.Coordinate if r.Body == nil { err := errors.New("Request body is missing") log.Error(err.Error()) Loading @@ -1646,11 +1646,6 @@ func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } var amCoordinates []am.Coordinate jsonString, _ := json.Marshal(coordinates) json.Unmarshal([]byte(jsonString), &amCoordinates) // Make sure scenario is active if ge.activeModel.GetScenarioName() == "" { err := errors.New("No active scenario") Loading @@ -1659,7 +1654,7 @@ func geGetGeoDataPowerValues(w http.ResponseWriter, r *http.Request) { return } coordinatesPower, err := ge.assetMgr.GetPowerValuesForCoordinates(amCoordinates) coordinatesPower, err := ge.assetMgr.GetPowerValuesForCoordinates(coordinates) if err != nil { log.Error(err.Error()) http.Error(w, err.Error(), http.StatusInternalServerError) Loading