| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141 |
- import {
- imgServerUrl
- } from '../../config/config.js'
- import {
- getMoneyAccountDetail,
- getHpMemberDetail
- } from '../../services/index.js'
- Page({
- data: {
- moneyBalance: '0.00',
- imgServerUrl: imgServerUrl,
- confirm: '',
- model_message: '',
- cover: true,
- cancel: false,
- },
- tixian() {
- wx.showModal({
- title: '提示',
- content: '如果您有提现需求,请联系客服400-692-0099',
- confirmText: '知道了',
- showCancel: false,
- success: res => {
- if (res.confirm) {
- wx.makePhoneCall({
- phoneNumber: '4006920099',
- })
- // wx.showModal({
- // title: '提示',
- // content: '是否立即拨打电话',
- // success: res => {
- // if (res.confirm) {
- // }
- // }
- // })
- }
- }
- })
- return
- const cover = !this.data.cover;
- getHpMemberDetail({
- user_id: wx.getStorageSync('user_id'),
- user_token: wx.getStorageSync('user_token'),
- member_id: wx.getStorageSync('member_id'),
- }).then(res => {
- if (res.errcode === 0) {
- let _json = {
- 0: {
- confirm: '好的',
- cancel: true,
- model_message: '为了保证资金安全,请先进行实名认证。'
- },
- 1: {
- confirm: '好的',
- cancel: true,
- model_message: '实名认证正在审核中,请耐心等待。'
- },
- 3: {
- confirm: '去下载',
- cancel: false,
- model_message: '为了保证资金安全,您需要在app上进行提现。'
- },
- }
- this.setData({
- cover,
- ..._json[res.data.hpMember.authenticationStatus]
- })
- }
- })
- },
- confirm() {
- this.setData({
- cover: true
- })
- },
- cancel() {
- this.setData({
- cover: true
- })
- },
- /**
- * 生命周期函数--监听页面加载
- */
- onLoad: function(options) {
- },
- /**
- * 生命周期函数--监听页面初次渲染完成
- */
- onReady: function() {
- },
- /**
- * 生命周期函数--监听页面显示
- */
- onShow: function() {
- getMoneyAccountDetail({
- user_id: wx.getStorageSync('user_id'),
- user_token: wx.getStorageSync('user_token'),
- member_id: wx.getStorageSync('member_id'),
- }).then(res => {
- if (res.errcode === 0) {
- this.setData({
- moneyBalance: res.data.MpMemberAccountAPI.moneyBalance.toFixed(2)
- })
- }
- })
- },
- /**
- * 生命周期函数--监听页面隐藏
- */
- onHide: function() {
- },
- /**
- * 生命周期函数--监听页面卸载
- */
- onUnload: function() {
- },
- /**
- * 页面相关事件处理函数--监听用户下拉动作
- */
- onPullDownRefresh: function() {
- },
- /**
- * 页面上拉触底事件的处理函数
- */
- onReachBottom: function() {
- },
- })
|