refactor: 性能测试删除指定版本
This commit is contained in:
parent
5fe5939086
commit
220fe2775d
|
@ -1024,10 +1024,6 @@ public class PerformanceTestService {
|
|||
public void deleteLoadTestByVersion(String version,String refId) {
|
||||
LoadTestExample loadTestExample = new LoadTestExample();
|
||||
loadTestExample.createCriteria().andRefIdEqualTo(refId).andVersionIdEqualTo(version);
|
||||
List<LoadTest> loadTests = loadTestMapper.selectByExample(loadTestExample);
|
||||
LoadTest loadTest = loadTests.get(0);
|
||||
DeleteTestPlanRequest request = new DeleteTestPlanRequest();
|
||||
request.setId(loadTest.getId());
|
||||
this.delete(request);
|
||||
loadTestMapper.deleteByExample(loadTestExample);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -261,7 +261,7 @@ export default {
|
|||
},
|
||||
_handleDelete(test, deleteCurrentVersion) {
|
||||
if (deleteCurrentVersion) {
|
||||
this.$get('performance/delete/' + test.id + '/' + test.refId, () => {
|
||||
this.$get('performance/delete/' + test.versionId + '/' + test.refId, () => {
|
||||
this.$success(this.$t('commons.delete_success'));
|
||||
this.initTableData();
|
||||
this.$refs.apiDeleteConfirm.close();
|
||||
|
|
Loading…
Reference in New Issue