detail.js 724 B

1234567891011121314151617181920212223242526272829303132
  1. const _Http = getApp().globalData.http;
  2. Page({
  3. data: {
  4. sa_orderid: null,
  5. },
  6. onLoad(options) {
  7. console.log(options)
  8. this.setData({
  9. sa_orderid: options.id
  10. });
  11. this.getDetail();
  12. },
  13. getDetail() {
  14. _Http.basic({
  15. "id": 20221108151302,
  16. "content": {
  17. "sa_orderid": this.data.sa_orderid
  18. }
  19. }).then(res => {
  20. console.log("订单详情", res)
  21. if (res.msg != '成功') return wx.showToast({
  22. title: res.msg,
  23. icon: "none"
  24. });
  25. this.setData({
  26. detail: res.data
  27. })
  28. })
  29. }
  30. })