shouKuanAll.jsx 72 KB

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