41 lines
867 B
JavaScript
41 lines
867 B
JavaScript
|
import request from '@/utils/request';
|
||
|
|
||
|
/** 分页查找仿真任务*/
|
||
|
export function getQuestPageList(params) {
|
||
|
return request({
|
||
|
url: `/api/quest/paging`,
|
||
|
method: 'get',
|
||
|
params: params
|
||
|
});
|
||
|
}
|
||
|
/** 创建任务 */
|
||
|
export function createQuest(data) {
|
||
|
return request({
|
||
|
url: `/api/quest`,
|
||
|
method: 'post',
|
||
|
data
|
||
|
});
|
||
|
}
|
||
|
/** 根据任务id删除任务 */
|
||
|
export function deleteQuest(id) {
|
||
|
return request({
|
||
|
url: `/api/quest/${id}`,
|
||
|
method: 'delete'
|
||
|
});
|
||
|
}
|
||
|
/** 根据id查询任务基础信息 */
|
||
|
export function getQuestById(id) {
|
||
|
return request({
|
||
|
url: `/api/quest/${id}`,
|
||
|
method: 'get',
|
||
|
});
|
||
|
}
|
||
|
/** 更新任务基本信息 */
|
||
|
export function updateQuest(id, data) {
|
||
|
return request({
|
||
|
url: `/api/quest/${id}`,
|
||
|
method: 'put',
|
||
|
data
|
||
|
});
|
||
|
}
|