From daad8414d7998dfb156ed442b278c61ade1caeb4 Mon Sep 17 00:00:00 2001 From: yangfuda <945208611@qq.com> Date: Tue, 9 Sep 2025 13:27:01 +0800 Subject: [PATCH] =?UTF-8?q?TASK=2045751=20=E5=9C=B0=E5=9D=97=E5=B1=9E?= =?UTF-8?q?=E6=80=A7=E5=92=8C=E5=9C=B0=E5=9D=97=E7=BB=8F=E8=90=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ruoyi/web/controller/gis/GisMapController.java | 13 +++++++------ .../web/controller/system/SysDeptController.java | 6 +++--- .../com/ruoyi/system/service/ISysDeptService.java | 2 ++ .../system/service/impl/SysDeptServiceImpl.java | 5 +++++ 4 files changed, 17 insertions(+), 9 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/gis/GisMapController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/gis/GisMapController.java index f9ff91a..4fc1500 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/gis/GisMapController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/gis/GisMapController.java @@ -10,6 +10,7 @@ import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; @@ -32,7 +33,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/point/do") @ResponseBody - public AjaxResult pointSave(SysGis gis) { + public AjaxResult pointSave(@RequestBody SysGis gis) { return toAjax(gisService.updateGeomByPoint(gis)); } @@ -42,7 +43,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/point/private/do") @ResponseBody - public AjaxResult pointSavePri(SysGis gis) { + public AjaxResult pointSavePri(@RequestBody SysGis gis) { return toAjax(gisService.updateGeomByPointPri(gis)); } @@ -53,7 +54,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/polygon/do") @ResponseBody - public AjaxResult areaSave(SysGis gis) { + public AjaxResult areaSave(@RequestBody SysGis gis) { return toAjax(gisService.updateGeomByPolygon(gis)); } @@ -64,7 +65,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/polygon/private/do") @ResponseBody - public AjaxResult areaSavePri(SysGis gis) { + public AjaxResult areaSavePri(@RequestBody SysGis gis) { return toAjax(gisService.updateGeomByPolygonPri(gis)); } @@ -75,7 +76,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/clean/do") @ResponseBody - public AjaxResult cleanSave(SysGis gis) { + public AjaxResult cleanSave(@RequestBody SysGis gis) { return toAjax(gisService.cleanGeomById(gis)); } @@ -86,7 +87,7 @@ public class GisMapController extends BaseController { @Log(title = "GIS", businessType = BusinessType.UPDATE) @PostMapping("/clean/private/do") @ResponseBody - public AjaxResult cleanSavePri(SysGis gis) { + public AjaxResult cleanSavePri(@RequestBody SysGis gis) { return toAjax(gisService.cleanGeomByIdPri(gis)); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java index 12215e9..2db3f23 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java @@ -86,9 +86,9 @@ public class SysDeptController extends BaseController { * 根据部门编号获取详细信息 */ @PreAuthorize("@ss.hasPermi('system:dept:query')") - @GetMapping(value = "/getInfoByCode/{orgCode}") - public AjaxResult getInfoByCode(@PathVariable String orgCode) { - return success(deptService.selectDeptByOrgCode(orgCode)); + @GetMapping(value = "/getInfoByImportCode/{importCode}") + public AjaxResult getInfoByImportCode(@PathVariable String importCode) { + return success(deptService.selectDeptByImportCode(importCode)); } /** diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/ISysDeptService.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/ISysDeptService.java index 0af57ea..d9f82b2 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/service/ISysDeptService.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/ISysDeptService.java @@ -73,6 +73,8 @@ public interface ISysDeptService public SysDept selectDeptByOrgCode(String orgCode); + public SysDept selectDeptByImportCode(String importCode); + /** * 是否存在部门子节点 * diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java index cf811ed..8160f4a 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java @@ -153,6 +153,11 @@ public class SysDeptServiceImpl implements ISysDeptService { return deptMapper.selectDeptByOrgCode(orgCode); } + @Override + public SysDept selectDeptByImportCode(String importCode) { + return deptMapper.selectDeptByImportCode(importCode); + } + /** * 是否存在子节点 *