Merge branch 'master' of gitee.com:youlaitech/vue3-element-admin

This commit is contained in:
有来技术
2021-12-26 12:57:09 +08:00
19 changed files with 288 additions and 355 deletions

View File

@@ -72,7 +72,7 @@
<script>
import SvgIcon from '@/components/SvgIcon/index.vue';
import {getCaptcha} from "@/api/login";
import { useUserStoreHook } from "@/store/modules/user";
export default {
name: 'Login',
components:{
@@ -130,7 +130,7 @@ export default {
this.$refs.loginForm.validate(valid => {
if (valid) {
this.loading = true
this.$store.dispatch('user/login', this.loginForm).then(() => {
useUserStoreHook().login(this.loginForm).then(() => {
this.$router.push({ path: this.redirect || '/' })
this.loading = false
}).catch(() => {