wolf2w_cloud-master

狼性天下


回答

[TOC]

简要描述
  • 问题详情下查询单个回答接口
请求URL
  • http://localhost/9000/questions/comments?id={}
    请求方式
  • GET
参数
参数名 必选 类型 说明
id Long 回答的id
返回示例
  {
    "code": 200,
    "msg":"success",
    "data":{
    "content":"适合春季游的地方太多了。看自己喜好吧",
    "thumbsupnum":66,
    "starnum":11,
    "state":0,
    "questionId":2,
    "userId":5,
    "UserInfo":[{"nickname":"小李","phone":"13045687921","email":null,"gender":1,"level":0,"city":"四川","headImgUrl":"https://p1-q.mafengwo.net/s9/M00/AF/F6/wKgBs1aVL52ASPBKAAKedkjQxwo58.jpeg?imageMogr2%2Fthumbnail%2F%2190x90r%2Fgravity%2FCenter%2Fcrop%2F%2190x90%2Fquality%2F90","info":"蔷薇","state":0}],
    "optimum":false,
    "createTime":2023-01-12 15:26:22,
    updateTime:null,
    }
  }
简要描述
  • 问题详情下分页查询接口
请求URL
  • http://localhost/9000/questions/comments/query?currentPage=1&pageSize=10&keyword=?&qid=2
    请求方式
  • GET
参数
参数名 必选 类型 说明
QuestionsCommentQo 查询对象 查询对象
返回示例
  {
    "code": 200,
    "msg":"success",
    "data":{
    "records":[{
    "content":"适合春季游的地方太多了。看自己喜好吧",
    "thumbsupnum":66,
    "starnum":11,
    "state":0,
    "questionId":2,
    "userId":5,
    "UserInfo":[{"nickname":"小李","phone":"13045687921","email":null,"gender":1,"level":0,"city":"四川","headImgUrl":"https://p1-q.mafengwo.net/s9/M00/AF/F6/wKgBs1aVL52ASPBKAAKedkjQxwo58.jpeg?imageMogr2%2Fthumbnail%2F%2190x90r%2Fgravity%2FCenter%2Fcrop%2F%2190x90%2Fquality%2F90","info":"蔷薇","state":0}],
    "optimum":false,
    "createTime":2023-01-12 15:26:22,
    updateTime:null,
    },{
    "content":"适合春季游的地方太多了。看自己喜好吧",
    "thumbsupnum":66,
    "starnum":11,
    "state":0,
    "questionId":3,
    "userId":5,
    "UserInfo":[{"nickname":"小王","phone":"18908082855","email":null,"gender":2,"level":0,"city":"四川","headImgUrl":"https://p1-q.mafengwo.net/s9/M00/AF/F6/wKgBs1aVL52ASPBKAAKedkjQxwo58.jpeg?imageMogr2%2Fthumbnail%2F%2190x90r%2Fgravity%2FCenter%2Fcrop%2F%2190x90%2Fquality%2F90","info":"玫瑰","state":0}],
    "optimum":false,
    "createTime":2023-01-12 15:26:22,
    updateTime:null,
    }],
    "total": 2,
    "size": 10,
    "current": 1,
    "pages":1
    }
  }
简要描述
  • 问题详情下回答接口
请求URL
  • http://localhost/9000/questions/comments/save
请求方式
  • POST
参数
参数名 必选 类型 说明
QuestionsComment 对象 回答对象
返回示例
  {
    "code": 200,
    "msg":"success"
  }
备注
  • 用户未登录或登录失效, 返回错误代码情况示例
  {
    "timestamp": "2023-01-12T10:55:22.383+00:00",
    "status": 500,
    "error": "Internal Server Error",
    "message": "",
    "path": "/questions/comments/save"
}
简要描述
  • 问题详情下文件上传接口
请求URL
  • http://localhost/9000/questions/comments/uploadImg
请求方式
  • POST
参数
参数名 必选 类型 说明
upload 对象 上传的对象
返回示例
  {
    "code": 200,
    "msg":"success"
  }
简要描述
  • 问题详情点赞接口
请求URL
  • http://localhost/9000/questions/comments/thumb
请求方式
  • POST
参数
参数名 必选 类型 说明
cid String 回答id
request HttpServletRequest 请求对象
返回示例
  {
    "code": 200,
    "msg":"success"
  }
备注
  • 用户未登录或登录失效, 返回错误代码情况示例
  {
    "timestamp": "2023-01-13T011:50:45.369+00:00",
    "status": 500,
    "error": "Internal Server Error",
    "message": "",
    "path": "/questions/comments/thumb"
}
简要描述
  • 问题详情收藏接口
请求URL
  • http://localhost/9000/questions/comments/starnum
请求方式
  • POST
参数
参数名 必选 类型 说明
qid String 回答id
request HttpServletRequest 请求对象
返回示例
  {
    "code": 200,
    "msg":"success"
  }
备注
  • 用户未登录或登录失效, 返回错误代码情况示例
  {
    "timestamp": "2023-01-13T16:49:32.258+00:00",
    "status": 500,
    "error": "Internal Server Error",
    "message": "",
    "path": "/questions/comments/starnum"
}

页面列表

ITEM_HTML