64 lines
1.2 KiB
Vue
64 lines
1.2 KiB
Vue
import request from '@/utils/request'
|
|
|
|
export function getList(data) {
|
|
return request({
|
|
url: '/management/api/spring/index/tips/list',
|
|
method: 'get',
|
|
params: data,
|
|
})
|
|
}
|
|
|
|
export function doAdd(data) {
|
|
return request({
|
|
url: '/management/api/spring/index/tips',
|
|
method: 'post',
|
|
data,
|
|
})
|
|
}
|
|
|
|
export function doEdit(id, data) {
|
|
return request({
|
|
url: `/management/api/spring/index/tips/${id}`,
|
|
method: 'put',
|
|
data,
|
|
})
|
|
}
|
|
|
|
export function doDelete(data) {
|
|
return request({
|
|
url: '/management/api/spring/index/tips/delete',
|
|
method: 'put',
|
|
data,
|
|
})
|
|
}
|
|
|
|
export function doMoveUp(id) {
|
|
return request({
|
|
url: `/management/api/spring/index/tips/moveUp/${id}`,
|
|
method: 'patch',
|
|
})
|
|
}
|
|
|
|
export function doMoveDown(id) {
|
|
return request({
|
|
url: `/management/api/spring/index/tips/moveDown/${id}`,
|
|
method: 'patch',
|
|
})
|
|
}
|
|
|
|
export function toggleEnable(id, isEnabled) {
|
|
return request({
|
|
url: `/management/api/spring/index/tips/enable/${id}`,
|
|
method: 'patch',
|
|
data: { isEnabled },
|
|
})
|
|
}
|
|
|
|
export function getItemDetail(data) {
|
|
return request({
|
|
url: '/management/api/spring/index/tips/check',
|
|
method: 'get',
|
|
params: data,
|
|
})
|
|
}
|