mine.ts 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. // pages/mine/mine.ts
  2. Page({
  3. /**
  4. * 页面的初始数据
  5. */
  6. data: {
  7. // 功能菜单项
  8. menulists: [{id: 1, title: '资金资产', img: 'medal', path: "/mMine/pages/assets/assets"},
  9. {id: 2, title: "交易服务", img: 'invitation', path: "/mMine/pages/tradeserver/tradeserver"},
  10. {id: 3, title: '现货挂牌', img: 'underway', path: "/mTrade/pages/listing/listing"},
  11. {id: 4, title: '仓储服务', img: 'hot', path: "/mMine/pages/storage/storage"}],
  12. // 列表菜单项
  13. tablelists: [{id: 1, title: '实名认证', path: "/mMine/pages/realauth/realauth"},
  14. {id: 2, title: '签约解约管理', path: "/mMine/pages/bank/bank"},
  15. {id: 3, title: '我的库存', path: "/mMine/pages/myinventorys/myinventorys"},
  16. {id: 4, title: '单据查询', path: "/mMine/pages/ordersearch/ordersearch"},
  17. {id: 5, title: '我的订单', path: "/mMine/pages/myorders/myorders"},
  18. {id: 6, title: '我的报表', path: "/mMine/pages/myreports/myreports"},
  19. {id: 7, title: '我的履约', path: "/mMine/pages/myperformance/myperformance"}],
  20. /// 微信头像
  21. avatarUrl: "",
  22. /// 微信昵称
  23. nickName: ""
  24. },
  25. /**
  26. * 进入系统设置
  27. */
  28. goToSettings() {
  29. wx.navigateTo({
  30. url: '/mMine/pages/settings/settings'
  31. })
  32. },
  33. /**
  34. * 生命周期函数--监听页面加载
  35. */
  36. onLoad() {
  37. /// 获取微信头像
  38. let url = wx.getStorageSync('avatarUrl')
  39. if (url) {
  40. this.setData({
  41. avatarUrl: url
  42. })
  43. }
  44. },
  45. /**
  46. * 生命周期函数--监听页面初次渲染完成
  47. */
  48. onReady() {
  49. },
  50. /**
  51. * 生命周期函数--监听页面显示
  52. */
  53. onShow() {
  54. this.getTabBar().init()
  55. },
  56. /**
  57. * 生命周期函数--监听页面隐藏
  58. */
  59. onHide() {
  60. },
  61. /**
  62. * 生命周期函数--监听页面卸载
  63. */
  64. onUnload() {
  65. },
  66. /**
  67. * 页面相关事件处理函数--监听用户下拉动作
  68. */
  69. onPullDownRefresh() {
  70. },
  71. /**
  72. * 页面上拉触底事件的处理函数
  73. */
  74. onReachBottom() {
  75. },
  76. /**
  77. * 用户点击右上角分享
  78. */
  79. onShareAppMessage() {
  80. }
  81. })