fix(测试跟踪): 用例评审,全部通过状态更新有误

--bug=1024731 --user=陈建星 【测试跟踪】用例评审-多人评审-全部通过-用例状态仍为评审中 https://www.tapd.cn/55049933/s/1354161
This commit is contained in:
chenjianxing 2023-03-22 10:51:41 +08:00 committed by jianxing
parent 931782a9e2
commit 9264762f72
2 changed files with 6 additions and 4 deletions

View File

@ -17,9 +17,11 @@ public class TestCaseReviewTestCaseUsersService {
@Resource @Resource
TestCaseReviewTestCaseUsersMapper testCaseReviewTestCaseUsersMapper; TestCaseReviewTestCaseUsersMapper testCaseReviewTestCaseUsersMapper;
public List<String> getUsersByCaseId(String caseId) { public List<String> getUsersByCaseId(String caseId, String reviewId) {
TestCaseReviewTestCaseUsersExample example = new TestCaseReviewTestCaseUsersExample(); TestCaseReviewTestCaseUsersExample example = new TestCaseReviewTestCaseUsersExample();
example.createCriteria().andCaseIdEqualTo(caseId); example.createCriteria()
.andCaseIdEqualTo(caseId)
.andReviewIdEqualTo(reviewId);
return testCaseReviewTestCaseUsersMapper.selectByExample(example) return testCaseReviewTestCaseUsersMapper.selectByExample(example)
.stream() .stream()
.map(TestCaseReviewTestCaseUsers::getUserId) .map(TestCaseReviewTestCaseUsers::getUserId)

View File

@ -251,7 +251,7 @@ public class TestReviewTestCaseService {
String reviewPassRule = testCaseReviewService.getTestReview(testCaseReviewTestCase.getReviewId()) String reviewPassRule = testCaseReviewService.getTestReview(testCaseReviewTestCase.getReviewId())
.getReviewPassRule(); .getReviewPassRule();
List<String> users = testCaseReviewTestCaseUsersService.getUsersByCaseId(testCaseReviewTestCase.getCaseId()); List<String> users = testCaseReviewTestCaseUsersService.getUsersByCaseId(testCaseReviewTestCase.getCaseId(), testCaseReviewTestCase.getReviewId());
Set<String> reviewerSet = users.stream().collect(Collectors.toSet()); Set<String> reviewerSet = users.stream().collect(Collectors.toSet());
comments = filterAgainComments(comments); comments = filterAgainComments(comments);
@ -292,7 +292,7 @@ public class TestReviewTestCaseService {
String originStatus = originReviewTestCase.getStatus(); String originStatus = originReviewTestCase.getStatus();
String status = originStatus; String status = originStatus;
List<String> reviewers = testCaseReviewTestCaseUsersService.getUsersByCaseId(testCaseReviewTestCase.getCaseId()); List<String> reviewers = testCaseReviewTestCaseUsersService.getUsersByCaseId(testCaseReviewTestCase.getCaseId(), testCaseReviewTestCase.getReviewId());
Set<String> reviewerSet = reviewers.stream().collect(Collectors.toSet()); Set<String> reviewerSet = reviewers.stream().collect(Collectors.toSet());