Browse Source

去掉登录页的分享进入判断,改在首页取值

master
chenxuhui 7 years ago
parent
commit
8436b89ce3
2 changed files with 2 additions and 3 deletions
  1. +2
    -1
      pages/homePage/homePage.js
  2. +0
    -2
      pages/login/login.js

+ 2
- 1
pages/homePage/homePage.js View File

@ -19,6 +19,8 @@ Page({
onLoad: function(options) { onLoad: function(options) {
var that = this; var that = this;
//由登录页面进入详情页变更值为0;分享直接进入为1
app.globalData.shareInState = 0;
// 添加接口请求当前余额 // 添加接口请求当前余额
GetUserProfile(function(res) { GetUserProfile(function(res) {
if (res != null) { if (res != null) {
@ -28,7 +30,6 @@ Page({
} }
var shareURL = app.globalData.shareInPath; var shareURL = app.globalData.shareInPath;
if (shareURL) { if (shareURL) {
app.globalData.shareInState = 0,
wx.navigateTo({ wx.navigateTo({
url: "../../" + shareURL, url: "../../" + shareURL,
complete: function (res) { complete: function (res) {


+ 0
- 2
pages/login/login.js View File

@ -137,8 +137,6 @@ Page({
// 页面生命周期函数 // 页面生命周期函数
onShow: function () { onShow: function () {
var that = this; var that = this;
//由登录页面进入详情页变更值为0;分享直接进入为1
app.globalData.shareInState = 0;
wx.login({ wx.login({
success: function (res) { success: function (res) {
let code = res.code; let code = res.code;


Loading…
Cancel
Save