changeDetailJszj.js 28 KB

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