45 lines
798 B
JavaScript
45 lines
798 B
JavaScript
|
import request from '@/utils/request'
|
||
|
|
||
|
// 查询话题评论列表
|
||
|
export function listComment(query) {
|
||
|
return request({
|
||
|
url: '/postComment/comment/list',
|
||
|
method: 'get',
|
||
|
params: query
|
||
|
})
|
||
|
}
|
||
|
|
||
|
// 查询话题评论详细
|
||
|
export function getComment(id) {
|
||
|
return request({
|
||
|
url: '/postComment/comment/' + id,
|
||
|
method: 'get'
|
||
|
})
|
||
|
}
|
||
|
|
||
|
// 新增话题评论
|
||
|
export function addComment(data) {
|
||
|
return request({
|
||
|
url: '/postComment/comment',
|
||
|
method: 'post',
|
||
|
data: data
|
||
|
})
|
||
|
}
|
||
|
|
||
|
// 修改话题评论
|
||
|
export function updateComment(data) {
|
||
|
return request({
|
||
|
url: '/postComment/comment',
|
||
|
method: 'put',
|
||
|
data: data
|
||
|
})
|
||
|
}
|
||
|
|
||
|
// 删除话题评论
|
||
|
export function delComment(id) {
|
||
|
return request({
|
||
|
url: '/postComment/comment/' + id,
|
||
|
method: 'delete'
|
||
|
})
|
||
|
}
|