shouKuang.jsx 133 KB

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