|
|
|
@ -153,7 +153,6 @@ public class ProjectServiceImpl implements ProjectService {
|
|
|
|
|
LocalDateTime startTime = pageDTO.getTimeLimit() == 2 ? nowTime.minusDays(3) : nowTime.minusDays(14); |
|
|
|
|
queryWrapperX.between(ProjectDO::getCreateTime, startTime, nowTime); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
queryWrapperX.eqIfPresent(ProjectDO::getDraft, pageDTO.getDraft()); |
|
|
|
|
if (pageDTO.getDraft()){ |
|
|
|
|
//查看自己的草稿
|
|
|
|
@ -165,11 +164,10 @@ public class ProjectServiceImpl implements ProjectService {
|
|
|
|
|
CpUserDO user = cpUserMapper.selectOne(Wrappers.<CpUserDO>lambdaQuery().eq(CpUserDO::getUserId, adminUser.getUsername())); |
|
|
|
|
if (ObjectUtil.isNotEmpty(user)){ |
|
|
|
|
//查看我参与或创建的项目
|
|
|
|
|
queryWrapperX.last(" and (JSON_CONTAINS(members, '"+ user.getId()+"') or creator = " + getLoginUserId() +") ORDER BY id") ; |
|
|
|
|
queryWrapperX.apply(" ((JSON_CONTAINS(members, '"+ user.getId()+"') or creator = " + getLoginUserId() +"))"); |
|
|
|
|
} |
|
|
|
|
}else{ |
|
|
|
|
queryWrapperX.orderByDesc(ProjectDO::getId); |
|
|
|
|
} |
|
|
|
|
queryWrapperX.orderByDesc(ProjectDO::getId); |
|
|
|
|
|
|
|
|
|
List<ProjectDO> list = projectMapper.selectList(queryWrapperX); |
|
|
|
|
if (ObjectUtil.isEmpty(list)){ |
|
|
|
|