|
@@ -52,7 +52,6 @@ const MyTaskOutsource = React.createClass({
|
|
|
loadData(pageNo) {
|
|
|
this.state.data = [];
|
|
|
this.setState({
|
|
|
- page: pageNo,
|
|
|
loading: true,
|
|
|
});
|
|
|
$.ajax({
|
|
@@ -61,7 +60,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
crossDomain: false,
|
|
|
url: globalConfig.context + "/api/admin/orderProject/orderTaskList",
|
|
|
data: {
|
|
|
- pageNo: pageNo || this.state.page || 1,
|
|
|
+ pageNo: pageNo || 1,
|
|
|
pageSize: this.state.pagination.pageSize,
|
|
|
specially: 0, //个人
|
|
|
name: this.state.nameSearch, //客户名称
|
|
@@ -105,6 +104,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
}
|
|
|
this.setState({
|
|
|
dataSource: theArr,
|
|
|
+ page: data.data.pageNo,
|
|
|
pagination: this.state.pagination,
|
|
|
});
|
|
|
}.bind(this),
|
|
@@ -227,9 +227,6 @@ const MyTaskOutsource = React.createClass({
|
|
|
pageSize: 10,
|
|
|
onChange: function (page) {
|
|
|
this.loadData(page);
|
|
|
- this.setState({
|
|
|
- page,
|
|
|
- });
|
|
|
}.bind(this),
|
|
|
showTotal: function (total) {
|
|
|
return "共" + total + "条数据";
|
|
@@ -716,6 +713,10 @@ const MyTaskOutsource = React.createClass({
|
|
|
},
|
|
|
},
|
|
|
],
|
|
|
+
|
|
|
+ displayFees: 'none',
|
|
|
+ costReduction: '',
|
|
|
+ officialCost: '',
|
|
|
};
|
|
|
},
|
|
|
/* 分派 */
|
|
@@ -1044,26 +1045,8 @@ const MyTaskOutsource = React.createClass({
|
|
|
} else {
|
|
|
for (let i = 0; i < data.data.length; i++) {
|
|
|
let thisdata = data.data[i];
|
|
|
- theArr.push({
|
|
|
- key: i,
|
|
|
- id: thisdata.id,
|
|
|
- orderNo: thisdata.orderNo, //订单编号
|
|
|
- commodityId: thisdata.commodityId, //项目ID
|
|
|
- commodityName: thisdata.commodityName, //项目名称
|
|
|
- cname: thisdata.cname, //项目类别
|
|
|
- commodityPrice: thisdata.commodityPrice, //项目价格
|
|
|
- commodityQuantity: thisdata.commodityQuantity, //项目数量
|
|
|
- main: thisdata.main, //是否为主要项目
|
|
|
- taskComment: thisdata.taskComment, //项目说明
|
|
|
- contacts: thisdata.contacts, //联系人
|
|
|
- contactsMobile: thisdata.contactsMobile, //联系人电话
|
|
|
- taskStatus: thisdata.taskStatus, //是否分配
|
|
|
- contractNo: thisdata.contractNo, //合同编号
|
|
|
- certificateNumber: thisdata.certificateNumber,
|
|
|
- splitStatus: thisdata.splitStatus, //是否为子项目 2是 1主项目
|
|
|
- splitSuper: thisdata.splitSuper,
|
|
|
- splitId: thisdata.splitId,
|
|
|
- });
|
|
|
+ thisdata.key = i;
|
|
|
+ theArr.push(thisdata);
|
|
|
}
|
|
|
}
|
|
|
this.setState({
|
|
@@ -1110,14 +1093,14 @@ const MyTaskOutsource = React.createClass({
|
|
|
updataSwicth: false,
|
|
|
});
|
|
|
this.companyReset();
|
|
|
- this.reset();
|
|
|
+ this.reset(this.state.page);
|
|
|
},
|
|
|
visitOk() {
|
|
|
this.setState({
|
|
|
visible: false,
|
|
|
speVisible: false,
|
|
|
});
|
|
|
- this.reset();
|
|
|
+ this.reset(this.state.page);
|
|
|
},
|
|
|
closeDesc(e, s) {
|
|
|
this.state.showDesc = e;
|
|
@@ -1537,10 +1520,20 @@ const MyTaskOutsource = React.createClass({
|
|
|
nextCancel() {
|
|
|
this.setState({
|
|
|
addnextVisible: false,
|
|
|
+ displayFees: "none",
|
|
|
+ costReduction: '',
|
|
|
+ officialCost: '',
|
|
|
});
|
|
|
},
|
|
|
//点击打卡项目详情
|
|
|
tableRowClickX(record) {
|
|
|
+ if (record.type == "1") {
|
|
|
+ this.setState({
|
|
|
+ displayFees: "block",
|
|
|
+ costReduction: record.costReduction,
|
|
|
+ officialCost: record.officialCost,
|
|
|
+ });
|
|
|
+ }
|
|
|
this.setState({
|
|
|
jid: record.id, //项目ID
|
|
|
kid: record.commodityId, //商品ID
|
|
@@ -1563,7 +1556,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
search() {
|
|
|
this.loadData();
|
|
|
},
|
|
|
- reset() {
|
|
|
+ reset(page) {
|
|
|
this.state.id = ""; //项目编号
|
|
|
this.state.orderNo = ""; //订单编号
|
|
|
this.state.contractNoSearch = undefined; //订单编号
|
|
@@ -1577,7 +1570,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
this.state.reviewDate = ""; //评审日期
|
|
|
this.state.publicityDate = ""; //公示日期
|
|
|
this.state.licenceDate = ""; //发证日期
|
|
|
- attachmentUrl: []; //附件
|
|
|
+ // attachmentUrl: []; //附件
|
|
|
this.state.contacts = ""; //联系人
|
|
|
this.state.contactMobile = ""; //联系人电话
|
|
|
this.state.legalPerson = ""; //法人
|
|
@@ -1595,8 +1588,8 @@ const MyTaskOutsource = React.createClass({
|
|
|
this.state.departmenttSearch = undefined;
|
|
|
this.state.outsourceName = ""; //外包公司名称
|
|
|
this.state.outsourcePrice = ""; //外包价格
|
|
|
- this.loadData(this.state.page);
|
|
|
this.state.approvalSearch = undefined;
|
|
|
+ this.loadData(page || 0);
|
|
|
this.setState({
|
|
|
oldInfor: {}
|
|
|
})
|
|
@@ -2139,7 +2132,9 @@ const MyTaskOutsource = React.createClass({
|
|
|
<Button type="primary" onClick={this.search}>
|
|
|
搜索
|
|
|
</Button>
|
|
|
- <Button onClick={this.reset}>重置</Button>
|
|
|
+ <Button onClick={()=>{
|
|
|
+ this.reset();
|
|
|
+ }}>重置</Button>
|
|
|
|
|
|
{/* <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
|
|
|
<div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
|
|
@@ -3112,7 +3107,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
</Spin>
|
|
|
</Form>
|
|
|
</Modal>
|
|
|
- <Modal
|
|
|
+ {this.state.addnextVisible ? <Modal
|
|
|
maskClosable={false}
|
|
|
visible={this.state.addnextVisible}
|
|
|
onOk={this.nextCancel}
|
|
@@ -3140,6 +3135,26 @@ const MyTaskOutsource = React.createClass({
|
|
|
<span>{this.state.commodityQuantity}</span>
|
|
|
</FormItem>
|
|
|
<FormItem
|
|
|
+ className="half-item"
|
|
|
+ {...formItemLayout}
|
|
|
+ label="官费"
|
|
|
+ style={{ display: this.state.displayFees }}
|
|
|
+ >
|
|
|
+ <span>
|
|
|
+ {this.state.officialCost == 0 ? "无官费" : "有官费"}
|
|
|
+ </span>
|
|
|
+ </FormItem>
|
|
|
+ <FormItem
|
|
|
+ className="half-item"
|
|
|
+ {...formItemLayout}
|
|
|
+ label="费减"
|
|
|
+ style={{ display: this.state.displayFees }}
|
|
|
+ >
|
|
|
+ <span>
|
|
|
+ {this.state.costReduction == 0 ? "无费减" : "有费减"}
|
|
|
+ </span>
|
|
|
+ </FormItem>
|
|
|
+ <FormItem
|
|
|
className="half-item"
|
|
|
{...formItemLayout}
|
|
|
label="金额(万元)"
|
|
@@ -3165,7 +3180,7 @@ const MyTaskOutsource = React.createClass({
|
|
|
</div>
|
|
|
</Spin>
|
|
|
</Form>
|
|
|
- </Modal>
|
|
|
+ </Modal> : <div/>}
|
|
|
<Modal
|
|
|
maskClosable={false}
|
|
|
visible={this.state.speVisible}
|