index.js 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. const app = getApp();
  2. Page({
  3. data: {
  4. StatusBar: app.globalData.StatusBar,
  5. CustomBar: app.globalData.CustomBar,
  6. mytask:[{
  7. img: "../../img/server/order.png",
  8. openpath: "/pages/task/lyg/index",
  9. tab:0,
  10. text: "任务中心"
  11. },
  12. {
  13. img: "../../img/server/doing.png",
  14. openpath: "/pages/task/lyg/index",
  15. tab:1,
  16. text: "待交付"
  17. },
  18. {
  19. img: "../../img/server/account.png",
  20. openpath: "/pages/task/lyg/index",
  21. tab:2,
  22. text: "已交付"
  23. },
  24. {
  25. img: "../../img/server/history.png",
  26. openpath: "/pages/task/lyg/index",
  27. tab:3,
  28. text: "已完成"
  29. }
  30. ],
  31. server:[
  32. {
  33. img: "../../img/server/identify.png",
  34. openpath: "/pages/tool/identify/index",
  35. text: "实名认证"
  36. },
  37. {
  38. img: "../../img/server/band.png",
  39. openpath: "/pages/tool/band/band",
  40. text: "绑定银行"
  41. },
  42. {
  43. img: "../../img/server/credit.png",
  44. openpath: "/pages/tool/empty/index",
  45. text: "营业执照"
  46. },
  47. {
  48. img: "../../img/server/info.png",
  49. openpath: "/pages/tool/agree/agree",
  50. text: "电子合同"
  51. }
  52. ],
  53. other:[
  54. {
  55. img: "../../img/icons/mesopen.png",
  56. openpath: "/pages/user/info/index",
  57. text: "我的信息"
  58. },
  59. {
  60. img: "../../img/server/help.png",
  61. openpath: "/pages/tool/empty/index",
  62. text: "联系客服"
  63. },
  64. {
  65. img: "../../img/server/more.png",
  66. openpath: "/pages/tool/empty/index",
  67. text: "其他更多"
  68. }
  69. ]
  70. },
  71. selectTag(e){
  72. let {tab, url} = e.currentTarget.dataset;
  73. console.log( {tab, url} )
  74. app.setTaskTab( tab );
  75. wx.switchTab({
  76. url: url,
  77. })
  78. },
  79. onLoad: function (options) {
  80. app.getMakerInfo()
  81. },
  82. gotoInfo( ){
  83. wx.navigateTo({
  84. url: '/pages/user/info/index',
  85. })
  86. },
  87. /**
  88. * 生命周期函数--监听页面初次渲染完成
  89. */
  90. onReady: function () {
  91. },
  92. /**
  93. * 生命周期函数--监听页面显示
  94. */
  95. onShow: function () {
  96. },
  97. /**
  98. * 生命周期函数--监听页面隐藏
  99. */
  100. onHide: function () {
  101. },
  102. /**
  103. * 生命周期函数--监听页面卸载
  104. */
  105. onUnload: function () {
  106. },
  107. /**
  108. * 页面相关事件处理函数--监听用户下拉动作
  109. */
  110. onPullDownRefresh: function () {
  111. },
  112. /**
  113. * 页面上拉触底事件的处理函数
  114. */
  115. onReachBottom: function () {
  116. },
  117. /**
  118. * 用户点击右上角分享
  119. */
  120. onShareAppMessage: function () {
  121. }
  122. })