changeDetailJsjl.js 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867
  1. import React, { Component } from "react";
  2. import { Form, Upload, Modal, Input, Button, message, Select, Table } from "antd";
  3. import AgreeButton from "./agreeButton.js";
  4. import Rizhi from "./rizhi.js";
  5. import { getProcessStatusNew, changeColor } from "@/tools.js";
  6. import { shenghePeo } from "@/tools.js";
  7. import { typeList } from '@/dataDic.js'
  8. import $ from "jquery/src/ajax";
  9. import tongguo from "../../../../../../image/tongguo.png";
  10. import quxiao from "../../../../../../image/quxiao.png";
  11. import ProAndCuiList from "./proAndCuiList.jsx";
  12. import "./xButton.less";
  13. import Refund from "./refund.js"
  14. import ImgList from "../../../../common/imgList";
  15. import FlowChart from '../../../../common/flowchart'; // 流程图
  16. import SelectReject from '../../../../common/selectreject'; // 驳回位置选择
  17. // import ReactToPrint from "react-to-print";
  18. const formItemLayout = {
  19. labelCol: { span: 8 },
  20. wrapperCol: { span: 14 }
  21. };
  22. const getChangeType = function (e) {
  23. if (e || e == 0) {
  24. let str = e.toString();
  25. let theType = "";
  26. typeList.map(function (item) {
  27. if (item.value == str) {
  28. theType = item.key;
  29. }
  30. });
  31. return theType;
  32. }
  33. };
  34. class Itemlist extends Component {
  35. constructor(props) {
  36. super(props);
  37. }
  38. render() {
  39. let pageData = this.props.pageData;
  40. return (
  41. <div className="clearfix">
  42. <Form.Item
  43. label={pageData.labelA}
  44. {...pageData.formItemLayoutA}
  45. className="half-item"
  46. >
  47. <p style={{ width: 350, wordWrap: "break-word" }}>
  48. {pageData.dataA}
  49. {
  50. pageData.labelA === '当前进度' &&
  51. <FlowChart id={this.props.id} />
  52. }
  53. </p>
  54. </Form.Item>
  55. <Form.Item
  56. label={pageData.labelB}
  57. {...pageData.formItemLayoutB}
  58. className="half-item"
  59. >
  60. <span>{pageData.dataB}</span>
  61. </Form.Item>
  62. </div>
  63. );
  64. }
  65. }
  66. class ChangeDetail extends Component {
  67. constructor(props) {
  68. super(props);
  69. this.state = {
  70. rotateDeg: 0,
  71. previewVisible: false,
  72. buttonStatus: true,
  73. changeType: 1,
  74. dataSource: [],
  75. reason: "",
  76. // 累计回收退票
  77. refundInvoice: 0,
  78. // 退票数组
  79. contactList: [],
  80. rejectState: 0,
  81. // 收款信息
  82. proceedsData: [],
  83. proceedsTotal: this.props.proceedsTotal,
  84. // 开票信息
  85. invoiceData: [],
  86. invoiceTotal: this.props.invoiceTotal,
  87. cost: 10,
  88. refund: 8,
  89. // 测试添加退票
  90. contactList: this.props.contactList,
  91. ContactsLists: [
  92. {
  93. title: "金额(万元)",
  94. dataIndex: "amount",
  95. key: "amount",
  96. render: (text, record) => {
  97. return (
  98. <div>
  99. 实际回收退票(万元)
  100. <Input
  101. value={record.amount}
  102. placeholder="请输入金额(必填项)"
  103. disabled={record.load}
  104. key={record.id}
  105. required="required"
  106. onChange={(e) => {
  107. record.amount = e.target.value;
  108. this.setState({ contactList: this.state.contactList });
  109. }}
  110. style={{ width: "120px" }}
  111. />
  112. </div>
  113. );
  114. },
  115. },
  116. {
  117. title: "时间",
  118. dataIndex: "createTimes",
  119. key: "createTimes",
  120. render: (text, record) => {
  121. return <div>{record.createTimes}</div>;
  122. },
  123. },
  124. ],
  125. };
  126. this.getOrgCodeUrl = this.getOrgCodeUrl.bind(this);
  127. this.changeButtonStatus = this.changeButtonStatus.bind(this);
  128. this.moneyOld = this.moneyOld.bind(this);
  129. this.rotate = this.rotate.bind(this);
  130. this.downImg = this.downImg.bind(this);
  131. this.upImg = this.upImg.bind(this);
  132. }
  133. componentWillReceiveProps(nextProps) {
  134. this.setState({
  135. projectState: nextProps.data.projectState,
  136. zxsCost: nextProps.data.zxsCost,
  137. zxsRemarks: nextProps.data.zxsRemarks,
  138. paymentTimes: nextProps.data.paymentTimes,
  139. paymentAmount: nextProps.data.paymentAmount,
  140. invoiceTimes: nextProps.data.invoiceTimes,
  141. invoiceAmount: nextProps.data.invoiceAmount,
  142. cwCost: nextProps.data.cwCost,
  143. refundableAmount: nextProps.data.refundableAmount,
  144. cwRemarks: nextProps.data.cwRemarks,
  145. contactList: nextProps.contactList,
  146. refundInvoice: nextProps.data.refundInvoice,
  147. });
  148. }
  149. getOrgCodeUrl(e) {
  150. this.setState({
  151. orgCodeUrl: e,
  152. });
  153. }
  154. //同意拒绝按钮的有无
  155. changeButtonStatus() {
  156. this.setState({
  157. buttonStatus: !this.state.buttonStatus,
  158. });
  159. window.setTimeout(() => {
  160. this.setState({
  161. reason: "",
  162. });
  163. }, 100);
  164. }
  165. downImg() {
  166. let num = 0;
  167. for (let i = 0; i < this.props.pictureUrl.length; i++) {
  168. if (this.props.pictureUrl[i].url == this.state.previewImage) {
  169. num = i;
  170. }
  171. }
  172. if (num == this.props.pictureUrl.length - 1) {
  173. return message.warning("已经是最后一张了哦");
  174. }
  175. this.state.previewImage = this.props.pictureUrl[num + 1].url;
  176. this.setState({
  177. previewImage: this.state.previewImage,
  178. rotateDeg: 0,
  179. });
  180. }
  181. upImg() {
  182. let num = 0;
  183. for (let i = 0; i < this.props.pictureUrl.length; i++) {
  184. if (this.props.pictureUrl[i].url == this.state.previewImage) {
  185. num = i;
  186. }
  187. }
  188. if (num == 0) {
  189. return message.warning("已经是第一张了哦");
  190. }
  191. this.state.previewImage = this.props.pictureUrl[num - 1].url;
  192. this.setState({
  193. previewImage: this.state.previewImage,
  194. rotateDeg: 0,
  195. });
  196. }
  197. rotate() {
  198. let rotateDeg = this.state.rotateDeg + 90;
  199. this.setState({
  200. rotateDeg,
  201. });
  202. }
  203. moneyOld(str, money) {
  204. if (money) {
  205. return (
  206. <span style={{ color: "red", fontWeight: 900, fontSize: 16 }}>
  207. {str}(原合同金额{money}万元)
  208. </span>
  209. );
  210. } else {
  211. return (
  212. <span style={{ color: "red", fontWeight: 900, fontSize: 16 }}>
  213. {str}
  214. </span>
  215. );
  216. }
  217. }
  218. render() {
  219. const pageData = [
  220. {
  221. labelA: "客户名称",
  222. formItemLayoutA: formItemLayout,
  223. dataA: this.props.data.userName,
  224. labelB: "合同编号",
  225. formItemLayoutB: formItemLayout,
  226. dataB: this.props.data.contractNo,
  227. },
  228. {
  229. labelA: "时间",
  230. formItemLayoutA: formItemLayout,
  231. dataA: this.props.data.createTimes,
  232. labelB: "发起人",
  233. formItemLayoutB: formItemLayout,
  234. dataB: this.props.data.applicant,
  235. },
  236. {
  237. labelA: "当前进度",
  238. formItemLayoutA: formItemLayout,
  239. // 当前是咨询师以及咨询师经理时使用shenhePeo函数,其他流程正常显示
  240. dataA:
  241. this.props.data.processState == 3 || this.props.data.processState == 4
  242. ? shenghePeo(this.props.data.examineName, this.props.data.processState)
  243. : getProcessStatusNew(
  244. this.props.data.examineName,
  245. this.props.data.processState,
  246. this.props.data.status
  247. ),
  248. labelB: "变更类型",
  249. formItemLayoutB: formItemLayout,
  250. dataB: getChangeType(this.props.data.type),
  251. },
  252. {
  253. labelA: "合同额(万元)",
  254. formItemLayoutA: formItemLayout,
  255. dataA: this.moneyOld(this.props.data.totalAmount, this.props.money),
  256. labelB: "已收款(万元)",
  257. formItemLayoutB: formItemLayout,
  258. dataB: changeColor(this.props.data.settlementAmount),
  259. },
  260. {
  261. labelA: "欠款(万元)",
  262. formItemLayoutA: formItemLayout,
  263. dataA: changeColor(this.props.data.arrears),
  264. labelB: "申请退款(万元)",
  265. formItemLayoutB: formItemLayout,
  266. dataB: changeColor(this.props.data.changeAmount),
  267. },
  268. {
  269. labelA: "首付款(万元)",
  270. formItemLayoutA: formItemLayout,
  271. dataA: changeColor(this.props.data.firstAmount),
  272. },
  273. {
  274. labelA: "变更原因",
  275. formItemLayoutA: formItemLayout,
  276. dataA: this.props.data.remarks,
  277. },
  278. ];
  279. const planData = [
  280. {
  281. labelA: "项目进度",
  282. formItemLayoutA: formItemLayout,
  283. dataA: this.props.data.projectState,
  284. onChangeA: (value) => {
  285. this.setState({
  286. projectState: value,
  287. });
  288. },
  289. labelB: "发生成本费用(万元)",
  290. formItemLayoutB: formItemLayout,
  291. dataB: this.props.data.zxsCost,
  292. onChangeB: (value) => {
  293. this.setState({
  294. zxsCost: value,
  295. });
  296. },
  297. },
  298. {
  299. labelA: "备注",
  300. formItemLayoutA: formItemLayout,
  301. dataA: this.props.data.zxsRemarks,
  302. onChangeA: (value) => {
  303. this.setState({
  304. zxsRemarks: value,
  305. });
  306. },
  307. },
  308. ];
  309. const financeData = [
  310. {
  311. labelA: "发生成本(万元)",
  312. formItemLayoutA: formItemLayout,
  313. dataA: this.props.data.cwCost,
  314. labelB: "应退金额(万元)",
  315. formItemLayoutB: formItemLayout,
  316. dataB: this.props.data.refundableAmount,
  317. },
  318. ];
  319. const buttonData = [
  320. {
  321. name: "同意",
  322. title: "理由",
  323. placeholder: "请输入理由",
  324. type: "primary",
  325. status: 2,
  326. onChange: (value) => {
  327. this.setState({
  328. remarks: value,
  329. });
  330. },
  331. },
  332. {
  333. name: "拒绝",
  334. title: "理由",
  335. placeholder: "请输入理由",
  336. type: "danger",
  337. status: 3,
  338. onChange: (value) => {
  339. this.setState({
  340. remarks: value,
  341. });
  342. },
  343. },
  344. ];
  345. const orgCodeUrl = this.props.pictureUrl;
  346. const attachment = this.props.attachment
  347. return (
  348. <div className="clearfix changeDetail">
  349. <div
  350. className="clearfix"
  351. ref={(e) => {
  352. this.refs = e;
  353. }}
  354. >
  355. <div
  356. style={{
  357. borderRadius: "50%",
  358. width: 300,
  359. height: 300,
  360. position: "absolute",
  361. top: 230,
  362. left: 525,
  363. transform: "rotate(-5deg)",
  364. zIndex: 1,
  365. display:
  366. this.props.data.status == 4
  367. ? "block"
  368. : "none",
  369. }}
  370. >
  371. <img src={tongguo} style={{ width: "100%" }} />
  372. </div>
  373. <div
  374. style={{
  375. borderRadius: "50%",
  376. width: 300,
  377. height: 300,
  378. position: "absolute",
  379. top: 284,
  380. left: 586,
  381. transform: "rotate(-5deg)",
  382. zIndex: 1,
  383. display: this.props.data.status == 5 ? "block" : "none",
  384. }}
  385. >
  386. <img src={quxiao} style={{ width: "63%" }} />
  387. </div>
  388. <h2 style={{ textAlign: "center", marginBottom: 10 }}>
  389. 合同变更记录
  390. </h2>
  391. {pageData.map((item, index) => {
  392. return <Itemlist key={index} pageData={item} id={this.props.id} />;
  393. })}
  394. <Form.Item
  395. label="变更凭证"
  396. labelCol={{ span: 4 }}
  397. wrapperCol={{ span: 18 }}
  398. >
  399. <div style={{ paddingTop: '10px', paddingBottom: '10px' }}>
  400. <ImgList domId={this.props.domId ? this.props.domId + '1' : 'changeDetailJsjl1'} fileList={orgCodeUrl} ItemWidth={'96px'} />
  401. </div>
  402. <Rizhi changeId={this.props.id} />
  403. </Form.Item>
  404. {
  405. this.props.contractPictureUrl && this.props.contractPictureUrl.length != 0 &&
  406. <div className="clearfix">
  407. <Form.Item
  408. labelCol={{ span: 4 }}
  409. wrapperCol={{ span: 18 }}
  410. label="最新合同"
  411. >
  412. <div style={{ paddingTop: 10 }}>
  413. <ImgList
  414. domId={"zxht"}
  415. fileList={
  416. this.props.contractPictureUrl
  417. }
  418. ItemWidth={"96px"}
  419. />
  420. </div>
  421. </Form.Item>
  422. </div>
  423. }
  424. <ul
  425. style={{
  426. width: "868px",
  427. overflow: "hidden",
  428. paddingLeft: "90px",
  429. position: "relative",
  430. bottom: "0px",
  431. }}
  432. >
  433. {/* <span>操作人:</span> */}
  434. {this.props.dataSource.map((item, index) => {
  435. if (item.status == 0) {
  436. item.status = "发起";
  437. } else if (item.status == 1) {
  438. item.status = "审核中";
  439. } else if (item.status == 2) {
  440. item.status = "通过";
  441. } else if (item.status == 3) {
  442. item.status = "驳回";
  443. } else if (item.status == 4) {
  444. item.status = "完成";
  445. } else if (item.status == 5) {
  446. item.status = "撤销";
  447. }
  448. return (
  449. <li
  450. key={index}
  451. style={{
  452. width: "100%",
  453. height: "auto",
  454. wordBreak: "break-all",
  455. marginBottom: "10px",
  456. }}
  457. >
  458. {item.aname + ":" + "【" + item.status + "】" + item.remarks + "(" + item.createTimes + ")"}
  459. </li>
  460. );
  461. })}
  462. </ul>
  463. <ProAndCuiList id={this.props.id} />
  464. <div className="clearfix">
  465. <h3 style={{ marginLeft: 20, fontWeight: 800, marginBottom: 10 }}>
  466. 收款情况
  467. </h3>
  468. <div style={{ marginLeft: "90px" }}>
  469. <ul>
  470. {(this.props.proceedsData.bill || []).map((item, index) => (
  471. <li key={index}>
  472. {item.payTime +
  473. " " +
  474. item.aName +
  475. " 收款:" +
  476. item.transactionAmount +
  477. "万元"}
  478. </li>
  479. ))}
  480. </ul>
  481. <div>收款总计:{this.props.proceedsTotal}万元</div>
  482. </div>
  483. <br />
  484. <div style={{ marginLeft: "90px" }}>
  485. <ul>
  486. {(this.props.proceedsData.invoice || []).map((item, index) => (
  487. <li key={index}>
  488. {item.createTime + " " + " 开票:" + item.amount + "万元"}
  489. </li>
  490. ))}
  491. </ul>
  492. <div>开票总计:{this.props.invoiceTotal}万元</div>
  493. </div>
  494. <p style={{ marginLeft: "90px", color: "red" }}>
  495. 系统预估 产生成本(万元):
  496. {this.props.data.estimateCost
  497. ? this.props.data.estimateCost
  498. : "0"}{" "}
  499. &nbsp;应退金额(万元):
  500. {this.props.data.estimateRefundable
  501. ? this.props.data.estimateRefundable
  502. : "0"}
  503. </p>
  504. </div>
  505. {/* 当前财务状态 */}
  506. <div
  507. style={{
  508. display: this.props.data.processState > 6 ? "block" : "none",
  509. marginTop: '10px'
  510. }}
  511. >
  512. <h3 style={{ marginLeft: 20, fontWeight: 800, marginBottom: 10 }}>
  513. 当前财务状态(财务填写)
  514. </h3>
  515. {financeData.map((item, index) => {
  516. return <Itemlist key={index} pageData={item} id={this.props.id} />;
  517. })}
  518. </div>
  519. {/* {this.props.data.type === 0 ? (
  520. <div>
  521. <h3 style={{ marginLeft: 10, fontWeight: 800, marginBottom: 10 }}>
  522. 当前项目进度(咨询师经理填写)
  523. </h3>
  524. {planData.map((item, index) => {
  525. return <Itemlist key={index} pageData={item} />;
  526. })}
  527. </div>
  528. ) : (
  529. ""
  530. )} */}
  531. {/* 回收退票 */}
  532. <div
  533. style={{
  534. display:
  535. (this.props.data.processState == 9 ||
  536. this.props.data.processState == 8) &&
  537. (this.props.data.status == 2 || this.props.data.status == 4 || this.props.data.status == 3 || this.props.data.status == 6)
  538. ? "block"
  539. : "none",
  540. }}
  541. >
  542. <h3 style={{ marginLeft: 20, fontWeight: 800, marginBottom: 10 }}>
  543. 回收退票
  544. </h3>
  545. <Table
  546. size="middle"
  547. pagination={false}
  548. bordered
  549. columns={this.state.ContactsLists}
  550. dataSource={this.state.contactList}
  551. />
  552. </div>
  553. {/* 完成审核,上传附件 */}
  554. <div style={{
  555. position: "relative",
  556. display:
  557. ((this.props.data.processState == 8 || this.props.data.processState == 9) &&
  558. (this.props.data.status == 2 || this.props.data.status == 3 || this.props.data.status == 4 || this.props.data.status == 6))
  559. ? "block"
  560. : "none",
  561. marginTop: 10,
  562. }}
  563. >
  564. <hr
  565. style={{
  566. marginTop: 12,
  567. marginBottom: 10,
  568. backgroundColor: "black",
  569. height: 1,
  570. border: "none",
  571. }}
  572. />
  573. <h3
  574. style={{
  575. marginLeft: 20,
  576. fontWeight: 800,
  577. marginBottom: 10,
  578. display: "inline-block",
  579. }}
  580. >
  581. 完成审核,上传附件{" "}
  582. <span
  583. style={{ fontSize: 12, fontWeight: "normal", color: "red" }}
  584. >
  585. (注:由营销员上传变更后附件,全变更流程完成。)
  586. </span>
  587. </h3>
  588. <div>
  589. <Form.Item
  590. label="变更附件"
  591. labelCol={{ span: 4 }}
  592. wrapperCol={{ span: 18 }}
  593. >
  594. <div style={{ paddingTop: '10px', paddingBottom: '10px' }}>
  595. {attachment.length > 0 ? <ImgList domId={this.props.domId + 2 ? this.props.domId + 2 : 'changeDetailJsjl2'} fileList={attachment} ItemWidth={'96px'} /> : '无附件'}
  596. </div>
  597. {/* <Rizhi changeId={this.props.id} /> */}
  598. </Form.Item>
  599. </div>
  600. </div>
  601. {/*
  602. (
  603. <div>
  604. <h3 style={{ marginLeft: 10, fontWeight: 800, marginBottom: 10 }}>
  605. 当前项目进度(咨询师经理填写)
  606. </h3>
  607. {planData.map((item, index) => {
  608. return <Itemlist key={index} pageData={item} />;
  609. })}
  610. </div>
  611. )
  612. */}
  613. {/* {this.props.data.processState >= 4 ? (
  614. ""
  615. ) : (
  616. <div style={{ marginBottom: 10 }}>
  617. <div className="clearfix">
  618. <h3
  619. style={{ marginLeft: 10, fontWeight: 800, marginBottom: 10 }}
  620. >
  621. 当前项目进度(咨询师经理填写)
  622. </h3>
  623. <Form.Item
  624. className="half-item"
  625. label="项目进度"
  626. labelCol={{ span: 8 }}
  627. wrapperCol={{ span: 14 }}
  628. >
  629. <Input
  630. style={{ width: 160 }}
  631. value={this.state.projectState}
  632. placeholder="请输入项目进度"
  633. onChange={e => {
  634. this.setState({
  635. projectState: e.target.value
  636. });
  637. }}
  638. />
  639. </Form.Item>
  640. <Form.Item
  641. className="half-item"
  642. label="发生成本费用(万元)"
  643. labelCol={{ span: 8 }}
  644. wrapperCol={{ span: 14 }}
  645. >
  646. <Input
  647. style={{ width: 160 }}
  648. value={this.state.zxsCost}
  649. placeholder="请输入发生成本费用"
  650. onChange={e => {
  651. this.setState({
  652. zxsCost: e.target.value
  653. });
  654. }}
  655. />
  656. </Form.Item>
  657. </div>
  658. </div>
  659. )} */}
  660. {/* {this.props.data.processState >= 5 ? (
  661. <div>
  662. <h3 style={{ marginLeft: 10, fontWeight: 800, marginBottom: 10 }}>
  663. 当前财务状态(财务填写)
  664. </h3>
  665. {financeData.map((item, index) => {
  666. return <Itemlist key={index} pageData={item} />;
  667. })}
  668. </div>
  669. ) : (
  670. ""
  671. )} */}
  672. <div
  673. style={{
  674. display:
  675. (this.props.data.processState == 8 ||
  676. this.props.data.processState == 9) &&
  677. this.props.data.status == 4 &&
  678. this.props.data.refundStatus
  679. ? "block"
  680. : "none",
  681. }}
  682. >
  683. <Refund data={this.props.data} id={this.props.id} />
  684. </div>
  685. </div>
  686. {
  687. ((this.props.processState == this.props.data.processState) &&
  688. (this.props.data.status == 1 || this.props.data.status == 3)) &&
  689. <div
  690. style={{
  691. display: this.props.data.isExamine == 0 ? "block" : "none",
  692. }}
  693. >
  694. <div style={{ marginBottom: "10px" }}>
  695. <Form.Item
  696. label="备注"
  697. labelCol={{ span: 4 }}
  698. wrapperCol={{ span: 14 }}
  699. >
  700. <Input.TextArea
  701. value={this.state.reason}
  702. rows={4}
  703. placeholder="请输入备注"
  704. onChange={(e) => {
  705. let reason = e.target.value;
  706. this.setState({ reason });
  707. }}
  708. />
  709. </Form.Item>
  710. </div>
  711. <div
  712. className="clearfix"
  713. style={{ display: "flex", justifyContent: "space-around" }}
  714. >
  715. {buttonData.map((item, index) => {
  716. return (
  717. <AgreeButton
  718. data={item}
  719. key={index}
  720. backData={this.props.data}
  721. processState={this.props.processState}
  722. visible={this.changeButtonStatus}
  723. loadData={this.props.loadData}
  724. reason={this.state.reason}
  725. ajaxData={this.state}
  726. rejectState={this.state.rejectState}
  727. onCancel={this.props.onCancel}
  728. />
  729. );
  730. })}
  731. </div>
  732. <div style={{ width: 120, float: "left", position: "relative", bottom: "28px", right: "-600px", }}>
  733. <SelectReject
  734. type={this.props.data.type}
  735. processState={this.props.processState}
  736. onSelect={val => {
  737. this.setState({
  738. rejectState: val
  739. })
  740. }}
  741. />
  742. </div>
  743. {/* <Select
  744. defaultValue="0"
  745. style={{
  746. width: 120,
  747. float: "left",
  748. position: "relative",
  749. bottom: "28px",
  750. right: "-600px",
  751. }}
  752. onChange={(val) => {
  753. this.setState({ rejectState: val });
  754. }}
  755. >
  756. <Option
  757. value="0"
  758. style={{
  759. display: this.props.processState >= 2 ? "block" : "none",
  760. }}
  761. >
  762. 营销员
  763. </Option>
  764. <Option
  765. value="1"
  766. style={{
  767. display: this.props.processState >= 3 ? "block" : "none",
  768. }}
  769. >
  770. 营销管理员
  771. </Option>
  772. <Option
  773. value="2"
  774. style={{
  775. display: this.props.processState >= 4 ? "block" : "none",
  776. }}
  777. >
  778. 咨询师
  779. </Option>
  780. <Option
  781. value="3"
  782. style={{
  783. display: this.props.processState >= 5 ? "block" : "none",
  784. }}
  785. >
  786. 咨询师经理
  787. </Option>
  788. <Option
  789. value="4"
  790. style={{
  791. display: this.props.processState >= 6 ? "block" : "none",
  792. }}
  793. >
  794. 咨询师总监
  795. </Option>
  796. <Option
  797. value="5"
  798. style={{
  799. display: this.props.processState >= 7 ? "block" : "none",
  800. }}
  801. >
  802. 财务专员(退单)
  803. </Option>
  804. <Option
  805. value="6"
  806. style={{
  807. display: this.props.processState >= 8 ? "block" : "none",
  808. }}
  809. >
  810. 财务总监
  811. </Option>
  812. <Option
  813. value="7"
  814. style={{
  815. display: this.props.processState >= 9 ? "block" : "none",
  816. }}
  817. >
  818. 总裁
  819. </Option>
  820. </Select> */}
  821. </div>
  822. }
  823. {/* <ReactToPrint
  824. trigger={() => (
  825. <div className="clearfix">
  826. <Button type="primary" style={{ float: "right", marginTop: 10 }}>
  827. 打印
  828. </Button>
  829. </div>
  830. )}
  831. content={() => this.refs}
  832. /> */}
  833. </div>
  834. );
  835. }
  836. }
  837. export { ChangeDetail };