tab7.js 884 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. import axios from '../utils/request'
  2. // -----------------------web----------------------------
  3. // 提交留言
  4. export const commentSave = (data) => {
  5. return axios({
  6. method: 'post',
  7. url: '/web/comment/save',
  8. data
  9. })
  10. }
  11. // 获取列表
  12. export const commentWebList = (data) => {
  13. return axios({
  14. method: 'post',
  15. url: '/web/comment/list',
  16. data
  17. })
  18. }
  19. // -----------------------后台----------------------------
  20. // 获取列表
  21. export const commentList = (data) => {
  22. return axios({
  23. method: 'post',
  24. url: '/cms/comment/list',
  25. data
  26. })
  27. }
  28. // 留言的审核-通过2,不通过1
  29. export const commentAudit = (status, id) => {
  30. return axios({
  31. method: 'get',
  32. url: `/cms/comment/audit/${id}/${status}`
  33. })
  34. }
  35. // 删除留言
  36. export const commentRemove = (id) => {
  37. return axios({
  38. method: 'get',
  39. url: `/cms/comment/remove/${id}`
  40. })
  41. }