diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/check/TdCheckResultController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/check/TdCheckResultController.java index e6b3775..58e5fab 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/check/TdCheckResultController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/check/TdCheckResultController.java @@ -15,6 +15,7 @@ import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.*; import java.util.List; +import java.util.Objects; @Controller @RequestMapping("/system/checkresult") @@ -115,9 +116,12 @@ public class TdCheckResultController extends BaseController { @ResponseBody public AjaxResult selfcheckSave(TdCheck tdCheck) { - if (tdCheck.getCheckresult1().equals("0")&&tdCheck.getCheckresult2().equals("0") - &&tdCheck.getCheckresult3().equals("0")&&tdCheck.getCheckresult4().equals("0") - &&tdCheck.getCheckresult5().equals("0")&&tdCheck.getCheckresult6().equals("0")){ + if (Objects.equals(tdCheck.getCheckresult1(),"0") + && Objects.equals(tdCheck.getCheckresult2(),"0") + && Objects.equals(tdCheck.getCheckresult3(),"0") + && Objects.equals(tdCheck.getCheckresult4(),"0") + && Objects.equals(tdCheck.getCheckresult5(),"0") + && Objects.equals(tdCheck.getCheckresult6(),"0")){ tdCheck.setCheckState("0"); }else { tdCheck.setCheckState("1"); diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileDestoryController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileDestoryController.java index 606fb7f..46d855d 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileDestoryController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileDestoryController.java @@ -2,6 +2,7 @@ package com.ruoyi.web.controller.system.filemanager; import java.util.ArrayList; import java.util.List; +import java.util.Objects; import com.ruoyi.system.domain.TdFileProvide; import com.ruoyi.system.domain.TdFileReceive; @@ -58,7 +59,7 @@ public class TdFileDestoryController extends BaseController List list = tdFileReceiveService.selectTdFileReceiveList(tdFileReceive); List tdFileReceives = new ArrayList<>(); for (TdFileReceive FileReceivelist : list){ - if (FileReceivelist.getExtractState().equals("1") && FileReceivelist.getReceiveDepartid().equals(deptService.selectDeptById(getSysUser().getDeptId()).getDeptName())){ + if (Objects.equals(FileReceivelist.getExtractState(),"1") && FileReceivelist.getReceiveDepartid().equals(deptService.selectDeptById(getSysUser().getDeptId()).getDeptName())){ tdFileReceives.add(FileReceivelist); } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileExtractController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileExtractController.java index 44f9198..46c0292 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileExtractController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/filemanager/TdFileExtractController.java @@ -17,6 +17,7 @@ import org.springframework.web.bind.annotation.*; import java.util.ArrayList; import java.util.List; +import java.util.Objects; /** * 涉密文件提取Controller @@ -49,7 +50,7 @@ public class TdFileExtractController extends BaseController { List list = tdFileReceiveService.selectTdFileReceiveList(tdFileReceive); List tdFileReceives = new ArrayList<>(); for (TdFileReceive FileReceivelist : list){ - if (FileReceivelist.getReceiveState().equals("1") && FileReceivelist.getReceiveDepartid().equals(getSysUser().getDept().getDeptName())){ + if (Objects.equals(FileReceivelist.getReceiveState(),"1") && FileReceivelist.getReceiveDepartid().equals(getSysUser().getDept().getDeptName())){ tdFileReceives.add(FileReceivelist); } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/system/TdLeaveController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/system/TdLeaveController.java index 19d7a8f..73f9186 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/system/TdLeaveController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/system/TdLeaveController.java @@ -1,6 +1,7 @@ package com.ruoyi.web.controller.system.system; import java.util.List; +import java.util.Objects; import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.system.service.ISysPostService; @@ -145,7 +146,7 @@ public class TdLeaveController extends BaseController @ResponseBody public AjaxResult examinesave(TdLeave tdLeave) { - if (tdLeave.getLeavestate().equals("1")){ + if (Objects.equals(tdLeave.getLeavestate(),"1")){ SysUser sysUser = userService.selectUserById(tdLeave.getUserId()); sysUser.setStatus("1"); userService.updateUser(sysUser);