|
@@ -305,8 +305,8 @@ const HuiKuan = React.createClass({
|
|
|
str = "金额异常";
|
|
|
} else if (status.first == 4) {
|
|
|
str = "名称异常";
|
|
|
- }else {
|
|
|
- str = "未知异常"
|
|
|
+ } else if (status.first == 5) {
|
|
|
+ str = "已收款";
|
|
|
}
|
|
|
}
|
|
|
return (
|
|
@@ -441,8 +441,15 @@ const HuiKuan = React.createClass({
|
|
|
// console.log(this.state.modalData);
|
|
|
}
|
|
|
})
|
|
|
-
|
|
|
-
|
|
|
+ },
|
|
|
+ tableRowClick(record) {
|
|
|
+ this.setState({
|
|
|
+ visible: true,
|
|
|
+ choose: true
|
|
|
+ });
|
|
|
+ this.setState({
|
|
|
+ modalData: JSON.parse(JSON.stringify(record))
|
|
|
+ });
|
|
|
},
|
|
|
|
|
|
handleOk() {
|
|
@@ -470,6 +477,7 @@ const HuiKuan = React.createClass({
|
|
|
message.warning(data.error[0].message);
|
|
|
} else {
|
|
|
// console.log("成功", data);
|
|
|
+ message.success("添加成功!")
|
|
|
this.loadData();
|
|
|
this.state.selectedRowKeys = [];
|
|
|
this.setState({
|
|
@@ -508,6 +516,7 @@ const HuiKuan = React.createClass({
|
|
|
message.warning(data.error[0].message);
|
|
|
}else {
|
|
|
// console.log("成功",data);
|
|
|
+ message.success("修改成功!")
|
|
|
this.loadData()
|
|
|
this.state.selectedRowKeys = [];
|
|
|
this.setState({
|
|
@@ -529,7 +538,7 @@ const HuiKuan = React.createClass({
|
|
|
},
|
|
|
|
|
|
handleCancel() {
|
|
|
- this.loadData()
|
|
|
+ // this.loadData()
|
|
|
this.setState({ visible: false });
|
|
|
},
|
|
|
callback(key) {
|
|
@@ -551,6 +560,7 @@ const HuiKuan = React.createClass({
|
|
|
if (data.error && data.error.length) {
|
|
|
message.warning(data.error[0].message);
|
|
|
}
|
|
|
+ message.success("删除成功!")
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
function() {
|
|
@@ -578,6 +588,7 @@ const HuiKuan = React.createClass({
|
|
|
if (data.error && data.error.length) {
|
|
|
message.warning(data.error[0].message);
|
|
|
}
|
|
|
+ message.success("删除全部成功!")
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
function() {
|
|
@@ -666,7 +677,7 @@ const HuiKuan = React.createClass({
|
|
|
<span style={{ fontWeight: 900, fontSize: 16 }}>批量回款</span>
|
|
|
</div>
|
|
|
|
|
|
- <Tabs defaultActiveKey="1" onChange={this.callback}>
|
|
|
+ <Tabs defaultActiveKey="1" onChange={this.callback} className="test">
|
|
|
<TabPane tab="搜索" key="1">
|
|
|
<div className="user-search" style={{ marginLeft: 10 }}>
|
|
|
<Input
|
|
@@ -766,6 +777,7 @@ const HuiKuan = React.createClass({
|
|
|
changeFn={this.changeList}
|
|
|
changeList={this.state.changeList}
|
|
|
top={55}
|
|
|
+ margin={11}
|
|
|
display={"inline-block"}
|
|
|
style={{ marginBottom: 17 }}
|
|
|
/>
|
|
@@ -800,7 +812,7 @@ const HuiKuan = React.createClass({
|
|
|
|
|
|
<Button
|
|
|
type="primary"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 25 }}
|
|
|
onClick={this.download}
|
|
|
>
|
|
|
下载回款列表模板
|
|
@@ -816,7 +828,7 @@ const HuiKuan = React.createClass({
|
|
|
|
|
|
<Button
|
|
|
type="primary"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
disabled={this.state.selectedRowKeys.length == 1 ? false : true}
|
|
|
onClick={this.showModal}
|
|
|
>
|
|
@@ -825,7 +837,7 @@ const HuiKuan = React.createClass({
|
|
|
|
|
|
<Button
|
|
|
type="primary"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
onClick={this.addModal}
|
|
|
>
|
|
|
添加单条数据
|
|
@@ -841,7 +853,7 @@ const HuiKuan = React.createClass({
|
|
|
<Button
|
|
|
primary
|
|
|
type="danger"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
disabled={this.state.selectedRowKeys.length > 0 ? false : true}
|
|
|
>
|
|
|
删除选中项
|
|
@@ -857,7 +869,7 @@ const HuiKuan = React.createClass({
|
|
|
>
|
|
|
<Button
|
|
|
type="danger"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
disabled={this.state.dataSource.length == 0}
|
|
|
>
|
|
|
删除全部
|
|
@@ -865,17 +877,29 @@ const HuiKuan = React.createClass({
|
|
|
</Popconfirm>
|
|
|
<Button
|
|
|
type="danger"
|
|
|
- style={{ marginBottom: 20, marginLeft: 15 }}
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
disabled={this.state.dataSource.length == 0}
|
|
|
onClick={e => {
|
|
|
this.loadData(1, 100);
|
|
|
this.setState({
|
|
|
- mergeModal: true,
|
|
|
+ mergeModal: true
|
|
|
});
|
|
|
}}
|
|
|
>
|
|
|
确认合并回款
|
|
|
</Button>
|
|
|
+ <Button
|
|
|
+ type="danger"
|
|
|
+ style={{ marginBottom: 11, marginLeft: 15 }}
|
|
|
+ disabled={this.state.dataSource.length == 0}
|
|
|
+ onClick={e => {
|
|
|
+ this.setState({
|
|
|
+ selectedRowKeys: []
|
|
|
+ });
|
|
|
+ }}
|
|
|
+ >
|
|
|
+ 重置选项
|
|
|
+ </Button>
|
|
|
</TabPane>
|
|
|
</Tabs>
|
|
|
|
|
@@ -891,6 +915,7 @@ const HuiKuan = React.createClass({
|
|
|
dataSource={this.state.dataSource}
|
|
|
pagination={this.state.pagination}
|
|
|
rowSelection={rowSelection}
|
|
|
+ onRowDoubleClick={this.tableRowClick.bind(this)}
|
|
|
bordered
|
|
|
size="small"
|
|
|
/>
|
|
@@ -1015,7 +1040,7 @@ const HuiKuan = React.createClass({
|
|
|
display: this.state.choose ? "block" : "none"
|
|
|
}}
|
|
|
>
|
|
|
- 合同额(万元):
|
|
|
+ 合同额(万元):
|
|
|
<Input
|
|
|
style={{
|
|
|
width: "auto",
|
|
@@ -1031,7 +1056,7 @@ const HuiKuan = React.createClass({
|
|
|
/>
|
|
|
</p>
|
|
|
<p style={{ marginBottom: 10 }}>
|
|
|
- 本次回款(万元):
|
|
|
+ 本次回款(万元):
|
|
|
<Input
|
|
|
style={{ width: "auto" }}
|
|
|
value={this.state.modalData.amount}
|
|
@@ -1104,7 +1129,7 @@ const HuiKuan = React.createClass({
|
|
|
onOk={this.mergeAll}
|
|
|
onCancel={() => {
|
|
|
this.setState({
|
|
|
- mergeModal: false,
|
|
|
+ mergeModal: false
|
|
|
});
|
|
|
}}
|
|
|
>
|