diff --git a/rc-busness/pages/personal/mypersonal.vue b/rc-busness/pages/personal/mypersonal.vue index 9ff515cf..eb39c0c7 100644 --- a/rc-busness/pages/personal/mypersonal.vue +++ b/rc-busness/pages/personal/mypersonal.vue @@ -247,73 +247,57 @@ export default { } }, findall(){ - console.log('PPP'); - console.log(this.userid.length); - - let user= localStorage.getItem("userInfo"); - if(user==undefined||user==null||user==''){ - this.$message({ - type: 'warning', - message: '您还未登录' - }); - return - - }else{ - this.$router.push({ - path: "/personal/useraddress/", - query: { - stype: 0, - }, - }); - } - + let user= this.$store.state.userInfo; + if(user==undefined||user==null||user==''){ + this.$message({ + type: 'warning', + message: '您还未登录' + }); + return + + } else { + this.$router.push({ + path: "/personal/useraddress/", + query: { + stype: 0, + }, + }); + } }, //地址的跳转 -obligation(item,index){ - console.log(index); - console.log(item); - let user= localStorage.getItem("userInfo"); - if(user==undefined||user==null||user==''){ - this.$message({ - type: 'warning', - message: '您还未登录' - }); - return - - - }else{ - if(item.title=='待付款'){ - this.$router.push({ - path: "/personal/useraddress", - query: { - stype: 1, - }, - }); - - } - - else if(item.title=='待发货'){ - this.$router.push({ - path: "/personal/useraddress", - query: { - stype: 2, - }, - }); - } - else if(item.title=='待收货'){ - this.$router.push({ - path: "/personal/useraddress", - query: { - stype: 3, - }, - }); - } - } - -}, - - - + obligation(item,index){ + let user= this.$store.state.userInfo; + if(user==undefined||user==null||user==''){ + this.$message({ + type: 'warning', + message: '您还未登录' + }); + return + }else{ + if(item.title=='待付款'){ + this.$router.push({ + path: "/personal/useraddress", + query: { + stype: 1, + }, + }); + } else if(item.title=='待发货') { + this.$router.push({ + path: "/personal/useraddress", + query: { + stype: 2, + }, + }); + } else if(item.title=='待收货') { + this.$router.push({ + path: "/personal/useraddress", + query: { + stype: 3, + }, + }); + } + } + }, handleClose(){ this.dialogInfo1=false; console.log(this.dialogInfo1); @@ -347,39 +331,41 @@ obligation(item,index){ } }, openaddress(item,index){ - let user= localStorage.getItem("userInfo"); + let user= this.$store.state.userInfo; if(user==undefined||user==null||user==''){ this.$message({ type: 'warning', message: '您还未登录' }); - return - - }else{ - if(item.title=='收货地址'){ - this.$router.push({ - path: `/useraddress/openaddress/` - }) + return + } else { + if(item.title=='收货地址'){ + this.$router.push({ + path: `/useraddress/openaddress/` + }) + } + if(index==0){ + this.userlog=true + _hmt.push([ + "_trackCustomEvent", + "jump_to_crmMiniApp", + { + "type":"积分商城", + } + ]) + let isMobile = this.ifadroind(); + if(isMobile) + window.location.href="weixin://dl/business/?t=BE1OA2AngRs"; + } + if(index==1){ + this.$router.push({ + path: `/personal/discount/` + }) + } } - if(index==0){ - this.userlog=true - let isMobile = this.ifadroind(); - if(isMobile) - window.location.href="weixin://dl/business/?t=BE1OA2AngRs"; - } - - if(index==1){ - this.$router.push({ - path: `/personal/discount/` - }) - } - } - }, - opendialog(){ - - this.ifadroind(); + this.ifadroind(); } }, mounted() { diff --git a/rc-busness/pages/productdetails/producted.vue b/rc-busness/pages/productdetails/producted.vue index eb7b8d16..8e9a280d 100644 --- a/rc-busness/pages/productdetails/producted.vue +++ b/rc-busness/pages/productdetails/producted.vue @@ -659,7 +659,7 @@ export default { this.courseId(item); if (orderm == 0) { this.$message({ - type: "warning", + type: "success", message: "加入购物车成功", }); _hmt.push([