登陆界面移除默认登陆用户名和密码

This commit is contained in:
qinjie 2021-09-08 17:44:54 +08:00
parent 9c25a47261
commit 078b82a541
1 changed files with 6 additions and 6 deletions

View File

@ -23,11 +23,11 @@ import { mapActions } from 'vuex'
import { timeFix } from '@/utils/util' import { timeFix } from '@/utils/util'
export default { export default {
data () { data() {
return { return {
form: { form: {
username: 'admin', username: '',
password: 'daobang123' password: ''
}, },
rules: { rules: {
username: [{ required: true, message: '请输入用户名' }], username: [{ required: true, message: '请输入用户名' }],
@ -38,7 +38,7 @@ export default {
}, },
methods: { methods: {
...mapActions(['Login', 'Logout']), ...mapActions(['Login', 'Logout']),
handleSubmit () { handleSubmit() {
if (this.loading) { if (this.loading) {
return false return false
} }
@ -57,7 +57,7 @@ export default {
} }
}) })
}, },
loginSuccess (res) { loginSuccess(res) {
this.loading = false this.loading = false
this.$router.push({ path: '/' }) this.$router.push({ path: '/' })
// 1 // 1
@ -68,7 +68,7 @@ export default {
}) })
}, 1000) }, 1000)
}, },
requestFailed () { requestFailed() {
this.loading = false this.loading = false
} }
} }