inquiry.jsx 152 KB

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