|
@@ -1,5 +1,5 @@
|
|
|
import React from "react";
|
|
|
-import {Button, Input, Spin, Table, message, Form, Modal, Tabs, Tooltip,} from "antd";
|
|
|
+import { Button, Input, Spin, Table, message, Form, Modal, Tabs, Tooltip, } from "antd";
|
|
|
import $ from "jquery/src/ajax";
|
|
|
import {
|
|
|
getNewOrderStatus,
|
|
@@ -22,9 +22,10 @@ import ChangeApply from "./changeComponent/changeApply";
|
|
|
import { ChooseList } from "./chooseList.jsx";
|
|
|
import ShowModalDiv from "@/showModal.jsx";
|
|
|
import OrderRiZi from "@/orderRiZi.jsx";
|
|
|
-import {getProjectName} from "../../../tools";
|
|
|
+import { getProjectName } from "../../../tools";
|
|
|
import ProjectDetailsReadOnly from "../../../common/projectDetailsReadOnly";
|
|
|
import OrderItemStatus from "../../../common/orderItemStatus";
|
|
|
+import Cascaders from "../../../common/cascaders";
|
|
|
|
|
|
const contractChange = Form.create()(
|
|
|
React.createClass({
|
|
@@ -47,7 +48,7 @@ const contractChange = Form.create()(
|
|
|
endTime: this.state.searchData.releaseDate[1],
|
|
|
salesmanName: this.state.searchData.salesmanNameSearch,
|
|
|
complete: this.state.searchData.completeSearch || 1,
|
|
|
- depId: this.state.searchData.depIdSearch,
|
|
|
+ deps: this.state.searchData.deps,
|
|
|
orderNo: this.state.searchData.orderNoSearch,
|
|
|
contractNo: this.state.searchData.contractNoSearch,
|
|
|
type: this.state.searchData.changeSearch
|
|
@@ -118,7 +119,7 @@ const contractChange = Form.create()(
|
|
|
orderData: {}, //现订单数据
|
|
|
pictureUrl: [],
|
|
|
voucherUrl: [],
|
|
|
- attachment:[],
|
|
|
+ attachment: [],
|
|
|
buttonStatusA: true,
|
|
|
attachmentUrl: [],
|
|
|
proceedsData: {},
|
|
@@ -162,14 +163,14 @@ const contractChange = Form.create()(
|
|
|
width: 150,
|
|
|
render: (text) => {
|
|
|
return (
|
|
|
- <Tooltip title={text}>
|
|
|
- <div style={{
|
|
|
- maxWidth:'150px',
|
|
|
- overflow:'hidden',
|
|
|
- textOverflow: "ellipsis",
|
|
|
- whiteSpace:'nowrap',
|
|
|
- }}>{text}</div>
|
|
|
- </Tooltip>
|
|
|
+ <Tooltip title={text}>
|
|
|
+ <div style={{
|
|
|
+ maxWidth: '150px',
|
|
|
+ overflow: 'hidden',
|
|
|
+ textOverflow: "ellipsis",
|
|
|
+ whiteSpace: 'nowrap',
|
|
|
+ }}>{text}</div>
|
|
|
+ </Tooltip>
|
|
|
)
|
|
|
},
|
|
|
},
|
|
@@ -248,9 +249,9 @@ const contractChange = Form.create()(
|
|
|
key: "commodityName",
|
|
|
render: (text, record) => {
|
|
|
return (
|
|
|
- <span>{text}<span style={{ color: "red" }}>{record.patentTypeName}</span></span>
|
|
|
+ <span>{text}<span style={{ color: "red" }}>{record.patentTypeName}</span></span>
|
|
|
)
|
|
|
- }
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
title: "项目类别",
|
|
@@ -382,7 +383,7 @@ const contractChange = Form.create()(
|
|
|
taskComment: record.taskComment, //备注
|
|
|
main: record.main.toString(), //是否为主要
|
|
|
addnextVisible: true,
|
|
|
- dataInfor:record,
|
|
|
+ dataInfor: record,
|
|
|
addState: 0
|
|
|
});
|
|
|
},
|
|
@@ -426,7 +427,7 @@ const contractChange = Form.create()(
|
|
|
url
|
|
|
)
|
|
|
: [],
|
|
|
- attachment: thisdata.attachmentUrl
|
|
|
+ attachment: thisdata.attachmentUrl
|
|
|
? splitUrl(
|
|
|
thisdata.attachmentUrl,
|
|
|
",",
|
|
@@ -516,7 +517,7 @@ const contractChange = Form.create()(
|
|
|
// arrears: thisdata.arrears,
|
|
|
orderData: thisdata,
|
|
|
isAddition: thisdata.additionalOrder ? true : false,
|
|
|
- deleteSign:thisdata.deleteSign,
|
|
|
+ deleteSign: thisdata.deleteSign,
|
|
|
},
|
|
|
() => {
|
|
|
if (this.state.orderData.deleteSign !== 3) {
|
|
@@ -615,14 +616,20 @@ const contractChange = Form.create()(
|
|
|
},
|
|
|
|
|
|
search(obj) {
|
|
|
- this.setState(
|
|
|
- {
|
|
|
- searchData: obj
|
|
|
- },
|
|
|
- () => {
|
|
|
- this.loadData(1);
|
|
|
- }
|
|
|
- );
|
|
|
+ if (obj.reset) {
|
|
|
+ this.state.searchData.deps = [];
|
|
|
+ this.Cascaders.empty();
|
|
|
+ this.loadData(1);
|
|
|
+ } else {
|
|
|
+ this.setState(
|
|
|
+ {
|
|
|
+ searchData: Object.assign(this.state.searchData, obj)
|
|
|
+ },
|
|
|
+ () => {
|
|
|
+ this.loadData(1);
|
|
|
+ }
|
|
|
+ );
|
|
|
+ }
|
|
|
},
|
|
|
|
|
|
rizhi(orderNo) {
|
|
@@ -1162,16 +1169,33 @@ const contractChange = Form.create()(
|
|
|
<div className="user-search">
|
|
|
<Tabs defaultActiveKey="1" className="test">
|
|
|
<TabPane tab="搜索" key="1">
|
|
|
- <SearchInput search={this.search} isYxy={true} />
|
|
|
+ <div>
|
|
|
+ <Cascaders
|
|
|
+ ref={node => this.Cascaders = node}
|
|
|
+ placeholder="订单部门"
|
|
|
+ id="id"
|
|
|
+ name="name"
|
|
|
+ children="list"
|
|
|
+ height={28}
|
|
|
+ onSel={(e) => {
|
|
|
+ const { searchData } = this.state
|
|
|
+ searchData["deps"] = JSON.stringify(e);
|
|
|
+ this.setState({
|
|
|
+ searchData: searchData
|
|
|
+ })
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ <SearchInput search={this.search} isYxy={true} />
|
|
|
+ </div>
|
|
|
</TabPane>
|
|
|
<TabPane tab="更改表格显示数据" key="2">
|
|
|
<div style={{ marginLeft: 10 }}>
|
|
|
<ChooseList
|
|
|
- columns={this.state.columns}
|
|
|
- changeFn={this.changeList}
|
|
|
- changeList={this.state.changeList}
|
|
|
- top={55}
|
|
|
- margin={11}
|
|
|
+ columns={this.state.columns}
|
|
|
+ changeFn={this.changeList}
|
|
|
+ changeList={this.state.changeList}
|
|
|
+ top={55}
|
|
|
+ margin={11}
|
|
|
/>
|
|
|
</div>
|
|
|
</TabPane>
|
|
@@ -1183,8 +1207,8 @@ const contractChange = Form.create()(
|
|
|
bordered
|
|
|
columns={
|
|
|
this.state.changeList
|
|
|
- ? this.state.changeList
|
|
|
- : this.state.columns
|
|
|
+ ? this.state.changeList
|
|
|
+ : this.state.columns
|
|
|
}
|
|
|
style={{
|
|
|
cursor: 'pointer',
|
|
@@ -1209,87 +1233,87 @@ const contractChange = Form.create()(
|
|
|
onChange={this.callback}
|
|
|
type="card"
|
|
|
tabBarExtraContent={
|
|
|
- <div style={{fontWeight:'bold',paddingRight:'15px'}}>
|
|
|
- <OrderItemStatus deleteSign={this.state.deleteSign}/>
|
|
|
+ <div style={{ fontWeight: 'bold', paddingRight: '15px' }}>
|
|
|
+ <OrderItemStatus deleteSign={this.state.deleteSign} />
|
|
|
</div>
|
|
|
}
|
|
|
>
|
|
|
<TabPane tab="订单详情" key="a">
|
|
|
{this.state.activeKey === 'a' ? <div>
|
|
|
{this.state.orderData.deleteSign === 3 ? (
|
|
|
- <AddOrders
|
|
|
+ <AddOrders
|
|
|
+ orderUid={this.state.orderUid}
|
|
|
+ processStatus={0}
|
|
|
+ data={this.state.orderData.orderNo}
|
|
|
+ mark={this.state.buttonStatus}
|
|
|
+ getPrimaryOrder={this.getPrimaryOrder}
|
|
|
+ totalCui={this.state.totalCui}
|
|
|
+ closeDesc={this.closeDesc}
|
|
|
+ getAdditionalOrder={this.getAdditionalOrder}
|
|
|
+ deleteSign={this.state.orderData.deleteSign}
|
|
|
+ />
|
|
|
+ ) : (
|
|
|
+ <Form
|
|
|
+ layout="horizontal"
|
|
|
+ onSubmit={this.handleSubmit}
|
|
|
+ id="demand-form"
|
|
|
+ style={{ paddingBottom: "40px" }}
|
|
|
+ >
|
|
|
+ <Spin spinning={this.state.loading}>
|
|
|
+ <OrderDetail
|
|
|
+ domId='dindanxiangqing'
|
|
|
orderUid={this.state.orderUid}
|
|
|
- processStatus={0}
|
|
|
- data={this.state.orderData.orderNo}
|
|
|
- mark={this.state.buttonStatus}
|
|
|
- getPrimaryOrder={this.getPrimaryOrder}
|
|
|
- totalCui={this.state.totalCui}
|
|
|
- closeDesc={this.closeDesc}
|
|
|
- getAdditionalOrder={this.getAdditionalOrder}
|
|
|
- deleteSign={this.state.orderData.deleteSign}
|
|
|
- />
|
|
|
- ):(
|
|
|
- <Form
|
|
|
- layout="horizontal"
|
|
|
- onSubmit={this.handleSubmit}
|
|
|
- id="demand-form"
|
|
|
- style={{ paddingBottom: "40px" }}
|
|
|
- >
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <OrderDetail
|
|
|
- domId='dindanxiangqing'
|
|
|
- orderUid={this.state.orderUid}
|
|
|
- orderData={this.state.orderData}
|
|
|
- getOrderLog={this.getOrderLog}
|
|
|
- totalCui={parseFloat(this.state.totalCui)}
|
|
|
- dataSourceX={this.state.dataSourceX}
|
|
|
- contactList={this.state.contactList}
|
|
|
- contactListNew={this.state.contactListNew}
|
|
|
- orderNo={this.state.orderNo}
|
|
|
- />
|
|
|
- </Spin>
|
|
|
- </Form>
|
|
|
- ) }
|
|
|
- </div>:<div/>}
|
|
|
+ orderData={this.state.orderData}
|
|
|
+ getOrderLog={this.getOrderLog}
|
|
|
+ totalCui={parseFloat(this.state.totalCui)}
|
|
|
+ dataSourceX={this.state.dataSourceX}
|
|
|
+ contactList={this.state.contactList}
|
|
|
+ contactListNew={this.state.contactListNew}
|
|
|
+ orderNo={this.state.orderNo}
|
|
|
+ />
|
|
|
+ </Spin>
|
|
|
+ </Form>
|
|
|
+ )}
|
|
|
+ </div> : <div />}
|
|
|
</TabPane>
|
|
|
{tabList.map((item, index, arr) => {
|
|
|
return (
|
|
|
<TabPane tab={"合同变更记录" + (index + 1)} key={item.id}>
|
|
|
{
|
|
|
this.state.activeKey === String(item.id) ?
|
|
|
- (
|
|
|
- this.state.contractData.processState === 0 &&
|
|
|
- this.state.contractData.status != 5 ? (
|
|
|
- <ChangeApply
|
|
|
- orderUid={this.state.orderUid}
|
|
|
- id={Math.random()}
|
|
|
- orderData={this.state.contractData}
|
|
|
- voucherUrl={this.state.voucherUrl}
|
|
|
- onCancel={this.visitCancel}
|
|
|
- />
|
|
|
- ) : (
|
|
|
- <ChangeDetail
|
|
|
- domId={'hetongbiangenjilu' + (index + 1)}
|
|
|
- orderUid={this.state.orderUid}
|
|
|
- id={item.id}
|
|
|
- money={
|
|
|
- index == arr.length - 1
|
|
|
- ? this.state.orderData.totalAmount + ""
|
|
|
- : undefined
|
|
|
- }
|
|
|
- visitCancel={this.visitCancel}
|
|
|
- data={this.state.contractData}
|
|
|
- pictureUrl={this.state.voucherUrl}
|
|
|
- attachment = {this.state.attachment}
|
|
|
- processState={this.props.processState}
|
|
|
- dataSource={this.state.dataProps}
|
|
|
- proceedsData={this.state.proceedsData}
|
|
|
- proceedsTotal={this.state.proTotal}
|
|
|
- invoiceTotal={this.state.invTotal}
|
|
|
- contactList={this.state.refundInvoice}
|
|
|
- />
|
|
|
- )
|
|
|
- ) : <div/>
|
|
|
+ (
|
|
|
+ this.state.contractData.processState === 0 &&
|
|
|
+ this.state.contractData.status != 5 ? (
|
|
|
+ <ChangeApply
|
|
|
+ orderUid={this.state.orderUid}
|
|
|
+ id={Math.random()}
|
|
|
+ orderData={this.state.contractData}
|
|
|
+ voucherUrl={this.state.voucherUrl}
|
|
|
+ onCancel={this.visitCancel}
|
|
|
+ />
|
|
|
+ ) : (
|
|
|
+ <ChangeDetail
|
|
|
+ domId={'hetongbiangenjilu' + (index + 1)}
|
|
|
+ orderUid={this.state.orderUid}
|
|
|
+ id={item.id}
|
|
|
+ money={
|
|
|
+ index == arr.length - 1
|
|
|
+ ? this.state.orderData.totalAmount + ""
|
|
|
+ : undefined
|
|
|
+ }
|
|
|
+ visitCancel={this.visitCancel}
|
|
|
+ data={this.state.contractData}
|
|
|
+ pictureUrl={this.state.voucherUrl}
|
|
|
+ attachment={this.state.attachment}
|
|
|
+ processState={this.props.processState}
|
|
|
+ dataSource={this.state.dataProps}
|
|
|
+ proceedsData={this.state.proceedsData}
|
|
|
+ proceedsTotal={this.state.proTotal}
|
|
|
+ invoiceTotal={this.state.invTotal}
|
|
|
+ contactList={this.state.refundInvoice}
|
|
|
+ />
|
|
|
+ )
|
|
|
+ ) : <div />
|
|
|
}
|
|
|
</TabPane>
|
|
|
);
|
|
@@ -1303,26 +1327,26 @@ const contractChange = Form.create()(
|
|
|
>
|
|
|
{
|
|
|
this.state.activeKey === String(item.usedOrder) ?
|
|
|
- <Form
|
|
|
- layout="horizontal"
|
|
|
- onSubmit={this.handleSubmit}
|
|
|
- id="demand-form"
|
|
|
- style={{ paddingBottom: "40px" }}
|
|
|
- >
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <OrderDetail
|
|
|
- domId={'yuandingdan' + (index + 1)}
|
|
|
- orderUid={this.state.orderUid}
|
|
|
- orderData={this.state.primaryOrderData}
|
|
|
- getOrderLog={this.getOrderLog}
|
|
|
- dataSourceX={this.state.dataSourceX}
|
|
|
- contactList={this.state.contactList}
|
|
|
- orderNo={this.state.primaryOrderNo}
|
|
|
- totalCui={this.state.totalCui}
|
|
|
- contactListNew={this.state.contactListNew}
|
|
|
- />
|
|
|
- </Spin>
|
|
|
- </Form> : <div/>
|
|
|
+ <Form
|
|
|
+ layout="horizontal"
|
|
|
+ onSubmit={this.handleSubmit}
|
|
|
+ id="demand-form"
|
|
|
+ style={{ paddingBottom: "40px" }}
|
|
|
+ >
|
|
|
+ <Spin spinning={this.state.loading}>
|
|
|
+ <OrderDetail
|
|
|
+ domId={'yuandingdan' + (index + 1)}
|
|
|
+ orderUid={this.state.orderUid}
|
|
|
+ orderData={this.state.primaryOrderData}
|
|
|
+ getOrderLog={this.getOrderLog}
|
|
|
+ dataSourceX={this.state.dataSourceX}
|
|
|
+ contactList={this.state.contactList}
|
|
|
+ orderNo={this.state.primaryOrderNo}
|
|
|
+ totalCui={this.state.totalCui}
|
|
|
+ contactListNew={this.state.contactListNew}
|
|
|
+ />
|
|
|
+ </Spin>
|
|
|
+ </Form> : <div />
|
|
|
}
|
|
|
</TabPane>
|
|
|
);
|
|
@@ -1359,27 +1383,27 @@ const contractChange = Form.create()(
|
|
|
<TabPane tab="附加订单" key="c">
|
|
|
{
|
|
|
this.state.activeKey === "c" ?
|
|
|
- <AddOrders
|
|
|
- domId='fujiadingdan'
|
|
|
- orderUid={this.state.orderUid}
|
|
|
- processStatus={0}
|
|
|
- data={this.state.orderData.additionalOrder}
|
|
|
- mark={this.state.buttonStatusA}
|
|
|
- getPrimaryOrder={this.getPrimaryOrder}
|
|
|
- closeDesc={this.closeDesc}
|
|
|
- getAdditionalOrder={this.getAdditionalOrder}
|
|
|
- activeKey={this.state.activeKey}
|
|
|
- /> : <div/>
|
|
|
+ <AddOrders
|
|
|
+ domId='fujiadingdan'
|
|
|
+ orderUid={this.state.orderUid}
|
|
|
+ processStatus={0}
|
|
|
+ data={this.state.orderData.additionalOrder}
|
|
|
+ mark={this.state.buttonStatusA}
|
|
|
+ getPrimaryOrder={this.getPrimaryOrder}
|
|
|
+ closeDesc={this.closeDesc}
|
|
|
+ getAdditionalOrder={this.getAdditionalOrder}
|
|
|
+ activeKey={this.state.activeKey}
|
|
|
+ /> : <div />
|
|
|
}
|
|
|
</TabPane>
|
|
|
) : (
|
|
|
- ""
|
|
|
- )
|
|
|
- ) : (
|
|
|
""
|
|
|
- )}
|
|
|
+ )
|
|
|
+ ) : (
|
|
|
+ ""
|
|
|
+ )}
|
|
|
</Tabs>
|
|
|
- </Modal> : <div/>}
|
|
|
+ </Modal> : <div />}
|
|
|
<Modal
|
|
|
maskClosable={false}
|
|
|
visible={this.state.noVisible}
|
|
@@ -1461,9 +1485,9 @@ const contractChange = Form.create()(
|
|
|
/>
|
|
|
</div>
|
|
|
{this.state.addnextVisible && <ProjectDetailsReadOnly
|
|
|
- infor={this.state.dataInfor}
|
|
|
- visible={this.state.addnextVisible}
|
|
|
- onCancel={this.nextCancel}
|
|
|
+ infor={this.state.dataInfor}
|
|
|
+ visible={this.state.addnextVisible}
|
|
|
+ onCancel={this.nextCancel}
|
|
|
/>}
|
|
|
</div>
|
|
|
);
|