salary-management-front/pc4mobx/hrmSalary/components/customTab/index.js

38 lines
1.1 KiB
JavaScript

import React from 'react';
import { WeaTab } from 'ecCom';
import "./index.less";
export default class CustomTab extends React.Component {
constructor(props) {
super(props);
this.state = {
selectedKey: ""
}
}
render() {
return (<div className="tabWrapper">
<div className="weaTab">
{
this.props.topTab && <WeaTab
datas={this.props.topTab}
keyParam="viewcondition" //主键
selectedKey={this.state.selectedKey}
onChange={(v) => {
this.setState({selectedKey: v})
this.props.onChange(v);
}}
/>
}
{
this.props.leftOperation && this.props.leftOperation
}
</div>
<div className="tabSearchWrapper">
{
this.props.searchOperationItem
}
</div>
</div>)
}
}