shouKuanAll.jsx 67 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import moment from "moment";
  4. import "./public.less";
  5. import "./shouKuan.less";
  6. import {
  7. Button,
  8. Form,
  9. Input,
  10. Spin,
  11. Table,
  12. Select,
  13. message,
  14. DatePicker,
  15. Modal,
  16. Tabs,
  17. Col,
  18. Tag
  19. } from "antd";
  20. import OrderDesc from "../orderDetail/orderDesc";
  21. import Receivable from "./receivable";
  22. import ResolutionDetail from "@/resolutionDetail";
  23. import Assign from "@/manageCenter/publicComponent/assign";
  24. import ReactToPrint from "react-to-print";
  25. import {
  26. getLiquidationStatus,
  27. getProcessStatus,
  28. getApproval,
  29. getInvoiceStatus,
  30. getTransactionProject,
  31. getTaskStatus,
  32. getNewOrderStatus,
  33. getProjectStatus,
  34. getjiedian
  35. } from "@/tools";
  36. import { ChooseList } from "../../order/orderNew/chooseList";
  37. import Project from "../../../../component/project"
  38. const FormItem = Form.Item;
  39. const { TabPane } = Tabs;
  40. const ShouKuang = React.createClass({
  41. departmentList() {
  42. this.setState({
  43. loading: true
  44. });
  45. $.ajax({
  46. method: "get",
  47. dataType: "json",
  48. crossDomain: false,
  49. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  50. data: {},
  51. success: function(data) {
  52. let thedata = data.data;
  53. let theArr = [];
  54. if (!thedata) {
  55. if (data.error && data.error.length) {
  56. message.warning(data.error[0].message);
  57. }
  58. } else {
  59. thedata.map(function(item, index) {
  60. theArr.push({
  61. key: index,
  62. name: item.name,
  63. id: item.id
  64. });
  65. });
  66. }
  67. this.setState({
  68. departmentArr: theArr
  69. });
  70. }.bind(this)
  71. }).always(
  72. function() {
  73. this.setState({
  74. loading: false
  75. });
  76. }.bind(this)
  77. );
  78. },
  79. loadData(pageNo, pageSize) {
  80. this.state.data = [];
  81. this.state.pagination.pageSize = 10;
  82. this.setState({
  83. // selectedRowKeys: [],
  84. // selectedRowKey: [],
  85. page: pageNo,
  86. loadingA: true,
  87. pagination: this.state.pagination
  88. });
  89. $.ajax({
  90. method: "get",
  91. dataType: "json",
  92. crossDomain: false,
  93. url: globalConfig.context + "/api/admin/financial/financeList",
  94. data: {
  95. pageNo: pageNo || 1,
  96. pageSize: pageSize || this.state.pagination.pageSize,
  97. buyerName: this.state.nameSearch, //客户名称
  98. orderNo: this.state.orderNoSearch,
  99. startTime: this.state.releaseDate[0],
  100. endTime: this.state.releaseDate[1],
  101. startFinalReceivablesTime: this.state.shouKuanDate[0],
  102. endFinalReceivablesTime: this.state.shouKuanDate[1],
  103. departmentId: this.state.departmenttList,
  104. processStatus: this.state.processStatusSearch,
  105. contractNo: this.state.contractNoSearch,
  106. liquidationStatus: this.state.liquidationStatus,
  107. amountStatus: this.state.amountStatus
  108. },
  109. success: function(data) {
  110. let theArr = [];
  111. if (!data.data || !data.data.pagination.list) {
  112. if (data.error && data.error.length) {
  113. message.warning(data.error[0].message);
  114. }
  115. } else {
  116. for (let i = 0; i < data.data.pagination.list.length; i++) {
  117. let thisdata = data.data.pagination.list[i];
  118. theArr.push({
  119. key: thisdata.orderNo,
  120. orderNo: thisdata.orderNo,
  121. orderType: thisdata.orderType,
  122. orderStatus: thisdata.orderStatus,
  123. sellerName: thisdata.sellerName,
  124. processStatus: thisdata.processStatus,
  125. liquidationStatus: thisdata.liquidationStatus,
  126. approval: thisdata.approval,
  127. buyerName: thisdata.buyerName,
  128. actuallyTotalAmount: thisdata.actuallyTotalAmount,
  129. signTime: thisdata.signTime,
  130. companyId: thisdata.companyId,
  131. companyName: thisdata.companyName,
  132. buyerId: thisdata.buyerId,
  133. buyerName: thisdata.buyerName,
  134. contractNo: thisdata.contractNo,
  135. createTime: thisdata.createTime,
  136. departmentName: thisdata.departmentName,
  137. invoiceAmount: thisdata.invoiceAmount,
  138. finalReceivables: thisdata.finalReceivables,
  139. finalReceivablesTime: thisdata.finalReceivablesTime,
  140. signTotalAmount: thisdata.signTotalAmount,
  141. financeName: thisdata.financeName,
  142. backStatus: thisdata.backStatus,
  143. orderReceivables: thisdata.orderReceivables,
  144. orderArrears: thisdata.orderArrears,
  145. });
  146. }
  147. }
  148. this.state.pagination.current = data.data.pagination.pageNo;
  149. this.state.pagination.total = data.data.pagination.totalCount;
  150. if (
  151. data.data &&
  152. data.data.pagination.list &&
  153. !data.data.pagination.list.length
  154. ) {
  155. this.state.pagination.current = 0;
  156. this.state.pagination.total = 0;
  157. }
  158. this.setState({
  159. totalPage: data.data.pagination.totalPage,
  160. dataSource: theArr,
  161. pagination: this.state.pagination,
  162. totalHui: data.data.count ? data.data.count.signTotalAmount : 0,
  163. hui: data.data.count ? data.data.count.actuallyTotalAmount : 0
  164. });
  165. }.bind(this)
  166. }).always(
  167. function() {
  168. this.setState({
  169. loadingA: false
  170. });
  171. }.bind(this)
  172. );
  173. },
  174. getInitialState() {
  175. return {
  176. searchMore: true,
  177. dvisible: false,
  178. assignVisibleX: false,
  179. assignVisibleY: false,
  180. releaseDate: [],
  181. shouKuanDate: [],
  182. assignDataX: [],
  183. assignDataY: [],
  184. totalPage: 0,
  185. processStatusSearch: [],
  186. boHuivisible: false,
  187. selectedRowKeys: [],
  188. selectedRows: [],
  189. loading: false,
  190. loadingA: false,
  191. pagination: {
  192. defaultCurrent: 1,
  193. defaultPageSize: 10,
  194. showQuickJumper: true,
  195. pageSize: 10,
  196. onChange: function (page) {
  197. this.loadData(page);
  198. }.bind(this),
  199. showTotal: function (total) {
  200. return "共" + total + "条数据";
  201. },
  202. },
  203. // 子组件改变的表格title数组
  204. changeList: undefined,
  205. proColumns: [
  206. {
  207. title: "序号",
  208. dataIndex: "key",
  209. key: "key",
  210. },
  211. {
  212. title: "合同编号",
  213. dataIndex: "contractNo",
  214. key: "contractNo",
  215. },
  216. {
  217. title: "订单编号",
  218. dataIndex: "orderNo",
  219. key: "orderNo",
  220. },
  221. {
  222. title: "客户名称",
  223. dataIndex: "userName",
  224. key: "userName",
  225. },
  226. {
  227. title: "订单负责人",
  228. dataIndex: "salesmanName",
  229. key: "salesmanName",
  230. },
  231. {
  232. title: "是否主项目",
  233. dataIndex: "main",
  234. key: "main",
  235. render: (text) => {
  236. return text == 0 ? "否" : "是";
  237. },
  238. },
  239. {
  240. title: "项目类别",
  241. dataIndex: "cname",
  242. key: "cname",
  243. },
  244. {
  245. title: "项目名称",
  246. dataIndex: "commodityName",
  247. key: "commodityName",
  248. },
  249. {
  250. title: "项目数量",
  251. dataIndex: "commodityQuantity",
  252. key: "commodityQuantity",
  253. render: (text, record) => {
  254. if (record.splitStatus == 1) {
  255. return (
  256. <span>
  257. {text}{" "}
  258. <Tag
  259. color="#108ee9"
  260. onClick={(e) => {
  261. e.stopPropagation();
  262. this.showRes(record);
  263. }}
  264. >
  265. 已拆
  266. </Tag>
  267. </span>
  268. );
  269. } else {
  270. return text;
  271. }
  272. },
  273. },
  274. {
  275. title: "服务市价",
  276. dataIndex: "commodityPrice",
  277. key: "commodityPrice",
  278. },
  279. {
  280. title: "证书编号",
  281. dataIndex: "certificateNumber",
  282. key: "certificateNumber",
  283. },
  284. {
  285. title: "项目状态",
  286. dataIndex: "projectStatus",
  287. key: "projectStatus",
  288. render: (text) => {
  289. return getProjectStatus(text);
  290. },
  291. },
  292. {
  293. title: "项目说明",
  294. dataIndex: "taskComment",
  295. key: "taskComment",
  296. },
  297. {
  298. title: "是否外包",
  299. dataIndex: "outsource",
  300. key: "outsource",
  301. render: (text) => {
  302. if (text == 0) {
  303. return "否";
  304. } else if (text == 1) {
  305. return "是";
  306. }
  307. },
  308. },
  309. {
  310. title: "外包(内部)公司",
  311. dataIndex: "outsourceName",
  312. key: "outsourceName",
  313. },
  314. {
  315. title: "外包(内部)价格",
  316. dataIndex: "outsourcePrice",
  317. key: "outsourcePrice",
  318. },
  319. ],
  320. cuiColumns: [
  321. {
  322. title: "序号",
  323. dataIndex: "key",
  324. key: "key",
  325. },
  326. {
  327. title: "合同编号",
  328. dataIndex: "contractNo",
  329. key: "contractNo",
  330. },
  331. {
  332. title: "订单编号",
  333. dataIndex: "orderNo",
  334. key: "orderNo",
  335. },
  336. {
  337. title: "客户名称",
  338. dataIndex: "userName",
  339. key: "userName",
  340. },
  341. {
  342. title: "订单负责人",
  343. dataIndex: "salesmanName",
  344. key: "salesmanName",
  345. },
  346. {
  347. title: "订单部门",
  348. dataIndex: "depName",
  349. key: "depName",
  350. },
  351. {
  352. title: "订单状态",
  353. dataIndex: "orderStatus",
  354. key: "orderStatus",
  355. render: (text) => {
  356. return getNewOrderStatus(text);
  357. },
  358. },
  359. {
  360. title: "项目状态",
  361. dataIndex: "projectStatus",
  362. key: "projectStatus",
  363. render: (text) => {
  364. return getProjectStatus(text);
  365. },
  366. },
  367. {
  368. title: "签单金额",
  369. dataIndex: "totalAmount",
  370. key: "totalAmount",
  371. },
  372. {
  373. title: "结算状态",
  374. dataIndex: "liquidationStatus",
  375. key: "liquidationStatus",
  376. render: (text) => {
  377. return getLiquidationStatus(text);
  378. },
  379. },
  380. {
  381. title: "已收款",
  382. dataIndex: "settlementAmount",
  383. key: "settlementAmount",
  384. },
  385. {
  386. title: "应收款",
  387. dataIndex: "accountsReceivable",
  388. key: "accountsReceivable",
  389. },
  390. {
  391. title: "催收科目",
  392. dataIndex: "dunSubject",
  393. key: "dunSubject",
  394. // render: text => {
  395. // return getjiedian(text);
  396. // }
  397. },
  398. {
  399. title: "催款状态",
  400. dataIndex: "dunStatus",
  401. key: "dunStatus",
  402. },
  403. {
  404. title: "催收启动时间",
  405. dataIndex: "startDate",
  406. key: "startDate",
  407. },
  408. ],
  409. timeColumns: [
  410. {
  411. title: "合同编号",
  412. dataIndex: "contractNo",
  413. key: "contractNo",
  414. },
  415. {
  416. title: "订单编号",
  417. dataIndex: "orderNo",
  418. key: "orderNo",
  419. },
  420. {
  421. title: "项目编号",
  422. dataIndex: "id",
  423. key: "id",
  424. render: (text, record) => {
  425. if (record.splitStatus == 2) {
  426. return <span>{record.splitSuper + "-" + record.splitId}</span>;
  427. } else {
  428. return text;
  429. }
  430. },
  431. },
  432. {
  433. title: "客户名称",
  434. dataIndex: "userName",
  435. key: "userName",
  436. render: (text) => {
  437. return text && text.length > 9 ? text.substr(0, 9) + "..." : text;
  438. },
  439. },
  440. {
  441. title: "订单部门",
  442. dataIndex: "depName",
  443. key: "depName",
  444. },
  445. {
  446. title: "订单负责人",
  447. dataIndex: "salesmanName",
  448. key: "salesmanName",
  449. },
  450. {
  451. title: "项目类别",
  452. dataIndex: "cname",
  453. key: "cname",
  454. },
  455. {
  456. title: "项目名称",
  457. dataIndex: "taskName",
  458. key: "taskName",
  459. },
  460. {
  461. title: "项目负责人",
  462. dataIndex: "receiverName",
  463. key: "receiverName",
  464. },
  465. {
  466. title: "项目价格(万元)",
  467. dataIndex: "commodityPrice",
  468. key: "commodityPrice",
  469. },
  470. {
  471. title: "数量(个)",
  472. dataIndex: "commodityQuantity",
  473. key: "commodityQuantity",
  474. },
  475. {
  476. title: "任务状态",
  477. dataIndex: "taskStatus",
  478. key: "taskStatus",
  479. render: (text) => {
  480. return getTaskStatus(text);
  481. },
  482. },
  483. {
  484. title: "项目状态",
  485. dataIndex: "projectStatus",
  486. key: "projectStatus",
  487. render: (text) => {
  488. return getProjectStatus(text);
  489. },
  490. },
  491. {
  492. title: "工时",
  493. dataIndex: "hours",
  494. key: "hours",
  495. },
  496. {
  497. title: "是否外包",
  498. dataIndex: "outsource",
  499. key: "outsource",
  500. render: (text) => {
  501. if (text == 0) {
  502. return "否";
  503. } else if (text == 1) {
  504. return "是";
  505. }
  506. },
  507. },
  508. {
  509. title: "签单日期",
  510. dataIndex: "signTime",
  511. key: "signTime",
  512. },
  513. {
  514. title: "派单日期",
  515. dataIndex: "creteTime",
  516. key: "creteTime",
  517. },
  518. {
  519. title: "分配时间",
  520. dataIndex: "taskDistributionTime",
  521. key: "taskDistributionTime",
  522. },
  523. {
  524. title: "完成时间",
  525. dataIndex: "taskEndTime",
  526. key: "taskEndTime",
  527. },
  528. ],
  529. printColumns: [
  530. {
  531. title: "合同编号",
  532. dataIndex: "contractNo",
  533. key: "contractNo",
  534. },
  535. {
  536. title: "订单编号",
  537. dataIndex: "orderNo",
  538. key: "orderNo",
  539. // fixed: "left"
  540. },
  541. {
  542. title: "客户名称",
  543. dataIndex: "buyerName",
  544. key: "buyerName",
  545. },
  546. {
  547. title: "订单部门",
  548. dataIndex: "departmentName",
  549. key: "departmentName",
  550. },
  551. {
  552. title: "订单负责人",
  553. dataIndex: "sellerName",
  554. key: "sellerName",
  555. },
  556. {
  557. title: "签单日期",
  558. dataIndex: "signTime",
  559. key: "signTime",
  560. },
  561. {
  562. title: "下单日期",
  563. dataIndex: "createTime",
  564. key: "createTime",
  565. },
  566. {
  567. title: "签单金额(万元)",
  568. dataIndex: "signTotalAmount",
  569. key: "signTotalAmount",
  570. },
  571. {
  572. title: "开票金额(万元)",
  573. dataIndex: "invoiceAmount",
  574. key: "invoiceAmount",
  575. },
  576. {
  577. title: "已收款(万元)",
  578. dataIndex: "actuallyTotalAmount",
  579. key: "actuallyTotalAmount",
  580. },
  581. {
  582. title: "最近收款(万元)",
  583. dataIndex: "finalReceivables",
  584. key: "finalReceivables",
  585. },
  586. {
  587. title: "最近收款时间",
  588. dataIndex: "finalReceivablesTime",
  589. key: "finalReceivablesTime",
  590. },
  591. {
  592. title: "结算状态",
  593. dataIndex: "liquidationStatus",
  594. key: "liquidationStatus",
  595. render: (text) => {
  596. return getLiquidationStatus(text);
  597. },
  598. },
  599. {
  600. title: "流程状态",
  601. dataIndex: "processStatus",
  602. key: "processStatus",
  603. render: (text) => {
  604. return getProcessStatus(text);
  605. },
  606. },
  607. {
  608. title: "特批状态",
  609. dataIndex: "approval",
  610. key: "approval",
  611. render: (text) => {
  612. return getApproval(text);
  613. },
  614. },
  615. ],
  616. columns: [
  617. {
  618. title: "合同编号",
  619. dataIndex: "contractNo",
  620. key: "contractNo",
  621. className: "title-table",
  622. fixed: "left",
  623. },
  624. {
  625. title: "客户名称",
  626. dataIndex: "buyerName",
  627. key: "buyerName",
  628. className: "title-table",
  629. fixed: "left",
  630. },
  631. {
  632. title: "订单编号",
  633. dataIndex: "orderNo",
  634. key: "orderNo",
  635. className: "title-table",
  636. // fixed: "left"
  637. },
  638. {
  639. title: "特批状态",
  640. dataIndex: "approval",
  641. key: "approval",
  642. className: "title-table",
  643. render: (text) => {
  644. if (text == 1 || text == 2) {
  645. return <Tag color="#f50">{getApproval(text)}</Tag>;
  646. }
  647. return getApproval(text);
  648. },
  649. },
  650. {
  651. title: "订单部门",
  652. dataIndex: "departmentName",
  653. key: "departmentName",
  654. className: "title-table",
  655. },
  656. {
  657. title: "订单负责人",
  658. dataIndex: "sellerName",
  659. key: "sellerName",
  660. className: "title-table",
  661. },
  662. {
  663. title: "财务负责人",
  664. dataIndex: "financeName",
  665. key: "financeName",
  666. className: "title-table",
  667. },
  668. {
  669. title: "签单日期",
  670. dataIndex: "signTime",
  671. key: "signTime",
  672. className: "title-table",
  673. },
  674. {
  675. title: "下单日期",
  676. dataIndex: "createTime",
  677. key: "createTime",
  678. className: "title-table",
  679. },
  680. {
  681. title: "签单金额(万元)",
  682. dataIndex: "signTotalAmount",
  683. key: "signTotalAmount",
  684. className: "title-table",
  685. },
  686. {
  687. title: "开票金额(万元)",
  688. dataIndex: "invoiceAmount",
  689. key: "invoiceAmount",
  690. className: "title-table",
  691. },
  692. {
  693. title: "已收款(万元)",
  694. dataIndex: "actuallyTotalAmount",
  695. key: "actuallyTotalAmount",
  696. className: "title-table",
  697. },
  698. {
  699. title: "应收款(万元)",
  700. dataIndex: "orderReceivables",
  701. key: "orderReceivables",
  702. className: "title-table",
  703. },
  704. {
  705. title: "欠款(万元)",
  706. dataIndex: "orderArrears",
  707. key: "orderArrears",
  708. className: "title-table",
  709. },
  710. {
  711. title: "最近收款(万元)",
  712. dataIndex: "finalReceivables",
  713. key: "finalReceivables",
  714. className: "title-table",
  715. },
  716. {
  717. title: "最近收款时间",
  718. dataIndex: "finalReceivablesTime",
  719. key: "finalReceivablesTime",
  720. className: "title-table",
  721. },
  722. {
  723. title: "结算状态",
  724. dataIndex: "liquidationStatus",
  725. key: "liquidationStatus",
  726. className: "title-table",
  727. render: (text) => {
  728. return getLiquidationStatus(text);
  729. },
  730. },
  731. {
  732. title: "流程状态",
  733. dataIndex: "processStatus",
  734. key: "processStatus",
  735. className: "title-table",
  736. render: (text) => {
  737. return getProcessStatus(text);
  738. },
  739. },
  740. {
  741. title: "驳回状态",
  742. dataIndex: "backStatus",
  743. key: "backStatus",
  744. className: "title-table",
  745. render: (text) => {
  746. if (text == 3) {
  747. return <Tag>已驳回</Tag>;
  748. } else {
  749. return "";
  750. }
  751. },
  752. },
  753. // {
  754. // title: '订单状态',
  755. // dataIndex: 'orderStatus',
  756. // key: 'orderStatus',
  757. // render: text => { return getNewOrderStatus(text)}
  758. // },
  759. // {
  760. // title: "操作",
  761. // dataIndex: "caozuo",
  762. // key: "caouzo",
  763. // className: "title-table",
  764. // render: (text, recard) => {
  765. // return (
  766. // <div>
  767. // {recard.liquidationStatus < 2 &&
  768. // (recard.approval === 1 || recard.approval === 2) ? (
  769. // <Button
  770. // style={{ background: "rgb(192,192,192)" }}
  771. // onClick={e => {
  772. // e.stopPropagation(), this.evaluateX(recard);
  773. // }}
  774. // >
  775. // 收款
  776. // </Button>
  777. // ) : (
  778. // <Button
  779. // type="primary"
  780. // onClick={e => {
  781. // e.stopPropagation(), this.evaluateX(recard);
  782. // }}
  783. // >
  784. // 收款
  785. // </Button>
  786. // )}
  787. // {recard.processStatus < 4 ? (
  788. // <Button
  789. // type="primary"
  790. // onClick={e => {
  791. // e.stopPropagation(), this.evaluateZ(recard);
  792. // }}
  793. // style={{ marginLeft: "5px" }}
  794. // >
  795. // 通过
  796. // </Button>
  797. // ) : (
  798. // ""
  799. // )}
  800. // {!(
  801. // recard.actuallyTotalAmount &&
  802. // Number(recard.actuallyTotalAmount) > 0
  803. // ) && (
  804. // <Button
  805. // type="danger"
  806. // style={{ marginLeft: "5px" }}
  807. // onClick={e => {
  808. // e.stopPropagation(), this.reject(recard);
  809. // }}
  810. // >
  811. // 驳回
  812. // </Button>
  813. // )}
  814. // {
  815. // // <Button
  816. // // type="primary"
  817. // // style={{ marginLeft: "5px" }}
  818. // // onClick={e => {
  819. // // e.stopPropagation(), this.evaluateY(recard, "财务专员");
  820. // // console.log(recard);
  821. // // }}
  822. // // >
  823. // // 转交
  824. // // </Button>
  825. // }
  826. // </div>
  827. // );
  828. // }
  829. // }
  830. ],
  831. dataSource: [],
  832. searchTime: [],
  833. columnsDate: [
  834. {
  835. title: "编号",
  836. dataIndex: "id",
  837. key: "id",
  838. },
  839. {
  840. title: "订单编号",
  841. dataIndex: "orderno",
  842. key: "orderno",
  843. },
  844. {
  845. title: "开票金额(万元)",
  846. dataIndex: "amount",
  847. key: "amount",
  848. },
  849. {
  850. title: "申请时间",
  851. dataIndex: "createTime",
  852. key: "createTime",
  853. },
  854. {
  855. title: "开票状态",
  856. dataIndex: "status",
  857. key: "status",
  858. render: (text) => {
  859. return getInvoiceStatus(text);
  860. },
  861. },
  862. ],
  863. waterlistDate: [
  864. {
  865. title: "订单编号",
  866. dataIndex: "orderNo",
  867. key: "orderNo",
  868. },
  869. {
  870. title: "平台流水号",
  871. dataIndex: "billNo",
  872. key: "billNo",
  873. // fixed: "left"
  874. },
  875. {
  876. title: "收款金额(万元)",
  877. dataIndex: "transactionAmount",
  878. key: "transactionAmount",
  879. },
  880. {
  881. title: "收款方",
  882. dataIndex: "payeeName",
  883. key: "payeeName",
  884. },
  885. {
  886. title: "付款方",
  887. dataIndex: "payerName",
  888. key: "payerName",
  889. },
  890. {
  891. title: "流水科目",
  892. dataIndex: "transactionSubject",
  893. key: "transactionSubject",
  894. render: (text) => {
  895. return getTransactionProject(text);
  896. },
  897. },
  898. {
  899. title: "收款类型",
  900. dataIndex: "type",
  901. key: "type",
  902. },
  903. {
  904. title: "财务流水时间",
  905. dataIndex: "financialPayTimes",
  906. key: "financialPayTimes",
  907. },
  908. {
  909. title: "财务流水号",
  910. dataIndex: "financialPayNo",
  911. key: "financialPayNo",
  912. },
  913. {
  914. title: "订单负责人",
  915. dataIndex: "saleName",
  916. key: "saleName",
  917. },
  918. {
  919. title: "创建时间",
  920. dataIndex: "createTimes",
  921. key: "createTimes",
  922. },
  923. {
  924. title: "退款时间",
  925. dataIndex: "refundTimes",
  926. key: "refundTimes",
  927. },
  928. {
  929. title: "删除时间",
  930. dataIndex: "deleteTimes",
  931. key: "deleteTimes",
  932. },
  933. {
  934. title: "备注",
  935. dataIndex: "remarks",
  936. key: "remarks",
  937. },
  938. {
  939. title: "流水状态",
  940. dataIndex: "deleteSign",
  941. key: "deleteSign",
  942. render: (text, record) => {
  943. if (!text) {
  944. return "";
  945. } else {
  946. return <Tag>已删除</Tag>;
  947. }
  948. },
  949. },
  950. ],
  951. waterData: [],
  952. };
  953. },
  954. // 特批通过
  955. evaluateZ(record) {
  956. $.ajax({
  957. method: "POST",
  958. dataType: "json",
  959. crossDomain: false,
  960. url: globalConfig.context + "/api/admin/financial/financeApproval",
  961. data: {
  962. orderNo: record.orderNo
  963. }
  964. }).done(
  965. function(data) {
  966. if (!data.error.length) {
  967. message.success("通过成功!");
  968. this.setState({
  969. loading: false
  970. });
  971. this.loadData();
  972. } else {
  973. message.warning(data.error[0].message);
  974. }
  975. }.bind(this)
  976. );
  977. },
  978. /* 收款 */
  979. evaluateX(recard) {
  980. this.state.assignDataX = recard;
  981. this.setState({
  982. assignVisibleX: true
  983. });
  984. },
  985. /* 转交 */
  986. evaluateY(recard, nub) {
  987. this.state.assignDataY = recard;
  988. this.setState({
  989. nub,
  990. assignVisibleY: true
  991. });
  992. },
  993. /* 驳回 */
  994. reject(recard) {
  995. this.setState({
  996. bohuiData: recard,
  997. boHuiVisible: true,
  998. content: ""
  999. });
  1000. },
  1001. boHuiOk() {
  1002. this.setState({
  1003. boHuiVisible: false
  1004. });
  1005. if (
  1006. this.state.pagination.current == this.state.totalPage &&
  1007. this.state.pagination.total % 10 == 1
  1008. ) {
  1009. this.loadData(this.state.page - 1);
  1010. } else {
  1011. this.loadData(this.state.page);
  1012. }
  1013. },
  1014. boHuiCancel() {
  1015. this.setState({
  1016. boHuiVisible: false
  1017. });
  1018. },
  1019. componentWillMount() {
  1020. this.loadData();
  1021. this.departmentList();
  1022. },
  1023. tableRowClick(record) {
  1024. this.state.RowData = record;
  1025. this.setState({
  1026. showDesc: true
  1027. });
  1028. },
  1029. closeDesc(e, s) {
  1030. this.state.showDesc = e;
  1031. if (s) {
  1032. this.loadData(this.state.page);
  1033. }
  1034. },
  1035. closeAssignX(e, s) {
  1036. this.state.assignDataX = {};
  1037. this.state.assignVisibleX = e;
  1038. if (s) {
  1039. this.loadData(this.state.page);
  1040. }
  1041. },
  1042. closeAssignY(e, s) {
  1043. this.state.assignDataY = {};
  1044. this.state.assignVisibleY = e;
  1045. if (s) {
  1046. this.loadData(this.state.page);
  1047. }
  1048. },
  1049. search() {
  1050. this.loadData();
  1051. },
  1052. // 拆分详细
  1053. showRes(record) {
  1054. this.setState({
  1055. resVisible: true,
  1056. resRecord: record
  1057. });
  1058. },
  1059. resCancel() {
  1060. this.setState({
  1061. resVisible: false
  1062. });
  1063. },
  1064. reset() {
  1065. this.state.nameSearch = "";
  1066. this.state.releaseDate = [];
  1067. this.state.shouKuanDate = [];
  1068. this.state.orderNoSearch = "";
  1069. this.state.departmenttList = undefined;
  1070. this.state.amountStatus = undefined;
  1071. this.state.processStatus = [];
  1072. this.state.processStatusSearch = [];
  1073. this.state.contractNoSearch = "";
  1074. this.state.liquidationStatus = [];
  1075. this.state.contractNo = "";
  1076. this.loadData();
  1077. },
  1078. //驳回
  1079. boHuiSubmit(e) {
  1080. e.preventDefault();
  1081. if (!this.state.content) {
  1082. message.warning("请填写驳回原因");
  1083. return false;
  1084. }
  1085. this.setState({
  1086. loading: true
  1087. });
  1088. $.ajax({
  1089. method: "POST",
  1090. dataType: "json",
  1091. crossDomain: false,
  1092. url: globalConfig.context + "/api/admin/financial/reject",
  1093. data: {
  1094. orderNo: this.state.bohuiData.orderNo,
  1095. reason: this.state.content
  1096. }
  1097. }).done(
  1098. function(data) {
  1099. if (!data.error.length) {
  1100. message.success("驳回成功!");
  1101. this.setState({
  1102. loading: false
  1103. });
  1104. this.boHuiOk();
  1105. } else {
  1106. message.warning(data.error[0].message);
  1107. }
  1108. }.bind(this)
  1109. );
  1110. },
  1111. searchSwitch() {
  1112. this.setState({
  1113. searchMore: !this.state.searchMore
  1114. });
  1115. },
  1116. changeList(arr) {
  1117. const newArr = [];
  1118. this.state.columns.forEach(item => {
  1119. arr.forEach(val => {
  1120. if (val === item.title) {
  1121. newArr.push(item);
  1122. }
  1123. });
  1124. });
  1125. this.setState({
  1126. changeList: newArr
  1127. });
  1128. },
  1129. callback(key) {
  1130. console.log(key);
  1131. },
  1132. onSelectChange(selectedRowKeys) {
  1133. // for(var i=0; i<selectedRowKeys.length; i++){
  1134. // for(var j=i+1; j<selectedRowKeys.length; j++){
  1135. // if(selectedRowKeys[i]==selectedRowKeys[j]){
  1136. // selectedRowKeys.splice(j,1);
  1137. // j--;
  1138. // }
  1139. // }
  1140. // }
  1141. this.setState({ selectedRowKeys });
  1142. },
  1143. inRecordCanl() {
  1144. this.setState({
  1145. bvisible: false
  1146. });
  1147. },
  1148. inRecordData() {
  1149. this.setState({
  1150. loading: true
  1151. });
  1152. $.ajax({
  1153. method: "get",
  1154. dataType: "json",
  1155. crossDomain: false,
  1156. url:
  1157. globalConfig.context +
  1158. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  1159. data: {
  1160. orderNo: this.state.selectedRowKeys[0],
  1161. pageSize: 9999
  1162. },
  1163. success: function(data) {
  1164. let theArr = [];
  1165. let sum = 0;
  1166. if (!data.data) {
  1167. if (data.error && data.error.length) {
  1168. message.warning(data.error[0].message);
  1169. }
  1170. } else {
  1171. for (let i = 0; i < data.data.list.length; i++) {
  1172. let thisdata = data.data.list[i];
  1173. sum += parseFloat(thisdata.amount);
  1174. theArr.push({
  1175. id: thisdata.id,
  1176. orderno: thisdata.orderno, //订单编号
  1177. amount: thisdata.amount, //签单金额
  1178. createTime: thisdata.createTime, //流程状态
  1179. status: thisdata.status, //结算状态
  1180. rejectReason: thisdata.rejectReason
  1181. });
  1182. }
  1183. }
  1184. this.setState({
  1185. recordData: theArr,
  1186. sum: sum.toFixed(4)
  1187. });
  1188. }.bind(this)
  1189. }).done(
  1190. function() {
  1191. this.setState({
  1192. loading: false
  1193. });
  1194. }.bind(this)
  1195. );
  1196. },
  1197. waterData() {
  1198. this.state.data = [];
  1199. this.setState({
  1200. loading: true
  1201. });
  1202. $.ajax({
  1203. method: "get",
  1204. dataType: "json",
  1205. crossDomain: false,
  1206. url: globalConfig.context + "/api/admin/financial/myBillList",
  1207. data: {
  1208. orderNo: this.state.selectedRowKeys[0],
  1209. pageSize: 9999,
  1210. whoType: 1
  1211. },
  1212. success: function(data) {
  1213. let theArr = [];
  1214. let waterSum = 0;
  1215. if (!data.data || !data.data.list) {
  1216. if (data.error && data.error.length) {
  1217. message.warning(data.error[0].message);
  1218. }
  1219. } else {
  1220. for (let i = 0; i < data.data.list.length; i++) {
  1221. let thisdata = data.data.list[i];
  1222. if (thisdata.deleteSign == 0) {
  1223. waterSum += parseFloat(thisdata.transactionAmount);
  1224. }
  1225. theArr.push({
  1226. key: i,
  1227. orderNo: thisdata.orderNo,
  1228. billNo: thisdata.billNo,
  1229. transactionAmount: thisdata.transactionAmount,
  1230. payeeName: thisdata.payeeName,
  1231. payerName: thisdata.payerName,
  1232. transactionSubject: thisdata.transactionSubject,
  1233. transactionChannel: thisdata.transactionChannel,
  1234. financialPayTimes: thisdata.financialPayTimes,
  1235. financialPayNo: thisdata.financialPayNo,
  1236. createrName: thisdata.createrName,
  1237. saleName: thisdata.saleName,
  1238. createTimes: thisdata.createTimes,
  1239. type:
  1240. thisdata.type == 0
  1241. ? "手工"
  1242. : thisdata.type == 1
  1243. ? "批量"
  1244. : "合同变更退款",
  1245. deleteSign: thisdata.deleteSign,
  1246. deleteTimes: thisdata.deleteTimes,
  1247. refundTimes: thisdata.refundTimes,
  1248. remarks: thisdata.remarks
  1249. });
  1250. }
  1251. }
  1252. this.setState({
  1253. waterData: theArr,
  1254. waterSum: (Math.round(waterSum * 10000) / 10000).toFixed(4)
  1255. });
  1256. }.bind(this)
  1257. }).always(
  1258. function() {
  1259. this.setState({
  1260. loading: false
  1261. });
  1262. }.bind(this)
  1263. );
  1264. },
  1265. waterCanl() {
  1266. this.setState({
  1267. cvisible: false
  1268. });
  1269. },
  1270. exportKaip() {
  1271. window.location.href =
  1272. globalConfig.context +
  1273. "/api/admin/receivables/exportInvoice?" +
  1274. `orderNo=${this.state.selectedRowKeys}`;
  1275. },
  1276. exportAll() {
  1277. window.location.href =
  1278. globalConfig.context +
  1279. "/api/admin/receivables/exportReceivables?" +
  1280. `orderNo=${
  1281. this.state.orderNoSearch ? this.state.orderNoSearch : ""
  1282. }&buyerName=${
  1283. this.state.nameSearch ? this.state.nameSearch : ""
  1284. }&departmentId=${
  1285. this.state.departmenttList ? this.state.departmenttList : ""
  1286. }&contractNo=${
  1287. this.state.contractNoSearch ? this.state.contractNoSearch : ""
  1288. }&processStatus=${this.state.processStatusSearch}`;
  1289. },
  1290. exportWater() {
  1291. window.location.href =
  1292. globalConfig.context +
  1293. "/api/admin/receivables/exportMyBill?" +
  1294. `orderNo=${this.state.selectedRowKeys}&whoType=1`;
  1295. },
  1296. printAll() {
  1297. this.setState({
  1298. dvisible: true
  1299. });
  1300. this.loadData(1, 9999);
  1301. },
  1302. timeData() {
  1303. this.setState({
  1304. loading: true
  1305. });
  1306. $.ajax({
  1307. method: "get",
  1308. dataType: "json",
  1309. crossDomain: false,
  1310. url: globalConfig.context + "/api/admin/orderProject/taskHoursList",
  1311. data: {
  1312. orderNo: this.state.selectedRowKeys[0],
  1313. pageSize: 9999
  1314. },
  1315. success: function(data) {
  1316. let theArr = [];
  1317. if (!data.data || !data.data.list) {
  1318. if (data.error && data.error.length) {
  1319. message.warning(data.error[0].message);
  1320. }
  1321. } else {
  1322. for (let i = 0; i < data.data.list.length; i++) {
  1323. let thisdata = data.data.list[i];
  1324. theArr.push({
  1325. key: i + 1,
  1326. id: thisdata.id, //ID
  1327. orderNo: thisdata.orderNo, //订单编号
  1328. taskName: thisdata.taskName, //任务名称
  1329. userName: thisdata.userName, //客户名称
  1330. cname: thisdata.cname, //项目品类
  1331. taskStatus: thisdata.taskStatus, //任务状态
  1332. receiverName: thisdata.receiverName, //负责人
  1333. hours: thisdata.hours, //任务工时
  1334. depName: thisdata.depName, //派单公司
  1335. contractNo: thisdata.contractNo,
  1336. signTime: thisdata.signTime,
  1337. creteTime: thisdata.creteTime,
  1338. projectStatus: thisdata.projectStatus,
  1339. commodityPrice: thisdata.commodityPrice, //价格
  1340. commodityQuantity: thisdata.commodityQuantity, //数量
  1341. salesmanName: thisdata.salesmanName, //订单负责人
  1342. taskDistributionTime: thisdata.taskDistributionTime,
  1343. taskEndTime: thisdata.taskEndTime,
  1344. outsource: thisdata.outsource,
  1345. splitStatus: thisdata.splitStatus,
  1346. splitSuper: thisdata.splitSuper,
  1347. splitId: thisdata.splitId
  1348. });
  1349. }
  1350. }
  1351. this.setState({
  1352. timeDataList: theArr
  1353. });
  1354. }.bind(this)
  1355. }).always(
  1356. function() {
  1357. this.setState({
  1358. loading: false
  1359. });
  1360. }.bind(this)
  1361. );
  1362. },
  1363. exportTime() {
  1364. const data = {
  1365. orderNo: this.state.selectedRowKeys[0],
  1366. pageSize: 9999
  1367. };
  1368. window.location.href =
  1369. globalConfig.context +
  1370. "/api/admin/orderProject/exportMyTaskList?" +
  1371. $.param(data);
  1372. },
  1373. exportPro() {
  1374. const data = {
  1375. orderNo: this.state.selectedRowKeys[0]
  1376. };
  1377. window.location.href =
  1378. globalConfig.context +
  1379. "/api/admin/newOrder/exportOrderTaskData?" +
  1380. $.param(data);
  1381. },
  1382. exportCui() {
  1383. var data = {
  1384. orderNo: this.state.selectedRowKeys[0]
  1385. ? this.state.selectedRowKeys[0]
  1386. : undefined, //订单编号
  1387. // specially: 1,
  1388. pageSize: 9999
  1389. };
  1390. window.location.href =
  1391. globalConfig.context +
  1392. "/api/admin/newOrder/exportOrderDunData?" +
  1393. $.param(data);
  1394. },
  1395. cuiData() {
  1396. this.setState({
  1397. loading: true
  1398. });
  1399. $.ajax({
  1400. method: "get",
  1401. dataType: "json",
  1402. crossDomain: false,
  1403. url: globalConfig.context + "/api/admin/newOrder/dunOrderNewList",
  1404. data: {
  1405. orderNo: this.state.selectedRowKeys[0],
  1406. pageSize: 9999
  1407. },
  1408. success: function(data) {
  1409. let theArr = [];
  1410. if (!data.data || !data.data.list) {
  1411. if (data.error && data.error.length) {
  1412. message.warning(data.error[0].message);
  1413. }
  1414. } else {
  1415. for (let i = 0; i < data.data.list.length; i++) {
  1416. let thisdata = data.data.list[i];
  1417. theArr.push({
  1418. key: i + 1,
  1419. orderNo: thisdata.orderNo,
  1420. contractNo: thisdata.contractNo,
  1421. userName: thisdata.userName,
  1422. buyerName: thisdata.buyerName,
  1423. departmentName: thisdata.departmentName,
  1424. salesmanName: thisdata.salesmanName,
  1425. depName: thisdata.depName,
  1426. orderStatus: thisdata.orderStatus,
  1427. projectStatus: thisdata.projectStatus,
  1428. totalAmount: thisdata.totalAmount,
  1429. liquidationStatus: thisdata.liquidationStatus,
  1430. settlementAmount: thisdata.settlementAmount,
  1431. accountsReceivable: thisdata.accountsReceivable,
  1432. dunSubject: thisdata.dunSubject,
  1433. startDate: thisdata.startDate,
  1434. taskStatus: thisdata.taskStatus,
  1435. cname: thisdata.cname,
  1436. id: thisdata.id,
  1437. taskName: thisdata.taskName,
  1438. hours: thisdata.hours,
  1439. taskDistributionTime: thisdata.taskDistributionTime,
  1440. taskEndTime: thisdata.taskEndTime,
  1441. dunStatus: thisdata.dunStatus == 0 ? "未触发" : "已触发"
  1442. });
  1443. }
  1444. }
  1445. this.setState({
  1446. cuiDataList: theArr
  1447. });
  1448. }.bind(this)
  1449. }).always(
  1450. function() {
  1451. this.setState({
  1452. loading: false
  1453. });
  1454. }.bind(this)
  1455. );
  1456. },
  1457. proData() {
  1458. this.setState({
  1459. loading: true
  1460. });
  1461. $.ajax({
  1462. method: "get",
  1463. dataType: "json",
  1464. crossDomain: false,
  1465. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  1466. data: {
  1467. orderNo: this.state.selectedRowKeys[0],
  1468. pageSize: 9999
  1469. },
  1470. success: function(data) {
  1471. let theArr = [];
  1472. let totalWaibao = 0;
  1473. if (!data.data) {
  1474. if (data.error && data.error.length) {
  1475. message.warning(data.error[0].message);
  1476. }
  1477. } else {
  1478. for (let i = 0; i < data.data.length; i++) {
  1479. let thisdata = data.data[i];
  1480. totalWaibao += thisdata.outsourcePrice;
  1481. theArr.push({
  1482. key: i + 1,
  1483. orderNo: thisdata.orderNo,
  1484. contractNo: thisdata.contractNo,
  1485. userName: thisdata.userName,
  1486. buyerName: thisdata.buyerName,
  1487. departmentName: thisdata.departmentName,
  1488. salesmanName: thisdata.salesmanName,
  1489. depName: thisdata.depName,
  1490. orderStatus: thisdata.orderStatus,
  1491. projectStatus: thisdata.projectStatus,
  1492. commodityName: thisdata.commodityName,
  1493. totalAmount: thisdata.totalAmount,
  1494. liquidationStatus: thisdata.liquidationStatus,
  1495. settlementAmount: thisdata.settlementAmount,
  1496. accountsReceivable: thisdata.accountsReceivable,
  1497. dunSubject: thisdata.dunSubject,
  1498. startDate: thisdata.startDate,
  1499. taskStatus: thisdata.taskStatus,
  1500. cname: thisdata.cname,
  1501. id: thisdata.id,
  1502. taskName: thisdata.taskName,
  1503. hours: thisdata.hours,
  1504. taskDistributionTime: thisdata.taskDistributionTime,
  1505. taskEndTime: thisdata.taskEndTime,
  1506. commodityQuantity: thisdata.commodityQuantity,
  1507. commodityPrice: thisdata.commodityPrice,
  1508. certificateNumber: thisdata.certificateNumber,
  1509. taskComment: thisdata.taskComment,
  1510. outsourceName: thisdata.outsourceName,
  1511. outsourcePrice: thisdata.outsourcePrice,
  1512. outsource: thisdata.outsource,
  1513. splitStatus: thisdata.splitStatus
  1514. });
  1515. }
  1516. }
  1517. totalWaibao = (Math.round(totalWaibao * 10000) / 10000).toFixed(4);
  1518. this.setState({
  1519. proDataList: theArr,
  1520. totalWaibao
  1521. });
  1522. }.bind(this)
  1523. }).always(
  1524. function() {
  1525. this.setState({
  1526. loading: false
  1527. });
  1528. }.bind(this)
  1529. );
  1530. },
  1531. tableRowClickPro(record) {
  1532. this.setState({
  1533. pvisible: true,
  1534. record
  1535. });
  1536. },
  1537. render() {
  1538. const formItemLayout = {
  1539. labelCol: { span: 8 },
  1540. wrapperCol: { span: 14 }
  1541. };
  1542. const { RangePicker } = DatePicker;
  1543. var departmentArr = this.state.departmentArr || [];
  1544. const { loading, selectedRowKeys, visible } = this.state;
  1545. const rowSelection = {
  1546. selectedRowKeys,
  1547. onChange: this.onSelectChange,
  1548. hideDefaultSelections: true,
  1549. type: "radio"
  1550. };
  1551. return (
  1552. <div className="user-content">
  1553. {this.state.resVisible ? (
  1554. <ResolutionDetail
  1555. cancel={this.resCancel}
  1556. detail={this.state.resRecord}
  1557. visible={this.state.resVisible}
  1558. id={this.state.resRecord.orderNo}
  1559. />
  1560. ) : (
  1561. ""
  1562. )}
  1563. <div className="content-title" style={{ marginBottom: 10 }}>
  1564. <span style={{ fontWeight: 900, fontSize: 16 }}>收款结算</span>
  1565. </div>
  1566. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  1567. <TabPane tab="更改表格显示数据" key="1">
  1568. <div style={{ marginLeft: 10 }}>
  1569. <ChooseList
  1570. columns={this.state.columns}
  1571. changeFn={this.changeList}
  1572. changeList={this.state.changeList}
  1573. top={55}
  1574. margin={11}
  1575. />
  1576. </div>
  1577. </TabPane>
  1578. <TabPane tab="搜索" key="2">
  1579. <div className="user-search" style={{ marginLeft: 10 }}>
  1580. <Input
  1581. placeholder="订单编号"
  1582. value={this.state.orderNoSearch}
  1583. onChange={e => {
  1584. this.setState({ orderNoSearch: e.target.value });
  1585. }}
  1586. />
  1587. <Input
  1588. placeholder="客户名称"
  1589. value={this.state.nameSearch}
  1590. onChange={e => {
  1591. this.setState({ nameSearch: e.target.value });
  1592. }}
  1593. />
  1594. <Select
  1595. placeholder="订单部门"
  1596. style={{ width: 120, marginRight: 10 }}
  1597. value={this.state.departmenttList}
  1598. onChange={e => {
  1599. this.setState({ departmenttList: e });
  1600. }}
  1601. >
  1602. {departmentArr.map(function(item) {
  1603. return (
  1604. <Select.Option key={item.id}>{item.name}</Select.Option>
  1605. );
  1606. })}
  1607. </Select>
  1608. <Input
  1609. placeholder="合同编号"
  1610. value={this.state.contractNoSearch}
  1611. onChange={e => {
  1612. this.setState({
  1613. contractNoSearch: e.target.value
  1614. });
  1615. }}
  1616. />
  1617. <Select
  1618. placeholder="流程状态"
  1619. onChange={e => {
  1620. this.setState({ processStatusSearch: e });
  1621. }}
  1622. style={{ width: 120, marginRight: 5 }}
  1623. value={this.state.processStatusSearch}
  1624. >
  1625. <Option value="3">未分配</Option>
  1626. <Option value="4">已分配</Option>
  1627. <Option value="9">已驳回</Option>
  1628. </Select>
  1629. <Select
  1630. placeholder="结算状态"
  1631. onChange={e => {
  1632. this.setState({ liquidationStatus: e });
  1633. }}
  1634. style={{ width: 120, marginRight: 5 }}
  1635. value={this.state.liquidationStatus}
  1636. >
  1637. <Option value="0">首付待付清</Option>
  1638. <Option value="1">尾款待付清</Option>
  1639. <Option value="2">已付清</Option>
  1640. </Select>
  1641. <Select
  1642. style={{ width: 120 }}
  1643. placeholder="签单金额"
  1644. value={this.state.amountStatus}
  1645. onChange={e => {
  1646. this.setState({
  1647. amountStatus: e
  1648. });
  1649. }}
  1650. >
  1651. <Option value="0">10万元以下</Option>
  1652. <Option value="1">10~20万元</Option>
  1653. <Option value="2">20~30万元</Option>
  1654. <Option value="3">30~40万元</Option>
  1655. <Option value="4">40万元以上</Option>
  1656. </Select>
  1657. <span style={{}}>下单日期:</span>
  1658. <RangePicker
  1659. value={[
  1660. this.state.releaseDate[0]
  1661. ? moment(this.state.releaseDate[0])
  1662. : null,
  1663. this.state.releaseDate[1]
  1664. ? moment(this.state.releaseDate[1])
  1665. : null
  1666. ]}
  1667. onChange={(data, dataString) => {
  1668. this.setState({ releaseDate: dataString });
  1669. }}
  1670. />
  1671. <span style={{}}>最近收款:</span>
  1672. <RangePicker
  1673. value={[
  1674. this.state.shouKuanDate[0]
  1675. ? moment(this.state.shouKuanDate[0])
  1676. : null,
  1677. this.state.shouKuanDate[1]
  1678. ? moment(this.state.shouKuanDate[1])
  1679. : null
  1680. ]}
  1681. onChange={(data, dataString) => {
  1682. this.setState({ shouKuanDate: dataString });
  1683. }}
  1684. />
  1685. <Button
  1686. type="primary"
  1687. onClick={this.search}
  1688. style={{ marginLeft: 10 }}
  1689. disabled={this.state.loadingA ? true : false}
  1690. >
  1691. 搜索
  1692. </Button>
  1693. <Button onClick={this.reset}>重置</Button>
  1694. </div>
  1695. </TabPane>
  1696. <TabPane tab="打印" key="3">
  1697. <Button
  1698. type="primary"
  1699. style={{ margin: "11px 0px 10px 10px" }}
  1700. onClick={this.printAll}
  1701. disabled={!this.state.dataSource.length}
  1702. >
  1703. 打印所有列表信息
  1704. </Button>
  1705. <Button
  1706. type="primary"
  1707. disabled={this.state.selectedRowKeys.length != 1}
  1708. style={{ margin: "11px 0px 10px 10px" }}
  1709. onClick={() => {
  1710. this.inRecordData();
  1711. this.setState({
  1712. bvisible: true
  1713. });
  1714. }}
  1715. >
  1716. 打印开票详情
  1717. </Button>
  1718. <Button
  1719. type="primary"
  1720. disabled={this.state.selectedRowKeys.length != 1}
  1721. style={{ margin: "11px 0px 10px 10px" }}
  1722. onClick={() => {
  1723. this.waterData();
  1724. this.setState({
  1725. cvisible: true
  1726. });
  1727. }}
  1728. >
  1729. 打印收款流水
  1730. </Button>
  1731. <Button
  1732. type="primary"
  1733. disabled={this.state.selectedRowKeys.length != 1}
  1734. style={{ margin: "11px 0px 10px 10px" }}
  1735. onClick={() => {
  1736. this.timeData();
  1737. this.setState({
  1738. timeVisible: true
  1739. });
  1740. }}
  1741. >
  1742. 打印工时信息
  1743. </Button>
  1744. <Button
  1745. type="primary"
  1746. disabled={this.state.selectedRowKeys.length != 1}
  1747. style={{ margin: "11px 0px 10px 10px" }}
  1748. onClick={() => {
  1749. this.cuiData();
  1750. this.setState({
  1751. cuiVisible: true
  1752. });
  1753. }}
  1754. >
  1755. 打印催款信息
  1756. </Button>
  1757. <Button
  1758. type="primary"
  1759. disabled={this.state.selectedRowKeys.length != 1}
  1760. style={{ margin: "11px 0px 10px 10px" }}
  1761. onClick={() => {
  1762. this.proData();
  1763. this.setState({
  1764. proVisible: true
  1765. });
  1766. }}
  1767. >
  1768. 打印项目信息
  1769. </Button>
  1770. </TabPane>
  1771. <TabPane tab="导出Excel" key="4">
  1772. <Button
  1773. type="primary"
  1774. style={{ margin: "11px 0px 10px 10px" }}
  1775. onClick={this.exportAll}
  1776. >
  1777. 导出当前列表
  1778. </Button>
  1779. <Button
  1780. type="primary"
  1781. disabled={this.state.selectedRowKeys.length != 1}
  1782. style={{ margin: "11px 0px 10px 10px" }}
  1783. onClick={this.exportKaip}
  1784. >
  1785. 导出所选开票详情
  1786. </Button>
  1787. <Button
  1788. type="primary"
  1789. disabled={this.state.selectedRowKeys.length != 1}
  1790. style={{ margin: "11px 0px 10px 10px" }}
  1791. onClick={this.exportWater}
  1792. >
  1793. 导出所选收款详情流水
  1794. </Button>
  1795. <Button
  1796. type="primary"
  1797. disabled={this.state.selectedRowKeys.length != 1}
  1798. style={{ margin: "11px 0px 10px 10px" }}
  1799. onClick={this.exportTime}
  1800. >
  1801. 导出所选工时信息
  1802. </Button>
  1803. <Button
  1804. type="primary"
  1805. disabled={this.state.selectedRowKeys.length != 1}
  1806. style={{ margin: "11px 0px 10px 10px" }}
  1807. onClick={this.exportCui}
  1808. >
  1809. 导出催款信息
  1810. </Button>
  1811. <Button
  1812. type="primary"
  1813. disabled={this.state.selectedRowKeys.length != 1}
  1814. style={{ margin: "11px 0px 10px 10px" }}
  1815. onClick={this.exportPro}
  1816. >
  1817. 导出项目详情
  1818. </Button>
  1819. </TabPane>
  1820. <TabPane tab="查看" key="5">
  1821. <Button
  1822. type="primary"
  1823. disabled={this.state.selectedRowKeys.length != 1}
  1824. style={{ margin: "11px 0px 10px 10px" }}
  1825. onClick={() => {
  1826. this.inRecordData();
  1827. this.setState({
  1828. bvisible: true
  1829. });
  1830. }}
  1831. >
  1832. 查看开票详情
  1833. </Button>
  1834. <Button
  1835. type="primary"
  1836. disabled={this.state.selectedRowKeys.length != 1}
  1837. style={{ margin: "11px 0px 10px 10px" }}
  1838. onClick={() => {
  1839. this.waterData();
  1840. this.setState({
  1841. cvisible: true
  1842. });
  1843. }}
  1844. >
  1845. 详情收款流水
  1846. </Button>
  1847. <Button
  1848. type="primary"
  1849. disabled={this.state.selectedRowKeys.length != 1}
  1850. style={{ margin: "11px 0px 10px 10px" }}
  1851. onClick={() => {
  1852. this.timeData();
  1853. this.setState({
  1854. timeVisible: true
  1855. });
  1856. }}
  1857. >
  1858. 工时信息
  1859. </Button>
  1860. <Button
  1861. type="primary"
  1862. disabled={this.state.selectedRowKeys.length != 1}
  1863. style={{ margin: "11px 0px 10px 10px" }}
  1864. onClick={() => {
  1865. this.cuiData();
  1866. this.setState({
  1867. cuiVisible: true
  1868. });
  1869. }}
  1870. >
  1871. 催款信息
  1872. </Button>
  1873. <Button
  1874. type="primary"
  1875. disabled={this.state.selectedRowKeys.length != 1}
  1876. style={{ margin: "11px 0px 10px 10px" }}
  1877. onClick={() => {
  1878. this.proData();
  1879. this.setState({
  1880. proVisible: true
  1881. });
  1882. }}
  1883. >
  1884. 项目信息
  1885. </Button>
  1886. </TabPane>
  1887. {/* <TabPane tab="批量操作" key="6">
  1888. <Button
  1889. type="primary"
  1890. disabled={this.state.selectedRowKeys.length == 0}
  1891. style={{ margin: "0px 0px 10px 10px" }}
  1892. onClick={e => {
  1893. e.stopPropagation(),
  1894. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  1895. }}
  1896. >
  1897. 转交
  1898. </Button>
  1899. </TabPane> */}
  1900. </Tabs>
  1901. <div className="patent-table">
  1902. <Spin spinning={this.state.loadingA}>
  1903. <Table
  1904. bordered
  1905. columns={
  1906. this.state.changeList == undefined
  1907. ? this.state.columns
  1908. : this.state.changeList
  1909. }
  1910. dataSource={this.state.dataSource}
  1911. rowSelection={rowSelection}
  1912. scroll={{ x: "max-content", y: 0 }}
  1913. pagination={this.state.pagination}
  1914. onRowDoubleClick={this.tableRowClick.bind(this)}
  1915. size="small"
  1916. />
  1917. </Spin>
  1918. <p
  1919. style={{ display: "inline-block", fontSize: "14px", color: "red" }}
  1920. >
  1921. {
  1922. <span style={{ marginRight: 10 }}>
  1923. {`收款金额总计(万元):${this.state.hui ? this.state.hui : "0"}`}
  1924. </span>
  1925. }
  1926. {
  1927. <span>
  1928. {`合同额总计(万元):${
  1929. this.state.totalHui ? this.state.totalHui : "0"
  1930. }`}
  1931. </span>
  1932. }
  1933. </p>
  1934. </div>
  1935. <Assign
  1936. title="任务"
  1937. selApi={"/api/admin/newOrder/updateFinance"}
  1938. data={this.state.assignDataY}
  1939. showDesc={this.state.assignVisibleY}
  1940. closeDesc={this.closeAssignY.bind(this)}
  1941. // fenpaiData={8}
  1942. specially={0}
  1943. roleName={this.state.nub}
  1944. requestMethod={"get"}
  1945. />
  1946. <OrderDesc
  1947. data={this.state.RowData}
  1948. showDesc={this.state.showDesc}
  1949. closeDesc={this.closeDesc.bind(this)}
  1950. />
  1951. <Receivable
  1952. title="收款记录"
  1953. api="/api/admin/financial/addReceiptsFlow"
  1954. data={this.state.assignDataX}
  1955. showDesc={this.state.assignVisibleX}
  1956. closeDesc={this.closeAssignX.bind(this)}
  1957. />
  1958. <Modal
  1959. visible={this.state.boHuiVisible}
  1960. width="400px"
  1961. title="驳回备注"
  1962. footer=""
  1963. onOk={this.boHuiOk}
  1964. onCancel={this.boHuiCancel}
  1965. >
  1966. <Form layout="horizontal" onSubmit={this.boHuiSubmit}>
  1967. <Spin spinning={this.state.loading}>
  1968. <FormItem
  1969. labelCol={{ span: 5 }}
  1970. wrapperCol={{ span: 16 }}
  1971. label={
  1972. <span>
  1973. <strong style={{ color: "#f00" }}>*</strong>驳回原因
  1974. </span>
  1975. }
  1976. >
  1977. <Input
  1978. type="textarea"
  1979. rows={4}
  1980. placeholder="请输入驳回原因"
  1981. value={this.state.content}
  1982. onChange={e => {
  1983. this.setState({ content: e.target.value });
  1984. }}
  1985. />
  1986. </FormItem>
  1987. <FormItem wrapperCol={{ span: 12, offset: 5 }}>
  1988. <Button
  1989. type="primary"
  1990. htmlType="submit"
  1991. style={{ marginRight: 20 }}
  1992. >
  1993. 驳回
  1994. </Button>
  1995. <Button
  1996. type="default"
  1997. onClick={() => {
  1998. this.boHuiCancel();
  1999. }}
  2000. >
  2001. 取消
  2002. </Button>
  2003. </FormItem>
  2004. </Spin>
  2005. </Form>
  2006. </Modal>
  2007. <Modal
  2008. visible={this.state.bvisible}
  2009. footer=""
  2010. title="开票历史记录"
  2011. className="admin-desc-content"
  2012. width="900px"
  2013. onCancel={this.inRecordCanl}
  2014. >
  2015. <Spin spinning={this.state.loading}>
  2016. <div
  2017. className="patent-table"
  2018. ref={e => {
  2019. this.refs.kaiPiao = e;
  2020. }}
  2021. >
  2022. <Table
  2023. columns={this.state.columnsDate}
  2024. dataSource={this.state.recordData}
  2025. pagination={false}
  2026. bordered
  2027. size="small"
  2028. />
  2029. <div className="clearfix" style={{ marginTop: "20px" }}>
  2030. <FormItem
  2031. className="half-item"
  2032. {...formItemLayout}
  2033. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  2034. >
  2035. <span>{this.state.sum + "(万元)"}</span>
  2036. </FormItem>
  2037. </div>
  2038. <ReactToPrint
  2039. trigger={() => (
  2040. <Button
  2041. type="primary"
  2042. style={{
  2043. float: "right",
  2044. // marginTop: 10,
  2045. position: "absolute",
  2046. top: -54,
  2047. right: 30
  2048. }}
  2049. >
  2050. 打印
  2051. </Button>
  2052. )}
  2053. content={() => this.refs.kaiPiao}
  2054. />
  2055. </div>
  2056. </Spin>
  2057. </Modal>
  2058. <Modal
  2059. visible={this.state.cvisible}
  2060. footer=""
  2061. title="详细收款流水"
  2062. className="admin-desc-content"
  2063. width="1300px"
  2064. onCancel={this.waterCanl}
  2065. >
  2066. <Spin spinning={this.state.loading}>
  2067. <div
  2068. className="patent-table"
  2069. ref={e => {
  2070. this.refs.shouKuan = e;
  2071. }}
  2072. >
  2073. <Table
  2074. columns={this.state.waterlistDate}
  2075. dataSource={this.state.waterData}
  2076. pagination={false}
  2077. scroll={{ x: "max-content", y: 0 }}
  2078. bordered
  2079. size="small"
  2080. />
  2081. <div className="clearfix" style={{ marginTop: "20px" }}>
  2082. <FormItem
  2083. className="half-item"
  2084. {...formItemLayout}
  2085. label={<span style={{ fontSize: "14px" }}>总计金额</span>}
  2086. >
  2087. <span>{this.state.waterSum + "(万元)"}</span>
  2088. </FormItem>
  2089. </div>
  2090. <ReactToPrint
  2091. trigger={() => (
  2092. <Button
  2093. type="primary"
  2094. style={{
  2095. float: "right",
  2096. position: "absolute",
  2097. top: -54,
  2098. right: 30
  2099. }}
  2100. >
  2101. 打印
  2102. </Button>
  2103. )}
  2104. content={() => this.refs.shouKuan}
  2105. />
  2106. </div>
  2107. </Spin>
  2108. </Modal>
  2109. <Modal
  2110. visible={this.state.dvisible}
  2111. footer=""
  2112. title="所有列表信息"
  2113. className="admin-desc-content"
  2114. width="1300px"
  2115. onCancel={() => {
  2116. this.loadData();
  2117. this.setState({
  2118. dvisible: false
  2119. });
  2120. }}
  2121. >
  2122. <Spin spinning={this.state.loading}>
  2123. <div
  2124. className="patent-table"
  2125. style={{
  2126. // width: 900,
  2127. // position: "relative",
  2128. // left: "50%",
  2129. // transform: "translate(-50%)",
  2130. padding: "25px 0 30px 30px"
  2131. }}
  2132. ref={e => {
  2133. this.refs.all = e;
  2134. }}
  2135. >
  2136. <Table
  2137. columns={this.state.printColumns}
  2138. dataSource={this.state.dataSource}
  2139. pagination={false}
  2140. bordered
  2141. size="small"
  2142. />
  2143. </div>
  2144. </Spin>
  2145. <ReactToPrint
  2146. trigger={() => (
  2147. <Button
  2148. type="primary"
  2149. style={{
  2150. float: "right",
  2151. marginTop: 10,
  2152. position: "absolute",
  2153. top: 0,
  2154. right: 30
  2155. }}
  2156. >
  2157. 打印
  2158. </Button>
  2159. )}
  2160. content={() => this.refs.all}
  2161. />
  2162. </Modal>
  2163. <Modal
  2164. visible={this.state.timeVisible}
  2165. footer=""
  2166. title="工时详情"
  2167. className="admin-desc-content"
  2168. width="1300px"
  2169. pagination={false}
  2170. onCancel={() => {
  2171. this.loadData();
  2172. this.setState({
  2173. timeVisible: false
  2174. });
  2175. }}
  2176. >
  2177. <Spin spinning={this.state.loading}>
  2178. <Project
  2179. record={this.state.record}
  2180. visible={this.state.pvisible}
  2181. cancel={() => {
  2182. this.setState({ pvisible: false });
  2183. }}
  2184. />
  2185. <div
  2186. className="patent-table"
  2187. style={
  2188. {
  2189. // width: 900,
  2190. // position: "relative",
  2191. // left: "50%",
  2192. // transform: "translate(-50%)",
  2193. // padding: "25px 0 30px 30px"
  2194. }
  2195. }
  2196. ref={e => {
  2197. this.refs.all = e;
  2198. }}
  2199. >
  2200. <Table
  2201. columns={this.state.timeColumns}
  2202. dataSource={this.state.timeDataList}
  2203. onRowClick={this.tableRowClickPro}
  2204. scroll={{ x: "max-content", y: 0 }}
  2205. pagination={false}
  2206. bordered
  2207. size="small"
  2208. />
  2209. </div>
  2210. </Spin>
  2211. <ReactToPrint
  2212. trigger={() => (
  2213. <Button
  2214. type="primary"
  2215. style={{
  2216. float: "right",
  2217. marginTop: 10,
  2218. position: "absolute",
  2219. top: 0,
  2220. right: 30
  2221. }}
  2222. >
  2223. 打印
  2224. </Button>
  2225. )}
  2226. content={() => this.refs.all}
  2227. />
  2228. </Modal>
  2229. <Modal
  2230. visible={this.state.cuiVisible}
  2231. footer=""
  2232. title="催款详情"
  2233. className="admin-desc-content"
  2234. width="1300px"
  2235. pagination={false}
  2236. onCancel={() => {
  2237. this.loadData();
  2238. this.setState({
  2239. cuiVisible: false
  2240. });
  2241. }}
  2242. >
  2243. <Spin spinning={this.state.loading}>
  2244. <div
  2245. className="patent-table"
  2246. style={
  2247. {
  2248. // width: 900,
  2249. // position: "relative",
  2250. // left: "50%",
  2251. // transform: "translate(-50%)",
  2252. // padding: "25px 0 30px 30px"
  2253. }
  2254. }
  2255. ref={e => {
  2256. this.refs.all = e;
  2257. }}
  2258. >
  2259. <Table
  2260. columns={this.state.cuiColumns}
  2261. dataSource={this.state.cuiDataList}
  2262. scroll={{ x: "max-content", y: 0 }}
  2263. pagination={false}
  2264. bordered
  2265. size="small"
  2266. />
  2267. </div>
  2268. </Spin>
  2269. <ReactToPrint
  2270. trigger={() => (
  2271. <Button
  2272. type="primary"
  2273. style={{
  2274. float: "right",
  2275. marginTop: 10,
  2276. position: "absolute",
  2277. top: 0,
  2278. right: 30
  2279. }}
  2280. >
  2281. 打印
  2282. </Button>
  2283. )}
  2284. content={() => this.refs.all}
  2285. />
  2286. </Modal>
  2287. <Modal
  2288. visible={this.state.proVisible}
  2289. footer=""
  2290. title="项目详情"
  2291. className="admin-desc-content"
  2292. width="1300px"
  2293. pagination={false}
  2294. onCancel={() => {
  2295. this.loadData();
  2296. this.setState({
  2297. proVisible: false
  2298. });
  2299. }}
  2300. >
  2301. <Spin spinning={this.state.loading}>
  2302. <Project
  2303. record={this.state.record}
  2304. visible={this.state.pvisible}
  2305. cancel={() => {
  2306. this.setState({ pvisible: false });
  2307. }}
  2308. />
  2309. <div
  2310. className="patent-table"
  2311. style={
  2312. {
  2313. // width: 900,
  2314. // position: "relative",
  2315. // left: "50%",
  2316. // transform: "translate(-50%)",
  2317. // padding: "25px 0 30px 30px"
  2318. }
  2319. }
  2320. ref={e => {
  2321. this.refs.all = e;
  2322. }}
  2323. >
  2324. <Table
  2325. columns={this.state.proColumns}
  2326. dataSource={this.state.proDataList}
  2327. onRowClick={this.tableRowClickPro}
  2328. scroll={{ x: "max-content", y: 0 }}
  2329. pagination={false}
  2330. bordered
  2331. size="small"
  2332. />
  2333. </div>
  2334. <span style={{ display: "block", marginTop: 10, color: "red" }}>
  2335. 外包(内部)价格总计(万元):{this.state.totalWaibao}
  2336. </span>
  2337. </Spin>
  2338. <ReactToPrint
  2339. trigger={() => (
  2340. <Button
  2341. type="primary"
  2342. style={{
  2343. float: "right",
  2344. marginTop: 10,
  2345. position: "absolute",
  2346. top: 0,
  2347. right: 30
  2348. }}
  2349. >
  2350. 打印
  2351. </Button>
  2352. )}
  2353. content={() => this.refs.all}
  2354. />
  2355. </Modal>
  2356. </div>
  2357. );
  2358. }
  2359. });
  2360. export default ShouKuang;