Ver a proveniência

登录

master
朱文强 há 2 anos
ascendente
cometimento
9e8e58419b
1 ficheiros alterados com 10 adições e 6 eliminações
  1. +10
    -6
      src/views/common/login.vue

+ 10
- 6
src/views/common/login.vue Ver ficheiro

@@ -3,7 +3,7 @@
<div class="site-content__wrapper">
<div class="site-content">
<div class="brand-info">
<h2 class="brand-info__text">奔一智能仓库</h2>
<h2 class="brand-info__text">智能立体仓库</h2>
<p class="brand-info__intro"></p>
</div>
<div class="login-main">
@@ -54,6 +54,7 @@ export default {
password: 'admin',
uuid: ''
},
loading: '',
dataRule: {
userName: [
{ required: true, message: '帐号不能为空', trigger: 'blur' }
@@ -63,7 +64,13 @@ export default {
}
},
created () {
// this.dataFormSubmit()
this.dataFormSubmit()
this.loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
})
},
methods: {
// 提交表单
@@ -79,6 +86,7 @@ export default {
}).then(({ data }) => {
if (data && data.code === 0) {
this.$cookie.set('token', data.token)
this.loading.close()
this.$router.replace({ name: 'home' })
} else {
this.$message.error(data.msg)
@@ -96,7 +104,6 @@ export default {
right: 0;
bottom: 0;
left: 0;
background-color: rgba(38, 50, 56, 0.3);
overflow: hidden;
&:before {
position: fixed;
@@ -106,8 +113,6 @@ export default {
width: 80%;
height: 100%;
content: "";
background-image: url(~@/assets/img/loginbg.png);
background-size: cover;
}
.site-content__wrapper {
position: absolute;
@@ -127,7 +132,6 @@ export default {
}
.brand-info {
margin: 220px 100px 0 90px;
color: #fff;
}
.brand-info__text {
margin: 0 0 22px 30%;


Carregando…
Cancelar
Guardar