diff --git a/client/containers/Project/Interface/InterfaceCol/InterfaceColMenu.js b/client/containers/Project/Interface/InterfaceCol/InterfaceColMenu.js index 80716410..ca7dc3cf 100644 --- a/client/containers/Project/Interface/InterfaceCol/InterfaceColMenu.js +++ b/client/containers/Project/Interface/InterfaceCol/InterfaceColMenu.js @@ -73,7 +73,8 @@ export default class InterfaceColMenu extends Component { expandedKeys: [], colModalType: '', colModalVisible: false, - editColId: 0 + editColId: 0, + filterValue: '' } constructor(props) { @@ -187,9 +188,14 @@ export default class InterfaceColMenu extends Component { this.form = form; } + filterCol = (e) => { + const value = e.target.value; + this.setState({filterValue: value}) + } + render() { const { currColId, currCaseId, isShowCol } = this.props; - const { colModalType, colModalVisible } = this.state; + const { colModalType, colModalVisible, filterValue } = this.state; const menu = (col) => { return ( @@ -209,7 +215,7 @@ export default class InterfaceColMenu extends Component { return (
- + this.showColModal('add')} > @@ -223,7 +229,7 @@ export default class InterfaceColMenu extends Component { onExpand={this.onExpand} > { - this.props.interfaceColList.map((col) => ( + this.props.interfaceColList.filter(col => col.name.indexOf(filterValue) !== -1).map((col) => (