changeDetailYxgly.js 23 KB

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