changeDetailCwzj.js 27 KB

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