detail.js 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. const _Http = getApp().globalData.http;
  2. Page({
  3. data: {
  4. sa_orderid: null,
  5. tabsActive:0,
  6. tabsList: [{
  7. label: "产品明细",
  8. icon: "icon-tabxiangxixinxi1"
  9. }, {
  10. label: "附件",
  11. icon: "icon-tabgenjinjilu"
  12. }, {
  13. label: "订单进度",
  14. icon: "icon-tabcaozuojilu1"
  15. }, {
  16. label: "发票",
  17. icon: "icon-tabgenjinjilu"
  18. }],
  19. },
  20. onLoad(options) {
  21. console.log(options)
  22. this.setData({
  23. sa_orderid: options.id
  24. });
  25. this.getDetail();
  26. },
  27. getDetail() {
  28. _Http.basic({
  29. "id": 20221108151302,
  30. "content": {
  31. "sa_orderid": this.data.sa_orderid
  32. }
  33. }).then(res => {
  34. console.log("订单详情", res)
  35. if (res.msg != '成功') return wx.showToast({
  36. title: res.msg,
  37. icon: "none"
  38. });
  39. this.setData({
  40. detail: res.data
  41. })
  42. })
  43. }
  44. })