shop.js 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. import request from "@/utils/request.js";
  2. //获取店铺分类
  3. export function store_cate(data) {
  4. return request({
  5. url: '/api/store_cate',
  6. method: 'get',
  7. data
  8. });
  9. }
  10. //获取店铺列表
  11. export function getStoreList(data) {
  12. return request({
  13. url: '/api/store_list',
  14. method: 'get',
  15. data
  16. });
  17. }
  18. //获取店铺详情
  19. export function getStoreDetail(data, id) {
  20. return request({
  21. url: '/api/store_details/' + id,
  22. method: 'get',
  23. data
  24. });
  25. }
  26. // 获取优惠券详情
  27. export function getYhqDetail(data) {
  28. return request({
  29. url: '/api/coupon_datalis',
  30. method: 'get',
  31. data
  32. })
  33. }
  34. export function getGift(data) {
  35. return request({
  36. url: '/api/share',
  37. method: 'post',
  38. data
  39. })
  40. }
  41. // 地址逆解析/api/address
  42. export function getCity(data) {
  43. return request({
  44. url: '/api/address',
  45. method: 'get',
  46. data
  47. })
  48. }
  49. //兑换
  50. export function goDh(data) {
  51. return request({
  52. url: '/api/exchange',
  53. method: 'post',
  54. data
  55. })
  56. }
  57. //转赠
  58. export function gozz(data) {
  59. return request({
  60. url: '/api/donation',
  61. method: 'post',
  62. data
  63. })
  64. }
  65. // 发布优惠券
  66. export function storeCoupon(data) {
  67. return request({
  68. url: '/api/store_coupon',
  69. method: 'post',
  70. data
  71. })
  72. }