This repository was archived by the owner on May 12, 2020. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22 <el-container class =" layout__material" >
33 <!-- Dynamic aside rendering area -->
44
5- <el-container >
5+ <el-container class = " layout__material__placeholder " >
66 <el-header >
77 <el-button
88 class =" logout"
99 type =" text"
1010 @click =" onLogout"
1111 >Logout</el-button >
1212 </el-header >
13- <router-view />
14- <el-footer >footer</el-footer >
13+ <router-view class =" layout__material__placeholder-main" />
14+ <el-footer class =" layout__material__footer" >
15+ Copyright © ; {{currentYear}}
16+ </el-footer >
1517 </el-container >
1618 </el-container >
1719</template >
@@ -21,14 +23,36 @@ export default {
2123 data () {
2224 return {}
2325 },
26+
2427 methods: {
2528 onLogout () {
2629 this .$store .dispatch (' login/userLogout' )
2730 .then (() => this .$router .replace (' /login' ))
2831 }
32+ },
33+
34+ computed: {
35+ currentYear () {
36+ return new Date ().getFullYear ()
37+ }
2938 }
3039}
3140 </script >
3241
3342<style lang='scss' scoped>
43+ .layout__material {
44+ & __placeholder {
45+ display : flex ;
46+ flex-direction : column ;
47+ min-height : 100vh ;
48+
49+ & -main {
50+ flex : 1 ;
51+ }
52+ }
53+
54+ & __footer {
55+ line-height : 60px ;
56+ }
57+ }
3458 </style >
Original file line number Diff line number Diff line change 11<template >
22 <div class =" home" >
3- < router-link to = " /login " >login page</ router-link >
3+ This is home page.
44 </div >
55</template >
66
You can’t perform that action at this time.
0 commit comments