2024-08-28 13:42:32 +08:00
|
|
|
/*
|
|
|
|
|
* 薪酬二开项目
|
|
|
|
|
* 领悦
|
|
|
|
|
* @Author: 黎永顺
|
|
|
|
|
* @Date: 2024/8/22
|
|
|
|
|
* @Wechat:
|
|
|
|
|
* @Email: 971387674@qq.com
|
|
|
|
|
* @description:
|
|
|
|
|
*/
|
|
|
|
|
import React, { Component } from "react";
|
2024-08-30 14:22:23 +08:00
|
|
|
import { inject, observer } from "mobx-react";
|
2024-08-28 13:42:32 +08:00
|
|
|
import { WeaDatePicker, WeaInputSearch, WeaLocaleProvider, WeaTop } from "ecCom";
|
|
|
|
|
import { Button } from "antd";
|
|
|
|
|
import "./index.less";
|
|
|
|
|
|
|
|
|
|
const getLabel = WeaLocaleProvider.getLabel;
|
|
|
|
|
|
2024-08-30 14:22:23 +08:00
|
|
|
@inject("taxAgentStore")
|
|
|
|
|
@observer
|
2024-08-28 13:42:32 +08:00
|
|
|
class Layout extends Component {
|
|
|
|
|
render() {
|
2024-08-30 14:22:23 +08:00
|
|
|
const { title, query, onChange, listRef, isQuery, taxAgentStore: { salaryManager } } = this.props;
|
2024-08-28 16:25:15 +08:00
|
|
|
const { salaryMonth, ffgsqc } = query;
|
2024-08-30 14:22:23 +08:00
|
|
|
let buttons = [
|
2024-08-28 16:25:15 +08:00
|
|
|
<Button type="primary" onClick={() => listRef.handleOperate("GENERATE")}>{getLabel(111, "生成数据")}</Button>,
|
|
|
|
|
<Button type="ghost" onClick={() => listRef.handleOperate("BATCHDEL")}>{getLabel(111, "批量删除")}</Button>,
|
2024-08-28 13:42:32 +08:00
|
|
|
<WeaDatePicker format="YYYY-MM" value={salaryMonth}
|
|
|
|
|
onChange={value => onChange({ ...query, salaryMonth: value, isQuery: !isQuery })}/>,
|
|
|
|
|
<WeaInputSearch value={ffgsqc} onChange={value => onChange({ ...query, ffgsqc: value })}
|
|
|
|
|
onSearch={() => onChange({ ...query, isQuery: !isQuery })}/>
|
|
|
|
|
];
|
|
|
|
|
const dropMenuDatas = [
|
|
|
|
|
{ key: "EXPORTALL", icon: <i className="iconfont icon-daochu"/>, content: getLabel(81272, "导出全部") }
|
|
|
|
|
];
|
2024-08-30 14:22:23 +08:00
|
|
|
!salaryManager && (buttons = buttons.slice(2));
|
2024-08-28 13:42:32 +08:00
|
|
|
return (
|
|
|
|
|
<WeaTop
|
2024-08-30 14:22:23 +08:00
|
|
|
title={title} icon={<i className="icon-coms-fa"/>} buttons={buttons} showDropIcon={salaryManager}
|
2024-08-28 13:42:32 +08:00
|
|
|
iconBgcolor="#F14A2D" className="custom_salary_lingyue" dropMenuDatas={dropMenuDatas}
|
2024-08-28 14:46:00 +08:00
|
|
|
onDropMenuClick={key => listRef.handleOperate(key)}>
|
2024-08-28 13:42:32 +08:00
|
|
|
<div className="lingyue-body">{this.props.children}</div>
|
|
|
|
|
</WeaTop>);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default Layout;
|