小程序端工程代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

153 lines
2.8 KiB

  1. import request from "@/utils/request";
  2. /**
  3. * 拼团列表
  4. */
  5. export function getCombinationList(data) {
  6. return request.get("/combination/list", data, { login: false });
  7. }
  8. /**
  9. * 拼团产品详情
  10. * @param {*} id
  11. */
  12. export function getCombinationDetail(id) {
  13. return request.get("/combination/detail/" + id, {}, { login: true });
  14. }
  15. /**
  16. * 拼团 开团
  17. * @param {*} id
  18. */
  19. export function getCombinationPink(id) {
  20. return request.get("/combination/pink/" + id);
  21. }
  22. /**
  23. * 拼团 取消开团
  24. */
  25. export function getCombinationRemove(data) {
  26. return request.post("/combination/remove", data);
  27. }
  28. /**
  29. * 拼团海报
  30. * @param {*} id
  31. */
  32. export function getCombinationPoster(data) {
  33. return request.post("/combination/poster", data);
  34. }
  35. /**
  36. * 秒杀列表配置
  37. */
  38. export function getSeckillConfig() {
  39. return request.get("/seckill/index", {}, { login: false });
  40. }
  41. /**
  42. * 秒杀列表
  43. */
  44. export function getSeckillList(time, data) {
  45. return request.get("/seckill/list/" + time, data, { login: false });
  46. }
  47. /**
  48. * 秒杀产品详情
  49. */
  50. export function getSeckillDetail(id) {
  51. return request.get("/seckill/detail/" + id, {}, { login: true });
  52. }
  53. /**
  54. * 砍价列表
  55. * @param {*} data
  56. */
  57. export function getBargainList(data) {
  58. return request.get("/bargain/list", data, { login: false });
  59. }
  60. /**
  61. * 砍价产品详情
  62. */
  63. export function getBargainDetail(id) {
  64. return request.get("/bargain/detail/" + id);
  65. }
  66. /**
  67. * 砍价 观看/分享/参与次数
  68. */
  69. export function getBargainShare(data) {
  70. return request.post("/bargain/share", data);
  71. }
  72. /**
  73. * 砍价开启
  74. * @param {*} data
  75. */
  76. export function getBargainStart(data) {
  77. return request.post("/bargain/start", data);
  78. }
  79. /**
  80. * 砍价 帮助好友砍价
  81. * @param {*} data
  82. */
  83. export function getBargainHelp(data) {
  84. return request.post("/bargain/help", data);
  85. }
  86. /**
  87. * 砍价 砍掉金额
  88. * @param {*} data
  89. */
  90. export function getBargainHelpPrice(data) {
  91. return request.post("/bargain/help/price", data);
  92. }
  93. /**
  94. * 砍价 砍价帮总人数剩余金额进度条已经砍掉的价格
  95. * @param {*} data
  96. */
  97. export function getBargainHelpCount(data) {
  98. return request.post("/bargain/help/count", data);
  99. }
  100. /**
  101. * 砍价 开启砍价用户信息
  102. * @param {*} data
  103. */
  104. export function getBargainStartUser(data) {
  105. return request.post("/bargain/start/user", data);
  106. }
  107. /**
  108. * 砍价 砍价帮
  109. * @param {*} data
  110. */
  111. export function getBargainHelpList(data) {
  112. return request.post("/bargain/help/list", data);
  113. }
  114. /**
  115. * 砍价海报
  116. * @param {*} data
  117. */
  118. export function getBargainPoster(data) {
  119. return request.post("/bargain/poster", data);
  120. }
  121. /**
  122. * 砍价列表(已参与)
  123. * @param {*} data
  124. */
  125. export function getBargainUserList(data) {
  126. return request.get("/bargain/user/list", data);
  127. }
  128. /**
  129. * 砍价取消
  130. */
  131. export function getBargainUserCancel(data) {
  132. return request.post("/bargain/user/cancel", data);
  133. }