Commit 809f3f00 authored by zhangyanni's avatar zhangyanni

优化

parent 744f9081
import Vue from 'vue'; import Vue from 'vue';
import VueI18n from 'vue-i18n'; import VueI18n from 'vue-i18n';
import api from '../../src/views/loginregister/api/api'; import api from '../../src/views/loginregister/api/api';
import $ from 'jquery';
import publicFunc from '../../src/common/public'
Vue.use(VueI18n); Vue.use(VueI18n);
const i18n = new VueI18n({ const i18n = new VueI18n({
locale: window.sessionStorage.getItem("language")||"zh-CN", // 语言标识 locale: window.sessionStorage.getItem("language")||"zh-CN", // 语言标识
......
...@@ -143,8 +143,7 @@ ...@@ -143,8 +143,7 @@
isShowErrorText4: false, isShowErrorText4: false,
isShowErrorText5: false, isShowErrorText5: false,
uploadDisabled: false,//是否禁用上传图片 uploadDisabled: false,//是否禁用上传图片
disabledFlag:0, disabledFlag:0
isSendPcCode:false
} }
}, },
...@@ -385,16 +384,9 @@ ...@@ -385,16 +384,9 @@
this.getUserInfoFunc(); this.getUserInfoFunc();
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==10){ if(data&&which==10){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -81,8 +81,7 @@ ...@@ -81,8 +81,7 @@
message: null message: null
}, },
fullscreenLoading: false, fullscreenLoading: false,
showMessageInfo:false, showMessageInfo:false
isSendPcCode:false,
} }
}, },
methods:{ methods:{
...@@ -261,16 +260,9 @@ ...@@ -261,16 +260,9 @@
mounted(){ mounted(){
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==9){ if(data&&which==9){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -73,8 +73,7 @@ ...@@ -73,8 +73,7 @@
type: "success", type: "success",
message: null message: null
}, },
showMessageInfo:false, showMessageInfo:false
isSendPcCode:false
} }
}, },
methods:{ methods:{
...@@ -248,16 +247,9 @@ ...@@ -248,16 +247,9 @@
mounted() { mounted() {
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==7){ if(data&&which==7){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
// 每次都让盒子移动指定的距离,在我自己做的项目中,这种字符串拼接的方法并没有生效 // 每次都让盒子移动指定的距离,在我自己做的项目中,这种字符串拼接的方法并没有生效
// outbox.style = 'transform: translateX3d(' + startDis + 'px)' // outbox.style = 'transform: translateX3d(' + startDis + 'px)'
// 后面换了es6的模板字符串就可以了 // 后面换了es6的模板字符串就可以了
outbox.style = `transform: translateX(${startDis}px)` outbox.style.transform = `translateX(${startDis}px)`
// outbox.style = 'transform: translateX(\' + startDis + \' px)' // outbox.style = 'transform: translateX(\' + startDis + \' px)'
// outbox.style.marginLeft = 'startDis' // outbox.style.marginLeft = 'startDis'
// console.log('这里:', startDis) // console.log('这里:', startDis)
......
...@@ -117,8 +117,7 @@ ...@@ -117,8 +117,7 @@
message:null message:null
}, },
showMessageInfo:false, showMessageInfo:false,
fullscreenLoading:false, fullscreenLoading:false
isSendPcCode:false
} }
}, },
methods: { methods: {
...@@ -323,16 +322,9 @@ ...@@ -323,16 +322,9 @@
if(this.$route.query.refereesId||this.$route.query.registerChannel) this.getActiveName(); if(this.$route.query.refereesId||this.$route.query.registerChannel) this.getActiveName();
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==8){ if(data&&which==8){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -80,8 +80,7 @@ ...@@ -80,8 +80,7 @@
showCount:true, showCount:true,
count:'', count:'',
flag:0, flag:0,
fullscreenLoading:false, fullscreenLoading:false
isSendPcCode:false
} }
}, },
methods:{ methods:{
...@@ -241,16 +240,9 @@ ...@@ -241,16 +240,9 @@
mounted(){ mounted(){
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==11){ if(data&&which==11){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -106,8 +106,7 @@ ...@@ -106,8 +106,7 @@
messageObj:{ messageObj:{
type:"success", type:"success",
message:null message:null
}, }
isSendPcCode:false
} }
}, },
methods: { methods: {
...@@ -300,16 +299,9 @@ ...@@ -300,16 +299,9 @@
if(this.$route.query.refereesId||this.$route.query.registerChannel) this.getActiveName(); if(this.$route.query.refereesId||this.$route.query.registerChannel) this.getActiveName();
globalMsg.$on("isSendCode",(data,which)=>{ globalMsg.$on("isSendCode",(data,which)=>{
if(data&&which==6){ if(data&&which==6){
this.isSendPcCode = true;
}
})
},
watch:{
isSendPcCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -188,8 +188,7 @@ ...@@ -188,8 +188,7 @@
disabledFlag: 0, disabledFlag: 0,
userInfo: window.sessionStorage.getItem("userInfo") ? JSON.parse(this.Base64.decode(window.sessionStorage.getItem("userInfo"))) : null, userInfo: window.sessionStorage.getItem("userInfo") ? JSON.parse(this.Base64.decode(window.sessionStorage.getItem("userInfo"))) : null,
imgUrls:[], imgUrls:[],
isPhoto:true, isPhoto:true
isSendCode:false
} }
}, },
...@@ -489,16 +488,9 @@ ...@@ -489,16 +488,9 @@
this.getInitData(); this.getInitData();
globalMsg.$on("isPhoneSendCode",(data,which)=>{ globalMsg.$on("isPhoneSendCode",(data,which)=>{
if(data&&which==5){ if(data&&which==5){
this.isSendCode = true;
}
})
},
watch:{
isSendCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -68,8 +68,7 @@ ...@@ -68,8 +68,7 @@
showCount: true, showCount: true,
count: '', count: '',
flag: 0, flag: 0,
fullscreenLoading: false, fullscreenLoading: false
isSendCode:false
} }
}, },
methods:{ methods:{
...@@ -243,16 +242,9 @@ ...@@ -243,16 +242,9 @@
mounted() { mounted() {
globalMsg.$on("isPhoneSendCode",(data,which)=>{ globalMsg.$on("isPhoneSendCode",(data,which)=>{
if(data&&which==4){ if(data&&which==4){
this.isSendCode = true;
}
})
},
watch:{
isSendCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -97,8 +97,7 @@ ...@@ -97,8 +97,7 @@
count:'', count:'',
protocolVisible:false, protocolVisible:false,
className:"height600px", className:"height600px",
fullscreenLoading:false, fullscreenLoading:false
isSendCode:false
} }
}, },
...@@ -271,16 +270,9 @@ ...@@ -271,16 +270,9 @@
mounted() { mounted() {
globalMsg.$on("isPhoneSendCode",(data,which)=>{ globalMsg.$on("isPhoneSendCode",(data,which)=>{
if(data&&which==3){ if(data&&which==3){
this.isSendCode = true;
}
})
},
watch:{
isSendCode(val){
if(val){
this.getCodeFunc(); this.getCodeFunc();
} }
} })
} }
} }
</script> </script>
......
...@@ -62,8 +62,7 @@ ...@@ -62,8 +62,7 @@
count:'', count:'',
flag:0, flag:0,
fullscreenLoading:false, fullscreenLoading:false,
lang:this.$i18n.locale=="zh-CN"?1:2, lang:this.$i18n.locale=="zh-CN"?1:2
isSendCode:false
} }
}, },
methods:{ methods:{
...@@ -233,17 +232,10 @@ ...@@ -233,17 +232,10 @@
mounted() { mounted() {
globalMsg.$on("isPhoneSendCode",(data,which)=>{ globalMsg.$on("isPhoneSendCode",(data,which)=>{
if(data&&this.$route.path=='/loginByPhone'&&which==2){ if(data&&this.$route.path=='/loginByPhone'&&which==2){
this.isSendCode = true; this.getCodeFunc();
} }
}) })
},
watch:{
isSendCode(val){
if(val){
this.getCodeFunc();
}
}
} }
} }
</script> </script>
......
...@@ -95,8 +95,7 @@ ...@@ -95,8 +95,7 @@
type:"success", type:"success",
message:null message:null
}, },
fullscreenLoading:false, fullscreenLoading:false
isSendCode:false
} }
}, },
...@@ -273,18 +272,11 @@ ...@@ -273,18 +272,11 @@
mounted() { mounted() {
globalMsg.$on("isPhoneSendCode",(data,which)=>{ globalMsg.$on("isPhoneSendCode",(data,which)=>{
if(data&&this.$route.path=='/mobileRegister'&&which==1){ if(data&&this.$route.path=='/mobileRegister'&&which==1){
this.isSendCode = true; this.getCodeFunc();
} }
}) })
},
watch:{
isSendCode(val){
if(val){
this.getCodeFunc();
}
}
} }
} }
</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