approvedOutsourcing.jsx 97 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import moment from "moment";
  4. import "./public.less";
  5. import {
  6. Button,
  7. Form,
  8. Input,
  9. Select,
  10. Spin,
  11. Table,
  12. message,
  13. DatePicker,
  14. Modal,
  15. Upload,
  16. Tabs
  17. } from "antd";
  18. import Receivable from "./receivable";
  19. import Assign from "@/manageCenter/publicComponent/assign";
  20. import ReactToPrint from "react-to-print";
  21. import OrderRiZi from "@/orderRiZi.jsx";
  22. import {
  23. getjiedian,
  24. getProcessStatus,
  25. getApproval,
  26. getNewOrderType,
  27. getLiquidationStatus,
  28. getProjectStatus,
  29. splitUrl,
  30. getprovince,
  31. getRefundStatus,
  32. getTransactionProject,
  33. getTaskStatus,
  34. getNewOrderStatus,
  35. } from "@/tools";
  36. import { ChooseList } from "../../../../component/manageCenter/order/orderNew/chooseList";
  37. const FormItem = Form.Item;
  38. const approvedOutsourcing = React.createClass({
  39. departmentList() {
  40. this.setState({
  41. loading: true
  42. });
  43. $.ajax({
  44. method: "get",
  45. dataType: "json",
  46. crossDomain: false,
  47. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  48. data: {},
  49. success: function(data) {
  50. let thedata = data.data;
  51. let theArr = [];
  52. if (!thedata) {
  53. if (data.error && data.error.length) {
  54. message.warning(data.error[0].message);
  55. }
  56. } else {
  57. thedata.map(function(item, index) {
  58. theArr.push({
  59. key: index,
  60. name: item.name,
  61. id: item.id
  62. });
  63. });
  64. }
  65. this.setState({
  66. departmentArr: theArr
  67. });
  68. }.bind(this)
  69. }).always(
  70. function() {
  71. this.setState({
  72. loading: false
  73. });
  74. }.bind(this)
  75. );
  76. },
  77. loadData(pageNo, pageSize) {
  78. this.state.data = [];
  79. this.setState({
  80. page: pageNo,
  81. loading: true
  82. });
  83. $.ajax({
  84. method: "get",
  85. dataType: "json",
  86. crossDomain: false,
  87. url: globalConfig.context + "/api/admin/financial/financeList",
  88. data: {
  89. pageNo: pageNo || 1,
  90. pageSize: pageSize || this.state.pagination.pageSize,
  91. buyerName: this.state.nameSearch, //客户名称
  92. orderNo: this.state.orderNoSearch,
  93. startTime: this.state.releaseDate[0],
  94. endTime: this.state.releaseDate[1],
  95. startFinalReceivablesTime: this.state.shouKuanDate[0],
  96. endFinalReceivablesTime: this.state.shouKuanDate[1],
  97. departmentId: this.state.departmenttList,
  98. processStatus: this.state.processStatusSearch,
  99. contractNo: this.state.contractNoSearch,
  100. outsource: 1,
  101. liquidationStatus: this.state.liquidationStatus
  102. },
  103. success: function(data) {
  104. let theArr = [];
  105. if (!data.data || !data.data.pagination.list) {
  106. if (data.error && data.error.length) {
  107. message.warning(data.error[0].message);
  108. }
  109. } else {
  110. for (let i = 0; i < data.data.pagination.list.length; i++) {
  111. let thisdata = data.data.pagination.list[i];
  112. theArr.push({
  113. key: thisdata.orderNo,
  114. orderNo: thisdata.orderNo,
  115. orderType: thisdata.orderType,
  116. orderStatus: thisdata.orderStatus,
  117. sellerName: thisdata.sellerName,
  118. processStatus: thisdata.processStatus,
  119. liquidationStatus: thisdata.liquidationStatus,
  120. approval: thisdata.approval,
  121. buyerName: thisdata.buyerName,
  122. actuallyTotalAmount: thisdata.actuallyTotalAmount,
  123. signTime: thisdata.signTime,
  124. companyId: thisdata.companyId,
  125. companyName: thisdata.companyName,
  126. buyerId: thisdata.buyerId,
  127. buyerName: thisdata.buyerName,
  128. contractNo: thisdata.contractNo,
  129. createTime: thisdata.createTime,
  130. departmentName: thisdata.departmentName,
  131. outsourceName: thisdata.outsourceName,
  132. invoiceAmount: thisdata.invoiceAmount,
  133. finalReceivables: thisdata.finalReceivables,
  134. finalReceivablesTime: thisdata.finalReceivablesTime,
  135. signTotalAmount: thisdata.signTotalAmount,
  136. outsourceAmount: thisdata.outsourceAmount,
  137. financeName: thisdata.financeName,
  138. outsourceAmount: thisdata.outsourceAmount
  139. });
  140. }
  141. }
  142. this.state.pagination.current = data.data.pagination.pageNo;
  143. this.state.pagination.total = data.data.pagination.totalCount;
  144. if (
  145. data.data &&
  146. data.data.pagination.list &&
  147. !data.data.pagination.list.length
  148. ) {
  149. this.state.pagination.current = 0;
  150. this.state.pagination.total = 0;
  151. }
  152. this.setState({
  153. totalPage: data.data.pagination.totalPage,
  154. dataSource: theArr,
  155. pagination: this.state.pagination,
  156. totalHui: data.data.count ? data.data.count.signTotalAmount : 0,
  157. hui: data.data.count ? data.data.count.actuallyTotalAmount : 0
  158. });
  159. }.bind(this)
  160. }).always(
  161. function() {
  162. this.setState({
  163. loading: false
  164. });
  165. }.bind(this)
  166. );
  167. },
  168. getInitialState() {
  169. return {
  170. rotateDeg: 0,
  171. searchMore: true,
  172. assignVisibleX: false,
  173. assignVisibleY: false,
  174. releaseDate: [],
  175. shouKuanDate: [],
  176. assignDataX: [],
  177. assignDataY: [],
  178. attachmentUrl: [],
  179. pictureUrl: [],
  180. totalPage: 0,
  181. modKey: "1",
  182. width: "800px",
  183. boHuivisible: false,
  184. selectedRowKeys: [],
  185. selectedRows: [],
  186. loading: false,
  187. pagination: {
  188. defaultCurrent: 1,
  189. defaultPageSize: 10,
  190. showQuickJumper: true,
  191. pageSize: 10,
  192. onChange: function(page) {
  193. this.loadData(page);
  194. }.bind(this),
  195. showTotal: function(total) {
  196. return "共" + total + "条数据";
  197. }
  198. },
  199. // 子组件改变的表格title数组
  200. changeList: undefined,
  201. columns: [
  202. {
  203. title: "合同编号",
  204. dataIndex: "contractNo",
  205. key: "contractNo",
  206. className: "title-table"
  207. },
  208. {
  209. title: "订单编号",
  210. dataIndex: "orderNo",
  211. key: "orderNo",
  212. className: "title-table"
  213. // fixed: "left"
  214. },
  215. {
  216. title: "客户名称",
  217. dataIndex: "buyerName",
  218. key: "buyerName",
  219. className: "title-table"
  220. },
  221. {
  222. title: "订单部门",
  223. dataIndex: "departmentName",
  224. key: "departmentName",
  225. className: "title-table"
  226. },
  227. {
  228. title: "订单负责人",
  229. dataIndex: "sellerName",
  230. key: "sellerName",
  231. className: "title-table"
  232. },
  233. {
  234. title: "财务负责人",
  235. dataIndex: "financeName",
  236. key: "financeName",
  237. className: "title-table"
  238. },
  239. {
  240. title: "外包公司",
  241. dataIndex: "outsourceName",
  242. key: "outsourceName",
  243. className: "title-table"
  244. },
  245. {
  246. title: "外包成本",
  247. dataIndex: "outsourceAmount",
  248. key: "outsourceAmount",
  249. className: "title-table"
  250. },
  251. {
  252. title: "签单日期",
  253. dataIndex: "signTime",
  254. key: "signTime",
  255. className: "title-table"
  256. },
  257. {
  258. title: "下单日期",
  259. dataIndex: "createTime",
  260. key: "createTime",
  261. className: "title-table"
  262. },
  263. {
  264. title: "签单金额(万元)",
  265. dataIndex: "signTotalAmount",
  266. key: "signTotalAmount",
  267. className: "title-table"
  268. },
  269. {
  270. title: "开票金额(万元)",
  271. dataIndex: "invoiceAmount",
  272. key: "invoiceAmount",
  273. className: "title-table"
  274. },
  275. {
  276. title: "已收款(万元)",
  277. dataIndex: "actuallyTotalAmount",
  278. key: "actuallyTotalAmount",
  279. className: "title-table"
  280. },
  281. {
  282. title: "最近收款(万元)",
  283. dataIndex: "finalReceivables",
  284. key: "finalReceivables",
  285. className: "title-table"
  286. },
  287. {
  288. title: "最近收款时间",
  289. dataIndex: "finalReceivablesTime",
  290. key: "finalReceivablesTime",
  291. className: "title-table"
  292. },
  293. {
  294. title: "结算状态",
  295. dataIndex: "liquidationStatus",
  296. key: "liquidationStatus",
  297. className: "title-table",
  298. render: text => {
  299. return getLiquidationStatus(text);
  300. }
  301. },
  302. {
  303. title: "流程状态",
  304. dataIndex: "processStatus",
  305. key: "processStatus",
  306. className: "title-table",
  307. render: text => {
  308. return getProcessStatus(text);
  309. }
  310. },
  311. {
  312. title: "特批状态",
  313. dataIndex: "approval",
  314. key: "approval",
  315. className: "title-table",
  316. render: text => {
  317. return getApproval(text);
  318. }
  319. },
  320. {
  321. title: "操作",
  322. dataIndex: "caozuo",
  323. key: "caouzo",
  324. className: "title-table",
  325. render: (text, recard) => {
  326. return (
  327. <div>
  328. {/* {recard.liquidationStatus < 2 &&
  329. (recard.approval === 1 || recard.approval === 2) ? (
  330. <Button
  331. style={{ background: "rgb(192,192,192)" }}
  332. onClick={e => {
  333. e.stopPropagation(), this.evaluateX(recard);
  334. }}
  335. >
  336. 收款
  337. </Button>
  338. ) : (
  339. <Button
  340. type="primary"
  341. onClick={e => {
  342. e.stopPropagation(), this.evaluateX(recard);
  343. }}
  344. >
  345. 收款
  346. </Button>
  347. )} */}
  348. {recard.processStatus < 4 ? (
  349. <Button
  350. type="primary"
  351. onClick={e => {
  352. // e.stopPropagation(), this.evaluateZ(recard);
  353. e.stopPropagation(), this.checkRemark(recard);
  354. }}
  355. style={{ marginLeft: "5px" }}
  356. >
  357. 通过
  358. </Button>
  359. ) : (
  360. ""
  361. )}
  362. {!(
  363. recard.actuallyTotalAmount &&
  364. Number(recard.actuallyTotalAmount) > 0
  365. ) && (
  366. <Button
  367. type="danger"
  368. style={{ marginLeft: "5px" }}
  369. onClick={e => {
  370. e.stopPropagation(), this.reject(recard);
  371. }}
  372. >
  373. 驳回
  374. </Button>
  375. )}
  376. {
  377. // <Button
  378. // type="primary"
  379. // style={{ marginLeft: "5px" }}
  380. // onClick={e => {
  381. // e.stopPropagation(), this.evaluateY(recard, "财务专员");
  382. // console.log(recard);
  383. // }}
  384. // >
  385. // 转交
  386. // </Button>
  387. }
  388. </div>
  389. );
  390. }
  391. }
  392. ],
  393. proColumns: [
  394. {
  395. title: "序号",
  396. dataIndex: "key",
  397. key: "key"
  398. },
  399. {
  400. title: "合同编号",
  401. dataIndex: "contractNo",
  402. key: "contractNo"
  403. },
  404. {
  405. title: "订单编号",
  406. dataIndex: "orderNo",
  407. key: "orderNo"
  408. },
  409. {
  410. title: "客户名称",
  411. dataIndex: "userName",
  412. key: "userName"
  413. },
  414. {
  415. title: "订单负责人",
  416. dataIndex: "salesmanName",
  417. key: "salesmanName"
  418. },
  419. {
  420. title: "是否主项目",
  421. dataIndex: "main",
  422. key: "main",
  423. render: text => {
  424. return text == 0 ? "否" : "是";
  425. }
  426. },
  427. {
  428. title: "项目类别",
  429. dataIndex: "cname",
  430. key: "cname"
  431. },
  432. {
  433. title: "项目名称",
  434. dataIndex: "commodityName",
  435. key: "commodityName"
  436. },
  437. {
  438. title: "项目数量",
  439. dataIndex: "commodityQuantity",
  440. key: "commodityQuantity"
  441. },
  442. {
  443. title: "服务市价",
  444. dataIndex: "commodityPrice",
  445. key: "commodityPrice"
  446. },
  447. {
  448. title: "证书编号",
  449. dataIndex: "certificateNumber",
  450. key: "certificateNumber"
  451. },
  452. {
  453. title: "项目状态",
  454. dataIndex: "projectStatus",
  455. key: "projectStatus",
  456. render: text => {
  457. return getProjectStatus(text);
  458. }
  459. },
  460. {
  461. title: "项目说明",
  462. dataIndex: "taskComment",
  463. key: "taskComment"
  464. },
  465. {
  466. title: "外包(内部)公司",
  467. dataIndex: "outsourceName",
  468. key: "outsourceName"
  469. },
  470. {
  471. title: "外包(内部)价格",
  472. dataIndex: "outsourcePrice",
  473. key: "outsourcePrice"
  474. }
  475. ],
  476. cuiColumns: [
  477. {
  478. title: "序号",
  479. dataIndex: "key",
  480. key: "key"
  481. },
  482. {
  483. title: "合同编号",
  484. dataIndex: "contractNo",
  485. key: "contractNo"
  486. },
  487. {
  488. title: "订单编号",
  489. dataIndex: "orderNo",
  490. key: "orderNo"
  491. },
  492. {
  493. title: "客户名称",
  494. dataIndex: "userName",
  495. key: "userName"
  496. },
  497. {
  498. title: "订单负责人",
  499. dataIndex: "salesmanName",
  500. key: "salesmanName"
  501. },
  502. {
  503. title: "订单部门",
  504. dataIndex: "depName",
  505. key: "depName"
  506. },
  507. {
  508. title: "订单状态",
  509. dataIndex: "orderStatus",
  510. key: "orderStatus",
  511. render: text => {
  512. return getNewOrderStatus(text);
  513. }
  514. },
  515. {
  516. title: "项目状态",
  517. dataIndex: "projectStatus",
  518. key: "projectStatus",
  519. render: text => {
  520. return getProjectStatus(text);
  521. }
  522. },
  523. {
  524. title: "签单金额",
  525. dataIndex: "totalAmount",
  526. key: "totalAmount"
  527. },
  528. {
  529. title: "结算状态",
  530. dataIndex: "liquidationStatus",
  531. key: "liquidationStatus",
  532. render: text => {
  533. return getLiquidationStatus(text);
  534. }
  535. },
  536. {
  537. title: "已收款",
  538. dataIndex: "settlementAmount",
  539. key: "settlementAmount"
  540. },
  541. {
  542. title: "应收款",
  543. dataIndex: "accountsReceivable",
  544. key: "accountsReceivable"
  545. },
  546. {
  547. title: "催收科目",
  548. dataIndex: "dunSubject",
  549. key: "dunSubject",
  550. render: text => {
  551. return getjiedian(text);
  552. }
  553. },
  554. {
  555. title: "催收启动时间",
  556. dataIndex: "startDate",
  557. key: "startDate"
  558. }
  559. ],
  560. timeColumns: [
  561. {
  562. title: "序号",
  563. dataIndex: "key",
  564. key: "key"
  565. },
  566. {
  567. title: "合同编号",
  568. dataIndex: "contractNo",
  569. key: "contractNo"
  570. },
  571. {
  572. title: "订单编号",
  573. dataIndex: "orderNo",
  574. key: "orderNo"
  575. },
  576. {
  577. title: "客户名称",
  578. dataIndex: "userName",
  579. key: "userName"
  580. },
  581. {
  582. title: "项目负责人",
  583. dataIndex: "receiverName",
  584. key: "receiverName"
  585. },
  586. {
  587. title: "项目类别",
  588. dataIndex: "cname",
  589. key: "cname"
  590. },
  591. {
  592. title: "项目编号",
  593. dataIndex: "id",
  594. key: "id"
  595. },
  596. {
  597. title: "项目名称",
  598. dataIndex: "taskName",
  599. key: "taskName"
  600. },
  601. {
  602. title: "项目状态",
  603. dataIndex: "taskStatus",
  604. key: "taskStatus",
  605. render: text => {
  606. return getTaskStatus(text);
  607. }
  608. },
  609. {
  610. title: "工时",
  611. dataIndex: "hours",
  612. key: "hours"
  613. },
  614. {
  615. title: "分配时间",
  616. dataIndex: "taskDistributionTime",
  617. key: "taskDistributionTime"
  618. },
  619. {
  620. title: "完成时间",
  621. dataIndex: "taskEndTime",
  622. key: "taskEndTime"
  623. }
  624. ],
  625. printColumns: [
  626. {
  627. title: "合同编号",
  628. dataIndex: "contractNo",
  629. key: "contractNo"
  630. },
  631. {
  632. title: "订单编号",
  633. dataIndex: "orderNo",
  634. key: "orderNo"
  635. // fixed: "left"
  636. },
  637. {
  638. title: "客户名称",
  639. dataIndex: "buyerName",
  640. key: "buyerName"
  641. },
  642. {
  643. title: "订单部门",
  644. dataIndex: "departmentName",
  645. key: "departmentName"
  646. },
  647. {
  648. title: "订单负责人",
  649. dataIndex: "sellerName",
  650. key: "sellerName"
  651. },
  652. {
  653. title: "签单日期",
  654. dataIndex: "signTime",
  655. key: "signTime"
  656. },
  657. {
  658. title: "下单日期",
  659. dataIndex: "createTime",
  660. key: "createTime"
  661. },
  662. {
  663. title: "签单金额(万元)",
  664. dataIndex: "signTotalAmount",
  665. key: "signTotalAmount"
  666. },
  667. {
  668. title: "开票金额(万元)",
  669. dataIndex: "invoiceAmount",
  670. key: "invoiceAmount"
  671. },
  672. {
  673. title: "已收款(万元)",
  674. dataIndex: "actuallyTotalAmount",
  675. key: "actuallyTotalAmount"
  676. },
  677. {
  678. title: "最近收款(万元)",
  679. dataIndex: "finalReceivables",
  680. key: "finalReceivables"
  681. },
  682. {
  683. title: "最近收款时间",
  684. dataIndex: "finalReceivablesTime",
  685. key: "finalReceivablesTime"
  686. },
  687. {
  688. title: "结算状态",
  689. dataIndex: "liquidationStatus",
  690. key: "liquidationStatus",
  691. render: text => {
  692. return getLiquidationStatus(text);
  693. }
  694. },
  695. {
  696. title: "流程状态",
  697. dataIndex: "processStatus",
  698. key: "processStatus",
  699. render: text => {
  700. return getProcessStatus(text);
  701. }
  702. },
  703. {
  704. title: "特批状态",
  705. dataIndex: "approval",
  706. key: "approval",
  707. render: text => {
  708. return getApproval(text);
  709. }
  710. }
  711. ],
  712. columnsX: [
  713. {
  714. title: "业务项目名称",
  715. dataIndex: "commodityName",
  716. key: "commodityName",
  717. render: text => {
  718. return text && text.length > 6 ? (
  719. <span title={text}>{text.substr(0, 8)}...</span>
  720. ) : (
  721. text
  722. );
  723. }
  724. },
  725. {
  726. title: "项目类别",
  727. dataIndex: "cname",
  728. key: "cname"
  729. },
  730. {
  731. title: "项目数量(个)",
  732. dataIndex: "commodityQuantity",
  733. key: "commodityQuantity"
  734. },
  735. {
  736. title: "服务市价(万元)",
  737. dataIndex: "commodityPrice",
  738. key: "commodityPrice"
  739. },
  740. {
  741. title: "项目状态",
  742. dataIndex: "projectStatus",
  743. key: "projectStatus",
  744. render: text => {
  745. return getProjectStatus(text);
  746. }
  747. },
  748. {
  749. title: "证书编号",
  750. dataIndex: "certificateNumber",
  751. key: "certificateNumber"
  752. },
  753. {
  754. title: "是否主要项目",
  755. dataIndex: "main",
  756. key: "main",
  757. render: text => {
  758. return text ? "是" : "否";
  759. }
  760. },
  761. {
  762. title: "项目说明",
  763. dataIndex: "taskComment",
  764. key: "taskComment",
  765. render: text => {
  766. return text && text.length > 8 ? (
  767. <span title={text}>{text.substr(0, 8)}...</span>
  768. ) : (
  769. text
  770. );
  771. }
  772. }
  773. ],
  774. columnsDate: [
  775. {
  776. title: "编号",
  777. dataIndex: "id",
  778. key: "id"
  779. },
  780. {
  781. title: "订单编号",
  782. dataIndex: "orderno",
  783. key: "orderno"
  784. },
  785. {
  786. title: "开票金额(万元)",
  787. dataIndex: "amount",
  788. key: "amount"
  789. },
  790. {
  791. title: "申请时间",
  792. dataIndex: "createTime",
  793. key: "createTime"
  794. },
  795. {
  796. title: "开票状态",
  797. dataIndex: "status",
  798. key: "status",
  799. render: text => {
  800. return getInvoiceStatus(text);
  801. }
  802. }
  803. ],
  804. columnsY: [
  805. {
  806. title: "流程",
  807. dataIndex: "processName",
  808. key: "processName"
  809. },
  810. {
  811. title: "操作人",
  812. dataIndex: "adminName",
  813. key: "adminName"
  814. },
  815. {
  816. title: "时间",
  817. dataIndex: "createDate",
  818. key: "createDate"
  819. }
  820. ],
  821. columnsW: [
  822. {
  823. title: "外包名称",
  824. dataIndex: "name",
  825. key: "name"
  826. },
  827. {
  828. title: "联系人",
  829. dataIndex: "contacts",
  830. key: "contacts"
  831. },
  832. {
  833. title: "联系人电话",
  834. dataIndex: "contactsMobile",
  835. key: "contactsMobile"
  836. },
  837. {
  838. title: "地址",
  839. dataIndex: "ProvinceCity",
  840. key: "ProvinceCity",
  841. render: test => {
  842. return test[0] === null
  843. ? ""
  844. : getprovince(test[0]) +
  845. "/" +
  846. getprovince(test[1]) +
  847. "/" +
  848. getprovince(test[2]);
  849. }
  850. },
  851. {
  852. title: "地址详情",
  853. dataIndex: "address",
  854. key: "address",
  855. render: text => {
  856. return text && text.length > 8 ? text.substr(0, 8) + "..." : text;
  857. }
  858. },
  859. {
  860. title: "创建时间",
  861. dataIndex: "createTimes",
  862. key: "createTimes"
  863. },
  864. {
  865. title: "任务名称",
  866. dataIndex: "tname",
  867. key: "tname"
  868. },
  869. {
  870. title: "合同编号",
  871. dataIndex: "contractNo",
  872. key: "contractNo"
  873. },
  874. {
  875. title: "项目状态",
  876. dataIndex: "projectStatus",
  877. key: "projectStatus",
  878. render: text => {
  879. return getProjectStatus(text);
  880. }
  881. }
  882. ],
  883. dataSource: [],
  884. searchTime: [,],
  885. printColumns: [
  886. {
  887. title: "合同编号",
  888. dataIndex: "contractNo",
  889. key: "contractNo"
  890. },
  891. {
  892. title: "订单编号",
  893. dataIndex: "orderNo",
  894. key: "orderNo"
  895. // fixed: "left"
  896. },
  897. {
  898. title: "客户名称",
  899. dataIndex: "buyerName",
  900. key: "buyerName"
  901. },
  902. {
  903. title: "订单部门",
  904. dataIndex: "departmentName",
  905. key: "departmentName"
  906. },
  907. {
  908. title: "订单负责人",
  909. dataIndex: "sellerName",
  910. key: "sellerName"
  911. },
  912. {
  913. title: "外包公司",
  914. dataIndex: "outsourceName",
  915. key: "outsourceName"
  916. },
  917. {
  918. title: "签单日期",
  919. dataIndex: "signTime",
  920. key: "signTime"
  921. },
  922. {
  923. title: "下单日期",
  924. dataIndex: "createTime",
  925. key: "createTime"
  926. },
  927. {
  928. title: "签单金额(万元)",
  929. dataIndex: "signTotalAmount",
  930. key: "signTotalAmount"
  931. },
  932. {
  933. title: "开票金额(万元)",
  934. dataIndex: "invoiceAmount",
  935. key: "invoiceAmount"
  936. },
  937. {
  938. title: "已收款(万元)",
  939. dataIndex: "actuallyTotalAmount",
  940. key: "actuallyTotalAmount"
  941. },
  942. {
  943. title: "最近收款(万元)",
  944. dataIndex: "finalReceivables",
  945. key: "finalReceivables"
  946. },
  947. {
  948. title: "最近收款时间",
  949. dataIndex: "finalReceivablesTime",
  950. key: "finalReceivablesTime"
  951. },
  952. {
  953. title: "结算状态",
  954. dataIndex: "liquidationStatus",
  955. key: "liquidationStatus",
  956. render: text => {
  957. return getLiquidationStatus(text);
  958. }
  959. },
  960. {
  961. title: "流程状态",
  962. dataIndex: "processStatus",
  963. key: "processStatus",
  964. render: text => {
  965. return getProcessStatus(text);
  966. }
  967. },
  968. {
  969. title: "特批状态",
  970. dataIndex: "approval",
  971. key: "approval",
  972. render: text => {
  973. return getApproval(text);
  974. }
  975. }
  976. ],
  977. waterlistDate: [
  978. {
  979. title: "订单编号",
  980. dataIndex: "orderNo",
  981. key: "orderNo"
  982. },
  983. {
  984. title: "平台流水号",
  985. dataIndex: "billNo",
  986. key: "billNo"
  987. // fixed: "left"
  988. },
  989. {
  990. title: "金额(万元)",
  991. dataIndex: "transactionAmount",
  992. key: "transactionAmount"
  993. },
  994. {
  995. title: "收款方",
  996. dataIndex: "payeeName",
  997. key: "payeeName"
  998. },
  999. {
  1000. title: "付款方",
  1001. dataIndex: "payerName",
  1002. key: "payerName"
  1003. },
  1004. {
  1005. title: "流水科目",
  1006. dataIndex: "transactionSubject",
  1007. key: "transactionSubject",
  1008. render: text => {
  1009. return getTransactionProject(text);
  1010. }
  1011. },
  1012. {
  1013. title: "收款类型",
  1014. dataIndex: "type",
  1015. key: "type"
  1016. },
  1017. {
  1018. title: "财务流水时间",
  1019. dataIndex: "financialPayTimes",
  1020. key: "financialPayTimes"
  1021. },
  1022. {
  1023. title: "财务流水号",
  1024. dataIndex: "financialPayNo",
  1025. key: "financialPayNo"
  1026. },
  1027. {
  1028. title: "订单负责人",
  1029. dataIndex: "saleName",
  1030. key: "saleName"
  1031. },
  1032. {
  1033. title: "创建时间",
  1034. dataIndex: "createTimes",
  1035. key: "createTimes"
  1036. }
  1037. ],
  1038. waterData: []
  1039. };
  1040. },
  1041. // 特批通过
  1042. evaluateZ(record) {
  1043. $.ajax({
  1044. method: "POST",
  1045. dataType: "json",
  1046. crossDomain: false,
  1047. url: globalConfig.context + "/api/admin/financial/financeApproval",
  1048. data: {
  1049. orderNo: record.orderNo
  1050. }
  1051. }).done(
  1052. function(data) {
  1053. if (!data.error.length) {
  1054. message.success("通过成功!");
  1055. this.setState({
  1056. loading: false
  1057. });
  1058. this.loadData();
  1059. } else {
  1060. message.warning(data.error[0].message);
  1061. }
  1062. }.bind(this)
  1063. );
  1064. },
  1065. jdDate(orderNo) {
  1066. $.ajax({
  1067. method: "get",
  1068. dataType: "json",
  1069. crossDomain: false,
  1070. url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  1071. data: {
  1072. orderNo: orderNo
  1073. },
  1074. success: function(data) {
  1075. let thisData = data.data;
  1076. if (!thisData.length) {
  1077. if (data.error && data.error.length) {
  1078. message.warning(data.error[0].message);
  1079. }
  1080. thisData = {};
  1081. } else {
  1082. this.setState({
  1083. jsDate: thisData
  1084. });
  1085. }
  1086. }.bind(this)
  1087. }).always(
  1088. function() {
  1089. this.setState({
  1090. loading: false
  1091. });
  1092. }.bind(this)
  1093. );
  1094. },
  1095. /* 收款 */
  1096. evaluateX(recard) {
  1097. this.state.assignDataX = recard;
  1098. this.setState({
  1099. assignVisibleX: true
  1100. });
  1101. },
  1102. /* 转交 */
  1103. evaluateY(recard, nub) {
  1104. this.state.assignDataY = recard;
  1105. this.setState({
  1106. nub,
  1107. assignVisibleY: true
  1108. });
  1109. },
  1110. /* 驳回 */
  1111. reject(recard) {
  1112. this.setState({
  1113. bohuiData: recard,
  1114. boHuiVisible: true,
  1115. content: ""
  1116. });
  1117. },
  1118. boHuiCancel() {
  1119. this.setState({
  1120. boHuiVisible: false,
  1121. reason: ""
  1122. });
  1123. },
  1124. componentWillMount() {
  1125. this.loadData();
  1126. this.departmentList();
  1127. },
  1128. tableRowClick(record) {
  1129. this.state.RowData = record;
  1130. this.setState({
  1131. showDesc: true,
  1132. visible: true,
  1133. orderNo: record.orderNo,
  1134. modKey: "1"
  1135. });
  1136. this.jdDate(record.orderNo);
  1137. this.loadXmu(record);
  1138. this.loadModal(record);
  1139. },
  1140. //详情
  1141. callBack(key) {
  1142. if (key === "2") {
  1143. this.setState({
  1144. modKey: key,
  1145. width: "1200px"
  1146. });
  1147. this.loadWaiBao();
  1148. }
  1149. if (key === "1") {
  1150. this.setState({
  1151. modKey: key,
  1152. width: "800px"
  1153. });
  1154. }
  1155. if (this.state.pictureUrl.length) {
  1156. let picArr = [];
  1157. this.state.pictureUrl.map(function(item) {
  1158. if (item.response && item.response.data && item.response.data.length) {
  1159. picArr.push(item.response.data);
  1160. }
  1161. });
  1162. }
  1163. if (key === "3") {
  1164. this.setState({
  1165. modKey: key,
  1166. width: "800px"
  1167. });
  1168. this.setState({
  1169. loading: true
  1170. });
  1171. $.ajax({
  1172. method: "get",
  1173. dataType: "json",
  1174. crossDomain: false,
  1175. url:
  1176. globalConfig.context + "/api/admin/outsourceOrg/orderOutsourceDtails",
  1177. data: {
  1178. orderNo: this.state.orderNo
  1179. },
  1180. success: function(data) {
  1181. let thisdata = data.data;
  1182. this.setState({
  1183. id: thisdata.id,
  1184. createTimes: thisdata.createTimes,
  1185. auditTimes: thisdata.auditTimes,
  1186. remarks: thisdata.remarks,
  1187. attachmentUrl: thisdata.attachmentUrl
  1188. ? splitUrl(
  1189. thisdata.attachmentUrl,
  1190. ",",
  1191. globalConfig.avatarHost + "/upload"
  1192. )
  1193. : [],
  1194. pictureUrl: thisdata.pictureUrl
  1195. ? splitUrl(
  1196. thisdata.pictureUrl,
  1197. ",",
  1198. globalConfig.avatarHost + "/upload"
  1199. )
  1200. : [], //图片地址
  1201. amount: thisdata.amount,
  1202. companyName: thisdata.companyName,
  1203. refundStatus: thisdata.refundStatus,
  1204. outsourceRemarks: thisdata.outsourceRemarks,
  1205. unitNumber: thisdata.unitNumber,
  1206. unitPrice: thisdata.unitPrice
  1207. });
  1208. }.bind(this)
  1209. }).always(
  1210. function() {
  1211. this.setState({
  1212. loading: false
  1213. });
  1214. }.bind(this)
  1215. );
  1216. }
  1217. },
  1218. //外包详情
  1219. loadWaiBao() {
  1220. $.ajax({
  1221. method: "get",
  1222. dataType: "json",
  1223. rossDomain: false,
  1224. url:
  1225. globalConfig.context +
  1226. "/api/admin/outsourceOrg/selectOrderOutsourceOrg",
  1227. data: {
  1228. orderNo: this.state.orderNo
  1229. },
  1230. success: function(data) {
  1231. let theArr = [];
  1232. if (data.error.length || data.data.list == "") {
  1233. if (data.error && data.error.length) {
  1234. message.warning(data.error[0].message);
  1235. }
  1236. } else {
  1237. for (let i = 0; i < data.data.length; i++) {
  1238. let thisdata = data.data[i];
  1239. let ProvinceCityArr = [];
  1240. let ProvinceS = thisdata.province; //省
  1241. let citys = thisdata.city; //市
  1242. let Areas = thisdata.area; //区
  1243. ProvinceCityArr.push(ProvinceS, citys, Areas);
  1244. theArr.push({
  1245. key: i,
  1246. id: thisdata.id,
  1247. name: thisdata.name,
  1248. contacts: thisdata.contacts, //订单编号
  1249. contactsMobile: thisdata.contactsMobile,
  1250. ProvinceCity: ProvinceCityArr[0] === null ? [] : ProvinceCityArr,
  1251. province: thisdata.province,
  1252. city: thisdata.city,
  1253. area: thisdata.area,
  1254. address: thisdata.address,
  1255. remarks: thisdata.remarks,
  1256. tid: thisdata.tid,
  1257. createTimes: thisdata.createTimes,
  1258. tname: thisdata.tname,
  1259. contractNo: thisdata.contractNo,
  1260. projectStatus: thisdata.projectStatus
  1261. });
  1262. }
  1263. }
  1264. this.setState(
  1265. {
  1266. dataSourceW: theArr
  1267. },
  1268. () => {}
  1269. );
  1270. }.bind(this)
  1271. }).always(
  1272. function() {
  1273. this.setState({
  1274. loading: false
  1275. });
  1276. }.bind(this)
  1277. );
  1278. },
  1279. loadXmu(record) {
  1280. this.state.data = [];
  1281. this.setState({
  1282. loading: true
  1283. });
  1284. $.ajax({
  1285. method: "get",
  1286. dataType: "json",
  1287. crossDomain: false,
  1288. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  1289. data: {
  1290. orderNo: record.orderNo
  1291. },
  1292. success: function(data) {
  1293. let theArr = [];
  1294. if (!data.data) {
  1295. if (data.error && data.error.length) {
  1296. message.warning(data.error[0].message);
  1297. }
  1298. } else {
  1299. for (let i = 0; i < data.data.length; i++) {
  1300. let thisdata = data.data[i];
  1301. theArr.push({
  1302. key: i,
  1303. id: thisdata.id,
  1304. orderNo: thisdata.orderNo,
  1305. commodityName: thisdata.commodityName,
  1306. commodityPrice: thisdata.commodityPrice,
  1307. commodityQuantity: thisdata.commodityQuantity,
  1308. taskStatus: thisdata.taskStatus,
  1309. taskComment: thisdata.taskComment,
  1310. main: thisdata.main,
  1311. contacts: thisdata.contacts,
  1312. contactsMobile: thisdata.contactsMobile,
  1313. cname: thisdata.cname,
  1314. certificateNumber: thisdata.certificateNumber,
  1315. projectStatus: thisdata.projectStatus
  1316. });
  1317. }
  1318. }
  1319. this.setState({
  1320. dataSourceX: theArr
  1321. });
  1322. }.bind(this)
  1323. }).always(
  1324. function() {
  1325. this.setState({
  1326. loading: false
  1327. });
  1328. }.bind(this)
  1329. );
  1330. },
  1331. loadModal(record) {
  1332. this.state.orderList = [];
  1333. $.ajax({
  1334. method: "get",
  1335. dataType: "json",
  1336. crossDomain: false,
  1337. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  1338. data: {
  1339. orderNo: record.orderNo
  1340. },
  1341. success: function(data) {
  1342. let thisData = data.data;
  1343. if (!thisData) {
  1344. if (data.error && data.error.length) {
  1345. message.warning(data.error[0].message);
  1346. }
  1347. thisData = {};
  1348. }
  1349. this.setState({
  1350. id: thisData.id,
  1351. orderList: thisData,
  1352. approval:
  1353. thisData.approval == 0
  1354. ? thisData.approval.toString()
  1355. : thisData.approval,
  1356. orderRemarks: thisData.orderRemarks,
  1357. orgCodeUrl: thisData.contractPictureUrl
  1358. ? splitUrl(
  1359. thisData.contractPictureUrl,
  1360. ",",
  1361. globalConfig.avatarHost + "/upload"
  1362. )
  1363. : [],
  1364. orderNo: thisData.orderNo, //订单编号
  1365. buyerId: thisData.buyerId,
  1366. depName: thisData.depName
  1367. });
  1368. }.bind(this)
  1369. }).always(
  1370. function() {
  1371. this.setState({
  1372. loading: false
  1373. });
  1374. }.bind(this)
  1375. );
  1376. },
  1377. rizhi() {
  1378. this.setState({
  1379. loading: true
  1380. });
  1381. $.ajax({
  1382. method: "get",
  1383. dataType: "json",
  1384. crossDomain: false,
  1385. url: "/api/admin/newOrder/selectOrderLog",
  1386. data: {
  1387. orderNo: this.state.orderNo
  1388. },
  1389. success: function(data) {
  1390. let theArr = [];
  1391. let thisData = data.data;
  1392. if (!thisData.length) {
  1393. if (data.error && data.error.length) {
  1394. message.warning(data.error[0].message);
  1395. }
  1396. thisData = {};
  1397. } else {
  1398. for (let i = 0; i < data.data.length; i++) {
  1399. let thisdata = data.data[i];
  1400. theArr.push({
  1401. processName: thisdata.processName,
  1402. adminName: thisdata.adminName,
  1403. createDate: thisdata.createDate
  1404. });
  1405. }
  1406. }
  1407. this.setState({
  1408. dataSourceY: theArr
  1409. });
  1410. }.bind(this)
  1411. }).always(
  1412. function() {
  1413. this.setState({
  1414. loading: false
  1415. });
  1416. }.bind(this)
  1417. );
  1418. },
  1419. closeOrderLog() {
  1420. this.setState({
  1421. avisible: false
  1422. });
  1423. },
  1424. load() {
  1425. if (this.state.attachmentUrl) {
  1426. let url = window.location.href.substring(7);
  1427. this.state.attachmentUrl.forEach(e => {
  1428. window.location.href =
  1429. "http://" +
  1430. url.substring(0, url.indexOf("/")) +
  1431. "/api/admin/outsourceOrg//downloadFile?path=" +
  1432. e.response.data;
  1433. });
  1434. } else {
  1435. message.error("此订单无上传文件");
  1436. }
  1437. },
  1438. getOrderLog() {
  1439. this.setState({
  1440. avisible: true
  1441. });
  1442. this.rizhi();
  1443. },
  1444. closeModal() {
  1445. this.setState(
  1446. {
  1447. visible: false,
  1448. width: "800px"
  1449. },
  1450. () => {
  1451. this.setState({
  1452. modKey: "1"
  1453. });
  1454. }
  1455. );
  1456. },
  1457. closeDesc(e, s) {
  1458. this.state.showDesc = e;
  1459. if (s) {
  1460. this.loadData();
  1461. }
  1462. },
  1463. closeAssignX(e, s) {
  1464. this.state.assignDataX = {};
  1465. this.state.assignVisibleX = e;
  1466. if (s) {
  1467. this.loadData();
  1468. }
  1469. },
  1470. closeAssignY(e, s) {
  1471. this.state.assignDataY = {};
  1472. this.state.assignVisibleY = e;
  1473. if (s) {
  1474. this.loadData();
  1475. }
  1476. },
  1477. search() {
  1478. this.loadData();
  1479. },
  1480. reset() {
  1481. this.state.nameSearch = "";
  1482. this.state.releaseDate = [];
  1483. this.state.shouKuanDate = [];
  1484. this.state.orderNoSearch = "";
  1485. this.state.departmenttList = undefined;
  1486. this.state.processStatus = [];
  1487. this.state.contractNoSearch = "";
  1488. this.state.liquidationStatus = [];
  1489. this.state.contractNo = "";
  1490. this.loadData();
  1491. },
  1492. boHuiCo() {
  1493. this.boHuiCancel();
  1494. this.boHuiSubmit();
  1495. },
  1496. //驳回
  1497. boHuiSubmit() {
  1498. if (!this.state.reason) {
  1499. message.warning("请填写驳回原因");
  1500. return false;
  1501. }
  1502. this.setState({
  1503. loading: true
  1504. });
  1505. $.ajax({
  1506. method: "POST",
  1507. dataType: "json",
  1508. crossDomain: false,
  1509. url: globalConfig.context + "/api/admin/financial/reject",
  1510. data: {
  1511. orderNo: this.state.bohuiData.orderNo,
  1512. reason: this.state.reason
  1513. }
  1514. }).done(
  1515. function(data) {
  1516. if (!data.error.length) {
  1517. message.success("驳回成功!");
  1518. this.setState({
  1519. loading: false
  1520. });
  1521. this.loadData();
  1522. } else {
  1523. message.warning(data.error[0].message);
  1524. }
  1525. }.bind(this)
  1526. );
  1527. },
  1528. searchSwitch() {
  1529. this.setState({
  1530. searchMore: !this.state.searchMore
  1531. });
  1532. },
  1533. changeList(arr) {
  1534. const newArr = [];
  1535. this.state.columns.forEach(item => {
  1536. arr.forEach(val => {
  1537. if (val === item.title) {
  1538. newArr.push(item);
  1539. }
  1540. });
  1541. });
  1542. this.setState({
  1543. changeList: newArr
  1544. });
  1545. },
  1546. onSelectChange(selectedRowKeys) {
  1547. // for(var i=0; i<selectedRowKeys.length; i++){
  1548. // for(var j=i+1; j<selectedRowKeys.length; j++){
  1549. // if(selectedRowKeys[i]==selectedRowKeys[j]){
  1550. // selectedRowKeys.splice(j,1);
  1551. // j--;
  1552. // }
  1553. // }
  1554. // }
  1555. console.log(selectedRowKeys);
  1556. this.setState({ selectedRowKeys });
  1557. },
  1558. inRecordData() {
  1559. this.setState({
  1560. loading: true
  1561. });
  1562. $.ajax({
  1563. method: "get",
  1564. dataType: "json",
  1565. crossDomain: false,
  1566. url:
  1567. globalConfig.context +
  1568. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  1569. data: {
  1570. orderNo: this.state.selectedRowKeys[0],
  1571. pageSize: 9999
  1572. },
  1573. success: function(data) {
  1574. let theArr = [];
  1575. let sum = 0;
  1576. if (!data.data) {
  1577. if (data.error && data.error.length) {
  1578. message.warning(data.error[0].message);
  1579. }
  1580. } else {
  1581. for (let i = 0; i < data.data.list.length; i++) {
  1582. let thisdata = data.data.list[i];
  1583. sum += parseFloat(thisdata.amount);
  1584. theArr.push({
  1585. id: thisdata.id,
  1586. orderno: thisdata.orderno, //订单编号
  1587. amount: thisdata.amount, //签单金额
  1588. createTime: thisdata.createTime, //流程状态
  1589. status: thisdata.status, //结算状态
  1590. rejectReason: thisdata.rejectReason
  1591. });
  1592. }
  1593. }
  1594. this.setState({
  1595. recordData: theArr,
  1596. sum: sum.toFixed(4)
  1597. });
  1598. }.bind(this)
  1599. }).done(
  1600. function() {
  1601. this.setState({
  1602. loading: false
  1603. });
  1604. }.bind(this)
  1605. );
  1606. },
  1607. inRecordCanl() {
  1608. this.setState({
  1609. bvisible: false
  1610. });
  1611. },
  1612. waterData() {
  1613. this.state.data = [];
  1614. this.setState({
  1615. loading: true
  1616. });
  1617. $.ajax({
  1618. method: "get",
  1619. dataType: "json",
  1620. crossDomain: false,
  1621. url: globalConfig.context + "/api/admin/financial/myBillList",
  1622. data: {
  1623. orderNo: this.state.selectedRowKeys[0],
  1624. pageSize: 9999
  1625. },
  1626. success: function(data) {
  1627. let theArr = [];
  1628. let waterSum = 0;
  1629. if (!data.data || !data.data.list) {
  1630. if (data.error && data.error.length) {
  1631. message.warning(data.error[0].message);
  1632. }
  1633. } else {
  1634. for (let i = 0; i < data.data.list.length; i++) {
  1635. let thisdata = data.data.list[i];
  1636. waterSum += parseFloat(thisdata.transactionAmount);
  1637. theArr.push({
  1638. key: i,
  1639. orderNo: thisdata.orderNo,
  1640. billNo: thisdata.billNo,
  1641. transactionAmount: thisdata.transactionAmount,
  1642. payeeName: thisdata.payeeName,
  1643. payerName: thisdata.payerName,
  1644. transactionSubject: thisdata.transactionSubject,
  1645. transactionChannel: thisdata.transactionChannel,
  1646. financialPayTimes: thisdata.financialPayTimes,
  1647. financialPayNo: thisdata.financialPayNo,
  1648. createrName: thisdata.createrName,
  1649. saleName: thisdata.saleName,
  1650. createTimes: thisdata.createTimes,
  1651. type: thisdata.type == 0 ? "手工" : "批量"
  1652. });
  1653. }
  1654. }
  1655. this.setState({
  1656. waterData: theArr,
  1657. waterSum: waterSum.toFixed(4)
  1658. });
  1659. }.bind(this)
  1660. }).always(
  1661. function() {
  1662. this.setState({
  1663. loading: false
  1664. });
  1665. }.bind(this)
  1666. );
  1667. },
  1668. waterCanl() {
  1669. this.setState({
  1670. cvisible: false
  1671. });
  1672. },
  1673. exportAll() {
  1674. const data = {
  1675. pageSize: 9999,
  1676. buyerName: this.state.nameSearch, //客户名称
  1677. orderNo: this.state.orderNoSearch,
  1678. startTime: this.state.releaseDate[0],
  1679. endTime: this.state.releaseDate[1],
  1680. startFinalReceivablesTime: this.state.shouKuanDate[0],
  1681. endFinalReceivablesTime: this.state.shouKuanDate[1],
  1682. departmentId: this.state.departmenttList,
  1683. processStatus: this.state.processStatusSearch,
  1684. contractNo: this.state.contractNoSearch,
  1685. outsource: 1,
  1686. liquidationStatus: this.state.liquidationStatus
  1687. };
  1688. window.location.href =
  1689. globalConfig.context +
  1690. "/api/admin/receivables/exportReceivables?" +
  1691. $.param(data);
  1692. },
  1693. exportKaip() {
  1694. window.location.href =
  1695. globalConfig.context +
  1696. "/api/admin/receivables/exportInvoice?" +
  1697. `orderNo=${this.state.selectedRowKeys}`;
  1698. },
  1699. exportWater() {
  1700. window.location.href =
  1701. globalConfig.context +
  1702. "/api/admin/receivables/exportMyBill?" +
  1703. `orderNo=${this.state.selectedRowKeys}`;
  1704. },
  1705. printAll() {
  1706. this.setState({
  1707. dvisible: true
  1708. // loading: true
  1709. });
  1710. this.loadData(1, 9999);
  1711. },
  1712. downImg() {
  1713. let num = 0;
  1714. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  1715. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  1716. num = i;
  1717. }
  1718. }
  1719. if (num == this.state.orgCodeUrl.length - 1) {
  1720. return message.warning("已经是最后一张了哦");
  1721. }
  1722. this.state.previewImage = this.state.orgCodeUrl[num + 1].url;
  1723. this.setState({
  1724. previewImage: this.state.previewImage,
  1725. rotateDeg: 0
  1726. });
  1727. },
  1728. upImg() {
  1729. let num = 0;
  1730. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  1731. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  1732. num = i;
  1733. }
  1734. }
  1735. if (num == 0) {
  1736. return message.warning("已经是第一张了哦");
  1737. }
  1738. this.state.previewImage = this.state.orgCodeUrl[num - 1].url;
  1739. this.setState({
  1740. previewImage: this.state.previewImage,
  1741. rotateDeg: 0
  1742. });
  1743. },
  1744. rotate() {
  1745. let rotateDeg = this.state.rotateDeg + 90;
  1746. this.setState({
  1747. rotateDeg
  1748. });
  1749. },
  1750. timeData() {
  1751. this.setState({
  1752. loading: true
  1753. });
  1754. $.ajax({
  1755. method: "get",
  1756. dataType: "json",
  1757. crossDomain: false,
  1758. url: globalConfig.context + "/api/admin/orderProject/taskHoursList",
  1759. data: {
  1760. orderNo: this.state.selectedRowKeys[0],
  1761. pageSize: 9999
  1762. },
  1763. success: function(data) {
  1764. let theArr = [];
  1765. if (!data.data || !data.data.list) {
  1766. if (data.error && data.error.length) {
  1767. message.warning(data.error[0].message);
  1768. }
  1769. } else {
  1770. for (let i = 0; i < data.data.list.length; i++) {
  1771. let thisdata = data.data.list[i];
  1772. theArr.push({
  1773. key: i + 1,
  1774. orderNo: thisdata.orderNo,
  1775. contractNo: thisdata.contractNo,
  1776. userName: thisdata.userName,
  1777. receiverName: thisdata.receiverName,
  1778. taskStatus: thisdata.taskStatus,
  1779. cname: thisdata.cname,
  1780. id: thisdata.id,
  1781. taskName: thisdata.taskName,
  1782. hours: thisdata.hours,
  1783. taskDistributionTime: thisdata.taskDistributionTime,
  1784. taskEndTime: thisdata.taskEndTime
  1785. });
  1786. }
  1787. }
  1788. this.setState({
  1789. timeDataList: theArr
  1790. });
  1791. }.bind(this)
  1792. }).always(
  1793. function() {
  1794. this.setState({
  1795. loading: false
  1796. });
  1797. }.bind(this)
  1798. );
  1799. },
  1800. exportTime() {
  1801. const data = {
  1802. orderNo: this.state.selectedRowKeys[0],
  1803. outsourcing: 1
  1804. };
  1805. window.location.href =
  1806. globalConfig.context +
  1807. "/api/admin/orderProject/exportMyTaskList?" +
  1808. $.param(data);
  1809. },
  1810. exportPro() {
  1811. const data = {
  1812. orderNo: this.state.selectedRowKeys[0]
  1813. };
  1814. window.location.href =
  1815. globalConfig.context +
  1816. "/api/admin/newOrder/exportOrderTaskData?" +
  1817. $.param(data);
  1818. },
  1819. exportCui() {
  1820. var data = {
  1821. orderNo: this.state.selectedRowKeys[0]
  1822. ? this.state.selectedRowKeys[0]
  1823. : undefined, //订单编号
  1824. // specially: 1,
  1825. pageSize: 9999,
  1826. outsource: 1
  1827. };
  1828. window.location.href =
  1829. globalConfig.context +
  1830. "/api/admin/newOrder/exportOrderDunData?" +
  1831. $.param(data);
  1832. },
  1833. cuiData() {
  1834. this.setState({
  1835. loading: true
  1836. });
  1837. $.ajax({
  1838. method: "get",
  1839. dataType: "json",
  1840. crossDomain: false,
  1841. url: globalConfig.context + "/api/admin/newOrder/dunOrderNewList",
  1842. data: {
  1843. orderNo: this.state.selectedRowKeys[0],
  1844. pageSize: 9999
  1845. },
  1846. success: function(data) {
  1847. let theArr = [];
  1848. if (!data.data || !data.data.list) {
  1849. if (data.error && data.error.length) {
  1850. message.warning(data.error[0].message);
  1851. }
  1852. } else {
  1853. for (let i = 0; i < data.data.list.length; i++) {
  1854. let thisdata = data.data.list[i];
  1855. theArr.push({
  1856. key: i + 1,
  1857. orderNo: thisdata.orderNo,
  1858. contractNo: thisdata.contractNo,
  1859. userName: thisdata.userName,
  1860. buyerName: thisdata.buyerName,
  1861. departmentName: thisdata.departmentName,
  1862. salesmanName: thisdata.salesmanName,
  1863. depName: thisdata.depName,
  1864. orderStatus: thisdata.orderStatus,
  1865. projectStatus: thisdata.projectStatus,
  1866. totalAmount: thisdata.totalAmount,
  1867. liquidationStatus: thisdata.liquidationStatus,
  1868. settlementAmount: thisdata.settlementAmount,
  1869. accountsReceivable: thisdata.accountsReceivable,
  1870. dunSubject: thisdata.dunSubject,
  1871. startDate: thisdata.startDate,
  1872. taskStatus: thisdata.taskStatus,
  1873. cname: thisdata.cname,
  1874. id: thisdata.id,
  1875. taskName: thisdata.taskName,
  1876. hours: thisdata.hours,
  1877. taskDistributionTime: thisdata.taskDistributionTime,
  1878. taskEndTime: thisdata.taskEndTime
  1879. });
  1880. }
  1881. }
  1882. this.setState({
  1883. cuiDataList: theArr
  1884. });
  1885. }.bind(this)
  1886. }).always(
  1887. function() {
  1888. this.setState({
  1889. loading: false
  1890. });
  1891. }.bind(this)
  1892. );
  1893. },
  1894. proData() {
  1895. this.setState({
  1896. loading: true
  1897. });
  1898. $.ajax({
  1899. method: "get",
  1900. dataType: "json",
  1901. crossDomain: false,
  1902. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  1903. data: {
  1904. orderNo: this.state.selectedRowKeys[0],
  1905. pageSize: 9999
  1906. },
  1907. success: function(data) {
  1908. let theArr = [];
  1909. let totalWaibao = 0;
  1910. if (!data.data) {
  1911. if (data.error && data.error.length) {
  1912. message.warning(data.error[0].message);
  1913. }
  1914. } else {
  1915. for (let i = 0; i < data.data.length; i++) {
  1916. let thisdata = data.data[i];
  1917. totalWaibao += thisdata.outsourcePrice;
  1918. theArr.push({
  1919. key: i + 1,
  1920. orderNo: thisdata.orderNo,
  1921. contractNo: thisdata.contractNo,
  1922. userName: thisdata.userName,
  1923. buyerName: thisdata.buyerName,
  1924. departmentName: thisdata.departmentName,
  1925. salesmanName: thisdata.salesmanName,
  1926. depName: thisdata.depName,
  1927. orderStatus: thisdata.orderStatus,
  1928. projectStatus: thisdata.projectStatus,
  1929. commodityName: thisdata.commodityName,
  1930. totalAmount: thisdata.totalAmount,
  1931. liquidationStatus: thisdata.liquidationStatus,
  1932. settlementAmount: thisdata.settlementAmount,
  1933. accountsReceivable: thisdata.accountsReceivable,
  1934. dunSubject: thisdata.dunSubject,
  1935. startDate: thisdata.startDate,
  1936. taskStatus: thisdata.taskStatus,
  1937. cname: thisdata.cname,
  1938. id: thisdata.id,
  1939. taskName: thisdata.taskName,
  1940. hours: thisdata.hours,
  1941. taskDistributionTime: thisdata.taskDistributionTime,
  1942. taskEndTime: thisdata.taskEndTime,
  1943. commodityQuantity: thisdata.commodityQuantity,
  1944. commodityPrice: thisdata.commodityPrice,
  1945. certificateNumber: thisdata.certificateNumber,
  1946. taskComment: thisdata.taskComment,
  1947. outsourceName: thisdata.outsourceName,
  1948. outsourcePrice: thisdata.outsourcePrice
  1949. });
  1950. }
  1951. }
  1952. totalWaibao = (Math.round(totalWaibao * 10000) / 10000).toFixed(4);
  1953. this.setState({
  1954. proDataList: theArr,
  1955. totalWaibao
  1956. });
  1957. }.bind(this)
  1958. }).always(
  1959. function() {
  1960. this.setState({
  1961. loading: false
  1962. });
  1963. }.bind(this)
  1964. );
  1965. },
  1966. checkRemark(record) {
  1967. this.setState({
  1968. checkVisible: true,
  1969. checkOrderNo: record.orderNo
  1970. });
  1971. },
  1972. checkOk() {
  1973. if (this.state.checkData.trim() == "") {
  1974. message.warning("请填写审核内容");
  1975. return;
  1976. }
  1977. this.setState({
  1978. loading: true
  1979. });
  1980. $.ajax({
  1981. method: "post",
  1982. dataType: "json",
  1983. crossDomain: false,
  1984. url: globalConfig.context + "/api/admin/financial/financeApproval",
  1985. data: {
  1986. orderNo: this.state.checkOrderNo,
  1987. remarks: this.state.checkData
  1988. },
  1989. success: function(data) {
  1990. let theArr = [];
  1991. if (!data.data) {
  1992. if (data.error && data.error.length) {
  1993. message.warning(data.error[0].message);
  1994. }
  1995. } else {
  1996. message.success("通过成功!");
  1997. this.loadData();
  1998. this.setState({
  1999. checkVisible: false
  2000. });
  2001. }
  2002. }.bind(this)
  2003. }).always(
  2004. function() {
  2005. this.setState({
  2006. loading: false
  2007. });
  2008. }.bind(this)
  2009. );
  2010. },
  2011. render() {
  2012. const { TextArea } = Input;
  2013. const { RangePicker } = DatePicker;
  2014. const { TabPane } = Tabs;
  2015. var departmentArr = this.state.departmentArr || [];
  2016. const theData = this.state.orderList || {};
  2017. const formItemLayout = {
  2018. labelCol: { span: 8 },
  2019. wrapperCol: { span: 12 }
  2020. };
  2021. const { loading, selectedRowKeys, visible } = this.state;
  2022. const rowSelection = {
  2023. selectedRowKeys,
  2024. onChange: this.onSelectChange,
  2025. hideDefaultSelections: true,
  2026. type: "radio"
  2027. };
  2028. const jsDate = this.state.jsDate || [];
  2029. return (
  2030. <div className="user-content">
  2031. <div className="content-title" style={{ marginBottom: 10 }}>
  2032. <span style={{ fontWeight: 900, fontSize: 16 }}>外包结算管理</span>
  2033. </div>
  2034. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  2035. <TabPane tab="更改表格显示数据" key="1">
  2036. <div style={{ marginLeft: 10 }}>
  2037. <ChooseList
  2038. columns={this.state.columns}
  2039. changeFn={this.changeList}
  2040. changeList={this.state.changeList}
  2041. top={55}
  2042. margin={11}
  2043. />
  2044. </div>
  2045. </TabPane>
  2046. <TabPane tab="搜索" key="2">
  2047. <div className="user-search" style={{ marginLeft: 10 }}>
  2048. <Input
  2049. placeholder="订单编号"
  2050. value={this.state.orderNoSearch}
  2051. onChange={e => {
  2052. this.setState({ orderNoSearch: e.target.value });
  2053. }}
  2054. />
  2055. <Input
  2056. placeholder="客户名称"
  2057. value={this.state.nameSearch}
  2058. onChange={e => {
  2059. this.setState({ nameSearch: e.target.value });
  2060. }}
  2061. />
  2062. <Select
  2063. placeholder="订单部门"
  2064. style={{ width: 150, marginRight: 10 }}
  2065. value={this.state.departmenttList}
  2066. onChange={e => {
  2067. this.setState({ departmenttList: e });
  2068. }}
  2069. >
  2070. {departmentArr.map(function(item) {
  2071. return (
  2072. <Select.Option key={item.id}>{item.name}</Select.Option>
  2073. );
  2074. })}
  2075. </Select>
  2076. <Input
  2077. placeholder="合同编号"
  2078. value={this.state.contractNoSearch}
  2079. onChange={e => {
  2080. this.setState({
  2081. contractNoSearch: e.target.value
  2082. });
  2083. }}
  2084. />
  2085. <Select
  2086. placeholder="流程状态"
  2087. onChange={e => {
  2088. this.setState({ processStatusSearch: e });
  2089. }}
  2090. style={{ width: 160, marginRight: 5 }}
  2091. value={this.state.processStatusSearch}
  2092. >
  2093. <Option value="3">未分配</Option>
  2094. <Option value="4">已分配</Option>
  2095. </Select>
  2096. <Select
  2097. placeholder="结算状态"
  2098. onChange={e => {
  2099. this.setState({ liquidationStatus: e });
  2100. }}
  2101. style={{ width: 160, marginRight: 5 }}
  2102. value={this.state.liquidationStatus}
  2103. >
  2104. <Option value="0">首付待付清</Option>
  2105. <Option value="1">尾款待付清</Option>
  2106. <Option value="2">已付清</Option>
  2107. </Select>
  2108. <span style={{ marginRight: 0 }}>下单日期:</span>
  2109. <RangePicker
  2110. value={[
  2111. this.state.releaseDate[0]
  2112. ? moment(this.state.releaseDate[0])
  2113. : null,
  2114. this.state.releaseDate[1]
  2115. ? moment(this.state.releaseDate[1])
  2116. : null
  2117. ]}
  2118. onChange={(data, dataString) => {
  2119. this.setState({ releaseDate: dataString });
  2120. }}
  2121. />
  2122. <span style={{}}>最近收款:</span>
  2123. <RangePicker
  2124. value={[
  2125. this.state.shouKuanDate[0]
  2126. ? moment(this.state.shouKuanDate[0])
  2127. : null,
  2128. this.state.shouKuanDate[1]
  2129. ? moment(this.state.shouKuanDate[1])
  2130. : null
  2131. ]}
  2132. onChange={(data, dataString) => {
  2133. this.setState({ shouKuanDate: dataString });
  2134. }}
  2135. />
  2136. <Button
  2137. type="primary"
  2138. onClick={this.search}
  2139. style={{ marginLeft: 10 }}
  2140. >
  2141. 搜索
  2142. </Button>
  2143. <Button onClick={this.reset}>重置</Button>
  2144. </div>
  2145. </TabPane>
  2146. <TabPane tab="打印" key="3">
  2147. <Button
  2148. type="primary"
  2149. style={{ margin: "11px 0px 10px 10px" }}
  2150. onClick={this.printAll}
  2151. disabled={!this.state.dataSource.length}
  2152. >
  2153. 打印所有列表信息
  2154. </Button>
  2155. <Button
  2156. type="primary"
  2157. disabled={this.state.selectedRowKeys.length != 1}
  2158. style={{ margin: "11px 0px 10px 10px" }}
  2159. onClick={() => {
  2160. this.inRecordData();
  2161. this.setState({
  2162. bvisible: true
  2163. });
  2164. }}
  2165. >
  2166. 打印开票详情
  2167. </Button>
  2168. <Button
  2169. type="primary"
  2170. disabled={this.state.selectedRowKeys.length != 1}
  2171. style={{ margin: "11px 0px 10px 10px" }}
  2172. onClick={() => {
  2173. this.waterData();
  2174. this.setState({
  2175. cvisible: true
  2176. });
  2177. }}
  2178. >
  2179. 打印收款流水
  2180. </Button>
  2181. <Button
  2182. type="primary"
  2183. disabled={this.state.selectedRowKeys.length != 1}
  2184. style={{ margin: "11px 0px 10px 10px" }}
  2185. onClick={() => {
  2186. this.timeData();
  2187. this.setState({
  2188. timeVisible: true
  2189. });
  2190. }}
  2191. >
  2192. 打印工时信息
  2193. </Button>
  2194. <Button
  2195. type="primary"
  2196. disabled={this.state.selectedRowKeys.length != 1}
  2197. style={{ margin: "11px 0px 10px 10px" }}
  2198. onClick={() => {
  2199. this.cuiData();
  2200. this.setState({
  2201. cuiVisible: true
  2202. });
  2203. }}
  2204. >
  2205. 打印催款信息
  2206. </Button>
  2207. <Button
  2208. type="primary"
  2209. disabled={this.state.selectedRowKeys.length != 1}
  2210. style={{ margin: "11px 0px 10px 10px" }}
  2211. onClick={() => {
  2212. this.proData();
  2213. this.setState({
  2214. proVisible: true
  2215. });
  2216. }}
  2217. >
  2218. 打印项目信息
  2219. </Button>
  2220. </TabPane>
  2221. <TabPane tab="导出Excel" key="4">
  2222. <Button
  2223. type="primary"
  2224. style={{ margin: "11px 0px 10px 10px" }}
  2225. onClick={this.exportAll}
  2226. >
  2227. 导出当前列表
  2228. </Button>
  2229. <Button
  2230. type="primary"
  2231. disabled={this.state.selectedRowKeys.length != 1}
  2232. style={{ margin: "11px 0px 10px 10px" }}
  2233. onClick={this.exportKaip}
  2234. >
  2235. 导出所选开票详情
  2236. </Button>
  2237. <Button
  2238. type="primary"
  2239. disabled={this.state.selectedRowKeys.length != 1}
  2240. style={{ margin: "11px 0px 10px 10px" }}
  2241. onClick={this.exportWater}
  2242. >
  2243. 导出所选收款详情流水
  2244. </Button>
  2245. <Button
  2246. type="primary"
  2247. disabled={this.state.selectedRowKeys.length != 1}
  2248. style={{ margin: "11px 0px 10px 10px" }}
  2249. onClick={this.exportTime}
  2250. >
  2251. 导出所选工时信息
  2252. </Button>
  2253. <Button
  2254. type="primary"
  2255. disabled={this.state.selectedRowKeys.length != 1}
  2256. style={{ margin: "11px 0px 10px 10px" }}
  2257. onClick={this.exportCui}
  2258. >
  2259. 导出催款信息
  2260. </Button>
  2261. <Button
  2262. type="primary"
  2263. disabled={this.state.selectedRowKeys.length != 1}
  2264. style={{ margin: "11px 0px 10px 10px" }}
  2265. onClick={this.exportPro}
  2266. >
  2267. 导出项目详情
  2268. </Button>
  2269. </TabPane>
  2270. <TabPane tab="查看" key="5">
  2271. <Button
  2272. type="primary"
  2273. disabled={this.state.selectedRowKeys.length != 1}
  2274. style={{ margin: "11px 0px 10px 10px" }}
  2275. onClick={() => {
  2276. this.inRecordData();
  2277. this.setState({
  2278. bvisible: true
  2279. });
  2280. }}
  2281. >
  2282. 查看开票详情
  2283. </Button>
  2284. <Button
  2285. type="primary"
  2286. disabled={this.state.selectedRowKeys.length != 1}
  2287. style={{ margin: "11px 0px 10px 10px" }}
  2288. onClick={() => {
  2289. this.waterData();
  2290. this.setState({
  2291. cvisible: true
  2292. });
  2293. }}
  2294. >
  2295. 详情收款流水
  2296. </Button>
  2297. <Button
  2298. type="primary"
  2299. disabled={this.state.selectedRowKeys.length != 1}
  2300. style={{ margin: "11px 0px 10px 10px" }}
  2301. onClick={() => {
  2302. this.timeData();
  2303. this.setState({
  2304. timeVisible: true
  2305. });
  2306. }}
  2307. >
  2308. 工时信息
  2309. </Button>
  2310. <Button
  2311. type="primary"
  2312. disabled={this.state.selectedRowKeys.length != 1}
  2313. style={{ margin: "11px 0px 10px 10px" }}
  2314. onClick={() => {
  2315. this.cuiData();
  2316. this.setState({
  2317. cuiVisible: true
  2318. });
  2319. }}
  2320. >
  2321. 催款信息
  2322. </Button>
  2323. <Button
  2324. type="primary"
  2325. disabled={this.state.selectedRowKeys.length != 1}
  2326. style={{ margin: "11px 0px 10px 10px" }}
  2327. onClick={() => {
  2328. this.proData();
  2329. this.setState({
  2330. proVisible: true
  2331. });
  2332. }}
  2333. >
  2334. 项目信息
  2335. </Button>
  2336. </TabPane>
  2337. {/* <TabPane tab="批量操作" key="6">
  2338. <Button
  2339. type="primary"
  2340. disabled={this.state.selectedRowKeys.length == 0}
  2341. style={{ margin: "0px 0px 10px 10px" }}
  2342. onClick={e => {
  2343. e.stopPropagation(),
  2344. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  2345. }}
  2346. >
  2347. 转交
  2348. </Button>
  2349. </TabPane> */}
  2350. </Tabs>
  2351. <div className="patent-table">
  2352. <Spin spinning={this.state.loading}>
  2353. <Table
  2354. bordered
  2355. columns={
  2356. this.state.changeList == undefined
  2357. ? this.state.columns
  2358. : this.state.changeList
  2359. }
  2360. dataSource={this.state.dataSource}
  2361. rowSelection={false}
  2362. scroll={{ x: "max-content", y: 0 }}
  2363. pagination={this.state.pagination}
  2364. onRowDoubleClick={this.tableRowClick.bind(this)}
  2365. rowSelection={rowSelection}
  2366. size="small"
  2367. />
  2368. </Spin>
  2369. <p
  2370. style={{ display: "inline-block", fontSize: "14px", color: "red" }}
  2371. >
  2372. {
  2373. <span style={{ marginRight: 10 }}>
  2374. {`收款金额总计(万元):${this.state.hui ? this.state.hui : "0"}`}
  2375. </span>
  2376. }
  2377. {
  2378. <span>
  2379. {`合同额总计(万元):${
  2380. this.state.totalHui ? this.state.totalHui : "0"
  2381. }`}
  2382. </span>
  2383. }
  2384. </p>
  2385. </div>
  2386. <div className="patent-desc">
  2387. <Modal
  2388. maskClosable={false}
  2389. visible={this.state.visible}
  2390. onCancel={this.closeModal}
  2391. width={this.state.width}
  2392. footer=""
  2393. className="admin-desc-content"
  2394. >
  2395. <Tabs
  2396. onChange={this.callBack}
  2397. type="card"
  2398. activeKey={this.state.modKey}
  2399. >
  2400. <TabPane tab="项目概况" key="1">
  2401. <Form layout="horizontal" id="demand-form">
  2402. <Spin spinning={this.state.loading}>
  2403. <div className="clearfix">
  2404. <FormItem
  2405. className="half-item"
  2406. {...formItemLayout}
  2407. label="订单编号"
  2408. >
  2409. <span>{this.state.orderNo}</span>
  2410. </FormItem>
  2411. <FormItem
  2412. className="half-item"
  2413. {...formItemLayout}
  2414. label="签单时间"
  2415. >
  2416. <span>{theData.signDate}</span>
  2417. </FormItem>
  2418. <FormItem
  2419. className="half-item"
  2420. {...formItemLayout}
  2421. label="客户名称"
  2422. >
  2423. <span>{theData.userName}</span>
  2424. </FormItem>
  2425. <FormItem
  2426. className="half-item"
  2427. {...formItemLayout}
  2428. label="流转状态"
  2429. >
  2430. <span>{getProcessStatus(theData.processStatus)}</span>
  2431. </FormItem>
  2432. <FormItem
  2433. className="half-item"
  2434. {...formItemLayout}
  2435. label="订单类型"
  2436. >
  2437. <span>{getNewOrderType(theData.orderType)}</span>
  2438. </FormItem>
  2439. <FormItem
  2440. className="half-item"
  2441. {...formItemLayout}
  2442. label="结算状态"
  2443. >
  2444. <span>
  2445. {getLiquidationStatus(theData.liquidationStatus)}
  2446. </span>
  2447. </FormItem>
  2448. <FormItem
  2449. className="half-item"
  2450. {...formItemLayout}
  2451. label="签单总金额(万元)"
  2452. >
  2453. <span>{theData.totalAmount}</span>
  2454. </FormItem>
  2455. <FormItem
  2456. className="half-item"
  2457. {...formItemLayout}
  2458. label="首付款(万元)"
  2459. >
  2460. <span>{theData.firstAmount}</span>
  2461. </FormItem>
  2462. <FormItem
  2463. className="half-item"
  2464. {...formItemLayout}
  2465. label="已收款(万元)"
  2466. >
  2467. <span>{theData.settlementAmount}</span>
  2468. </FormItem>
  2469. <FormItem
  2470. className="half-item"
  2471. {...formItemLayout}
  2472. label="是否特批"
  2473. >
  2474. <span>{getApproval(theData.approval)}</span>
  2475. </FormItem>
  2476. {/*this.props.data.orderStatus=='6'&&<FormItem className="half-item" {...formItemLayout} label="已退(万元)">
  2477. <span>{this.props.data.refundAmount}</span>
  2478. </FormItem>*/}
  2479. </div>
  2480. <div className="clearfix">
  2481. <FormItem
  2482. labelCol={{ span: 5 }}
  2483. wrapperCol={{ span: 18 }}
  2484. label="合同扫描件"
  2485. >
  2486. <Upload
  2487. className="demandDetailShow-upload"
  2488. listType="picture-card"
  2489. fileList={this.state.orgCodeUrl}
  2490. onPreview={file => {
  2491. this.setState({
  2492. previewImage: file.url || file.thumbUrl,
  2493. previewVisible: true
  2494. });
  2495. }}
  2496. ></Upload>
  2497. <Modal
  2498. maskClosable={false}
  2499. footer={null}
  2500. visible={this.state.previewVisible}
  2501. onCancel={() => {
  2502. this.setState({
  2503. previewVisible: false,
  2504. rotateDeg: 0
  2505. });
  2506. }}
  2507. >
  2508. <img
  2509. alt=""
  2510. style={{
  2511. width: "100%",
  2512. transform: `rotate(${this.state.rotateDeg}deg)`
  2513. }}
  2514. src={this.state.previewImage || ""}
  2515. />
  2516. <Button
  2517. onClick={this.rotate}
  2518. style={{
  2519. position: "relative",
  2520. left: "50%",
  2521. transform: "translateX(-50%)"
  2522. }}
  2523. >
  2524. 旋转
  2525. </Button>
  2526. <Button
  2527. onClick={this.upImg}
  2528. style={{
  2529. position: "absolute",
  2530. left: -81,
  2531. top: "50%",
  2532. transform: "translateY(-50%)"
  2533. }}
  2534. >
  2535. 上一张
  2536. </Button>
  2537. <Button
  2538. onClick={this.downImg}
  2539. style={{
  2540. position: "absolute",
  2541. right: -81,
  2542. top: "50%",
  2543. transform: "translateY(-50%)"
  2544. }}
  2545. >
  2546. 下一张
  2547. </Button>
  2548. </Modal>
  2549. <Button
  2550. style={{
  2551. float: "right",
  2552. marginRight: "140px",
  2553. marginTop: "20px"
  2554. }}
  2555. onClick={this.getOrderLog}
  2556. >
  2557. 查看订单日志
  2558. </Button>
  2559. </FormItem>
  2560. </div>
  2561. <div className="clearfix">
  2562. <FormItem
  2563. className="half-item"
  2564. {...formItemLayout}
  2565. label="合同编号"
  2566. >
  2567. <span>{theData.contractNo}</span>
  2568. </FormItem>
  2569. <FormItem
  2570. className="half-item"
  2571. {...formItemLayout}
  2572. label="订单部门"
  2573. >
  2574. <span>{theData.depName}</span>
  2575. </FormItem>
  2576. </div>
  2577. <div className="clearfix">
  2578. <FormItem
  2579. labelCol={{ span: 5 }}
  2580. wrapperCol={{ span: 18 }}
  2581. label="订单留言"
  2582. >
  2583. <p style={{ width: 500, wordWrap: "break-word" }}>
  2584. {this.state.orderRemarks}
  2585. </p>
  2586. </FormItem>
  2587. </div>
  2588. <div className="clearfix">
  2589. <FormItem
  2590. labelCol={{ span: 5 }}
  2591. wrapperCol={{ span: 18 }}
  2592. label="收款节点"
  2593. >
  2594. {jsDate.map(item => {
  2595. return (
  2596. <p>
  2597. {getjiedian(item.dunSubject)} -- {item.money} 万元
  2598. </p>
  2599. );
  2600. })}
  2601. </FormItem>
  2602. </div>
  2603. <div className="clearfix">
  2604. <FormItem
  2605. className="half-item"
  2606. {...formItemLayout}
  2607. label="订单负责人"
  2608. >
  2609. <span>{theData.salesmanName}</span>
  2610. </FormItem>
  2611. <FormItem
  2612. className="half-item"
  2613. {...formItemLayout}
  2614. label="订单负责人电话"
  2615. >
  2616. <span>{theData.salesmanMobile}</span>
  2617. </FormItem>
  2618. <FormItem
  2619. className="half-item"
  2620. {...formItemLayout}
  2621. label="当前财务负责人"
  2622. >
  2623. <span>{theData.nowFinance}</span>
  2624. </FormItem>
  2625. <FormItem
  2626. className="half-item"
  2627. {...formItemLayout}
  2628. label="当前财务负责人电话"
  2629. >
  2630. <span>{theData.nowFinanceMobile}</span>
  2631. </FormItem>
  2632. <FormItem
  2633. className="half-item"
  2634. {...formItemLayout}
  2635. style={{ opacity: ".5" }}
  2636. label="原订单负责人"
  2637. >
  2638. <span>{theData.oldSalesmanName}</span>
  2639. </FormItem>
  2640. <FormItem
  2641. className="half-item"
  2642. {...formItemLayout}
  2643. style={{ opacity: ".5" }}
  2644. label="原订单负责人电话"
  2645. >
  2646. <span>{theData.oldSalesmanMobile}</span>
  2647. </FormItem>
  2648. <FormItem
  2649. className="half-item"
  2650. {...formItemLayout}
  2651. style={{ opacity: ".5" }}
  2652. label="实际财务操作人"
  2653. >
  2654. <span>{theData.financeName}</span>
  2655. </FormItem>
  2656. <FormItem
  2657. className="half-item"
  2658. {...formItemLayout}
  2659. style={{ opacity: ".5" }}
  2660. label="实际财务操作人电话"
  2661. >
  2662. <span>{theData.financeMobile}</span>
  2663. </FormItem>
  2664. </div>
  2665. {/* <Modal
  2666. visible={this.state.avisible}
  2667. className="admin-desc-content"
  2668. width="800px"
  2669. maskClosable={false}
  2670. title="订单日志"
  2671. footer={null}
  2672. onCancel={this.closeOrderLog}
  2673. >
  2674. <div className="patent-table">
  2675. <Spin spinning={this.state.loading}>
  2676. <Table
  2677. columns={this.state.columnsY}
  2678. dataSource={this.state.dataSourceY}
  2679. pagination={false}
  2680. />
  2681. </Spin>
  2682. </div>
  2683. </Modal> */}
  2684. <OrderRiZi
  2685. dataSourcerizhi={this.state.dataSourceY}
  2686. closeOrderLog={this.closeOrderLog}
  2687. visible={this.state.avisible}
  2688. loading={this.state.loading}
  2689. />
  2690. <div className="clearfix">
  2691. <p style={{ fontSize: 18, marginLeft: 20 }}>项目业务</p>
  2692. <div className="patent-table">
  2693. <Spin spinning={this.state.loading}>
  2694. <Table
  2695. columns={this.state.columnsX}
  2696. dataSource={this.state.dataSourceX}
  2697. pagination={false}
  2698. />
  2699. </Spin>
  2700. </div>
  2701. </div>
  2702. </Spin>
  2703. </Form>
  2704. </TabPane>
  2705. <TabPane tab="外包详情" key="2">
  2706. <div className="clearfix">
  2707. <p style={{ color: "red" }}>
  2708. 提示:查看备注请点击表格左侧加号按钮~
  2709. </p>
  2710. <div className="patent-table">
  2711. <Spin spinning={this.state.loading}>
  2712. <Table
  2713. columns={this.state.columnsW}
  2714. dataSource={this.state.dataSourceW}
  2715. pagination={false}
  2716. expandedRowRender={record => (
  2717. <p style={{ margin: 0 }}>{record.remarks}</p>
  2718. )}
  2719. scroll={{ x: 300, y: 0 }}
  2720. />
  2721. </Spin>
  2722. </div>
  2723. </div>
  2724. </TabPane>
  2725. <TabPane tab="外包审核" key="3">
  2726. <div className="clearfix">
  2727. <FormItem
  2728. className="half-item"
  2729. labelCol={{ span: 8 }}
  2730. wrapperCol={{ span: 14 }}
  2731. label="外包公司"
  2732. >
  2733. <span>{this.state.companyName}</span>
  2734. </FormItem>
  2735. </div>
  2736. <div className="clearfix">
  2737. <FormItem
  2738. className="half-item"
  2739. {...formItemLayout}
  2740. label="单价(万元)"
  2741. >
  2742. <span>{this.state.unitPrice}</span>
  2743. </FormItem>
  2744. </div>
  2745. <div className="clearfix">
  2746. <FormItem
  2747. className="half-item"
  2748. {...formItemLayout}
  2749. label="数量(万元)"
  2750. >
  2751. <span>{this.state.unitNumber}</span>
  2752. </FormItem>
  2753. </div>
  2754. <div className="clearfix">
  2755. <FormItem
  2756. className="half-item"
  2757. {...formItemLayout}
  2758. label="总金额(万元)"
  2759. >
  2760. <span>{this.state.amount}</span>
  2761. </FormItem>
  2762. </div>
  2763. <div className="clearfix">
  2764. <FormItem
  2765. className="half-item"
  2766. {...formItemLayout}
  2767. label="备注"
  2768. >
  2769. <span>{this.state.outsourceRemarks}</span>
  2770. </FormItem>
  2771. </div>
  2772. {/*<div className="clearfix">
  2773. <FormItem className="half-item"
  2774. labelCol={{ span: 8 }}
  2775. wrapperCol={{ span: 14 }}
  2776. label="上传协议文件" >
  2777. <Upload header={{authorization: 'authorization-text'}} action={globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"}
  2778. data={(e)=>{
  2779. return {
  2780. 'sign': e.name.substring(0,e.name.lastIndexOf("."))
  2781. }
  2782. }}
  2783. fileList={this.state.attachmentUrl}
  2784. showUploadList={{showRemoveIcon:false}}
  2785. onPreview={(e)=>{
  2786. let url = window.location.href.substring(7)
  2787. window.location.href="http://"+url.substring(0,url.indexOf("/"))+"/api/admin/outsourceOrg//downloadFile?path="+e.response.data
  2788. }}>
  2789. </Upload>
  2790. </FormItem>
  2791. </div>*/}
  2792. <div className="clearfix">
  2793. <FormItem
  2794. labelCol={{ span: 4 }}
  2795. wrapperCol={{ span: 18 }}
  2796. label="合同/协议扫描件"
  2797. >
  2798. <Upload
  2799. className="demandDetailShow-upload"
  2800. listType="picture-card"
  2801. fileList={this.state.pictureUrl}
  2802. onPreview={file => {
  2803. this.setState({
  2804. previewImage: file.url || file.thumbUrl,
  2805. previewVisible: true
  2806. });
  2807. }}
  2808. ></Upload>
  2809. <Modal
  2810. maskClosable={false}
  2811. footer={null}
  2812. visible={this.state.previewVisible}
  2813. onCancel={() => {
  2814. this.setState({ previewVisible: false });
  2815. }}
  2816. >
  2817. <img
  2818. alt=""
  2819. style={{
  2820. width: "100%",
  2821. transform: `rotate(${this.state.rotateDeg}deg)`
  2822. }}
  2823. src={this.state.previewImage || ""}
  2824. />
  2825. <Button
  2826. onClick={this.rotate}
  2827. style={{
  2828. position: "relative",
  2829. left: "50%",
  2830. transform: "translateX(-50%)"
  2831. }}
  2832. >
  2833. 旋转
  2834. </Button>
  2835. <Button
  2836. onClick={this.upImg}
  2837. style={{
  2838. position: "absolute",
  2839. left: -81,
  2840. top: "50%",
  2841. transform: "translateY(-50%)"
  2842. }}
  2843. >
  2844. 上一张
  2845. </Button>
  2846. <Button
  2847. onClick={this.downImg}
  2848. style={{
  2849. position: "absolute",
  2850. right: -81,
  2851. top: "50%",
  2852. transform: "translateY(-50%)"
  2853. }}
  2854. >
  2855. 下一张
  2856. </Button>
  2857. </Modal>
  2858. </FormItem>
  2859. </div>
  2860. <div className="clearfix">
  2861. <hr className="division" />
  2862. <div className="clearfix">
  2863. <FormItem
  2864. className="half-item"
  2865. labelCol={{ span: 8 }}
  2866. wrapperCol={{ span: 14 }}
  2867. label="审核意见"
  2868. >
  2869. <span>{this.state.remarks}</span>
  2870. </FormItem>
  2871. </div>
  2872. <div className="clearfix">
  2873. <FormItem
  2874. className="half-item"
  2875. labelCol={{ span: 8 }}
  2876. wrapperCol={{ span: 14 }}
  2877. label="审核结果"
  2878. >
  2879. <span>{getRefundStatus(this.state.refundStatus)}</span>
  2880. </FormItem>
  2881. </div>
  2882. <div className="clearfix">
  2883. <FormItem
  2884. className="half-item"
  2885. labelCol={{ span: 8 }}
  2886. wrapperCol={{ span: 14 }}
  2887. label="审核时间"
  2888. >
  2889. <span>{this.state.auditTimes}</span>
  2890. </FormItem>
  2891. </div>
  2892. </div>
  2893. </TabPane>
  2894. </Tabs>
  2895. </Modal>
  2896. </div>
  2897. <div className="patent-desc">
  2898. <Modal
  2899. maskClosable={false}
  2900. title="驳回理由"
  2901. visible={this.state.boHuiVisible}
  2902. onCancel={this.boHuiCancel}
  2903. width="500px"
  2904. footer=""
  2905. className="admin-desc-content"
  2906. >
  2907. <TextArea
  2908. rows={4}
  2909. value={this.state.reason}
  2910. onChange={e => {
  2911. console.log(e.target.value);
  2912. this.setState({
  2913. reason: e.target.value
  2914. });
  2915. }}
  2916. />
  2917. <Button
  2918. type="primary"
  2919. style={{ marginTop: "20px" }}
  2920. onClick={this.boHuiCo}
  2921. >
  2922. 确定
  2923. </Button>
  2924. </Modal>
  2925. </div>
  2926. <Assign
  2927. title="任务"
  2928. selApi={"/api/admin/newOrder/updateFinance"}
  2929. data={this.state.assignDataY}
  2930. showDesc={this.state.assignVisibleY}
  2931. closeDesc={this.closeAssignY.bind(this)}
  2932. // fenpaiData={8}
  2933. specially={0}
  2934. roleName={this.state.nub}
  2935. requestMethod={"get"}
  2936. />
  2937. <Receivable
  2938. title="收款记录"
  2939. api="/api/admin/financial/addReceiptsFlow"
  2940. data={this.state.assignDataX}
  2941. showDesc={this.state.assignVisibleX}
  2942. closeDesc={this.closeAssignX.bind(this)}
  2943. />
  2944. <Modal
  2945. visible={this.state.bvisible}
  2946. footer=""
  2947. title="开票历史记录"
  2948. className="admin-desc-content"
  2949. width="900px"
  2950. onCancel={this.inRecordCanl}
  2951. >
  2952. <Spin spinning={this.state.loading}>
  2953. <div
  2954. className="patent-table"
  2955. ref={e => {
  2956. this.refs.kaiPiao = e;
  2957. }}
  2958. >
  2959. <Table
  2960. columns={this.state.columnsDate}
  2961. dataSource={this.state.recordData}
  2962. pagination={false}
  2963. bordered
  2964. />
  2965. <div className="clearfix" style={{ marginTop: "20px" }}>
  2966. <FormItem
  2967. className="half-item"
  2968. {...formItemLayout}
  2969. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  2970. >
  2971. <span>{this.state.sum + "(万元)"}</span>
  2972. </FormItem>
  2973. </div>
  2974. <ReactToPrint
  2975. trigger={() => (
  2976. <Button
  2977. type="primary"
  2978. style={{
  2979. float: "right",
  2980. // marginTop: 10,
  2981. position: "absolute",
  2982. top: -54,
  2983. right: 30
  2984. }}
  2985. >
  2986. 打印
  2987. </Button>
  2988. )}
  2989. content={() => this.refs.kaiPiao}
  2990. />
  2991. </div>
  2992. </Spin>
  2993. </Modal>
  2994. <Modal
  2995. visible={this.state.cvisible}
  2996. footer=""
  2997. title="详细收款流水"
  2998. className="admin-desc-content"
  2999. width="1300px"
  3000. onCancel={this.waterCanl}
  3001. >
  3002. <Spin spinning={this.state.loading}>
  3003. <div
  3004. className="patent-table"
  3005. ref={e => {
  3006. this.refs.shouKuan = e;
  3007. }}
  3008. >
  3009. <Table
  3010. columns={this.state.waterlistDate}
  3011. dataSource={this.state.waterData}
  3012. pagination={false}
  3013. bordered
  3014. />
  3015. <div className="clearfix" style={{ marginTop: "20px" }}>
  3016. <FormItem
  3017. className="half-item"
  3018. {...formItemLayout}
  3019. label={<span style={{ fontSize: "14px" }}>总计金额</span>}
  3020. >
  3021. <span>{this.state.waterSum + "(万元)"}</span>
  3022. </FormItem>
  3023. </div>
  3024. <ReactToPrint
  3025. trigger={() => (
  3026. <Button
  3027. type="primary"
  3028. style={{
  3029. float: "right",
  3030. position: "absolute",
  3031. top: -54,
  3032. right: 30
  3033. }}
  3034. >
  3035. 打印
  3036. </Button>
  3037. )}
  3038. content={() => this.refs.shouKuan}
  3039. />
  3040. </div>
  3041. </Spin>
  3042. </Modal>
  3043. <Modal
  3044. visible={this.state.dvisible}
  3045. footer=""
  3046. title="所有列表信息"
  3047. className="admin-desc-content"
  3048. width="1300px"
  3049. onCancel={() => {
  3050. this.loadData();
  3051. this.setState({
  3052. dvisible: false
  3053. });
  3054. }}
  3055. >
  3056. <Spin spinning={this.state.loading}>
  3057. <div
  3058. className="patent-table"
  3059. style={{
  3060. // width: 900,
  3061. // position: "relative",
  3062. // left: "50%",
  3063. // transform: "translate(-50%)",
  3064. padding: "25px 0 30px 30px"
  3065. }}
  3066. ref={e => {
  3067. this.refs.all = e;
  3068. }}
  3069. >
  3070. <Table
  3071. columns={this.state.printColumns}
  3072. dataSource={this.state.dataSource}
  3073. pagination={false}
  3074. bordered
  3075. size="small"
  3076. />
  3077. </div>
  3078. </Spin>
  3079. <ReactToPrint
  3080. trigger={() => (
  3081. <Button
  3082. type="primary"
  3083. style={{
  3084. float: "right",
  3085. marginTop: 10,
  3086. position: "absolute",
  3087. top: 0,
  3088. right: 30
  3089. }}
  3090. >
  3091. 打印
  3092. </Button>
  3093. )}
  3094. content={() => this.refs.all}
  3095. />
  3096. </Modal>
  3097. <Modal
  3098. visible={this.state.timeVisible}
  3099. footer=""
  3100. title="工时详情"
  3101. className="admin-desc-content"
  3102. width="1300px"
  3103. pagination={false}
  3104. onCancel={() => {
  3105. this.loadData();
  3106. this.setState({
  3107. timeVisible: false
  3108. });
  3109. }}
  3110. >
  3111. <Spin spinning={this.state.loading}>
  3112. <div
  3113. className="patent-table"
  3114. style={
  3115. {
  3116. // width: 900,
  3117. // position: "relative",
  3118. // left: "50%",
  3119. // transform: "translate(-50%)",
  3120. // padding: "25px 0 30px 30px"
  3121. }
  3122. }
  3123. ref={e => {
  3124. this.refs.all = e;
  3125. }}
  3126. >
  3127. <Table
  3128. columns={this.state.timeColumns}
  3129. dataSource={this.state.timeDataList}
  3130. pagination={false}
  3131. bordered
  3132. size="small"
  3133. />
  3134. </div>
  3135. </Spin>
  3136. <ReactToPrint
  3137. trigger={() => (
  3138. <Button
  3139. type="primary"
  3140. style={{
  3141. float: "right",
  3142. marginTop: 10,
  3143. position: "absolute",
  3144. top: 0,
  3145. right: 30
  3146. }}
  3147. >
  3148. 打印
  3149. </Button>
  3150. )}
  3151. content={() => this.refs.all}
  3152. />
  3153. </Modal>
  3154. <Modal
  3155. visible={this.state.cuiVisible}
  3156. footer=""
  3157. title="催款详情"
  3158. className="admin-desc-content"
  3159. width="1300px"
  3160. pagination={false}
  3161. onCancel={() => {
  3162. this.loadData();
  3163. this.setState({
  3164. cuiVisible: false
  3165. });
  3166. }}
  3167. >
  3168. <Spin spinning={this.state.loading}>
  3169. <div
  3170. className="patent-table"
  3171. style={
  3172. {
  3173. // width: 900,
  3174. // position: "relative",
  3175. // left: "50%",
  3176. // transform: "translate(-50%)",
  3177. // padding: "25px 0 30px 30px"
  3178. }
  3179. }
  3180. ref={e => {
  3181. this.refs.all = e;
  3182. }}
  3183. >
  3184. <Table
  3185. columns={this.state.cuiColumns}
  3186. dataSource={this.state.cuiDataList}
  3187. pagination={false}
  3188. bordered
  3189. size="small"
  3190. />
  3191. </div>
  3192. </Spin>
  3193. <ReactToPrint
  3194. trigger={() => (
  3195. <Button
  3196. type="primary"
  3197. style={{
  3198. float: "right",
  3199. marginTop: 10,
  3200. position: "absolute",
  3201. top: 0,
  3202. right: 30
  3203. }}
  3204. >
  3205. 打印
  3206. </Button>
  3207. )}
  3208. content={() => this.refs.all}
  3209. />
  3210. </Modal>
  3211. <Modal
  3212. visible={this.state.proVisible}
  3213. footer=""
  3214. title="项目详情"
  3215. className="admin-desc-content"
  3216. width="1300px"
  3217. pagination={false}
  3218. onCancel={() => {
  3219. this.loadData();
  3220. this.setState({
  3221. proVisible: false
  3222. });
  3223. }}
  3224. >
  3225. <Spin spinning={this.state.loading}>
  3226. <div
  3227. className="patent-table"
  3228. style={
  3229. {
  3230. // width: 900,
  3231. // position: "relative",
  3232. // left: "50%",
  3233. // transform: "translate(-50%)",
  3234. // padding: "25px 0 30px 30px"
  3235. }
  3236. }
  3237. ref={e => {
  3238. this.refs.all = e;
  3239. }}
  3240. >
  3241. <Table
  3242. columns={this.state.proColumns}
  3243. dataSource={this.state.proDataList}
  3244. pagination={false}
  3245. bordered
  3246. size="small"
  3247. />
  3248. </div>
  3249. <span style={{ display: "block", marginTop: 10, color: "red" }}>
  3250. 外包(内部)价格总计(万元):{this.state.totalWaibao}
  3251. </span>
  3252. </Spin>
  3253. <ReactToPrint
  3254. trigger={() => (
  3255. <Button
  3256. type="primary"
  3257. style={{
  3258. float: "right",
  3259. marginTop: 10,
  3260. position: "absolute",
  3261. top: 0,
  3262. right: 30
  3263. }}
  3264. >
  3265. 打印
  3266. </Button>
  3267. )}
  3268. content={() => this.refs.all}
  3269. />
  3270. </Modal>
  3271. <Spin spinning={this.state.loading}>
  3272. <Modal
  3273. title="审核订单"
  3274. visible={this.state.checkVisible}
  3275. onOk={this.checkOk}
  3276. okText={"通过"}
  3277. onCancel={() => {
  3278. this.loadData();
  3279. this.setState({
  3280. checkVisible: false,
  3281. checkData: ""
  3282. });
  3283. }}
  3284. >
  3285. <TextArea
  3286. onChange={(e, recard) => {
  3287. this.setState({
  3288. checkData: e.target.value
  3289. });
  3290. console.log(e.target.value);
  3291. }}
  3292. placeholder="请填写审核内容"
  3293. />
  3294. </Modal>
  3295. </Spin>
  3296. </div>
  3297. );
  3298. }
  3299. });
  3300. export default approvedOutsourcing;