inquiry.jsx 151 KB

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