From f6f1443e6e13d1c90285aff2f16860ef2d0f4272 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=94=B0=E4=BF=8A=E5=BD=AA?= <937283697@qq.com> Date: Tue, 26 Nov 2024 19:46:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/cuit/solarenergy/controller/DataController.java | 4 ++-- .../cuit/solarenergy/service/impl/DataImportServiceImpl.java | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/cuit/solarenergy/controller/DataController.java b/src/main/java/com/cuit/solarenergy/controller/DataController.java index 80b0501..4f19db1 100644 --- a/src/main/java/com/cuit/solarenergy/controller/DataController.java +++ b/src/main/java/com/cuit/solarenergy/controller/DataController.java @@ -40,7 +40,7 @@ public class DataController { @AuthToken @ApiOperation("1、区域查询") @PreAuthorize("hasAuthority('minio:upload')") - @RequestMapping(value = "/dataimport/getRefionInfo", method = {RequestMethod.POST}) + @RequestMapping(value = "/dataimport/getRefionInfo", method = {RequestMethod.GET}) @ApiResponses({ @ApiResponse(code = 200, message = "成功"), @ApiResponse(code = 401, message = "访问未经授权"), @@ -53,9 +53,9 @@ public class DataController { try { log.info("区域查询"); List regionInfo = dataImportService.getRefionInfo(); + return RetResponse.makeOKRsp(regionInfo); }catch (ParamsException e){ return RetResponse.makeErrRsp("查询错误!"+e.getMessage()); } - return getRefionInfo(); } } diff --git a/src/main/java/com/cuit/solarenergy/service/impl/DataImportServiceImpl.java b/src/main/java/com/cuit/solarenergy/service/impl/DataImportServiceImpl.java index 52e3d74..14d0886 100644 --- a/src/main/java/com/cuit/solarenergy/service/impl/DataImportServiceImpl.java +++ b/src/main/java/com/cuit/solarenergy/service/impl/DataImportServiceImpl.java @@ -370,10 +370,10 @@ public class DataImportServiceImpl implements DataImportService { regionInfo.add("广元"); regionInfo.add("达州"); regionInfo.add("广安"); + return regionInfo; }catch (ParamsException e){ return null; } - return getRefionInfo(); }