Browse Source

首页ui接口更换

master
nige 3 years ago
parent
commit
ad616b543e
  1. 21
      app.js

21
app.js

@ -4,8 +4,7 @@ App({
onLaunch: function (options) {
if (options.query.authCode) {
wx.setStorageSync('authCode', options.query.authCode)
}
else {
} else {
wx.removeStorageSync('authCode')
}
this.updateApp()
@ -22,11 +21,22 @@ App({
unique_key: "wechatxcx"
}).then(res => {
let data = JSON.parse(res.data);
data.isTest = data.isTest50?true:false;
data.isTest = data.isTest51 ? true : false;
this.globalData.configJson = data
}).then(() => {
// 获取ui配置文件
commonApi._post("adv/get_home_ui", {}).then(res => {
let obj = {}
res.data.content.forEach(item => {
obj[item.id] = item.image
});
this.globalData.configJson.indexSeason = obj
})
})
// 获取用户信息
// wx.getSetting({
// success: res => {
@ -77,7 +87,10 @@ App({
updateManager.onUpdateFailed(function () {
// 新的版本下载失败
wx.hideLoading();
wx.showToast({ title:'下载失败...', icon:"none" });
wx.showToast({
title: '下载失败...',
icon: "none"
});
})
},
getShareCategoryId: function () {

Loading…
Cancel
Save