review code.

This commit is contained in:
lijiahang
2023-08-03 14:21:27 +08:00
parent 598e33b0b5
commit d86b301628
22 changed files with 83 additions and 47 deletions

View File

@@ -1,5 +1,5 @@
<template>
<div class="container">
<div class="layout-container">
<div class="left-side">
<div class="panel">
<Banner />
@@ -61,12 +61,6 @@
</script>
<style lang="less" scoped>
.container {
background-color: var(--color-fill-2);
padding: 16px 20px;
padding-bottom: 0;
display: flex;
}
.left-side {
flex: 1;
@@ -140,7 +134,7 @@
<style lang="less" scoped>
// responsive
.mobile {
.container {
.layout-container {
display: block;
}

View File

@@ -57,7 +57,7 @@
import { useI18n } from 'vue-i18n';
import { useUserStore } from '@/store';
import useLoading from '@/hooks/loading';
import type { LoginData } from '@/api/user';
import type { LoginRequest } from '@/api/user/auth';
const router = useRouter();
const { t } = useI18n();
@@ -82,7 +82,7 @@
setLoading(true);
try {
// 执行登陆
await userStore.login(values as LoginData);
await userStore.login(values as LoginRequest);
// 跳转路由
const { redirect, ...othersQuery } = router.currentRoute.value.query;
router.push({