From 9c0bfff1512e53dc810b1b227310ea89b4cddf01 Mon Sep 17 00:00:00 2001
From: xuhy <3313886187@qq.com>
Date: 星期四, 10 四月 2025 15:27:22 +0800
Subject: [PATCH] bug修改
---
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TDeptServiceImpl.java | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TDeptServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TDeptServiceImpl.java
index a994a66..40deee2 100644
--- a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TDeptServiceImpl.java
+++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TDeptServiceImpl.java
@@ -2,8 +2,7 @@
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.ruoyi.common.basic.PageInfo;
-import com.ruoyi.common.utils.StringUtils;
-import com.ruoyi.system.dto.TDeptUpAndDownDTO;
+import com.ruoyi.system.mapper.SysMenuMapper;
import com.ruoyi.system.model.TDept;
import com.ruoyi.system.mapper.TDeptMapper;
import com.ruoyi.system.query.TDeptQuery;
@@ -12,8 +11,8 @@
import com.ruoyi.system.vo.DeptVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
-import java.time.LocalDateTime;
import java.util.List;
/**
@@ -27,9 +26,11 @@
@Service
public class TDeptServiceImpl extends ServiceImpl<TDeptMapper, TDept> implements TDeptService {
+ @Autowired
+ private SysMenuMapper sysMenuMapper;
@Override
public boolean isExit(TDept dto) {
- if(StringUtils.isNotEmpty(dto.getDeptId())){
+ if(StringUtils.hasLength(dto.getId())){
// 修改
return this.count(Wrappers.lambdaQuery(TDept.class).ne(TDept::getId, dto.getId()).eq(TDept::getDeptId, dto.getDeptId())) > 0;
}else {
@@ -46,4 +47,5 @@
return pageInfo;
}
+
}
--
Gitblit v1.7.1