feat: 增加部分页面

This commit is contained in:
caoqianming 2025-10-30 08:14:33 +08:00
parent 28d57c8c39
commit 1c90f6d571
7 changed files with 87 additions and 11 deletions

View File

@ -4,7 +4,7 @@
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" /> <link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>XT_WEB_TD</title> <title>双碳金融系统</title>
</head> </head>
<body> <body>
<div id="app"></div> <div id="app"></div>

View File

@ -1,8 +1,8 @@
<template> <template>
<div> <div>
<t-layout style="height: 100vh;width: 100vw;"> <t-layout style="height: 100vh;width: 100vw;">
<t-aside> <t-aside width="160px">
<t-menu theme="light" default-value="item1" style="margin-right: 40px" @change="handleMenuChange" v-model="activeMenu"> <t-menu theme="light" default-value="item1" @change="handleMenuChange" v-model="activeMenu" width="160px">
<template #logo> <template #logo>
<img height="28" src="https://tdesign.gtimg.com/site/baseLogo-light.png" alt="logo" /> <img height="28" src="https://tdesign.gtimg.com/site/baseLogo-light.png" alt="logo" />
</template> </template>
@ -20,8 +20,12 @@
</template> </template>
</t-head-menu> </t-head-menu>
</t-header> </t-header>
<t-content> <t-content style="padding: 4px">
<router-view /> <router-view v-slot="{ Component }">
<transition name="fade" mode="out-in">
<component :is="Component" />
</transition>
</router-view>
</t-content> </t-content>
</t-layout> </t-layout>
</t-layout> </t-layout>

7
src/pages/cal/dh.vue Normal file
View File

@ -0,0 +1,7 @@
<template>
<div>
<p>dh</p>
</div>
</template>
<script setup>
</script>

15
src/pages/cal/dq.vue Normal file
View File

@ -0,0 +1,15 @@
<template>
<t-layout style="height: 100%;">
<t-aside width="350px">
<t-form>
<t-input></t-input>
</t-form>
</t-aside>
<t-content>
<t-input></t-input>
</t-content>
</t-layout>
</template>
<script setup>
</script>

35
src/pages/cal/index.vue Normal file
View File

@ -0,0 +1,35 @@
<template>
<t-row>
<t-col :span="3">
<t-card hoverShadow class="bigNav" @click="goDq">
双碳贷前计算器
</t-card>
</t-col>
<t-col :span="3">
<t-card hoverShadow class="bigNav" @click="goDh">
双碳贷后计算器
</t-card>
</t-col>
</t-row>
</template>
<script setup>
import { useRouter, useRoute } from 'vue-router';
const router = useRouter();
const goDq = () => {
router.push('/dq')
}
const goDh = () => {
router.push('/dh')
}
</script>
<style scoped>
.bigNav {
font-size: 20px;
font-weight: 500;
color: darkblue;
height: 180px;
display: flex;
align-items: center;
justify-content: center;
}
</style>

View File

@ -2,7 +2,7 @@
<div class="login-wrapper"> <div class="login-wrapper">
<div class="login-container"> <div class="login-container">
<div class="title-container"> <div class="title-container">
<h1>XT_WEB_TD</h1> <h1>双碳金融系统</h1>
</div> </div>
<t-form class="item-container" label-width="0" @submit="handleLogin"> <t-form class="item-container" label-width="0" @submit="handleLogin">
<t-form-item> <t-form-item>

View File

@ -15,15 +15,30 @@ const routes = [
path: "", path: "",
name: "工作台", name: "工作台",
children: [ children: [
// {
// path: "home",
// name: "主页",
// component: () => import("@/pages/home/index.vue"),
// },
// {
// path: "user",
// name: "用户管理",
// component: () => import("@/pages/system/user.vue"),
// },
{ {
path: "home", path: "home",
name: "主页", name: "快捷导航",
component: () => import("@/pages/home/index.vue"), component: () => import("@/pages/cal/index.vue"),
}, },
{ {
path: "user", path: "dq",
name: "用户管理", name: "贷前计算",
component: () => import("@/pages/system/user.vue"), component: () => import("@/pages/cal/dq.vue"),
},
{
path: "dh",
name: "贷后计算",
component: () => import("@/pages/cal/dh.vue"),
}, },
], ],
}, },