MyHome.vue 880 字节
Newer Older
1
<template>
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
	<div class="home-container">
		<el-row>
			<el-col :span="24">
				<!-- 头部区域 -->
				<MyHeader></MyHeader>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="3">
				<!-- 左侧边栏 -->
				<MyAside></MyAside>
			</el-col>
			<el-col :span="21">
				<!-- 主体区域 -->
				<router-view></router-view>
			</el-col>
		</el-row>
	</div>
20 21 22 23
</template>

<script>
// 头部区域组件
24
import MyHeader from './subcomponents/MyHeader.vue'
25
// 左侧边栏组件
26
import MyAside from './subcomponents/MyAside.vue'
27
export default {
28 29 30 31 32 33 34
    name: 'MyHome',
    // 注册组件
    components: {
        MyHeader,
        MyAside,
    },
}
35 36 37 38
</script>

<style lang="less" scoped>
.home-container {
39 40 41
	height: 100%;
	display: flex;
	flex-direction: column;
42

43 44 45 46 47 48 49 50
	.home-main-box {
		height: 100%;
		display: flex;
		.home-main-body {
			padding: 15px;
			flex: 1;
		}
	}
51
}
52
</style>