更新
This commit is contained in:
parent
ea3f8f8a84
commit
baea439695
1
App.vue
1
App.vue
@ -38,6 +38,7 @@
|
||||
data
|
||||
} = await userInfo();
|
||||
this.$store.commit('setUserInfo', data);
|
||||
this.$isResolve()
|
||||
// uni.$emit('home_initUserInfo', data);
|
||||
return ;
|
||||
}catch(e){
|
||||
|
@ -2,8 +2,8 @@ let httpApiThree;
|
||||
let httpApi; // 总域名
|
||||
let httpApiTwo; // 物流系统域名
|
||||
|
||||
const env = 'dev'; // 开发
|
||||
// const env = 'prod'; // 生产
|
||||
// const env = 'dev'; // 开发
|
||||
const env = 'prod'; // 生产
|
||||
// const env = 'prew'; // 预上线
|
||||
|
||||
switch(env){
|
||||
|
4
main.js
4
main.js
@ -14,6 +14,10 @@ Vue.use(mybtn)
|
||||
Vue.use(company)
|
||||
|
||||
// initRouter()
|
||||
// 让app的onLaunch先执行,主要是用来进行登录
|
||||
Vue.prototype.$onLaunched = new Promise(resolve => {
|
||||
Vue.prototype.$isResolve = resolve
|
||||
})
|
||||
|
||||
|
||||
// #ifndef VUE3
|
||||
|
@ -2,8 +2,8 @@
|
||||
"name" : "里海社区",
|
||||
"appid" : "__UNI__B5B1EDD",
|
||||
"description" : "",
|
||||
"versionName" : "1.0.6",
|
||||
"versionCode" : 106,
|
||||
"versionName" : "1.0.8",
|
||||
"versionCode" : 108,
|
||||
"transformPx" : false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus" : {
|
||||
|
@ -239,7 +239,8 @@
|
||||
showOaHomeData: false, //更新首页计算的值
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
async onLoad() {
|
||||
await this.$onLaunched;
|
||||
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO")).is_captain
|
||||
this.options.data = bj;
|
||||
// uni.$on('home_initUserInfo', (data=null)=>{
|
||||
@ -257,9 +258,10 @@
|
||||
});
|
||||
// #endif
|
||||
},
|
||||
onShow() {
|
||||
async onShow() {
|
||||
// this.getUserIndex()
|
||||
// this.getIndexList()
|
||||
await this.$onLaunched;
|
||||
if(uni.getStorageSync('uniMP'))this.uniMP = true;
|
||||
userInfo().then(({data})=>{
|
||||
this.$store.commit('setUserInfo', data);
|
||||
|
Loading…
x
Reference in New Issue
Block a user