shouKuang.jsx 133 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import moment from "moment";
  4. import "./public.less";
  5. import "./shouKuan.less";
  6. import {
  7. AutoComplete,
  8. Button,
  9. Form,
  10. Input,
  11. Spin,
  12. Table,
  13. Select,
  14. message,
  15. DatePicker,
  16. Modal,
  17. Tabs,
  18. Col,
  19. Tag,
  20. Popconfirm,
  21. Tooltip,
  22. } from "antd";
  23. import OrderDesc from "../orderDetail/orderDesc";
  24. import ResolutionDetail from "@/resolutionDetail";
  25. import Receivable from "./receivable";
  26. import Assign from "@/manageCenter/publicComponent/assign";
  27. import KaiPiaoModal from "./kaiPiaoModal";
  28. import ReactToPrint from "react-to-print";
  29. import {
  30. getLiquidationStatus,
  31. getProcessStatus,
  32. getApproval,
  33. getInvoiceStatus,
  34. getTransactionProject,
  35. getTaskStatus,
  36. getNewOrderStatus,
  37. getProjectStatus,
  38. getjiedian,
  39. splitUrl,
  40. } from "@/tools";
  41. import { ChooseList } from "../../order/orderNew/chooseList"
  42. import Project from "../../../../component/project"
  43. import LogPopup from "../../../common/logPopup";
  44. import { throws } from "assert";
  45. import { getProjectName, getClockState } from "@/tools";
  46. import { clockState, salesList } from "@/dataDic";
  47. import OrderItemStatus from "../../../common/orderItemStatus";
  48. import Cascaders from "../../../common/cascaders";
  49. const FormItem = Form.Item;
  50. const { TabPane } = Tabs;
  51. const { TextArea } = Input;
  52. const ShouKuang = React.createClass({
  53. //获取上级组织
  54. selectSuperId() {
  55. $.ajax({
  56. method: "get",
  57. dataType: "json",
  58. crossDomain: false,
  59. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  60. data: {},
  61. success: function (data) {
  62. let theArr = [];
  63. if (data.error && data.error.length === 0) {
  64. for (let i = 0; i < data.data.length; i++) {
  65. let theData = data.data[i];
  66. theArr.push(
  67. <Select.Option value={theData.id} key={theData.id}>
  68. {theData.name}
  69. </Select.Option>
  70. );
  71. }
  72. this.setState({
  73. contactsOption: theArr,
  74. });
  75. } else {
  76. message.warning(data.error[0].message);
  77. }
  78. }.bind(this),
  79. }).always(
  80. function () {
  81. this.setState({
  82. loading: false,
  83. });
  84. }.bind(this)
  85. );
  86. },
  87. departmentList() {
  88. // this.setState({
  89. // loading: true
  90. // });
  91. $.ajax({
  92. method: "get",
  93. dataType: "json",
  94. crossDomain: false,
  95. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  96. data: {},
  97. success: function (data) {
  98. let thedata = data.data;
  99. let theArr = [];
  100. if (!thedata) {
  101. if (data.error && data.error.length) {
  102. message.warning(data.error[0].message);
  103. }
  104. } else {
  105. thedata.map(function (item, index) {
  106. theArr.push({
  107. key: index,
  108. name: item.name,
  109. id: item.id,
  110. });
  111. });
  112. }
  113. this.setState({
  114. departmentArr: theArr,
  115. });
  116. }.bind(this),
  117. }).always(
  118. function () {
  119. // this.setState({
  120. // loading: false
  121. // });
  122. }.bind(this)
  123. );
  124. },
  125. loadData(pageNo, pageSize) {
  126. this.state.data = [];
  127. this.state.pagination.pageSize = 10;
  128. this.setState({
  129. // selectedRowKeys: [],
  130. // selectedRowKey: [],
  131. page: pageNo || this.state.pageNo,
  132. loadingA: true,
  133. pagination: this.state.pagination,
  134. });
  135. $.ajax({
  136. method: "get",
  137. dataType: "json",
  138. crossDomain: false,
  139. url: globalConfig.context + "/api/admin/financial/financeList",
  140. data: {
  141. pageNo: pageNo || 1,
  142. pageSize: pageSize || this.state.pagination.pageSize,
  143. buyerName: this.state.nameSearch, //客户名称
  144. orderNo: this.state.orderNoSearch,
  145. startTime: this.state.releaseDate[0],
  146. endTime: this.state.releaseDate[1],
  147. startFinalReceivablesTime: this.state.shouKuanDate[0],
  148. endFinalReceivablesTime: this.state.shouKuanDate[1],
  149. deps: this.state.departmenttList,
  150. processStatus: this.state.processStatusSearch,
  151. contractNo: this.state.contractNoSearch,
  152. liquidationStatus: this.state.liquidationStatus,
  153. amountStatus: this.state.amountStatus,
  154. approval: this.state.approval,
  155. projectType: this.state.projectType,
  156. },
  157. success: function (data) {
  158. let theArr = [];
  159. if (!data.data || !data.data.pagination.list) {
  160. if (data.error && data.error.length) {
  161. message.warning(data.error[0].message);
  162. }
  163. } else {
  164. for (let i = 0; i < data.data.pagination.list.length; i++) {
  165. let thisdata = data.data.pagination.list[i];
  166. thisdata.key = thisdata.orderNo;
  167. theArr.push(thisdata);
  168. }
  169. }
  170. this.state.pagination.current = data.data.pagination.pageNo;
  171. this.state.pagination.total = data.data.pagination.totalCount;
  172. if (
  173. data.data &&
  174. data.data.pagination.list &&
  175. !data.data.pagination.list.length
  176. ) {
  177. this.state.pagination.current = 0;
  178. this.state.pagination.total = 0;
  179. }
  180. this.setState({
  181. totalPage: data.data.pagination.totalPage,
  182. dataSource: theArr,
  183. pagination: this.state.pagination,
  184. totalHui: data.data.count ? data.data.count.signTotalAmount : 0,
  185. hui: data.data.count ? data.data.count.actuallyTotalAmount : 0,
  186. });
  187. }.bind(this),
  188. }).always(
  189. function () {
  190. // window.setTimeout(() => {
  191. this.setState({
  192. loadingA: false,
  193. });
  194. // },5000)
  195. }.bind(this)
  196. );
  197. },
  198. getInitialState() {
  199. return {
  200. cuiTabKey: "1",
  201. pubVisible: false,
  202. pubDataList: [],
  203. pubpageNo: 1,
  204. pubpagination: {
  205. defaultCurrent: 1,
  206. defaultPageSize: 10,
  207. showQuickJumper: true,
  208. pageSize: 10,
  209. onChange: function (page) {
  210. this.loadData(page);
  211. }.bind(this),
  212. showTotal: function (total) {
  213. return "共" + total + "条数据";
  214. },
  215. },
  216. searchMore: true,
  217. dvisible: false,
  218. pageNo: 1,
  219. assignVisibleX: false,
  220. assignVisibleY: false,
  221. releaseDate: [],
  222. shouKuanDate: [],
  223. assignDataX: [],
  224. assignDataY: [],
  225. totalPage: 0,
  226. processStatusSearch: [],//默认搜索无流程状态
  227. boHuivisible: false,
  228. selectedRowKeys: [],
  229. selectedRows: [],
  230. loading: false,
  231. loadingA: false,
  232. pagination: {
  233. defaultCurrent: 1,
  234. defaultPageSize: 10,
  235. showQuickJumper: true,
  236. pageSize: 10,
  237. onChange: function (page) {
  238. // console.log(page);
  239. this.setState({
  240. pageNo: page,
  241. });
  242. this.loadData(page);
  243. }.bind(this),
  244. showTotal: function (total) {
  245. return "共" + total + "条数据";
  246. },
  247. },
  248. // 子组件改变的表格title数组
  249. changeList: undefined,
  250. pubColumns: [
  251. {
  252. title: "编号",
  253. dataIndex: "key",
  254. key: "key",
  255. width: 45,
  256. },
  257. {
  258. title: "公出类型",
  259. dataIndex: "type",
  260. key: "type",
  261. width: 70,
  262. render: (text) =>
  263. <span
  264. style={{ color: ["#1D4FEA", "#1E90FF", "#FF5500", "red"][text] }}
  265. >
  266. {
  267. text === 0
  268. ? "业务公出" : text === 1
  269. ? "技术公出" : text === 2
  270. ? "行政公出" : text === 3
  271. ? "技术协单" : ""
  272. }
  273. </span>
  274. },
  275. {
  276. title: "客户名称",
  277. dataIndex: "nickname",
  278. key: "nickname",
  279. width: 80,
  280. render: (text) => {
  281. return (
  282. <div
  283. style={{
  284. width: 80,
  285. wordBreak: "break-all",
  286. }}
  287. >
  288. {text}
  289. </div>
  290. );
  291. },
  292. },
  293. {
  294. title: "跟单人",
  295. dataIndex: "sname",
  296. key: "sname",
  297. width: 70,
  298. render: (text) => {
  299. return (
  300. <Tooltip title={text}>
  301. <div
  302. style={{
  303. width: 90,
  304. overflow: "hidden",
  305. textOverflow: "ellipsis",
  306. whiteSpace: "nowrap",
  307. }}
  308. >
  309. {text}
  310. </div>
  311. </Tooltip>
  312. );
  313. },
  314. },
  315. {
  316. title: "公出人",
  317. dataIndex: "aname",
  318. key: "aname",
  319. width: 70,
  320. render: (text) => {
  321. return (
  322. <Tooltip title={text}>
  323. <div
  324. style={{
  325. width: 90,
  326. overflow: "hidden",
  327. textOverflow: "ellipsis",
  328. whiteSpace: "nowrap",
  329. }}
  330. >
  331. {text}
  332. </div>
  333. </Tooltip>
  334. );
  335. },
  336. },
  337. // {
  338. // title: "申请时间",
  339. // dataIndex: "createTimes",
  340. // key: "createTimes",
  341. // width: 130,
  342. // },
  343. {
  344. title: "公出时间",
  345. dataIndex: "releaseStarts",
  346. key: "releaseStarts",
  347. width: 130,
  348. render: (text, record) => (
  349. <div>
  350. <div>{text}</div>
  351. <div style={{ paddingLeft: "44px" }}>至</div>
  352. <div>{record.releaseEnds}</div>
  353. </div>
  354. ),
  355. },
  356. {
  357. title: "公出地点",
  358. dataIndex: "userName",
  359. key: "userName",
  360. width: 120,
  361. render: (text) => {
  362. return (
  363. <div>{text}</div>
  364. );
  365. },
  366. },
  367. {
  368. title: "打卡时间",
  369. dataIndex: "clockInTimes",
  370. key: "clockInTimes",
  371. width: 75,
  372. },
  373. {
  374. title: "时长(时)",
  375. dataIndex: "duration",
  376. key: "duration",
  377. width: 50,
  378. },
  379. {
  380. title: "打卡状态",
  381. dataIndex: "clockIn",
  382. key: "clockIn",
  383. width: 65,
  384. render: (text) => (
  385. <span
  386. style={{ color: ["#F21212", "#34DE38"][text] }}
  387. >
  388. {["未打卡", "已打卡"][text]}
  389. </span>
  390. )
  391. },
  392. {
  393. title: "审核状态",
  394. dataIndex: "status",
  395. key: "status",
  396. width: 110,
  397. render: (text, record) => (
  398. <div style={{ display: "flex", flexDirection: "row", flexWrap: "warp" }}>
  399. <Tag color={getClockState(text).color}>
  400. {getClockState(text).title}
  401. </Tag>
  402. {record.updateStatus == 1 && <Tag color="#1E90FF">改</Tag>}
  403. </div>
  404. ),
  405. },
  406. {
  407. title: "审核/指导",
  408. dataIndex: "auditInfo",
  409. key: "auditInfo",
  410. width: 160,
  411. render: (text) => {
  412. return <div style={{ wordBreak: "break-all" }}>{text}</div>;
  413. },
  414. },
  415. ],
  416. proColumns: [
  417. {
  418. title: "序号",
  419. dataIndex: "key",
  420. key: "key",
  421. },
  422. {
  423. title: "合同编号",
  424. dataIndex: "contractNo",
  425. key: "contractNo",
  426. },
  427. {
  428. title: "订单编号",
  429. dataIndex: "orderNo",
  430. key: "orderNo",
  431. },
  432. // {
  433. // title: "项目编号",
  434. // dataIndex: "id",
  435. // key: "id"
  436. // },
  437. {
  438. title: "客户名称",
  439. dataIndex: "userName",
  440. key: "userName",
  441. render: text => {
  442. return (
  443. <Tooltip title={text}>
  444. <div style={{
  445. maxWidth: '150px',
  446. overflow: 'hidden',
  447. textOverflow: "ellipsis",
  448. whiteSpace: 'nowrap',
  449. }}>{text}</div>
  450. </Tooltip>
  451. )
  452. }
  453. },
  454. {
  455. title: "订单负责人",
  456. dataIndex: "salesmanName",
  457. key: "salesmanName",
  458. },
  459. {
  460. title: "是否主项目",
  461. dataIndex: "main",
  462. key: "main",
  463. render: (text) => {
  464. return text == 0 ? "否" : "是";
  465. },
  466. },
  467. {
  468. title: "项目类别",
  469. dataIndex: "cname",
  470. key: "cname",
  471. },
  472. {
  473. title: "项目名称",
  474. dataIndex: "commodityName",
  475. key: "commodityName",
  476. },
  477. {
  478. title: "项目数量",
  479. dataIndex: "commodityQuantity",
  480. key: "commodityQuantity",
  481. render: (text, record) => {
  482. if (record.splitStatus == 1) {
  483. return (
  484. <span>
  485. {text}{" "}
  486. <Tag
  487. color="#108ee9"
  488. onClick={(e) => {
  489. e.stopPropagation();
  490. this.showRes(record);
  491. }}
  492. >
  493. 已拆
  494. </Tag>
  495. </span>
  496. );
  497. } else {
  498. return text;
  499. }
  500. },
  501. },
  502. {
  503. title: "服务市价",
  504. dataIndex: "commodityPrice",
  505. key: "commodityPrice",
  506. },
  507. {
  508. title: "证书编号",
  509. dataIndex: "certificateNumber",
  510. key: "certificateNumber",
  511. },
  512. {
  513. title: "项目状态",
  514. dataIndex: "projectStatus",
  515. key: "projectStatus",
  516. render: (text) => {
  517. return getProjectName(text);
  518. },
  519. },
  520. {
  521. title: "项目说明",
  522. dataIndex: "taskComment",
  523. key: "taskComment",
  524. },
  525. {
  526. title: "是否外包",
  527. dataIndex: "outsource",
  528. key: "outsource",
  529. render: (text) => {
  530. if (text == 0) {
  531. return "否";
  532. } else if (text == 1) {
  533. return "是";
  534. }
  535. },
  536. },
  537. // {
  538. // title: "外包(内部)公司",
  539. // dataIndex: "outsourceName",
  540. // key: "outsourceName",
  541. // },
  542. // {
  543. // title: "外包(内部)价格",
  544. // dataIndex: "outsourcePrice",
  545. // key: "outsourcePrice",
  546. // },
  547. ],
  548. qianColumns: [
  549. {
  550. title: "序号",
  551. dataIndex: "key",
  552. key: "key",
  553. },
  554. {
  555. title: "合同编号",
  556. dataIndex: "contractNo",
  557. key: "contractNo",
  558. },
  559. {
  560. title: "订单编号",
  561. dataIndex: "orderNo",
  562. key: "orderNo",
  563. },
  564. {
  565. title: "客户名称",
  566. dataIndex: "userName",
  567. key: "userName",
  568. render: text => {
  569. return (
  570. <Tooltip title={text}>
  571. <div style={{
  572. maxWidth: '150px',
  573. overflow: 'hidden',
  574. textOverflow: "ellipsis",
  575. whiteSpace: 'nowrap',
  576. }}>{text}</div>
  577. </Tooltip>
  578. )
  579. }
  580. },
  581. {
  582. title: "订单负责人",
  583. dataIndex: "salesmanName",
  584. key: "salesmanName",
  585. },
  586. {
  587. title: "订单部门",
  588. dataIndex: "depName",
  589. key: "depName",
  590. },
  591. {
  592. title: "订单状态",
  593. dataIndex: "orderStatus",
  594. key: "orderStatus",
  595. render: (text) => {
  596. return getNewOrderStatus(text);
  597. },
  598. },
  599. {
  600. title: "项目状态",
  601. dataIndex: "projectStatus",
  602. key: "projectStatus",
  603. render: (text) => {
  604. return getProjectName(text);
  605. },
  606. },
  607. {
  608. title: "签单金额",
  609. dataIndex: "totalAmount",
  610. key: "totalAmount",
  611. },
  612. {
  613. title: "结算状态",
  614. dataIndex: "liquidationStatus",
  615. key: "liquidationStatus",
  616. render: (text) => {
  617. return getLiquidationStatus(text);
  618. },
  619. },
  620. {
  621. title: "已收款",
  622. dataIndex: "settlementAmount",
  623. key: "settlementAmount",
  624. },
  625. {
  626. title: "欠款",
  627. dataIndex: "orderArrears",
  628. key: "orderArrears",
  629. },
  630. {
  631. title: "催收科目",
  632. dataIndex: "type",
  633. key: "type",
  634. render: (text) => {
  635. return "按时触发应收欠款";
  636. },
  637. },
  638. {
  639. title: "催款状态",
  640. dataIndex: "dunStatus",
  641. key: "dunStatus",
  642. render: (text) => {
  643. if (text == 0) {
  644. return "未启动";
  645. } else if (text == 1) {
  646. return "催款中";
  647. } else if (text == 2) {
  648. return "已完成";
  649. } else if (text == 3) {
  650. return "已停止";
  651. }
  652. },
  653. },
  654. {
  655. title: "催收启动时间",
  656. dataIndex: "startDate",
  657. key: "startDate",
  658. },
  659. ],
  660. cuiColumns: [
  661. {
  662. title: "序号",
  663. dataIndex: "key",
  664. key: "key",
  665. },
  666. {
  667. title: "合同编号",
  668. dataIndex: "contractNo",
  669. key: "contractNo",
  670. },
  671. {
  672. title: "订单编号",
  673. dataIndex: "orderNo",
  674. key: "orderNo",
  675. },
  676. {
  677. title: "客户名称",
  678. dataIndex: "userName",
  679. key: "userName",
  680. render: text => {
  681. return (
  682. <Tooltip title={text}>
  683. <div style={{
  684. maxWidth: '150px',
  685. overflow: 'hidden',
  686. textOverflow: "ellipsis",
  687. whiteSpace: 'nowrap',
  688. }}>{text}</div>
  689. </Tooltip>
  690. )
  691. }
  692. },
  693. {
  694. title: "订单负责人",
  695. dataIndex: "salesmanName",
  696. key: "salesmanName",
  697. },
  698. {
  699. title: "订单部门",
  700. dataIndex: "depName",
  701. key: "depName",
  702. },
  703. {
  704. title: "订单状态",
  705. dataIndex: "orderStatus",
  706. key: "orderStatus",
  707. render: (text) => {
  708. return getNewOrderStatus(text);
  709. },
  710. },
  711. {
  712. title: "项目状态",
  713. dataIndex: "projectStatus",
  714. key: "projectStatus",
  715. render: (text) => {
  716. return getProjectName(text);
  717. },
  718. },
  719. {
  720. title: "签单金额",
  721. dataIndex: "totalAmount",
  722. key: "totalAmount",
  723. },
  724. {
  725. title: "结算状态",
  726. dataIndex: "liquidationStatus",
  727. key: "liquidationStatus",
  728. render: (text) => {
  729. return getLiquidationStatus(text);
  730. },
  731. },
  732. {
  733. title: "已收款",
  734. dataIndex: "settlementAmount",
  735. key: "settlementAmount",
  736. },
  737. {
  738. title: "应收款",
  739. dataIndex: "accountsReceivable",
  740. key: "accountsReceivable",
  741. },
  742. {
  743. title: "催收科目",
  744. dataIndex: "dunSubject",
  745. key: "dunSubject",
  746. // render: text => {
  747. // return getjiedian(text);
  748. // }
  749. },
  750. {
  751. title: "催款状态",
  752. dataIndex: "dunStatus",
  753. key: "dunStatus",
  754. },
  755. {
  756. title: "催收启动时间",
  757. dataIndex: "startDate",
  758. key: "startDate",
  759. },
  760. ],
  761. timeColumns: [
  762. {
  763. title: "合同编号",
  764. dataIndex: "contractNo",
  765. key: "contractNo",
  766. },
  767. {
  768. title: "订单编号",
  769. dataIndex: "orderNo",
  770. key: "orderNo",
  771. },
  772. {
  773. title: "项目编号",
  774. dataIndex: "id",
  775. key: "id",
  776. render: (text, record) => {
  777. if (record.splitStatus == 2) {
  778. return <span>{record.splitSuper + "-" + record.splitId}</span>;
  779. } else {
  780. return text;
  781. }
  782. },
  783. },
  784. {
  785. title: "客户名称",
  786. dataIndex: "userName",
  787. key: "userName",
  788. render: text => {
  789. return (
  790. <Tooltip title={text}>
  791. <div style={{
  792. maxWidth: '150px',
  793. overflow: 'hidden',
  794. textOverflow: "ellipsis",
  795. whiteSpace: 'nowrap',
  796. }}>{text}</div>
  797. </Tooltip>
  798. )
  799. }
  800. },
  801. {
  802. title: "订单部门",
  803. dataIndex: "depName",
  804. key: "depName",
  805. },
  806. {
  807. title: "订单负责人",
  808. dataIndex: "salesmanName",
  809. key: "salesmanName",
  810. },
  811. {
  812. title: "项目类别",
  813. dataIndex: "cname",
  814. key: "cname",
  815. },
  816. {
  817. title: "项目名称",
  818. dataIndex: "taskName",
  819. key: "taskName",
  820. },
  821. {
  822. title: "项目负责人",
  823. dataIndex: "receiverName",
  824. key: "receiverName",
  825. },
  826. {
  827. title: "项目价格(万元)",
  828. dataIndex: "commodityPrice",
  829. key: "commodityPrice",
  830. },
  831. {
  832. title: "数量(个)",
  833. dataIndex: "commodityQuantity",
  834. key: "commodityQuantity",
  835. },
  836. {
  837. title: "任务状态",
  838. dataIndex: "taskStatus",
  839. key: "taskStatus",
  840. render: (text) => {
  841. return getTaskStatus(text);
  842. },
  843. },
  844. {
  845. title: "项目状态",
  846. dataIndex: "projectStatus",
  847. key: "projectStatus",
  848. render: (text) => {
  849. return getProjectName(text);
  850. },
  851. },
  852. {
  853. title: "工时",
  854. dataIndex: "hours",
  855. key: "hours",
  856. },
  857. {
  858. title: "是否外包",
  859. dataIndex: "outsource",
  860. key: "outsource",
  861. render: (text) => {
  862. if (text == 0) {
  863. return "否";
  864. } else if (text == 1) {
  865. return "是";
  866. }
  867. },
  868. },
  869. {
  870. title: "签单日期",
  871. dataIndex: "signTime",
  872. key: "signTime",
  873. },
  874. {
  875. title: "派单日期",
  876. dataIndex: "creteTime",
  877. key: "creteTime",
  878. },
  879. {
  880. title: "分配时间",
  881. dataIndex: "taskDistributionTime",
  882. key: "taskDistributionTime",
  883. },
  884. {
  885. title: "完成时间",
  886. dataIndex: "taskEndTime",
  887. key: "taskEndTime",
  888. },
  889. ],
  890. printColumns: [
  891. {
  892. title: "合同编号",
  893. dataIndex: "contractNo",
  894. key: "contractNo",
  895. },
  896. {
  897. title: "订单编号",
  898. dataIndex: "orderNo",
  899. key: "orderNo",
  900. // fixed: "left"
  901. },
  902. {
  903. title: "客户名称",
  904. dataIndex: "buyerName",
  905. key: "buyerName",
  906. render: text => {
  907. return (
  908. <Tooltip title={text}>
  909. <div style={{
  910. maxWidth: '150px',
  911. overflow: 'hidden',
  912. textOverflow: "ellipsis",
  913. whiteSpace: 'nowrap',
  914. }}>{text}</div>
  915. </Tooltip>
  916. )
  917. }
  918. },
  919. {
  920. title: "订单部门",
  921. dataIndex: "departmentName",
  922. key: "departmentName",
  923. },
  924. {
  925. title: "订单负责人",
  926. dataIndex: "sellerName",
  927. key: "sellerName",
  928. },
  929. {
  930. title: "签单日期",
  931. dataIndex: "signTime",
  932. key: "signTime",
  933. },
  934. {
  935. title: "下单日期",
  936. dataIndex: "createTime",
  937. key: "createTime",
  938. },
  939. {
  940. title: "签单金额(万元)",
  941. dataIndex: "signTotalAmount",
  942. key: "signTotalAmount",
  943. render: (text) => {
  944. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  945. },
  946. },
  947. {
  948. title: "开票金额(万元)",
  949. dataIndex: "invoiceAmount",
  950. key: "invoiceAmount",
  951. render: (text) => {
  952. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  953. },
  954. },
  955. {
  956. title: "已收款(万元)",
  957. dataIndex: "actuallyTotalAmount",
  958. key: "actuallyTotalAmount",
  959. render: (text) => {
  960. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  961. },
  962. },
  963. {
  964. title: "总成本(万元)",
  965. dataIndex: "costAmount",
  966. key: "costAmount",
  967. render: (text) => {
  968. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  969. }
  970. },
  971. {
  972. title: "已付成本(万元)",
  973. dataIndex: "paymentAmount",
  974. key: "paymentAmount",
  975. render: (text) => {
  976. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  977. },
  978. },
  979. {
  980. title: "最近收款(万元)",
  981. dataIndex: "finalReceivables",
  982. key: "finalReceivables",
  983. render: (text) => {
  984. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  985. },
  986. },
  987. {
  988. title: "最近收款时间",
  989. dataIndex: "finalReceivablesTime",
  990. key: "finalReceivablesTime",
  991. },
  992. {
  993. title: "结算状态",
  994. dataIndex: "liquidationStatus",
  995. key: "liquidationStatus",
  996. render: (text) => {
  997. return getLiquidationStatus(text);
  998. },
  999. },
  1000. {
  1001. title: "流程状态",
  1002. dataIndex: "processStatus",
  1003. key: "processStatus",
  1004. render: (text) => {
  1005. return getProcessStatus(text);
  1006. },
  1007. },
  1008. {
  1009. title: "特批状态",
  1010. dataIndex: "approval",
  1011. key: "approval",
  1012. render: (text) => {
  1013. return getApproval(text);
  1014. },
  1015. },
  1016. ],
  1017. columns: [
  1018. {
  1019. title: "销售类型",
  1020. dataIndex: "salesType",
  1021. key: "salesType",
  1022. className: "title-table",
  1023. fixed: "left",
  1024. render: (text, record) => {
  1025. return (
  1026. <Tooltip
  1027. title={salesList[text] + ((text == 3 || text == 4 || text == 5) ? (!record.other ? "" : "," + record.other) : "")}
  1028. >
  1029. <span>
  1030. {salesList[text]}
  1031. </span>
  1032. </Tooltip>
  1033. );
  1034. },
  1035. },
  1036. {
  1037. title: "合同编号",
  1038. dataIndex: "contractNo",
  1039. key: "contractNo",
  1040. className: "title-table",
  1041. fixed: "left",
  1042. render: (text, record) => {
  1043. return (
  1044. <Tooltip
  1045. title={
  1046. <Button
  1047. type="primary"
  1048. onClick={(e) => {
  1049. e.stopPropagation();
  1050. let input = document.getElementById("copyText");
  1051. input.value = text;
  1052. input.select();
  1053. document.execCommand("copy");
  1054. message.success("复制成功");
  1055. }}
  1056. >
  1057. 复制
  1058. </Button>
  1059. }
  1060. >
  1061. <div>
  1062. {text}
  1063. <div style={{ display: "flex" }}>
  1064. <OrderItemStatus deleteSign={record.deleteSign} />
  1065. {
  1066. record.approval == 1
  1067. ? <Tag color="#faa755">特批待审</Tag> : record.approval == 2
  1068. ? <Tag color="#ff0000">特批通过</Tag> : record.approval == 4
  1069. ? <Tag color="#faa755">特批待审</Tag> : record.approval == 5
  1070. ? <Tag color="#ff0000">特批通过</Tag> : ""
  1071. }
  1072. </div>
  1073. </div>
  1074. </Tooltip>
  1075. );
  1076. },
  1077. },
  1078. {
  1079. title: "客户名称",
  1080. dataIndex: "buyerName",
  1081. key: "buyerName",
  1082. className: "title-table",
  1083. fixed: "left",
  1084. width: 150,
  1085. render: text => {
  1086. return (
  1087. <Tooltip title={text}>
  1088. <div style={{
  1089. maxWidth: '150px',
  1090. overflow: 'hidden',
  1091. textOverflow: "ellipsis",
  1092. whiteSpace: 'nowrap',
  1093. }}>{text}</div>
  1094. </Tooltip>
  1095. )
  1096. }
  1097. },
  1098. {
  1099. title: "订单编号",
  1100. dataIndex: "orderNo",
  1101. key: "orderNo",
  1102. className: "title-table",
  1103. fixed: "left",
  1104. width: 150,
  1105. render: (text, record) => {
  1106. return (
  1107. <Tooltip
  1108. title={
  1109. <Button
  1110. type="primary"
  1111. onClick={(e) => {
  1112. e.stopPropagation();
  1113. let input = document.getElementById("copyText");
  1114. input.value = text;
  1115. input.select();
  1116. document.execCommand("copy");
  1117. message.success("复制成功");
  1118. }}
  1119. >
  1120. 复制
  1121. </Button>
  1122. }
  1123. >
  1124. <div>
  1125. {text}
  1126. <div>
  1127. {record.signTotalAmount >= 10 && <Tag color="#ef7207">大客户</Tag>}
  1128. {record.projectType == 1 && <Tag color="rgb(22, 155, 213)">会员</Tag>}
  1129. </div>
  1130. </div>
  1131. </Tooltip>
  1132. );
  1133. },
  1134. },
  1135. // {
  1136. // title: "特批状态",
  1137. // dataIndex: "approval",
  1138. // key: "approval",
  1139. // className: "title-table",
  1140. // render: (text) => {
  1141. // if (text == 1 || text == 2) {
  1142. // return <Tag color="#f50">{getApproval(text)}</Tag>;
  1143. // }
  1144. // return getApproval(text);
  1145. // },
  1146. // },
  1147. {
  1148. title: "订单部门",
  1149. dataIndex: "departmentName",
  1150. key: "departmentName",
  1151. className: "title-table",
  1152. },
  1153. {
  1154. title: "订单负责人",
  1155. dataIndex: "sellerName",
  1156. key: "sellerName",
  1157. className: "title-table",
  1158. },
  1159. {
  1160. title: "订单类型",
  1161. dataIndex: "serviceType",
  1162. key: "serviceType",
  1163. className: "title-table",
  1164. width: 150,
  1165. render: (text) => {
  1166. return !!text && text.replace(/[,,]/g, "+");
  1167. }
  1168. },
  1169. {
  1170. title: "订单内容",
  1171. dataIndex: "serviceProject",
  1172. key: "serviceProject",
  1173. className: "title-table",
  1174. render: (text) => {
  1175. return (<div dangerouslySetInnerHTML={{ __html: !!text && text.replace(/[,,]/g, "<br/>") }} />);
  1176. // return (<pre>{!!text && text.replace(/[,,]/g, "\n")}</pre>);
  1177. }
  1178. },
  1179. {
  1180. title: "财务负责人",
  1181. dataIndex: "financeName",
  1182. key: "financeName",
  1183. className: "title-table",
  1184. },
  1185. {
  1186. title: "签单日期",
  1187. dataIndex: "signTime",
  1188. key: "signTime",
  1189. className: "title-table",
  1190. },
  1191. {
  1192. title: "下单日期",
  1193. dataIndex: "createTime",
  1194. key: "createTime",
  1195. className: "title-table",
  1196. },
  1197. {
  1198. title: "签单金额(万元)",
  1199. dataIndex: "signTotalAmount",
  1200. key: "signTotalAmount",
  1201. className: "title-table",
  1202. render: (text) => {
  1203. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1204. }
  1205. },
  1206. {
  1207. title: "开票金额(万元)",
  1208. dataIndex: "invoiceAmount",
  1209. key: "invoiceAmount",
  1210. className: "title-table",
  1211. render: (text) => {
  1212. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1213. }
  1214. },
  1215. {
  1216. title: "已收款(万元)",
  1217. dataIndex: "actuallyTotalAmount",
  1218. key: "actuallyTotalAmount",
  1219. className: "title-table",
  1220. render: (text) => {
  1221. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1222. }
  1223. },
  1224. {
  1225. title: "应收款(万元)",
  1226. dataIndex: "orderReceivables",
  1227. key: "orderReceivables",
  1228. className: "title-table",
  1229. render: (text) => {
  1230. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1231. }
  1232. },
  1233. {
  1234. title: "欠款(万元)",
  1235. dataIndex: "orderArrears",
  1236. key: "orderArrears",
  1237. className: "title-table",
  1238. render: (text) => {
  1239. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1240. }
  1241. },
  1242. {
  1243. title: "总成本/实付",
  1244. dataIndex: "costAmount",
  1245. key: "costAmount",
  1246. className: "title-table",
  1247. render: (text, record) => {
  1248. return (
  1249. <span>
  1250. {isNaN(parseFloat(text)) ? text : parseFloat(text)}/
  1251. {isNaN(parseFloat(record.paymentAmount)) ? text : parseFloat(record.paymentAmount)}
  1252. </span>
  1253. )
  1254. },
  1255. },
  1256. {
  1257. title: "专利/专利已付",
  1258. dataIndex: "patentCost",
  1259. key: "patentCost",
  1260. className: "title-table",
  1261. render: (text, record) => {
  1262. return (
  1263. <span>
  1264. {isNaN(parseFloat(text)) ? text : parseFloat(text)}/
  1265. {isNaN(parseFloat(record.patentCostActual)) ? text : parseFloat(record.patentCostActual)}
  1266. </span>
  1267. )
  1268. },
  1269. },
  1270. {
  1271. title: "软著/软著已付",
  1272. dataIndex: "softCost",
  1273. key: "softCost",
  1274. className: "title-table",
  1275. render: (text, record) => {
  1276. return (
  1277. <span>
  1278. {isNaN(parseFloat(text)) ? text : parseFloat(text)}/
  1279. {isNaN(parseFloat(record.softCostActual)) ? text : parseFloat(record.softCostActual)}
  1280. </span>
  1281. )
  1282. },
  1283. },
  1284. {
  1285. title: "审计/审计已付",
  1286. dataIndex: "auditCost",
  1287. key: "auditCost",
  1288. className: "title-table",
  1289. render: (text, record) => {
  1290. return (
  1291. <span>
  1292. {isNaN(parseFloat(text)) ? text : parseFloat(text)}/
  1293. {isNaN(parseFloat(record.auditCostActual)) ? text : parseFloat(record.auditCostActual)}
  1294. </span>
  1295. )
  1296. },
  1297. },
  1298. {
  1299. title: "其他/其他已付",
  1300. dataIndex: "otherCost",
  1301. key: "otherCost",
  1302. className: "title-table",
  1303. render: (text, record) => {
  1304. return (
  1305. <span>
  1306. {isNaN(parseFloat(text)) ? text : parseFloat(text)}/
  1307. {isNaN(parseFloat(record.otherCostActual)) ? text : parseFloat(record.otherCostActual)}
  1308. </span>
  1309. )
  1310. },
  1311. },
  1312. {
  1313. title: "预估毛利(万元)",
  1314. dataIndex: "expectProfit",
  1315. key: "expectProfit",
  1316. className: "title-table",
  1317. },
  1318. {
  1319. title: "实际毛利(万元)",
  1320. dataIndex: "actualProfit",
  1321. key: "actualProfit",
  1322. className: "title-table",
  1323. },
  1324. {
  1325. title: "最近收款(万元)",
  1326. dataIndex: "finalReceivables",
  1327. key: "finalReceivables",
  1328. className: "title-table",
  1329. render: (text) => {
  1330. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1331. }
  1332. },
  1333. {
  1334. title: "最近收款时间",
  1335. dataIndex: "finalReceivablesTime",
  1336. key: "finalReceivablesTime",
  1337. className: "title-table",
  1338. },
  1339. {
  1340. title: "结算状态",
  1341. dataIndex: "liquidationStatus",
  1342. key: "liquidationStatus",
  1343. className: "title-table",
  1344. render: (text) => {
  1345. return getLiquidationStatus(text);
  1346. },
  1347. },
  1348. {
  1349. title: "流程状态",
  1350. dataIndex: "processStatus",
  1351. key: "processStatus",
  1352. className: "title-table",
  1353. render: (text) => {
  1354. return getProcessStatus(text);
  1355. },
  1356. },
  1357. // {
  1358. // title: '订单状态',
  1359. // dataIndex: 'orderStatus',
  1360. // key: 'orderStatus',
  1361. // render: text => { return getNewOrderStatus(text)}
  1362. // },
  1363. {
  1364. title: "操作",
  1365. dataIndex: "caozuo",
  1366. key: "caouzo",
  1367. className: "title-table",
  1368. render: (text, recard) => {
  1369. return (
  1370. <div>
  1371. {/* {recard.liquidationStatus < 2 &&
  1372. (recard.approval === 1 || recard.approval === 2) ? (
  1373. <Button
  1374. style={{ background: "rgb(192,192,192)" }}
  1375. onClick={e => {
  1376. e.stopPropagation(), this.evaluateX(recard);
  1377. }}
  1378. >
  1379. 收款
  1380. </Button>
  1381. ) : (
  1382. <Button
  1383. type="primary"
  1384. onClick={e => {
  1385. e.stopPropagation(), this.evaluateX(recard);
  1386. }}
  1387. >
  1388. 收款
  1389. </Button>
  1390. )} */}
  1391. {recard.backStatus == 3 ? <Tag>已驳回</Tag> : ""}
  1392. {recard.processStatus == 3 ? (
  1393. <Button
  1394. type="primary"
  1395. onClick={(e) => {
  1396. // e.stopPropagation(), this.evaluateZ(recard);
  1397. e.stopPropagation(), this.checkRemark(recard);
  1398. }}
  1399. style={{ marginLeft: "5px" }}
  1400. >
  1401. 通过
  1402. </Button>
  1403. ) : (
  1404. ""
  1405. )}
  1406. {!(
  1407. recard.actuallyTotalAmount &&
  1408. Number(recard.actuallyTotalAmount) > 0
  1409. ) && (
  1410. <Button
  1411. type="danger"
  1412. style={{
  1413. marginLeft: "5px",
  1414. display:
  1415. recard.processStatus == 3 ? "inline-block" : "none",
  1416. }}
  1417. onClick={(e) => {
  1418. e.stopPropagation(), this.reject(recard);
  1419. }}
  1420. >
  1421. 驳回
  1422. </Button>
  1423. )}
  1424. {
  1425. // <Button
  1426. // type="primary"
  1427. // style={{ marginLeft: "5px" }}
  1428. // onClick={e => {
  1429. // e.stopPropagation(), this.evaluateY(recard, "财务专员");
  1430. // console.log(recard);
  1431. // }}
  1432. // >
  1433. // 转交
  1434. // </Button>
  1435. }
  1436. </div>
  1437. );
  1438. },
  1439. },
  1440. ],
  1441. dataSource: [],
  1442. searchTime: [],
  1443. columnsDate: [
  1444. {
  1445. title: "编号",
  1446. dataIndex: "id",
  1447. key: "id",
  1448. },
  1449. {
  1450. title: "订单编号",
  1451. dataIndex: "orderno",
  1452. key: "orderno",
  1453. },
  1454. {
  1455. title: "开票金额(万元)",
  1456. dataIndex: "amount",
  1457. key: "amount",
  1458. },
  1459. {
  1460. title: "申请时间",
  1461. dataIndex: "createTime",
  1462. key: "createTime",
  1463. },
  1464. {
  1465. title: "开票状态",
  1466. dataIndex: "status",
  1467. key: "status",
  1468. render: (text, record) => {
  1469. return <div>{getInvoiceStatus(text, record)} <LogPopup id={record.id} /></div>;
  1470. },
  1471. },
  1472. ],
  1473. waterlistDate: [
  1474. {
  1475. title: "订单编号",
  1476. dataIndex: "orderNo",
  1477. key: "orderNo",
  1478. },
  1479. {
  1480. title: "平台流水号",
  1481. dataIndex: "billNo",
  1482. key: "billNo",
  1483. // fixed: "left"
  1484. },
  1485. {
  1486. title: "收款金额(万元)",
  1487. dataIndex: "transactionAmount",
  1488. key: "transactionAmount",
  1489. },
  1490. {
  1491. title: "收款方",
  1492. dataIndex: "payeeName",
  1493. key: "payeeName",
  1494. },
  1495. {
  1496. title: "付款方",
  1497. dataIndex: "payerName",
  1498. key: "payerName",
  1499. },
  1500. {
  1501. title: "流水科目",
  1502. dataIndex: "transactionSubject",
  1503. key: "transactionSubject",
  1504. render: (text) => {
  1505. return getTransactionProject(text);
  1506. },
  1507. },
  1508. {
  1509. title: "收款类型",
  1510. dataIndex: "type",
  1511. key: "type",
  1512. },
  1513. {
  1514. title: "财务流水时间",
  1515. dataIndex: "financialPayTimes",
  1516. key: "financialPayTimes",
  1517. },
  1518. {
  1519. title: "财务流水号",
  1520. dataIndex: "financialPayNo",
  1521. key: "financialPayNo",
  1522. },
  1523. {
  1524. title: "订单负责人",
  1525. dataIndex: "saleName",
  1526. key: "saleName",
  1527. },
  1528. {
  1529. title: "创建时间",
  1530. dataIndex: "createTimes",
  1531. key: "createTimes",
  1532. },
  1533. {
  1534. title: "退款时间",
  1535. dataIndex: "refundTimes",
  1536. key: "refundTimes",
  1537. },
  1538. {
  1539. title: "删除时间",
  1540. dataIndex: "deleteTimes",
  1541. key: "deleteTimes",
  1542. },
  1543. {
  1544. title: "备注",
  1545. dataIndex: "remarks",
  1546. key: "remarks",
  1547. },
  1548. {
  1549. title: "流水状态",
  1550. dataIndex: "deleteSign",
  1551. key: "deleteSign",
  1552. render: (text, record) => {
  1553. if (!text) {
  1554. return (
  1555. <Popconfirm
  1556. title="是否删除?"
  1557. onConfirm={() => {
  1558. this.changeWater(record.billNo);
  1559. }}
  1560. okText="删除"
  1561. cancelText="不删除"
  1562. >
  1563. <Button>删除</Button>
  1564. </Popconfirm>
  1565. );
  1566. } else {
  1567. return <Tag>已删除</Tag>;
  1568. }
  1569. },
  1570. },
  1571. ],
  1572. waterData: [],
  1573. newVisible: "",
  1574. };
  1575. },
  1576. changeWater(billNo) {
  1577. this.setState({
  1578. loading: true,
  1579. });
  1580. $.ajax({
  1581. method: "get",
  1582. dataType: "json",
  1583. crossDomain: false,
  1584. url: globalConfig.context + "/api/admin/financial/deleteMyBill",
  1585. data: {
  1586. billNo,
  1587. },
  1588. success: function (data) {
  1589. let theArr = [];
  1590. if (data.error && data.error.length) {
  1591. message.warning(data.error[0].message);
  1592. } else {
  1593. message.warning("删除流水成功!");
  1594. this.waterData();
  1595. this.loadData();
  1596. }
  1597. }.bind(this),
  1598. }).always(
  1599. function () {
  1600. this.setState({
  1601. loading: false,
  1602. });
  1603. }.bind(this)
  1604. );
  1605. },
  1606. // 特批通过
  1607. evaluateZ(record) {
  1608. $.ajax({
  1609. method: "POST",
  1610. dataType: "json",
  1611. crossDomain: false,
  1612. url: globalConfig.context + "/api/admin/financial/financeApproval",
  1613. data: {
  1614. orderNo: record.orderNo,
  1615. },
  1616. }).done(
  1617. function (data) {
  1618. if (!data.error.length) {
  1619. message.success("通过成功!");
  1620. this.setState({
  1621. loading: false,
  1622. });
  1623. this.loadData();
  1624. } else {
  1625. message.warning(data.error[0].message);
  1626. }
  1627. }.bind(this)
  1628. );
  1629. },
  1630. /* 收款 */
  1631. evaluateX(recard) {
  1632. this.state.assignDataX = recard;
  1633. this.setState({
  1634. assignVisibleX: true,
  1635. });
  1636. },
  1637. /* 转交 */
  1638. evaluateY(recard, nub) {
  1639. this.state.assignDataY = recard;
  1640. this.setState({
  1641. nub,
  1642. assignVisibleY: true,
  1643. });
  1644. },
  1645. /* 驳回 */
  1646. reject(recard) {
  1647. this.setState({
  1648. bohuiData: recard,
  1649. boHuiVisible: true,
  1650. content: "",
  1651. });
  1652. },
  1653. boHuiOk() {
  1654. this.setState({
  1655. boHuiVisible: false,
  1656. });
  1657. if (
  1658. this.state.pagination.current == this.state.totalPage &&
  1659. this.state.pagination.total % 10 == 1
  1660. ) {
  1661. this.loadData(this.state.page - 1);
  1662. } else {
  1663. this.loadData(this.state.page);
  1664. }
  1665. },
  1666. boHuiCancel() {
  1667. this.setState({
  1668. boHuiVisible: false,
  1669. });
  1670. },
  1671. componentWillMount() {
  1672. this.loadData();
  1673. this.departmentList();
  1674. },
  1675. tableRowClick(record) {
  1676. this.state.RowData = record;
  1677. this.setState({
  1678. showDesc: true,
  1679. });
  1680. },
  1681. closeDesc(e, s) {
  1682. this.state.showDesc = e;
  1683. if (s) {
  1684. this.loadData(this.state.page);
  1685. }
  1686. },
  1687. closeAssignX(e, s) {
  1688. this.state.assignDataX = {};
  1689. this.state.assignVisibleX = e;
  1690. if (s) {
  1691. this.loadData(this.state.page);
  1692. }
  1693. },
  1694. closeAssignY(e, s) {
  1695. this.state.assignDataY = {};
  1696. this.state.assignVisibleY = e;
  1697. if (s) {
  1698. this.loadData(this.state.page);
  1699. }
  1700. },
  1701. search() {
  1702. this.setState({
  1703. selectedRowKeys: []
  1704. })
  1705. this.loadData();
  1706. },
  1707. // 拆分详细
  1708. showRes(record) {
  1709. this.setState({
  1710. resVisible: true,
  1711. resRecord: record,
  1712. });
  1713. },
  1714. resCancel() {
  1715. this.setState({
  1716. resVisible: false,
  1717. });
  1718. },
  1719. reset() {
  1720. this.state.nameSearch = "";
  1721. this.state.releaseDate = [];
  1722. this.state.shouKuanDate = [];
  1723. this.state.orderNoSearch = "";
  1724. this.state.departmenttList = undefined;
  1725. this.state.amountStatus = undefined;
  1726. this.state.approval = undefined;
  1727. this.state.projectType = undefined;
  1728. this.state.processStatus = [];
  1729. this.state.contractNoSearch = "";
  1730. this.state.liquidationStatus = [];
  1731. this.state.processStatusSearch = [];
  1732. this.state.contractNo = "";
  1733. this.Cascaders.empty();
  1734. this.loadData();
  1735. },
  1736. //驳回
  1737. boHuiSubmit(e) {
  1738. e.preventDefault();
  1739. if (!this.state.content) {
  1740. message.warning("请填写驳回原因");
  1741. return false;
  1742. }
  1743. if (!this.state.content.replace(/\s+/g, '')) {
  1744. message.warning("请填写驳回原因");
  1745. return false;
  1746. }
  1747. this.setState({
  1748. loading: true,
  1749. });
  1750. $.ajax({
  1751. method: "POST",
  1752. dataType: "json",
  1753. crossDomain: false,
  1754. url: globalConfig.context + "/api/admin/financial/reject",
  1755. data: {
  1756. orderNo: this.state.bohuiData.orderNo,
  1757. reason: this.state.content,
  1758. },
  1759. }).done(
  1760. function (data) {
  1761. if (!data.error.length) {
  1762. message.success("驳回成功!");
  1763. this.setState({
  1764. loading: false,
  1765. });
  1766. this.boHuiOk();
  1767. } else {
  1768. message.warning(data.error[0].message);
  1769. }
  1770. }.bind(this)
  1771. );
  1772. },
  1773. searchSwitch() {
  1774. this.setState({
  1775. searchMore: !this.state.searchMore,
  1776. });
  1777. },
  1778. changeList(arr) {
  1779. const newArr = [];
  1780. this.state.columns.forEach((item) => {
  1781. arr.forEach((val) => {
  1782. if (val === item.title) {
  1783. newArr.push(item);
  1784. }
  1785. });
  1786. });
  1787. this.setState({
  1788. changeList: newArr,
  1789. });
  1790. },
  1791. callback(key) {
  1792. // console.log(key);
  1793. },
  1794. onSelectChange(selectedRowKeys, selectedRows) {
  1795. // for(var i=0; i<selectedRowKeys.length; i++){
  1796. // for(var j=i+1; j<selectedRowKeys.length; j++){
  1797. // if(selectedRowKeys[i]==selectedRowKeys[j]){
  1798. // selectedRowKeys.splice(j,1);
  1799. // j--;
  1800. // }
  1801. // }
  1802. // }
  1803. this.setState({
  1804. selectedRowKeys,
  1805. selectedRows,
  1806. newData: selectedRows,
  1807. });
  1808. },
  1809. inRecordCanl() {
  1810. this.setState({
  1811. bvisible: false,
  1812. });
  1813. },
  1814. inRecordData() {
  1815. this.setState({
  1816. loading: true,
  1817. });
  1818. $.ajax({
  1819. method: "get",
  1820. dataType: "json",
  1821. crossDomain: false,
  1822. url:
  1823. globalConfig.context +
  1824. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  1825. data: {
  1826. orderNo: this.state.selectedRowKeys[0],
  1827. pageSize: 9999999,
  1828. },
  1829. success: function (data) {
  1830. let theArr = [];
  1831. let sum = 0;
  1832. if (!data.data) {
  1833. if (data.error && data.error.length) {
  1834. message.warning(data.error[0].message);
  1835. }
  1836. } else {
  1837. for (let i = 0; i < data.data.list.length; i++) {
  1838. let thisdata = data.data.list[i];
  1839. sum += parseFloat(thisdata.amount);
  1840. theArr.push({
  1841. id: thisdata.id,
  1842. orderno: thisdata.orderno, //订单编号
  1843. amount: thisdata.amount, //签单金额
  1844. createTime: thisdata.createTime, //流程状态
  1845. status: thisdata.status, //结算状态
  1846. rejectReason: thisdata.rejectReason,
  1847. approval: thisdata.approval,//0非特批 1待审核 2审核通过
  1848. });
  1849. }
  1850. }
  1851. this.setState({
  1852. recordData: theArr,
  1853. sum: sum.toFixed(6),
  1854. });
  1855. }.bind(this),
  1856. }).done(
  1857. function () {
  1858. this.setState({
  1859. loading: false,
  1860. });
  1861. }.bind(this)
  1862. );
  1863. },
  1864. waterData() {
  1865. this.state.data = [];
  1866. this.setState({
  1867. loading: true,
  1868. });
  1869. $.ajax({
  1870. method: "get",
  1871. dataType: "json",
  1872. crossDomain: false,
  1873. url: globalConfig.context + "/api/admin/financial/myBillList",
  1874. data: {
  1875. orderNo: this.state.selectedRowKeys[0],
  1876. pageSize: 9999999,
  1877. whoType: 1,
  1878. },
  1879. success: function (data) {
  1880. let theArr = [];
  1881. let waterSum = 0;
  1882. if (!data.data || !data.data.list) {
  1883. if (data.error && data.error.length) {
  1884. message.warning(data.error[0].message);
  1885. }
  1886. } else {
  1887. for (let i = 0; i < data.data.list.length; i++) {
  1888. let thisdata = data.data.list[i];
  1889. if (thisdata.deleteSign == 0) {
  1890. waterSum += parseFloat(thisdata.transactionAmount);
  1891. }
  1892. theArr.push({
  1893. key: i,
  1894. orderNo: thisdata.orderNo,
  1895. billNo: thisdata.billNo,
  1896. transactionAmount: thisdata.transactionAmount,
  1897. payeeName: thisdata.payeeName,
  1898. payerName: thisdata.payerName,
  1899. transactionSubject: thisdata.transactionSubject,
  1900. transactionChannel: thisdata.transactionChannel,
  1901. financialPayTimes: thisdata.financialPayTimes,
  1902. financialPayNo: thisdata.financialPayNo,
  1903. createrName: thisdata.createrName,
  1904. saleName: thisdata.saleName,
  1905. createTimes: thisdata.createTimes,
  1906. type:
  1907. thisdata.type == 0
  1908. ? "手工"
  1909. : thisdata.type == 1
  1910. ? "批量"
  1911. : "合同变更退款",
  1912. deleteSign: thisdata.deleteSign,
  1913. deleteTimes: thisdata.deleteTimes,
  1914. refundTimes: thisdata.refundTimes,
  1915. remarks: thisdata.remarks,
  1916. });
  1917. }
  1918. }
  1919. this.setState({
  1920. waterData: theArr,
  1921. waterSum: (Math.round(waterSum * 1000000) / 1000000).toFixed(6),
  1922. });
  1923. }.bind(this),
  1924. }).always(
  1925. function () {
  1926. this.setState({
  1927. loading: false,
  1928. });
  1929. }.bind(this)
  1930. );
  1931. },
  1932. waterCanl() {
  1933. this.setState({
  1934. cvisible: false,
  1935. });
  1936. },
  1937. exportKaip() {
  1938. window.location.href =
  1939. globalConfig.context +
  1940. "/api/admin/receivables/exportInvoice?" +
  1941. `orderNo=${this.state.selectedRowKeys}`;
  1942. },
  1943. exportAll() {
  1944. message.config({
  1945. duration: 20,
  1946. });
  1947. let loading = message.loading("下载中...");
  1948. this.setState({
  1949. exportPendingLoading: true,
  1950. });
  1951. let data = {
  1952. orderNo: this.state.orderNoSearch,
  1953. buyerName: this.state.nameSearch,
  1954. deps: this.state.departmenttList,
  1955. contractNo: this.state.contractNoSearch,
  1956. processStatus: this.state.processStatusSearch,
  1957. startTime: this.state.releaseDate[0],
  1958. endTime: this.state.releaseDate[1],
  1959. startFinalReceivablesTime: this.state.shouKuanDate[0],
  1960. endFinalReceivablesTime: this.state.shouKuanDate[1],
  1961. contractNo: this.state.contractNoSearch,
  1962. liquidationStatus: this.state.liquidationStatus,
  1963. amountStatus: this.state.amountStatus,
  1964. approval: this.state.approval,
  1965. projectType: this.state.projectType,
  1966. };
  1967. $.ajax({
  1968. method: "get",
  1969. dataType: "json",
  1970. crossDomain: false,
  1971. url: "/api/admin/receivables/exportReceivables",
  1972. data,
  1973. success: function (data) {
  1974. if (data.error.length === 0) {
  1975. this.download(data.data);
  1976. } else {
  1977. message.warning(data.error[0].message);
  1978. }
  1979. }.bind(this),
  1980. }).always(
  1981. function () {
  1982. loading();
  1983. this.setState({
  1984. exportPendingLoading: false,
  1985. });
  1986. }.bind(this)
  1987. );
  1988. // window.location.href =
  1989. // globalConfig.context +
  1990. // "/api/admin/receivables/exportReceivables?" +
  1991. // `orderNo=${this.state.orderNoSearch ? this.state.orderNoSearch : ""
  1992. // }&buyerName=${this.state.nameSearch ? this.state.nameSearch : ""
  1993. // }&deps=${this.state.departmenttList ? this.state.departmenttList : ""
  1994. // }&contractNo=${this.state.contractNoSearch ? this.state.contractNoSearch : ""
  1995. // }&processStatus=${this.state.processStatusSearch}`;
  1996. },
  1997. // 下载
  1998. download(fileName) {
  1999. window.location.href =
  2000. globalConfig.context + "/open/download?fileName=" + fileName;
  2001. },
  2002. exportWater() {
  2003. window.location.href =
  2004. globalConfig.context +
  2005. "/api/admin/receivables/exportMyBill?" +
  2006. `orderNo=${this.state.selectedRowKeys}&whoType=1`;
  2007. },
  2008. printAll() {
  2009. this.setState({
  2010. dvisible: true,
  2011. });
  2012. this.loadData(1, 9999999);
  2013. },
  2014. timeData() {
  2015. this.setState({
  2016. loading: true,
  2017. });
  2018. $.ajax({
  2019. method: "get",
  2020. dataType: "json",
  2021. crossDomain: false,
  2022. url: globalConfig.context + "/api/admin/orderProject/taskHoursList",
  2023. data: {
  2024. orderNo: this.state.selectedRowKeys[0],
  2025. pageSize: 9999999,
  2026. },
  2027. success: function (data) {
  2028. let theArr = [];
  2029. if (!data.data || !data.data.list) {
  2030. if (data.error && data.error.length) {
  2031. message.warning(data.error[0].message);
  2032. }
  2033. } else {
  2034. for (let i = 0; i < data.data.list.length; i++) {
  2035. let thisdata = data.data.list[i];
  2036. theArr.push({
  2037. key: i + 1,
  2038. id: thisdata.id, //ID
  2039. orderNo: thisdata.orderNo, //订单编号
  2040. taskName: thisdata.taskName, //任务名称
  2041. userName: thisdata.userName, //客户名称
  2042. cname: thisdata.cname, //项目品类
  2043. taskStatus: thisdata.taskStatus, //任务状态
  2044. receiverName: thisdata.receiverName, //负责人
  2045. hours: thisdata.hours, //任务工时
  2046. depName: thisdata.depName, //派单公司
  2047. contractNo: thisdata.contractNo,
  2048. signTime: thisdata.signTime,
  2049. creteTime: thisdata.creteTime,
  2050. projectStatus: thisdata.projectStatus,
  2051. commodityPrice: thisdata.commodityPrice, //价格
  2052. commodityQuantity: thisdata.commodityQuantity, //数量
  2053. salesmanName: thisdata.salesmanName, //订单负责人
  2054. taskDistributionTime: thisdata.taskDistributionTime,
  2055. taskEndTime: thisdata.taskEndTime,
  2056. outsource: thisdata.outsource,
  2057. splitStatus: thisdata.splitStatus,
  2058. splitSuper: thisdata.splitSuper,
  2059. splitId: thisdata.splitId,
  2060. });
  2061. }
  2062. }
  2063. this.setState({
  2064. timeDataList: theArr,
  2065. });
  2066. }.bind(this),
  2067. }).always(
  2068. function () {
  2069. this.setState({
  2070. loading: false,
  2071. });
  2072. }.bind(this)
  2073. );
  2074. },
  2075. exportTime() {
  2076. const data = {
  2077. orderNo: this.state.selectedRowKeys[0],
  2078. pageSize: 9999999,
  2079. };
  2080. window.location.href =
  2081. globalConfig.context +
  2082. "/api/admin/orderProject/exportMyTaskList?" +
  2083. $.param(data);
  2084. },
  2085. exportPro() {
  2086. const data = {
  2087. orderNo: this.state.selectedRowKeys[0],
  2088. };
  2089. window.location.href =
  2090. globalConfig.context +
  2091. "/api/admin/newOrder/exportOrderTaskData?" +
  2092. $.param(data);
  2093. },
  2094. // exportCui() {
  2095. // const data = {
  2096. // orderNo: this.state.selectedRowKeys[0]
  2097. // ? this.state.selectedRowKeys[0]
  2098. // : undefined, //订单编号
  2099. // // specially: 1,
  2100. // pageSize: 9999999,
  2101. // };
  2102. // window.location.href =
  2103. // globalConfig.context +
  2104. // "/api/admin/newOrder/exportOrderDunData?" +
  2105. // $.param(data);
  2106. // },
  2107. exportCui() {
  2108. this.setState({
  2109. exportPendingLoading: true,
  2110. });
  2111. message.config({
  2112. duration: 20,
  2113. });
  2114. let loading = message.loading("下载中...");
  2115. let data = {
  2116. orderNo: this.state.selectedRowKeys[0]
  2117. ? this.state.selectedRowKeys[0]
  2118. : undefined, //订单编号
  2119. pageSize: 9999999,
  2120. };
  2121. $.ajax({
  2122. method: "get",
  2123. dataType: "json",
  2124. crossDomain: false,
  2125. url:
  2126. globalConfig.context + "/api/admin/newOrder/exportOrderDunData",
  2127. data,
  2128. success: function (data) {
  2129. if (data.error.length === 0) {
  2130. this.download(data.data);
  2131. } else {
  2132. message.warning(data.error[0].message);
  2133. }
  2134. }.bind(this),
  2135. }).always(
  2136. function () {
  2137. loading();
  2138. this.setState({
  2139. exportPendingLoading: false,
  2140. });
  2141. }.bind(this)
  2142. );
  2143. },
  2144. cuiData() {
  2145. this.setState({
  2146. loading: true,
  2147. });
  2148. $.ajax({
  2149. method: "get",
  2150. dataType: "json",
  2151. crossDomain: false,
  2152. url: globalConfig.context + "/api/admin/newOrder/dunOrderNewList",
  2153. data: {
  2154. orderNo: this.state.selectedRowKeys[0],
  2155. pageSize: 9999999,
  2156. },
  2157. success: function (data) {
  2158. let theArr = [];
  2159. if (!data.data || !data.data.list) {
  2160. if (data.error && data.error.length) {
  2161. message.warning(data.error[0].message);
  2162. }
  2163. } else {
  2164. for (let i = 0; i < data.data.list.length; i++) {
  2165. let thisdata = data.data.list[i];
  2166. theArr.push({
  2167. key: i + 1,
  2168. orderNo: thisdata.orderNo,
  2169. contractNo: thisdata.contractNo,
  2170. userName: thisdata.userName,
  2171. buyerName: thisdata.buyerName,
  2172. departmentName: thisdata.departmentName,
  2173. salesmanName: thisdata.salesmanName,
  2174. depName: thisdata.depName,
  2175. orderStatus: thisdata.orderStatus,
  2176. projectStatus: thisdata.projectStatus,
  2177. totalAmount: thisdata.totalAmount,
  2178. liquidationStatus: thisdata.liquidationStatus,
  2179. settlementAmount: thisdata.settlementAmount,
  2180. accountsReceivable: thisdata.accountsReceivable,
  2181. dunSubject: thisdata.dunSubject,
  2182. startDate: thisdata.startDate,
  2183. taskStatus: thisdata.taskStatus,
  2184. cname: thisdata.cname,
  2185. id: thisdata.id,
  2186. taskName: thisdata.taskName,
  2187. hours: thisdata.hours,
  2188. taskDistributionTime: thisdata.taskDistributionTime,
  2189. taskEndTime: thisdata.taskEndTime,
  2190. dunStatus: thisdata.dunStatus == 0 ? "未触发" : "已触发",
  2191. });
  2192. }
  2193. }
  2194. this.setState({
  2195. cuiDataList: theArr,
  2196. });
  2197. }.bind(this),
  2198. }).always(
  2199. function () {
  2200. this.setState({
  2201. loading: false,
  2202. });
  2203. }.bind(this)
  2204. );
  2205. },
  2206. cuiTabChange(index) {
  2207. this.setState({
  2208. cuiTabKey: index,
  2209. });
  2210. if (index == 2) {
  2211. this.setState({
  2212. loading: true,
  2213. });
  2214. $.ajax({
  2215. method: "get",
  2216. dataType: "json",
  2217. crossDomain: false,
  2218. url: globalConfig.context + "/api/admin/newOrder/arrearsDunList",
  2219. data: {
  2220. orderNo: this.state.selectedRowKeys[0],
  2221. pageSize: 9999999,
  2222. },
  2223. success: function (data) {
  2224. let theArr = [];
  2225. if (data.error.length || data.data.list == "") {
  2226. if (data.error && data.error.length) {
  2227. message.warning(data.error[0].message);
  2228. }
  2229. } else {
  2230. for (let i = 0; i < data.data.list.length; i++) {
  2231. let thisdata = data.data.list[i];
  2232. let obj = thisdata;
  2233. obj.key = i;
  2234. theArr.push(obj);
  2235. }
  2236. }
  2237. this.setState({
  2238. qianDataList: theArr,
  2239. });
  2240. }.bind(this),
  2241. }).always(
  2242. function () {
  2243. this.setState({
  2244. loading: false,
  2245. });
  2246. }.bind(this)
  2247. );
  2248. }
  2249. },
  2250. proData() {
  2251. this.setState({
  2252. loading: true,
  2253. });
  2254. $.ajax({
  2255. method: "get",
  2256. dataType: "json",
  2257. crossDomain: false,
  2258. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  2259. data: {
  2260. orderNo: this.state.selectedRowKeys[0],
  2261. pageSize: 9999999,
  2262. },
  2263. success: function (data) {
  2264. let theArr = [];
  2265. let totalWaibao = 0;
  2266. if (!data.data) {
  2267. if (data.error && data.error.length) {
  2268. message.warning(data.error[0].message);
  2269. }
  2270. } else {
  2271. for (let i = 0; i < data.data.length; i++) {
  2272. let thisdata = data.data[i];
  2273. totalWaibao += thisdata.outsourcePrice;
  2274. thisdata.key = i + 1;
  2275. theArr.push(thisdata);
  2276. }
  2277. }
  2278. totalWaibao = (Math.round(totalWaibao * 1000000) / 1000000).toFixed(6);
  2279. this.setState({
  2280. proDataList: theArr,
  2281. totalWaibao,
  2282. });
  2283. }.bind(this),
  2284. }).always(
  2285. function () {
  2286. this.setState({
  2287. loading: false,
  2288. });
  2289. }.bind(this)
  2290. );
  2291. },
  2292. // 查看公出列表
  2293. pubData() {
  2294. this.setState({
  2295. loading: true,
  2296. });
  2297. let rows = this.state.selectedRows[0]
  2298. let searchInfor = {
  2299. releaseStart: this.state.releaseDate[0] || undefined,
  2300. releaseEnd: this.state.releaseDate[1] || undefined,
  2301. aid: this.state.theTypes || undefined,
  2302. sid: this.state.theTypes1 || undefined,
  2303. status: this.state.status,
  2304. clockIn: this.state.clockIn,
  2305. depId: this.state.depId || undefined,
  2306. publicType: this.state.type,
  2307. }
  2308. let datas = Object.assign(searchInfor, {
  2309. pageNo: this.state.pubpageNo || 1,
  2310. pageSize: 9999999,
  2311. uid: rows.buyerId,
  2312. });
  2313. $.ajax({
  2314. method: "get",
  2315. dataType: "json",
  2316. crossDomain: false,
  2317. url: globalConfig.context + "/api/admin/release/publicReleaseDtails",
  2318. data: datas,
  2319. success: function (data) {
  2320. let theArr = [];
  2321. this.setState({
  2322. loading: false,
  2323. });
  2324. if (!data.data) {
  2325. if (data.error && data.error.length) {
  2326. message.warning(data.error[0].message);
  2327. }
  2328. } else {
  2329. for (let i = 0; i < data.data.list.length; i++) {
  2330. let thisdata = data.data.list[i];
  2331. thisdata.key = (data.data.pageNo - 1) * data.data.pageSize + i + 1;
  2332. theArr.push(thisdata);
  2333. }
  2334. this.state.pubpagination.current = data.data.pageNo;
  2335. this.state.pubpagination.total = data.data.totalCount;
  2336. if (data.data && data.data.list && !data.data.list.length) {
  2337. this.state.pubpagination.current = 0;
  2338. this.state.pubpagination.total = 0;
  2339. }
  2340. }
  2341. this.setState({
  2342. pubDataList: theArr,
  2343. pubpagination: this.state.pubpagination,
  2344. pubpageNo: data.data.pageNo,
  2345. });
  2346. }.bind(this),
  2347. }).always(
  2348. function () {
  2349. this.setState({
  2350. loading: false,
  2351. });
  2352. }.bind(this)
  2353. );
  2354. },
  2355. // 重置公出列表查询
  2356. resetAll() {
  2357. this.setState(
  2358. {
  2359. releaseDate: [],
  2360. theCustomerTypes: undefined,
  2361. status: undefined,
  2362. clockIn: undefined,
  2363. depId: undefined,
  2364. auto: "",
  2365. auto1: "",
  2366. customer: "",
  2367. theTypes: undefined,
  2368. theTypes1: undefined,
  2369. type: undefined,
  2370. },
  2371. () => {
  2372. this.pubData();
  2373. }
  2374. );
  2375. },
  2376. //公出导出
  2377. pubexportExec() {
  2378. this.setState({
  2379. exportPendingLoading: true,
  2380. });
  2381. message.config({
  2382. duration: 20,
  2383. });
  2384. let loading = message.loading("下载中...");
  2385. let rows = this.state.selectedRows[0]
  2386. let searchInfor = {
  2387. releaseStart: this.state.releaseDate[0] || undefined,
  2388. releaseEnd: this.state.releaseDate[1] || undefined,
  2389. aid: this.state.theTypes || undefined,
  2390. sid: this.state.theTypes1 || undefined,
  2391. status: this.state.status,
  2392. clockIn: this.state.clockIn,
  2393. depId: this.state.depId || undefined,
  2394. publicType: this.state.type,
  2395. }
  2396. let data = Object.assign(searchInfor, {
  2397. pageNo: this.state.pubpageNo || 1,
  2398. pageSize: 9999999,
  2399. uid: rows.buyerId,
  2400. exportType: 1,
  2401. });
  2402. for (let i of Object.keys(data)) {
  2403. if (i === "status" || i === "clockIn") {
  2404. if (isNaN(parseInt(data[i]))) {
  2405. delete data[i];
  2406. }
  2407. } else if (!data[i]) {
  2408. delete data[i];
  2409. }
  2410. }
  2411. $.ajax({
  2412. method: "get",
  2413. dataType: "json",
  2414. crossDomain: false,
  2415. url: globalConfig.context + "/api/admin/release/publicReleaseDtails/export",
  2416. data,
  2417. success: function (data) {
  2418. if (data.error.length === 0) {
  2419. this.download(data.data);
  2420. } else {
  2421. message.warning(data.error[0].message);
  2422. }
  2423. }.bind(this),
  2424. }).always(
  2425. function () {
  2426. loading();
  2427. this.setState({
  2428. exportPendingLoading: false,
  2429. });
  2430. }.bind(this)
  2431. );
  2432. },
  2433. // 下载
  2434. download(fileName) {
  2435. window.location.href =
  2436. globalConfig.context + "/open/download?fileName=" + fileName;
  2437. },
  2438. checkRemark(record) {
  2439. this.setState({
  2440. checkVisible: true,
  2441. checkOrderNo: record.orderNo,
  2442. });
  2443. },
  2444. checkOk() {
  2445. if (this.state.checkData == "" || this.state.checkData == undefined) {
  2446. message.warning("请填写审核内容");
  2447. return;
  2448. }
  2449. this.setState({
  2450. loading: true,
  2451. });
  2452. let ajaxObj = $.ajax({
  2453. method: "post",
  2454. dataType: "json",
  2455. crossDomain: false,
  2456. url: globalConfig.context + "/api/admin/financial/financeApproval",
  2457. data: {
  2458. orderNo: this.state.checkOrderNo,
  2459. remarks: this.state.checkData,
  2460. },
  2461. success: function (data) {
  2462. let theArr = [];
  2463. if (!data.data) {
  2464. if (data.error && data.error.length) {
  2465. message.warning(data.error[0].message);
  2466. }
  2467. } else {
  2468. message.success("通过成功!");
  2469. this.loadData();
  2470. this.setState({
  2471. checkVisible: false,
  2472. checkData: "",
  2473. });
  2474. }
  2475. }.bind(this),
  2476. }).always(
  2477. function () {
  2478. this.setState({
  2479. loading: false,
  2480. financeApprovalAjaxObj: null
  2481. });
  2482. }.bind(this)
  2483. );
  2484. this.setState({
  2485. financeApprovalAjaxObj: ajaxObj
  2486. })
  2487. },
  2488. tableRowClickPro(record) {
  2489. this.setState({
  2490. pvisible: true,
  2491. record,
  2492. });
  2493. },
  2494. kaiPiaoData(record) {
  2495. this.setState({
  2496. avisible: true,
  2497. });
  2498. this.invoiceData(record.id)
  2499. },
  2500. invoiceData(id) {
  2501. this.setState({
  2502. loading: true,
  2503. });
  2504. $.ajax({
  2505. method: "get",
  2506. dataType: "json",
  2507. crossDomain: false,
  2508. url:
  2509. globalConfig.context + "/api/admin/orderInvoice/selectByIdOrderInvoice",
  2510. data: {
  2511. id,
  2512. },
  2513. success: function (data) {
  2514. let thisdata = data.data;
  2515. let obj = {
  2516. contractNo: thisdata.contractNo,
  2517. orderNo: thisdata.orderNo,
  2518. approval: thisdata.approval,
  2519. type: thisdata.type,
  2520. status: thisdata.status,
  2521. remarks: thisdata.remarks,
  2522. invoiceType: thisdata.invoiceType,
  2523. unitName: thisdata.unitName,
  2524. taxNumber: thisdata.taxNumber,
  2525. amount: thisdata.amount,
  2526. banks: thisdata.banks,
  2527. content: thisdata.content,
  2528. unitAddress: thisdata.unitAddress,
  2529. invoiceRemarks: thisdata.invoiceRemarks,
  2530. unitMobile: thisdata.unitMobile,
  2531. post: thisdata.post,
  2532. addressee: thisdata.addressee,
  2533. addresseeMobile: thisdata.addresseeMobile,
  2534. addresseeProvince: thisdata.addresseeProvince,
  2535. addresseeCity: thisdata.addresseeCity,
  2536. addresseeArea: thisdata.addresseeArea,
  2537. alreadyAmount: thisdata.alreadyAmount,
  2538. recipientAddress: thisdata.recipientAddress,
  2539. orgCodeUrl: thisdata.voucherUrl
  2540. ? splitUrl(
  2541. thisdata.voucherUrl,
  2542. ",",
  2543. globalConfig.avatarHost + "/upload"
  2544. )
  2545. : [],
  2546. };
  2547. this.setState({
  2548. modalData: obj,
  2549. });
  2550. }.bind(this),
  2551. }).done(
  2552. function () {
  2553. this.setState({
  2554. loading: false,
  2555. });
  2556. }.bind(this)
  2557. );
  2558. },
  2559. visitCancels() {
  2560. this.setState({
  2561. avisible: false
  2562. })
  2563. },
  2564. selectAuto(value, options) {
  2565. this.setState({
  2566. auto: value,
  2567. });
  2568. },
  2569. selectAuto1(value, options) {
  2570. this.setState({
  2571. auto1: value,
  2572. });
  2573. },
  2574. blurChange(e) {
  2575. let theType = "";
  2576. let contactLists = this.state.customerArr || [];
  2577. if (e) {
  2578. contactLists.map(function (item) {
  2579. if (item.name == e.toString()) {
  2580. theType = item.id;
  2581. }
  2582. });
  2583. }
  2584. this.setState({
  2585. theTypes: theType,
  2586. });
  2587. },
  2588. blurChange1(e) {
  2589. let theType = "";
  2590. let contactLists = this.state.customerArr1 || [];
  2591. if (e) {
  2592. contactLists.map(function (item) {
  2593. if (item.name == e.toString()) {
  2594. theType = item.id;
  2595. }
  2596. });
  2597. }
  2598. this.setState({
  2599. theTypes1: theType,
  2600. });
  2601. },
  2602. httpChange(e) {
  2603. if (e.length >= 1) {
  2604. this.supervisor(e);
  2605. }
  2606. this.setState({
  2607. auto: e,
  2608. });
  2609. },
  2610. httpChange1(e) {
  2611. if (e.length >= 1) {
  2612. this.supervisor1(e);
  2613. }
  2614. this.setState({
  2615. auto1: e,
  2616. });
  2617. },
  2618. supervisor(e) {
  2619. $.ajax({
  2620. method: "get",
  2621. dataType: "json",
  2622. crossDomain: false,
  2623. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  2624. data: {
  2625. adminName: e,
  2626. },
  2627. success: function (data) {
  2628. if (data.error && data.error.length === 0) {
  2629. this.setState({
  2630. customerArr: data.data,
  2631. });
  2632. } else {
  2633. message.warning(data.error[0].message);
  2634. }
  2635. }.bind(this),
  2636. }).always(function () { }.bind(this));
  2637. },
  2638. supervisor1(e) {
  2639. $.ajax({
  2640. method: "get",
  2641. dataType: "json",
  2642. crossDomain: false,
  2643. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  2644. data: {
  2645. adminName: e,
  2646. },
  2647. success: function (data) {
  2648. if (data.error && data.error.length === 0) {
  2649. this.setState({
  2650. customerArr1: data.data,
  2651. });
  2652. } else {
  2653. message.warning(data.error[0].message);
  2654. }
  2655. }.bind(this),
  2656. }).always(function () { }.bind(this));
  2657. },
  2658. render() {
  2659. const formItemLayout = {
  2660. labelCol: { span: 8 },
  2661. wrapperCol: { span: 14 },
  2662. };
  2663. const { RangePicker } = DatePicker;
  2664. var departmentArr = this.state.departmentArr || [];
  2665. const { loading, selectedRowKeys, visible } = this.state;
  2666. const rowSelection = {
  2667. selectedRowKeys,
  2668. onChange: this.onSelectChange,
  2669. hideDefaultSelections: true,
  2670. type: "radio",
  2671. };
  2672. const dataSources = this.state.customerArr || [];
  2673. const dataSources1 = this.state.customerArr1 || [];
  2674. const options = dataSources.map((group) => (
  2675. <Select.Option key={group.id} value={group.name}>
  2676. {group.name}
  2677. </Select.Option>
  2678. ));
  2679. const options1 = dataSources1.map((group) => (
  2680. <Select.Option key={group.id} value={group.name}>
  2681. {group.name}
  2682. </Select.Option>
  2683. ));
  2684. return (
  2685. <div className="user-content">
  2686. {this.state.resVisible ? (
  2687. <ResolutionDetail
  2688. cancel={this.resCancel}
  2689. detail={this.state.resRecord}
  2690. visible={this.state.resVisible}
  2691. id={this.state.resRecord.orderNo}
  2692. />
  2693. ) : (
  2694. ""
  2695. )}
  2696. <div className="content-title" style={{ marginBottom: 10 }}>
  2697. <span style={{ fontWeight: 900, fontSize: 16 }}>收款结算</span>
  2698. </div>
  2699. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  2700. <TabPane tab="更改表格显示数据" key="1">
  2701. <div style={{ marginLeft: 10 }}>
  2702. <ChooseList
  2703. columns={this.state.columns}
  2704. changeFn={this.changeList}
  2705. changeList={this.state.changeList}
  2706. top={55}
  2707. margin={11}
  2708. />
  2709. </div>
  2710. </TabPane>
  2711. <TabPane tab="搜索" key="2">
  2712. <div className="user-search" style={{ padding: "0 20px 0 10px" }}>
  2713. <Input
  2714. style={{ width: 200 }}
  2715. placeholder="订单编号"
  2716. value={this.state.orderNoSearch}
  2717. onChange={(e) => {
  2718. this.setState({ orderNoSearch: e.target.value });
  2719. }}
  2720. />
  2721. <Input
  2722. style={{ width: 200 }}
  2723. placeholder="客户名称"
  2724. value={this.state.nameSearch}
  2725. onChange={(e) => {
  2726. this.setState({ nameSearch: e.target.value });
  2727. }}
  2728. />
  2729. <Cascaders
  2730. ref={node => this.Cascaders = node}
  2731. placeholder="订单部门"
  2732. id="id"
  2733. name="name"
  2734. children="list"
  2735. height={28}
  2736. onSel={(e) => {
  2737. this.setState({
  2738. departmenttList: JSON.stringify(e),
  2739. });
  2740. }}
  2741. />
  2742. {/* <Select
  2743. placeholder="订单部门"
  2744. style={{ width: 190, marginRight: 10 }}
  2745. value={this.state.departmenttList}
  2746. onChange={(e) => {
  2747. this.setState({ departmenttList: e });
  2748. }}
  2749. >
  2750. {departmentArr.map(function (item) {
  2751. return (
  2752. <Select.Option key={item.id}>{item.name}</Select.Option>
  2753. );
  2754. })}
  2755. </Select> */}
  2756. <Input
  2757. style={{ width: 200 }}
  2758. placeholder="合同编号"
  2759. value={this.state.contractNoSearch}
  2760. onChange={(e) => {
  2761. this.setState({
  2762. contractNoSearch: e.target.value,
  2763. });
  2764. }}
  2765. />
  2766. <Select
  2767. placeholder="流程状态"
  2768. onChange={(e) => {
  2769. this.setState({ processStatusSearch: e });
  2770. }}
  2771. style={{ width: 150, marginRight: 10 }}
  2772. value={this.state.processStatusSearch}
  2773. >
  2774. <Option value="3">未分配</Option>
  2775. <Option value="4">已分配</Option>
  2776. <Option value="9">已驳回</Option>
  2777. </Select>
  2778. <Select
  2779. placeholder="结算状态"
  2780. onChange={(e) => {
  2781. this.setState({ liquidationStatus: e });
  2782. }}
  2783. style={{ width: 150, marginRight: 10 }}
  2784. value={this.state.liquidationStatus}
  2785. >
  2786. <Option value="0">首付待付清</Option>
  2787. <Option value="1">尾款待付清</Option>
  2788. <Option value="2">已付清</Option>
  2789. </Select>
  2790. <Select
  2791. style={{ width: 150 }}
  2792. placeholder="签单金额"
  2793. value={this.state.amountStatus}
  2794. onChange={(e) => {
  2795. this.setState({
  2796. amountStatus: e,
  2797. });
  2798. }}
  2799. >
  2800. <Option value="0">10万元以下</Option>
  2801. <Option value="1">10~20万元</Option>
  2802. <Option value="2">20~30万元</Option>
  2803. <Option value="3">30~40万元</Option>
  2804. <Option value="4">40万元以上</Option>
  2805. </Select>
  2806. <Select
  2807. style={{ width: 150 }}
  2808. placeholder="特批状态"
  2809. value={this.state.approval}
  2810. onChange={(e) => {
  2811. this.setState({
  2812. approval: e,
  2813. });
  2814. }}
  2815. >
  2816. <Option value="0">非特批</Option>
  2817. <Option value="1">特批待审</Option>
  2818. <Option value="2">特批通过</Option>
  2819. <Option value="4">全部特批</Option>
  2820. </Select>
  2821. <Select
  2822. style={{ width: 150 }}
  2823. placeholder="会员状态"
  2824. value={this.state.projectType}
  2825. onChange={(e) => {
  2826. this.setState({
  2827. projectType: e,
  2828. });
  2829. }}
  2830. >
  2831. <Option value="1">会员</Option>
  2832. <Option value="0">非会员</Option>
  2833. </Select>
  2834. <span style={{}}>下单日期:</span>
  2835. <RangePicker
  2836. value={[
  2837. this.state.releaseDate[0]
  2838. ? moment(this.state.releaseDate[0])
  2839. : null,
  2840. this.state.releaseDate[1]
  2841. ? moment(this.state.releaseDate[1])
  2842. : null,
  2843. ]}
  2844. onChange={(data, dataString) => {
  2845. this.setState({ releaseDate: dataString });
  2846. }}
  2847. />
  2848. <span style={{ marginLeft: 10 }}>最近收款:</span>
  2849. <RangePicker
  2850. value={[
  2851. this.state.shouKuanDate[0]
  2852. ? moment(this.state.shouKuanDate[0])
  2853. : null,
  2854. this.state.shouKuanDate[1]
  2855. ? moment(this.state.shouKuanDate[1])
  2856. : null,
  2857. ]}
  2858. onChange={(data, dataString) => {
  2859. this.setState({ shouKuanDate: dataString });
  2860. }}
  2861. />
  2862. <Button
  2863. type="primary"
  2864. onClick={this.search}
  2865. style={{ marginLeft: 10 }}
  2866. disabled={this.state.loadingA ? true : false}
  2867. >
  2868. 搜索
  2869. </Button>
  2870. <Button onClick={this.reset}>重置</Button>
  2871. </div>
  2872. </TabPane>
  2873. <TabPane tab="打印" key="3">
  2874. <Button
  2875. type="primary"
  2876. style={{ margin: "11px 0px 10px 10px" }}
  2877. onClick={this.printAll}
  2878. disabled={!this.state.dataSource.length}
  2879. >
  2880. 打印所有列表信息
  2881. </Button>
  2882. <Button
  2883. type="primary"
  2884. disabled={this.state.selectedRowKeys.length != 1}
  2885. style={{ margin: "11px 0px 10px 10px" }}
  2886. onClick={() => {
  2887. this.inRecordData();
  2888. this.setState({
  2889. bvisible: true,
  2890. });
  2891. }}
  2892. >
  2893. 打印开票详情
  2894. </Button>
  2895. <Button
  2896. type="primary"
  2897. disabled={this.state.selectedRowKeys.length != 1}
  2898. style={{ margin: "11px 0px 10px 10px" }}
  2899. onClick={() => {
  2900. this.waterData();
  2901. this.setState({
  2902. cvisible: true,
  2903. });
  2904. }}
  2905. >
  2906. 打印收款流水
  2907. </Button>
  2908. <Button
  2909. type="primary"
  2910. disabled={this.state.selectedRowKeys.length != 1}
  2911. style={{ margin: "11px 0px 10px 10px" }}
  2912. onClick={() => {
  2913. this.timeData();
  2914. this.setState({
  2915. timeVisible: true,
  2916. });
  2917. }}
  2918. >
  2919. 打印工时信息
  2920. </Button>
  2921. <Button
  2922. type="primary"
  2923. disabled={this.state.selectedRowKeys.length != 1}
  2924. style={{ margin: "11px 0px 10px 10px" }}
  2925. onClick={() => {
  2926. this.cuiData();
  2927. this.setState({
  2928. cuiVisible: true,
  2929. });
  2930. }}
  2931. >
  2932. 打印催款信息
  2933. </Button>
  2934. <Button
  2935. type="primary"
  2936. disabled={this.state.selectedRowKeys.length != 1}
  2937. style={{ margin: "11px 0px 10px 10px" }}
  2938. onClick={() => {
  2939. this.proData();
  2940. this.setState({
  2941. proVisible: true,
  2942. });
  2943. }}
  2944. >
  2945. 打印项目进度
  2946. </Button>
  2947. </TabPane>
  2948. <TabPane tab="导出Excel" key="4">
  2949. <Button
  2950. type="primary"
  2951. style={{ margin: "11px 0px 10px 10px" }}
  2952. onClick={this.exportAll}
  2953. >
  2954. 导出当前列表
  2955. </Button>
  2956. <Button
  2957. type="primary"
  2958. disabled={this.state.selectedRowKeys.length != 1}
  2959. style={{ margin: "11px 0px 10px 10px" }}
  2960. onClick={this.exportKaip}
  2961. >
  2962. 导出所选开票详情
  2963. </Button>
  2964. <Button
  2965. type="primary"
  2966. disabled={this.state.selectedRowKeys.length != 1}
  2967. style={{ margin: "11px 0px 10px 10px" }}
  2968. onClick={this.exportWater}
  2969. >
  2970. 导出所选收款详情流水
  2971. </Button>
  2972. <Button
  2973. type="primary"
  2974. disabled={this.state.selectedRowKeys.length != 1}
  2975. style={{ margin: "11px 0px 10px 10px" }}
  2976. onClick={this.exportTime}
  2977. >
  2978. 导出所选工时信息
  2979. </Button>
  2980. <Button
  2981. type="primary"
  2982. disabled={this.state.selectedRowKeys.length != 1}
  2983. style={{ margin: "11px 0px 10px 10px" }}
  2984. onClick={this.exportCui}
  2985. >
  2986. 导出催款信息
  2987. </Button>
  2988. <Button
  2989. type="primary"
  2990. disabled={this.state.selectedRowKeys.length != 1}
  2991. style={{ margin: "11px 0px 10px 10px" }}
  2992. onClick={this.exportPro}
  2993. >
  2994. 导出项目进度
  2995. </Button>
  2996. </TabPane>
  2997. <TabPane tab="查看" key="5">
  2998. <Button
  2999. type="primary"
  3000. disabled={this.state.selectedRowKeys.length != 1}
  3001. style={{ margin: "11px 0px 10px 10px" }}
  3002. onClick={() => {
  3003. this.inRecordData();
  3004. this.setState({
  3005. // bvisible: true,
  3006. newVisible: "开票历史记录",
  3007. });
  3008. }}
  3009. >
  3010. 查看开票详情
  3011. </Button>
  3012. <Button
  3013. type="primary"
  3014. disabled={this.state.selectedRowKeys.length != 1}
  3015. style={{ margin: "11px 0px 10px 10px" }}
  3016. onClick={() => {
  3017. this.waterData();
  3018. this.setState({
  3019. // cvisible: true,
  3020. newVisible: "详细收款流水",
  3021. });
  3022. }}
  3023. >
  3024. 详情收款流水
  3025. </Button>
  3026. <Button
  3027. type="primary"
  3028. disabled={this.state.selectedRowKeys.length != 1}
  3029. style={{ margin: "11px 0px 10px 10px" }}
  3030. onClick={() => {
  3031. this.timeData();
  3032. this.setState({
  3033. // timeVisible: true,
  3034. newVisible: "工时详情",
  3035. });
  3036. }}
  3037. >
  3038. 工时信息
  3039. </Button>
  3040. <Button
  3041. type="primary"
  3042. disabled={this.state.selectedRowKeys.length != 1}
  3043. style={{ margin: "11px 0px 10px 10px" }}
  3044. onClick={() => {
  3045. this.cuiData();
  3046. this.setState({
  3047. // cuiVisible: true,
  3048. newVisible: "催款详情",
  3049. });
  3050. }}
  3051. >
  3052. 催款信息
  3053. </Button>
  3054. <Button
  3055. type="primary"
  3056. disabled={this.state.selectedRowKeys.length != 1}
  3057. style={{ margin: "11px 0px 10px 10px" }}
  3058. onClick={() => {
  3059. this.proData();
  3060. this.setState({
  3061. // proVisible: true,
  3062. newVisible: "项目进度",
  3063. });
  3064. }}
  3065. >
  3066. 项目进度
  3067. </Button>
  3068. <Button
  3069. type="primary"
  3070. disabled={this.state.selectedRowKeys.length != 1}
  3071. style={{ margin: "11px 0px 10px 10px" }}
  3072. onClick={() => {
  3073. this.pubData();
  3074. this.selectSuperId();
  3075. this.setState({
  3076. // pubVisible: true,
  3077. newVisible: "公出详细列表",
  3078. });
  3079. }}
  3080. >
  3081. 查看公出
  3082. </Button>
  3083. </TabPane>
  3084. {/* <TabPane tab="批量操作" key="6">
  3085. <Button
  3086. type="primary"
  3087. disabled={this.state.selectedRowKeys.length == 0}
  3088. style={{ margin: "0px 0px 10px 10px" }}
  3089. onClick={e => {
  3090. e.stopPropagation(),
  3091. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  3092. }}
  3093. >
  3094. 转交
  3095. </Button>
  3096. </TabPane> */}
  3097. </Tabs>
  3098. <div className="patent-table">
  3099. <Spin spinning={this.state.loadingA}>
  3100. <Table
  3101. bordered
  3102. columns={
  3103. this.state.changeList == undefined
  3104. ? this.state.columns
  3105. : this.state.changeList
  3106. }
  3107. dataSource={this.state.dataSource}
  3108. rowSelection={rowSelection}
  3109. scroll={{ x: "max-content", y: 0 }}
  3110. pagination={this.state.pagination}
  3111. onRowDoubleClick={this.tableRowClick.bind(this)}
  3112. size="small"
  3113. />
  3114. </Spin>
  3115. <p
  3116. style={{ display: "inline-block", fontSize: "14px", color: "red" }}
  3117. >
  3118. {
  3119. <span style={{ marginRight: 10 }}>
  3120. {`收款金额总计(万元):${this.state.hui ? this.state.hui : "0"}`}
  3121. </span>
  3122. }
  3123. {
  3124. <span>
  3125. {`合同额总计(万元):${this.state.totalHui ? this.state.totalHui : "0"
  3126. }`}
  3127. </span>
  3128. }
  3129. </p>
  3130. </div>
  3131. <Assign
  3132. title="任务"
  3133. selApi={"/api/admin/newOrder/updateFinance"}
  3134. data={this.state.assignDataY}
  3135. showDesc={this.state.assignVisibleY}
  3136. closeDesc={this.closeAssignY.bind(this)}
  3137. // fenpaiData={8}
  3138. specially={0}
  3139. roleName={this.state.nub}
  3140. requestMethod={"get"}
  3141. />
  3142. <OrderDesc
  3143. data={this.state.RowData}
  3144. showDesc={this.state.showDesc}
  3145. closeDesc={this.closeDesc.bind(this)}
  3146. />
  3147. <Receivable
  3148. title="收款记录"
  3149. api="/api/admin/financial/addReceiptsFlow"
  3150. data={this.state.assignDataX}
  3151. showDesc={this.state.assignVisibleX}
  3152. closeDesc={this.closeAssignX.bind(this)}
  3153. />
  3154. <Modal
  3155. visible={this.state.boHuiVisible}
  3156. width="400px"
  3157. title="驳回备注"
  3158. footer=""
  3159. onOk={this.boHuiOk}
  3160. onCancel={this.boHuiCancel}
  3161. >
  3162. <Form layout="horizontal" onSubmit={this.boHuiSubmit}>
  3163. <Spin spinning={this.state.loading}>
  3164. <FormItem
  3165. labelCol={{ span: 5 }}
  3166. wrapperCol={{ span: 16 }}
  3167. label={
  3168. <span>
  3169. <strong style={{ color: "#f00" }}>*</strong>驳回原因
  3170. </span>
  3171. }
  3172. >
  3173. <Input
  3174. type="textarea"
  3175. rows={4}
  3176. placeholder="请输入驳回原因"
  3177. value={this.state.content}
  3178. onChange={(e) => {
  3179. this.setState({ content: e.target.value });
  3180. }}
  3181. />
  3182. </FormItem>
  3183. <FormItem wrapperCol={{ span: 12, offset: 5 }}>
  3184. <Button
  3185. type="primary"
  3186. htmlType="submit"
  3187. style={{ marginRight: 20 }}
  3188. >
  3189. 驳回
  3190. </Button>
  3191. <Button
  3192. type="default"
  3193. onClick={() => {
  3194. this.boHuiCancel();
  3195. }}
  3196. >
  3197. 取消
  3198. </Button>
  3199. </FormItem>
  3200. </Spin>
  3201. </Form>
  3202. </Modal>
  3203. <Modal
  3204. visible={this.state.bvisible}
  3205. footer=""
  3206. title="开票历史记录"
  3207. className="admin-desc-content"
  3208. width="1200px"
  3209. onCancel={this.inRecordCanl}
  3210. >
  3211. <Spin spinning={this.state.loading}>
  3212. <div
  3213. className="patent-table"
  3214. ref={(e) => {
  3215. this.refs.kaiPiao = e;
  3216. }}
  3217. >
  3218. <Table
  3219. columns={this.state.columnsDate}
  3220. dataSource={this.state.recordData}
  3221. onRowClick={this.kaiPiaoData}
  3222. pagination={false}
  3223. bordered
  3224. size="small"
  3225. />
  3226. <div className="clearfix" style={{ marginTop: "20px" }}>
  3227. <FormItem
  3228. className="half-item"
  3229. {...formItemLayout}
  3230. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  3231. >
  3232. <span>{this.state.sum + "(万元)"}</span>
  3233. </FormItem>
  3234. </div>
  3235. <ReactToPrint
  3236. trigger={() => (
  3237. <Button
  3238. type="primary"
  3239. style={{
  3240. float: "right",
  3241. // marginTop: 10,
  3242. position: "absolute",
  3243. top: -54,
  3244. right: 30,
  3245. }}
  3246. >
  3247. 打印
  3248. </Button>
  3249. )}
  3250. content={() => this.refs.kaiPiao}
  3251. />
  3252. </div>
  3253. </Spin>
  3254. </Modal>
  3255. <Modal
  3256. visible={this.state.cvisible}
  3257. footer=""
  3258. title="详细收款流水"
  3259. className="admin-desc-content"
  3260. width="1300px"
  3261. onCancel={this.waterCanl}
  3262. >
  3263. <Spin spinning={this.state.loading}>
  3264. <div
  3265. className="patent-table"
  3266. ref={(e) => {
  3267. this.refs.shouKuan = e;
  3268. }}
  3269. >
  3270. <Table
  3271. columns={this.state.waterlistDate}
  3272. dataSource={this.state.waterData}
  3273. pagination={false}
  3274. scroll={{ x: "max-content", y: 0 }}
  3275. bordered
  3276. size="small"
  3277. />
  3278. <div className="clearfix" style={{ marginTop: "20px" }}>
  3279. <FormItem
  3280. className="half-item"
  3281. {...formItemLayout}
  3282. label={<span style={{ fontSize: "14px" }}>总计金额</span>}
  3283. >
  3284. <span>{this.state.waterSum + "(万元)"}</span>
  3285. </FormItem>
  3286. </div>
  3287. <ReactToPrint
  3288. trigger={() => (
  3289. <Button
  3290. type="primary"
  3291. style={{
  3292. float: "right",
  3293. position: "absolute",
  3294. top: -54,
  3295. right: 30,
  3296. }}
  3297. >
  3298. 打印
  3299. </Button>
  3300. )}
  3301. content={() => this.refs.shouKuan}
  3302. />
  3303. </div>
  3304. </Spin>
  3305. </Modal>
  3306. <Modal
  3307. visible={this.state.dvisible}
  3308. footer=""
  3309. title="所有列表信息"
  3310. className="admin-desc-content"
  3311. width="1300px"
  3312. onCancel={() => {
  3313. this.loadData();
  3314. this.setState({
  3315. dvisible: false,
  3316. });
  3317. }}
  3318. >
  3319. <Spin spinning={this.state.loading}>
  3320. <div
  3321. className="patent-table"
  3322. style={{
  3323. // width: 900,
  3324. // position: "relative",
  3325. // left: "50%",
  3326. // transform: "translate(-50%)",
  3327. padding: "25px 0 30px 30px",
  3328. }}
  3329. ref={(e) => {
  3330. this.refs.all = e;
  3331. }}
  3332. >
  3333. <Table
  3334. columns={this.state.printColumns}
  3335. dataSource={this.state.dataSource}
  3336. pagination={false}
  3337. bordered
  3338. size="small"
  3339. />
  3340. </div>
  3341. </Spin>
  3342. <ReactToPrint
  3343. trigger={() => (
  3344. <Button
  3345. type="primary"
  3346. style={{
  3347. float: "right",
  3348. marginTop: 10,
  3349. position: "absolute",
  3350. top: 0,
  3351. right: 30,
  3352. }}
  3353. >
  3354. 打印
  3355. </Button>
  3356. )}
  3357. content={() => this.refs.all}
  3358. />
  3359. </Modal>
  3360. <Project
  3361. record={this.state.record}
  3362. visible={this.state.pvisible}
  3363. isAuditPayment={true}
  3364. cancel={() => {
  3365. this.setState({ pvisible: false });
  3366. }}
  3367. />
  3368. {/* 工时详情 */}
  3369. <Modal
  3370. visible={this.state.timeVisible}
  3371. footer=""
  3372. title="工时详情"
  3373. className="admin-desc-content"
  3374. width="1300px"
  3375. pagination={false}
  3376. onCancel={() => {
  3377. this.loadData();
  3378. this.setState({
  3379. timeVisible: false,
  3380. });
  3381. }}
  3382. >
  3383. <Spin spinning={this.state.loading}>
  3384. <div
  3385. className="patent-table"
  3386. style={
  3387. {
  3388. // width: 900,
  3389. // position: "relative",
  3390. // left: "50%",
  3391. // transform: "translate(-50%)",
  3392. // padding: "25px 0 30px 30px"
  3393. }
  3394. }
  3395. ref={(e) => {
  3396. this.refs.all = e;
  3397. }}
  3398. >
  3399. <Table
  3400. columns={this.state.timeColumns}
  3401. dataSource={this.state.timeDataList}
  3402. onRowClick={this.tableRowClickPro}
  3403. scroll={{ x: "max-content", y: 0 }}
  3404. pagination={false}
  3405. bordered
  3406. size="small"
  3407. />
  3408. </div>
  3409. </Spin>
  3410. <ReactToPrint
  3411. trigger={() => (
  3412. <Button
  3413. type="primary"
  3414. style={{
  3415. float: "right",
  3416. marginTop: 10,
  3417. position: "absolute",
  3418. top: 0,
  3419. right: 30,
  3420. }}
  3421. >
  3422. 打印
  3423. </Button>
  3424. )}
  3425. content={() => this.refs.all}
  3426. />
  3427. </Modal>
  3428. {/* 催款详情 */}
  3429. <Modal
  3430. visible={this.state.cuiVisible}
  3431. footer=""
  3432. title="催款详情"
  3433. className="admin-desc-content"
  3434. width="1300px"
  3435. pagination={false}
  3436. onCancel={() => {
  3437. this.loadData();
  3438. this.setState({
  3439. cuiVisible: false,
  3440. cuiTabKey: "1",
  3441. });
  3442. }}
  3443. >
  3444. <Tabs activeKey={this.state.cuiTabKey} onChange={this.cuiTabChange}>
  3445. <TabPane tab="催款节点" key="1">
  3446. <Spin spinning={this.state.loading}>
  3447. <div
  3448. className="patent-table"
  3449. ref={(e) => {
  3450. this.refs.all = e;
  3451. }}
  3452. >
  3453. <Table
  3454. columns={this.state.cuiColumns}
  3455. dataSource={this.state.cuiDataList}
  3456. scroll={{ x: "max-content", y: 0 }}
  3457. pagination={false}
  3458. bordered
  3459. size="small"
  3460. />
  3461. </div>
  3462. <ReactToPrint
  3463. trigger={() => (
  3464. <Button
  3465. type="primary"
  3466. style={{
  3467. float: "right",
  3468. marginTop: 10,
  3469. position: "absolute",
  3470. top: "-60px",
  3471. right: 30,
  3472. }}
  3473. >
  3474. 打印
  3475. </Button>
  3476. )}
  3477. content={() => this.refs.all}
  3478. />
  3479. </Spin>
  3480. </TabPane>
  3481. <TabPane tab="欠款催收记录" key="2">
  3482. <Spin spinning={this.state.loading}>
  3483. <div
  3484. className="patent-table"
  3485. ref={(e) => {
  3486. this.refs.all = e;
  3487. }}
  3488. >
  3489. <Table
  3490. columns={this.state.qianColumns}
  3491. dataSource={this.state.qianDataList}
  3492. scroll={{ x: "max-content", y: 0 }}
  3493. pagination={false}
  3494. bordered
  3495. size="small"
  3496. />
  3497. </div>
  3498. <ReactToPrint
  3499. trigger={() => (
  3500. <Button
  3501. type="primary"
  3502. style={{
  3503. float: "right",
  3504. marginTop: 10,
  3505. position: "absolute",
  3506. top: "-60px",
  3507. right: 30,
  3508. }}
  3509. >
  3510. 打印
  3511. </Button>
  3512. )}
  3513. content={() => this.refs.all}
  3514. />
  3515. </Spin>
  3516. </TabPane>
  3517. </Tabs>
  3518. </Modal>
  3519. {/* 项目进度 */}
  3520. <Modal
  3521. visible={this.state.proVisible}
  3522. footer=""
  3523. title="项目进度"
  3524. className="admin-desc-content"
  3525. width="1300px"
  3526. pagination={false}
  3527. onCancel={() => {
  3528. this.loadData(this.state.page);
  3529. this.setState({
  3530. proVisible: false,
  3531. });
  3532. }}
  3533. >
  3534. <Spin spinning={this.state.loading}>
  3535. <div
  3536. className="patent-table"
  3537. ref={(e) => {
  3538. this.refs.all = e;
  3539. }}
  3540. >
  3541. <Table
  3542. columns={this.state.proColumns}
  3543. dataSource={this.state.proDataList}
  3544. scroll={{ x: "max-content", y: 0 }}
  3545. onRowClick={this.tableRowClickPro}
  3546. pagination={false}
  3547. bordered
  3548. size="small"
  3549. />
  3550. </div>
  3551. <span style={{ display: "block", marginTop: 10, color: "red" }}>
  3552. 外包(内部)价格总计(万元):{this.state.totalWaibao}
  3553. </span>
  3554. </Spin>
  3555. <ReactToPrint
  3556. trigger={() => (
  3557. <Button
  3558. type="primary"
  3559. style={{
  3560. float: "right",
  3561. marginTop: 10,
  3562. position: "absolute",
  3563. top: 0,
  3564. right: 30,
  3565. }}
  3566. >
  3567. 打印
  3568. </Button>
  3569. )}
  3570. content={() => this.refs.all}
  3571. />
  3572. </Modal>
  3573. {/* 查看公出 */}
  3574. <Modal
  3575. visible={this.state.pubVisible}
  3576. footer=""
  3577. title={<span>公出详细列表(
  3578. {this.state.selectedRows.length > 0 && this.state.selectedRows[0].buyerName}
  3579. )</span>}
  3580. className="admin-desc-content"
  3581. width="1500px"
  3582. pagination={false}
  3583. onCancel={() => {
  3584. this.pubData();
  3585. this.setState({
  3586. pubVisible: false,
  3587. });
  3588. }}
  3589. >
  3590. <div
  3591. className="user-search"
  3592. style={{
  3593. marginTop: "10px",
  3594. marginLeft: "10px",
  3595. marginRight: "10px",
  3596. }}
  3597. >
  3598. <span style={{ marginRight: "10px" }}>
  3599. <Select
  3600. placeholder="请选择审核状态"
  3601. style={{ width: 120 }}
  3602. value={this.state.status}
  3603. onChange={(e) => {
  3604. this.setState({ status: e });
  3605. }}
  3606. >
  3607. {clockState.map((v, k) => (
  3608. <Select.Option key={k} value={v.id}>
  3609. {v.title}
  3610. </Select.Option>
  3611. ))}
  3612. </Select>
  3613. </span>
  3614. <span style={{ marginRight: "10px" }}>
  3615. <Select
  3616. placeholder="请选择打卡状态"
  3617. style={{ width: 120 }}
  3618. value={this.state.clockIn}
  3619. onChange={(e) => {
  3620. this.setState({ clockIn: e });
  3621. }}
  3622. >
  3623. <Select.Option value={1}>已打卡</Select.Option>
  3624. <Select.Option value={0}>未打卡</Select.Option>
  3625. </Select>
  3626. </span>
  3627. <span style={{ marginRight: "10px" }}>
  3628. <Select
  3629. placeholder="请选择公出类型"
  3630. style={{ width: 120 }}
  3631. value={this.state.type}
  3632. onChange={(e) => {
  3633. this.setState({ type: e });
  3634. }}
  3635. >
  3636. <Select.Option value={0}>业务打卡</Select.Option>
  3637. <Select.Option value={1}>技术打卡</Select.Option>
  3638. <Select.Option value={2}>行政打卡</Select.Option>
  3639. <Select.Option value={3}>技术协单</Select.Option>
  3640. </Select>
  3641. </span>
  3642. <span style={{ marginRight: "10px" }}>
  3643. <AutoComplete
  3644. className="certain-category-search"
  3645. dropdownClassName="certain-category-search-dropdown"
  3646. dropdownMatchSelectWidth={false}
  3647. style={{ width: "120px" }}
  3648. dataSource={options}
  3649. placeholder="输入公出申请人"
  3650. value={this.state.auto}
  3651. onChange={this.httpChange}
  3652. filterOption={true}
  3653. onBlur={this.blurChange}
  3654. onSelect={this.selectAuto}
  3655. >
  3656. <Input />
  3657. </AutoComplete>
  3658. </span>
  3659. <span style={{ marginRight: "10px" }}>
  3660. <AutoComplete
  3661. className="certain-category-search"
  3662. dropdownClassName="certain-category-search-dropdown"
  3663. dropdownMatchSelectWidth={false}
  3664. style={{ width: "120px" }}
  3665. dataSource={options1}
  3666. placeholder="输入跟单人"
  3667. value={this.state.auto1}
  3668. onChange={this.httpChange1}
  3669. filterOption={true}
  3670. onBlur={this.blurChange1}
  3671. onSelect={this.selectAuto1}
  3672. >
  3673. <Input />
  3674. </AutoComplete>
  3675. </span>
  3676. <span style={{ marginRight: "10px" }}>
  3677. <Select
  3678. placeholder="请选择公出部门"
  3679. style={{ width: 200 }}
  3680. value={this.state.depId}
  3681. onChange={(e) => {
  3682. this.setState({ depId: e });
  3683. }}
  3684. notFoundContent="未获取到上级组织列表"
  3685. >
  3686. {this.state.contactsOption}
  3687. </Select>
  3688. </span>
  3689. <span style={{ marginRight: "10px" }}>
  3690. <span style={{ marginRight: "5px", marginBottom: "10px" }}>
  3691. 公出时间 :
  3692. </span>
  3693. <RangePicker
  3694. style={{ marginRight: "10px", marginBottom: "10px" }}
  3695. value={[
  3696. this.state.releaseDate[0]
  3697. ? moment(this.state.releaseDate[0])
  3698. : null,
  3699. this.state.releaseDate[1]
  3700. ? moment(this.state.releaseDate[1])
  3701. : null,
  3702. ]}
  3703. onChange={(data, dataString) => {
  3704. this.setState({ releaseDate: dataString });
  3705. }}
  3706. />
  3707. </span>
  3708. <Button
  3709. type="primary"
  3710. onClick={() => {
  3711. this.pubData();
  3712. }}
  3713. style={{ marginRight: "10px", marginBottom: "10px" }}
  3714. >
  3715. 搜索
  3716. </Button>
  3717. <Button
  3718. onClick={this.resetAll}
  3719. style={{ marginRight: "10px", marginBottom: "10px" }}
  3720. >
  3721. 重置
  3722. </Button>
  3723. </div>
  3724. <Spin spinning={this.state.loading}>
  3725. <div
  3726. className="patent-table"
  3727. ref={(e) => {
  3728. this.refs.all = e;
  3729. }}
  3730. >
  3731. <Table
  3732. columns={this.state.pubColumns}
  3733. dataSource={this.state.pubDataList}
  3734. scroll={{ x: "max-content", y: 0 }}
  3735. pagination={false}
  3736. bordered
  3737. size="small"
  3738. />
  3739. </div>
  3740. </Spin>
  3741. <Button
  3742. type="primary"
  3743. style={{
  3744. float: "right",
  3745. marginTop: 10,
  3746. position: "absolute",
  3747. top: 0,
  3748. right: 120,
  3749. }}
  3750. loading={this.state.exportPendingLoading}
  3751. onClick={() => { this.pubexportExec() }}
  3752. >
  3753. 导出
  3754. </Button>
  3755. <ReactToPrint
  3756. trigger={() => (
  3757. <Button
  3758. type="primary"
  3759. style={{
  3760. float: "right",
  3761. marginTop: 10,
  3762. position: "absolute",
  3763. top: 0,
  3764. right: 30,
  3765. }}
  3766. >
  3767. 打印
  3768. </Button>
  3769. )}
  3770. content={() => this.refs.all}
  3771. />
  3772. </Modal>
  3773. <Spin spinning={this.state.loading}>
  3774. {this.state.checkVisible ? <Modal
  3775. title="审核订单"
  3776. visible={this.state.checkVisible}
  3777. onOk={this.checkOk}
  3778. confirmLoading={this.state.loading}
  3779. okText={"通过"}
  3780. onCancel={() => {
  3781. this.state.financeApprovalAjaxObj ? this.state.financeApprovalAjaxObj.abort() : null;
  3782. this.setState({
  3783. financeApprovalAjaxObj: null
  3784. })
  3785. this.loadData();
  3786. this.setState({
  3787. checkVisible: false,
  3788. checkData: "",
  3789. });
  3790. }}
  3791. >
  3792. <TextArea
  3793. value={this.state.checkData}
  3794. onChange={(e, recard) => {
  3795. this.setState({
  3796. checkData: e.target.value,
  3797. });
  3798. }}
  3799. placeholder="请填写审核内容"
  3800. />
  3801. </Modal> : <div />}
  3802. </Spin>
  3803. <KaiPiaoModal
  3804. visible={this.state.avisible}
  3805. data={this.state.modalData}
  3806. onCancel={this.visitCancels}
  3807. loading={this.state.loading}
  3808. />
  3809. {/* 合并查看 */}
  3810. {
  3811. this.state.newVisible != "" &&
  3812. <Modal
  3813. visible={this.state.newVisible != ""}
  3814. footer=""
  3815. title={this.state.newVisible}
  3816. className="admin-desc-content"
  3817. width="1500px"
  3818. pagination={false}
  3819. onCancel={() => {
  3820. this.setState({
  3821. newVisible: "",
  3822. });
  3823. }}
  3824. >
  3825. <Spin spinning={this.state.loading}>
  3826. <div style={{ margin: 20 }}>
  3827. <div style={{ marginBottom: 20 }}>
  3828. <Table
  3829. bordered
  3830. columns={this.state.columns}
  3831. dataSource={this.state.newData}
  3832. scroll={{ x: "max-content", y: 0 }}
  3833. pagination={false}
  3834. onRowDoubleClick={this.tableRowClick.bind(this)}
  3835. size="small"
  3836. />
  3837. </div>
  3838. <div>
  3839. <Button
  3840. type="primary"
  3841. style={{
  3842. margin: "11px 0px 10px 10px",
  3843. background: this.state.newVisible == "开票历史记录" ? "#f04134" : "",
  3844. }}
  3845. onClick={() => {
  3846. this.inRecordData();
  3847. this.setState({
  3848. newVisible: "开票历史记录"
  3849. });
  3850. }}
  3851. >
  3852. 查看开票详情
  3853. </Button>
  3854. <Button
  3855. type="primary"
  3856. style={{
  3857. margin: "11px 0px 10px 10px",
  3858. background: this.state.newVisible == "详细收款流水" ? "#f04134" : "",
  3859. }}
  3860. onClick={() => {
  3861. this.waterData();
  3862. this.setState({
  3863. newVisible: "详细收款流水",
  3864. });
  3865. }}
  3866. >
  3867. 详情收款流水
  3868. </Button>
  3869. <Button
  3870. type="primary"
  3871. style={{
  3872. margin: "11px 0px 10px 10px",
  3873. background: this.state.newVisible == "工时详情" ? "#f04134" : "",
  3874. }}
  3875. onClick={() => {
  3876. this.timeData();
  3877. this.setState({
  3878. newVisible: "工时详情",
  3879. });
  3880. }}
  3881. >
  3882. 工时信息
  3883. </Button>
  3884. <Button
  3885. type="primary"
  3886. style={{
  3887. margin: "11px 0px 10px 10px",
  3888. background: this.state.newVisible == "催款详情" ? "#f04134" : "",
  3889. }}
  3890. onClick={() => {
  3891. this.cuiData();
  3892. this.setState({
  3893. newVisible: "催款详情",
  3894. });
  3895. }}
  3896. >
  3897. 催款信息
  3898. </Button>
  3899. <Button
  3900. type="primary"
  3901. style={{
  3902. margin: "11px 0px 10px 10px",
  3903. background: this.state.newVisible == "项目进度" ? "#f04134" : "",
  3904. }}
  3905. onClick={() => {
  3906. this.proData();
  3907. this.setState({
  3908. newVisible: "项目进度",
  3909. });
  3910. }}
  3911. >
  3912. 项目进度
  3913. </Button>
  3914. <Button
  3915. type="primary"
  3916. style={{
  3917. margin: "11px 0px 10px 10px",
  3918. background: this.state.newVisible == "公出详细列表" ? "#f04134" : "",
  3919. }}
  3920. onClick={() => {
  3921. this.pubData();
  3922. this.selectSuperId();
  3923. this.setState({
  3924. newVisible: "公出详细列表",
  3925. });
  3926. }}
  3927. >
  3928. 查看公出
  3929. </Button>
  3930. </div>
  3931. {
  3932. this.state.newVisible == "公出详细列表" &&
  3933. <div
  3934. className="user-search"
  3935. style={{
  3936. marginTop: "10px",
  3937. marginLeft: "10px",
  3938. marginRight: "10px",
  3939. }}
  3940. >
  3941. <span style={{ marginRight: "10px" }}>
  3942. <Select
  3943. placeholder="请选择审核状态"
  3944. style={{ width: 120 }}
  3945. value={this.state.status}
  3946. onChange={(e) => {
  3947. this.setState({ status: e });
  3948. }}
  3949. >
  3950. {clockState.map((v, k) => (
  3951. <Select.Option key={k} value={v.id}>
  3952. {v.title}
  3953. </Select.Option>
  3954. ))}
  3955. </Select>
  3956. </span>
  3957. <span style={{ marginRight: "10px" }}>
  3958. <Select
  3959. placeholder="请选择打卡状态"
  3960. style={{ width: 120 }}
  3961. value={this.state.clockIn}
  3962. onChange={(e) => {
  3963. this.setState({ clockIn: e });
  3964. }}
  3965. >
  3966. <Select.Option value={1}>已打卡</Select.Option>
  3967. <Select.Option value={0}>未打卡</Select.Option>
  3968. </Select>
  3969. </span>
  3970. <span style={{ marginRight: "10px" }}>
  3971. <Select
  3972. placeholder="请选择公出类型"
  3973. style={{ width: 120 }}
  3974. value={this.state.type}
  3975. onChange={(e) => {
  3976. this.setState({ type: e });
  3977. }}
  3978. >
  3979. <Select.Option value={0}>业务打卡</Select.Option>
  3980. <Select.Option value={1}>技术打卡</Select.Option>
  3981. <Select.Option value={2}>行政打卡</Select.Option>
  3982. <Select.Option value={3}>技术协单</Select.Option>
  3983. </Select>
  3984. </span>
  3985. <span style={{ marginRight: "10px" }}>
  3986. <AutoComplete
  3987. className="certain-category-search"
  3988. dropdownClassName="certain-category-search-dropdown"
  3989. dropdownMatchSelectWidth={false}
  3990. style={{ width: "120px" }}
  3991. dataSource={options}
  3992. placeholder="输入公出申请人"
  3993. value={this.state.auto}
  3994. onChange={this.httpChange}
  3995. filterOption={true}
  3996. onBlur={this.blurChange}
  3997. onSelect={this.selectAuto}
  3998. >
  3999. <Input />
  4000. </AutoComplete>
  4001. </span>
  4002. <span style={{ marginRight: "10px" }}>
  4003. <AutoComplete
  4004. className="certain-category-search"
  4005. dropdownClassName="certain-category-search-dropdown"
  4006. dropdownMatchSelectWidth={false}
  4007. style={{ width: "120px" }}
  4008. dataSource={options1}
  4009. placeholder="输入跟单人"
  4010. value={this.state.auto1}
  4011. onChange={this.httpChange1}
  4012. filterOption={true}
  4013. onBlur={this.blurChange1}
  4014. onSelect={this.selectAuto1}
  4015. >
  4016. <Input />
  4017. </AutoComplete>
  4018. </span>
  4019. <span style={{ marginRight: "10px" }}>
  4020. <Select
  4021. placeholder="请选择公出部门"
  4022. style={{ width: 200 }}
  4023. value={this.state.depId}
  4024. onChange={(e) => {
  4025. this.setState({ depId: e });
  4026. }}
  4027. notFoundContent="未获取到上级组织列表"
  4028. >
  4029. {this.state.contactsOption}
  4030. </Select>
  4031. </span>
  4032. <span style={{ marginRight: "10px" }}>
  4033. <span style={{ marginRight: "5px", marginBottom: "10px" }}>
  4034. 公出时间 :
  4035. </span>
  4036. <RangePicker
  4037. style={{ marginRight: "10px", marginBottom: "10px" }}
  4038. value={[
  4039. this.state.releaseDate[0]
  4040. ? moment(this.state.releaseDate[0])
  4041. : null,
  4042. this.state.releaseDate[1]
  4043. ? moment(this.state.releaseDate[1])
  4044. : null,
  4045. ]}
  4046. onChange={(data, dataString) => {
  4047. this.setState({ releaseDate: dataString });
  4048. }}
  4049. />
  4050. </span>
  4051. <Button
  4052. type="primary"
  4053. onClick={() => {
  4054. this.pubData();
  4055. }}
  4056. style={{ marginRight: "10px", marginBottom: "10px" }}
  4057. >
  4058. 搜索
  4059. </Button>
  4060. <Button
  4061. onClick={this.resetAll}
  4062. style={{ marginRight: "10px", marginBottom: "10px" }}
  4063. >
  4064. 重置
  4065. </Button>
  4066. </div>
  4067. }
  4068. {
  4069. this.state.newVisible == "催款详情"
  4070. ? <Tabs activeKey={this.state.cuiTabKey} onChange={this.cuiTabChange}>
  4071. <TabPane tab="催款节点" key="1">
  4072. <Spin spinning={this.state.loading}>
  4073. <div
  4074. className="patent-table"
  4075. ref={(e) => {
  4076. this.refs.all = e;
  4077. }}
  4078. >
  4079. <Table
  4080. columns={this.state.cuiColumns}
  4081. dataSource={this.state.cuiDataList}
  4082. scroll={{ x: "max-content", y: 0 }}
  4083. pagination={false}
  4084. bordered
  4085. size="small"
  4086. />
  4087. </div>
  4088. <Button
  4089. type="primary"
  4090. style={{
  4091. float: "right",
  4092. marginTop: 10,
  4093. position: "absolute",
  4094. top: "-60px",
  4095. right: "100px",
  4096. }}
  4097. loading={this.state.exportPendingLoading}
  4098. onClick={() => { this.exportCui() }}
  4099. >
  4100. 导出
  4101. </Button>
  4102. <ReactToPrint
  4103. trigger={() => (
  4104. <Button
  4105. type="primary"
  4106. style={{
  4107. float: "right",
  4108. marginTop: 10,
  4109. position: "absolute",
  4110. top: "-60px",
  4111. right: "10px",
  4112. }}
  4113. >
  4114. 打印
  4115. </Button>
  4116. )}
  4117. content={() => this.refs.all}
  4118. />
  4119. </Spin>
  4120. </TabPane>
  4121. <TabPane tab="欠款催收记录" key="2">
  4122. <Spin spinning={this.state.loading}>
  4123. <div
  4124. className="patent-table"
  4125. ref={(e) => {
  4126. this.refs.all = e;
  4127. }}
  4128. >
  4129. <Table
  4130. columns={this.state.qianColumns}
  4131. dataSource={this.state.qianDataList}
  4132. scroll={{ x: "max-content", y: 0 }}
  4133. pagination={false}
  4134. bordered
  4135. size="small"
  4136. />
  4137. </div>
  4138. <ReactToPrint
  4139. trigger={() => (
  4140. <Button
  4141. type="primary"
  4142. style={{
  4143. float: "right",
  4144. marginTop: 10,
  4145. position: "absolute",
  4146. top: "-60px",
  4147. right: "10px",
  4148. }}
  4149. >
  4150. 打印
  4151. </Button>
  4152. )}
  4153. content={() => this.refs.all}
  4154. />
  4155. </Spin>
  4156. </TabPane>
  4157. </Tabs>
  4158. : <div
  4159. className="patent-table"
  4160. style={{ position: "relative" }}
  4161. ref={(e) => {
  4162. this.refs.all = e;
  4163. }}
  4164. >
  4165. <Table
  4166. bordered
  4167. columns={
  4168. this.state.newVisible == "开票历史记录"
  4169. ? this.state.columnsDate : this.state.newVisible == "详细收款流水"
  4170. ? this.state.waterlistDate : this.state.newVisible == "工时详情"
  4171. ? this.state.timeColumns : this.state.newVisible == "催款详情"
  4172. ? this.state.cuiColumns : this.state.newVisible == "项目进度"
  4173. ? this.state.proColumns : this.state.newVisible == "公出详细列表"
  4174. && this.state.pubColumns
  4175. }
  4176. dataSource={
  4177. this.state.newVisible == "开票历史记录"
  4178. ? this.state.recordData : this.state.newVisible == "详细收款流水"
  4179. ? this.state.waterData : this.state.newVisible == "工时详情"
  4180. ? this.state.timeDataList : this.state.newVisible == "催款详情"
  4181. ? this.state.cuiDataList : this.state.newVisible == "项目进度"
  4182. ? this.state.proDataList : this.state.newVisible == "公出详细列表"
  4183. && this.state.pubDataList
  4184. }
  4185. pagination={false}
  4186. scroll={{ x: "max-content", y: 0 }}
  4187. size="small"
  4188. />
  4189. {
  4190. this.state.newVisible == "开票历史记录" &&
  4191. <div className="clearfix" style={{ marginTop: "20px" }}>
  4192. <FormItem
  4193. className="half-item"
  4194. {...formItemLayout}
  4195. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  4196. >
  4197. <span>{this.state.sum + "(万元)"}</span>
  4198. </FormItem>
  4199. </div>
  4200. }
  4201. {
  4202. this.state.newVisible == "开票历史记录" &&
  4203. <Button
  4204. type="primary"
  4205. style={{
  4206. float: "right",
  4207. position: "absolute",
  4208. top: "-40px",
  4209. right: "100px",
  4210. }}
  4211. loading={this.state.exportPendingLoading}
  4212. onClick={() => { this.exportKaip() }}
  4213. >
  4214. 导出
  4215. </Button>
  4216. }
  4217. {
  4218. this.state.newVisible == "开票历史记录" &&
  4219. <ReactToPrint
  4220. trigger={() => (
  4221. <Button type="primary"
  4222. style={{
  4223. float: "right",
  4224. position: "absolute",
  4225. top: "-40px",
  4226. right: "10px",
  4227. }}
  4228. >打印</Button>
  4229. )}
  4230. content={() => this.refs.kaiPiao}
  4231. />
  4232. }
  4233. {
  4234. this.state.newVisible == "详细收款流水" &&
  4235. <div className="clearfix" style={{ marginTop: "20px" }}>
  4236. <FormItem
  4237. className="half-item"
  4238. {...formItemLayout}
  4239. label={<span style={{ fontSize: "14px" }}>总计金额</span>}
  4240. >
  4241. <span>{this.state.waterSum + "(万元)"}</span>
  4242. </FormItem>
  4243. </div>
  4244. }
  4245. {
  4246. this.state.newVisible == "详细收款流水" &&
  4247. <Button
  4248. type="primary"
  4249. style={{
  4250. float: "right",
  4251. position: "absolute",
  4252. top: "-40px",
  4253. right: "100px",
  4254. }}
  4255. loading={this.state.exportPendingLoading}
  4256. onClick={() => { this.exportWater() }}
  4257. >
  4258. 导出
  4259. </Button>
  4260. }
  4261. {
  4262. this.state.newVisible == "详细收款流水" &&
  4263. <ReactToPrint
  4264. trigger={() => (
  4265. <Button
  4266. type="primary"
  4267. style={{
  4268. float: "right",
  4269. position: "absolute",
  4270. top: "-40px",
  4271. right: "10px",
  4272. }}
  4273. >
  4274. 打印
  4275. </Button>
  4276. )}
  4277. content={() => this.refs.shouKuan}
  4278. />
  4279. }
  4280. {
  4281. this.state.newVisible == "工时详情" &&
  4282. <Button
  4283. type="primary"
  4284. style={{
  4285. float: "right",
  4286. position: "absolute",
  4287. top: "-40px",
  4288. right: "100px",
  4289. }}
  4290. loading={this.state.exportPendingLoading}
  4291. onClick={() => { this.exportTime() }}
  4292. >
  4293. 导出
  4294. </Button>
  4295. }
  4296. {
  4297. this.state.newVisible == "工时详情" &&
  4298. <ReactToPrint
  4299. trigger={() => (
  4300. <Button
  4301. type="primary"
  4302. style={{
  4303. float: "right",
  4304. position: "absolute",
  4305. top: "-40px",
  4306. right: "10px",
  4307. }}
  4308. >
  4309. 打印
  4310. </Button>
  4311. )}
  4312. content={() => this.refs.all}
  4313. />
  4314. }
  4315. {
  4316. this.state.newVisible == "项目进度" &&
  4317. <span style={{ display: "block", marginTop: 10, color: "red" }}>
  4318. 外包(内部)价格总计(万元):{this.state.totalWaibao}
  4319. </span>
  4320. }
  4321. {
  4322. this.state.newVisible == "项目进度" &&
  4323. <Button
  4324. type="primary"
  4325. style={{
  4326. float: "right",
  4327. position: "absolute",
  4328. top: "-40px",
  4329. right: "100px",
  4330. }}
  4331. loading={this.state.exportPendingLoading}
  4332. onClick={() => { this.exportPro() }}
  4333. >
  4334. 导出
  4335. </Button>
  4336. }
  4337. {
  4338. this.state.newVisible == "项目进度" &&
  4339. <ReactToPrint
  4340. trigger={() => (
  4341. <Button
  4342. type="primary"
  4343. style={{
  4344. float: "right",
  4345. position: "absolute",
  4346. top: "-40px",
  4347. right: "10px",
  4348. }}
  4349. >
  4350. 打印
  4351. </Button>
  4352. )}
  4353. content={() => this.refs.all}
  4354. />
  4355. }
  4356. {
  4357. this.state.newVisible == "公出详细列表" &&
  4358. <Button
  4359. type="primary"
  4360. style={{
  4361. float: "right",
  4362. position: "absolute",
  4363. top: "-90px",
  4364. right: "100px",
  4365. }}
  4366. loading={this.state.exportPendingLoading}
  4367. onClick={() => { this.pubexportExec() }}
  4368. >
  4369. 导出
  4370. </Button>
  4371. }
  4372. {
  4373. this.state.newVisible == "公出详细列表" &&
  4374. <ReactToPrint
  4375. trigger={() => (
  4376. <Button
  4377. type="primary"
  4378. style={{
  4379. float: "right",
  4380. position: "absolute",
  4381. top: "-90px",
  4382. right: "10px",
  4383. }}
  4384. >
  4385. 打印
  4386. </Button>
  4387. )}
  4388. content={() => this.refs.all}
  4389. />
  4390. }
  4391. </div>
  4392. }
  4393. </div>
  4394. </Spin>
  4395. </Modal>
  4396. }
  4397. <textarea id="copyText" style={{ opacity: 0 }} />
  4398. </div>
  4399. );
  4400. },
  4401. });
  4402. export default ShouKuang;