// pages/mine_data/mine_data.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    setting: '',//区域配置信息
    userState: '',//用户信息
  },
  onLoad: function (options) {
    let setting = my.getStorageSync({'key':'setting'}).data
    let userState = my.getStorageSync({'key':'userState'}).data
    this.setData({
      setting: setting,
      userState: userState
    })
  },
  onReady: function () {

  },

  onShow: function () {

  },

  onHide: function () {

  },

  onUnload: function () {

  },

  onPullDownRefresh: function () {

  },

  onReachBottom: function () {

  },

  onShareAppMessage: function () {

  },
  myAccount: function () {
    my.navigateTo({
      url: '/pages/my_account/my_account',
    })
  },
  realName: function () {
    if (this.data.userState.is_card_certified == 1) {
      return;
    } else {
      my.navigateTo({
        url: '/pages/real_name/real_name',
      })
    }

  }
})