shouKuanAll.jsx 131 KB

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