From 538dedf9f42b43594ace93438a261e81f10989e6 Mon Sep 17 00:00:00 2001 From: lxd <1004405501@qq.com> Date: Mon, 25 Nov 2024 13:29:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=AF=B9=E5=A4=96=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/controller/admin/org/OrgUnitController.java | 8 ++++++++ .../yudao/module/system/dal/mysql/org/OrgUnitMapper.java | 4 ++++ .../yudao/module/system/service/org/OrgUnitService.java | 2 ++ .../module/system/service/org/OrgUnitServiceImpl.java | 5 +++++ 4 files changed, 19 insertions(+) diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/org/OrgUnitController.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/org/OrgUnitController.java index 270a7fff6..3b230497b 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/org/OrgUnitController.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/controller/admin/org/OrgUnitController.java @@ -119,6 +119,14 @@ public class OrgUnitController { return success(BeanUtils.toBean(aDo, OrgUnitRespVO.class)); } + @GetMapping("/orgSngetnoe") + public CommonResult getSnoneorg(@RequestParam("orgSN") String orgSN) + { + OrgUnitDO aDo = Service.getSnonekey(orgSN); + return success(BeanUtils.toBean(aDo, OrgUnitRespVO.class)); + } + + @GetMapping("/getlist") @Operation(summary = "获得机构管理字典") @PreAuthorize("@ss.hasPermission('org::query')") diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/org/OrgUnitMapper.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/org/OrgUnitMapper.java index 8abda4dca..01111f514 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/org/OrgUnitMapper.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/org/OrgUnitMapper.java @@ -46,4 +46,8 @@ public interface OrgUnitMapper extends BaseMapperX { default OrgUnitDO selectByKey(String key) { return selectOne(OrgUnitDO::getOrgID, key); } + default OrgUnitDO selectBySnKey(String key) { + return selectOne(OrgUnitDO::getOrgSN, key); + } + } \ No newline at end of file diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitService.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitService.java index 1c1ac466c..117b59617 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitService.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitService.java @@ -59,4 +59,6 @@ public interface OrgUnitService { List getOrgUnitList(); OrgUnitDO getonekey(String orgId); + + OrgUnitDO getSnonekey(String orgSn); } \ No newline at end of file diff --git a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitServiceImpl.java b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitServiceImpl.java index 95261492f..a4f9ae4b6 100644 --- a/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitServiceImpl.java +++ b/yudao-module-system/yudao-module-system-biz/src/main/java/cn/iocoder/yudao/module/system/service/org/OrgUnitServiceImpl.java @@ -89,4 +89,9 @@ public class OrgUnitServiceImpl implements OrgUnitService { { return Mapper.selectByKey(orgId); } + + @Override + public OrgUnitDO getSnonekey(String orgSn) { + return Mapper.selectBySnKey(orgSn); + } } \ No newline at end of file