|
|
@@ -61,23 +61,23 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '展会信息获取失败:'+err,
|
|
|
+ message: '展会信息获取失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
- } else {
|
|
|
- this.$router.push({
|
|
|
- name: 'login'
|
|
|
- })
|
|
|
}
|
|
|
},
|
|
|
tokenLogin(token) {
|
|
|
this.$store.dispatch('tokenLogin', { token: token }).then(res => {
|
|
|
- this.gotoForm()
|
|
|
+ if (this.expo_key) {
|
|
|
+ this.gotoForm()
|
|
|
+ } else {
|
|
|
+ this.$router.push({ name: 'userHome' })
|
|
|
+ }
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '使用本地令牌登录失败'+err,
|
|
|
+ message: '使用本地令牌登录失败' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
this.$message.error(err.message)
|
|
|
@@ -122,7 +122,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '领英授权登录失败'+err,
|
|
|
+ message: '领英授权登录失败' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
showError()
|
|
|
@@ -146,7 +146,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '谷歌授权登录失败'+err,
|
|
|
+ message: '谷歌授权登录失败' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
showError()
|
|
|
@@ -174,7 +174,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '验证码发送失败:'+err,
|
|
|
+ message: '验证码发送失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
@@ -201,7 +201,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '验证码发送失败'+err,
|
|
|
+ message: '验证码发送失败' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
@@ -233,14 +233,17 @@ export default Vue.extend({
|
|
|
login_type: this.regWay ? '0' : '1',
|
|
|
login_portal: 0
|
|
|
}).then(res => {
|
|
|
- this.gotoForm()
|
|
|
+ if (this.expo_key) {
|
|
|
+ this.gotoForm()
|
|
|
+ } else {
|
|
|
+ this.$router.push({ name: 'userHome' })
|
|
|
+ }
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '登录失败:'+err,
|
|
|
+ message: '登录失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
-
|
|
|
})
|
|
|
},
|
|
|
gotoForm() {
|
|
|
@@ -265,7 +268,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '注册失败:'+err,
|
|
|
+ message: '注册失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
@@ -280,7 +283,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '注册失败:'+err,
|
|
|
+ message: '注册失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
@@ -298,7 +301,7 @@ export default Vue.extend({
|
|
|
}).catch(err => {
|
|
|
this.$notify({
|
|
|
title: '提示',
|
|
|
- message: '注册失败:'+err,
|
|
|
+ message: '注册失败:' + err,
|
|
|
type: 'error'
|
|
|
})
|
|
|
})
|
|
|
@@ -307,11 +310,12 @@ export default Vue.extend({
|
|
|
})
|
|
|
</script>
|
|
|
<template>
|
|
|
- <div class="body">
|
|
|
+ <div class="login-body">
|
|
|
<div class="head">
|
|
|
- <div class="title">
|
|
|
+ <div v-if="expo_key" class="title">
|
|
|
{{ isLogin?'登录账号':'注册账号' }}
|
|
|
</div>
|
|
|
+ <img v-else class="logo" src="/static/image/logo_big.png">
|
|
|
<div class="desc">
|
|
|
中国大陆观众建议使用手机号码进行注册登录。
|
|
|
</div>
|
|
|
@@ -384,15 +388,15 @@ export default Vue.extend({
|
|
|
<el-button type="primary" @click="submitLogin()">登录</el-button>
|
|
|
<el-button type="text" @click="isLogin=false">没有账号?去注册。</el-button>
|
|
|
<div class="third-login">
|
|
|
- <div @click="openThirdLogin('wechat')" class="button wechat">
|
|
|
+ <div class="button wechat" @click="openThirdLogin('wechat')">
|
|
|
<img class="icon" src="/static/image/icon/wechat.png">
|
|
|
微信扫码登录
|
|
|
</div>
|
|
|
- <div @click="openThirdLogin('google')" class="button google">
|
|
|
+ <div class="button google" @click="openThirdLogin('google')">
|
|
|
<img class="icon" src="/static/image/icon/google.png">
|
|
|
谷歌授权登录
|
|
|
</div>
|
|
|
- <div @click="openThirdLogin('linkin')" class="button linkin">
|
|
|
+ <div class="button linkin" @click="openThirdLogin('linkin')">
|
|
|
<img class="icon" src="/static/image/icon/linkin.png">
|
|
|
领英授权登录
|
|
|
</div>
|
|
|
@@ -446,15 +450,15 @@ export default Vue.extend({
|
|
|
<el-button type="primary" @click="register()">注册</el-button>
|
|
|
<el-button type="text" @click="isLogin=true">已有账号?去登陆。</el-button>
|
|
|
<div class="third-login">
|
|
|
- <div @click="openThirdLogin('wechat')" class="button wechat">
|
|
|
+ <div class="button wechat" @click="openThirdLogin('wechat')">
|
|
|
<img class="icon" src="/static/image/icon/wechat.png">
|
|
|
微信扫码登录
|
|
|
</div>
|
|
|
- <div @click="openThirdLogin('google')" class="button google">
|
|
|
+ <div class="button google" @click="openThirdLogin('google')">
|
|
|
<img class="icon" src="/static/image/icon/google.png">
|
|
|
谷歌授权登录
|
|
|
</div>
|
|
|
- <div @click="openThirdLogin('linkin')" class="button linkin">
|
|
|
+ <div class="button linkin" @click="openThirdLogin('linkin')">
|
|
|
<img class="icon" src="/static/image/icon/linkin.png">
|
|
|
领英授权登录
|
|
|
</div>
|
|
|
@@ -495,7 +499,7 @@ export default Vue.extend({
|
|
|
</div>
|
|
|
</template>
|
|
|
<style scoped lang="scss">
|
|
|
-.body{
|
|
|
+.login-body{
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
overflow: hidden;
|
|
|
@@ -552,6 +556,10 @@ export default Vue.extend({
|
|
|
border-radius: 4px;
|
|
|
box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.05);
|
|
|
background: white;
|
|
|
+ @media (max-width:768px){
|
|
|
+ padding: 24px 20px;
|
|
|
+ margin: 24px 16px 0;
|
|
|
+ }
|
|
|
.third-login{
|
|
|
display: grid;
|
|
|
grid-gap: 16px;
|
|
|
@@ -590,6 +598,12 @@ export default Vue.extend({
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ @media (max-width:768px) {
|
|
|
+ grid-template-columns: 1fr 1fr;
|
|
|
+ .wechat{
|
|
|
+ display: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
.piracy{
|
|
|
color: #6B7280;
|
|
|
@@ -663,6 +677,10 @@ export default Vue.extend({
|
|
|
.head{
|
|
|
margin: 48px auto 0;
|
|
|
max-width: 800px;
|
|
|
+ text-align: center;
|
|
|
+ .logo{
|
|
|
+ width: 180px;
|
|
|
+ }
|
|
|
.title{
|
|
|
text-align: center;
|
|
|
font-size: 24px;
|