Browse Source

修改代码

plg 4 months ago
parent
commit
bd0269a2a7

+ 5 - 0
vue/src/router/index.js

@@ -22,6 +22,11 @@ const router = createRouter({
                     path: 'WangEditor',
                     component: () => import('../views/WangEditor.vue')
                 },
+                    //车辆方向检测
+                    {
+                        path: 'Home',
+                        component: () => import('../views/Home.vue')
+                    },
                 //车辆方向检测
                 {
                     path: 'Direction',

+ 1 - 1
vue/src/views/Category.vue

@@ -243,7 +243,7 @@ onMounted(() => {
 </template>
 <style scoped lang="less">
 .out {
-  height: 80vh;
+  min-height: 80vh;
   display: flex;
   flex-direction: column;
   /* background-color: #F0F3FA; */

+ 1 - 1
vue/src/views/Direction.vue

@@ -242,7 +242,7 @@ onMounted(() => {
 </template>
 <style scoped lang="less">
 .out {
-  height: 80vh;
+  min-height: 80vh;
   display: flex;
   flex-direction: column;
   /* background-color: #F0F3FA; */

+ 1 - 1
vue/src/views/DirectionAndCategory.vue

@@ -244,7 +244,7 @@ onMounted(() => {
 </template>
 <style scoped lang="less">
 .out {
-  height: 80vh;
+  min-height: 80vh;
   display: flex;
   flex-direction: column;
   /* background-color: #F0F3FA; */

+ 7 - 1
vue/src/views/HelloWorld.vue

@@ -33,7 +33,7 @@
         <el-container>
           <el-aside width="auto" height="100%">
             <el-menu
-              default-active="/TreeHoleManage"
+              default-active="/main/Home"
               class="el-menu-vertical-demo"
               :collapse="isCollapse"
               router
@@ -90,6 +90,12 @@
                 </el-icon>
                 <template #title>文件上传</template>
               </el-menu-item> -->
+              <el-menu-item index="/main/Home" v-if="type == '1'">
+                <el-icon>
+                  <document />
+                </el-icon>
+                <template #title>首页</template>
+              </el-menu-item>
               <el-menu-item index="/main/Direction" v-if="type == '1'">
                 <el-icon>
                   <document />

+ 16 - 0
vue/src/views/Home.vue

@@ -0,0 +1,16 @@
+<template>
+    <p>首页</p>
+   
+    <div class="out">
+        <img style="height:400px;width:600px" src="../assets/login/car.png" alt="">
+    </div>
+</template>
+<style scoped>
+ .out{
+    min-height: 70vh;
+    display: flex;
+    flex-direction: column;
+    align-items: center;
+    justify-content: center;
+ }
+</style>

+ 1 - 1
vue/src/views/user/login.vue

@@ -113,7 +113,7 @@ const onSubmit = () => {
         });
         setTimeout(() => {
           if (type.value == 1) {
-            router.push("/main/institutionManage");
+            router.push("/main/Direction");
           } else {
             router.push("/main/fileUpload");
           }