refund.js 806 B

123456789101112131415161718192021222324252627282930
  1. import request from '@/utils/request'
  2. // api地址
  3. const api = {
  4. list: 'clientApi/refund/list',
  5. goods: 'clientApi/refund/goods',
  6. apply: 'clientApi/refund/submit',
  7. detail: 'clientApi/refund/detail',
  8. delivery: 'clientApi/refund/delivery'
  9. }
  10. // 售后单列表
  11. export const list = (param, option) => {
  12. return request.get(api.list, param, option)
  13. }
  14. // 申请售后
  15. export const apply = (orderId, data) => {
  16. return request.post(api.apply, { orderId, type: data.type, remark: data.content, images: data.images })
  17. }
  18. // 售后单详情
  19. export const detail = (refundId, param) => {
  20. return request.get(api.detail, { refundId, ...param })
  21. }
  22. // 用户发货
  23. export const delivery = (refundId, expressName, expressNo) => {
  24. return request.post(api.delivery, { refundId, expressName, expressNo })
  25. }