const app=getApp(); Page({ /** * 页面的初始数据 */ data: { weburl:"", }, /** * 生命周期函数--监听页面加载 */ onLoad(options) { var that=this wx.clearStorage() if(!options.type){ this.setData({ weburl:app.globalData.webUrl + 'applet.html#/mycustomer?orgid='+(!!app.globalData.personMsg.binded.org_id?app.globalData.personMsg.binded.org_id:'')+'&empid='+app.globalData.personMsg.binded.id+'&token=' + app.globalData.token + '&client_type=' + app.globalData.clientype+"&platform="+app.globalData.platform }) }else{ this.setData({ weburl:app.globalData.webUrl + 'applet.html#/mycustomer?orgid='+(!!app.globalData.personMsg.binded.org_id?app.globalData.personMsg.binded.org_id:'')+'&empid='+app.globalData.personMsg.binded.id+'&type='+options.type+'&token=' + app.globalData.token + '&client_type=' + app.globalData.clientype+"&platform="+app.globalData.platform }) } }, /** * 生命周期函数--监听页面初次渲染完成 */ onReady() { }, binderror(){ wx.switchTab({ url: '/pages/customer/customer' }) }, /** * 生命周期函数--监听页面显示 */ onShow() { // this.getTabBar().setData({ // tabflag: true // }) // if (typeof this.getTabBar === 'function' && this.getTabBar()) { // this.getTabBar().setData({ // selected: 1 // }) // } }, /** * 生命周期函数--监听页面隐藏 */ onHide() { }, /** * 生命周期函数--监听页面卸载 */ onUnload() { }, /** * 页面相关事件处理函数--监听用户下拉动作 */ onPullDownRefresh() { }, /** * 页面上拉触底事件的处理函数 */ onReachBottom() { } })