17c523ab by 杨威

表格高度自适应

1 parent 74e34e3e
......@@ -11,7 +11,7 @@
<span class="logo-text" v-show="!textLogo">不动产权籍调查系统</span>
</div>
<div class="treeModule">
<LineTree :pd="pd"></LineTree>
<LineTree :pd="pd" @itemClick="itemClick"></LineTree>
</div>
</el-aside>
<el-container>
......@@ -115,6 +115,7 @@ export default {
label: "宗地代码1933",
children: [
{
id:'011',
label: "自然幢号1256",
},
],
......@@ -255,6 +256,10 @@ export default {
// }
screenfull.toggle();
},
//树控件点击事件
itemClick(data){
console.log(data);
}
},
};
</script>
......
......@@ -34,13 +34,14 @@
</div>
</el-card>
</div>
<div class="notice">
<div class="notice" ref="notice">
<el-card>
<div slot="header" class="clearfix">
<span>通知公告</span>
</div>
<el-table
:data="tableData"
:height="tableHeight"
style="width: 100%"
:row-class-name="tableRowClassName"
>
......@@ -63,6 +64,10 @@
</el-table>
</el-card>
</div>
<div class="pagination">
<el-pagination background layout="prev, pager, next" :total="1000">
</el-pagination>
</div>
</div>
</template>
......@@ -102,6 +107,10 @@ export default {
title: "自然资源部四单位党组织开展联学联建活动",
},
{
date: "2016-05-04 08:23",
title: "珠江委部署珠江水利改革发展“十四五”规划思路报告编制工作",
},
{
date: "2016-05-03 08:23",
title: "全国海洋伏季休渔暨渤海综合治理专项执法行动启动",
},
......@@ -114,9 +123,21 @@ export default {
title:
"生态环境部审议并原则通过《地级及以上城市国家地表水考核断面水环境质量排名方案》",
},
{
date: "2016-05-03 08:23",
title: "自然资源部四单位党组织开展联学联建活动",
},
{
date: "2016-05-03 08:23",
title: "全国海洋伏季休渔暨渤海综合治理专项执法行动启动",
},
],
tableHeight:''
};
},
mounted(){
this.tableHeight = this.$refs.notice.offsetHeight- 53;
},
methods: {
handleSelect() {},
tableRowClassName({ row, rowIndex }) {
......@@ -133,6 +154,7 @@ export default {
.main {
display: flex;
flex-direction: column;
overflow: hidden;
height: 100%;
.panel {
@flex();
......@@ -148,6 +170,7 @@ export default {
.enter_box {
@flex();
div {
cursor: pointer;
flex: 1;
img {
width: 68px;
......@@ -167,8 +190,8 @@ export default {
}
}
.notice {
flex: 1;
padding: 0 18px 26px 18px;
flex: auto;
padding: 0 18px;
box-sizing: border-box;
.el-table .even-row {
background: #f7f9fb;
......@@ -183,5 +206,8 @@ export default {
text-align: center;
}
}
.pagination {
padding: 18px;
}
}
</style>
......