inquiry.jsx 149 KB

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