You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
997 B
36 lines
997 B
1 year ago
|
import request from '@/config/axios'
|
||
|
|
||
|
export interface DataSourceConfigVO {
|
||
|
id: number | undefined
|
||
|
name: string
|
||
|
url: string
|
||
|
username: string
|
||
|
password: string
|
||
|
createTime?: Date
|
||
|
}
|
||
|
|
||
|
// 新增数据源配置
|
||
|
export const createDataSourceConfig = (data: DataSourceConfigVO) => {
|
||
|
return request.post({ url: '/infra/data-source-config/create', data })
|
||
|
}
|
||
|
|
||
|
// 修改数据源配置
|
||
|
export const updateDataSourceConfig = (data: DataSourceConfigVO) => {
|
||
|
return request.put({ url: '/infra/data-source-config/update', data })
|
||
|
}
|
||
|
|
||
|
// 删除数据源配置
|
||
|
export const deleteDataSourceConfig = (id: number) => {
|
||
|
return request.delete({ url: '/infra/data-source-config/delete?id=' + id })
|
||
|
}
|
||
|
|
||
|
// 查询数据源配置详情
|
||
|
export const getDataSourceConfig = (id: number) => {
|
||
|
return request.get({ url: '/infra/data-source-config/get?id=' + id })
|
||
|
}
|
||
|
|
||
|
// 查询数据源配置列表
|
||
|
export const getDataSourceConfigList = () => {
|
||
|
return request.get({ url: '/infra/data-source-config/list' })
|
||
|
}
|