chargeback.jsx 63 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684
  1. import React from 'react';
  2. import { Button, Input, Spin, Table, message,DatePicker, Upload, Form ,Modal,Col,Tabs, Tag} from 'antd';
  3. import $ from 'jquery/src/ajax';
  4. import Picture from '@/manageCenter/publicComponent/picture';
  5. import ResolutionDetail from "@/resolutionDetail";
  6. import moment from 'moment';
  7. import {
  8. getLiquidationStatus,
  9. getApprovedState,
  10. getProcessStatus,
  11. splitUrl,
  12. getjiedian,
  13. getNewOrderStatus,
  14. getRefundStatus,
  15. getCuikuan,
  16. ShowModal
  17. } from "@/tools.js";
  18. import './customer.less';
  19. import ShowModalDiv from "@/showModal.jsx";
  20. import OrderRiZi from "@/orderRiZi.jsx";
  21. import ImgList from "../../../common/imgList";
  22. import {ChooseList} from "./chooseList";
  23. const IntentionCustomer = Form.create()(
  24. React.createClass({
  25. loadData(pageNo) {
  26. this.setState({
  27. visitModul: false,
  28. loading: true,
  29. ispage: pageNo,
  30. modalVisible: false,
  31. });
  32. $.ajax({
  33. method: "get",
  34. dataType: "json",
  35. crossDomain: false,
  36. url: globalConfig.context + "/api/admin/newOrder/orderRefundList",
  37. data: {
  38. pageNo: pageNo || 1,
  39. pageSize: this.state.pagination.pageSize,
  40. name: this.state.customerName, //名称
  41. orderNo: this.state.orderNo, //订单编号
  42. starTime: this.state.releaseDate[0], //开始时间
  43. endTime: this.state.releaseDate[1], //结束时间
  44. },
  45. success: function (data) {
  46. ShowModal(this);
  47. let theArr = [];
  48. if (data.error.length || data.data.list == "") {
  49. if (data.error && data.error.length) {
  50. message.warning(data.error[0].message);
  51. }
  52. } else {
  53. for (let i = 0; i < data.data.list.length; i++) {
  54. let thisdata = data.data.list[i];
  55. theArr.push({
  56. key: i,
  57. id: thisdata.id, //用户ID
  58. orderNo: thisdata.orderNo, //订单编号
  59. userName: thisdata.userName, //客户名称
  60. orderStatus: thisdata.orderStatus, //订单状态
  61. refundStatus: thisdata.refundStatus, //退单状态
  62. reason: thisdata.reason, //退单原因
  63. createDate: thisdata.createDate, //退单时间
  64. liquidationStatus: thisdata.liquidationStatus, //结算状态
  65. });
  66. }
  67. this.state.pagination.total = data.data.totalCount;
  68. }
  69. if (data.data && data.data.list && !data.data.list.length) {
  70. this.state.pagination.total = 0;
  71. }
  72. this.setState({
  73. dataSource: theArr,
  74. pageNo: pageNo,
  75. pagination: this.state.pagination,
  76. selectedRowKeys: [],
  77. });
  78. }.bind(this),
  79. }).always(
  80. function () {
  81. this.setState({
  82. loading: false,
  83. });
  84. }.bind(this)
  85. );
  86. },
  87. getInitialState() {
  88. return {
  89. rotateDeg: 0,
  90. page: 1,
  91. resVisible: false,
  92. releaseDate: [],
  93. selectedRowKeys: [],
  94. orgCodeUrl: [],
  95. customerArr: [],
  96. applicationUrl: [],
  97. contractUrl: [],
  98. pagination: {
  99. defaultCurrent: 1,
  100. defaultPageSize: 10,
  101. showQuickJumper: true,
  102. pageSize: 10,
  103. onChange: function (page) {
  104. this.loadData(page);
  105. }.bind(this),
  106. showTotal: function (total) {
  107. return "共" + total + "条数据";
  108. },
  109. },
  110. columns: [
  111. {
  112. title: "退单编号",
  113. dataIndex: "id",
  114. key: "id",
  115. },
  116. {
  117. title: "退单日期",
  118. dataIndex: "createDate",
  119. key: "createDate",
  120. },
  121. {
  122. title: "客户名称",
  123. dataIndex: "userName",
  124. key: "userName",
  125. render: (text) => {
  126. return text && text.length > 9 ? text.substr(0, 9) + "..." : text;
  127. },
  128. },
  129. {
  130. title: "订单编号",
  131. dataIndex: "orderNo",
  132. key: "orderNo",
  133. },
  134. {
  135. title: "订单状态",
  136. dataIndex: "orderStatus",
  137. key: "orderStatus",
  138. render: (text) => {
  139. return getNewOrderStatus(text);
  140. },
  141. },
  142. {
  143. title: "结算状态",
  144. dataIndex: "liquidationStatus",
  145. key: "liquidationStatus",
  146. render: (text) => {
  147. return getLiquidationStatus(text);
  148. },
  149. },
  150. {
  151. title: "退单状态",
  152. dataIndex: "refundStatus",
  153. key: "refundStatus",
  154. render: (text) => {
  155. return getRefundStatus(text);
  156. },
  157. },
  158. {
  159. title: "退单原因",
  160. dataIndex: "reason",
  161. key: "reason",
  162. render: (text) => {
  163. return text && text.length > 18
  164. ? text.substr(0, 18) + "..."
  165. : text;
  166. },
  167. },
  168. {
  169. title: "操作",
  170. dataIndex: "abc",
  171. key: "abc",
  172. render: (text, record) => {
  173. return (
  174. <div>
  175. <Button
  176. onClick={(e) => {
  177. e.stopPropagation(), this.visit(record);
  178. }}
  179. type="primary"
  180. >
  181. {this.state.refundStatus == 2
  182. ? "修改退单申请"
  183. : "查看退款申请"}
  184. </Button>
  185. </div>
  186. );
  187. },
  188. },
  189. ],
  190. data: [],
  191. dataSource: [],
  192. columnsX: [
  193. {
  194. title: "业务项目名称",
  195. dataIndex: "commodityName",
  196. key: "commodityName",
  197. render: (text, record) => {
  198. return text + "-" + record.id
  199. }
  200. },
  201. {
  202. title: "项目类别",
  203. dataIndex: "cname",
  204. key: "cname",
  205. },
  206. {
  207. title: "项目数量",
  208. dataIndex: "commodityQuantity",
  209. key: "commodityQuantity",
  210. render: (text, record) => {
  211. if (record.splitStatus == 1) {
  212. return (
  213. <span>
  214. {text}{" "}
  215. <Tag
  216. color="#108ee9"
  217. onClick={(e) => {
  218. e.stopPropagation();
  219. this.showRes(record);
  220. }}
  221. >
  222. 已拆
  223. </Tag>
  224. </span>
  225. );
  226. } else {
  227. return text;
  228. }
  229. },
  230. },
  231. {
  232. title: "金额(万元)",
  233. dataIndex: "commodityPrice",
  234. key: "commodityPrice",
  235. },
  236. {
  237. title: "负责人",
  238. dataIndex: "contacts",
  239. key: "contacts",
  240. },
  241. {
  242. title: "负责人电话",
  243. dataIndex: "contactsMobile",
  244. key: "contactsMobile",
  245. },
  246. {
  247. title: "主要项目",
  248. dataIndex: "main",
  249. key: "main",
  250. render: (text) => {
  251. return text ? "是" : "否";
  252. },
  253. },
  254. {
  255. title: "项目说明",
  256. dataIndex: "taskComment",
  257. key: "taskComment",
  258. render: (text) => {
  259. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  260. },
  261. },
  262. ],
  263. columnsrizhi: [
  264. {
  265. title: "流程",
  266. dataIndex: "processName",
  267. key: "processName",
  268. },
  269. {
  270. title: "操作人",
  271. dataIndex: "adminName",
  272. key: "adminName",
  273. },
  274. {
  275. title: "时间",
  276. dataIndex: "createDate",
  277. key: "createDate",
  278. },
  279. ],
  280. dataSourceX: [],
  281. ContactsListsNew: [
  282. {
  283. title: "项目名称",
  284. dataIndex: "commodityName",
  285. key: "commodityName",
  286. render: (text, record) => {
  287. return <span>{text + "-" + record.tid}</span>;
  288. },
  289. },
  290. {
  291. title: "项目分类",
  292. dataIndex: "projectType",
  293. key: "projectType",
  294. render: (text) => {
  295. let arr = this.state.dataSourceX || [];
  296. let str = "";
  297. for (let i = 0; i < arr.length; i++) {
  298. if (this.state.dataSourceX[i].sort == text) {
  299. str = this.state.dataSourceX[i].cname;
  300. return <span>{str}</span>;
  301. }
  302. }
  303. },
  304. },
  305. {
  306. title: "催款科目",
  307. dataIndex: "dunTypeName",
  308. key: "dunTypeName",
  309. render: (text) => {
  310. if(record.customizeName) {
  311. return text + record.customizeName;
  312. }
  313. return <span>{text}</span>;
  314. },
  315. },
  316. {
  317. title: "时间(天)",
  318. dataIndex: "waitDay",
  319. key: "waitDay",
  320. render: (text, record) => {
  321. if (record.dunTypeName) {
  322. if (record.customizeTimes) {
  323. return record.customizeTimes;
  324. }
  325. return <span>{text}</span>;
  326. }
  327. },
  328. },
  329. {
  330. title: "金额(万元)",
  331. dataIndex: "money",
  332. key: "money",
  333. render: (text, record) => {
  334. if (record.dunTypeName) {
  335. if (record.appropriationRatio && !record.money) {
  336. return <span>{record.appropriationRatio}(拨款比例)</span>;
  337. } else if (record.appropriationRatio && record.money) {
  338. return (
  339. <span>
  340. {text}(比例:{record.appropriationRatio})
  341. </span>
  342. );
  343. } else {
  344. return <span>{text}</span>;
  345. }
  346. }
  347. },
  348. },
  349. {
  350. title: "服务年限",
  351. dataIndex: "startDate",
  352. key: "startDate",
  353. render: (text, record) => {
  354. if (record.dunTypeName) {
  355. return <span>{text}</span>;
  356. }
  357. },
  358. },
  359. {
  360. title: "催款状态",
  361. dataIndex: "status",
  362. key: "status",
  363. render: (text) => {
  364. return <span>{text == 1 ? "已启动" : "未启动"}</span>;
  365. },
  366. },
  367. ],
  368. ContactsLists: [
  369. {
  370. title: "催款科目",
  371. dataIndex: "dunSubject",
  372. key: "dunSubject",
  373. render: (text) => {
  374. return getjiedian(text);
  375. },
  376. },
  377. {
  378. title: "金额(万元)",
  379. dataIndex: "money",
  380. key: "money",
  381. },
  382. {
  383. title: "催款状态",
  384. dataIndex: "dunStatus",
  385. key: "dunStatus",
  386. render: (text) => {
  387. return getCuikuan(text);
  388. },
  389. },
  390. ],
  391. };
  392. },
  393. //进入新增拜访记录
  394. visit(record) {
  395. this.setState({
  396. addnextVisible: true,
  397. });
  398. this.tuidanxiangqing(record.id);
  399. },
  400. //退单详情
  401. tuidanxiangqing(id) {
  402. this.setState({
  403. loading: true,
  404. });
  405. $.ajax({
  406. method: "get",
  407. dataType: "json",
  408. crossDomain: false,
  409. url: globalConfig.context + "/api/admin/newOrder/orderRefundDetail",
  410. data: {
  411. id: id,
  412. },
  413. }).done(
  414. function (data) {
  415. if (data.error.length || data.data.list == "") {
  416. if (data.error && data.error.length) {
  417. message.warning(data.error[0].message);
  418. }
  419. } else {
  420. let thisdata = data.data;
  421. this.setState({
  422. id: thisdata.id,
  423. createDate: thisdata.createDate, //退单时间
  424. orderNo: thisdata.orderNo, //订单编号
  425. orderStatus: thisdata.orderStatus, //订单状态
  426. refundStatus: thisdata.refundStatus, //退单状态
  427. applicationUrl: thisdata.applicationUrl
  428. ? splitUrl(
  429. thisdata.applicationUrl,
  430. ",",
  431. globalConfig.avatarHost + "/upload"
  432. )
  433. : [], //申请表附件
  434. contractUrl: thisdata.contractUrl
  435. ? splitUrl(
  436. thisdata.contractUrl,
  437. ",",
  438. globalConfig.avatarHost + "/upload"
  439. )
  440. : [], //合同附件
  441. reason: thisdata.reason, //退单原因
  442. liquidationStatus: thisdata.liquidationStatus, //结算状态
  443. });
  444. this.setState({
  445. loading: false,
  446. });
  447. }
  448. }.bind(this)
  449. );
  450. },
  451. // 拆分详细
  452. showRes(record) {
  453. this.setState({
  454. resVisible: true,
  455. resRecord: record,
  456. });
  457. },
  458. resCancel() {
  459. this.setState({
  460. resVisible: false,
  461. });
  462. },
  463. //点击确认退单
  464. tuidanOk() {
  465. let contractUrls = [];
  466. let applicationUrls = [];
  467. if (this.state.contractUrl.length) {
  468. let picArr = [];
  469. this.state.contractUrl.map(function (item) {
  470. if (
  471. item.response &&
  472. item.response.data &&
  473. item.response.data.length
  474. ) {
  475. picArr.push(item.response.data);
  476. }
  477. });
  478. contractUrls = picArr.join(",");
  479. }
  480. if (this.state.applicationUrl.length) {
  481. let picArr = [];
  482. this.state.applicationUrl.map(function (item) {
  483. if (
  484. item.response &&
  485. item.response.data &&
  486. item.response.data.length
  487. ) {
  488. picArr.push(item.response.data);
  489. }
  490. });
  491. applicationUrls = picArr.join(",");
  492. }
  493. $.ajax({
  494. method: "POST",
  495. dataType: "json",
  496. crossDomain: false,
  497. url: globalConfig.context + "/api/admin/newOrder/updateOrderRefund",
  498. data: {
  499. id: this.state.id, //订单编号
  500. contractUrl: contractUrls.length ? contractUrls : "", //终止合同
  501. applicationUrl: applicationUrls.length ? applicationUrls : "", //退单申请表
  502. reason: this.state.reason, //退单原因
  503. },
  504. }).done(
  505. function (data) {
  506. this.setState({
  507. loading: false,
  508. });
  509. if (!data.error.length) {
  510. message.success("退单成功!");
  511. this.nextCancel();
  512. this.handleCancel();
  513. } else {
  514. message.warning(data.error[0].message);
  515. }
  516. }.bind(this)
  517. );
  518. },
  519. //页面加载函数
  520. componentWillMount() {
  521. this.loadData();
  522. },
  523. //整行点击
  524. tableRowClick(record) {
  525. this.setState({
  526. visible: true,
  527. });
  528. this.xiangqing(record.orderNo);
  529. this.xiangmu(record.orderNo);
  530. this.jiedian(record.orderNo);
  531. this.jiedianNew(record.orderNo);
  532. },
  533. rizhi() {
  534. console.log(this.state.orderNo);
  535. this.setState({
  536. loading: true,
  537. });
  538. $.ajax({
  539. method: "get",
  540. dataType: "json",
  541. crossDomain: false,
  542. url: "/api/admin/newOrder/selectOrderLog",
  543. data: {
  544. orderNo: this.state.orderNo,
  545. },
  546. success: function (data) {
  547. let theArr = [];
  548. let thisData = data.data;
  549. if (!thisData.length) {
  550. if (data.error && data.error.length) {
  551. message.warning(data.error[0].message);
  552. }
  553. thisData = {};
  554. } else {
  555. for (let i = 0; i < data.data.length; i++) {
  556. let thisdata = data.data[i];
  557. theArr.push({
  558. processName: thisdata.processName,
  559. adminName: thisdata.adminName,
  560. createDate: thisdata.createDate,
  561. remarks: thisdata.remarks,
  562. });
  563. }
  564. }
  565. this.setState({
  566. dataSourcerizhi: theArr,
  567. });
  568. }.bind(this),
  569. }).always(
  570. function () {
  571. this.setState({
  572. loading: false,
  573. });
  574. }.bind(this)
  575. );
  576. },
  577. //查看订单日志
  578. getOrderLog() {
  579. this.setState({
  580. rizhivisible: true,
  581. });
  582. this.rizhi();
  583. },
  584. closeOrderLog() {
  585. this.setState({
  586. rizhivisible: false,
  587. });
  588. },
  589. //详情关闭
  590. nextCancel() {
  591. this.setState({
  592. addnextVisible: false,
  593. });
  594. this.resets();
  595. },
  596. //订单详情
  597. xiangqing(orderNos) {
  598. $.ajax({
  599. method: "get",
  600. dataType: "json",
  601. crossDomain: false,
  602. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  603. data: {
  604. orderNo: orderNos,
  605. },
  606. success: function (data) {
  607. if (data.error.length || data.data.list == "") {
  608. if (data.error && data.error.length) {
  609. message.warning(data.error[0].message);
  610. }
  611. } else {
  612. let thisdata = data.data;
  613. this.setState({
  614. id: thisdata.id,
  615. kehuId: thisdata.buyerId,
  616. orderNo: thisdata.orderNo, //订单编号
  617. contractNo: thisdata.contractNo, //合同编号
  618. userName: thisdata.userName, //客户名称
  619. signDate: thisdata.signDate, //签单时间
  620. processStatus: thisdata.processStatus, //流程状态
  621. liquidationStatus: thisdata.liquidationStatus, //结算状态
  622. contacts: thisdata.contacts, //企业联系人
  623. contactMobile: thisdata.contactMobile, //联系人电话
  624. legalPerson: thisdata.legalPerson, //法人
  625. legalPersonTel: thisdata.legalPersonTel, //法人电话
  626. firstAmount: thisdata.firstAmount, //签单金额
  627. totalAmount: thisdata.totalAmount, //首付金额
  628. settlementAmount: thisdata.settlementAmount, //已收款项
  629. orderRemarks: thisdata.orderRemarks, //订单留言
  630. orgCodeUrl: thisdata.contractPictureUrl
  631. ? splitUrl(
  632. thisdata.contractPictureUrl,
  633. ",",
  634. globalConfig.avatarHost + "/upload"
  635. )
  636. : [], //图片地址
  637. replenishUrl: thisdata.agreementUrl
  638. ? splitUrl(
  639. thisdata.agreementUrl,
  640. ",",
  641. globalConfig.avatarHost + "/upload"
  642. )
  643. : [],
  644. salesmanName: thisdata.salesmanName, //营销员名称
  645. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  646. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  647. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  648. financeName: thisdata.financeName, //财务名称
  649. financeMobile: thisdata.financeMobile, //财务电话
  650. nowFinance: thisdata.nowFinance, //财务名称
  651. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  652. approval: thisdata.approval.toString(), //特批状态
  653. //approval:thisdata.approval==0?thisdata.approval.toString():thisdata.approval,//特批状态
  654. });
  655. }
  656. }.bind(this),
  657. }).always(
  658. function () {
  659. this.setState({
  660. loading: false,
  661. });
  662. }.bind(this)
  663. );
  664. },
  665. //项目列表
  666. xiangmu(orderNos) {
  667. $.ajax({
  668. method: "get",
  669. dataType: "json",
  670. crossDomain: false,
  671. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  672. data: {
  673. orderNo: orderNos,
  674. },
  675. success: function (data) {
  676. let theArr = [];
  677. if (data.error.length || data.data.list == "") {
  678. if (data.error && data.error.length) {
  679. message.warning(data.error[0].message);
  680. }
  681. } else {
  682. for (let i = 0; i < data.data.length; i++) {
  683. let thisdata = data.data[i];
  684. thisdata.key = i;
  685. thisdata.sort = thisdata.cSort;
  686. theArr.push(thisdata);
  687. }
  688. }
  689. this.setState({
  690. dataSourceX: theArr,
  691. paginations: false,
  692. });
  693. }.bind(this),
  694. }).always(
  695. function () {
  696. this.setState({
  697. loading: false,
  698. });
  699. }.bind(this)
  700. );
  701. },
  702. //节点列表
  703. // jiedian(orderNos) {
  704. // $.ajax({
  705. // method: "get",
  706. // dataType: "json",
  707. // crossDomain: false,
  708. // url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  709. // data: {
  710. // orderNo: orderNos,
  711. // },
  712. // success: function (data) {
  713. // let theArr = [];
  714. // let thisData = [];
  715. // if (data.error.length || data.data.list == "") {
  716. // if (data.error && data.error.length) {
  717. // message.warning(data.error[0].message);
  718. // }
  719. // } else {
  720. // for (let i = 0; i < data.data.length; i++) {
  721. // thisData = data.data[i];
  722. // theArr.push({
  723. // key: i,
  724. // dunSubject: thisData.dunSubject
  725. // ? thisData.dunSubject.toString()
  726. // : "", //催款科目
  727. // id: thisData.id, //节点Id
  728. // money: thisData.money, //催款金额
  729. // dunStatus: thisData.dunStatus, //催款状态
  730. // orderNo: thisData.orderNo,
  731. // });
  732. // }
  733. // this.setState({
  734. // contactList: theArr,
  735. // });
  736. // }
  737. // }.bind(this),
  738. // }).always(
  739. // function () {
  740. // this.setState({
  741. // loading: false,
  742. // });
  743. // }.bind(this)
  744. // );
  745. // },
  746. //查看催款节点
  747. jiedianNew(orderNos) {
  748. $.ajax({
  749. method: "get",
  750. dataType: "json",
  751. crossDomain: false,
  752. url:
  753. globalConfig.context + "/api/admin/newOrderDun/selectListNewOrderDun",
  754. data: {
  755. orderNo: orderNos,
  756. },
  757. success: function (data) {
  758. if (data.error && data.error.length) {
  759. message.warning(data.error[0].message);
  760. } else {
  761. let theArr = [];
  762. let thisData = [];
  763. let arr = data.data || [];
  764. let totalCui = 0;
  765. for (let i = 0; i < arr.length; i++) {
  766. thisData = arr[i];
  767. totalCui += +thisData.money;
  768. theArr.push({
  769. key: i,
  770. dunSubject: thisData.dunSubject
  771. ? thisData.dunSubject.toString()
  772. : "", //催款科目
  773. id: thisData.id, //节点Id
  774. money: thisData.money, //催款金额
  775. // orderNo: record ? record.orderNo : this.props.datauser.orderNo,
  776. commodityName: thisData.commodityName,
  777. projectType: thisData.projectType,
  778. dunTypeName: thisData.dunTypeName,
  779. status: thisData.status,
  780. waitDay: thisData.waitDay,
  781. effectiveCount: thisData.effectiveCount,
  782. startDate: thisData.startDate,
  783. dunType: thisData.dunType,
  784. appropriationRatio: thisData.appropriationRatio,
  785. customizeTimes: thisData.customizeTimes,
  786. customizeName: thisData.customizeName,
  787. tid: thisData.tid,
  788. });
  789. }
  790. if (!totalCui) {
  791. totalCui = 0;
  792. }
  793. totalCui = (Math.round(totalCui * 1000000) / 1000000).toFixed(6);
  794. this.setState({
  795. contactListNew: theArr,
  796. totalCui,
  797. });
  798. }
  799. }.bind(this),
  800. }).always(
  801. function () {
  802. this.setState({
  803. loading: false,
  804. });
  805. }.bind(this)
  806. );
  807. },
  808. downImg() {
  809. let num = 0;
  810. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  811. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  812. num = i;
  813. }
  814. }
  815. if (num == this.state.orgCodeUrl.length - 1) {
  816. return message.warning("已经是最后一张了哦");
  817. }
  818. this.state.previewImage = this.state.orgCodeUrl[num + 1].url;
  819. this.setState({
  820. previewImage: this.state.previewImage,
  821. rotateDeg: 0,
  822. });
  823. },
  824. upImg() {
  825. let num = 0;
  826. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  827. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  828. num = i;
  829. }
  830. }
  831. if (num == 0) {
  832. return message.warning("已经是第一张了哦");
  833. }
  834. this.state.previewImage = this.state.orgCodeUrl[num - 1].url;
  835. this.setState({
  836. previewImage: this.state.previewImage,
  837. rotateDeg: 0,
  838. });
  839. },
  840. rotate() {
  841. let rotateDeg = this.state.rotateDeg + 90;
  842. this.setState({
  843. rotateDeg,
  844. });
  845. },
  846. downImgs() {
  847. let num = 0;
  848. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  849. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  850. num = i;
  851. }
  852. }
  853. if (num == this.state.replenishUrl.length - 1) {
  854. return message.warning("已经是最后一张了哦");
  855. }
  856. this.state.previewImage = this.state.replenishUrl[num + 1].url;
  857. this.setState({
  858. previewImage: this.state.previewImage,
  859. rotateDeg: 0,
  860. });
  861. },
  862. upImgs() {
  863. let num = 0;
  864. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  865. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  866. num = i;
  867. }
  868. }
  869. if (num == 0) {
  870. return message.warning("已经是第一张了哦");
  871. }
  872. this.state.previewImage = this.state.replenishUrl[num - 1].url;
  873. this.setState({
  874. previewImage: this.state.previewImage,
  875. rotateDeg: 0,
  876. });
  877. },
  878. rotates() {
  879. let rotateDeg = this.state.rotateDeg + 90;
  880. this.setState({
  881. rotateDeg,
  882. });
  883. },
  884. resets() {
  885. this.state.orderNo = "";
  886. this.state.customerName = "";
  887. this.state.releaseDate[0] = undefined;
  888. this.state.releaseDate[1] = undefined;
  889. },
  890. reset() {
  891. this.state.orderNo = "";
  892. this.state.customerName = "";
  893. this.state.releaseDate[0] = undefined;
  894. this.state.releaseDate[1] = undefined;
  895. this.loadData();
  896. },
  897. //搜索
  898. search() {
  899. this.setState({
  900. //signBillVisible:false
  901. });
  902. this.loadData();
  903. },
  904. getOrgCodeUrl(e) {
  905. this.setState({ orgCodeUrl: e });
  906. },
  907. getReplenishUrl(e) {
  908. this.setState({ replenishUrl: e });
  909. },
  910. //关闭详情
  911. visitCancel() {
  912. this.setState({
  913. visible: false,
  914. });
  915. this.resets();
  916. },
  917. visitOk() {
  918. this.setState({
  919. visible: false,
  920. });
  921. this.resets();
  922. },
  923. changeList(arr) {
  924. const newArr = [];
  925. this.state.columns.forEach(item => {
  926. arr.forEach(val => {
  927. if (val === item.title) {
  928. newArr.push(item);
  929. }
  930. });
  931. });
  932. this.setState({
  933. changeList: newArr
  934. });
  935. },
  936. render() {
  937. const formItemLayout = {
  938. labelCol: { span: 8 },
  939. wrapperCol: { span: 14 },
  940. };
  941. const FormItem = Form.Item;
  942. const { RangePicker } = DatePicker;
  943. const cuiDataList = this.state.contactList || [];
  944. const rowSelection = {
  945. selectedRowKeys: this.state.selectedRowKeys,
  946. onChange: (selectedRowKeys, selectedRows) => {
  947. this.setState({
  948. modalVisible: false,
  949. selectedRows: selectedRows.slice(-1),
  950. selectedRowKeys: selectedRowKeys.slice(-1),
  951. });
  952. },
  953. onSelect: (recordt) => {
  954. this.setState({
  955. modalVisible: false,
  956. recordt: recordt.id,
  957. });
  958. },
  959. };
  960. const { TabPane } = Tabs;
  961. return (
  962. <div className="user-content">
  963. {this.state.resVisible ? (
  964. <ResolutionDetail
  965. cancel={this.resCancel}
  966. detail={this.state.resRecord}
  967. visible={this.state.resVisible}
  968. id={this.state.resRecord.orderNo}
  969. />
  970. ) : (
  971. ""
  972. )}
  973. <ShowModalDiv ShowModal={this.state.showModal} />
  974. <div className="content-title">
  975. <span>退单管理</span>
  976. </div>
  977. <div className="user-search">
  978. <Tabs
  979. defaultActiveKey="1"
  980. onChange={this.callback}
  981. className="test"
  982. >
  983. <TabPane tab="搜索" key="1">
  984. <Input
  985. placeholder="客户名称"
  986. style={{
  987. width: "150px",
  988. marginBottom: "10px",
  989. marginTop: 10,
  990. marginRight: 10,
  991. marginLeft: 10,
  992. }}
  993. value={this.state.customerName}
  994. onChange={(e) => {
  995. this.setState({ customerName: e.target.value });
  996. }}
  997. />
  998. <Input
  999. placeholder="订单编号"
  1000. style={{ width: "150px", marginRight: 10 }}
  1001. value={this.state.orderNo}
  1002. onChange={(e) => {
  1003. this.setState({ orderNo: e.target.value });
  1004. }}
  1005. />
  1006. <span style={{ marginRight: "10px" }}>下单时间 :</span>
  1007. <RangePicker
  1008. value={[
  1009. this.state.releaseDate[0]
  1010. ? moment(this.state.releaseDate[0])
  1011. : null,
  1012. this.state.releaseDate[1]
  1013. ? moment(this.state.releaseDate[1])
  1014. : null,
  1015. ]}
  1016. onChange={(data, dataString) => {
  1017. this.setState({ releaseDate: dataString });
  1018. }}
  1019. />
  1020. <Button
  1021. type="primary"
  1022. onClick={this.search}
  1023. style={{ marginLeft: "10px", marginRight: 10 }}
  1024. >
  1025. 搜索
  1026. </Button>
  1027. <Button onClick={this.reset}>重置</Button>
  1028. </TabPane>
  1029. <TabPane tab="更改表格显示数据" key="2">
  1030. <div style={{ marginLeft: 10 }}>
  1031. <ChooseList
  1032. columns={this.state.columns}
  1033. changeFn={this.changeList}
  1034. changeList={this.state.changeList}
  1035. top={55}
  1036. margin={11}
  1037. />
  1038. </div>
  1039. </TabPane>
  1040. </Tabs>
  1041. <div className="patent-table">
  1042. <Spin spinning={this.state.loading}>
  1043. <Table
  1044. columns={
  1045. this.state.changeList
  1046. ? this.state.changeList
  1047. : this.state.columns
  1048. }
  1049. dataSource={this.state.dataSource}
  1050. // rowSelection={rowSelection}
  1051. pagination={this.state.pagination}
  1052. onRowClick={this.tableRowClick}
  1053. bordered
  1054. size="small"
  1055. />
  1056. </Spin>
  1057. </div>
  1058. {this.state.visible ? <Modal
  1059. maskClosable={false}
  1060. className="customeDetails"
  1061. footer=""
  1062. title="订单详情"
  1063. width="900px"
  1064. visible={this.state.visible}
  1065. onOk={this.visitOk}
  1066. onCancel={this.visitCancel}
  1067. >
  1068. <Form
  1069. layout="horizontal"
  1070. onSubmit={this.handleSubmit}
  1071. id="demand-form"
  1072. style={{ paddingBottom: "40px" }}
  1073. >
  1074. <Spin spinning={this.state.loading}>
  1075. <div className="clearfix">
  1076. <FormItem
  1077. className="half-item"
  1078. {...formItemLayout}
  1079. label="订单编号"
  1080. >
  1081. <span>{this.state.orderNo}</span>
  1082. </FormItem>
  1083. <FormItem
  1084. className="half-item"
  1085. {...formItemLayout}
  1086. label="合同编号"
  1087. >
  1088. <span>{this.state.contractNo}</span>
  1089. </FormItem>
  1090. <FormItem
  1091. className="half-item"
  1092. {...formItemLayout}
  1093. label="客户名称"
  1094. >
  1095. <span>{this.state.userName}</span>
  1096. </FormItem>
  1097. <FormItem
  1098. className="half-item"
  1099. {...formItemLayout}
  1100. label="合同签订时间"
  1101. >
  1102. <span>{this.state.signDate}</span>
  1103. </FormItem>
  1104. <FormItem
  1105. className="half-item"
  1106. {...formItemLayout}
  1107. label="流程状态"
  1108. >
  1109. <span>{getProcessStatus(this.state.processStatus)}</span>
  1110. </FormItem>
  1111. <FormItem
  1112. className="half-item"
  1113. {...formItemLayout}
  1114. label="结算状态"
  1115. >
  1116. <span>
  1117. {getLiquidationStatus(this.state.liquidationStatus)}
  1118. </span>
  1119. </FormItem>
  1120. <FormItem
  1121. className="half-item"
  1122. {...formItemLayout}
  1123. label="企业联系人"
  1124. >
  1125. <span>{this.state.contacts}</span>
  1126. </FormItem>
  1127. <FormItem
  1128. className="half-item"
  1129. {...formItemLayout}
  1130. label="联系人电话"
  1131. >
  1132. <span>{this.state.contactMobile}</span>
  1133. </FormItem>
  1134. <FormItem
  1135. className="half-item"
  1136. {...formItemLayout}
  1137. label="企业法人"
  1138. >
  1139. <span>{this.state.legalPerson}</span>
  1140. </FormItem>
  1141. <FormItem
  1142. className="half-item"
  1143. {...formItemLayout}
  1144. label="法人电话"
  1145. >
  1146. <span>{this.state.legalPersonTel}</span>
  1147. </FormItem>
  1148. <FormItem
  1149. className="half-item"
  1150. {...formItemLayout}
  1151. label="签单金额(万元)"
  1152. >
  1153. <span>{this.state.firstAmount}</span>
  1154. </FormItem>
  1155. <FormItem
  1156. className="half-item"
  1157. {...formItemLayout}
  1158. label="首付金额(万元)"
  1159. >
  1160. <span>{this.state.totalAmount}</span>
  1161. </FormItem>
  1162. <FormItem
  1163. className="half-item"
  1164. {...formItemLayout}
  1165. label="特批立项"
  1166. >
  1167. <span>{getApprovedState(this.state.approval)}</span>
  1168. </FormItem>
  1169. <FormItem
  1170. className="half-item"
  1171. {...formItemLayout}
  1172. label="已收款项(万元)"
  1173. >
  1174. <span>{this.state.settlementAmount}</span>
  1175. </FormItem>
  1176. <div className="clearfix">
  1177. <FormItem
  1178. labelCol={{ span: 4 }}
  1179. wrapperCol={{ span: 16 }}
  1180. label="订单留言"
  1181. >
  1182. <span>{this.state.orderRemarks}</span>
  1183. </FormItem>
  1184. </div>
  1185. <div className="clearfix">
  1186. <FormItem
  1187. labelCol={{ span: 4 }}
  1188. wrapperCol={{ span: 18 }}
  1189. label="合同扫描件"
  1190. >
  1191. {/*<Upload*/}
  1192. {/* className="demandDetailShow-upload"*/}
  1193. {/* listType="picture-card"*/}
  1194. {/* fileList={this.state.orgCodeUrl}*/}
  1195. {/* onPreview={(file) => {*/}
  1196. {/* this.setState({*/}
  1197. {/* previewImage: file.url || file.thumbUrl,*/}
  1198. {/* previewVisible: true,*/}
  1199. {/* });*/}
  1200. {/* }}*/}
  1201. {/*/>*/}
  1202. <div style={{paddingTop:'10px',paddingBottom:'10px'}}>
  1203. {this.state.visible && this.state.orgCodeUrl ? <ImgList fileList={this.state.orgCodeUrl} ItemWidth={'96px'}/> : <div/>}
  1204. </div>
  1205. <Modal
  1206. maskClosable={false}
  1207. footer={null}
  1208. width={"50%"}
  1209. visible={this.state.previewVisible}
  1210. onCancel={() => {
  1211. this.setState({
  1212. previewVisible: false,
  1213. rotateDeg: 0,
  1214. });
  1215. }}
  1216. >
  1217. <img
  1218. alt=""
  1219. style={{
  1220. width: "100%",
  1221. transform: `rotate(${this.state.rotateDeg}deg)`,
  1222. }}
  1223. src={this.state.previewImage || ""}
  1224. />
  1225. <Button
  1226. onClick={this.rotate}
  1227. style={{
  1228. position: "relative",
  1229. left: "50%",
  1230. transform: "translateX(-50%)",
  1231. }}
  1232. >
  1233. 旋转
  1234. </Button>
  1235. <Button
  1236. onClick={this.upImg}
  1237. style={{
  1238. position: "absolute",
  1239. left: -81,
  1240. top: "50%",
  1241. transform: "translateY(-50%)",
  1242. }}
  1243. >
  1244. 上一张
  1245. </Button>
  1246. <Button
  1247. onClick={this.downImg}
  1248. style={{
  1249. position: "absolute",
  1250. right: -81,
  1251. top: "50%",
  1252. transform: "translateY(-50%)",
  1253. }}
  1254. >
  1255. 下一张
  1256. </Button>
  1257. </Modal>
  1258. <Button
  1259. style={{
  1260. float: "right",
  1261. marginRight: "140px",
  1262. marginTop: "20px",
  1263. }}
  1264. onClick={this.getOrderLog}
  1265. >
  1266. 查看订单 日志
  1267. </Button>
  1268. </FormItem>
  1269. <FormItem
  1270. labelCol={{ span: 4 }}
  1271. wrapperCol={{ span: 18 }}
  1272. label="补充协议"
  1273. >
  1274. {/*<Upload*/}
  1275. {/* className="demandDetailShow-upload"*/}
  1276. {/* listType="picture-card"*/}
  1277. {/* fileList={this.state.replenishUrl}*/}
  1278. {/* onPreview={(file) => {*/}
  1279. {/* this.setState({*/}
  1280. {/* previewImage: file.url || file.thumbUrl,*/}
  1281. {/* previewVisibles: true,*/}
  1282. {/* });*/}
  1283. {/* }}*/}
  1284. {/*/>*/}
  1285. <div style={{paddingTop:'10px',paddingBottom:'10px'}}>
  1286. {this.state.visible && this.state.replenishUrl ? <ImgList domId={'chargeback1'} fileList={this.state.replenishUrl}/> : <div/>}
  1287. </div>
  1288. <Modal
  1289. maskClosable={false}
  1290. footer={null}
  1291. width={"50%"}
  1292. visible={this.state.previewVisibles}
  1293. onCancel={() => {
  1294. this.setState({ previewVisibles: false, rotateDeg: 0, });
  1295. }}
  1296. >
  1297. <img
  1298. alt=""
  1299. style={{
  1300. width: "100%",
  1301. transform: `rotate(${this.state.rotateDeg}deg)`,
  1302. }}
  1303. src={this.state.previewImage || ""}
  1304. />
  1305. <Button
  1306. onClick={this.rotates}
  1307. style={{
  1308. position: "relative",
  1309. left: "50%",
  1310. transform: "translateX(-50%)",
  1311. }}
  1312. >
  1313. 旋转
  1314. </Button>
  1315. <Button
  1316. onClick={this.upImgs}
  1317. style={{
  1318. position: "absolute",
  1319. left: -81,
  1320. top: "50%",
  1321. transform: "translateY(-50%)",
  1322. }}
  1323. >
  1324. 上一张
  1325. </Button>
  1326. <Button
  1327. onClick={this.downImgs}
  1328. style={{
  1329. position: "absolute",
  1330. right: -81,
  1331. top: "50%",
  1332. transform: "translateY(-50%)",
  1333. }}
  1334. >
  1335. 下一张
  1336. </Button>
  1337. </Modal>
  1338. </FormItem>
  1339. </div>
  1340. <div className="clearfix">
  1341. <FormItem
  1342. className="half-item"
  1343. {...formItemLayout}
  1344. label="订单负责人"
  1345. >
  1346. <span>{this.state.salesmanName}</span>
  1347. </FormItem>
  1348. <FormItem
  1349. className="half-item"
  1350. {...formItemLayout}
  1351. label="订单负责人电话"
  1352. >
  1353. <span>{this.state.salesmanMobile}</span>
  1354. </FormItem>
  1355. </div>
  1356. <div className="clearfix">
  1357. <FormItem
  1358. className="half-item"
  1359. {...formItemLayout}
  1360. label="当前财务负责人"
  1361. >
  1362. <span>{this.state.nowFinance}</span>
  1363. </FormItem>
  1364. <FormItem
  1365. className="half-item"
  1366. {...formItemLayout}
  1367. label="当前财务负责人电话"
  1368. >
  1369. <span>{this.state.nowFinanceMobile}</span>
  1370. </FormItem>
  1371. </div>
  1372. {/*<div className="clearfix">*/}
  1373. {/* <FormItem*/}
  1374. {/* className="half-item"*/}
  1375. {/* {...formItemLayout}*/}
  1376. {/* style={{ opacity: ".5" }}*/}
  1377. {/* label="原订单负责人"*/}
  1378. {/* >*/}
  1379. {/* <span>{this.state.oldSalesmanName}</span>*/}
  1380. {/* </FormItem>*/}
  1381. {/* <FormItem*/}
  1382. {/* className="half-item"*/}
  1383. {/* {...formItemLayout}*/}
  1384. {/* style={{ opacity: ".5" }}*/}
  1385. {/* label="原订单负责人电话"*/}
  1386. {/* >*/}
  1387. {/* <span>{this.state.oldSalesmanMobile}</span>*/}
  1388. {/* </FormItem>*/}
  1389. {/*</div>*/}
  1390. {/*<div className="clearfix">*/}
  1391. {/* <FormItem*/}
  1392. {/* className="half-item"*/}
  1393. {/* style={{ opacity: ".5" }}*/}
  1394. {/* {...formItemLayout}*/}
  1395. {/* label="实际财务操作人"*/}
  1396. {/* >*/}
  1397. {/* <span>{this.state.financeName}</span>*/}
  1398. {/* </FormItem>*/}
  1399. {/* <FormItem*/}
  1400. {/* className="half-item"*/}
  1401. {/* {...formItemLayout}*/}
  1402. {/* style={{ opacity: ".5" }}*/}
  1403. {/* label="实际财务操作人电话"*/}
  1404. {/* >*/}
  1405. {/* <span>{this.state.financeMobile}</span>*/}
  1406. {/* </FormItem>*/}
  1407. {/*</div>*/}
  1408. <div>
  1409. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  1410. 项目业务
  1411. </span>
  1412. </div>
  1413. <div className="patent-table">
  1414. <Spin spinning={this.state.loading}>
  1415. <Table
  1416. columns={this.state.columnsX}
  1417. dataSource={this.state.dataSourceX}
  1418. pagination={this.state.paginations}
  1419. bordered
  1420. size="small"
  1421. />
  1422. </Spin>
  1423. </div>
  1424. {/* <div>*/}
  1425. {/*<span style={{ marginLeft: "50px", fontSize: "20px" }}>*/}
  1426. {/* 催款节点*/}
  1427. {/*</span>*/}
  1428. {/* <span*/}
  1429. {/* style={{*/}
  1430. {/* display: cuiDataList.length ? "none" : "inline-block",*/}
  1431. {/* marginLeft: 10,*/}
  1432. {/* color: "red",*/}
  1433. {/* }}*/}
  1434. {/* >*/}
  1435. {/* 金额总计(万元): {this.state.totalCui}*/}
  1436. {/*</span>*/}
  1437. {/* </div>*/}
  1438. {/* <div className="clearfix">*/}
  1439. {/* <Spin spinning={this.state.loading}>*/}
  1440. {/* <Form layout="horizontal" id="demand-form">*/}
  1441. {/* <Table*/}
  1442. {/* pagination={false}*/}
  1443. {/* bordered*/}
  1444. {/* size="small"*/}
  1445. {/* // columns={this.state.ContactsLists}*/}
  1446. {/* // dataSource={this.state.contactList}*/}
  1447. {/* columns={*/}
  1448. {/* cuiDataList.length*/}
  1449. {/* ? this.state.ContactsLists*/}
  1450. {/* : this.state.ContactsListsNew*/}
  1451. {/* }*/}
  1452. {/* dataSource={*/}
  1453. {/* cuiDataList.length*/}
  1454. {/* ? this.state.contactList*/}
  1455. {/* : this.state.contactListNew*/}
  1456. {/* }*/}
  1457. {/* />*/}
  1458. {/* <Col*/}
  1459. {/* span={24}*/}
  1460. {/* offset={9}*/}
  1461. {/* style={{ marginTop: "15px" }}*/}
  1462. {/* />*/}
  1463. {/* </Form>*/}
  1464. {/* </Spin>*/}
  1465. {/* </div>*/}
  1466. </div>
  1467. </Spin>
  1468. </Form>
  1469. </Modal> : <div/>}
  1470. {this.state.addnextVisible ? <Modal
  1471. maskClosable={false}
  1472. visible={this.state.addnextVisible}
  1473. onOk={this.nextCancel}
  1474. onCancel={this.nextCancel}
  1475. width="800px"
  1476. title={this.state.refundStatus == 2 ? "修改退单申请" : "退单详情"}
  1477. footer=""
  1478. className="admin-desc-content"
  1479. >
  1480. <Form layout="horizontal" id="demand-form">
  1481. <Spin spinning={this.state.loading}>
  1482. <div className="clearfix">
  1483. <FormItem
  1484. className="half-item"
  1485. {...formItemLayout}
  1486. label="退单编号"
  1487. >
  1488. <span>{this.state.id}</span>
  1489. </FormItem>
  1490. <FormItem
  1491. className="half-item"
  1492. {...formItemLayout}
  1493. label="退单日期"
  1494. >
  1495. <span>{this.state.createDate}</span>
  1496. </FormItem>
  1497. <FormItem
  1498. className="half-item"
  1499. {...formItemLayout}
  1500. label="订单编号"
  1501. >
  1502. <span>{this.state.orderNo}</span>
  1503. </FormItem>
  1504. <FormItem
  1505. className="half-item"
  1506. {...formItemLayout}
  1507. label="订单状态"
  1508. >
  1509. <span>{getNewOrderStatus(this.state.orderStatus)}</span>
  1510. </FormItem>
  1511. <FormItem
  1512. className="half-item"
  1513. {...formItemLayout}
  1514. label="退单状态"
  1515. >
  1516. <span>{getRefundStatus(this.state.refundStatus)}</span>
  1517. </FormItem>
  1518. <FormItem
  1519. className="half-item"
  1520. {...formItemLayout}
  1521. label="退款状态"
  1522. >
  1523. <span>
  1524. {getLiquidationStatus(this.state.liquidationStatus)}
  1525. </span>
  1526. </FormItem>
  1527. <div className="clearfix">
  1528. {this.state.refundStatus == 2 ? (
  1529. <FormItem
  1530. labelCol={{ span: 4 }}
  1531. wrapperCol={{ span: 16 }}
  1532. label="终止合同"
  1533. >
  1534. <Picture
  1535. domId={'chargeback4'}
  1536. fileList={(e) => {
  1537. this.setState({ contractUrl: e });
  1538. }}
  1539. pictureUrl={this.state.contractUrl}
  1540. visible={this.props.visible}
  1541. data={{
  1542. sign: "order_refund_file",
  1543. url: "/api/admin/newOrder/uploadRefundOrderFile",
  1544. }}
  1545. />
  1546. </FormItem>
  1547. ) : (
  1548. <FormItem
  1549. labelCol={{ span: 4 }}
  1550. wrapperCol={{ span: 18 }}
  1551. label="合同扫描件"
  1552. >
  1553. {/*<Upload*/}
  1554. {/* className="demandDetailShow-upload"*/}
  1555. {/* listType="picture-card"*/}
  1556. {/* fileList={this.state.orgCodeUrl}*/}
  1557. {/* onPreview={(file) => {*/}
  1558. {/* this.setState({*/}
  1559. {/* previewImage: file.url || file.thumbUrl,*/}
  1560. {/* previewVisible: true,*/}
  1561. {/* });*/}
  1562. {/* }}*/}
  1563. {/*/>*/}
  1564. <div style={{paddingTop:'10px',paddingBottom:'10px'}}>
  1565. {this.state.visible && this.state.orgCodeUrl ? <ImgList domId={'chargeback2'} fileList={this.state.orgCodeUrl}/> : <div/>}
  1566. </div>
  1567. <Modal
  1568. maskClosable={false}
  1569. footer={null}
  1570. visible={this.state.previewVisible}
  1571. onCancel={() => {
  1572. this.setState({ previewVisible: false });
  1573. }}
  1574. >
  1575. <img
  1576. alt=""
  1577. style={{ width: "100%" }}
  1578. src={this.state.previewImage || ""}
  1579. />
  1580. </Modal>
  1581. </FormItem>
  1582. )}
  1583. </div>
  1584. <div className="clearfix">
  1585. <FormItem
  1586. labelCol={{ span: 4 }}
  1587. wrapperCol={{ span: 16 }}
  1588. label="退单申请表"
  1589. >
  1590. {/*<Upload*/}
  1591. {/* className="demandDetailShow-upload"*/}
  1592. {/* listType="picture-card"*/}
  1593. {/* fileList={this.state.orgCodeUrl}*/}
  1594. {/* onPreview={(file) => {*/}
  1595. {/* this.setState({*/}
  1596. {/* previewImage: file.url || file.thumbUrl,*/}
  1597. {/* previewVisible: true,*/}
  1598. {/* });*/}
  1599. {/* }}*/}
  1600. {/*/>*/}
  1601. <div style={{paddingTop:'10px',paddingBottom:'10px'}}>
  1602. {this.state.visible && this.state.orgCodeUrl ? <ImgList domId={'chargeback3'} fileList={this.state.orgCodeUrl}/> : <div/>}
  1603. </div>
  1604. </FormItem>
  1605. </div>
  1606. <div className="clearfix">
  1607. <FormItem
  1608. labelCol={{ span: 4 }}
  1609. wrapperCol={{ span: 16 }}
  1610. label="退单理由"
  1611. >
  1612. {this.state.refundStatus == 2 ? (
  1613. <Input
  1614. type="textarea"
  1615. placeholder="请输入退单理由"
  1616. rows={4}
  1617. value={this.state.reason}
  1618. onChange={(e) => {
  1619. this.setState({ reason: e.target.value });
  1620. }}
  1621. />
  1622. ) : (
  1623. <span>{this.state.reason}</span>
  1624. )}
  1625. </FormItem>
  1626. </div>
  1627. {this.state.refundStatus == 2 ? (
  1628. <FormItem
  1629. wrapperCol={{ span: 12, offset: 4 }}
  1630. className="half-middle"
  1631. >
  1632. <Button
  1633. className="submitSave"
  1634. type="primary"
  1635. onClick={this.tuidanOk}
  1636. >
  1637. 重新退单
  1638. </Button>
  1639. <Button
  1640. className="submitSave"
  1641. type="ghost"
  1642. onClick={this.nextCancel}
  1643. >
  1644. 取消
  1645. </Button>
  1646. </FormItem>
  1647. ) : (
  1648. ""
  1649. )}
  1650. </div>
  1651. </Spin>
  1652. </Form>
  1653. </Modal> : <div/>}
  1654. <OrderRiZi
  1655. dataSourcerizhi={this.state.dataSourcerizhi}
  1656. closeOrderLog={this.closeOrderLog}
  1657. visible={this.state.rizhivisible}
  1658. loading={this.state.loading}
  1659. />
  1660. </div>
  1661. </div>
  1662. );
  1663. },
  1664. })
  1665. );
  1666. export default IntentionCustomer;