fix: 不同项目下测试计划名称冲突问题

This commit is contained in:
chenjianxing 2021-01-27 10:56:10 +08:00
parent 7035f6c0e3
commit 4367ef3291
1 changed files with 1 additions and 0 deletions

View File

@ -150,6 +150,7 @@ public class TestPlanService {
public List<TestPlan> getTestPlanByName(String name) { public List<TestPlan> getTestPlanByName(String name) {
TestPlanExample example = new TestPlanExample(); TestPlanExample example = new TestPlanExample();
example.createCriteria().andWorkspaceIdEqualTo(SessionUtils.getCurrentWorkspaceId()) example.createCriteria().andWorkspaceIdEqualTo(SessionUtils.getCurrentWorkspaceId())
.andProjectIdEqualTo(SessionUtils.getCurrentProjectId())
.andNameEqualTo(name); .andNameEqualTo(name);
return testPlanMapper.selectByExample(example); return testPlanMapper.selectByExample(example);
} }