diff --git a/src/views/user/Login.vue b/src/views/user/Login.vue index 31df9ea..1403366 100644 --- a/src/views/user/Login.vue +++ b/src/views/user/Login.vue @@ -23,11 +23,11 @@ import { mapActions } from 'vuex' import { timeFix } from '@/utils/util' export default { - data () { + data() { return { form: { - username: 'admin', - password: 'daobang123' + username: '', + password: '' }, rules: { username: [{ required: true, message: '请输入用户名' }], @@ -38,7 +38,7 @@ export default { }, methods: { ...mapActions(['Login', 'Logout']), - handleSubmit () { + handleSubmit() { if (this.loading) { return false } @@ -57,7 +57,7 @@ export default { } }) }, - loginSuccess (res) { + loginSuccess(res) { this.loading = false this.$router.push({ path: '/' }) // 延迟 1 秒显示欢迎信息 @@ -68,7 +68,7 @@ export default { }) }, 1000) }, - requestFailed () { + requestFailed() { this.loading = false } }