shop.js 644 B

12345678910111213141516171819202122232425262728293031323334353637
  1. import {
  2. request
  3. } from '@/request/request.js';
  4. const baseUrl = '/prod-api/mobile-api';
  5. /*
  6. * 获取订单状态
  7. *
  8. *
  9. */
  10. export function getOrderResult(orderSn) {
  11. return request({
  12. url: `${baseUrl}/pay/queryResult/${orderSn}`,
  13. method: 'get'
  14. })
  15. }
  16. /*
  17. * 获取订单信息
  18. *
  19. *
  20. */
  21. export function getPaymentInformation(orderSn) {
  22. return request({
  23. url: `${baseUrl}/pay/wx/prepare?orderSn=${orderSn}`,
  24. method: 'post'
  25. })
  26. }
  27. /*
  28. * 修改用户OpenId
  29. *
  30. *
  31. */
  32. export function updateWxOpenId(openId) {
  33. return request({
  34. url: `${baseUrl}/user/updateOpenId/${openId}`,
  35. method: 'post'
  36. })
  37. }