shouKuanAll.jsx 74 KB

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