diff --git a/backend/src/main/java/io/metersphere/api/service/ApiDefinitionService.java b/backend/src/main/java/io/metersphere/api/service/ApiDefinitionService.java index 96a9480ac4..b70e291875 100644 --- a/backend/src/main/java/io/metersphere/api/service/ApiDefinitionService.java +++ b/backend/src/main/java/io/metersphere/api/service/ApiDefinitionService.java @@ -968,7 +968,7 @@ public class ApiDefinitionService { //删除 public void deleteSchedule(ScheduleRequest request) { swaggerUrlProjectMapper.deleteByPrimaryKey(request.getId()); - scheduleService.deleteByResourceId(request.getTaskId(), ScheduleGroup.SWAGGER_IMPORT.name()); + scheduleService.deleteByResourceId(request.getId(), ScheduleGroup.SWAGGER_IMPORT.name()); } //查询swaggerUrl详情 diff --git a/frontend/src/business/components/api/definition/ApiDefinition.vue b/frontend/src/business/components/api/definition/ApiDefinition.vue index 938c80b367..7da05e59f1 100644 --- a/frontend/src/business/components/api/definition/ApiDefinition.vue +++ b/frontend/src/business/components/api/definition/ApiDefinition.vue @@ -13,7 +13,7 @@ @setModuleOptions="setModuleOptions" @setNodeTree="setNodeTree" @enableTrash="enableTrash" - @schedule="handleTabsEdit($t('api_test.definition.request.fast_debug'), 'SCHEDULE')" + @schedule="handleTabsEdit($t('api_test.api_import.timing_synchronization'), 'SCHEDULE')" :type="'edit'" page-source="definition" ref="nodeTree"/> @@ -177,7 +177,6 @@ import ApiCaseSimpleList from "./components/list/ApiCaseSimpleList"; import ApiDocumentsPage from "@/business/components/api/definition/components/list/ApiDocumentsPage"; import MsTableButton from "@/business/components/common/components/MsTableButton"; import MsTabButton from "@/business/components/common/components/MsTabButton"; -import {getLabel} from "@/common/js/tableUtils"; import MockConfig from "@/business/components/api/definition/components/mock/MockConfig"; import ApiSchedule from "@/business/components/api/definition/components/import/ApiSchedule"; diff --git a/frontend/src/business/components/api/definition/components/import/ApiSchedule.vue b/frontend/src/business/components/api/definition/components/import/ApiSchedule.vue index 22a2a9a82d..7a0346d248 100644 --- a/frontend/src/business/components/api/definition/components/import/ApiSchedule.vue +++ b/frontend/src/business/components/api/definition/components/import/ApiSchedule.vue @@ -53,6 +53,7 @@
diff --git a/frontend/src/business/components/api/definition/components/import/SwaggerTaskList.vue b/frontend/src/business/components/api/definition/components/import/SwaggerTaskList.vue index 1d8ea9779d..a53ca9b379 100644 --- a/frontend/src/business/components/api/definition/components/import/SwaggerTaskList.vue +++ b/frontend/src/business/components/api/definition/components/import/SwaggerTaskList.vue @@ -106,6 +106,7 @@ export default { deleteRowTask(row) { this.result = this.$post('/api/definition/schedule/delete', row, response => { this.search(); + this.$emit('clear'); }); } diff --git a/frontend/src/business/components/api/definition/components/module/ApiModuleHeader.vue b/frontend/src/business/components/api/definition/components/module/ApiModuleHeader.vue index 0b840f2cae..9ff02d5e52 100644 --- a/frontend/src/business/components/api/definition/components/module/ApiModuleHeader.vue +++ b/frontend/src/business/components/api/definition/components/module/ApiModuleHeader.vue @@ -61,17 +61,17 @@ export default { permissions: ['PROJECT_API_DEFINITION:READ+DEBUG'] }, { - label: this.$t('api_test.api_import.label'), - callback: this.handleImport, - permissions: ['PROJECT_API_DEFINITION:READ+IMPORT_API'] - }, - { - label: this.$t('定时同步'), + label: this.$t('api_test.api_import.timing_synchronization'), callback: () => { this.$emit('schedule'); }, permissions: ['PROJECT_API_DEFINITION:READ+IMPORT_API'] }, + { + label: this.$t('api_test.api_import.label'), + callback: this.handleImport, + permissions: ['PROJECT_API_DEFINITION:READ+IMPORT_API'] + }, { label: this.$t('report.export'), permissions: ['PROJECT_API_DEFINITION:READ+EXPORT_API'],