shouKuang.jsx 133 KB

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