fix(用例管理): 修复用例评论无法回复问题
--bug=1035920 --user=郭雨琦 https://www.tapd.cn/55049933/bugtrace/bugs/view/1155049933001035920
This commit is contained in:
parent
8bdd2cd2d3
commit
16d88a4db3
|
@ -277,7 +277,11 @@ public class FunctionalCaseCommentService {
|
||||||
Map<String, List<FunctionalCaseCommentDTO>> commentMap = replyList.stream().collect(Collectors.groupingBy(FunctionalCaseComment::getParentId));
|
Map<String, List<FunctionalCaseCommentDTO>> commentMap = replyList.stream().collect(Collectors.groupingBy(FunctionalCaseComment::getParentId));
|
||||||
for (FunctionalCaseCommentDTO functionalCaseComment : rootList) {
|
for (FunctionalCaseCommentDTO functionalCaseComment : rootList) {
|
||||||
List<FunctionalCaseCommentDTO> replyComments = commentMap.get(functionalCaseComment.getId());
|
List<FunctionalCaseCommentDTO> replyComments = commentMap.get(functionalCaseComment.getId());
|
||||||
functionalCaseComment.setChildComments(replyComments);
|
if (CollectionUtils.isNotEmpty(replyComments)) {
|
||||||
|
functionalCaseComment.setChildComments(replyComments);
|
||||||
|
} else {
|
||||||
|
functionalCaseComment.setChildComments(new ArrayList<>());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return rootList;
|
return rootList;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue