C端小程序
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

67 lines
1.5 KiB

  1. // pages/index/sw/index.js
  2. let config = require('../../../config/config.js')
  3. let Http = require('../../../utils/HttpBasics')
  4. Component({
  5. /**
  6. * 组件的属性列表
  7. */
  8. properties: {
  9. },
  10. /**
  11. * 组件的初始数据
  12. */
  13. data: {
  14. list: [
  15. // {
  16. // img: "http://img02.tooopen.com/images/20150928/tooopen_sy_143912755726.jpg",
  17. // name: "海鲜焗饭",
  18. // time: "2天12小时25分钟",
  19. // oPrice: "59.00",
  20. // pPrice: "1.00",
  21. // },
  22. // {
  23. // img: "http://img06.tooopen.com/images/20160818/tooopen_sy_175866434296.jpg",
  24. // name: "海鲜焗饭",
  25. // time: "2天12小时25分钟",
  26. // oPrice: "59.00",
  27. // pPrice: "1.00",
  28. // },
  29. // {
  30. // img: "http://img02.tooopen.com/images/20150928/tooopen_sy_143912755726.jpg",
  31. // name: "海鲜焗饭",
  32. // time: "2天12小时25分钟",
  33. // oPrice: "59.00",
  34. // pPrice: "1.00",
  35. // },
  36. // {
  37. // img: "http://img06.tooopen.com/images/20160818/tooopen_sy_175866434296.jpg",
  38. // name: "海鲜焗饭",
  39. // time: "2天12小时25分钟",
  40. // oPrice: "59.00",
  41. // pPrice: "1.00",
  42. // },
  43. ]
  44. },
  45. /**
  46. * 组件的方法列表
  47. */
  48. methods: {
  49. },
  50. ready() {
  51. Http.get({
  52. url: config.api.couponChannelList,
  53. data: {
  54. pageNum: 1,
  55. pageSize: 10
  56. }
  57. }).then(res => {
  58. this.setData({
  59. list: res.list
  60. })
  61. })
  62. }
  63. })