| 12345678910111213141516171819202122232425262728293031 |
- import { http } from '@/utils/http/axios';
- import { COMMENT_STATUS } from '@/types/comments/constant';
- import { CommentsQuery, ListType } from '@/types/comments/type';
- //查询留言列表
- export const getCommentsList = (data: CommentsQuery) => {
- return http.request<ListType>({
- url: `/admin/comment/queryCommentPageByFilters`,
- method: 'post',
- data,
- });
- };
- //更新评论状态
- export const undateCommentStatus = (data: { id: number; status: COMMENT_STATUS }) => {
- return http.request({
- url: `/admin/comment/updateCommentStatus`,
- method: 'PUT',
- data,
- });
- };
- //回复评论
- export const replyComment = (data: { id: number; reply: string }) => {
- return http.request({
- url: `/admin/comment/replyComment`,
- method: 'post',
- data,
- });
- };
|