changeDetailYxgly.js 27 KB

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