Commit fa19f97c authored by 沈翠玲's avatar 沈翠玲

排班日历增加筛选

parent 811efd0b
...@@ -2,6 +2,10 @@ ...@@ -2,6 +2,10 @@
<div class="app-container"> <div class="app-container">
<el-container class="el-container-cal"> <el-container class="el-container-cal">
<el-aside width="200px" class="el-aside-cal"> <el-aside width="200px" class="el-aside-cal">
<el-input
placeholder="请输入车间名称"
v-model="filterText">
</el-input>
<el-tree :data="teamList" :props="defaultProps" :expand-on-click-node="false" class="el-tree-pro" highlight-current node-key="id" <el-tree :data="teamList" :props="defaultProps" :expand-on-click-node="false" class="el-tree-pro" highlight-current node-key="id"
:filter-node-method="filterNode" ref="tree" :default-expanded-keys="defaultExpandedKeys" @node-click="onSelected" > :filter-node-method="filterNode" ref="tree" :default-expanded-keys="defaultExpandedKeys" @node-click="onSelected" >
<span slot-scope="{ data }" :title="data.label" <span slot-scope="{ data }" :title="data.label"
...@@ -64,6 +68,7 @@ export default { ...@@ -64,6 +68,7 @@ export default {
label: "label", label: "label",
}, },
selectRow: {}, selectRow: {},
filterText: null,
date: new Date(), date: new Date(),
teamList: [], //所有的班组 teamList: [], //所有的班组
holidayList:[],//假日 holidayList:[],//假日
...@@ -90,6 +95,9 @@ export default { ...@@ -90,6 +95,9 @@ export default {
} }
this.getList(type); this.getList(type);
} }
},
filterText (val) {
this.$refs.tree.filter(val)
} }
}, },
created() { created() {
...@@ -205,6 +213,11 @@ export default { ...@@ -205,6 +213,11 @@ export default {
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
.el-aside-cal .el-tree {
max-height: calc(700px - 46px);
overflow: auto;
padding-top: 10px;
}
.grid-content{ .grid-content{
padding: 5px 0; padding: 5px 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment