2 changed files with 25 additions and 54 deletions
@ -1,60 +1,30 @@ |
|||
import request from '@/utils/request' |
|||
import request from '@/config/axios' |
|||
|
|||
// 查询参数列表
|
|||
export function listConfig(query) { |
|||
return request({ |
|||
url: '/system/config/list', |
|||
method: 'get', |
|||
params: query |
|||
}) |
|||
export const listConfig = (params) => { |
|||
return request.get({ url: '/system/config/list', params }) |
|||
} |
|||
|
|||
// 查询参数详细
|
|||
export function getConfig(configId) { |
|||
return request({ |
|||
url: '/system/config/' + configId, |
|||
method: 'get' |
|||
}) |
|||
export const getConfig = (configId) => { |
|||
return request.get({ url: '/system/config/'+ configId }) |
|||
} |
|||
|
|||
// 根据参数键名查询参数值
|
|||
export function getConfigKey(configKey) { |
|||
return request({ |
|||
url: '/system/config/configKey/' + configKey, |
|||
method: 'get' |
|||
}) |
|||
export const getConfigKey = (configKey) => { |
|||
return request.get({ url: '/system/config/configKey/' + configKey}) |
|||
} |
|||
|
|||
// 新增参数配置
|
|||
export function addConfig(data) { |
|||
return request({ |
|||
url: '/system/config', |
|||
method: 'post', |
|||
data: data |
|||
}) |
|||
export const addConfig = (data) => { |
|||
return request.post({ url: '/system/config',data }) |
|||
} |
|||
|
|||
// 修改参数配置
|
|||
export function updateConfig(data) { |
|||
return request({ |
|||
url: '/system/config', |
|||
method: 'put', |
|||
data: data |
|||
}) |
|||
export const updateConfig = (data) => { |
|||
return request.put({ url: '/system/config',data }) |
|||
} |
|||
|
|||
// 删除参数配置
|
|||
export function delConfig(configId) { |
|||
return request({ |
|||
url: '/system/config/' + configId, |
|||
method: 'delete' |
|||
}) |
|||
export const delConfig = (configId) => { |
|||
return request.delete({ url:'/system/config/' + configId }) |
|||
} |
|||
|
|||
// 刷新参数缓存
|
|||
export function refreshCache() { |
|||
return request({ |
|||
url: '/system/config/refreshCache', |
|||
method: 'delete' |
|||
}) |
|||
} |
|||
export const refreshCache = () => { |
|||
return request.delete({ url:'/system/config/refreshCache'}) |
|||
} |
|||
|
Loading…
Reference in new issue