guide.ts 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. import request from '@/config/axios'
  2. import { GuideDataComparisonRespVO } from '@/api/guide/statistics/common'
  3. export interface GuideStatisticsVO {
  4. id: number
  5. day: string
  6. time: Date
  7. guideId: number
  8. nickName: string
  9. picUrl: string
  10. browseCount: number
  11. browseUserCount: number
  12. favoriteCount: number
  13. cartCount: number
  14. orderCount: number
  15. orderPayCount: number
  16. orderPayPrice: number
  17. afterSaleCount: number
  18. afterSaleRefundPrice: number
  19. browseConvertPercent: number
  20. }
  21. // 商品统计 API
  22. export const GuideStatisticsApi = {
  23. // 获得商品统计分析
  24. getGuideStatisticsAnalyse: (params: any) => {
  25. return request.get<GuideDataComparisonRespVO<GuideStatisticsVO>>({
  26. url: '/guide/statistics/guide/analyse',
  27. params
  28. })
  29. },
  30. // 获得商品状况明细
  31. getGuideStatisticsList: (params: any) => {
  32. return request.get<GuideStatisticsVO[]>({
  33. url: '/guide/statistics/guide/list',
  34. params
  35. })
  36. },
  37. // 导出获得商品状况明细 Excel
  38. exportGuideStatisticsExcel: (params: any) => {
  39. return request.download({
  40. url: '/guide/statistics/guide/export-excel',
  41. params
  42. })
  43. },
  44. // 获得商品排行榜分页
  45. getGuideStatisticsRankPage: async (params: any) => {
  46. return await request.get({
  47. url: `/guide/statistics/guide/rank-page`,
  48. params
  49. })
  50. }
  51. }