outsourcingPaiDan.jsx 50 KB

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