提交 bf036e78 authored 作者: lihuihui's avatar lihuihui

优化loading

上级 8237a0ee
...@@ -35,7 +35,7 @@ export default { ...@@ -35,7 +35,7 @@ export default {
} }
.img-certificate{ .img-certificate{
width: 632px; width: 632px;
margin: 66px auto; margin: 0 auto;
display: block; display: block;
} }
</style> </style>
...@@ -41,15 +41,23 @@ export default { ...@@ -41,15 +41,23 @@ export default {
}, },
tabStep() { tabStep() {
if (this.verification() === -1) { if (this.verification() === -1) {
const loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
})
this.isErrShow = false this.isErrShow = false
action.Certs.search(this.form).then(res => { action.Certs.search(this.form).then(res => {
if (res.data) { if (res.data) {
loading.close()
this.isErrShow = true this.isErrShow = true
} else { } else {
const data = { const data = {
ssoId: res.sso_id, ssoId: res.sso_id,
email: this.form.email email: this.form.email
} }
loading.close()
this.$emit('stepIndexs1', data) this.$emit('stepIndexs1', data)
} }
}) })
......
...@@ -33,12 +33,20 @@ export default { ...@@ -33,12 +33,20 @@ export default {
return false return false
} }
this.errShow = false this.errShow = false
const loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
})
action.Certs.getCert(param).then(res => { action.Certs.getCert(param).then(res => {
if (res.data) { if (res.data) {
if (res.data.status) { if (res.data.status) {
loading.close()
this.errShow = true this.errShow = true
} else { } else {
const certImg = res.data.length ? res.data[0].cert : '' const certImg = res.data.length ? res.data[0].cert : ''
loading.close()
this.$emit('stepIndexs2', certImg) this.$emit('stepIndexs2', certImg)
} }
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论