|
@@ -19,6 +19,7 @@ import {
|
|
|
Popconfirm
|
|
|
} from "antd";
|
|
|
import OrderDesc from "../orderDetail/orderDesc";
|
|
|
+import ResolutionDetail from "@/resolutionDetail";
|
|
|
import Receivable from "./receivable";
|
|
|
import Assign from "@/manageCenter/publicComponent/assign";
|
|
|
import ReactToPrint from "react-to-print";
|
|
@@ -51,7 +52,7 @@ const ShouKuang = React.createClass({
|
|
|
crossDomain: false,
|
|
|
url: globalConfig.context + "/api/admin/organization/selectSuperId",
|
|
|
data: {},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let thedata = data.data;
|
|
|
let theArr = [];
|
|
|
if (!thedata) {
|
|
@@ -59,7 +60,7 @@ const ShouKuang = React.createClass({
|
|
|
message.warning(data.error[0].message);
|
|
|
}
|
|
|
} else {
|
|
|
- thedata.map(function (item, index) {
|
|
|
+ thedata.map(function(item, index) {
|
|
|
theArr.push({
|
|
|
key: index,
|
|
|
name: item.name,
|
|
@@ -72,7 +73,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
// this.setState({
|
|
|
// loading: false
|
|
|
// });
|
|
@@ -109,12 +110,11 @@ const ShouKuang = React.createClass({
|
|
|
liquidationStatus: this.state.liquidationStatus,
|
|
|
amountStatus: this.state.amountStatus
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
if (!data.data || !data.data.pagination.list) {
|
|
|
if (data.error && data.error.length) {
|
|
|
message.warning(data.error[0].message);
|
|
|
-
|
|
|
}
|
|
|
} else {
|
|
|
for (let i = 0; i < data.data.pagination.list.length; i++) {
|
|
@@ -164,10 +164,9 @@ const ShouKuang = React.createClass({
|
|
|
totalHui: data.data.count ? data.data.count.signTotalAmount : 0,
|
|
|
hui: data.data.count ? data.data.count.actuallyTotalAmount : 0
|
|
|
});
|
|
|
-
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
// window.setTimeout(() => {
|
|
|
this.setState({
|
|
|
loadingA: false
|
|
@@ -201,15 +200,15 @@ const ShouKuang = React.createClass({
|
|
|
defaultPageSize: 10,
|
|
|
showQuickJumper: true,
|
|
|
pageSize: 10,
|
|
|
- onChange: function (page) {
|
|
|
- console.log(page);
|
|
|
+ onChange: function(page) {
|
|
|
+ // console.log(page);
|
|
|
|
|
|
this.setState({
|
|
|
pageNo: page
|
|
|
- })
|
|
|
+ });
|
|
|
this.loadData(page);
|
|
|
}.bind(this),
|
|
|
- showTotal: function (total) {
|
|
|
+ showTotal: function(total) {
|
|
|
return "共" + total + "条数据";
|
|
|
}
|
|
|
},
|
|
@@ -267,7 +266,27 @@ const ShouKuang = React.createClass({
|
|
|
{
|
|
|
title: "项目数量",
|
|
|
dataIndex: "commodityQuantity",
|
|
|
- key: "commodityQuantity"
|
|
|
+ key: "commodityQuantity",
|
|
|
+ render: (text, record) => {
|
|
|
+ if (record.splitStatus == 1) {
|
|
|
+ return (
|
|
|
+ <span>
|
|
|
+ {text}{" "}
|
|
|
+ <Tag
|
|
|
+ color="#108ee9"
|
|
|
+ onClick={e => {
|
|
|
+ e.stopPropagation();
|
|
|
+ this.showRes(record);
|
|
|
+ }}
|
|
|
+ >
|
|
|
+ 已拆
|
|
|
+ </Tag>
|
|
|
+ </span>
|
|
|
+ );
|
|
|
+ } else {
|
|
|
+ return text;
|
|
|
+ }
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
title: "服务市价",
|
|
@@ -298,9 +317,9 @@ const ShouKuang = React.createClass({
|
|
|
key: "outsource",
|
|
|
render: text => {
|
|
|
if (text == 0) {
|
|
|
- return "否"
|
|
|
+ return "否";
|
|
|
} else if (text == 1) {
|
|
|
- return "是"
|
|
|
+ return "是";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
@@ -416,6 +435,18 @@ const ShouKuang = React.createClass({
|
|
|
dataIndex: "orderNo",
|
|
|
key: "orderNo"
|
|
|
},
|
|
|
+ {
|
|
|
+ title: "项目编号",
|
|
|
+ dataIndex: "id",
|
|
|
+ key: "id",
|
|
|
+ render: (text, record) => {
|
|
|
+ if (record.splitStatus == 2) {
|
|
|
+ return <span>{record.splitSuper + "-" + record.splitId}</span>;
|
|
|
+ } else {
|
|
|
+ return text;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
|
|
|
{
|
|
|
title: "客户名称",
|
|
@@ -441,11 +472,7 @@ const ShouKuang = React.createClass({
|
|
|
dataIndex: "cname",
|
|
|
key: "cname"
|
|
|
},
|
|
|
- {
|
|
|
- title: "项目编号",
|
|
|
- dataIndex: "id",
|
|
|
- key: "id"
|
|
|
- },
|
|
|
+
|
|
|
{
|
|
|
title: "项目名称",
|
|
|
dataIndex: "taskName",
|
|
@@ -493,9 +520,9 @@ const ShouKuang = React.createClass({
|
|
|
key: "outsource",
|
|
|
render: text => {
|
|
|
if (text == 0) {
|
|
|
- return "否"
|
|
|
+ return "否";
|
|
|
} else if (text == 1) {
|
|
|
- return "是"
|
|
|
+ return "是";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
@@ -613,14 +640,14 @@ const ShouKuang = React.createClass({
|
|
|
dataIndex: "contractNo",
|
|
|
key: "contractNo",
|
|
|
className: "title-table",
|
|
|
- fixed: 'left',
|
|
|
+ fixed: "left"
|
|
|
},
|
|
|
{
|
|
|
title: "客户名称",
|
|
|
dataIndex: "buyerName",
|
|
|
key: "buyerName",
|
|
|
className: "title-table",
|
|
|
- fixed: 'left',
|
|
|
+ fixed: "left"
|
|
|
},
|
|
|
{
|
|
|
title: "订单编号",
|
|
@@ -756,7 +783,7 @@ const ShouKuang = React.createClass({
|
|
|
收款
|
|
|
</Button>
|
|
|
)} */}
|
|
|
- {recard.backStatus == 3 ? (<Tag>已驳回</Tag>) : ("")}
|
|
|
+ {recard.backStatus == 3 ? <Tag>已驳回</Tag> : ""}
|
|
|
{recard.processStatus == 3 ? (
|
|
|
<Button
|
|
|
type="primary"
|
|
@@ -769,22 +796,26 @@ const ShouKuang = React.createClass({
|
|
|
通过
|
|
|
</Button>
|
|
|
) : (
|
|
|
- ""
|
|
|
- )}
|
|
|
+ ""
|
|
|
+ )}
|
|
|
{!(
|
|
|
recard.actuallyTotalAmount &&
|
|
|
Number(recard.actuallyTotalAmount) > 0
|
|
|
) && (
|
|
|
- <Button
|
|
|
- type="danger"
|
|
|
- style={{ marginLeft: "5px", display: recard.processStatus == 3 ? "inline-block" : "none" }}
|
|
|
- onClick={e => {
|
|
|
- e.stopPropagation(), this.reject(recard);
|
|
|
- }}
|
|
|
- >
|
|
|
- 驳回
|
|
|
- </Button>
|
|
|
- )}
|
|
|
+ <Button
|
|
|
+ type="danger"
|
|
|
+ style={{
|
|
|
+ marginLeft: "5px",
|
|
|
+ display:
|
|
|
+ recard.processStatus == 3 ? "inline-block" : "none"
|
|
|
+ }}
|
|
|
+ onClick={e => {
|
|
|
+ e.stopPropagation(), this.reject(recard);
|
|
|
+ }}
|
|
|
+ >
|
|
|
+ 驳回
|
|
|
+ </Button>
|
|
|
+ )}
|
|
|
{
|
|
|
// <Button
|
|
|
// type="primary"
|
|
@@ -924,15 +955,11 @@ const ShouKuang = React.createClass({
|
|
|
okText="删除"
|
|
|
cancelText="不删除"
|
|
|
>
|
|
|
- <Button>
|
|
|
- 删除
|
|
|
- </Button>
|
|
|
+ <Button>删除</Button>
|
|
|
</Popconfirm>
|
|
|
- )
|
|
|
+ );
|
|
|
} else {
|
|
|
- return (
|
|
|
- <Tag>已删除</Tag>
|
|
|
- )
|
|
|
+ return <Tag>已删除</Tag>;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -953,18 +980,18 @@ const ShouKuang = React.createClass({
|
|
|
data: {
|
|
|
billNo
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
if (data.error && data.error.length) {
|
|
|
message.warning(data.error[0].message);
|
|
|
} else {
|
|
|
- message.warning("删除流水成功!")
|
|
|
- this.waterData()
|
|
|
- this.loadData()
|
|
|
+ message.warning("删除流水成功!");
|
|
|
+ this.waterData();
|
|
|
+ this.loadData();
|
|
|
}
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -982,7 +1009,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: record.orderNo
|
|
|
}
|
|
|
}).done(
|
|
|
- function (data) {
|
|
|
+ function(data) {
|
|
|
if (!data.error.length) {
|
|
|
message.success("通过成功!");
|
|
|
this.setState({
|
|
@@ -1069,6 +1096,20 @@ const ShouKuang = React.createClass({
|
|
|
search() {
|
|
|
this.loadData();
|
|
|
},
|
|
|
+
|
|
|
+ // 拆分详细
|
|
|
+ showRes(record) {
|
|
|
+ this.setState({
|
|
|
+ resVisible: true,
|
|
|
+ resRecord: record
|
|
|
+ });
|
|
|
+ },
|
|
|
+ resCancel() {
|
|
|
+ this.setState({
|
|
|
+ resVisible: false
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
reset() {
|
|
|
this.state.nameSearch = "";
|
|
|
this.state.releaseDate = [];
|
|
@@ -1103,7 +1144,7 @@ const ShouKuang = React.createClass({
|
|
|
reason: this.state.content
|
|
|
}
|
|
|
}).done(
|
|
|
- function (data) {
|
|
|
+ function(data) {
|
|
|
if (!data.error.length) {
|
|
|
message.success("驳回成功!");
|
|
|
this.setState({
|
|
@@ -1135,7 +1176,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
},
|
|
|
callback(key) {
|
|
|
- console.log(key);
|
|
|
+ // console.log(key);
|
|
|
},
|
|
|
onSelectChange(selectedRowKeys) {
|
|
|
// for(var i=0; i<selectedRowKeys.length; i++){
|
|
@@ -1169,7 +1210,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: this.state.selectedRowKeys[0],
|
|
|
pageSize: 9999
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
let sum = 0;
|
|
|
if (!data.data) {
|
|
@@ -1196,7 +1237,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).done(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1218,7 +1259,7 @@ const ShouKuang = React.createClass({
|
|
|
pageSize: 9999,
|
|
|
whoType: 1
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
let waterSum = 0;
|
|
|
if (!data.data || !data.data.list) {
|
|
@@ -1245,7 +1286,12 @@ const ShouKuang = React.createClass({
|
|
|
createrName: thisdata.createrName,
|
|
|
saleName: thisdata.saleName,
|
|
|
createTimes: thisdata.createTimes,
|
|
|
- type: thisdata.type == 0 ? "手工" : thisdata.type == 1 ? "批量" : "合同变更退款",
|
|
|
+ type:
|
|
|
+ thisdata.type == 0
|
|
|
+ ? "手工"
|
|
|
+ : thisdata.type == 1
|
|
|
+ ? "批量"
|
|
|
+ : "合同变更退款",
|
|
|
deleteSign: thisdata.deleteSign,
|
|
|
deleteTimes: thisdata.deleteTimes,
|
|
|
refundTimes: thisdata.refundTimes,
|
|
@@ -1259,7 +1305,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1282,13 +1328,13 @@ const ShouKuang = React.createClass({
|
|
|
globalConfig.context +
|
|
|
"/api/admin/receivables/exportReceivables?" +
|
|
|
`orderNo=${
|
|
|
- this.state.orderNoSearch ? this.state.orderNoSearch : ""
|
|
|
+ this.state.orderNoSearch ? this.state.orderNoSearch : ""
|
|
|
}&buyerName=${
|
|
|
- this.state.nameSearch ? this.state.nameSearch : ""
|
|
|
+ this.state.nameSearch ? this.state.nameSearch : ""
|
|
|
}&departmentId=${
|
|
|
- this.state.departmenttList ? this.state.departmenttList : ""
|
|
|
+ this.state.departmenttList ? this.state.departmenttList : ""
|
|
|
}&contractNo=${
|
|
|
- this.state.contractNoSearch ? this.state.contractNoSearch : ""
|
|
|
+ this.state.contractNoSearch ? this.state.contractNoSearch : ""
|
|
|
}&processStatus=${this.state.processStatusSearch}`;
|
|
|
},
|
|
|
exportWater() {
|
|
@@ -1316,7 +1362,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: this.state.selectedRowKeys[0],
|
|
|
pageSize: 9999
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
if (!data.data || !data.data.list) {
|
|
|
if (data.error && data.error.length) {
|
|
@@ -1345,7 +1391,10 @@ const ShouKuang = React.createClass({
|
|
|
salesmanName: thisdata.salesmanName, //订单负责人
|
|
|
taskDistributionTime: thisdata.taskDistributionTime,
|
|
|
taskEndTime: thisdata.taskEndTime,
|
|
|
- outsource: thisdata.outsource
|
|
|
+ outsource: thisdata.outsource,
|
|
|
+ splitStatus: thisdata.splitStatus,
|
|
|
+ splitSuper: thisdata.splitSuper,
|
|
|
+ splitId: thisdata.splitId
|
|
|
});
|
|
|
}
|
|
|
}
|
|
@@ -1354,7 +1403,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1406,7 +1455,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: this.state.selectedRowKeys[0],
|
|
|
pageSize: 9999
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
if (!data.data || !data.data.list) {
|
|
|
if (data.error && data.error.length) {
|
|
@@ -1448,7 +1497,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1468,7 +1517,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: this.state.selectedRowKeys[0],
|
|
|
pageSize: 9999
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
let totalWaibao = 0;
|
|
|
if (!data.data) {
|
|
@@ -1523,7 +1572,7 @@ const ShouKuang = React.createClass({
|
|
|
});
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1553,7 +1602,7 @@ const ShouKuang = React.createClass({
|
|
|
orderNo: this.state.checkOrderNo,
|
|
|
remarks: this.state.checkData
|
|
|
},
|
|
|
- success: function (data) {
|
|
|
+ success: function(data) {
|
|
|
let theArr = [];
|
|
|
if (!data.data) {
|
|
|
if (data.error && data.error.length) {
|
|
@@ -1569,7 +1618,7 @@ const ShouKuang = React.createClass({
|
|
|
}
|
|
|
}.bind(this)
|
|
|
}).always(
|
|
|
- function () {
|
|
|
+ function() {
|
|
|
this.setState({
|
|
|
loading: false
|
|
|
});
|
|
@@ -1598,6 +1647,16 @@ const ShouKuang = React.createClass({
|
|
|
};
|
|
|
return (
|
|
|
<div className="user-content">
|
|
|
+ {this.state.resVisible ? (
|
|
|
+ <ResolutionDetail
|
|
|
+ cancel={this.resCancel}
|
|
|
+ detail={this.state.resRecord}
|
|
|
+ visible={this.state.resVisible}
|
|
|
+ id={this.state.resRecord.orderNo}
|
|
|
+ />
|
|
|
+ ) : (
|
|
|
+ ""
|
|
|
+ )}
|
|
|
<div className="content-title" style={{ marginBottom: 10 }}>
|
|
|
<span style={{ fontWeight: 900, fontSize: 16 }}>收款结算</span>
|
|
|
</div>
|
|
@@ -1638,7 +1697,7 @@ const ShouKuang = React.createClass({
|
|
|
this.setState({ departmenttList: e });
|
|
|
}}
|
|
|
>
|
|
|
- {departmentArr.map(function (item) {
|
|
|
+ {departmentArr.map(function(item) {
|
|
|
return (
|
|
|
<Select.Option key={item.id}>{item.name}</Select.Option>
|
|
|
);
|
|
@@ -1967,7 +2026,7 @@ const ShouKuang = React.createClass({
|
|
|
<span>
|
|
|
{`合同额总计(万元):${
|
|
|
this.state.totalHui ? this.state.totalHui : "0"
|
|
|
- }`}
|
|
|
+ }`}
|
|
|
</span>
|
|
|
}
|
|
|
</p>
|