|
|
|
@ -102,11 +102,21 @@ public class GovIssueServiceImpl implements GovIssueService { |
|
|
|
* @date 2020/12/25 下午2:30 |
|
|
|
*/ |
|
|
|
public List<IssueListResultDTO> issueStatusClosedOrVoting(AllIssueFormDTO formDTO){ |
|
|
|
if (StringUtils.isBlank(formDTO.getIssueType())){ |
|
|
|
throw new RenException(IssueConstant.NOT_EXISTS_ISSUE_TYPE); |
|
|
|
} |
|
|
|
if (CollectionUtils.isEmpty(formDTO.getGridIdList())){ |
|
|
|
return new ArrayList<>(); |
|
|
|
} |
|
|
|
PageInfo<IssueListResultDTO> result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize()).doSelectPageInfo(() -> issueDao.issueStatusClosedOrVoting(formDTO.getGridIdList(), formDTO.getIssueType())); |
|
|
|
return result.getList(); |
|
|
|
List<IssueListResultDTO> list = result.getList(); |
|
|
|
List<IssueListResultDTO> resultList = new ArrayList<>(); |
|
|
|
if (formDTO.getIssueType().equals(IssueConstant.ISSUE_STATUS_CLOSED)){ |
|
|
|
resultList = list.stream().sorted(Comparator.comparing(IssueListResultDTO::getIssueClosedTime).reversed()).collect(Collectors.toList()); |
|
|
|
}else { |
|
|
|
resultList = list.stream().sorted(Comparator.comparing(IssueListResultDTO::getCreateTime).reversed()).collect(Collectors.toList()); |
|
|
|
} |
|
|
|
return resultList; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
@ -145,7 +155,7 @@ public class GovIssueServiceImpl implements GovIssueService { |
|
|
|
return new ArrayList<>(); |
|
|
|
} |
|
|
|
PageInfo<IssueListResultDTO> result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize()).doSelectPageInfo(() -> issueApplicationDao.issueStatusAuditing(formDTO.getGridIdList())); |
|
|
|
return result.getList(); |
|
|
|
return result.getList().stream().sorted(Comparator.comparing(IssueListResultDTO::getAuditingTime).reversed()).collect(Collectors.toList()); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
@ -177,7 +187,8 @@ public class GovIssueServiceImpl implements GovIssueService { |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
return list; |
|
|
|
List<IssueListResultDTO> collect = list.stream().sorted(Comparator.comparing(IssueListResultDTO::getShiftProjectTime).reversed()).collect(Collectors.toList()); |
|
|
|
return collect; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
|