提交 | 用户 | 时间
|
820397
|
1 |
import request from '@/config/axios' |
H |
2 |
|
|
3 |
export interface Demo02CategoryVO { |
|
4 |
id: number |
|
5 |
name: string |
|
6 |
parentId: number |
|
7 |
} |
|
8 |
|
|
9 |
// 查询示例分类列表 |
|
10 |
export const getDemo02CategoryList = async () => { |
|
11 |
return await request.get({ url: `/infra/demo02-category/list` }) |
|
12 |
} |
|
13 |
|
|
14 |
// 查询示例分类详情 |
|
15 |
export const getDemo02Category = async (id: number) => { |
|
16 |
return await request.get({ url: `/infra/demo02-category/get?id=` + id }) |
|
17 |
} |
|
18 |
|
|
19 |
// 新增示例分类 |
|
20 |
export const createDemo02Category = async (data: Demo02CategoryVO) => { |
|
21 |
return await request.post({ url: `/infra/demo02-category/create`, data }) |
|
22 |
} |
|
23 |
|
|
24 |
// 修改示例分类 |
|
25 |
export const updateDemo02Category = async (data: Demo02CategoryVO) => { |
|
26 |
return await request.put({ url: `/infra/demo02-category/update`, data }) |
|
27 |
} |
|
28 |
|
|
29 |
// 删除示例分类 |
|
30 |
export const deleteDemo02Category = async (id: number) => { |
|
31 |
return await request.delete({ url: `/infra/demo02-category/delete?id=` + id }) |
|
32 |
} |
|
33 |
|
|
34 |
// 导出示例分类 Excel |
|
35 |
export const exportDemo02Category = async (params) => { |
|
36 |
return await request.download({ url: `/infra/demo02-category/export-excel`, params }) |
|
37 |
} |