shouKuang.jsx 104 KB

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