shouKuang.jsx 104 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694
  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> :
  1068. record.approval == 2 && <Tag color="#ff0000">特批通过</Tag>
  1069. }
  1070. </div>
  1071. </div>
  1072. </Tooltip>
  1073. );
  1074. },
  1075. },
  1076. {
  1077. title: "客户名称",
  1078. dataIndex: "buyerName",
  1079. key: "buyerName",
  1080. className: "title-table",
  1081. fixed: "left",
  1082. width: 150,
  1083. render: text => {
  1084. return (
  1085. <Tooltip title={text}>
  1086. <div style={{
  1087. maxWidth: '150px',
  1088. overflow: 'hidden',
  1089. textOverflow: "ellipsis",
  1090. whiteSpace: 'nowrap',
  1091. }}>{text}</div>
  1092. </Tooltip>
  1093. )
  1094. }
  1095. },
  1096. {
  1097. title: "订单编号",
  1098. dataIndex: "orderNo",
  1099. key: "orderNo",
  1100. className: "title-table",
  1101. fixed: "left",
  1102. width: 150,
  1103. render: (text, record) => {
  1104. return (
  1105. <Tooltip
  1106. title={
  1107. <Button
  1108. type="primary"
  1109. onClick={(e) => {
  1110. e.stopPropagation();
  1111. let input = document.getElementById("copyText");
  1112. input.value = text;
  1113. input.select();
  1114. document.execCommand("copy");
  1115. message.success("复制成功");
  1116. }}
  1117. >
  1118. 复制
  1119. </Button>
  1120. }
  1121. >
  1122. <div>
  1123. {text}
  1124. <div>
  1125. {record.signTotalAmount >= 10 && <Tag color="#ef7207">大客户</Tag>}
  1126. {record.projectType == 1 && <Tag color="rgb(22, 155, 213)">会员</Tag>}
  1127. </div>
  1128. </div>
  1129. </Tooltip>
  1130. );
  1131. },
  1132. },
  1133. // {
  1134. // title: "特批状态",
  1135. // dataIndex: "approval",
  1136. // key: "approval",
  1137. // className: "title-table",
  1138. // render: (text) => {
  1139. // if (text == 1 || text == 2) {
  1140. // return <Tag color="#f50">{getApproval(text)}</Tag>;
  1141. // }
  1142. // return getApproval(text);
  1143. // },
  1144. // },
  1145. {
  1146. title: "订单部门",
  1147. dataIndex: "departmentName",
  1148. key: "departmentName",
  1149. className: "title-table",
  1150. },
  1151. {
  1152. title: "订单负责人",
  1153. dataIndex: "sellerName",
  1154. key: "sellerName",
  1155. className: "title-table",
  1156. },
  1157. {
  1158. title: "财务负责人",
  1159. dataIndex: "financeName",
  1160. key: "financeName",
  1161. className: "title-table",
  1162. },
  1163. {
  1164. title: "签单日期",
  1165. dataIndex: "signTime",
  1166. key: "signTime",
  1167. className: "title-table",
  1168. },
  1169. {
  1170. title: "下单日期",
  1171. dataIndex: "createTime",
  1172. key: "createTime",
  1173. className: "title-table",
  1174. },
  1175. {
  1176. title: "签单金额(万元)",
  1177. dataIndex: "signTotalAmount",
  1178. key: "signTotalAmount",
  1179. className: "title-table",
  1180. render: (text) => {
  1181. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1182. }
  1183. },
  1184. {
  1185. title: "开票金额(万元)",
  1186. dataIndex: "invoiceAmount",
  1187. key: "invoiceAmount",
  1188. className: "title-table",
  1189. render: (text) => {
  1190. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1191. }
  1192. },
  1193. {
  1194. title: "已收款(万元)",
  1195. dataIndex: "actuallyTotalAmount",
  1196. key: "actuallyTotalAmount",
  1197. className: "title-table",
  1198. render: (text) => {
  1199. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1200. }
  1201. },
  1202. {
  1203. title: "应收款(万元)",
  1204. dataIndex: "orderReceivables",
  1205. key: "orderReceivables",
  1206. className: "title-table",
  1207. render: (text) => {
  1208. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1209. }
  1210. },
  1211. {
  1212. title: "欠款(万元)",
  1213. dataIndex: "orderArrears",
  1214. key: "orderArrears",
  1215. className: "title-table",
  1216. render: (text) => {
  1217. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1218. }
  1219. },
  1220. {
  1221. title: "总成本(万元)",
  1222. dataIndex: "costAmount",
  1223. key: "costAmount",
  1224. className: "title-table",
  1225. render: (text) => {
  1226. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1227. }
  1228. },
  1229. {
  1230. title: "已付成本(万元)",
  1231. dataIndex: "paymentAmount",
  1232. key: "paymentAmount",
  1233. className: "title-table",
  1234. render: (text) => {
  1235. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1236. }
  1237. },
  1238. {
  1239. title: "最近收款(万元)",
  1240. dataIndex: "finalReceivables",
  1241. key: "finalReceivables",
  1242. className: "title-table",
  1243. render: (text) => {
  1244. return isNaN(parseFloat(text)) ? text : parseFloat(text);
  1245. }
  1246. },
  1247. {
  1248. title: "最近收款时间",
  1249. dataIndex: "finalReceivablesTime",
  1250. key: "finalReceivablesTime",
  1251. className: "title-table",
  1252. },
  1253. {
  1254. title: "结算状态",
  1255. dataIndex: "liquidationStatus",
  1256. key: "liquidationStatus",
  1257. className: "title-table",
  1258. render: (text) => {
  1259. return getLiquidationStatus(text);
  1260. },
  1261. },
  1262. {
  1263. title: "流程状态",
  1264. dataIndex: "processStatus",
  1265. key: "processStatus",
  1266. className: "title-table",
  1267. render: (text) => {
  1268. return getProcessStatus(text);
  1269. },
  1270. },
  1271. // {
  1272. // title: '订单状态',
  1273. // dataIndex: 'orderStatus',
  1274. // key: 'orderStatus',
  1275. // render: text => { return getNewOrderStatus(text)}
  1276. // },
  1277. {
  1278. title: "操作",
  1279. dataIndex: "caozuo",
  1280. key: "caouzo",
  1281. className: "title-table",
  1282. render: (text, recard) => {
  1283. return (
  1284. <div>
  1285. {/* {recard.liquidationStatus < 2 &&
  1286. (recard.approval === 1 || recard.approval === 2) ? (
  1287. <Button
  1288. style={{ background: "rgb(192,192,192)" }}
  1289. onClick={e => {
  1290. e.stopPropagation(), this.evaluateX(recard);
  1291. }}
  1292. >
  1293. 收款
  1294. </Button>
  1295. ) : (
  1296. <Button
  1297. type="primary"
  1298. onClick={e => {
  1299. e.stopPropagation(), this.evaluateX(recard);
  1300. }}
  1301. >
  1302. 收款
  1303. </Button>
  1304. )} */}
  1305. {recard.backStatus == 3 ? <Tag>已驳回</Tag> : ""}
  1306. {recard.processStatus == 3 ? (
  1307. <Button
  1308. type="primary"
  1309. onClick={(e) => {
  1310. // e.stopPropagation(), this.evaluateZ(recard);
  1311. e.stopPropagation(), this.checkRemark(recard);
  1312. }}
  1313. style={{ marginLeft: "5px" }}
  1314. >
  1315. 通过
  1316. </Button>
  1317. ) : (
  1318. ""
  1319. )}
  1320. {!(
  1321. recard.actuallyTotalAmount &&
  1322. Number(recard.actuallyTotalAmount) > 0
  1323. ) && (
  1324. <Button
  1325. type="danger"
  1326. style={{
  1327. marginLeft: "5px",
  1328. display:
  1329. recard.processStatus == 3 ? "inline-block" : "none",
  1330. }}
  1331. onClick={(e) => {
  1332. e.stopPropagation(), this.reject(recard);
  1333. }}
  1334. >
  1335. 驳回
  1336. </Button>
  1337. )}
  1338. {
  1339. // <Button
  1340. // type="primary"
  1341. // style={{ marginLeft: "5px" }}
  1342. // onClick={e => {
  1343. // e.stopPropagation(), this.evaluateY(recard, "财务专员");
  1344. // console.log(recard);
  1345. // }}
  1346. // >
  1347. // 转交
  1348. // </Button>
  1349. }
  1350. </div>
  1351. );
  1352. },
  1353. },
  1354. ],
  1355. dataSource: [],
  1356. searchTime: [],
  1357. columnsDate: [
  1358. {
  1359. title: "编号",
  1360. dataIndex: "id",
  1361. key: "id",
  1362. },
  1363. {
  1364. title: "订单编号",
  1365. dataIndex: "orderno",
  1366. key: "orderno",
  1367. },
  1368. {
  1369. title: "开票金额(万元)",
  1370. dataIndex: "amount",
  1371. key: "amount",
  1372. },
  1373. {
  1374. title: "申请时间",
  1375. dataIndex: "createTime",
  1376. key: "createTime",
  1377. },
  1378. {
  1379. title: "开票状态",
  1380. dataIndex: "status",
  1381. key: "status",
  1382. render: (text, record) => {
  1383. return <div>{getInvoiceStatus(text, record)} <LogPopup id={record.id} /></div>;
  1384. },
  1385. },
  1386. ],
  1387. waterlistDate: [
  1388. {
  1389. title: "订单编号",
  1390. dataIndex: "orderNo",
  1391. key: "orderNo",
  1392. },
  1393. {
  1394. title: "平台流水号",
  1395. dataIndex: "billNo",
  1396. key: "billNo",
  1397. // fixed: "left"
  1398. },
  1399. {
  1400. title: "收款金额(万元)",
  1401. dataIndex: "transactionAmount",
  1402. key: "transactionAmount",
  1403. },
  1404. {
  1405. title: "收款方",
  1406. dataIndex: "payeeName",
  1407. key: "payeeName",
  1408. },
  1409. {
  1410. title: "付款方",
  1411. dataIndex: "payerName",
  1412. key: "payerName",
  1413. },
  1414. {
  1415. title: "流水科目",
  1416. dataIndex: "transactionSubject",
  1417. key: "transactionSubject",
  1418. render: (text) => {
  1419. return getTransactionProject(text);
  1420. },
  1421. },
  1422. {
  1423. title: "收款类型",
  1424. dataIndex: "type",
  1425. key: "type",
  1426. },
  1427. {
  1428. title: "财务流水时间",
  1429. dataIndex: "financialPayTimes",
  1430. key: "financialPayTimes",
  1431. },
  1432. {
  1433. title: "财务流水号",
  1434. dataIndex: "financialPayNo",
  1435. key: "financialPayNo",
  1436. },
  1437. {
  1438. title: "订单负责人",
  1439. dataIndex: "saleName",
  1440. key: "saleName",
  1441. },
  1442. {
  1443. title: "创建时间",
  1444. dataIndex: "createTimes",
  1445. key: "createTimes",
  1446. },
  1447. {
  1448. title: "退款时间",
  1449. dataIndex: "refundTimes",
  1450. key: "refundTimes",
  1451. },
  1452. {
  1453. title: "删除时间",
  1454. dataIndex: "deleteTimes",
  1455. key: "deleteTimes",
  1456. },
  1457. {
  1458. title: "备注",
  1459. dataIndex: "remarks",
  1460. key: "remarks",
  1461. },
  1462. {
  1463. title: "流水状态",
  1464. dataIndex: "deleteSign",
  1465. key: "deleteSign",
  1466. render: (text, record) => {
  1467. if (!text) {
  1468. return (
  1469. <Popconfirm
  1470. title="是否删除?"
  1471. onConfirm={() => {
  1472. this.changeWater(record.billNo);
  1473. }}
  1474. okText="删除"
  1475. cancelText="不删除"
  1476. >
  1477. <Button>删除</Button>
  1478. </Popconfirm>
  1479. );
  1480. } else {
  1481. return <Tag>已删除</Tag>;
  1482. }
  1483. },
  1484. },
  1485. ],
  1486. waterData: [],
  1487. };
  1488. },
  1489. changeWater(billNo) {
  1490. this.setState({
  1491. loading: true,
  1492. });
  1493. $.ajax({
  1494. method: "get",
  1495. dataType: "json",
  1496. crossDomain: false,
  1497. url: globalConfig.context + "/api/admin/financial/deleteMyBill",
  1498. data: {
  1499. billNo,
  1500. },
  1501. success: function (data) {
  1502. let theArr = [];
  1503. if (data.error && data.error.length) {
  1504. message.warning(data.error[0].message);
  1505. } else {
  1506. message.warning("删除流水成功!");
  1507. this.waterData();
  1508. this.loadData();
  1509. }
  1510. }.bind(this),
  1511. }).always(
  1512. function () {
  1513. this.setState({
  1514. loading: false,
  1515. });
  1516. }.bind(this)
  1517. );
  1518. },
  1519. // 特批通过
  1520. evaluateZ(record) {
  1521. $.ajax({
  1522. method: "POST",
  1523. dataType: "json",
  1524. crossDomain: false,
  1525. url: globalConfig.context + "/api/admin/financial/financeApproval",
  1526. data: {
  1527. orderNo: record.orderNo,
  1528. },
  1529. }).done(
  1530. function (data) {
  1531. if (!data.error.length) {
  1532. message.success("通过成功!");
  1533. this.setState({
  1534. loading: false,
  1535. });
  1536. this.loadData();
  1537. } else {
  1538. message.warning(data.error[0].message);
  1539. }
  1540. }.bind(this)
  1541. );
  1542. },
  1543. /* 收款 */
  1544. evaluateX(recard) {
  1545. this.state.assignDataX = recard;
  1546. this.setState({
  1547. assignVisibleX: true,
  1548. });
  1549. },
  1550. /* 转交 */
  1551. evaluateY(recard, nub) {
  1552. this.state.assignDataY = recard;
  1553. this.setState({
  1554. nub,
  1555. assignVisibleY: true,
  1556. });
  1557. },
  1558. /* 驳回 */
  1559. reject(recard) {
  1560. this.setState({
  1561. bohuiData: recard,
  1562. boHuiVisible: true,
  1563. content: "",
  1564. });
  1565. },
  1566. boHuiOk() {
  1567. this.setState({
  1568. boHuiVisible: false,
  1569. });
  1570. if (
  1571. this.state.pagination.current == this.state.totalPage &&
  1572. this.state.pagination.total % 10 == 1
  1573. ) {
  1574. this.loadData(this.state.page - 1);
  1575. } else {
  1576. this.loadData(this.state.page);
  1577. }
  1578. },
  1579. boHuiCancel() {
  1580. this.setState({
  1581. boHuiVisible: false,
  1582. });
  1583. },
  1584. componentWillMount() {
  1585. this.loadData();
  1586. this.departmentList();
  1587. },
  1588. tableRowClick(record) {
  1589. this.state.RowData = record;
  1590. this.setState({
  1591. showDesc: true,
  1592. });
  1593. },
  1594. closeDesc(e, s) {
  1595. this.state.showDesc = e;
  1596. if (s) {
  1597. this.loadData(this.state.page);
  1598. }
  1599. },
  1600. closeAssignX(e, s) {
  1601. this.state.assignDataX = {};
  1602. this.state.assignVisibleX = e;
  1603. if (s) {
  1604. this.loadData(this.state.page);
  1605. }
  1606. },
  1607. closeAssignY(e, s) {
  1608. this.state.assignDataY = {};
  1609. this.state.assignVisibleY = e;
  1610. if (s) {
  1611. this.loadData(this.state.page);
  1612. }
  1613. },
  1614. search() {
  1615. this.setState({
  1616. selectedRowKeys: []
  1617. })
  1618. this.loadData();
  1619. },
  1620. // 拆分详细
  1621. showRes(record) {
  1622. this.setState({
  1623. resVisible: true,
  1624. resRecord: record,
  1625. });
  1626. },
  1627. resCancel() {
  1628. this.setState({
  1629. resVisible: false,
  1630. });
  1631. },
  1632. reset() {
  1633. this.state.nameSearch = "";
  1634. this.state.releaseDate = [];
  1635. this.state.shouKuanDate = [];
  1636. this.state.orderNoSearch = "";
  1637. this.state.departmenttList = undefined;
  1638. this.state.amountStatus = undefined;
  1639. this.state.approval = undefined;
  1640. this.state.projectType = undefined;
  1641. this.state.processStatus = [];
  1642. this.state.contractNoSearch = "";
  1643. this.state.liquidationStatus = [];
  1644. this.state.processStatusSearch = [];
  1645. this.state.contractNo = "";
  1646. this.Cascaders.empty();
  1647. this.loadData();
  1648. },
  1649. //驳回
  1650. boHuiSubmit(e) {
  1651. e.preventDefault();
  1652. if (!this.state.content) {
  1653. message.warning("请填写驳回原因");
  1654. return false;
  1655. }
  1656. this.setState({
  1657. loading: true,
  1658. });
  1659. $.ajax({
  1660. method: "POST",
  1661. dataType: "json",
  1662. crossDomain: false,
  1663. url: globalConfig.context + "/api/admin/financial/reject",
  1664. data: {
  1665. orderNo: this.state.bohuiData.orderNo,
  1666. reason: this.state.content,
  1667. },
  1668. }).done(
  1669. function (data) {
  1670. if (!data.error.length) {
  1671. message.success("驳回成功!");
  1672. this.setState({
  1673. loading: false,
  1674. });
  1675. this.boHuiOk();
  1676. } else {
  1677. message.warning(data.error[0].message);
  1678. }
  1679. }.bind(this)
  1680. );
  1681. },
  1682. searchSwitch() {
  1683. this.setState({
  1684. searchMore: !this.state.searchMore,
  1685. });
  1686. },
  1687. changeList(arr) {
  1688. const newArr = [];
  1689. this.state.columns.forEach((item) => {
  1690. arr.forEach((val) => {
  1691. if (val === item.title) {
  1692. newArr.push(item);
  1693. }
  1694. });
  1695. });
  1696. this.setState({
  1697. changeList: newArr,
  1698. });
  1699. },
  1700. callback(key) {
  1701. // console.log(key);
  1702. },
  1703. onSelectChange(selectedRowKeys, selectedRows) {
  1704. // for(var i=0; i<selectedRowKeys.length; i++){
  1705. // for(var j=i+1; j<selectedRowKeys.length; j++){
  1706. // if(selectedRowKeys[i]==selectedRowKeys[j]){
  1707. // selectedRowKeys.splice(j,1);
  1708. // j--;
  1709. // }
  1710. // }
  1711. // }
  1712. this.setState({ selectedRowKeys, selectedRows });
  1713. },
  1714. inRecordCanl() {
  1715. this.setState({
  1716. bvisible: false,
  1717. });
  1718. },
  1719. inRecordData() {
  1720. this.setState({
  1721. loading: true,
  1722. });
  1723. $.ajax({
  1724. method: "get",
  1725. dataType: "json",
  1726. crossDomain: false,
  1727. url:
  1728. globalConfig.context +
  1729. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  1730. data: {
  1731. orderNo: this.state.selectedRowKeys[0],
  1732. pageSize: 9999999,
  1733. },
  1734. success: function (data) {
  1735. let theArr = [];
  1736. let sum = 0;
  1737. if (!data.data) {
  1738. if (data.error && data.error.length) {
  1739. message.warning(data.error[0].message);
  1740. }
  1741. } else {
  1742. for (let i = 0; i < data.data.list.length; i++) {
  1743. let thisdata = data.data.list[i];
  1744. sum += parseFloat(thisdata.amount);
  1745. theArr.push({
  1746. id: thisdata.id,
  1747. orderno: thisdata.orderno, //订单编号
  1748. amount: thisdata.amount, //签单金额
  1749. createTime: thisdata.createTime, //流程状态
  1750. status: thisdata.status, //结算状态
  1751. rejectReason: thisdata.rejectReason,
  1752. approval: thisdata.approval,//0非特批 1待审核 2审核通过
  1753. });
  1754. }
  1755. }
  1756. this.setState({
  1757. recordData: theArr,
  1758. sum: sum.toFixed(6),
  1759. });
  1760. }.bind(this),
  1761. }).done(
  1762. function () {
  1763. this.setState({
  1764. loading: false,
  1765. });
  1766. }.bind(this)
  1767. );
  1768. },
  1769. waterData() {
  1770. this.state.data = [];
  1771. this.setState({
  1772. loading: true,
  1773. });
  1774. $.ajax({
  1775. method: "get",
  1776. dataType: "json",
  1777. crossDomain: false,
  1778. url: globalConfig.context + "/api/admin/financial/myBillList",
  1779. data: {
  1780. orderNo: this.state.selectedRowKeys[0],
  1781. pageSize: 9999999,
  1782. whoType: 1,
  1783. },
  1784. success: function (data) {
  1785. let theArr = [];
  1786. let waterSum = 0;
  1787. if (!data.data || !data.data.list) {
  1788. if (data.error && data.error.length) {
  1789. message.warning(data.error[0].message);
  1790. }
  1791. } else {
  1792. for (let i = 0; i < data.data.list.length; i++) {
  1793. let thisdata = data.data.list[i];
  1794. if (thisdata.deleteSign == 0) {
  1795. waterSum += parseFloat(thisdata.transactionAmount);
  1796. }
  1797. theArr.push({
  1798. key: i,
  1799. orderNo: thisdata.orderNo,
  1800. billNo: thisdata.billNo,
  1801. transactionAmount: thisdata.transactionAmount,
  1802. payeeName: thisdata.payeeName,
  1803. payerName: thisdata.payerName,
  1804. transactionSubject: thisdata.transactionSubject,
  1805. transactionChannel: thisdata.transactionChannel,
  1806. financialPayTimes: thisdata.financialPayTimes,
  1807. financialPayNo: thisdata.financialPayNo,
  1808. createrName: thisdata.createrName,
  1809. saleName: thisdata.saleName,
  1810. createTimes: thisdata.createTimes,
  1811. type:
  1812. thisdata.type == 0
  1813. ? "手工"
  1814. : thisdata.type == 1
  1815. ? "批量"
  1816. : "合同变更退款",
  1817. deleteSign: thisdata.deleteSign,
  1818. deleteTimes: thisdata.deleteTimes,
  1819. refundTimes: thisdata.refundTimes,
  1820. remarks: thisdata.remarks,
  1821. });
  1822. }
  1823. }
  1824. this.setState({
  1825. waterData: theArr,
  1826. waterSum: (Math.round(waterSum * 1000000) / 1000000).toFixed(6),
  1827. });
  1828. }.bind(this),
  1829. }).always(
  1830. function () {
  1831. this.setState({
  1832. loading: false,
  1833. });
  1834. }.bind(this)
  1835. );
  1836. },
  1837. waterCanl() {
  1838. this.setState({
  1839. cvisible: false,
  1840. });
  1841. },
  1842. exportKaip() {
  1843. window.location.href =
  1844. globalConfig.context +
  1845. "/api/admin/receivables/exportInvoice?" +
  1846. `orderNo=${this.state.selectedRowKeys}`;
  1847. },
  1848. exportAll() {
  1849. message.config({
  1850. duration: 20,
  1851. });
  1852. let loading = message.loading("下载中...");
  1853. this.setState({
  1854. exportPendingLoading: true,
  1855. });
  1856. let data = {
  1857. orderNo: this.state.orderNoSearch,
  1858. buyerName: this.state.nameSearch,
  1859. deps: this.state.departmenttList,
  1860. contractNo: this.state.contractNoSearch,
  1861. processStatus: this.state.processStatusSearch,
  1862. };
  1863. $.ajax({
  1864. method: "get",
  1865. dataType: "json",
  1866. crossDomain: false,
  1867. url: "/api/admin/receivables/exportReceivables",
  1868. data,
  1869. success: function (data) {
  1870. if (data.error.length === 0) {
  1871. this.download(data.data);
  1872. } else {
  1873. message.warning(data.error[0].message);
  1874. }
  1875. }.bind(this),
  1876. }).always(
  1877. function () {
  1878. loading();
  1879. this.setState({
  1880. exportPendingLoading: false,
  1881. });
  1882. }.bind(this)
  1883. );
  1884. // window.location.href =
  1885. // globalConfig.context +
  1886. // "/api/admin/receivables/exportReceivables?" +
  1887. // `orderNo=${this.state.orderNoSearch ? this.state.orderNoSearch : ""
  1888. // }&buyerName=${this.state.nameSearch ? this.state.nameSearch : ""
  1889. // }&deps=${this.state.departmenttList ? this.state.departmenttList : ""
  1890. // }&contractNo=${this.state.contractNoSearch ? this.state.contractNoSearch : ""
  1891. // }&processStatus=${this.state.processStatusSearch}`;
  1892. },
  1893. // 下载
  1894. download(fileName) {
  1895. window.location.href =
  1896. globalConfig.context + "/open/download?fileName=" + fileName;
  1897. },
  1898. exportWater() {
  1899. window.location.href =
  1900. globalConfig.context +
  1901. "/api/admin/receivables/exportMyBill?" +
  1902. `orderNo=${this.state.selectedRowKeys}&whoType=1`;
  1903. },
  1904. printAll() {
  1905. this.setState({
  1906. dvisible: true,
  1907. });
  1908. this.loadData(1, 9999999);
  1909. },
  1910. timeData() {
  1911. this.setState({
  1912. loading: true,
  1913. });
  1914. $.ajax({
  1915. method: "get",
  1916. dataType: "json",
  1917. crossDomain: false,
  1918. url: globalConfig.context + "/api/admin/orderProject/taskHoursList",
  1919. data: {
  1920. orderNo: this.state.selectedRowKeys[0],
  1921. pageSize: 9999999,
  1922. },
  1923. success: function (data) {
  1924. let theArr = [];
  1925. if (!data.data || !data.data.list) {
  1926. if (data.error && data.error.length) {
  1927. message.warning(data.error[0].message);
  1928. }
  1929. } else {
  1930. for (let i = 0; i < data.data.list.length; i++) {
  1931. let thisdata = data.data.list[i];
  1932. theArr.push({
  1933. key: i + 1,
  1934. id: thisdata.id, //ID
  1935. orderNo: thisdata.orderNo, //订单编号
  1936. taskName: thisdata.taskName, //任务名称
  1937. userName: thisdata.userName, //客户名称
  1938. cname: thisdata.cname, //项目品类
  1939. taskStatus: thisdata.taskStatus, //任务状态
  1940. receiverName: thisdata.receiverName, //负责人
  1941. hours: thisdata.hours, //任务工时
  1942. depName: thisdata.depName, //派单公司
  1943. contractNo: thisdata.contractNo,
  1944. signTime: thisdata.signTime,
  1945. creteTime: thisdata.creteTime,
  1946. projectStatus: thisdata.projectStatus,
  1947. commodityPrice: thisdata.commodityPrice, //价格
  1948. commodityQuantity: thisdata.commodityQuantity, //数量
  1949. salesmanName: thisdata.salesmanName, //订单负责人
  1950. taskDistributionTime: thisdata.taskDistributionTime,
  1951. taskEndTime: thisdata.taskEndTime,
  1952. outsource: thisdata.outsource,
  1953. splitStatus: thisdata.splitStatus,
  1954. splitSuper: thisdata.splitSuper,
  1955. splitId: thisdata.splitId,
  1956. });
  1957. }
  1958. }
  1959. this.setState({
  1960. timeDataList: theArr,
  1961. });
  1962. }.bind(this),
  1963. }).always(
  1964. function () {
  1965. this.setState({
  1966. loading: false,
  1967. });
  1968. }.bind(this)
  1969. );
  1970. },
  1971. exportTime() {
  1972. const data = {
  1973. orderNo: this.state.selectedRowKeys[0],
  1974. pageSize: 9999999,
  1975. };
  1976. window.location.href =
  1977. globalConfig.context +
  1978. "/api/admin/orderProject/exportMyTaskList?" +
  1979. $.param(data);
  1980. },
  1981. exportPro() {
  1982. const data = {
  1983. orderNo: this.state.selectedRowKeys[0],
  1984. };
  1985. window.location.href =
  1986. globalConfig.context +
  1987. "/api/admin/newOrder/exportOrderTaskData?" +
  1988. $.param(data);
  1989. },
  1990. exportCui() {
  1991. var data = {
  1992. orderNo: this.state.selectedRowKeys[0]
  1993. ? this.state.selectedRowKeys[0]
  1994. : undefined, //订单编号
  1995. // specially: 1,
  1996. pageSize: 9999999,
  1997. };
  1998. window.location.href =
  1999. globalConfig.context +
  2000. "/api/admin/newOrder/exportOrderDunData?" +
  2001. $.param(data);
  2002. },
  2003. cuiData() {
  2004. this.setState({
  2005. loading: true,
  2006. });
  2007. $.ajax({
  2008. method: "get",
  2009. dataType: "json",
  2010. crossDomain: false,
  2011. url: globalConfig.context + "/api/admin/newOrder/dunOrderNewList",
  2012. data: {
  2013. orderNo: this.state.selectedRowKeys[0],
  2014. pageSize: 9999999,
  2015. },
  2016. success: function (data) {
  2017. let theArr = [];
  2018. if (!data.data || !data.data.list) {
  2019. if (data.error && data.error.length) {
  2020. message.warning(data.error[0].message);
  2021. }
  2022. } else {
  2023. for (let i = 0; i < data.data.list.length; i++) {
  2024. let thisdata = data.data.list[i];
  2025. theArr.push({
  2026. key: i + 1,
  2027. orderNo: thisdata.orderNo,
  2028. contractNo: thisdata.contractNo,
  2029. userName: thisdata.userName,
  2030. buyerName: thisdata.buyerName,
  2031. departmentName: thisdata.departmentName,
  2032. salesmanName: thisdata.salesmanName,
  2033. depName: thisdata.depName,
  2034. orderStatus: thisdata.orderStatus,
  2035. projectStatus: thisdata.projectStatus,
  2036. totalAmount: thisdata.totalAmount,
  2037. liquidationStatus: thisdata.liquidationStatus,
  2038. settlementAmount: thisdata.settlementAmount,
  2039. accountsReceivable: thisdata.accountsReceivable,
  2040. dunSubject: thisdata.dunSubject,
  2041. startDate: thisdata.startDate,
  2042. taskStatus: thisdata.taskStatus,
  2043. cname: thisdata.cname,
  2044. id: thisdata.id,
  2045. taskName: thisdata.taskName,
  2046. hours: thisdata.hours,
  2047. taskDistributionTime: thisdata.taskDistributionTime,
  2048. taskEndTime: thisdata.taskEndTime,
  2049. dunStatus: thisdata.dunStatus == 0 ? "未触发" : "已触发",
  2050. });
  2051. }
  2052. }
  2053. this.setState({
  2054. cuiDataList: theArr,
  2055. });
  2056. }.bind(this),
  2057. }).always(
  2058. function () {
  2059. this.setState({
  2060. loading: false,
  2061. });
  2062. }.bind(this)
  2063. );
  2064. },
  2065. cuiTabChange(index) {
  2066. this.setState({
  2067. cuiTabKey: index,
  2068. });
  2069. if (index == 2) {
  2070. this.setState({
  2071. loading: true,
  2072. });
  2073. $.ajax({
  2074. method: "get",
  2075. dataType: "json",
  2076. crossDomain: false,
  2077. url: globalConfig.context + "/api/admin/newOrder/arrearsDunList",
  2078. data: {
  2079. orderNo: this.state.selectedRowKeys[0],
  2080. pageSize: 9999999,
  2081. },
  2082. success: function (data) {
  2083. let theArr = [];
  2084. if (data.error.length || data.data.list == "") {
  2085. if (data.error && data.error.length) {
  2086. message.warning(data.error[0].message);
  2087. }
  2088. } else {
  2089. for (let i = 0; i < data.data.list.length; i++) {
  2090. let thisdata = data.data.list[i];
  2091. let obj = thisdata;
  2092. obj.key = i;
  2093. theArr.push(obj);
  2094. }
  2095. }
  2096. this.setState({
  2097. qianDataList: theArr,
  2098. });
  2099. }.bind(this),
  2100. }).always(
  2101. function () {
  2102. this.setState({
  2103. loading: false,
  2104. });
  2105. }.bind(this)
  2106. );
  2107. }
  2108. },
  2109. proData() {
  2110. this.setState({
  2111. loading: true,
  2112. });
  2113. $.ajax({
  2114. method: "get",
  2115. dataType: "json",
  2116. crossDomain: false,
  2117. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  2118. data: {
  2119. orderNo: this.state.selectedRowKeys[0],
  2120. pageSize: 9999999,
  2121. },
  2122. success: function (data) {
  2123. let theArr = [];
  2124. let totalWaibao = 0;
  2125. if (!data.data) {
  2126. if (data.error && data.error.length) {
  2127. message.warning(data.error[0].message);
  2128. }
  2129. } else {
  2130. for (let i = 0; i < data.data.length; i++) {
  2131. let thisdata = data.data[i];
  2132. totalWaibao += thisdata.outsourcePrice;
  2133. thisdata.key = i + 1;
  2134. theArr.push(thisdata);
  2135. }
  2136. }
  2137. totalWaibao = (Math.round(totalWaibao * 1000000) / 1000000).toFixed(6);
  2138. this.setState({
  2139. proDataList: theArr,
  2140. totalWaibao,
  2141. });
  2142. }.bind(this),
  2143. }).always(
  2144. function () {
  2145. this.setState({
  2146. loading: false,
  2147. });
  2148. }.bind(this)
  2149. );
  2150. },
  2151. // 查看公出列表
  2152. pubData() {
  2153. this.setState({
  2154. loading: true,
  2155. });
  2156. let rows = this.state.selectedRows[0]
  2157. let searchInfor = {
  2158. releaseStart: this.state.releaseDate[0] || undefined,
  2159. releaseEnd: this.state.releaseDate[1] || undefined,
  2160. aid: this.state.theTypes || undefined,
  2161. sid: this.state.theTypes1 || undefined,
  2162. status: this.state.status,
  2163. clockIn: this.state.clockIn,
  2164. depId: this.state.depId || undefined,
  2165. publicType: this.state.type,
  2166. }
  2167. let datas = Object.assign(searchInfor, {
  2168. pageNo: this.state.pubpageNo || 1,
  2169. pageSize: 9999999,
  2170. uid: rows.buyerId,
  2171. });
  2172. $.ajax({
  2173. method: "get",
  2174. dataType: "json",
  2175. crossDomain: false,
  2176. url: globalConfig.context + "/api/admin/release/publicReleaseDtails",
  2177. data: datas,
  2178. success: function (data) {
  2179. let theArr = [];
  2180. this.setState({
  2181. loading: false,
  2182. });
  2183. if (!data.data) {
  2184. if (data.error && data.error.length) {
  2185. message.warning(data.error[0].message);
  2186. }
  2187. } else {
  2188. for (let i = 0; i < data.data.list.length; i++) {
  2189. let thisdata = data.data.list[i];
  2190. thisdata.key = (data.data.pageNo - 1) * data.data.pageSize + i + 1;
  2191. theArr.push(thisdata);
  2192. }
  2193. this.state.pubpagination.current = data.data.pageNo;
  2194. this.state.pubpagination.total = data.data.totalCount;
  2195. if (data.data && data.data.list && !data.data.list.length) {
  2196. this.state.pubpagination.current = 0;
  2197. this.state.pubpagination.total = 0;
  2198. }
  2199. }
  2200. this.setState({
  2201. pubDataList: theArr,
  2202. pubpagination: this.state.pubpagination,
  2203. pubpageNo: data.data.pageNo,
  2204. });
  2205. }.bind(this),
  2206. }).always(
  2207. function () {
  2208. this.setState({
  2209. loading: false,
  2210. });
  2211. }.bind(this)
  2212. );
  2213. },
  2214. // 重置公出列表查询
  2215. resetAll() {
  2216. this.setState(
  2217. {
  2218. releaseDate: [],
  2219. theCustomerTypes: undefined,
  2220. status: undefined,
  2221. clockIn: undefined,
  2222. depId: undefined,
  2223. auto: "",
  2224. auto1: "",
  2225. customer: "",
  2226. theTypes: undefined,
  2227. theTypes1: undefined,
  2228. type: undefined,
  2229. },
  2230. () => {
  2231. this.pubData();
  2232. }
  2233. );
  2234. },
  2235. //公出导出
  2236. pubexportExec() {
  2237. this.setState({
  2238. exportPendingLoading: true,
  2239. });
  2240. message.config({
  2241. duration: 20,
  2242. });
  2243. let loading = message.loading("下载中...");
  2244. let rows = this.state.selectedRows[0]
  2245. let searchInfor = {
  2246. releaseStart: this.state.releaseDate[0] || undefined,
  2247. releaseEnd: this.state.releaseDate[1] || undefined,
  2248. aid: this.state.theTypes || undefined,
  2249. sid: this.state.theTypes1 || undefined,
  2250. status: this.state.status,
  2251. clockIn: this.state.clockIn,
  2252. depId: this.state.depId || undefined,
  2253. publicType: this.state.type,
  2254. }
  2255. let data = Object.assign(searchInfor, {
  2256. pageNo: this.state.pubpageNo || 1,
  2257. pageSize: 9999999,
  2258. uid: rows.buyerId,
  2259. exportType: 1,
  2260. });
  2261. for (let i of Object.keys(data)) {
  2262. if (i === "status" || i === "clockIn") {
  2263. if (isNaN(parseInt(data[i]))) {
  2264. delete data[i];
  2265. }
  2266. } else if (!data[i]) {
  2267. delete data[i];
  2268. }
  2269. }
  2270. $.ajax({
  2271. method: "get",
  2272. dataType: "json",
  2273. crossDomain: false,
  2274. url: globalConfig.context + "/api/admin/release/publicReleaseDtails/export",
  2275. data,
  2276. success: function (data) {
  2277. if (data.error.length === 0) {
  2278. this.download(data.data);
  2279. } else {
  2280. message.warning(data.error[0].message);
  2281. }
  2282. }.bind(this),
  2283. }).always(
  2284. function () {
  2285. loading();
  2286. this.setState({
  2287. exportPendingLoading: false,
  2288. });
  2289. }.bind(this)
  2290. );
  2291. },
  2292. // 下载
  2293. download(fileName) {
  2294. window.location.href =
  2295. globalConfig.context + "/open/download?fileName=" + fileName;
  2296. },
  2297. checkRemark(record) {
  2298. this.setState({
  2299. checkVisible: true,
  2300. checkOrderNo: record.orderNo,
  2301. });
  2302. },
  2303. checkOk() {
  2304. if (this.state.checkData == "" || this.state.checkData == undefined) {
  2305. message.warning("请填写审核内容");
  2306. return;
  2307. }
  2308. this.setState({
  2309. loading: true,
  2310. });
  2311. let ajaxObj = $.ajax({
  2312. method: "post",
  2313. dataType: "json",
  2314. crossDomain: false,
  2315. url: globalConfig.context + "/api/admin/financial/financeApproval",
  2316. data: {
  2317. orderNo: this.state.checkOrderNo,
  2318. remarks: this.state.checkData,
  2319. },
  2320. success: function (data) {
  2321. let theArr = [];
  2322. if (!data.data) {
  2323. if (data.error && data.error.length) {
  2324. message.warning(data.error[0].message);
  2325. }
  2326. } else {
  2327. message.success("通过成功!");
  2328. this.loadData();
  2329. this.setState({
  2330. checkVisible: false,
  2331. checkData: "",
  2332. });
  2333. }
  2334. }.bind(this),
  2335. }).always(
  2336. function () {
  2337. this.setState({
  2338. loading: false,
  2339. financeApprovalAjaxObj: null
  2340. });
  2341. }.bind(this)
  2342. );
  2343. this.setState({
  2344. financeApprovalAjaxObj: ajaxObj
  2345. })
  2346. },
  2347. tableRowClickPro(record) {
  2348. this.setState({
  2349. pvisible: true,
  2350. record,
  2351. });
  2352. },
  2353. kaiPiaoData(record) {
  2354. this.setState({
  2355. avisible: true,
  2356. });
  2357. this.invoiceData(record.id)
  2358. },
  2359. invoiceData(id) {
  2360. this.setState({
  2361. loading: true,
  2362. });
  2363. $.ajax({
  2364. method: "get",
  2365. dataType: "json",
  2366. crossDomain: false,
  2367. url:
  2368. globalConfig.context + "/api/admin/orderInvoice/selectByIdOrderInvoice",
  2369. data: {
  2370. id,
  2371. },
  2372. success: function (data) {
  2373. let thisdata = data.data;
  2374. let obj = {
  2375. contractNo: thisdata.contractNo,
  2376. orderNo: thisdata.orderNo,
  2377. approval: thisdata.approval,
  2378. type: thisdata.type,
  2379. status: thisdata.status,
  2380. remarks: thisdata.remarks,
  2381. invoiceType: thisdata.invoiceType,
  2382. unitName: thisdata.unitName,
  2383. taxNumber: thisdata.taxNumber,
  2384. amount: thisdata.amount,
  2385. banks: thisdata.banks,
  2386. content: thisdata.content,
  2387. unitAddress: thisdata.unitAddress,
  2388. invoiceRemarks: thisdata.invoiceRemarks,
  2389. unitMobile: thisdata.unitMobile,
  2390. post: thisdata.post,
  2391. addressee: thisdata.addressee,
  2392. addresseeMobile: thisdata.addresseeMobile,
  2393. addresseeProvince: thisdata.addresseeProvince,
  2394. addresseeCity: thisdata.addresseeCity,
  2395. addresseeArea: thisdata.addresseeArea,
  2396. alreadyAmount: thisdata.alreadyAmount,
  2397. recipientAddress: thisdata.recipientAddress,
  2398. orgCodeUrl: thisdata.voucherUrl
  2399. ? splitUrl(
  2400. thisdata.voucherUrl,
  2401. ",",
  2402. globalConfig.avatarHost + "/upload"
  2403. )
  2404. : [],
  2405. };
  2406. this.setState({
  2407. modalData: obj,
  2408. });
  2409. }.bind(this),
  2410. }).done(
  2411. function () {
  2412. this.setState({
  2413. loading: false,
  2414. });
  2415. }.bind(this)
  2416. );
  2417. },
  2418. visitCancels() {
  2419. this.setState({
  2420. avisible: false
  2421. })
  2422. },
  2423. selectAuto(value, options) {
  2424. this.setState({
  2425. auto: value,
  2426. });
  2427. },
  2428. selectAuto1(value, options) {
  2429. this.setState({
  2430. auto1: value,
  2431. });
  2432. },
  2433. blurChange(e) {
  2434. let theType = "";
  2435. let contactLists = this.state.customerArr || [];
  2436. if (e) {
  2437. contactLists.map(function (item) {
  2438. if (item.name == e.toString()) {
  2439. theType = item.id;
  2440. }
  2441. });
  2442. }
  2443. this.setState({
  2444. theTypes: theType,
  2445. });
  2446. },
  2447. blurChange1(e) {
  2448. let theType = "";
  2449. let contactLists = this.state.customerArr1 || [];
  2450. if (e) {
  2451. contactLists.map(function (item) {
  2452. if (item.name == e.toString()) {
  2453. theType = item.id;
  2454. }
  2455. });
  2456. }
  2457. this.setState({
  2458. theTypes1: theType,
  2459. });
  2460. },
  2461. httpChange(e) {
  2462. if (e.length >= 1) {
  2463. this.supervisor(e);
  2464. }
  2465. this.setState({
  2466. auto: e,
  2467. });
  2468. },
  2469. httpChange1(e) {
  2470. if (e.length >= 1) {
  2471. this.supervisor1(e);
  2472. }
  2473. this.setState({
  2474. auto1: e,
  2475. });
  2476. },
  2477. supervisor(e) {
  2478. $.ajax({
  2479. method: "get",
  2480. dataType: "json",
  2481. crossDomain: false,
  2482. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  2483. data: {
  2484. adminName: e,
  2485. },
  2486. success: function (data) {
  2487. if (data.error && data.error.length === 0) {
  2488. this.setState({
  2489. customerArr: data.data,
  2490. });
  2491. } else {
  2492. message.warning(data.error[0].message);
  2493. }
  2494. }.bind(this),
  2495. }).always(function () { }.bind(this));
  2496. },
  2497. supervisor1(e) {
  2498. $.ajax({
  2499. method: "get",
  2500. dataType: "json",
  2501. crossDomain: false,
  2502. url: globalConfig.context + "/api/admin/customer/listAdminByName",
  2503. data: {
  2504. adminName: e,
  2505. },
  2506. success: function (data) {
  2507. if (data.error && data.error.length === 0) {
  2508. this.setState({
  2509. customerArr1: data.data,
  2510. });
  2511. } else {
  2512. message.warning(data.error[0].message);
  2513. }
  2514. }.bind(this),
  2515. }).always(function () { }.bind(this));
  2516. },
  2517. render() {
  2518. const formItemLayout = {
  2519. labelCol: { span: 8 },
  2520. wrapperCol: { span: 14 },
  2521. };
  2522. const { RangePicker } = DatePicker;
  2523. var departmentArr = this.state.departmentArr || [];
  2524. const { loading, selectedRowKeys, visible } = this.state;
  2525. const rowSelection = {
  2526. selectedRowKeys,
  2527. onChange: this.onSelectChange,
  2528. hideDefaultSelections: true,
  2529. type: "radio",
  2530. };
  2531. const dataSources = this.state.customerArr || [];
  2532. const dataSources1 = this.state.customerArr1 || [];
  2533. const options = dataSources.map((group) => (
  2534. <Select.Option key={group.id} value={group.name}>
  2535. {group.name}
  2536. </Select.Option>
  2537. ));
  2538. const options1 = dataSources1.map((group) => (
  2539. <Select.Option key={group.id} value={group.name}>
  2540. {group.name}
  2541. </Select.Option>
  2542. ));
  2543. return (
  2544. <div className="user-content">
  2545. {this.state.resVisible ? (
  2546. <ResolutionDetail
  2547. cancel={this.resCancel}
  2548. detail={this.state.resRecord}
  2549. visible={this.state.resVisible}
  2550. id={this.state.resRecord.orderNo}
  2551. />
  2552. ) : (
  2553. ""
  2554. )}
  2555. <div className="content-title" style={{ marginBottom: 10 }}>
  2556. <span style={{ fontWeight: 900, fontSize: 16 }}>收款结算</span>
  2557. </div>
  2558. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  2559. <TabPane tab="更改表格显示数据" key="1">
  2560. <div style={{ marginLeft: 10 }}>
  2561. <ChooseList
  2562. columns={this.state.columns}
  2563. changeFn={this.changeList}
  2564. changeList={this.state.changeList}
  2565. top={55}
  2566. margin={11}
  2567. />
  2568. </div>
  2569. </TabPane>
  2570. <TabPane tab="搜索" key="2">
  2571. <div className="user-search" style={{ padding: "0 20px 0 10px" }}>
  2572. <Input
  2573. style={{ width: 200 }}
  2574. placeholder="订单编号"
  2575. value={this.state.orderNoSearch}
  2576. onChange={(e) => {
  2577. this.setState({ orderNoSearch: e.target.value });
  2578. }}
  2579. />
  2580. <Input
  2581. style={{ width: 200 }}
  2582. placeholder="客户名称"
  2583. value={this.state.nameSearch}
  2584. onChange={(e) => {
  2585. this.setState({ nameSearch: e.target.value });
  2586. }}
  2587. />
  2588. <Cascaders
  2589. ref={node => this.Cascaders = node}
  2590. placeholder="订单部门"
  2591. id="id"
  2592. name="name"
  2593. children="list"
  2594. height={28}
  2595. onSel={(e) => {
  2596. this.setState({
  2597. departmenttList: JSON.stringify(e),
  2598. });
  2599. }}
  2600. />
  2601. {/* <Select
  2602. placeholder="订单部门"
  2603. style={{ width: 190, marginRight: 10 }}
  2604. value={this.state.departmenttList}
  2605. onChange={(e) => {
  2606. this.setState({ departmenttList: e });
  2607. }}
  2608. >
  2609. {departmentArr.map(function (item) {
  2610. return (
  2611. <Select.Option key={item.id}>{item.name}</Select.Option>
  2612. );
  2613. })}
  2614. </Select> */}
  2615. <Input
  2616. style={{ width: 200 }}
  2617. placeholder="合同编号"
  2618. value={this.state.contractNoSearch}
  2619. onChange={(e) => {
  2620. this.setState({
  2621. contractNoSearch: e.target.value,
  2622. });
  2623. }}
  2624. />
  2625. <Select
  2626. placeholder="流程状态"
  2627. onChange={(e) => {
  2628. this.setState({ processStatusSearch: e });
  2629. }}
  2630. style={{ width: 150, marginRight: 10 }}
  2631. value={this.state.processStatusSearch}
  2632. >
  2633. <Option value="3">未分配</Option>
  2634. <Option value="4">已分配</Option>
  2635. <Option value="9">已驳回</Option>
  2636. </Select>
  2637. <Select
  2638. placeholder="结算状态"
  2639. onChange={(e) => {
  2640. this.setState({ liquidationStatus: e });
  2641. }}
  2642. style={{ width: 150, marginRight: 10 }}
  2643. value={this.state.liquidationStatus}
  2644. >
  2645. <Option value="0">首付待付清</Option>
  2646. <Option value="1">尾款待付清</Option>
  2647. <Option value="2">已付清</Option>
  2648. </Select>
  2649. <Select
  2650. style={{ width: 150 }}
  2651. placeholder="签单金额"
  2652. value={this.state.amountStatus}
  2653. onChange={(e) => {
  2654. this.setState({
  2655. amountStatus: e,
  2656. });
  2657. }}
  2658. >
  2659. <Option value="0">10万元以下</Option>
  2660. <Option value="1">10~20万元</Option>
  2661. <Option value="2">20~30万元</Option>
  2662. <Option value="3">30~40万元</Option>
  2663. <Option value="4">40万元以上</Option>
  2664. </Select>
  2665. <Select
  2666. style={{ width: 150 }}
  2667. placeholder="特批状态"
  2668. value={this.state.approval}
  2669. onChange={(e) => {
  2670. this.setState({
  2671. approval: e,
  2672. });
  2673. }}
  2674. >
  2675. <Option value="0">非特批</Option>
  2676. <Option value="1">特批待审</Option>
  2677. <Option value="2">特批通过</Option>
  2678. <Option value="4">全部特批</Option>
  2679. </Select>
  2680. <Select
  2681. style={{ width: 150 }}
  2682. placeholder="会员状态"
  2683. value={this.state.projectType}
  2684. onChange={(e) => {
  2685. this.setState({
  2686. projectType: e,
  2687. });
  2688. }}
  2689. >
  2690. <Option value="1">会员</Option>
  2691. <Option value="0">非会员</Option>
  2692. </Select>
  2693. <span style={{}}>下单日期:</span>
  2694. <RangePicker
  2695. value={[
  2696. this.state.releaseDate[0]
  2697. ? moment(this.state.releaseDate[0])
  2698. : null,
  2699. this.state.releaseDate[1]
  2700. ? moment(this.state.releaseDate[1])
  2701. : null,
  2702. ]}
  2703. onChange={(data, dataString) => {
  2704. this.setState({ releaseDate: dataString });
  2705. }}
  2706. />
  2707. <span style={{ marginLeft: 10 }}>最近收款:</span>
  2708. <RangePicker
  2709. value={[
  2710. this.state.shouKuanDate[0]
  2711. ? moment(this.state.shouKuanDate[0])
  2712. : null,
  2713. this.state.shouKuanDate[1]
  2714. ? moment(this.state.shouKuanDate[1])
  2715. : null,
  2716. ]}
  2717. onChange={(data, dataString) => {
  2718. this.setState({ shouKuanDate: dataString });
  2719. }}
  2720. />
  2721. <Button
  2722. type="primary"
  2723. onClick={this.search}
  2724. style={{ marginLeft: 10 }}
  2725. disabled={this.state.loadingA ? true : false}
  2726. >
  2727. 搜索
  2728. </Button>
  2729. <Button onClick={this.reset}>重置</Button>
  2730. </div>
  2731. </TabPane>
  2732. <TabPane tab="打印" key="3">
  2733. <Button
  2734. type="primary"
  2735. style={{ margin: "11px 0px 10px 10px" }}
  2736. onClick={this.printAll}
  2737. disabled={!this.state.dataSource.length}
  2738. >
  2739. 打印所有列表信息
  2740. </Button>
  2741. <Button
  2742. type="primary"
  2743. disabled={this.state.selectedRowKeys.length != 1}
  2744. style={{ margin: "11px 0px 10px 10px" }}
  2745. onClick={() => {
  2746. this.inRecordData();
  2747. this.setState({
  2748. bvisible: true,
  2749. });
  2750. }}
  2751. >
  2752. 打印开票详情
  2753. </Button>
  2754. <Button
  2755. type="primary"
  2756. disabled={this.state.selectedRowKeys.length != 1}
  2757. style={{ margin: "11px 0px 10px 10px" }}
  2758. onClick={() => {
  2759. this.waterData();
  2760. this.setState({
  2761. cvisible: true,
  2762. });
  2763. }}
  2764. >
  2765. 打印收款流水
  2766. </Button>
  2767. <Button
  2768. type="primary"
  2769. disabled={this.state.selectedRowKeys.length != 1}
  2770. style={{ margin: "11px 0px 10px 10px" }}
  2771. onClick={() => {
  2772. this.timeData();
  2773. this.setState({
  2774. timeVisible: true,
  2775. });
  2776. }}
  2777. >
  2778. 打印工时信息
  2779. </Button>
  2780. <Button
  2781. type="primary"
  2782. disabled={this.state.selectedRowKeys.length != 1}
  2783. style={{ margin: "11px 0px 10px 10px" }}
  2784. onClick={() => {
  2785. this.cuiData();
  2786. this.setState({
  2787. cuiVisible: true,
  2788. });
  2789. }}
  2790. >
  2791. 打印催款信息
  2792. </Button>
  2793. <Button
  2794. type="primary"
  2795. disabled={this.state.selectedRowKeys.length != 1}
  2796. style={{ margin: "11px 0px 10px 10px" }}
  2797. onClick={() => {
  2798. this.proData();
  2799. this.setState({
  2800. proVisible: true,
  2801. });
  2802. }}
  2803. >
  2804. 打印项目进度
  2805. </Button>
  2806. </TabPane>
  2807. <TabPane tab="导出Excel" key="4">
  2808. <Button
  2809. type="primary"
  2810. style={{ margin: "11px 0px 10px 10px" }}
  2811. onClick={this.exportAll}
  2812. >
  2813. 导出当前列表
  2814. </Button>
  2815. <Button
  2816. type="primary"
  2817. disabled={this.state.selectedRowKeys.length != 1}
  2818. style={{ margin: "11px 0px 10px 10px" }}
  2819. onClick={this.exportKaip}
  2820. >
  2821. 导出所选开票详情
  2822. </Button>
  2823. <Button
  2824. type="primary"
  2825. disabled={this.state.selectedRowKeys.length != 1}
  2826. style={{ margin: "11px 0px 10px 10px" }}
  2827. onClick={this.exportWater}
  2828. >
  2829. 导出所选收款详情流水
  2830. </Button>
  2831. <Button
  2832. type="primary"
  2833. disabled={this.state.selectedRowKeys.length != 1}
  2834. style={{ margin: "11px 0px 10px 10px" }}
  2835. onClick={this.exportTime}
  2836. >
  2837. 导出所选工时信息
  2838. </Button>
  2839. <Button
  2840. type="primary"
  2841. disabled={this.state.selectedRowKeys.length != 1}
  2842. style={{ margin: "11px 0px 10px 10px" }}
  2843. onClick={this.exportCui}
  2844. >
  2845. 导出催款信息
  2846. </Button>
  2847. <Button
  2848. type="primary"
  2849. disabled={this.state.selectedRowKeys.length != 1}
  2850. style={{ margin: "11px 0px 10px 10px" }}
  2851. onClick={this.exportPro}
  2852. >
  2853. 导出项目进度
  2854. </Button>
  2855. </TabPane>
  2856. <TabPane tab="查看" key="5">
  2857. <Button
  2858. type="primary"
  2859. disabled={this.state.selectedRowKeys.length != 1}
  2860. style={{ margin: "11px 0px 10px 10px" }}
  2861. onClick={() => {
  2862. this.inRecordData();
  2863. this.setState({
  2864. bvisible: true,
  2865. });
  2866. }}
  2867. >
  2868. 查看开票详情
  2869. </Button>
  2870. <Button
  2871. type="primary"
  2872. disabled={this.state.selectedRowKeys.length != 1}
  2873. style={{ margin: "11px 0px 10px 10px" }}
  2874. onClick={() => {
  2875. this.waterData();
  2876. this.setState({
  2877. cvisible: true,
  2878. });
  2879. }}
  2880. >
  2881. 详情收款流水
  2882. </Button>
  2883. <Button
  2884. type="primary"
  2885. disabled={this.state.selectedRowKeys.length != 1}
  2886. style={{ margin: "11px 0px 10px 10px" }}
  2887. onClick={() => {
  2888. this.timeData();
  2889. this.setState({
  2890. timeVisible: true,
  2891. });
  2892. }}
  2893. >
  2894. 工时信息
  2895. </Button>
  2896. <Button
  2897. type="primary"
  2898. disabled={this.state.selectedRowKeys.length != 1}
  2899. style={{ margin: "11px 0px 10px 10px" }}
  2900. onClick={() => {
  2901. this.cuiData();
  2902. this.setState({
  2903. cuiVisible: true,
  2904. });
  2905. }}
  2906. >
  2907. 催款信息
  2908. </Button>
  2909. <Button
  2910. type="primary"
  2911. disabled={this.state.selectedRowKeys.length != 1}
  2912. style={{ margin: "11px 0px 10px 10px" }}
  2913. onClick={() => {
  2914. this.proData();
  2915. this.setState({
  2916. proVisible: true,
  2917. });
  2918. }}
  2919. >
  2920. 项目进度
  2921. </Button>
  2922. <Button
  2923. type="primary"
  2924. disabled={this.state.selectedRowKeys.length != 1}
  2925. style={{ margin: "11px 0px 10px 10px" }}
  2926. onClick={() => {
  2927. this.pubData();
  2928. this.selectSuperId();
  2929. this.setState({
  2930. pubVisible: true,
  2931. });
  2932. }}
  2933. >
  2934. 查看公出
  2935. </Button>
  2936. </TabPane>
  2937. {/* <TabPane tab="批量操作" key="6">
  2938. <Button
  2939. type="primary"
  2940. disabled={this.state.selectedRowKeys.length == 0}
  2941. style={{ margin: "0px 0px 10px 10px" }}
  2942. onClick={e => {
  2943. e.stopPropagation(),
  2944. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  2945. }}
  2946. >
  2947. 转交
  2948. </Button>
  2949. </TabPane> */}
  2950. </Tabs>
  2951. <div className="patent-table">
  2952. <Spin spinning={this.state.loadingA}>
  2953. <Table
  2954. bordered
  2955. columns={
  2956. this.state.changeList == undefined
  2957. ? this.state.columns
  2958. : this.state.changeList
  2959. }
  2960. dataSource={this.state.dataSource}
  2961. rowSelection={rowSelection}
  2962. scroll={{ x: "max-content", y: 0 }}
  2963. pagination={this.state.pagination}
  2964. onRowDoubleClick={this.tableRowClick.bind(this)}
  2965. size="small"
  2966. />
  2967. </Spin>
  2968. <p
  2969. style={{ display: "inline-block", fontSize: "14px", color: "red" }}
  2970. >
  2971. {
  2972. <span style={{ marginRight: 10 }}>
  2973. {`收款金额总计(万元):${this.state.hui ? this.state.hui : "0"}`}
  2974. </span>
  2975. }
  2976. {
  2977. <span>
  2978. {`合同额总计(万元):${this.state.totalHui ? this.state.totalHui : "0"
  2979. }`}
  2980. </span>
  2981. }
  2982. </p>
  2983. </div>
  2984. <Assign
  2985. title="任务"
  2986. selApi={"/api/admin/newOrder/updateFinance"}
  2987. data={this.state.assignDataY}
  2988. showDesc={this.state.assignVisibleY}
  2989. closeDesc={this.closeAssignY.bind(this)}
  2990. // fenpaiData={8}
  2991. specially={0}
  2992. roleName={this.state.nub}
  2993. requestMethod={"get"}
  2994. />
  2995. <OrderDesc
  2996. data={this.state.RowData}
  2997. showDesc={this.state.showDesc}
  2998. closeDesc={this.closeDesc.bind(this)}
  2999. />
  3000. <Receivable
  3001. title="收款记录"
  3002. api="/api/admin/financial/addReceiptsFlow"
  3003. data={this.state.assignDataX}
  3004. showDesc={this.state.assignVisibleX}
  3005. closeDesc={this.closeAssignX.bind(this)}
  3006. />
  3007. <Modal
  3008. visible={this.state.boHuiVisible}
  3009. width="400px"
  3010. title="驳回备注"
  3011. footer=""
  3012. onOk={this.boHuiOk}
  3013. onCancel={this.boHuiCancel}
  3014. >
  3015. <Form layout="horizontal" onSubmit={this.boHuiSubmit}>
  3016. <Spin spinning={this.state.loading}>
  3017. <FormItem
  3018. labelCol={{ span: 5 }}
  3019. wrapperCol={{ span: 16 }}
  3020. label={
  3021. <span>
  3022. <strong style={{ color: "#f00" }}>*</strong>驳回原因
  3023. </span>
  3024. }
  3025. >
  3026. <Input
  3027. type="textarea"
  3028. rows={4}
  3029. placeholder="请输入驳回原因"
  3030. value={this.state.content}
  3031. onChange={(e) => {
  3032. this.setState({ content: e.target.value });
  3033. }}
  3034. />
  3035. </FormItem>
  3036. <FormItem wrapperCol={{ span: 12, offset: 5 }}>
  3037. <Button
  3038. type="primary"
  3039. htmlType="submit"
  3040. style={{ marginRight: 20 }}
  3041. >
  3042. 驳回
  3043. </Button>
  3044. <Button
  3045. type="default"
  3046. onClick={() => {
  3047. this.boHuiCancel();
  3048. }}
  3049. >
  3050. 取消
  3051. </Button>
  3052. </FormItem>
  3053. </Spin>
  3054. </Form>
  3055. </Modal>
  3056. <Modal
  3057. visible={this.state.bvisible}
  3058. footer=""
  3059. title="开票历史记录"
  3060. className="admin-desc-content"
  3061. width="1200px"
  3062. onCancel={this.inRecordCanl}
  3063. >
  3064. <Spin spinning={this.state.loading}>
  3065. <div
  3066. className="patent-table"
  3067. ref={(e) => {
  3068. this.refs.kaiPiao = e;
  3069. }}
  3070. >
  3071. <Table
  3072. columns={this.state.columnsDate}
  3073. dataSource={this.state.recordData}
  3074. onRowClick={this.kaiPiaoData}
  3075. pagination={false}
  3076. bordered
  3077. size="small"
  3078. />
  3079. <div className="clearfix" style={{ marginTop: "20px" }}>
  3080. <FormItem
  3081. className="half-item"
  3082. {...formItemLayout}
  3083. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  3084. >
  3085. <span>{this.state.sum + "(万元)"}</span>
  3086. </FormItem>
  3087. </div>
  3088. <ReactToPrint
  3089. trigger={() => (
  3090. <Button
  3091. type="primary"
  3092. style={{
  3093. float: "right",
  3094. // marginTop: 10,
  3095. position: "absolute",
  3096. top: -54,
  3097. right: 30,
  3098. }}
  3099. >
  3100. 打印
  3101. </Button>
  3102. )}
  3103. content={() => this.refs.kaiPiao}
  3104. />
  3105. </div>
  3106. </Spin>
  3107. </Modal>
  3108. <Modal
  3109. visible={this.state.cvisible}
  3110. footer=""
  3111. title="详细收款流水"
  3112. className="admin-desc-content"
  3113. width="1300px"
  3114. onCancel={this.waterCanl}
  3115. >
  3116. <Spin spinning={this.state.loading}>
  3117. <div
  3118. className="patent-table"
  3119. ref={(e) => {
  3120. this.refs.shouKuan = e;
  3121. }}
  3122. >
  3123. <Table
  3124. columns={this.state.waterlistDate}
  3125. dataSource={this.state.waterData}
  3126. pagination={false}
  3127. scroll={{ x: "max-content", y: 0 }}
  3128. bordered
  3129. size="small"
  3130. />
  3131. <div className="clearfix" style={{ marginTop: "20px" }}>
  3132. <FormItem
  3133. className="half-item"
  3134. {...formItemLayout}
  3135. label={<span style={{ fontSize: "14px" }}>总计金额</span>}
  3136. >
  3137. <span>{this.state.waterSum + "(万元)"}</span>
  3138. </FormItem>
  3139. </div>
  3140. <ReactToPrint
  3141. trigger={() => (
  3142. <Button
  3143. type="primary"
  3144. style={{
  3145. float: "right",
  3146. position: "absolute",
  3147. top: -54,
  3148. right: 30,
  3149. }}
  3150. >
  3151. 打印
  3152. </Button>
  3153. )}
  3154. content={() => this.refs.shouKuan}
  3155. />
  3156. </div>
  3157. </Spin>
  3158. </Modal>
  3159. <Modal
  3160. visible={this.state.dvisible}
  3161. footer=""
  3162. title="所有列表信息"
  3163. className="admin-desc-content"
  3164. width="1300px"
  3165. onCancel={() => {
  3166. this.loadData();
  3167. this.setState({
  3168. dvisible: false,
  3169. });
  3170. }}
  3171. >
  3172. <Spin spinning={this.state.loading}>
  3173. <div
  3174. className="patent-table"
  3175. style={{
  3176. // width: 900,
  3177. // position: "relative",
  3178. // left: "50%",
  3179. // transform: "translate(-50%)",
  3180. padding: "25px 0 30px 30px",
  3181. }}
  3182. ref={(e) => {
  3183. this.refs.all = e;
  3184. }}
  3185. >
  3186. <Table
  3187. columns={this.state.printColumns}
  3188. dataSource={this.state.dataSource}
  3189. pagination={false}
  3190. bordered
  3191. size="small"
  3192. />
  3193. </div>
  3194. </Spin>
  3195. <ReactToPrint
  3196. trigger={() => (
  3197. <Button
  3198. type="primary"
  3199. style={{
  3200. float: "right",
  3201. marginTop: 10,
  3202. position: "absolute",
  3203. top: 0,
  3204. right: 30,
  3205. }}
  3206. >
  3207. 打印
  3208. </Button>
  3209. )}
  3210. content={() => this.refs.all}
  3211. />
  3212. </Modal>
  3213. <Project
  3214. record={this.state.record}
  3215. visible={this.state.pvisible}
  3216. isAuditPayment={true}
  3217. cancel={() => {
  3218. this.setState({ pvisible: false });
  3219. }}
  3220. />
  3221. {/* 工时详情 */}
  3222. <Modal
  3223. visible={this.state.timeVisible}
  3224. footer=""
  3225. title="工时详情"
  3226. className="admin-desc-content"
  3227. width="1300px"
  3228. pagination={false}
  3229. onCancel={() => {
  3230. this.loadData();
  3231. this.setState({
  3232. timeVisible: false,
  3233. });
  3234. }}
  3235. >
  3236. <Spin spinning={this.state.loading}>
  3237. <div
  3238. className="patent-table"
  3239. style={
  3240. {
  3241. // width: 900,
  3242. // position: "relative",
  3243. // left: "50%",
  3244. // transform: "translate(-50%)",
  3245. // padding: "25px 0 30px 30px"
  3246. }
  3247. }
  3248. ref={(e) => {
  3249. this.refs.all = e;
  3250. }}
  3251. >
  3252. <Table
  3253. columns={this.state.timeColumns}
  3254. dataSource={this.state.timeDataList}
  3255. onRowClick={this.tableRowClickPro}
  3256. scroll={{ x: "max-content", y: 0 }}
  3257. pagination={false}
  3258. bordered
  3259. size="small"
  3260. />
  3261. </div>
  3262. </Spin>
  3263. <ReactToPrint
  3264. trigger={() => (
  3265. <Button
  3266. type="primary"
  3267. style={{
  3268. float: "right",
  3269. marginTop: 10,
  3270. position: "absolute",
  3271. top: 0,
  3272. right: 30,
  3273. }}
  3274. >
  3275. 打印
  3276. </Button>
  3277. )}
  3278. content={() => this.refs.all}
  3279. />
  3280. </Modal>
  3281. {/* 催款详情 */}
  3282. <Modal
  3283. visible={this.state.cuiVisible}
  3284. footer=""
  3285. title="催款详情"
  3286. className="admin-desc-content"
  3287. width="1300px"
  3288. pagination={false}
  3289. onCancel={() => {
  3290. this.loadData();
  3291. this.setState({
  3292. cuiVisible: false,
  3293. cuiTabKey: "1",
  3294. });
  3295. }}
  3296. >
  3297. <Tabs activeKey={this.state.cuiTabKey} onChange={this.cuiTabChange}>
  3298. <TabPane tab="催款节点" key="1">
  3299. <Spin spinning={this.state.loading}>
  3300. <div
  3301. className="patent-table"
  3302. ref={(e) => {
  3303. this.refs.all = e;
  3304. }}
  3305. >
  3306. <Table
  3307. columns={this.state.cuiColumns}
  3308. dataSource={this.state.cuiDataList}
  3309. scroll={{ x: "max-content", y: 0 }}
  3310. pagination={false}
  3311. bordered
  3312. size="small"
  3313. />
  3314. </div>
  3315. <ReactToPrint
  3316. trigger={() => (
  3317. <Button
  3318. type="primary"
  3319. style={{
  3320. float: "right",
  3321. marginTop: 10,
  3322. position: "absolute",
  3323. top: "-60px",
  3324. right: 30,
  3325. }}
  3326. >
  3327. 打印
  3328. </Button>
  3329. )}
  3330. content={() => this.refs.all}
  3331. />
  3332. </Spin>
  3333. </TabPane>
  3334. <TabPane tab="欠款催收记录" key="2">
  3335. <Spin spinning={this.state.loading}>
  3336. <div
  3337. className="patent-table"
  3338. ref={(e) => {
  3339. this.refs.all = e;
  3340. }}
  3341. >
  3342. <Table
  3343. columns={this.state.qianColumns}
  3344. dataSource={this.state.qianDataList}
  3345. scroll={{ x: "max-content", y: 0 }}
  3346. pagination={false}
  3347. bordered
  3348. size="small"
  3349. />
  3350. </div>
  3351. <ReactToPrint
  3352. trigger={() => (
  3353. <Button
  3354. type="primary"
  3355. style={{
  3356. float: "right",
  3357. marginTop: 10,
  3358. position: "absolute",
  3359. top: "-60px",
  3360. right: 30,
  3361. }}
  3362. >
  3363. 打印
  3364. </Button>
  3365. )}
  3366. content={() => this.refs.all}
  3367. />
  3368. </Spin>
  3369. </TabPane>
  3370. </Tabs>
  3371. </Modal>
  3372. {/* 项目进度 */}
  3373. <Modal
  3374. visible={this.state.proVisible}
  3375. footer=""
  3376. title="项目进度"
  3377. className="admin-desc-content"
  3378. width="1300px"
  3379. pagination={false}
  3380. onCancel={() => {
  3381. this.loadData(this.state.page);
  3382. this.setState({
  3383. proVisible: false,
  3384. });
  3385. }}
  3386. >
  3387. <Spin spinning={this.state.loading}>
  3388. <div
  3389. className="patent-table"
  3390. ref={(e) => {
  3391. this.refs.all = e;
  3392. }}
  3393. >
  3394. <Table
  3395. columns={this.state.proColumns}
  3396. dataSource={this.state.proDataList}
  3397. scroll={{ x: "max-content", y: 0 }}
  3398. onRowClick={this.tableRowClickPro}
  3399. pagination={false}
  3400. bordered
  3401. size="small"
  3402. />
  3403. </div>
  3404. <span style={{ display: "block", marginTop: 10, color: "red" }}>
  3405. 外包(内部)价格总计(万元):{this.state.totalWaibao}
  3406. </span>
  3407. </Spin>
  3408. <ReactToPrint
  3409. trigger={() => (
  3410. <Button
  3411. type="primary"
  3412. style={{
  3413. float: "right",
  3414. marginTop: 10,
  3415. position: "absolute",
  3416. top: 0,
  3417. right: 30,
  3418. }}
  3419. >
  3420. 打印
  3421. </Button>
  3422. )}
  3423. content={() => this.refs.all}
  3424. />
  3425. </Modal>
  3426. {/* 查看公出 */}
  3427. <Modal
  3428. visible={this.state.pubVisible}
  3429. footer=""
  3430. title={<span>公出详细列表(
  3431. {this.state.selectedRows.length > 0 && this.state.selectedRows[0].buyerName}
  3432. )</span>}
  3433. className="admin-desc-content"
  3434. width="1500px"
  3435. pagination={false}
  3436. onCancel={() => {
  3437. this.pubData();
  3438. this.setState({
  3439. pubVisible: false,
  3440. });
  3441. }}
  3442. >
  3443. <div
  3444. className="user-search"
  3445. style={{
  3446. marginTop: "10px",
  3447. marginLeft: "10px",
  3448. marginRight: "10px",
  3449. }}
  3450. >
  3451. <span style={{ marginRight: "10px" }}>
  3452. <Select
  3453. placeholder="请选择审核状态"
  3454. style={{ width: 120 }}
  3455. value={this.state.status}
  3456. onChange={(e) => {
  3457. this.setState({ status: e });
  3458. }}
  3459. >
  3460. {clockState.map((v, k) => (
  3461. <Select.Option key={k} value={v.id}>
  3462. {v.title}
  3463. </Select.Option>
  3464. ))}
  3465. </Select>
  3466. </span>
  3467. <span style={{ marginRight: "10px" }}>
  3468. <Select
  3469. placeholder="请选择打卡状态"
  3470. style={{ width: 120 }}
  3471. value={this.state.clockIn}
  3472. onChange={(e) => {
  3473. this.setState({ clockIn: e });
  3474. }}
  3475. >
  3476. <Select.Option value={1}>已打卡</Select.Option>
  3477. <Select.Option value={0}>未打卡</Select.Option>
  3478. </Select>
  3479. </span>
  3480. <span style={{ marginRight: "10px" }}>
  3481. <Select
  3482. placeholder="请选择公出类型"
  3483. style={{ width: 120 }}
  3484. value={this.state.type}
  3485. onChange={(e) => {
  3486. this.setState({ type: e });
  3487. }}
  3488. >
  3489. <Select.Option value={0}>业务打卡</Select.Option>
  3490. <Select.Option value={1}>技术打卡</Select.Option>
  3491. <Select.Option value={2}>行政打卡</Select.Option>
  3492. <Select.Option value={3}>技术协单</Select.Option>
  3493. </Select>
  3494. </span>
  3495. <span style={{ marginRight: "10px" }}>
  3496. <AutoComplete
  3497. className="certain-category-search"
  3498. dropdownClassName="certain-category-search-dropdown"
  3499. dropdownMatchSelectWidth={false}
  3500. style={{ width: "120px" }}
  3501. dataSource={options}
  3502. placeholder="输入公出申请人"
  3503. value={this.state.auto}
  3504. onChange={this.httpChange}
  3505. filterOption={true}
  3506. onBlur={this.blurChange}
  3507. onSelect={this.selectAuto}
  3508. >
  3509. <Input />
  3510. </AutoComplete>
  3511. </span>
  3512. <span style={{ marginRight: "10px" }}>
  3513. <AutoComplete
  3514. className="certain-category-search"
  3515. dropdownClassName="certain-category-search-dropdown"
  3516. dropdownMatchSelectWidth={false}
  3517. style={{ width: "120px" }}
  3518. dataSource={options1}
  3519. placeholder="输入跟单人"
  3520. value={this.state.auto1}
  3521. onChange={this.httpChange1}
  3522. filterOption={true}
  3523. onBlur={this.blurChange1}
  3524. onSelect={this.selectAuto1}
  3525. >
  3526. <Input />
  3527. </AutoComplete>
  3528. </span>
  3529. <span style={{ marginRight: "10px" }}>
  3530. <Select
  3531. placeholder="请选择公出部门"
  3532. style={{ width: 200 }}
  3533. value={this.state.depId}
  3534. onChange={(e) => {
  3535. this.setState({ depId: e });
  3536. }}
  3537. notFoundContent="未获取到上级组织列表"
  3538. >
  3539. {this.state.contactsOption}
  3540. </Select>
  3541. </span>
  3542. <span style={{ marginRight: "10px" }}>
  3543. <span style={{ marginRight: "5px", marginBottom: "10px" }}>
  3544. 公出时间 :
  3545. </span>
  3546. <RangePicker
  3547. style={{ marginRight: "10px", marginBottom: "10px" }}
  3548. value={[
  3549. this.state.releaseDate[0]
  3550. ? moment(this.state.releaseDate[0])
  3551. : null,
  3552. this.state.releaseDate[1]
  3553. ? moment(this.state.releaseDate[1])
  3554. : null,
  3555. ]}
  3556. onChange={(data, dataString) => {
  3557. this.setState({ releaseDate: dataString });
  3558. }}
  3559. />
  3560. </span>
  3561. <Button
  3562. type="primary"
  3563. onClick={() => {
  3564. this.pubData();
  3565. }}
  3566. style={{ marginRight: "10px", marginBottom: "10px" }}
  3567. >
  3568. 搜索
  3569. </Button>
  3570. <Button
  3571. onClick={this.resetAll}
  3572. style={{ marginRight: "10px", marginBottom: "10px" }}
  3573. >
  3574. 重置
  3575. </Button>
  3576. </div>
  3577. <Spin spinning={this.state.loading}>
  3578. <div
  3579. className="patent-table"
  3580. ref={(e) => {
  3581. this.refs.all = e;
  3582. }}
  3583. >
  3584. <Table
  3585. columns={this.state.pubColumns}
  3586. dataSource={this.state.pubDataList}
  3587. scroll={{ x: "max-content", y: 0 }}
  3588. pagination={false}
  3589. bordered
  3590. size="small"
  3591. />
  3592. </div>
  3593. </Spin>
  3594. <Button
  3595. type="primary"
  3596. style={{
  3597. float: "right",
  3598. marginTop: 10,
  3599. position: "absolute",
  3600. top: 0,
  3601. right: 120,
  3602. }}
  3603. loading={this.state.exportPendingLoading}
  3604. onClick={() => { this.pubexportExec() }}
  3605. >
  3606. 导出
  3607. </Button>
  3608. <ReactToPrint
  3609. trigger={() => (
  3610. <Button
  3611. type="primary"
  3612. style={{
  3613. float: "right",
  3614. marginTop: 10,
  3615. position: "absolute",
  3616. top: 0,
  3617. right: 30,
  3618. }}
  3619. >
  3620. 打印
  3621. </Button>
  3622. )}
  3623. content={() => this.refs.all}
  3624. />
  3625. </Modal>
  3626. <Spin spinning={this.state.loading}>
  3627. {this.state.checkVisible ? <Modal
  3628. title="审核订单"
  3629. visible={this.state.checkVisible}
  3630. onOk={this.checkOk}
  3631. confirmLoading={this.state.loading}
  3632. okText={"通过"}
  3633. onCancel={() => {
  3634. this.state.financeApprovalAjaxObj ? this.state.financeApprovalAjaxObj.abort() : null;
  3635. this.setState({
  3636. financeApprovalAjaxObj: null
  3637. })
  3638. this.loadData();
  3639. this.setState({
  3640. checkVisible: false,
  3641. checkData: "",
  3642. });
  3643. }}
  3644. >
  3645. <TextArea
  3646. value={this.state.checkData}
  3647. onChange={(e, recard) => {
  3648. this.setState({
  3649. checkData: e.target.value,
  3650. });
  3651. }}
  3652. placeholder="请填写审核内容"
  3653. />
  3654. </Modal> : <div />}
  3655. </Spin>
  3656. <KaiPiaoModal
  3657. visible={this.state.avisible}
  3658. data={this.state.modalData}
  3659. onCancel={this.visitCancels}
  3660. loading={this.state.loading}
  3661. />
  3662. <textarea id="copyText" style={{ opacity: 0 }} />
  3663. </div>
  3664. );
  3665. },
  3666. });
  3667. export default ShouKuang;