wxAccount.js 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. import request from '@/utils/request'
  2. // 创建公众号账户
  3. export function createWxAccount(data) {
  4. return request({
  5. url: '/wechatMp/wx-account/create',
  6. method: 'post',
  7. data: data
  8. })
  9. }
  10. // 更新公众号账户
  11. export function updateWxAccount(data) {
  12. return request({
  13. url: '/wechatMp/wx-account/update',
  14. method: 'put',
  15. data: data
  16. })
  17. }
  18. // 删除公众号账户
  19. export function deleteWxAccount(id) {
  20. return request({
  21. url: '/wechatMp/wx-account/delete?id=' + id,
  22. method: 'delete'
  23. })
  24. }
  25. // 获得公众号账户
  26. export function getWxAccount(id) {
  27. return request({
  28. url: '/wechatMp/wx-account/get?id=' + id,
  29. method: 'get'
  30. })
  31. }
  32. // 获得公众号账户分页
  33. export function getWxAccountPage(query) {
  34. return request({
  35. url: '/wechatMp/wx-account/page',
  36. method: 'get',
  37. params: query
  38. })
  39. }
  40. // 导出公众号账户 Excel
  41. export function exportWxAccountExcel(query) {
  42. return request({
  43. url: '/wechatMp/wx-account/export-excel',
  44. method: 'get',
  45. params: query,
  46. responseType: 'blob'
  47. })
  48. }