Commit 669dc424 authored by 华国豪's avatar 华国豪 🙄

1

parent e4d291f2
...@@ -119,13 +119,12 @@ App({ ...@@ -119,13 +119,12 @@ App({
let data={}; let data={};
var promise = new Promise((resolve, reject) => { var promise = new Promise((resolve, reject) => {
wx.showLoading({ wx.showLoading({
title: '加载中', title: '加载中...',
}); });
let timestamp = (new Date()).valueOf() let timestamp = (new Date()).valueOf()
let sign = md5('msg=' + encodeURIComponent(JSON.stringify(msg)).toLowerCase() + '&' + 'timestamp=' + timestamp + '&' + 'token=' + token + '&' + 'key=' + secretKey) let sign = md5('msg=' + encodeURIComponent(JSON.stringify(msg)).toLowerCase() + '&' + 'timestamp=' + timestamp + '&' + 'token=' + token + '&' + 'key=' + secretKey)
wx.request({ wx.request({
// url: 'https://reborn.oytour.com/api/common/post'+ url, //线上 url: 'https://efficient.oytour.com/'+ url, //线上
url: 'http://efficient.oytour.com/'+ url, //线上
// url: 'http://47.96.12.235:9001/' + url, //测试 // url: 'http://47.96.12.235:9001/' + url, //测试
// url: 'http://192.168.2.215:9000/'+ url, // url: 'http://192.168.2.215:9000/'+ url,
......
...@@ -15,7 +15,7 @@ Page({ ...@@ -15,7 +15,7 @@ Page({
let userInfo = wx.getStorageSync('admin') let userInfo = wx.getStorageSync('admin')
console.log(userInfo) console.log(userInfo)
this.setData({ this.setData({
url: "http://activity.oytour.com/html/task/home.html?customerId=" + userInfo.id + "&accountId=" + userInfo.customerAccountId + "&token=" + userInfo.token + "&secretKey=" + userInfo.secretKey url: "https://activity.oytour.com/html/task/home.html?customerId=" + userInfo.id + "&accountId=" + userInfo.customerAccountId + "&token=" + userInfo.token + "&secretKey=" + userInfo.secretKey
}) })
console.log(this.data.url) console.log(this.data.url)
}, },
......
...@@ -14,7 +14,7 @@ Page({ ...@@ -14,7 +14,7 @@ Page({
onLoad: function (options) { onLoad: function (options) {
console.log(options) console.log(options)
this.setData({ this.setData({
url: "http://activity.oytour.com/html/invesDetails.html" + '?ID=' + options.ID + '&name=' + encodeURI(options.name) + '&MobilePhone=' + options.MobilePhone url: "https://activity.oytour.com/html/invesDetails.html" + '?ID=' + options.ID + '&name=' + encodeURI(options.name) + '&MobilePhone=' + options.MobilePhone
}) })
console.log(this.data.url) console.log(this.data.url)
}, },
......
...@@ -55,16 +55,21 @@ Page({ ...@@ -55,16 +55,21 @@ Page({
*/ */
onLoad: function (options) { onLoad: function (options) {
let userInfo = wx.getStorageSync('admin'); let userInfo = wx.getStorageSync('admin');
if (wx.getStorageSync('admin')) { if (userInfo) {
this.setData({ this.setData({
isLogin: true, isLogin: true,
}) userInfo: userInfo,
} photo: app.state.admin.photo === null ? '' : app.state.admin.photo,
this.setData({ isMember: app.state.admin.isMember,
userInfo: userInfo account: app.state.admin.account,
address: app.state.admin.address,
businessCardPhotos: app.state.admin.businessCardPhotos === null ? [] : app.state.admin.businessCardPhotos,
housePhotos: app.state.admin.housePhotos === null ? [] : app.state.admin.housePhotos,
images: app.state.admin.images === null ? [] : app.state.admin.images
}) })
this.getInfo() this.getInfo()
this.getUserMemberExp() this.getUserMemberExp()
}
}, },
/** /**
...@@ -81,16 +86,21 @@ Page({ ...@@ -81,16 +86,21 @@ Page({
*/ */
onShow: function () { onShow: function () {
let userInfo = wx.getStorageSync('admin'); let userInfo = wx.getStorageSync('admin');
if (wx.getStorageSync('admin')) { if (userInfo) {
this.setData({ this.setData({
isLogin: true, isLogin: true,
}) userInfo: userInfo,
} photo: app.state.admin.photo === null ? '' : app.state.admin.photo,
this.setData({ isMember: app.state.admin.isMember,
userInfo: userInfo account: app.state.admin.account,
address: app.state.admin.address,
businessCardPhotos: app.state.admin.businessCardPhotos === null ? [] : app.state.admin.businessCardPhotos,
housePhotos: app.state.admin.housePhotos === null ? [] : app.state.admin.housePhotos,
images: app.state.admin.images === null ? [] : app.state.admin.images
}) })
this.getInfo() this.getInfo()
this.getUserMemberExp() this.getUserMemberExp()
}
}, },
/** /**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment