result.js 1.7 KB
const app = getApp();
Page({

  /**
   * 页面的初始数据
   */
  data: {
    datalist: '',
    list: ''
  },
  getdatalist() {
    let that = this;
    let url = 'index/member_center/status';
    let head = {
      'XX-Token': wx.getStorageSync('token')
    }
    app.post(url, {}, head).then((res) => {
      that.setData({
        datalist: res
      })
    }).catch((err) => {

    })

  },
  getdatalists() {
    let that = this;
    let url = '/index/second/getMyStatus';
    let head = {
      'XX-Token': wx.getStorageSync('token')
    }
    app.post(url, {}, head).then((res) => {
      that.setData({
        list: res
      })
    }).catch((err) => {

    })

  },


  // 提示
  click: function (e) {
    this.setData({
      hiddenName: !this.data.hiddenName
    })
  },
  getcomfirm() {
    wx.navigateTo({
      url: '/pages/apply/apply',
    })

  },

  goindex() {
    wx.switchTab({
      url: '/pages/index/index'
    })
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {

  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    let that = this;
    that.getdatalist();
    that.getdatalists();

  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})