2021-02-12 01:36:42 +08:00
|
|
|
import request from '@/utils/request'
|
|
|
|
|
|
|
|
// 创建字典类型
|
|
|
|
export function createTestDemo(data) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/create',
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'post',
|
|
|
|
data: data
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// 更新字典类型
|
|
|
|
export function updateTestDemo(data) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/update',
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'put',
|
|
|
|
data: data
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// 删除字典类型
|
|
|
|
export function deleteTestDemo(id) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/delete?id=' + id,
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'delete'
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// 获得字典类型
|
|
|
|
export function getTestDemo(id) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/get?id=' + id,
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'get'
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// 获得字典类型分页
|
|
|
|
export function getTestDemoPage(query) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/page',
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'get',
|
|
|
|
params: query
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// 导出字典类型 Excel
|
|
|
|
export function exportTestDemoExcel(query) {
|
|
|
|
return request({
|
2022-03-11 00:39:34 +08:00
|
|
|
url: '/infra/test-demo/export-excel',
|
2021-02-12 01:36:42 +08:00
|
|
|
method: 'get',
|
|
|
|
params: query,
|
2021-02-12 21:01:45 +08:00
|
|
|
responseType: 'blob'
|
2021-02-12 01:36:42 +08:00
|
|
|
})
|
|
|
|
}
|