diff --git a/pages/login/register.vue b/pages/login/register.vue index 3a3fed1..7ef6113 100644 --- a/pages/login/register.vue +++ b/pages/login/register.vue @@ -126,12 +126,16 @@ } }, _doRegister: function(e) { + let _communityId = un.getStorageSync("DEFAULT_COMMUNITY_ID") + if(!_communityId){ + _communityId = conf.DEFAULT_COMMUNITY_ID; + } let obj = { "link": this.link, "msgCode": this.msgCode, "password": this.password, "openId": uni.getStorageSync(constant.mapping.CURRENT_OPEN_ID), - "defaultCommunityId": conf.DEFAULT_COMMUNITY_ID + "defaultCommunityId": _communityId } if(!this.readme){ wx.showToast({ diff --git a/pages/machine/machineToCharge.vue b/pages/machine/machineToCharge.vue index ec30d20..8d61664 100644 --- a/pages/machine/machineToCharge.vue +++ b/pages/machine/machineToCharge.vue @@ -197,6 +197,9 @@ this.couponCount = chargeCoupons.length; }, _toLogin:function(){ + if(this.communityId){ + uni.setStorageSync("DEFAULT_COMMUNITY_ID",this.communityId); + } uni.navigateTo({ url: '/pages/login/login' })