员工福利档案页面添加编辑抽屉页面样式重构,以及修改页面参数回调的bug
This commit is contained in:
parent
ae3af8e59e
commit
e243085a0d
|
|
@ -1,121 +1,129 @@
|
|||
import React from 'react'
|
||||
import { Modal, Row, Col, Select, message, Button } from 'antd'
|
||||
import RequiredLabelTip from '../../components/requiredLabelTip'
|
||||
import { inject, observer } from 'mobx-react';
|
||||
import { WeaDatePicker, WeaInput } from 'ecCom'
|
||||
import { notNull } from '../../util/validate';
|
||||
import React from "react";
|
||||
import { Button, Col, message, Modal, Row, Select } from "antd";
|
||||
import RequiredLabelTip from "../../components/requiredLabelTip";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaDatePicker, WeaInput } from "ecCom";
|
||||
import { notNull } from "../../util/validate";
|
||||
import "./index.less";
|
||||
|
||||
|
||||
const { Option } = Select;
|
||||
|
||||
@inject('calculateStore')
|
||||
@inject("calculateStore")
|
||||
@observer
|
||||
export default class baseFormModal extends React.Component {
|
||||
constructor(props) {
|
||||
super(props)
|
||||
this.state = {
|
||||
salaryMonthStr: "",
|
||||
inited: false,
|
||||
selectOptions: [],
|
||||
salarySob: '',
|
||||
description: ""
|
||||
}
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
salaryMonthStr: "",
|
||||
inited: false,
|
||||
selectOptions: [],
|
||||
salarySob: "",
|
||||
description: ""
|
||||
};
|
||||
}
|
||||
|
||||
componentWillMount() {
|
||||
const { calculateStore } = this.props;
|
||||
const { salaryacctGetForm } = calculateStore;
|
||||
salaryacctGetForm().then(data => {
|
||||
this.setState({
|
||||
inited: true,
|
||||
selectOptions: data.salarySobs
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
handleSelectChange(value) {
|
||||
this.setState({
|
||||
salarySob: value
|
||||
});
|
||||
}
|
||||
|
||||
// 保存回调
|
||||
handleSave() {
|
||||
if (!this.validate()) {
|
||||
return;
|
||||
}
|
||||
|
||||
componentWillMount() {
|
||||
const { calculateStore } = this.props;
|
||||
const { salaryacctGetForm } = calculateStore
|
||||
salaryacctGetForm().then(data => {
|
||||
this.setState({
|
||||
inited: true,
|
||||
selectOptions: data.salarySobs
|
||||
})
|
||||
})
|
||||
let params = {
|
||||
salaryMonthStr: this.state.salaryMonthStr,
|
||||
salarySobId: this.state.salarySob,
|
||||
description: this.state.description
|
||||
};
|
||||
const { calculateStore: { saveBasic } } = this.props;
|
||||
|
||||
saveBasic(params).then((id) => {
|
||||
this.props.onCancel();
|
||||
this.props.onRefresh();
|
||||
window.open("/spa/hrmSalary/static/index.html#/main/hrmSalary/calculateDetail?id=" + id);
|
||||
});
|
||||
}
|
||||
|
||||
validate() {
|
||||
if (!notNull(this.state.salaryMonthStr)) {
|
||||
message.warning("薪酬所属月不能为空");
|
||||
return false;
|
||||
} else if (!notNull(this.state.salarySob)) {
|
||||
message.warning("核算账套不能为空");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
handleSelectChange(value) {
|
||||
this.setState({
|
||||
salarySob: value
|
||||
})
|
||||
}
|
||||
render() {
|
||||
const { salaryMonthStr, salarySobId, description } = this.state;
|
||||
return (
|
||||
<Modal
|
||||
title="核算"
|
||||
wrapClassName="dataList-wrapper"
|
||||
visible={this.props.visible}
|
||||
width={600}
|
||||
onCancel={() => {
|
||||
this.props.onCancel();
|
||||
}}
|
||||
footer={<Button type="primary" onClick={() => {
|
||||
this.handleSave();
|
||||
}}>保存</Button>}
|
||||
>
|
||||
<Row style={{ lineHeight: "40px" }}>
|
||||
<Col span={8}>薪酬所属月<RequiredLabelTip/></Col>
|
||||
<Col span={16}>
|
||||
<WeaDatePicker
|
||||
style={{ width: "100%" }}
|
||||
format="yyyy-MM"
|
||||
value={this.state.salaryMonthStr}
|
||||
onChange={value => {
|
||||
this.setState({
|
||||
salaryMonthStr: value
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
// 保存回调
|
||||
handleSave() {
|
||||
if(!this.validate()) {
|
||||
return
|
||||
}
|
||||
<Row style={{ lineHeight: "40px" }} className="formItem">
|
||||
<Col span={8}>核算账套<RequiredLabelTip/></Col>
|
||||
<Col span={16}>
|
||||
{
|
||||
this.state.inited && <Select
|
||||
defaultValue={this.state.salarySob} value={this.state.salarySob} style={{ width: "100%" }}
|
||||
onChange={(value) => this.handleSelectChange(value)}>
|
||||
{this.state.selectOptions.map(item => (
|
||||
<Option value={item.id} key={item.id}>{item.name}</Option>
|
||||
))}
|
||||
</Select>
|
||||
}
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
let params = {
|
||||
salaryMonthStr: this.state.salaryMonthStr,
|
||||
salarySobId: this.state.salarySob,
|
||||
description: this.state.description
|
||||
}
|
||||
const { calculateStore: { saveBasic }} = this.props;
|
||||
|
||||
saveBasic(params).then((id) => {
|
||||
this.props.onCancel()
|
||||
this.props.onRefresh()
|
||||
window.open("/spa/hrmSalary/static/index.html#/main/hrmSalary/calculateDetail?id=" + id)
|
||||
})
|
||||
}
|
||||
|
||||
validate() {
|
||||
if(!notNull(this.state.salaryMonthStr)) {
|
||||
message.warning("薪酬所属月不能为空")
|
||||
return false;
|
||||
} else if(!notNull(this.state.salarySob)) {
|
||||
message.warning("核算账套不能为空")
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
render() {
|
||||
const { salaryMonthStr, salarySobId, description } = this.state;
|
||||
return (
|
||||
<Modal title="核算" visible={this.props.visible} width={600} onCancel={() => {
|
||||
this.props.onCancel()
|
||||
}}
|
||||
footer={<Button type="primary" onClick={() => {
|
||||
this.handleSave()
|
||||
}}>保存</Button>}
|
||||
>
|
||||
<Row style={{lineHeight: '40px'}}>
|
||||
<Col span={8}>薪酬所属月<RequiredLabelTip /></Col>
|
||||
<Col span={16}>
|
||||
<WeaDatePicker
|
||||
style={{width: "100%"}}
|
||||
format="yyyy-MM"
|
||||
value={this.state.salaryMonthStr}
|
||||
onChange={value => {
|
||||
this.setState({
|
||||
salaryMonthStr: value
|
||||
})
|
||||
}}
|
||||
/>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
<Row style={{lineHeight: "40px"}}>
|
||||
<Col span={8}>核算账套<RequiredLabelTip /></Col>
|
||||
<Col span={16}>
|
||||
{
|
||||
this.state.inited && <Select
|
||||
defaultValue={this.state.salarySob} value={this.state.salarySob} style={{ width: "100%" }} onChange={(value) => this.handleSelectChange(value)}>
|
||||
{this.state.selectOptions.map(item => (
|
||||
<Option value={item.id} key={item.id}>{item.name}</Option>
|
||||
))}
|
||||
</Select>
|
||||
}
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
<Row style={{lineHeight: '40px'}}>
|
||||
<Col span={8}>备注</Col>
|
||||
<Col span={16}>
|
||||
<WeaInput value={description} onChange={(value) => this.setState({description: value})}/>
|
||||
</Col>
|
||||
</Row>
|
||||
</Modal>
|
||||
)
|
||||
}
|
||||
}
|
||||
<Row style={{ lineHeight: "40px" }}>
|
||||
<Col span={8}>备注</Col>
|
||||
<Col span={16}>
|
||||
<WeaInput value={description} onChange={(value) => this.setState({ description: value })}/>
|
||||
</Col>
|
||||
</Row>
|
||||
</Modal>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,8 @@
|
|||
.dataList-wrapper {
|
||||
.formItem {
|
||||
.ant-select-selection {
|
||||
height: 30px;
|
||||
border-radius: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,174 +1,181 @@
|
|||
import React from 'react'
|
||||
import CustomTab from '../../components/customTab'
|
||||
import { Dropdown, Menu, Button, Table, message } from 'antd'
|
||||
import { WeaHelpfulTip, WeaInputSearch, WeaSlideModal, WeaTable } from 'ecCom'
|
||||
import { placeOnFileColumns, dataSource } from './columns'
|
||||
import SlideModalTitle from "../../components/slideModalTitle"
|
||||
import FileMergeDetail from './fileMergeDetail'
|
||||
import React from "react";
|
||||
import CustomTab from "../../components/customTab";
|
||||
import { Dropdown, Menu, message } from "antd";
|
||||
import { WeaHelpfulTip, WeaInputSearch, WeaSlideModal } from "ecCom";
|
||||
import { placeOnFileColumns } from "./columns";
|
||||
import SlideModalTitle from "../../components/slideModalTitle";
|
||||
import FileMergeDetail from "./fileMergeDetail";
|
||||
import { getQueryString } from "../../util/url";
|
||||
import { inject, observer } from 'mobx-react';
|
||||
import CustomPaginationTable from '../../components/customPaginationTable'
|
||||
import { inject, observer } from "mobx-react";
|
||||
import CustomPaginationTable from "../../components/customPaginationTable";
|
||||
|
||||
@inject('calculateStore')
|
||||
@inject("calculateStore")
|
||||
@observer
|
||||
export default class PlaceOnFileDetail extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
placeOnFileColumns.map(item => {
|
||||
if(item.dataIndex == "username") {
|
||||
item.render = (text, record) => (
|
||||
<a onClick={() => {
|
||||
this.onDetail()
|
||||
}}>{text}</a>
|
||||
)
|
||||
}
|
||||
})
|
||||
this.state = {
|
||||
slideVisiable: false,
|
||||
selectedRowKeys: [],
|
||||
searchValue: ""
|
||||
}
|
||||
this.id = "";
|
||||
this.length = 0
|
||||
this.pageInfo = {
|
||||
current: 1,
|
||||
pageSize: 10
|
||||
}
|
||||
}
|
||||
|
||||
componentWillMount() {
|
||||
let id = getQueryString("id");
|
||||
this.id = id;
|
||||
const { calculateStore: { getSalarySobCycle, acctResultList } } = this.props;
|
||||
getSalarySobCycle(id)
|
||||
acctResultList(id)
|
||||
}
|
||||
|
||||
|
||||
// 获取列表的列
|
||||
getColumns() {
|
||||
const { calculateStore: {acctResultListTableStore, acctResultListColumns }} = this.props;
|
||||
let columns = acctResultListColumns ? acctResultListColumns : []
|
||||
columns = columns.filter(item => item.hide == "FALSE").map(item => {
|
||||
let result = {...item}
|
||||
result.title = item.text;
|
||||
result.dataIndex = item.column
|
||||
result.oldWidth = result.width;
|
||||
result.width = null;
|
||||
this.length = 0
|
||||
if(result.children) {
|
||||
result.children.map(child => {
|
||||
child.width = 150
|
||||
child.title = child.text
|
||||
child.dataIndex = child.column
|
||||
this.length ++
|
||||
})
|
||||
} else {
|
||||
this.length ++
|
||||
result.width = 150
|
||||
}
|
||||
return result;
|
||||
})
|
||||
columns.push({
|
||||
title: '操作',
|
||||
key: "cz",
|
||||
render: (text, record) => {
|
||||
return <a onClick={() => {
|
||||
this.handleEdit(record)
|
||||
}}>编辑</a>
|
||||
}
|
||||
})
|
||||
return columns;
|
||||
}
|
||||
|
||||
onDetail() {
|
||||
this.setState({slideVisiable: true})
|
||||
}
|
||||
|
||||
handleSearch(value){
|
||||
const { calculateStore: {acctResultList}} = this.props;
|
||||
acctResultList(this.id, value, 1, this.pageInfo)
|
||||
}
|
||||
|
||||
// 分页
|
||||
handleDataPageChange(value) {
|
||||
const { calculateStore: {acctResultList}} = this.props;
|
||||
acctResultList(this.id, this.state.searchValue, value, this.pageInfo)
|
||||
}
|
||||
|
||||
handleShowSizeChange(pageInfo) {
|
||||
const { calculateStore: {acctResultList}} = this.props;
|
||||
acctResultList(this.id, this.state.searchValue, pageInfo.current, pageInfo )
|
||||
}
|
||||
|
||||
handleMenuClick() {
|
||||
const {calculateStore: {exportAll}} = this.props;
|
||||
const { selectedRowKeys } = this.state;
|
||||
if(selectedRowKeys.length == 0) {
|
||||
message.warning("未选择条目")
|
||||
return
|
||||
}
|
||||
exportAll(this.id, selectedRowKeys.join(","))
|
||||
}
|
||||
|
||||
handleExportAll() {
|
||||
const {calculateStore: {exportAll}} = this.props;
|
||||
exportAll(this.id)
|
||||
}
|
||||
|
||||
onSelectChange = selectedRowKeys => {
|
||||
this.setState({ selectedRowKeys });
|
||||
}
|
||||
|
||||
|
||||
|
||||
render() {
|
||||
|
||||
const { calculateStore } = this.props;
|
||||
const { baseSalarySobCycle, acctResultListDateSource, acctResultListColumns, acctResultListPageInfo } = calculateStore
|
||||
const { selectedRowKeys } = this.state;
|
||||
|
||||
const rowSelection = {
|
||||
selectedRowKeys,
|
||||
onChange: this.onSelectChange,
|
||||
};
|
||||
|
||||
const menu = (
|
||||
<Menu onClick={(e) => this.handleMenuClick(e)}>
|
||||
<Menu.Item key="3">导出所选</Menu.Item>
|
||||
</Menu>
|
||||
constructor(props) {
|
||||
super(props);
|
||||
placeOnFileColumns.map(item => {
|
||||
if (item.dataIndex == "username") {
|
||||
item.render = (text, record) => (
|
||||
<a onClick={() => {
|
||||
this.onDetail();
|
||||
}}>{text}</a>
|
||||
);
|
||||
}
|
||||
});
|
||||
this.state = {
|
||||
slideVisiable: false,
|
||||
selectedRowKeys: [],
|
||||
searchValue: ""
|
||||
};
|
||||
this.id = "";
|
||||
this.length = 0;
|
||||
this.pageInfo = {
|
||||
current: 1,
|
||||
pageSize: 10
|
||||
};
|
||||
}
|
||||
|
||||
const renderRightOperation = () => {
|
||||
return (
|
||||
<div style={{display: "inline-block"}}>
|
||||
<Dropdown.Button type="primary" style={{marginRight: "10px"}} onClick={() => {
|
||||
this.handleExportAll()
|
||||
}} overlay={menu}>导出全部</Dropdown.Button>
|
||||
<WeaInputSearch onChange={(value) => {
|
||||
this.setState({searchValue: value})
|
||||
}} value={this.state.searchValue} onSearch={(value) => {
|
||||
this.handleSearch(value)
|
||||
}}/>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
componentWillMount() {
|
||||
let id = getQueryString("id");
|
||||
this.id = id;
|
||||
const { calculateStore: { getSalarySobCycle, acctResultList } } = this.props;
|
||||
getSalarySobCycle(id);
|
||||
acctResultList({ salaryAcctRecordId: id });
|
||||
}
|
||||
|
||||
const { slideVisiable } = this.state
|
||||
|
||||
return (
|
||||
|
||||
<div className="placeOnFileDetail">
|
||||
<CustomTab
|
||||
searchOperationItem={
|
||||
renderRightOperation()
|
||||
}
|
||||
/>
|
||||
<div className="tabWrapper">
|
||||
<span>薪资所属月:{baseSalarySobCycle.salaryMonth}</span>
|
||||
<WeaHelpfulTip
|
||||
width={100}
|
||||
title={`薪资周期\n
|
||||
|
||||
// 获取列表的列
|
||||
getColumns() {
|
||||
const { calculateStore: { acctResultListTableStore, acctResultListColumns } } = this.props;
|
||||
let columns = acctResultListColumns ? acctResultListColumns : [];
|
||||
columns = columns.filter(item => item.hide == "FALSE").map(item => {
|
||||
let result = { ...item };
|
||||
result.title = item.text;
|
||||
result.dataIndex = item.column;
|
||||
result.oldWidth = result.width;
|
||||
result.width = null;
|
||||
this.length = 0;
|
||||
if (result.children) {
|
||||
result.children.map(child => {
|
||||
child.width = 150;
|
||||
child.title = child.text;
|
||||
child.dataIndex = child.column;
|
||||
this.length++;
|
||||
});
|
||||
} else {
|
||||
this.length++;
|
||||
result.width = 150;
|
||||
}
|
||||
return result;
|
||||
});
|
||||
columns.push({
|
||||
title: "操作",
|
||||
key: "cz",
|
||||
render: (text, record) => {
|
||||
return <a onClick={() => {
|
||||
this.handleEdit(record);
|
||||
}}>编辑</a>;
|
||||
}
|
||||
});
|
||||
return columns;
|
||||
}
|
||||
|
||||
onDetail() {
|
||||
this.setState({ slideVisiable: true });
|
||||
}
|
||||
|
||||
handleSearch(employeeName) {
|
||||
const { calculateStore: { acctResultList } } = this.props;
|
||||
acctResultList({ salaryAcctRecordId: this.id, employeeName, ...this.pageInfo, current: 1 });
|
||||
}
|
||||
|
||||
// 分页
|
||||
handleDataPageChange(current) {
|
||||
const { calculateStore: { acctResultList } } = this.props;
|
||||
acctResultList({ salaryAcctRecordId: this.id, employeeName: this.state.searchValue, ...this.pageInfo, current });
|
||||
}
|
||||
|
||||
handleShowSizeChange(pageInfo) {
|
||||
const { calculateStore: { acctResultList } } = this.props;
|
||||
acctResultList({
|
||||
salaryAcctRecordId: this.id,
|
||||
employeeName: this.state.searchValue, ...this.pageInfo, ...pageInfo
|
||||
});
|
||||
}
|
||||
|
||||
handleMenuClick() {
|
||||
const { calculateStore: { exportAll } } = this.props;
|
||||
const { selectedRowKeys } = this.state;
|
||||
if (selectedRowKeys.length == 0) {
|
||||
message.warning("未选择条目");
|
||||
return;
|
||||
}
|
||||
exportAll(this.id, selectedRowKeys.join(","));
|
||||
}
|
||||
|
||||
handleExportAll() {
|
||||
const { calculateStore: { exportAll } } = this.props;
|
||||
exportAll(this.id);
|
||||
}
|
||||
|
||||
onSelectChange = selectedRowKeys => {
|
||||
this.setState({ selectedRowKeys });
|
||||
};
|
||||
|
||||
|
||||
render() {
|
||||
|
||||
const { calculateStore } = this.props;
|
||||
const {
|
||||
baseSalarySobCycle,
|
||||
acctResultListDateSource,
|
||||
acctResultListColumns,
|
||||
acctResultListPageInfo
|
||||
} = calculateStore;
|
||||
const { selectedRowKeys } = this.state;
|
||||
|
||||
const rowSelection = {
|
||||
selectedRowKeys,
|
||||
onChange: this.onSelectChange
|
||||
};
|
||||
|
||||
const menu = (
|
||||
<Menu onClick={(e) => this.handleMenuClick(e)}>
|
||||
<Menu.Item key="3">导出所选</Menu.Item>
|
||||
</Menu>
|
||||
);
|
||||
|
||||
const renderRightOperation = () => {
|
||||
return (
|
||||
<div style={{ display: "inline-block" }}>
|
||||
<Dropdown.Button type="primary" style={{ marginRight: "10px" }} onClick={() => {
|
||||
this.handleExportAll();
|
||||
}} overlay={menu}>导出全部</Dropdown.Button>
|
||||
<WeaInputSearch placeholder="请输入姓名" onChange={(value) => {
|
||||
this.setState({ searchValue: value });
|
||||
}} value={this.state.searchValue} onSearch={(value) => {
|
||||
this.handleSearch(value);
|
||||
}}/>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
const { slideVisiable } = this.state;
|
||||
|
||||
return (
|
||||
|
||||
<div className="placeOnFileDetail">
|
||||
<CustomTab
|
||||
searchOperationItem={
|
||||
renderRightOperation()
|
||||
}
|
||||
/>
|
||||
<div className="tabWrapper">
|
||||
<span>薪资所属月:{baseSalarySobCycle.salaryMonth}</span>
|
||||
<WeaHelpfulTip
|
||||
width={100}
|
||||
title={`薪资周期\n
|
||||
${baseSalarySobCycle.salaryCycle && baseSalarySobCycle.salaryCycle.fromDate}至${baseSalarySobCycle.salaryCycle && baseSalarySobCycle.salaryCycle.endDate}\n
|
||||
税款所属期\n
|
||||
${baseSalarySobCycle.taxCycle}\n
|
||||
|
|
@ -176,48 +183,48 @@ this.handleSearch(value)
|
|||
${baseSalarySobCycle.attendCycle && baseSalarySobCycle.attendCycle.fromDate}至${baseSalarySobCycle.attendCycle && baseSalarySobCycle.attendCycle.endDate}\n
|
||||
福利台账月份\n
|
||||
引用${baseSalarySobCycle.socialSecurityCycle}的福利台账数据`}
|
||||
placement="topLeft"
|
||||
/>
|
||||
</div>
|
||||
<div className="tableWrapper">
|
||||
<CustomPaginationTable
|
||||
columns={this.getColumns()}
|
||||
scroll={{x: this.length * 150}}
|
||||
dataSource={acctResultListDateSource}
|
||||
rowSelection={rowSelection}
|
||||
total={acctResultListPageInfo.total}
|
||||
current={acctResultListPageInfo.pageNum}
|
||||
pageSize={this.pageInfo.pageSize}
|
||||
onPageChange={(value) => {
|
||||
this.pageInfo.current = value
|
||||
this.handleDataPageChange(value)
|
||||
}}
|
||||
onShowSizeChange={(current, pageSize) => {
|
||||
this.pageInfo = {current, pageSize}
|
||||
this.handleShowSizeChange(this.pageInfo)
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
placement="topLeft"
|
||||
/>
|
||||
</div>
|
||||
<div className="tableWrapper">
|
||||
<CustomPaginationTable
|
||||
columns={this.getColumns()}
|
||||
scroll={{ x: this.length * 150 }}
|
||||
dataSource={acctResultListDateSource}
|
||||
rowSelection={rowSelection}
|
||||
total={acctResultListPageInfo.total}
|
||||
current={acctResultListPageInfo.pageNum}
|
||||
pageSize={this.pageInfo.pageSize}
|
||||
onPageChange={(value) => {
|
||||
this.pageInfo.current = value;
|
||||
this.handleDataPageChange(value);
|
||||
}}
|
||||
onShowSizeChange={(current, pageSize) => {
|
||||
this.pageInfo = { current, pageSize };
|
||||
this.handleShowSizeChange(this.pageInfo);
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
|
||||
{
|
||||
slideVisiable && <WeaSlideModal visible={slideVisiable}
|
||||
top={0}
|
||||
width={40}
|
||||
height={100}
|
||||
direction={'right'}
|
||||
measure={'%'}
|
||||
title={
|
||||
<SlideModalTitle
|
||||
subtitle={"合并计税详情"}
|
||||
editable={true}
|
||||
/>
|
||||
}
|
||||
content={(<FileMergeDetail />)}
|
||||
onClose={() => this.setState({slideVisiable: false})}
|
||||
showMask={true}
|
||||
closeMaskOnClick={() => this.setState({slideVisiable: false})} />
|
||||
}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
}
|
||||
{
|
||||
slideVisiable && <WeaSlideModal visible={slideVisiable}
|
||||
top={0}
|
||||
width={40}
|
||||
height={100}
|
||||
direction={"right"}
|
||||
measure={"%"}
|
||||
title={
|
||||
<SlideModalTitle
|
||||
subtitle={"合并计税详情"}
|
||||
editable={true}
|
||||
/>
|
||||
}
|
||||
content={(<FileMergeDetail/>)}
|
||||
onClose={() => this.setState({ slideVisiable: false })}
|
||||
showMask={true}
|
||||
closeMaskOnClick={() => this.setState({ slideVisiable: false })}/>
|
||||
}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from "react";
|
||||
import { Button, Col, Icon, Modal, Row } from "antd";
|
||||
import { WeaFormItem, WeaInput, WeaSelect, WeaTextarea } from "ecCom";
|
||||
import { WeaFormItem, WeaInput, WeaSelect, WeaTextarea, WeaHelpfulTip } from "ecCom";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import "./index.less";
|
||||
|
||||
|
|
@ -224,6 +224,7 @@ export default class FormalFormModal extends React.Component {
|
|||
this.handleSave();
|
||||
}}>保存</Button>
|
||||
}
|
||||
wrapClassName="formula-wrapper"
|
||||
onCancel={() => {
|
||||
this.props.onCancel();
|
||||
}}>
|
||||
|
|
@ -254,6 +255,11 @@ export default class FormalFormModal extends React.Component {
|
|||
this.setState({ extendParam: {...extendParam, datasource:{datasourceId}} });
|
||||
}}
|
||||
/>
|
||||
<WeaHelpfulTip
|
||||
width = {196}
|
||||
title="不设置,默认使用系统数据源"
|
||||
isCenter={true}
|
||||
/>
|
||||
</WeaFormItem>
|
||||
</Col>
|
||||
</Row>
|
||||
|
|
|
|||
|
|
@ -6,14 +6,27 @@
|
|||
}
|
||||
}
|
||||
|
||||
.formula-wrapper{
|
||||
.ant-modal-body{
|
||||
min-height: 200px;
|
||||
max-height: 50vh;
|
||||
overflow: auto;
|
||||
}
|
||||
}
|
||||
|
||||
.dataList-wrapper {
|
||||
.wea-select {
|
||||
width: 100%;
|
||||
.ant-select{
|
||||
.wea-form-item-wrapper{
|
||||
display: flex!important;
|
||||
align-items: center;
|
||||
.wea-select {
|
||||
width: 100%;
|
||||
.ant-select-selection{
|
||||
border-radius: 0;
|
||||
height: 30px;
|
||||
margin-right: 8px;
|
||||
.ant-select{
|
||||
width: 100%;
|
||||
.ant-select-selection{
|
||||
border-radius: 0;
|
||||
height: 30px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,70 +1,74 @@
|
|||
import React from 'react'
|
||||
import { systemItemColumns, dataSource } from './columns'
|
||||
import { WeaInputSearch } from 'ecCom'
|
||||
import { Modal, Button, Table } from 'antd'
|
||||
import { inject, observer } from 'mobx-react';
|
||||
import { WeaTableNew } from "comsMobx"
|
||||
import React from "react";
|
||||
import { WeaInputSearch } from "ecCom";
|
||||
import { Button, Modal } from "antd";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { WeaTableNew } from "comsMobx";
|
||||
import "./index.less";
|
||||
|
||||
const WeaTable = WeaTableNew.WeaTable;
|
||||
|
||||
@inject('salaryItemStore')
|
||||
@inject("salaryItemStore")
|
||||
@observer
|
||||
export default class SystemSalaryItemModal extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
searchValue: ""
|
||||
}
|
||||
}
|
||||
|
||||
// 搜索改变事件
|
||||
handleSearchChange(value) {
|
||||
this.setState({searchValue: value})
|
||||
}
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
searchValue: ""
|
||||
};
|
||||
}
|
||||
|
||||
// 搜索
|
||||
handleSearch(value) {
|
||||
const { salaryItemStore } = this.props;
|
||||
const { getSysItemList } = salaryItemStore
|
||||
getSysItemList({name: value})
|
||||
}
|
||||
// 搜索改变事件
|
||||
handleSearchChange(value) {
|
||||
this.setState({ searchValue: value });
|
||||
}
|
||||
|
||||
render() {
|
||||
const { salaryItemStore } = this.props;
|
||||
const { sysListTableStore } = salaryItemStore
|
||||
const { searchValue } = this.state;
|
||||
|
||||
const handleAdd = () => {
|
||||
const { salaryItemStore: { saveSysItem } } = this.props;
|
||||
saveSysItem();
|
||||
}
|
||||
|
||||
return (
|
||||
<Modal footer={null} visible={this.props.visible} onCancel={() => {
|
||||
this.props.onCancel()
|
||||
}} width={800}>
|
||||
<div style={{height: "47px", lineHeight: '47px'}}>
|
||||
<span style={{marginLeft: "10px", fontSize: '14px'}}>添加系统薪资项目</span>
|
||||
<div style={{float: "right", marginRight: "40px"}}>
|
||||
<Button type="primary" style={{marginRight: '10px'}} onClick={() => {
|
||||
handleAdd()
|
||||
}}>添加</Button>
|
||||
<WeaInputSearch value={searchValue} onChange={(value) => {
|
||||
this.handleSearchChange(value)
|
||||
}} onSearch={(value) => {
|
||||
this.handleSearch(value)
|
||||
}}/>
|
||||
</div>
|
||||
</div>
|
||||
<div style={{margin: "10px", height: "500px", overflowY: "scroll"}}>
|
||||
<WeaTable // table内部做了loading加载处理,页面就不需要再加了
|
||||
comsWeaTableStore={sysListTableStore} // table store
|
||||
hasOrder={true} // 是否启用排序
|
||||
needScroll={true} // 是否启用table内部列表滚动,将自适应到父级高度
|
||||
// getColumns={this.getColumns}
|
||||
// onOperatesClick={this.onOperatesClick.bind(this)}
|
||||
/>
|
||||
</div>
|
||||
</Modal>
|
||||
)
|
||||
}
|
||||
}
|
||||
// 搜索
|
||||
handleSearch(value) {
|
||||
const { salaryItemStore } = this.props;
|
||||
const { getSysItemList } = salaryItemStore;
|
||||
getSysItemList({ name: value });
|
||||
}
|
||||
|
||||
render() {
|
||||
const { salaryItemStore } = this.props;
|
||||
const { sysListTableStore } = salaryItemStore;
|
||||
const { searchValue } = this.state;
|
||||
|
||||
const handleAdd = () => {
|
||||
const { salaryItemStore: { saveSysItem } } = this.props;
|
||||
saveSysItem();
|
||||
};
|
||||
|
||||
return (
|
||||
<Modal
|
||||
footer={null}
|
||||
wrapClassName="formula-wrapper"
|
||||
visible={this.props.visible}
|
||||
onCancel={() => {
|
||||
this.props.onCancel();
|
||||
}} width={800}
|
||||
>
|
||||
<div style={{ height: "47px", lineHeight: "47px" }}>
|
||||
<span style={{ marginLeft: "10px", fontSize: "14px" }}>添加系统薪资项目</span>
|
||||
<div style={{ float: "right", marginRight: "40px" }}>
|
||||
<Button type="primary" style={{ marginRight: "10px" }} onClick={() => {
|
||||
handleAdd();
|
||||
}}>添加</Button>
|
||||
<WeaInputSearch value={searchValue} onChange={(value) => {
|
||||
this.handleSearchChange(value);
|
||||
}} onSearch={(value) => {
|
||||
this.handleSearch(value);
|
||||
}}/>
|
||||
</div>
|
||||
</div>
|
||||
<WeaTable // table内部做了loading加载处理,页面就不需要再加了
|
||||
comsWeaTableStore={sysListTableStore} // table store
|
||||
hasOrder={true} // 是否启用排序
|
||||
needScroll={true} // 是否启用table内部列表滚动,将自适应到父级高度
|
||||
// getColumns={this.getColumns}
|
||||
// onOperatesClick={this.onOperatesClick.bind(this)}
|
||||
/>
|
||||
</Modal>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,12 +1,8 @@
|
|||
import React from "react";
|
||||
import { inject, observer } from "mobx-react";
|
||||
import { toJS } from "mobx";
|
||||
|
||||
import { Button, DatePicker, Dropdown, Menu, message } from "antd";
|
||||
|
||||
import { Button, Dropdown, Menu, message } from "antd";
|
||||
import { WeaRightMenu, WeaSlideModal, WeaTab, WeaTop } from "ecCom";
|
||||
// import { WeaTableNew } from "comsMobx"
|
||||
// const WeaTable = WeaTableNew.WeaTable;
|
||||
import { getSearchs, renderNoright } from "../../../util"; // 渲染form数据的方法:因为多个页面都会使用,所以抽的公共方法在util中
|
||||
import BaseForm from "./baseForm";
|
||||
import SlideModalTitle from "../../../components/slideModalTitle";
|
||||
|
|
@ -16,8 +12,6 @@ import OtherForm from "./otherForm";
|
|||
import CustomPaginationTable from "../../../components/customPaginationTable";
|
||||
import ImportModal from "../../../components/importModal";
|
||||
|
||||
const { MonthPicker } = DatePicker;
|
||||
|
||||
@inject("archivesStore", "taxAgentStore")
|
||||
@observer
|
||||
export default class Archives extends React.Component {
|
||||
|
|
|
|||
|
|
@ -9,6 +9,10 @@
|
|||
padding-right: 10px;
|
||||
border: 1px solid #e2e2e2;
|
||||
margin-bottom: 0 !important;
|
||||
.ant-select-selection{
|
||||
height: 30px;
|
||||
border-radius: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.borderR-none {
|
||||
|
|
|
|||
|
|
@ -111,8 +111,7 @@ export default class SocialSecurityForm extends React.Component {
|
|||
</Col>
|
||||
</Row>
|
||||
<Row>
|
||||
<Col span={6} className="formItem borderR-none">缴纳组织:</Col>
|
||||
|
||||
<Col span={6} className="formItem borderR-none">个税扣缴义务人:</Col>
|
||||
<Col span={6} className="formItem borderR-none">
|
||||
<Select defaultValue={data && data.paymentOrganization} value={data && data.paymentOrganization}
|
||||
style={{ width: "100%" }}
|
||||
|
|
|
|||
Loading…
Reference in New Issue