Commit 796d322c authored by Mac's avatar Mac

首页登录 和 领券中心修改

parent b021d5e5
...@@ -85,6 +85,7 @@ export default { ...@@ -85,6 +85,7 @@ export default {
msg:{ msg:{
pageIndex: 1, pageIndex: 1,
pageSize:10, pageSize:10,
SmallShopId:0,
}, },
page_count: 1, page_count: 1,
status: "loadmore", status: "loadmore",
...@@ -124,6 +125,7 @@ export default { ...@@ -124,6 +125,7 @@ export default {
}; };
this.showAuth = true; this.showAuth = true;
} else{ } else{
this.loading = true; this.loading = true;
this.init(); this.init();
} }
...@@ -132,7 +134,7 @@ export default { ...@@ -132,7 +134,7 @@ export default {
methods: { methods: {
init() { init() {
this.msg.SmallShopId = this.u.UserSmallShopId
this.request2( this.request2(
{ {
url: '/api/AppletUser/GetAllCouponPageList', url: '/api/AppletUser/GetAllCouponPageList',
......
...@@ -76,6 +76,7 @@ ...@@ -76,6 +76,7 @@
@goLook="goLook" @goLook="goLook"
@closeBtn="closeBtn" @closeBtn="closeBtn"
></coupon> ></coupon>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'gbAuth'></auth>
</view> </view>
</view> </view>
</template> </template>
...@@ -101,6 +102,7 @@ import addialog from "@/components/addialog/index"; ...@@ -101,6 +102,7 @@ import addialog from "@/components/addialog/index";
import quicknav from "@/components/quicknav/index"; import quicknav from "@/components/quicknav/index";
import coupon from "@/components/coupons/coupons"; import coupon from "@/components/coupons/coupons";
import pingtuan from "@/components/pingtuan/index"; import pingtuan from "@/components/pingtuan/index";
import auth from "@/components/auth/index.vue";
export default { export default {
data() { data() {
return { return {
...@@ -120,6 +122,8 @@ export default { ...@@ -120,6 +122,8 @@ export default {
titleStyle: "", titleStyle: "",
pagePaddingBottom: "0px", pagePaddingBottom: "0px",
showBack: false, showBack: false,
showAuth:false,
U:{},
}; };
}, },
components: { components: {
...@@ -143,6 +147,7 @@ export default { ...@@ -143,6 +147,7 @@ export default {
quicknav, quicknav,
coupon, coupon,
pingtuan, pingtuan,
auth
}, },
onLoad(options) { onLoad(options) {
console.log(options, "option"); console.log(options, "option");
...@@ -218,6 +223,18 @@ export default { ...@@ -218,6 +223,18 @@ export default {
that.updateuserinfo(msg); that.updateuserinfo(msg);
}, },
}); });
}
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
} }
// #endif // #endif
this.init(); this.init();
...@@ -544,6 +561,14 @@ export default { ...@@ -544,6 +561,14 @@ export default {
closeBtn() { closeBtn() {
this.showCoupons = false; this.showCoupons = false;
}, },
reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo");
},
//关闭登录窗口
gbAuth(){
this.showAuth=false;
},
}, },
}; };
</script> </script>
......
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