shouKuang.jsx 75 KB

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