fix: 修复接口测试首页关闭swagger定时任务不彻底的问题
修复接口测试首页关闭swagger定时任务不彻底的问题
This commit is contained in:
parent
02205325fb
commit
3d939cbd83
|
@ -30,6 +30,7 @@ import io.metersphere.commons.utils.*;
|
|||
import io.metersphere.controller.request.ScheduleRequest;
|
||||
import io.metersphere.i18n.Translator;
|
||||
import io.metersphere.job.sechedule.ApiScenarioTestJob;
|
||||
import io.metersphere.job.sechedule.SwaggerUrlImportJob;
|
||||
import io.metersphere.job.sechedule.TestPlanTestJob;
|
||||
import io.metersphere.service.ScheduleService;
|
||||
import io.metersphere.track.dto.TestPlanDTO;
|
||||
|
@ -816,7 +817,9 @@ public class ApiAutomationService {
|
|||
if (StringUtils.equals(request.getGroup(), ScheduleGroup.TEST_PLAN_TEST.name())) {
|
||||
scheduleService.addOrUpdateCronJob(
|
||||
request, TestPlanTestJob.getJobKey(request.getResourceId()), TestPlanTestJob.getTriggerKey(request.getResourceId()), TestPlanTestJob.class);
|
||||
} else {
|
||||
}else if(StringUtils.equals(request.getGroup(), ScheduleGroup.SWAGGER_IMPORT.name())){
|
||||
scheduleService.addOrUpdateCronJob(request, SwaggerUrlImportJob.getJobKey(request.getResourceId()), SwaggerUrlImportJob.getTriggerKey(request.getResourceId()), SwaggerUrlImportJob.class);
|
||||
} else{
|
||||
scheduleService.addOrUpdateCronJob(
|
||||
request, ApiScenarioTestJob.getJobKey(request.getResourceId()), ApiScenarioTestJob.getTriggerKey(request.getResourceId()), ApiScenarioTestJob.class);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue