diff --git a/src/views/home/helpDialog.vue b/src/views/home/helpDialog.vue index 6455d4c..9c200bd 100644 --- a/src/views/home/helpDialog.vue +++ b/src/views/home/helpDialog.vue @@ -108,20 +108,15 @@ export default { mounted() { this.token = getToken() if(this.$route.params.name) { - if(this.$route.params.boxId.split("id=")[1] != 'undefined') { - this.boxId = this.$route.params.boxId.split("id=")[1]; - this.boxCode = this.$route.params.box.split("box=")[1]; + if(this.$route.params.code.split("=")[0] == 'box') { + this.boxCode = this.$route.params.code.split("box=")[1]; this.getBoxData() if(this.token) { this.getHelpBoxLog() - // this.helpConfirm() - this.initBoxState(this.boxCode,this.boxId) + this.initBoxState(this.boxCode) } - // } else { - // this.$emit('handleClose') } } - }, methods: { // 宝箱信息接口 diff --git a/src/views/home/index.vue b/src/views/home/index.vue index 18ed80d..1f146aa 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -750,8 +750,10 @@ export default { this.initData() this.$nextTick(() => { if (this.$route.params.code) { - if(this.$route.params.code.split("=")[0] == 'box') { - this.helpDialogVisible = true + if (this.$route.params.code.split("=")[0] == "box") { + if(this.$route.params.code.split("=").split[1]) { + this.helpDialogVisible = true; + } } } }); @@ -772,8 +774,12 @@ export default { this.myInviteCount = this.userData.inviteCount this.myEnhanceCount = this.userData.enhanceCount this.inWhiteList = this.userData.inWhiteList - if(this.$route.params.name) { - this.helpConfirm() + if (this.$route.params.code) { + if(this.$route.params.code.split("=")[0] == 'new') { + if (this.$route.params.code.split("new=")[1] != "undefined") { + this.helpConfirm() + } + } } } else {