fix: swagger定时任务优化
This commit is contained in:
parent
a4545cefef
commit
d09e42708f
|
@ -968,7 +968,7 @@ public class ApiDefinitionService {
|
||||||
//删除
|
//删除
|
||||||
public void deleteSchedule(ScheduleRequest request) {
|
public void deleteSchedule(ScheduleRequest request) {
|
||||||
swaggerUrlProjectMapper.deleteByPrimaryKey(request.getId());
|
swaggerUrlProjectMapper.deleteByPrimaryKey(request.getId());
|
||||||
scheduleService.deleteByResourceId(request.getTaskId(), ScheduleGroup.SWAGGER_IMPORT.name());
|
scheduleService.deleteByResourceId(request.getId(), ScheduleGroup.SWAGGER_IMPORT.name());
|
||||||
}
|
}
|
||||||
|
|
||||||
//查询swaggerUrl详情
|
//查询swaggerUrl详情
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
@setModuleOptions="setModuleOptions"
|
@setModuleOptions="setModuleOptions"
|
||||||
@setNodeTree="setNodeTree"
|
@setNodeTree="setNodeTree"
|
||||||
@enableTrash="enableTrash"
|
@enableTrash="enableTrash"
|
||||||
@schedule="handleTabsEdit($t('api_test.definition.request.fast_debug'), 'SCHEDULE')"
|
@schedule="handleTabsEdit($t('api_test.api_import.timing_synchronization'), 'SCHEDULE')"
|
||||||
:type="'edit'"
|
:type="'edit'"
|
||||||
page-source="definition"
|
page-source="definition"
|
||||||
ref="nodeTree"/>
|
ref="nodeTree"/>
|
||||||
|
@ -177,7 +177,6 @@ import ApiCaseSimpleList from "./components/list/ApiCaseSimpleList";
|
||||||
import ApiDocumentsPage from "@/business/components/api/definition/components/list/ApiDocumentsPage";
|
import ApiDocumentsPage from "@/business/components/api/definition/components/list/ApiDocumentsPage";
|
||||||
import MsTableButton from "@/business/components/common/components/MsTableButton";
|
import MsTableButton from "@/business/components/common/components/MsTableButton";
|
||||||
import MsTabButton from "@/business/components/common/components/MsTabButton";
|
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 MockConfig from "@/business/components/api/definition/components/mock/MockConfig";
|
||||||
import ApiSchedule from "@/business/components/api/definition/components/import/ApiSchedule";
|
import ApiSchedule from "@/business/components/api/definition/components/import/ApiSchedule";
|
||||||
|
|
|
@ -53,6 +53,7 @@
|
||||||
|
|
||||||
<div class="task-list">
|
<div class="task-list">
|
||||||
<swagger-task-list
|
<swagger-task-list
|
||||||
|
@clear="clear"
|
||||||
@rowClick="handleRowClick"
|
@rowClick="handleRowClick"
|
||||||
ref="taskList"/>
|
ref="taskList"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -106,6 +106,7 @@ export default {
|
||||||
deleteRowTask(row) {
|
deleteRowTask(row) {
|
||||||
this.result = this.$post('/api/definition/schedule/delete', row, response => {
|
this.result = this.$post('/api/definition/schedule/delete', row, response => {
|
||||||
this.search();
|
this.search();
|
||||||
|
this.$emit('clear');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -61,17 +61,17 @@ export default {
|
||||||
permissions: ['PROJECT_API_DEFINITION:READ+DEBUG']
|
permissions: ['PROJECT_API_DEFINITION:READ+DEBUG']
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: this.$t('api_test.api_import.label'),
|
label: this.$t('api_test.api_import.timing_synchronization'),
|
||||||
callback: this.handleImport,
|
|
||||||
permissions: ['PROJECT_API_DEFINITION:READ+IMPORT_API']
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: this.$t('定时同步'),
|
|
||||||
callback: () => {
|
callback: () => {
|
||||||
this.$emit('schedule');
|
this.$emit('schedule');
|
||||||
},
|
},
|
||||||
permissions: ['PROJECT_API_DEFINITION:READ+IMPORT_API']
|
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'),
|
label: this.$t('report.export'),
|
||||||
permissions: ['PROJECT_API_DEFINITION:READ+EXPORT_API'],
|
permissions: ['PROJECT_API_DEFINITION:READ+EXPORT_API'],
|
||||||
|
|
Loading…
Reference in New Issue