|
@@ -23,8 +23,6 @@ import com.ningdatech.basic.util.CollUtils; |
|
|
import lombok.RequiredArgsConstructor; |
|
|
import lombok.RequiredArgsConstructor; |
|
|
import org.springframework.stereotype.Component; |
|
|
import org.springframework.stereotype.Component; |
|
|
|
|
|
|
|
|
import java.time.LocalDate; |
|
|
|
|
|
import java.time.LocalDateTime; |
|
|
|
|
|
import java.util.Collections; |
|
|
import java.util.Collections; |
|
|
import java.util.List; |
|
|
import java.util.List; |
|
|
import java.util.Map; |
|
|
import java.util.Map; |
|
@@ -51,11 +49,11 @@ public class MhProjectManage { |
|
|
LambdaQueryWrapper<MhProject> query = Wrappers.lambdaQuery(MhProject.class) |
|
|
LambdaQueryWrapper<MhProject> query = Wrappers.lambdaQuery(MhProject.class) |
|
|
.like(StrUtil.isNotBlank(req.getProjectName()), MhProject::getProjectName, req.getProjectName()) |
|
|
.like(StrUtil.isNotBlank(req.getProjectName()), MhProject::getProjectName, req.getProjectName()) |
|
|
.like(StrUtil.isNotBlank(req.getDeclaredUnit()), MhProject::getUnitName, req.getDeclaredUnit()); |
|
|
.like(StrUtil.isNotBlank(req.getDeclaredUnit()), MhProject::getUnitName, req.getDeclaredUnit()); |
|
|
if (req.getBudgetYear() != null) { |
|
|
|
|
|
LocalDateTime startTime = LocalDate.of(req.getBudgetYear(), 1, 1).atStartOfDay(); |
|
|
|
|
|
LocalDateTime endTime = startTime.plusYears(1); |
|
|
|
|
|
query.ge(MhProject::getCreateTime, startTime); |
|
|
|
|
|
query.lt(MhProject::getCreateTime, endTime); |
|
|
|
|
|
|
|
|
if (req.getCreateDateMin() != null) { |
|
|
|
|
|
query.ge(MhProject::getCreateTime, req.getCreateDateMin()); |
|
|
|
|
|
} |
|
|
|
|
|
if (req.getCreateDateMax() != null) { |
|
|
|
|
|
query.lt(MhProject::getCreateTime, req.getCreateDateMax().minusDays(1)); |
|
|
} |
|
|
} |
|
|
UserInfoDetails user = LoginUserUtil.loginUserDetail(); |
|
|
UserInfoDetails user = LoginUserUtil.loginUserDetail(); |
|
|
if (!user.getSuperAdmin() && !user.getRegionAdmin()) { |
|
|
if (!user.getSuperAdmin() && !user.getRegionAdmin()) { |
|
@@ -89,7 +87,6 @@ public class MhProjectManage { |
|
|
} else { |
|
|
} else { |
|
|
item.setStatus(project.getStatus()); |
|
|
item.setStatus(project.getStatus()); |
|
|
item.setStage(project.getStage()); |
|
|
item.setStage(project.getStage()); |
|
|
item.setBizDomain(project.getBizDomain()); |
|
|
|
|
|
} |
|
|
} |
|
|
item.setProjectCode(w.getProjectCode()); |
|
|
item.setProjectCode(w.getProjectCode()); |
|
|
item.setProjectName(w.getProjectName()); |
|
|
item.setProjectName(w.getProjectName()); |
|
|