Commit a36cbab3 authored by zhengke's avatar zhengke

1

parent 6612f1f4
......@@ -49,8 +49,8 @@
}
</style>
<template>
<view class="mycollection" :style="{'height':contentHeight}" v-if="!loading">
<template>
<view class="mycollection" :style="{'height':contentHeight}" >
<template v-if="!loading">
<u-empty v-if="goodslist.length==0" text="没有任何收藏课程哦~" mode="favor"></u-empty>
<view v-if="goodslist.length>0" style="
height: calc(100vh - 50px);
......@@ -95,7 +95,7 @@
pageTitle: '课程收藏',
loading: true,
contentHeight: 0,
showAuth: false,
showAuth: true,
mainColor: '',
msg: {
pageIndex: 1,
......@@ -113,6 +113,7 @@
nomore: "没有更多了",
},
windowWidth:0,
u:{}
}
},
components: {
......@@ -141,6 +142,7 @@
},
onLoad() {
this.u = uni.getStorageSync("mall_UserInfo");
console.log(!this.u,'UserInfo');
if (!this.u) {
this.u = {
nickName: "未登录",
......
......@@ -172,7 +172,7 @@
</view>
</view>
</u-popup>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth='gbAuth'></auth>
</view>
</template>
<script>
......@@ -224,6 +224,7 @@
},
payBtn:false,
payExit:false,
showAuth:false
};
},
created() {
......@@ -247,12 +248,30 @@
}, 1000);
},
onLoad(option) {
this.current = option.status || 0;
this.getHeadList();
this.payInfo.OpenId=uni.getStorageSync('mall_UserInfo').OpenId;
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else {
this.current = option.status || 0;
this.payInfo.OpenId=uni.getStorageSync('mall_UserInfo').OpenId;
this.getHeadList();
this.getContent();
}
},
methods: {
reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth=false;
this.getContent();
},
//关闭登录窗口
gbAuth() {
uni.navigateBack()
},
getHeadHeight() {
let that = this;
const query = uni.createSelectorQuery().in(this);
......
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