1、引入Ruoyi-Vue-Plus版本的彩色控制台日志。

2、移除界面导航时的out-in fade-transform淡入效果。
3、添加非主框架内的独立路由用于测试。
This commit is contained in:
jlt
2022-04-02 22:45:41 +08:00
parent 7ede419ff1
commit 6ff5109ae3
6 changed files with 133 additions and 62 deletions

View File

@ -1,57 +1,55 @@
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<keep-alive :include="cachedViews">
<router-view :key="key" />
</keep-alive>
</transition>
</section>
</template>
<script>
export default {
name: 'AppMain',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<section class="app-main">
<keep-alive :include="cachedViews">
<router-view :key="key" />
</keep-alive>
</section>
</template>
<script>
export default {
name: 'AppMain',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>

View File

@ -51,6 +51,11 @@ export const constantRoutes = [
component: () => import('@/views/register'),
hidden: true
},
{
path: '/test',
component: () => import('@/views/test'),
hidden: true
},
{
path: '/404',
component: () => import('@/views/error/404'),

View File

@ -0,0 +1,46 @@
<template>
<div class="register">
<!-- 底部 -->
<div class="el-register-footer">
<span>Copyright © 2018-2022 私家农场 版权所有.</span>
</div>
</div>
</template>
<script>
export default {
name: "Test",
data() {
return {
codeUrl: ""
};
},
created() {
this.getCode();
},
methods: {
getCode() {
},
}
};
</script>
<style rel="stylesheet/scss" lang="scss">
.register {
height: 100%;
background-color: #1f2d3d;
}
.el-register-footer {
height: 40px;
line-height: 40px;
position: fixed;
bottom: 0;
width: 100%;
text-align: center;
color: #fff;
font-family: Arial;
font-size: 12px;
letter-spacing: 1px;
}
</style>