/* * Author: 黎永顺 * name: 工资单发放重构-工资单模板查询 * Description: * Date: 2023/10/12 */ import React, { Component } from "react"; import { WeaInputSearch, WeaLocaleProvider, WeaSelect } from "ecCom"; import { getPayrollTemplateLedgerList } from "../../../../apis/payroll"; const getLabel = WeaLocaleProvider.getLabel; class TemplateQuery extends Component { constructor(props) { super(props); this.state = { salarySobOptions: [] }; } componentDidMount() { this.getPayrollTemplateLedgerList(); } getPayrollTemplateLedgerList = () => { getPayrollTemplateLedgerList().then(({ status, data }) => { if (status) { this.setState({ salarySobOptions: _.map(data, o => ({ key: o.id, showname: o.content })) }); } }); }; render() { const { salarySobOptions } = this.state; const { queryParams } = this.props; const { salarySobId, name } = queryParams; return (
this.props.onChange({ salarySobId: v })}/> this.props.onChange({ name: v })} onSearch={this.props.onSearch} />
); } } export default TemplateQuery;