Browse Source

调整路由,添加login

liqk 6 years ago
parent
commit
93af48d2cc

BIN
TEAMModelOS.Admin/wwwroot/143146fa24554ae2c5ac0a3982abb952.woff2


+ 7 - 7
TEAMModelOS.SmartClass/ClientApp/components/smart-class/headers.vue

@@ -3,14 +3,14 @@
     <div class="header center-row">
     <div class="header center-row">
       <img src="http://ttkt.sxedu.org:70/upload/setting/0/0.png?_=1557194799800" />
       <img src="http://ttkt.sxedu.org:70/upload/setting/0/0.png?_=1557194799800" />
       <ul>
       <ul>
-        <li :class="this.$route.path ==  '/index' || activeIndex == 0 ? 'li-active':''" @click="handleMenuClick(0,'index')">首页</li>
-        <li :class="this.$route.path ==  '/notice' || activeIndex == 1? 'li-active':''" @click="handleMenuClick(1,'notice')">通知公告</li>
-        <li :class="this.$route.path ==  '/reviewActivity' || activeIndex == 2? 'li-active':''" @click="handleMenuClick(2,'reviewActivity')">评审活动</li> 
-        <li :class="this.$route.path ==  '/PastReview' || activeIndex == 3? 'li-active':''" @click="handleMenuClick(3,'PastReview')">往届回顾</li>
-        <li :class="this.$route.path ==  '/LiveBroadcast' || activeIndex == 4? 'li-active':''" @click="handleMenuClick(4,'LiveBroadcast')">天天直播</li>
-        <li :class="this.$route.path ==  '/Lessons' || activeIndex == 5? 'li-active':''" @click="handleMenuClick(5,'Lessons')">优课汇聚</li>
+        <li :class="this.$route.path ==  '/main/index' || activeIndex == 0 ? 'li-active':''" @click="handleMenuClick(0,'index')">首页</li>
+        <li :class="this.$route.path ==  '/main/notice' || activeIndex == 1? 'li-active':''" @click="handleMenuClick(1,'notice')">通知公告</li>
+        <li :class="this.$route.path ==  '/main/reviewActivity' || activeIndex == 2? 'li-active':''" @click="handleMenuClick(2,'reviewActivity')">评审活动</li> 
+        <li :class="this.$route.path ==  '/main/PastReview' || activeIndex == 3? 'li-active':''" @click="handleMenuClick(3,'PastReview')">往届回顾</li>
+        <li :class="this.$route.path ==  '/main/LiveBroadcast' || activeIndex == 4? 'li-active':''" @click="handleMenuClick(4,'LiveBroadcast')">天天直播</li>
+        <li :class="this.$route.path ==  '/main/Lessons' || activeIndex == 5? 'li-active':''" @click="handleMenuClick(5,'Lessons')">优课汇聚</li>
       </ul>
       </ul>
-      <span class="btn-login">登录</span>
+      <span class="btn-login"  @click="handleMenuClick(6,'login')">登录</span>
     </div>
     </div>
   </div>
   </div>
 </template>
 </template>

+ 9 - 4
TEAMModelOS.SmartClass/ClientApp/router/routes.js

@@ -2,12 +2,17 @@
 export const routes = [
 export const routes = [
   {
   {
     path: '/',
     path: '/',
-    redirect: '/index'
+    redirect: '/login'
   },
   },
   {
   {
-    name:'index',
+    name: 'login',
+    path: '/login',
+    component: resolve => require(['@/view/smart-class/LoginPage'], resolve), //路由懒加载
+  },
+  {
+    name: 'main',
     path: '',
     path: '',
-    component: resolve => require(['@/view/App'], resolve), //路由懒加载
+    component: resolve => require(['@/view/smart-class/MainPage'], resolve), //路由懒加载
     children: [
     children: [
       {
       {
         name: 'index',
         name: 'index',
@@ -58,7 +63,7 @@ export const routes = [
         name: 'lessons',
         name: 'lessons',
         path: '/lessons',
         path: '/lessons',
         component: resolve => require(['@/view/smart-class/Lessons'], resolve), //路由懒加载
         component: resolve => require(['@/view/smart-class/Lessons'], resolve), //路由懒加载
-      }
+      },
     ]
     ]
   }
   }
 ]
 ]

+ 3 - 3
TEAMModelOS.SmartClass/ClientApp/view/app.vue

@@ -1,13 +1,13 @@
 <template>
 <template>
   <div id="app">
   <div id="app">
     <div class="main-content">
     <div class="main-content">
-        <headers></headers>
+        <!--<headers></headers>-->
         <div class="content">
         <div class="content">
           <router-view />
           <router-view />
         </div>
         </div>
-        <div class="footer">
+        <!--<div class="footer">
           绍兴市柯桥区教师发展中心    广州市奥威亚电子科技有限公司技术支持&nbsp;浙ICP备05083914
           绍兴市柯桥区教师发展中心    广州市奥威亚电子科技有限公司技术支持&nbsp;浙ICP备05083914
-        </div>
+        </div>-->
     </div>
     </div>
   </div>
   </div>
 </template>
 </template>

+ 15 - 0
TEAMModelOS.SmartClass/ClientApp/view/smart-class/LoginPage.vue

@@ -0,0 +1,15 @@
+<template>
+  <div>login</div>
+</template>
+<script>
+  export default {
+    data() {
+      return {
+
+      }
+    }
+  }
+</script>
+<style>
+
+</style>

+ 67 - 0
TEAMModelOS.SmartClass/ClientApp/view/smart-class/MainPage.vue

@@ -0,0 +1,67 @@
+<template>
+  <div id="app">
+    <div class="main-content">
+      <headers></headers>
+      <div class="content">
+        <router-view />
+      </div>
+      <div class="footer">
+        绍兴市柯桥区教师发展中心    广州市奥威亚电子科技有限公司技术支持&nbsp;浙ICP备05083914
+      </div>
+    </div>
+  </div>
+</template>
+<script>
+  import headers from '@/components/smart-class/headers'
+  export default {
+    components: {
+      headers
+    },
+    data() {
+      return {
+      }
+    },
+    methods: {
+
+
+
+    },
+    mounted() {
+    }
+  }
+</script>
+<style scoped>
+  html, body, #app {
+    height: 100% !important;
+    user-select: none;
+  }
+
+  .main-content {
+    position: relative;
+    width: 100%;
+    min-width: 1200px;
+    min-height: 768px;
+    display: flex;
+    flex-direction: column;
+    align-items: center;
+    background: rgb(248,248,248);
+  }
+
+  .content {
+    width: 100%;
+  }
+
+  .logo {
+    width: 200px;
+    height: 200px;
+    margin-bottom: 50px;
+  }
+
+  .footer {
+    height: 60px;
+    text-align: center;
+    font-size: 12px;
+    color: #aaa;
+    line-height: 60px
+  }
+</style>