myTask.jsx 214 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134
  1. import React from 'react'
  2. import $ from 'jquery'
  3. import moment from 'moment'
  4. import Picture from '@/manageCenter/publicComponent/picture'
  5. import '@/manageCenter/financialManage/distribute/public.less'
  6. import '@/manageCenter/financialManage/distribute/shouKuan.less'
  7. import OrderDetail from '../../order/orderNew/changeComponent/orderDetail'
  8. import ResolutionDetail from '@/resolutionDetail'
  9. import {Button,
  10. Form,
  11. Input,
  12. Select,
  13. Spin,
  14. Table,
  15. message,
  16. DatePicker,
  17. Modal,
  18. Radio,
  19. Cascader,
  20. Popconfirm,
  21. Switch,
  22. Tabs,
  23. Col,
  24. Icon,
  25. Upload,
  26. AutoComplete,
  27. Tag, Row,
  28. } from 'antd'
  29. import Assign from '@/manageCenter/publicComponent/assign'
  30. import { areaSelect } from '@/NewDicProvinceList'
  31. import { ChooseList } from '../../order/orderNew/chooseList'
  32. import OrderRiZi from '@/orderRiZi.jsx'
  33. import './table.less'
  34. import {getMaterialStatus,
  35. getUrgentStatus,
  36. getProcessStatus,
  37. getApproval,
  38. getTaskStatus,
  39. getLiquidationStatus,
  40. getProjectStatus,
  41. splitUrl,
  42. getboutique,
  43. ShowModal,
  44. getRefundStatus,} from '@/tools'
  45. import { taskStatus, projectStatus, cuiJieDian } from '@/dataDic.js'
  46. import ShowModalDiv from '@/showModal.jsx'
  47. import CheckProject from '../../components/checkProject';
  48. import NewSupplier from './newSupplier';
  49. import ImgList from "../../../common/imgList";
  50. import OperationPayNode from "./operationPayNode";
  51. import {object} from "prop-types";
  52. const confirm = Modal.confirm
  53. const FormItem = Form.Item
  54. const { TabPane } = Tabs
  55. const { TextArea } = Input
  56. const { Option } = Select
  57. const { MonthPicker, RangePicker } = DatePicker
  58. const PicturesWall = React.createClass({
  59. getInitialState() {
  60. return {
  61. previewVisible: false,
  62. previewImage: '',
  63. fileList: [],
  64. }
  65. },
  66. handleCancel() {
  67. this.setState({
  68. previewVisible: false,
  69. })
  70. },
  71. handlePreview(file) {
  72. this.setState({
  73. previewImage: file.url || file.thumbUrl,
  74. previewVisible: true,
  75. })
  76. },
  77. handleChange(info) {
  78. let fileList = info.fileList
  79. this.setState({
  80. fileList,
  81. })
  82. this.props.fileList(fileList)
  83. },
  84. componentWillReceiveProps(nextProps) {
  85. this.state.fileList = nextProps.pictureUrl
  86. this.state.pojectApplicationUrl = undefined
  87. },
  88. render() {
  89. const { previewVisible, previewImage, fileList } = this.state
  90. const uploadButton = (
  91. <div>
  92. <Icon type="plus" />
  93. <div className="ant-upload-text">点击上传</div>
  94. </div>
  95. )
  96. return (
  97. <div style={{ display: 'inline-block' }}>
  98. <Upload
  99. action={
  100. globalConfig.context + '/api/admin/outsourceOrg/uploadOutsourceFile'
  101. }
  102. multiple
  103. data={{ sign: 'order_outsource' }}
  104. listType="picture-card"
  105. fileList={fileList}
  106. onPreview={this.handlePreview}
  107. onChange={this.handleChange}
  108. >
  109. {uploadButton}
  110. </Upload>
  111. <Modal
  112. maskClosable={false}
  113. visible={previewVisible}
  114. footer={null}
  115. onCancel={this.handleCancel}
  116. >
  117. <img alt="example" style={{ width: '100%' }} src={previewImage} />
  118. </Modal>
  119. </div>
  120. )
  121. },
  122. })
  123. const Task = React.createClass({
  124. loadData(pageNo) {
  125. this.state.data = []
  126. this.setState({
  127. page: pageNo,
  128. loading: true,
  129. })
  130. $.ajax({
  131. method: 'get',
  132. dataType: 'json',
  133. crossDomain: false,
  134. url: globalConfig.context + '/api/admin/orderProject/orderTaskList',
  135. data: {
  136. pageNo: pageNo || 1,
  137. pageSize: this.state.pagination.pageSize,
  138. specially: 0, //个人
  139. name: this.state.nameSearch, //客户名称
  140. depId: this.state.departmenttSearch, //订单部门
  141. orderNo: this.state.orderNoSearch, //订单编号
  142. contractNo: this.state.contractNoSearch, //合同编号
  143. taskId: this.state.taskNoSearch, //项目编号
  144. taskStatus: this.state.taskStatuSearch, //项目状态
  145. projectStatus: this.state.projectStatusSearch, //项目状态
  146. adminName: this.state.adminName, //项目受理人
  147. approval: this.state.approvalSearch, //特批状态搜索
  148. outsourceStatus:
  149. this.state.outsourceStatusSearch >= 999
  150. ? undefined
  151. : this.state.outsourceStatusSearch, //外包状态搜索
  152. },
  153. success: function (data) {
  154. ShowModal(this)
  155. let theArr = []
  156. if (!data.data || !data.data.list) {
  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. thisdata.key = i;
  164. thisdata.userName = thisdata.taskName.substring(0, 5) === '软件著作权'
  165. ? thisdata.userName +
  166. '(' +
  167. thisdata.commodityQuantity.toString() +
  168. '/' +
  169. thisdata.alreadyNumber +
  170. ')'
  171. : thisdata.userName;
  172. theArr.push(thisdata)
  173. }
  174. }
  175. this.state.pagination.current = data.data.pageNo
  176. this.state.pagination.total = data.data.totalCount
  177. if (data.data && data.data.list && !data.data.list.length) {
  178. this.state.pagination.current = 0
  179. this.state.pagination.total = 0
  180. }
  181. this.setState({
  182. dataSource: theArr,
  183. pagination: this.state.pagination,
  184. })
  185. }.bind(this),
  186. }).always(
  187. function () {
  188. this.setState({
  189. loading: false,
  190. })
  191. }.bind(this)
  192. )
  193. },
  194. getInitialState() {
  195. return {
  196. audit: 1,
  197. projectType: '', //项目分类
  198. paySubject: [],
  199. paySubjectName: '', //付款科目名称
  200. PayNodeCompany: [],
  201. thirdMaterial: 0, //第三方信息材料 0-无 1-有
  202. thirdUrgent: 0, //第三方信息加急状态
  203. thirdCompanyName: '',
  204. thirdUnitPrice: '',
  205. currentCompanyName: '', //当前选中供应商名称
  206. thirdQuantity: 1,
  207. payNodeQuantity: 1,
  208. thirdRemarks: '',
  209. customerArr: [],
  210. currentTotalPrice: 0, //当前修改页面的总价
  211. saveThirdList: [],
  212. orderData: [],
  213. orderNo: '',
  214. jiedian: [],
  215. jiedianNew: [],
  216. timeVisible: false,
  217. ThirdListVisible: false,
  218. PayNodeVisible: false, //新增付款节点
  219. searchMore: true,
  220. assignVisible: false,
  221. releaseDate: [],
  222. patentType: -1,
  223. patentNameType: -1,
  224. startType: 0, //外包供应商类型
  225. // 判断是否是退回给咨询师经理
  226. flag: false,
  227. roleName: '',
  228. activeKey: '1',
  229. //特批状态搜索
  230. approvalSearch: undefined,
  231. testFlag: true,
  232. boHuivisible: false,
  233. selectedRowKeys: [],
  234. avisible: false,
  235. departmentArr: [],
  236. selectedRows: [],
  237. attachmentUrl: [],
  238. contactList: [],
  239. paginations: false,
  240. loading: false,
  241. pagination: {
  242. defaultCurrent: 1,
  243. defaultPageSize: 10,
  244. showQuickJumper: true,
  245. pageSize: 10,
  246. onChange: function (page) {
  247. this.loadData(page)
  248. }.bind(this),
  249. showTotal: function (total) {
  250. return '共' + total + '条数据'
  251. },
  252. },
  253. // 子组件改变的表格title数组
  254. changeList: undefined,
  255. columnsTime: [
  256. {
  257. title: '工作时长(小时)',
  258. dataIndex: 'hours',
  259. key: 'hours',
  260. },
  261. {
  262. title: '工作时间',
  263. dataIndex: 'taskDays',
  264. key: 'taskDays',
  265. },
  266. // {
  267. // title: "项目负责人",
  268. // dataIndex: "remarks",
  269. // key: "remarks"
  270. // },
  271. {
  272. title: '备注',
  273. dataIndex: 'remarks',
  274. key: 'remarks',
  275. },
  276. ],
  277. columns: [
  278. {
  279. title: '项目编号',
  280. dataIndex: 'id',
  281. key: 'id',
  282. render: (text, record) => {
  283. if (record.splitStatus == 2) {
  284. return <span>{record.splitSuper + '-' + record.splitId}</span>
  285. } else {
  286. return text
  287. }
  288. },
  289. },
  290. {
  291. title: '项目名称',
  292. dataIndex: 'taskName',
  293. key: 'taskName',
  294. render: (text) => {
  295. return text && text.length > 8 ? text.substr(0, 8) + '…' : text
  296. },
  297. },
  298. {
  299. title: '项目数量',
  300. dataIndex: 'commodityQuantity',
  301. key: 'commodityQuantity',
  302. },
  303. {
  304. title: '订单编号',
  305. dataIndex: 'orderNo',
  306. key: 'orderNo',
  307. },
  308. {
  309. title: '合同编号',
  310. dataIndex: 'contractNo',
  311. key: 'contractNo',
  312. },
  313. {
  314. title: '业务类别',
  315. dataIndex: 'cname',
  316. key: 'cname',
  317. },
  318. {
  319. title: '客户名称',
  320. dataIndex: 'userName',
  321. key: 'userName',
  322. className: 'userName',
  323. },
  324. {
  325. title: '分配状态',
  326. dataIndex: 'taskStatus',
  327. key: 'taskStatus',
  328. render: (text) => {
  329. return getTaskStatus(text)
  330. },
  331. },
  332. {
  333. title: '项目状态',
  334. dataIndex: 'projectStatus',
  335. key: 'projectStatus',
  336. render: (text) => {
  337. return getProjectStatus(text)
  338. },
  339. },
  340. {
  341. title: '审核状态',
  342. dataIndex: 'outsourceStatus',
  343. key: 'outsourceStatus',
  344. render: (text,record) => {
  345. if(record.outsourceType === 1){
  346. return '供应商'
  347. }else{
  348. if (text === 0) {
  349. return <Tag color="#f50">外包待审核</Tag>
  350. } else if (text === 1) {
  351. return <Tag color="#87d068">外包已通过</Tag>
  352. } else if (text === 2) {
  353. return <Tag color="#2db7f5">外包被驳回</Tag>
  354. } else {
  355. return <div style={{textAlign:'center'}}>/</div>
  356. }
  357. return text
  358. }
  359. },
  360. },
  361. {
  362. title: '分配时间',
  363. dataIndex: 'taskDate',
  364. key: 'taskDate',
  365. },
  366. {
  367. title: '订单部门',
  368. dataIndex: 'depName',
  369. key: 'depName',
  370. },
  371. {
  372. title: '累计工时(小时)',
  373. dataIndex: 'hours',
  374. key: 'hours',
  375. },
  376. {
  377. title: "项目金额(万元)",
  378. dataIndex: "commodityPrice",
  379. key: "commodityPrice",
  380. },
  381. {
  382. title: "外包成本(万元)",
  383. dataIndex: "costAmount",
  384. key: "costAmount",
  385. render: (text, record) => {
  386. return (<span>
  387. {
  388. isNaN(parseFloat(text)) ? text : parseFloat(text)
  389. }
  390. </span>)
  391. }
  392. },
  393. {
  394. title: "已付(万元)",
  395. dataIndex: "partyAmount",
  396. key: "partyAmount",
  397. render: (text, record) => {
  398. return (<span>
  399. {
  400. isNaN(parseFloat(text)) ? text : parseFloat(text)
  401. }
  402. </span>)
  403. }
  404. },
  405. {
  406. title: '操作',
  407. dataIndex: 'caozuo',
  408. key: 'caozuo',
  409. render: (text, record) => {
  410. return (
  411. <div>
  412. <Button
  413. type="primary"
  414. onClick={(e) => {
  415. e.stopPropagation(), this.evaluate(record, '咨询师')
  416. }}
  417. >
  418. 转交
  419. </Button>
  420. <Button
  421. type="primary"
  422. style={{ marginLeft: 10 }}
  423. onClick={(e) => {
  424. e.stopPropagation(),
  425. this.evaluate(record, '咨询师经理', true)
  426. }}
  427. >
  428. 回退
  429. </Button>
  430. <Button
  431. type="primary"
  432. style={{ margin: '0 10px' }}
  433. onClick={(e) => {
  434. e.stopPropagation(), this.okCancel(record)
  435. }}
  436. >
  437. 添加工时
  438. </Button>
  439. <Button
  440. type="primary"
  441. onClick={(e) => {
  442. e.stopPropagation()
  443. this.setState({
  444. timeVisible: true,
  445. })
  446. this.timeDetail(record)
  447. }}
  448. >
  449. 工时记录
  450. </Button>
  451. </div>
  452. )
  453. },
  454. },
  455. ],
  456. dataSource: [],
  457. searchTime: [],
  458. columnsX: [
  459. {
  460. title: '业务项目名称',
  461. dataIndex: 'commodityName',
  462. key: 'commodityName',
  463. },
  464. {
  465. title: '项目类别',
  466. dataIndex: 'cname',
  467. key: 'cname',
  468. },
  469. {
  470. title: '项目数量',
  471. dataIndex: 'commodityQuantity',
  472. key: 'commodityQuantity',
  473. render: (text, record) => {
  474. if (record.splitStatus == 1) {
  475. return (
  476. <span>
  477. {text}{' '}
  478. <Tag
  479. color="#108ee9"
  480. onClick={(e) => {
  481. e.stopPropagation()
  482. this.showRes(record)
  483. }}
  484. >
  485. 已拆
  486. </Tag>
  487. </span>
  488. )
  489. } else {
  490. return text
  491. }
  492. },
  493. },
  494. {
  495. title: '金额(万元)',
  496. dataIndex: 'commodityPrice',
  497. key: 'commodityPrice',
  498. },
  499. {
  500. title: '负责人',
  501. dataIndex: 'contacts',
  502. key: 'contacts',
  503. },
  504. {
  505. title: '负责人电话',
  506. dataIndex: 'contactsMobile',
  507. key: 'contactsMobile',
  508. },
  509. {
  510. title: '主要项目',
  511. dataIndex: 'main',
  512. key: 'main',
  513. render: (text) => {
  514. return text ? '是' : '否'
  515. },
  516. },
  517. {
  518. title: '项目说明',
  519. dataIndex: 'taskComment',
  520. key: 'taskComment',
  521. render: (text) => {
  522. return text && text.length > 8 ? text.substr(0, 8) + '…' : text
  523. },
  524. },
  525. ],
  526. columnsA: [
  527. {
  528. title: '流程',
  529. dataIndex: 'content',
  530. key: 'content',
  531. align: 'center',
  532. },
  533. {
  534. title: '操作人',
  535. dataIndex: 'aName',
  536. key: 'aName',
  537. align: 'center',
  538. },
  539. {
  540. title: '时间',
  541. dataIndex: 'createTimes',
  542. key: 'createTimes',
  543. align: 'center',
  544. },
  545. ],
  546. dataSourceX: [],
  547. dataSourceA: [],
  548. ContactsLists: [
  549. {
  550. title: '批次',
  551. dataIndex: 'num',
  552. key: 'num',
  553. },
  554. {
  555. title: '下证时间',
  556. dataIndex: 'licenceTimes',
  557. key: 'licenceTimes',
  558. render: (text, record) => {
  559. return (
  560. <div>
  561. <DatePicker
  562. style={{ marginTop: '5px' }}
  563. showTime
  564. format="YYYY-MM-DD"
  565. onOk={() => {}}
  566. value={
  567. record.licenceTimes ? moment(record.licenceTimes) : null
  568. }
  569. onChange={(data, dataString) => {
  570. record.licenceTimes = dataString
  571. this.setState({ contactList: this.state.contactList })
  572. }}
  573. />
  574. </div>
  575. )
  576. },
  577. },
  578. {
  579. title: '下证数量',
  580. dataIndex: 'alreadyNumber',
  581. key: 'alreadyNumber',
  582. render: (text, record) => {
  583. return (
  584. <div>
  585. {
  586. <Input
  587. value={record.alreadyNumber}
  588. placeholder="请输入下证数量"
  589. key={record.id}
  590. required="required"
  591. onChange={(e) => {
  592. record.alreadyNumber = e.target.value
  593. this.setState({ contactList: this.state.contactList })
  594. }}
  595. style={{ width: '120px' }}
  596. />
  597. }
  598. </div>
  599. )
  600. },
  601. },
  602. {
  603. title: '未下证数量',
  604. dataIndex: 'notCount',
  605. key: 'notCount',
  606. },
  607. {
  608. title: '操作',
  609. dataIndex: 'dels',
  610. key: 'dels',
  611. render: (text, record, index) => {
  612. return (
  613. <div>
  614. {
  615. <Popconfirm
  616. title="是否删除?"
  617. onConfirm={() => {
  618. this.confirmDelet(record)
  619. }}
  620. okText="删除"
  621. cancelText="不删除"
  622. >
  623. <Button
  624. style={{
  625. marginRight: '10px',
  626. color: '#ffffff',
  627. background: '#f00',
  628. border: 'none',
  629. }}
  630. >
  631. 删除
  632. </Button>
  633. </Popconfirm>
  634. }
  635. {record.flag ? (
  636. ''
  637. ) : (
  638. <Button
  639. type="primary"
  640. onClick={(e) => {
  641. e.stopPropagation(), this.contactSave(record, index)
  642. }}
  643. >
  644. 保存
  645. </Button>
  646. )}
  647. </div>
  648. )
  649. },
  650. },
  651. ],
  652. // 专利
  653. ContactsListsNew: [],
  654. //付款节点表头
  655. PayNodeTableColunms: [],
  656. }
  657. },
  658. /* 分派 */
  659. evaluate(record, nub, flag) {
  660. this.setState(
  661. {
  662. nub: nub,
  663. assignData: record,
  664. flag,
  665. },
  666. () => {
  667. this.setState({
  668. assignVisible: true,
  669. })
  670. }
  671. )
  672. },
  673. componentWillMount() {
  674. this.departmentList()
  675. this.loadData()
  676. },
  677. componentDidMount() {
  678. this.setColor()
  679. },
  680. //用于判断 第三方信息表格显示
  681. projectTypeTabContent(projectType) {
  682. if(projectType === 0 || !projectType){ //0正常 1专利 2软著 3审计
  683. this.setState({
  684. ContactsListsNew: [
  685. {
  686. title: '供应商名称',
  687. dataIndex: 'companyName',
  688. key: 'companyName',
  689. render: (text, record, index) => {
  690. if (text) {
  691. return <span>{text}</span>
  692. }
  693. },
  694. },
  695. {
  696. title: '单价(万元)',
  697. dataIndex: 'unitPrice',
  698. key: 'unitPrice',
  699. render: (text, record) => {
  700. if (text) {
  701. return <span>
  702. {
  703. isNaN(text) ? text : parseFloat(text)
  704. }
  705. </span>
  706. }
  707. },
  708. },
  709. {
  710. title: '数量',
  711. dataIndex: 'quantity',
  712. key: 'quantity',
  713. render: (text, record) => {
  714. if (text) {
  715. return <span>{text}</span>
  716. }
  717. },
  718. },
  719. {
  720. title: '总价(万元)',
  721. dataIndex: 'totalAmount',
  722. key: 'totalAmount',
  723. render: (text, record) => {
  724. return <span>
  725. {
  726. isNaN(text) ? text : parseFloat(text)
  727. }
  728. </span>
  729. },
  730. },
  731. {
  732. title: '备注',
  733. dataIndex: 'remarks',
  734. key: 'remarks',
  735. },
  736. {
  737. title: '操作',
  738. dataIndex: 'action',
  739. key: 'action',
  740. render: (text, record) => {
  741. return (
  742. <div>
  743. {/*外包审核通过后,咨询师/咨询经理可申请付款*/}
  744. {/*存在支付节点时不显示第三方的申请付款*/}
  745. {/*0-待审核 ,1-审核通过,2-审核拒绝 true [NULL]*/}
  746. {
  747. <Button disabled={
  748. !(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)
  749. } type="primary" onClick={() => {
  750. this.setState({
  751. previewPayVisible: true,
  752. previewPayInfor: record,
  753. })
  754. }}>
  755. 申请付款
  756. </Button>
  757. }
  758. <Popconfirm
  759. title="是否删除?"
  760. onConfirm={() => {
  761. this.confirmDeletNew(record)
  762. }}
  763. okText="删除"
  764. cancelText="不删除"
  765. >
  766. <Button
  767. onClick={(e) => {
  768. e.stopPropagation()
  769. }}
  770. style={{
  771. marginLeft: '10px',
  772. color: '#ffffff',
  773. background: '#f00',
  774. border: 'none',
  775. }}
  776. >
  777. 删除
  778. </Button>
  779. </Popconfirm>
  780. </div>
  781. )
  782. },
  783. },
  784. ],
  785. })
  786. }else if(projectType === 2){ //2软著
  787. this.setState({
  788. ContactsListsNew: [
  789. {
  790. title: '供应商名称',
  791. dataIndex: 'companyName',
  792. key: 'companyName',
  793. render: (text, record, index) => {
  794. if (text) {
  795. return <span>{text}</span>
  796. }
  797. },
  798. },
  799. {
  800. title: '单价(万元)',
  801. dataIndex: 'unitPrice',
  802. key: 'unitPrice',
  803. render: (text, record) => {
  804. if (text) {
  805. return <span>
  806. {
  807. isNaN(text) ? text : parseFloat(text)
  808. }
  809. </span>
  810. }
  811. },
  812. },
  813. {
  814. title: '数量',
  815. dataIndex: 'quantity',
  816. key: 'quantity',
  817. render: (text, record) => {
  818. if (text) {
  819. return <span>{text}</span>
  820. }
  821. },
  822. },
  823. {
  824. title: '总价(万元)',
  825. dataIndex: 'totalAmount',
  826. key: 'totalAmount',
  827. render: (text, record) => {
  828. return <span>
  829. {
  830. isNaN(text) ? text : parseFloat(text)
  831. }
  832. </span>
  833. },
  834. },
  835. {
  836. title: '材料',
  837. dataIndex: 'material',
  838. key: 'material',
  839. render: (text, record) => {
  840. return getMaterialStatus(text)
  841. },
  842. },
  843. {
  844. title: '加急',
  845. dataIndex: 'urgent',
  846. key: 'urgent',
  847. render: (text, record) => {
  848. return getUrgentStatus(text)
  849. },
  850. },
  851. {
  852. title: '操作',
  853. dataIndex: 'action',
  854. key: 'action',
  855. render: (text, record) => {
  856. return (
  857. <div>
  858. {/*外包审核通过后,咨询师/咨询经理可申请付款*/}
  859. {/*存在支付节点时不显示第三方的申请付款*/}
  860. {/*0-待审核 ,1-审核通过,2-审核拒绝 true [NULL]*/}
  861. {
  862. <Button disabled={
  863. !(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)
  864. } type="primary" onClick={() => {
  865. this.setState({
  866. previewPayVisible: true,
  867. previewPayInfor: record,
  868. })
  869. }}>
  870. 申请付款
  871. </Button>
  872. }
  873. <Popconfirm
  874. title="是否删除?"
  875. onConfirm={() => {
  876. this.confirmDeletNew(record)
  877. }}
  878. okText="删除"
  879. cancelText="不删除"
  880. >
  881. <Button
  882. onClick={(e) => {
  883. e.stopPropagation()
  884. }}
  885. style={{
  886. marginLeft: '10px',
  887. color: '#ffffff',
  888. background: '#f00',
  889. border: 'none',
  890. }}
  891. >
  892. 删除
  893. </Button>
  894. </Popconfirm>
  895. </div>
  896. )
  897. },
  898. },
  899. ],
  900. })
  901. }else if(projectType === 1){ //1专利
  902. if(this.state.patentType === 0){ //专利申请
  903. this.setState({
  904. ContactsListsNew: [
  905. {
  906. title: '供应商名称',
  907. dataIndex: 'companyName',
  908. key: 'companyName',
  909. render: (text, record, index) => {
  910. if (text) {
  911. return <span>{text}</span>
  912. }
  913. },
  914. },
  915. {
  916. title: '单价(万元)',
  917. dataIndex: 'unitPrice',
  918. key: 'unitPrice',
  919. render: (text, record) => {
  920. if (text) {
  921. return <span>
  922. {
  923. isNaN(text) ? text : parseFloat(text)
  924. }
  925. </span>
  926. }
  927. },
  928. },
  929. {
  930. title: '数量',
  931. dataIndex: 'quantity',
  932. key: 'quantity',
  933. render: (text, record) => {
  934. if (text) {
  935. return <span>{text}</span>
  936. }
  937. },
  938. },
  939. {
  940. title: "官费",
  941. dataIndex: "officialCost",
  942. key: "officialCost",
  943. render: (text) => {
  944. return text === 1 ? '有官费' : '无官费'
  945. },
  946. },
  947. {
  948. title: "费减",
  949. dataIndex: "costReduction",
  950. key: "costReduction",
  951. render: (text) => {
  952. return text === 1 ? '有费减' : '无费减'
  953. },
  954. },
  955. {
  956. title: '总价(万元)',
  957. dataIndex: 'totalAmount',
  958. key: 'totalAmount',
  959. render: (text, record) => {
  960. return <span>
  961. {
  962. isNaN(text) ? text : parseFloat(text)
  963. }
  964. </span>
  965. },
  966. },
  967. {
  968. title: '备注',
  969. dataIndex: 'remarks',
  970. key: 'remarks',
  971. },
  972. {
  973. title: '操作',
  974. dataIndex: 'action',
  975. key: 'action',
  976. render: (text, record) => {
  977. return (
  978. <div>
  979. {/*外包审核通过后,咨询师/咨询经理可申请付款*/}
  980. {/*存在支付节点时不显示第三方的申请付款*/}
  981. {/*0-待审核 ,1-审核通过,2-审核拒绝 true [NULL]*/}
  982. {
  983. <Button disabled={
  984. !(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)
  985. } type="primary" onClick={() => {
  986. this.setState({
  987. previewPayVisible: true,
  988. previewPayInfor: record,
  989. })
  990. }}>
  991. 申请付款
  992. </Button>
  993. }
  994. {
  995. <Button
  996. type="primary"
  997. style={{
  998. marginLeft: '10px',
  999. }}
  1000. disabled={!(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)}
  1001. onClick={() => {
  1002. this.setState({
  1003. previewPayVisible: true,
  1004. previewPayInfor: record,
  1005. })
  1006. }}>
  1007. 付官费
  1008. </Button>
  1009. }
  1010. <Popconfirm
  1011. title="是否删除?"
  1012. onConfirm={() => {
  1013. this.confirmDeletNew(record)
  1014. }}
  1015. okText="删除"
  1016. cancelText="不删除"
  1017. >
  1018. <Button
  1019. onClick={(e) => {
  1020. e.stopPropagation()
  1021. }}
  1022. style={{
  1023. marginLeft: '10px',
  1024. color: '#ffffff',
  1025. background: '#f00',
  1026. border: 'none',
  1027. }}
  1028. >
  1029. 删除
  1030. </Button>
  1031. </Popconfirm>
  1032. </div>
  1033. )
  1034. },
  1035. },
  1036. ]
  1037. })
  1038. }else{
  1039. this.setState({
  1040. ContactsListsNew: [
  1041. {
  1042. title: '供应商名称',
  1043. dataIndex: 'companyName',
  1044. key: 'companyName',
  1045. render: (text, record, index) => {
  1046. if (text) {
  1047. return <span>{text}</span>
  1048. }
  1049. },
  1050. },
  1051. {
  1052. title: '单价(万元)',
  1053. dataIndex: 'unitPrice',
  1054. key: 'unitPrice',
  1055. render: (text, record) => {
  1056. if (text) {
  1057. return <span>
  1058. {
  1059. isNaN(text) ? text : parseFloat(text)
  1060. }
  1061. </span>
  1062. }
  1063. },
  1064. },
  1065. {
  1066. title: '数量',
  1067. dataIndex: 'quantity',
  1068. key: 'quantity',
  1069. render: (text, record) => {
  1070. if (text) {
  1071. return <span>{text}</span>
  1072. }
  1073. },
  1074. },
  1075. {
  1076. title: '总价(万元)',
  1077. dataIndex: 'totalAmount',
  1078. key: 'totalAmount',
  1079. render: (text, record) => {
  1080. return <span>
  1081. {
  1082. isNaN(text) ? text : parseFloat(text)
  1083. }
  1084. </span>
  1085. },
  1086. },
  1087. {
  1088. title: '备注',
  1089. dataIndex: 'remarks',
  1090. key: 'remarks',
  1091. },
  1092. {
  1093. title: '操作',
  1094. dataIndex: 'action',
  1095. key: 'action',
  1096. render: (text, record) => {
  1097. return (
  1098. <div>
  1099. {/*外包审核通过后,咨询师/咨询经理可申请付款*/}
  1100. {/*存在支付节点时不显示第三方的申请付款*/}
  1101. {/*0-待审核 ,1-审核通过,2-审核拒绝 true [NULL]*/}
  1102. {
  1103. <Button disabled={
  1104. !(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)
  1105. } type="primary" onClick={() => {
  1106. this.setState({
  1107. previewPayVisible: true,
  1108. previewPayInfor: record,
  1109. })
  1110. }}>
  1111. 申请付款
  1112. </Button>
  1113. }
  1114. <Popconfirm
  1115. title="是否删除?"
  1116. onConfirm={() => {
  1117. this.confirmDeletNew(record)
  1118. }}
  1119. okText="删除"
  1120. cancelText="不删除"
  1121. >
  1122. <Button
  1123. onClick={(e) => {
  1124. e.stopPropagation()
  1125. }}
  1126. style={{
  1127. marginLeft: '10px',
  1128. color: '#ffffff',
  1129. background: '#f00',
  1130. border: 'none',
  1131. }}
  1132. >
  1133. 删除
  1134. </Button>
  1135. </Popconfirm>
  1136. </div>
  1137. )
  1138. },
  1139. },
  1140. ]
  1141. })
  1142. }
  1143. }else if(projectType === 3){ //3审计
  1144. this.setState({
  1145. ContactsListsNew: [
  1146. {
  1147. title: '供应商名称',
  1148. dataIndex: 'companyName',
  1149. key: 'companyName',
  1150. render: (text, record, index) => {
  1151. if (text) {
  1152. return <span>{text}</span>
  1153. }
  1154. },
  1155. },
  1156. {
  1157. title: '单价(万元)',
  1158. dataIndex: 'unitPrice',
  1159. key: 'unitPrice',
  1160. render: (text, record) => {
  1161. if (text) {
  1162. return <span>
  1163. {
  1164. isNaN(text) ? text : parseFloat(text)
  1165. }
  1166. </span>
  1167. }
  1168. },
  1169. },
  1170. {
  1171. title: '数量',
  1172. dataIndex: 'quantity',
  1173. key: 'quantity',
  1174. render: (text, record) => {
  1175. if (text) {
  1176. return <span>{text}</span>
  1177. }
  1178. },
  1179. },
  1180. {
  1181. title: '总价(万元)',
  1182. dataIndex: 'totalAmount',
  1183. key: 'totalAmount',
  1184. render: (text, record) => {
  1185. return <span>
  1186. {
  1187. isNaN(text) ? text : parseFloat(text)
  1188. }
  1189. </span>
  1190. },
  1191. },
  1192. {
  1193. title: '审计',
  1194. dataIndex: 'audit',
  1195. key: 'audit',
  1196. render: (text, record) => {
  1197. if (text) {
  1198. return <span>{text===0?'无审计':text===1?'年审':'专审'}</span>
  1199. }
  1200. },
  1201. },
  1202. {
  1203. title: '公司资产(万元)',
  1204. dataIndex: 'assets',
  1205. key: 'assets',
  1206. render: (text, record) => {
  1207. if (text) {
  1208. return <span>{text}</span>
  1209. }
  1210. },
  1211. },
  1212. {
  1213. title: '收入(万元)',
  1214. dataIndex: 'income',
  1215. key: 'income',
  1216. render: (text, record) => {
  1217. return <span>
  1218. {
  1219. isNaN(text) ? text : parseFloat(text)
  1220. }
  1221. </span>
  1222. },
  1223. },
  1224. {
  1225. title: '操作',
  1226. dataIndex: 'action',
  1227. key: 'action',
  1228. render: (text, record) => {
  1229. return (
  1230. <div>
  1231. {/*外包审核通过后,咨询师/咨询经理可申请付款*/}
  1232. {/*存在支付节点时不显示第三方的申请付款*/}
  1233. {/*0-待审核 ,1-审核通过,2-审核拒绝 true [NULL]*/}
  1234. {
  1235. <Button disabled={
  1236. !(this.props.isPreviewPay && (this.props.status === 1 || parseInt(this.props.startType) === 1) && this.props.dataSource.length === 0)
  1237. } type="primary" onClick={() => {
  1238. this.setState({
  1239. previewPayVisible: true,
  1240. previewPayInfor: record,
  1241. })
  1242. }}>
  1243. 申请付款
  1244. </Button>
  1245. }
  1246. <Popconfirm
  1247. title="是否删除?"
  1248. onConfirm={() => {
  1249. this.confirmDeletNew(record)
  1250. }}
  1251. okText="删除"
  1252. cancelText="不删除"
  1253. >
  1254. <Button
  1255. onClick={(e) => {
  1256. e.stopPropagation()
  1257. }}
  1258. style={{
  1259. marginLeft: '10px',
  1260. color: '#ffffff',
  1261. background: '#f00',
  1262. border: 'none',
  1263. }}
  1264. >
  1265. 删除
  1266. </Button>
  1267. </Popconfirm>
  1268. </div>
  1269. )
  1270. },
  1271. },
  1272. ]
  1273. })
  1274. }
  1275. this.setState({
  1276. //付款节点表头
  1277. PayNodeTableColunms: [
  1278. {
  1279. title: '供应商名称',
  1280. dataIndex: 'companyName',
  1281. key: 'companyName',
  1282. render: (text, record, index) => {
  1283. if (text) {
  1284. return <span>{text}</span>
  1285. }
  1286. },
  1287. },
  1288. {
  1289. title: '付款科目',
  1290. dataIndex: 'dunType',
  1291. key: 'dunType',
  1292. render: (text, record) => {
  1293. if (text) {
  1294. return <span>{text}</span>
  1295. }
  1296. },
  1297. },
  1298. {
  1299. title: '付款时间',
  1300. dataIndex: 'partyTimes',
  1301. key: 'partyTimes',
  1302. render: (text, record) => {
  1303. return <span>{text ? text : '/'}</span>
  1304. },
  1305. },
  1306. {
  1307. title: '数量',
  1308. dataIndex: 'quantity',
  1309. key: 'quantity',
  1310. render: (text, record) => {
  1311. if (text) {
  1312. return <span>{text}</span>
  1313. }
  1314. },
  1315. },
  1316. {
  1317. title: '总价(万元)',
  1318. dataIndex: 'totalAmount',
  1319. key: 'totalAmount',
  1320. render: (text, record) => {
  1321. return <span>
  1322. {
  1323. isNaN(text) ? text : parseFloat(text)
  1324. }
  1325. </span>
  1326. },
  1327. },
  1328. {
  1329. title: '已付',
  1330. dataIndex: 'partyAmount',
  1331. key: 'partyAmount',
  1332. render: (text, record) => {
  1333. if (text) {
  1334. return <span>{text}</span>
  1335. }
  1336. },
  1337. },
  1338. {
  1339. title: '操作',
  1340. dataIndex: 'dels',
  1341. key: 'dels',
  1342. render: (text, record, index) => {
  1343. return (
  1344. <div>
  1345. <Popconfirm
  1346. title="是否删除?"
  1347. onConfirm={() => {
  1348. this.payNodeConfirmDeletNew(record)
  1349. }}
  1350. okText="删除"
  1351. cancelText="不删除"
  1352. >
  1353. <Button
  1354. onClick={(e) => {
  1355. e.stopPropagation()
  1356. }}
  1357. style={{
  1358. marginRight: '10px',
  1359. color: '#ffffff',
  1360. background: '#f00',
  1361. border: 'none',
  1362. }}
  1363. >
  1364. 删除
  1365. </Button>
  1366. </Popconfirm>
  1367. </div>
  1368. )
  1369. },
  1370. },
  1371. ],
  1372. })
  1373. },
  1374. setColor() {
  1375. $('.userName span').after(
  1376. "(<span class='ruanzhu'>软著数</span>/<span class='xiazheng'>下证数</span>)"
  1377. )
  1378. },
  1379. // 获取csort下的数据
  1380. getCsortData(cSort) {
  1381. cuiJieDian.map((item) => {
  1382. if (item.value == cSort) {
  1383. console.log(item.children)
  1384. this.setState({
  1385. paySubject: item.children,
  1386. })
  1387. }
  1388. })
  1389. },
  1390. tableRowClick(record) {
  1391. this.state.RowData = record
  1392. let str = record.taskName
  1393. let test = str.indexOf('会员')
  1394. if (test == -1) {
  1395. this.setState({
  1396. isHuiyuan: false,
  1397. })
  1398. } else {
  1399. this.setState({
  1400. isHuiyuan: true,
  1401. })
  1402. }
  1403. if (record.taskName.substring(0, 5) === '软件著作权') {
  1404. this.setState({
  1405. speVisible: true,
  1406. id: record.id,
  1407. splitStatus: record.splitStatus,
  1408. splitSuper: record.splitSuper,
  1409. splitId: record.splitId,
  1410. dataArr: record,
  1411. commodityQuantity: record.commodityQuantity,
  1412. })
  1413. } else {
  1414. this.setState({
  1415. visible: true,
  1416. splitStatus: record.splitStatus,
  1417. splitSuper: record.splitSuper,
  1418. splitId: record.splitId,
  1419. })
  1420. }
  1421. this.setState({
  1422. projectType: record.projectType
  1423. })
  1424. this.xiangqing(record.id, record.taskName)
  1425. this.xiangqings(record.orderNo)
  1426. this.xiangmu(record.orderNo)
  1427. this.loaduserss(record)
  1428. // 获取第三方信息表格
  1429. this.thirdTable(record.id);
  1430. //获取支付节点信息表格
  1431. this.payNodeTable(record.id);
  1432. //查看外包状态日志
  1433. this.getSelectOutsourceLog(record.id);
  1434. // 获取Csort
  1435. this.getCsortData(localStorage.getItem('cSort'))
  1436. this.projectTypeTabContent(record.projectType)
  1437. },
  1438. //点击修改项目详情
  1439. tijiaoOk() {
  1440. let attachmentUrls = []
  1441. if (this.state.attachmentUrl.length) {
  1442. let picArr = []
  1443. this.state.attachmentUrl.map(function (item) {
  1444. if (item.response && item.response.data && item.response.data.length) {
  1445. picArr.push(item.response.data)
  1446. }
  1447. })
  1448. attachmentUrls = picArr.join(',')
  1449. }
  1450. this.setState({
  1451. loading: true,
  1452. })
  1453. $.ajax({
  1454. method: 'POST',
  1455. dataType: 'json',
  1456. crossDomain: false,
  1457. url: globalConfig.context + '/api/admin/orderProject/updateOrderTask',
  1458. data: {
  1459. id: this.state.id, //项目编号
  1460. orderNo: this.state.orderNo, //订单编号
  1461. projectStatus: this.state.projectStatus, //项目状态
  1462. taskStatus: this.state.taskStatus, //项目状态
  1463. taskComment: this.state.taskComment, //说明
  1464. startDate: this.state.startDate, //启动日期
  1465. endDate: this.state.endDate, //结束日期
  1466. acceptDate: this.state.acceptDate, //受理日期
  1467. reviewDate: this.state.reviewDate, //评审日期
  1468. publicityDate: this.state.publicityDate, //公示日期
  1469. licenceDate: this.state.licenceDate, //发证日期
  1470. attachmentUrl: attachmentUrls.length ? attachmentUrls : '', //附件
  1471. contacts: this.state.contacts, //联系人
  1472. contactMobile: this.state.contactMobile, //联系人电话
  1473. legalPerson: this.state.legalPerson, //法人
  1474. legalPersonTel: this.state.legalPersonTel, //法人电话
  1475. certificateNumber: this.state.certificateNumber, //证书编号
  1476. status: this.state.status, //状态
  1477. formRetrieve: this.state.formRetrieve, //满意度表格
  1478. taskRefund: this.state.taskRefund, //退单
  1479. refundContent: this.state.refundContent, //退单信息
  1480. retrieveContent: this.state.retrieveContent, //回收信息
  1481. locationProvince: this.state.ProvinceCity[0],
  1482. locationCity: this.state.ProvinceCity[1],
  1483. locationArea: this.state.ProvinceCity[2],
  1484. postalAddress: this.state.postalAddress, //详细地址
  1485. arrivalMoney: this.state.arrivalMoney, //是否到款
  1486. setUpAmount: this.state.setUpAmount, //立项金额
  1487. declareUser: this.state.declareUser, //账号
  1488. declarePwd: this.state.declarePwd, //密码
  1489. outsourceName: this.state.outsourceName, //外包公司
  1490. outsourcePrice: this.state.outsourcePrice, //外包价格
  1491. declarationBatch: this.state.declarationBatch,
  1492. },
  1493. }).done(
  1494. function (data) {
  1495. this.setState({
  1496. loading: false,
  1497. })
  1498. if (!data.error.length) {
  1499. message.success('保存成功!')
  1500. this.visitCancel()
  1501. } else {
  1502. message.warning(data.error[0].message)
  1503. }
  1504. }.bind(this)
  1505. )
  1506. },
  1507. //点击修改项目详情
  1508. tianjiaOk() {
  1509. if (this.state.attachmentUrl.length) {
  1510. let picArr = []
  1511. this.state.attachmentUrl.map(function (item) {
  1512. if (item.response && item.response.data && item.response.data.length) {
  1513. picArr.push(item.response.data)
  1514. }
  1515. })
  1516. }
  1517. $.ajax({
  1518. method: 'POST',
  1519. dataType: 'json',
  1520. crossDomain: false,
  1521. url: globalConfig.context + '/api/admin/orderProject/addTaskHours',
  1522. data: {
  1523. taskId: this.state.taskId, //项目编号
  1524. hours: this.state.hours, //工时
  1525. remarks: this.state.remarks, //说明
  1526. taskDate: this.state.taskDate, //日期
  1527. taskComment: this.state.taskComment, //说明
  1528. },
  1529. }).done(
  1530. function (data) {
  1531. this.setState({
  1532. loading: false,
  1533. })
  1534. if (!data.error.length) {
  1535. message.success('保存成功!')
  1536. this.noCancel()
  1537. } else {
  1538. message.warning(data.error[0].message)
  1539. }
  1540. }.bind(this)
  1541. )
  1542. },
  1543. //订单详情
  1544. xiangqing(id) {
  1545. $.ajax({
  1546. method: 'get',
  1547. dataType: 'json',
  1548. crossDomain: false,
  1549. url: globalConfig.context + '/api/admin/orderProject/orderTaskDetail',
  1550. data: {
  1551. id: id,
  1552. },
  1553. success: function (data) {
  1554. let thisdata = data.data
  1555. if (data.error.length || data.data.list == '') {
  1556. if (data.error && data.error.length) {
  1557. message.warning(data.error[0].message)
  1558. }
  1559. } else {
  1560. this.setState({
  1561. id: thisdata.id, //ID
  1562. splitId: thisdata.splitId,//拆分序号
  1563. splitStatus: thisdata.splitStatus,//0未拆分 1已拆分
  1564. splitSuper: thisdata.splitSuper,//拆分前项目编号
  1565. orderNo: thisdata.orderNo, //订单编号
  1566. userName: thisdata.userName, //客户名称
  1567. taskName: thisdata.taskName, //项目名称
  1568. cname: thisdata.cname, //项目品类
  1569. contractNo: thisdata.contractNo, //合同编号
  1570. projectStatus: thisdata.projectStatus.toString(), //项目状态
  1571. taskStatus: thisdata.taskStatus.toString(), //项目状态
  1572. taskDate: thisdata.taskDate, //分配时间
  1573. taskComment: thisdata.taskComment, //说明
  1574. attachmentUrl: thisdata.attachmentUrl
  1575. ? splitUrl(
  1576. thisdata.attachmentUrl,
  1577. ',',
  1578. globalConfig.avatarHost + '/upload'
  1579. )
  1580. : [], //图片地址
  1581. salesmanName: thisdata.salesmanName, //订单负责人
  1582. startDate: thisdata.startDate, //启动日期
  1583. endDate: thisdata.endDate, //结束日期
  1584. acceptDate: thisdata.acceptDate, //受理日期
  1585. reviewDate: thisdata.reviewDate, //评审日期
  1586. publicityDate: thisdata.publicityDate, //公示日期
  1587. licenceDate: thisdata.licenceDate, //发证日期
  1588. contacts: thisdata.contacts, //联系人
  1589. contactMobile: thisdata.contactMobile, //联系人电话
  1590. legalPerson: thisdata.legalPerson, //法人
  1591. legalPersonTel: thisdata.legalPersonTel, //法人电话
  1592. certificateNumber: thisdata.certificateNumber, //证书编号
  1593. status: thisdata.status, //状态
  1594. formRetrieve: thisdata.formRetrieve, //满意度表格
  1595. taskRefund: thisdata.taskRefund, //退单
  1596. refundContent: thisdata.refundContent, //退单信息
  1597. retrieveContent: thisdata.retrieveContent, //回收信息
  1598. arrivalMoney: thisdata.arrivalMoney, //是否到款
  1599. setUpAmount: thisdata.setUpAmount, //立项金额
  1600. declareUser: thisdata.declareUser, //账号
  1601. declarePwd: thisdata.declarePwd, //密码
  1602. outsourceName: thisdata.outsourceName, //外包公司
  1603. outsourcePrice: thisdata.outsourcePrice, //外包价格
  1604. declarationBatch: thisdata.declarationBatch,
  1605. })
  1606. }
  1607. }.bind(this),
  1608. }).always(
  1609. function () {
  1610. this.setState({
  1611. loading: false,
  1612. })
  1613. }.bind(this)
  1614. )
  1615. },
  1616. //订单详情
  1617. xiangqings(orderNos) {
  1618. $.ajax({
  1619. method: 'get',
  1620. dataType: 'json',
  1621. crossDomain: false,
  1622. url: globalConfig.context + '/api/admin/newOrder/getOrderNewDetail',
  1623. data: {
  1624. orderNo: orderNos,
  1625. },
  1626. success: function (data) {
  1627. let thisdata = data.data
  1628. let ProvinceCityArr = []
  1629. let ProvinceS = thisdata.locationProvince //省
  1630. let citys = thisdata.locationCity //市
  1631. let Areas = thisdata.locationArea //区
  1632. ProvinceCityArr.push(ProvinceS, citys, Areas)
  1633. if (data.error.length || data.data.list == '') {
  1634. if (data.error && data.error.length) {
  1635. message.warning(data.error[0].message)
  1636. }
  1637. } else {
  1638. this.setState({
  1639. processStatus: thisdata.processStatus, //流程状态
  1640. liquidationStatus: thisdata.liquidationStatus, //结算状态
  1641. approval: thisdata.approval, //特批状态
  1642. orderRemarks: thisdata.orderRemarks, //订单留言
  1643. salesmanName: thisdata.salesmanName, //营销员名称
  1644. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  1645. financeName: thisdata.financeName, //财务名称
  1646. financeMobile: thisdata.financeMobile, //财务电话
  1647. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  1648. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  1649. nowFinance: thisdata.nowFinance, //财务名称
  1650. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  1651. depName: thisdata.depName, //订单部门
  1652. ProvinceCity: ProvinceCityArr[0] === null ? [] : ProvinceCityArr,
  1653. postalAddress: thisdata.postalAddress, //详细地址
  1654. })
  1655. }
  1656. }.bind(this),
  1657. }).always(
  1658. function () {
  1659. this.setState({
  1660. loading: false,
  1661. })
  1662. }.bind(this)
  1663. )
  1664. },
  1665. //项目列表
  1666. xiangmu(orderNos) {
  1667. $.ajax({
  1668. method: 'get',
  1669. dataType: 'json',
  1670. crossDomain: false,
  1671. url: globalConfig.context + '/api/admin/newOrder/getOrderTask',
  1672. data: {
  1673. orderNo: orderNos,
  1674. },
  1675. success: function (data) {
  1676. let theArr = []
  1677. if (data.error.length || data.data.list == '') {
  1678. if (data.error && data.error.length) {
  1679. message.warning(data.error[0].message)
  1680. }
  1681. } else {
  1682. for (let i = 0; i < data.data.length; i++) {
  1683. let thisdata = data.data[i]
  1684. localStorage.setItem('cSort', thisdata.cSort)
  1685. theArr.push({
  1686. key: i,
  1687. id: thisdata.id,
  1688. orderNo: thisdata.orderNo, //订单编号
  1689. commodityId: thisdata.commodityId, //项目ID
  1690. commodityName: thisdata.commodityName, //项目名称
  1691. cname: thisdata.cname, //项目类别
  1692. commodityPrice: thisdata.commodityPrice, //项目价格
  1693. commodityQuantity: thisdata.commodityQuantity, //项目数量
  1694. main: thisdata.main, //是否为主要项目
  1695. taskComment: thisdata.taskComment, //项目说明
  1696. contacts: thisdata.contacts, //联系人
  1697. contactsMobile: thisdata.contactsMobile, //联系人电话
  1698. taskStatus: thisdata.taskStatus, //是否分配
  1699. contractNo: thisdata.contractNo, //合同编号
  1700. certificateNumber: thisdata.certificateNumber,
  1701. splitStatus: thisdata.splitStatus,
  1702. officialCost: thisdata.officialCost,
  1703. costReduction: thisdata.costReduction,
  1704. type: thisdata.type,
  1705. cSort: thisdata.cSort,
  1706. })
  1707. }
  1708. }
  1709. this.setState({
  1710. dataSourceX: theArr,
  1711. type: theArr[0].type,
  1712. cSort: theArr[0].cSort,
  1713. })
  1714. }.bind(this),
  1715. }).always(
  1716. function () {
  1717. this.setState({
  1718. loading: false,
  1719. })
  1720. }.bind(this)
  1721. )
  1722. },
  1723. //导出
  1724. exportExec() {
  1725. let departmentName = '',
  1726. depart = this.state.departmentArr || []
  1727. depart.map((item) => {
  1728. if (this.state.departmentId == item.id) {
  1729. departmentName = item.name
  1730. return
  1731. }
  1732. })
  1733. let data = {
  1734. departmentId: this.state.departmentId,
  1735. departmentName: departmentName,
  1736. salesName: this.state.orderRefundSearch, //订单负责人
  1737. startTime: this.state.releaseDate[0],
  1738. endTime: this.state.releaseDate[1],
  1739. grantStatus: this.state.grantStatus,
  1740. }
  1741. window.location.href =
  1742. globalConfig.context +
  1743. '/api/admin/orderProject/exporProjectList?' +
  1744. $.param(data)
  1745. },
  1746. //关闭详情
  1747. visitCancel() {
  1748. this.setState({
  1749. visible: false,
  1750. speVisible: false,
  1751. activeKey: '1',
  1752. })
  1753. this.reset()
  1754. },
  1755. visitOk() {
  1756. this.setState({
  1757. visible: false,
  1758. speVisible: false,
  1759. })
  1760. this.reset()
  1761. },
  1762. closeDesc(e, s) {
  1763. this.state.showDesc = e
  1764. if (s) {
  1765. this.loadData(this.state.page)
  1766. }
  1767. },
  1768. closeAssign(e, s) {
  1769. this.state.roleName = ''
  1770. this.state.assignVisible = e
  1771. if (s) {
  1772. this.loadData(this.state.page)
  1773. }
  1774. },
  1775. //添加工时
  1776. okCancel(record) {
  1777. this.setState({
  1778. lookVisible: true,
  1779. taskId: record.id,
  1780. })
  1781. },
  1782. //测试
  1783. getOrgCodeUrl(e) {
  1784. this.setState({ orgCodeUrl: e })
  1785. },
  1786. //查看下证信息
  1787. loaduserss(record) {
  1788. $.ajax({
  1789. method: 'get',
  1790. dataType: 'json',
  1791. crossDomain: false,
  1792. url: globalConfig.context + '/api/admin/orderProject/selectTaskProgress',
  1793. data: {
  1794. tid: record.id,
  1795. },
  1796. success: function (data) {
  1797. let theArr = []
  1798. let thisData = []
  1799. if (!thisData) {
  1800. if (data.error && data.error.length) {
  1801. message.warning(data.error[0].message)
  1802. }
  1803. thisData = {}
  1804. } else {
  1805. for (let i = 0; i < data.data.length; i++) {
  1806. thisData = data.data[i]
  1807. theArr.push({
  1808. num: i + 1,
  1809. key: i,
  1810. id: thisData.id, //编号
  1811. alreadyNumber: thisData.alreadyNumber, //下证数
  1812. licenceTimes: thisData.licenceTimes, //下证时间
  1813. notCount: thisData.notCount, //未下证数
  1814. flag: true,
  1815. })
  1816. }
  1817. this.setState({
  1818. contactList: theArr,
  1819. tid: record.id,
  1820. })
  1821. }
  1822. }.bind(this),
  1823. }).always(
  1824. function () {
  1825. this.setState({
  1826. loading: false,
  1827. })
  1828. }.bind(this)
  1829. )
  1830. },
  1831. // 拆分详细
  1832. showRes(record) {
  1833. this.setState({
  1834. resVisible: true,
  1835. resRecord: record,
  1836. })
  1837. },
  1838. resCancel() {
  1839. this.setState({
  1840. resVisible: false,
  1841. })
  1842. },
  1843. //下证信息保存
  1844. contactSave(record) {
  1845. if (!record.licenceTimes) {
  1846. message.warning('下证日期不能为空')
  1847. return
  1848. }
  1849. if (!record.alreadyNumber) {
  1850. message.warning('下证数量不能为空')
  1851. return
  1852. }
  1853. this.setState({
  1854. loading: true,
  1855. })
  1856. $.ajax({
  1857. url: globalConfig.context + '/api/admin/orderProject/createTaskProgress',
  1858. method: 'post',
  1859. data: {
  1860. taskId: this.state.id,
  1861. licenceTimes: record.licenceTimes,
  1862. alreadyNumber: record.alreadyNumber,
  1863. },
  1864. }).done(
  1865. function (data) {
  1866. this.setState({
  1867. loading: false,
  1868. })
  1869. if (!data.error.length) {
  1870. message.success('保存成功!')
  1871. record.flag = true
  1872. this.loaduserss(this.state.dataArr)
  1873. } else {
  1874. message.warning(data.error[0].message)
  1875. }
  1876. }.bind(this)
  1877. )
  1878. },
  1879. //下证信息删除
  1880. contactDele(record) {
  1881. this.setState({
  1882. loading: true,
  1883. })
  1884. $.ajax({
  1885. url: globalConfig.context + '/api/admin/orderProject/delectTaskProgress',
  1886. method: 'post',
  1887. data: {
  1888. id: record.id,
  1889. },
  1890. }).done(
  1891. function (data) {
  1892. this.setState({
  1893. loading: false,
  1894. })
  1895. if (!data.error.length) {
  1896. this.loaduserss(this.state.dataArr)
  1897. } else {
  1898. message.warning(data.error[0].message)
  1899. }
  1900. }.bind(this)
  1901. )
  1902. },
  1903. //点击新增下证信息
  1904. addcontact() {
  1905. this.state.contactList.push({
  1906. num: this.state.contactList.length + 1,
  1907. key: this.state.contactList.length,
  1908. licenceTimes: '',
  1909. alreadyNumber: '',
  1910. notCount: '',
  1911. dels: '',
  1912. flag: false,
  1913. aflag: false,
  1914. })
  1915. this.setState({
  1916. contactList: this.state.contactList,
  1917. })
  1918. },
  1919. //删除下证信息
  1920. confirmDelet(record) {
  1921. this.state.contactList.splice(record.key, 1)
  1922. this.setState({
  1923. contactList: this.state.contactList,
  1924. })
  1925. if (record.id) {
  1926. this.contactDele(record)
  1927. }
  1928. },
  1929. caozuorizhi() {
  1930. this.setState({
  1931. visibleA: true,
  1932. })
  1933. $.ajax({
  1934. method: 'get',
  1935. dataType: 'json',
  1936. crossDomain: false,
  1937. url: globalConfig.context + '/api/admin/orderProject/TaskLogList',
  1938. data: {
  1939. id: this.state.id,
  1940. },
  1941. success: function (data) {
  1942. let theArr = []
  1943. if (data.error.length || data.data.list == '') {
  1944. if (data.error && data.error.length) {
  1945. message.warning(data.error[0].message)
  1946. }
  1947. } else {
  1948. for (let i = 0; i < data.data.length; i++) {
  1949. let thisdata = data.data[i]
  1950. theArr.push({
  1951. key: i,
  1952. id: thisdata.id, //日志ID
  1953. content: thisdata.content, //流程
  1954. taskId: thisdata.taskId, //项目ID
  1955. aName: thisdata.aName, //负责人
  1956. createTimes: thisdata.createTimes, //时间
  1957. })
  1958. }
  1959. }
  1960. this.setState({
  1961. dataSourceA: theArr,
  1962. })
  1963. }.bind(this),
  1964. }).always(
  1965. function () {
  1966. this.setState({
  1967. loading: false,
  1968. })
  1969. }.bind(this)
  1970. )
  1971. },
  1972. //关闭操作工时
  1973. visitCancelA() {
  1974. this.setState({
  1975. visibleA: false,
  1976. })
  1977. },
  1978. nextCancel() {
  1979. this.setState({
  1980. addnextVisible: false,
  1981. displayFees: 'none',
  1982. officialCost: '', //是否有官费
  1983. costReduction: '', //是否有费减
  1984. })
  1985. },
  1986. //点击打卡项目详情
  1987. tableRowClickX(record) {
  1988. if (record.type == '1') {
  1989. this.setState({
  1990. displayFees: 'block',
  1991. costReduction: record.costReduction,
  1992. officialCost: record.officialCost,
  1993. })
  1994. }
  1995. this.setState({
  1996. jid: record.id, //项目ID
  1997. kid: record.commodityId, //商品ID
  1998. commodityName: record.commodityName, //金额
  1999. commodityPrice: record.commodityPrice, //金额
  2000. commodityQuantity: record.commodityQuantity, //数量
  2001. taskComment: record.taskComment, //备注
  2002. main: record.main.toString(), //是否为主要
  2003. addnextVisible: true,
  2004. addState: 0,
  2005. })
  2006. },
  2007. //关闭添加工时
  2008. noCancel() {
  2009. this.setState({
  2010. lookVisible: false,
  2011. })
  2012. this.reset()
  2013. },
  2014. search() {
  2015. this.loadData()
  2016. },
  2017. reset(flag) {
  2018. if (flag) {
  2019. this.state.nameSearch = ''
  2020. this.state.orderNoSearch = ''
  2021. this.state.contractNoSearch = undefined
  2022. this.state.taskNoSearch = ''
  2023. this.state.departmenttSearch = undefined
  2024. this.state.projectStatusSearch = undefined //项目状态
  2025. this.state.approvalSearch = undefined
  2026. this.state.outsourceStatusSearch = []
  2027. }
  2028. this.state.id = '' //项目编号
  2029. this.state.orderNo = '' //订单编号
  2030. this.state.projectStatus = undefined //项目状态
  2031. this.state.taskStatuSearch = undefined //项目状态
  2032. this.state.taskComment = '' //说明
  2033. this.state.startDate = '' //启动日期
  2034. this.state.endDate = '' //结束日期
  2035. this.state.acceptDate = '' //受理日期
  2036. this.state.reviewDate = '' //评审日期
  2037. this.state.publicityDate = '' //公示日期
  2038. this.state.licenceDate = '' //发证日期
  2039. this.state.partyTimes = '' //付款时间
  2040. attachmentUrl: [] //附件
  2041. this.state.contacts = '' //联系人
  2042. this.state.contactMobile = '' //联系人电话
  2043. this.state.legalPerson = '' //法人
  2044. this.state.legalPersonTel = '' //法人电话
  2045. this.state.taskId = '' //项目编号
  2046. this.state.hours = '' //工时
  2047. this.state.remarks = '' //说明
  2048. this.state.taskDate = '' //日期
  2049. this.state.taskComment = '' //说明
  2050. this.state.releaseDate = []
  2051. this.state.outsourceName = ''
  2052. this.state.outsourcePrice = undefined
  2053. this.state.distribution = undefined
  2054. this.loadData(this.state.page)
  2055. this.state.companyName = undefined
  2056. this.state.unitPrice = undefined
  2057. this.state.unitNumber = undefined
  2058. this.state.amount = undefined
  2059. this.state.outsourceRemarks = undefined
  2060. this.state.pictureUrl = []
  2061. this.setState({
  2062. oldInfor: {}
  2063. })
  2064. },
  2065. searchSwitch() {
  2066. this.setState({
  2067. searchMore: !this.state.searchMore,
  2068. })
  2069. },
  2070. //部门
  2071. departmentList() {
  2072. this.setState({
  2073. loading: true,
  2074. })
  2075. $.ajax({
  2076. method: 'get',
  2077. dataType: 'json',
  2078. crossDomain: false,
  2079. url: globalConfig.context + '/api/admin/organization/selectSuperId',
  2080. data: {},
  2081. success: function (data) {
  2082. let thedata = data.data
  2083. let theArr = []
  2084. if (!thedata) {
  2085. if (data.error && data.error.length) {
  2086. message.warning(data.error[0].message)
  2087. }
  2088. thedata = {}
  2089. } else {
  2090. thedata.map(function (item, index) {
  2091. theArr.push({
  2092. key: index,
  2093. name: item.name,
  2094. id: item.id,
  2095. })
  2096. })
  2097. }
  2098. this.setState({
  2099. departmentArr: theArr,
  2100. })
  2101. }.bind(this),
  2102. }).always(
  2103. function () {
  2104. this.setState({
  2105. loading: false,
  2106. })
  2107. }.bind(this)
  2108. )
  2109. },
  2110. changeList(arr) {
  2111. const newArr = []
  2112. this.state.columns.forEach((item) => {
  2113. arr.forEach((val) => {
  2114. if (val === item.title) {
  2115. newArr.push(item)
  2116. }
  2117. })
  2118. })
  2119. this.setState({
  2120. changeList: newArr,
  2121. })
  2122. },
  2123. timeClose() {
  2124. this.setState({
  2125. timeVisible: false,
  2126. })
  2127. },
  2128. timeDetail(record) {
  2129. console.log(record)
  2130. this.setState({
  2131. loading: true,
  2132. recordHour: record.hours,
  2133. })
  2134. $.ajax({
  2135. method: 'get',
  2136. dataType: 'json',
  2137. crossDomain: false,
  2138. url:
  2139. globalConfig.context + '/api/admin/orderProject/taskHoursDetailsList',
  2140. data: {
  2141. taskId: record.id,
  2142. },
  2143. success: function (data) {
  2144. if (data.error && data.error.length) {
  2145. message.warning(data.error[0].message)
  2146. } else {
  2147. this.setState({
  2148. dataSourceTime: data.data,
  2149. })
  2150. console.log(this.state.dataSourceTime)
  2151. }
  2152. }.bind(this),
  2153. }).always(
  2154. function () {
  2155. this.setState({
  2156. loading: false,
  2157. })
  2158. }.bind(this)
  2159. )
  2160. },
  2161. showDeleteConfirm(num, fn) {
  2162. let text = getProjectStatus(num)
  2163. confirm({
  2164. title: <p style={{ fontSize: 16, fontWeight: 900 }}>注意</p>,
  2165. content: (
  2166. <p style={{ fontWeight: 900, color: 'red' }}>
  2167. 当前的项目状态为{text},保存后将触发对应的催款节点!!!您确定保存?
  2168. </p>
  2169. ),
  2170. okText: '确定',
  2171. okType: 'danger',
  2172. cancelText: '取消',
  2173. onOk() {
  2174. fn()
  2175. },
  2176. onCancel() {},
  2177. })
  2178. },
  2179. // 项目发起外包
  2180. sureOut(startType) {
  2181. if (this.state.startType !== 0 && this.state.startType !== 1) {
  2182. message.warning('请选择类型')
  2183. return
  2184. }
  2185. //0正常 1专利 2软著 3审计
  2186. if (this.state.projectType === 1) {
  2187. //专利
  2188. if (this.state.patentType === -1) {
  2189. message.warning('请选择专利类型')
  2190. return
  2191. }
  2192. if (this.state.patentNameType === -1) {
  2193. message.warning('请选择专利类型名称')
  2194. return
  2195. }
  2196. if (this.state.patentNameType == 3) {
  2197. if (!this.state.patentName) {
  2198. message.warning('请填写专利名称')
  2199. return
  2200. }
  2201. }
  2202. }
  2203. if (!this.state.outsourceRemarks) {
  2204. message.warning('备注不能为空')
  2205. return
  2206. }
  2207. //refundStatus 0-待审核 ,1-审核通过,2-审核拒绝
  2208. if(!this.state.reason && (this.state.refundStatus === 2 || typeof this.state.refundStatus === 'undefined')){
  2209. message.warning('发起原因不能为空')
  2210. return
  2211. }
  2212. // if (!this.state.pictureUrl && !Array.isArray(this.state.pictureUrl)) {
  2213. // message.warning('合同扫描件不能为空')
  2214. // return
  2215. // }
  2216. // if(this.state.pictureUrl.length === 0){
  2217. // message.warning('合同扫描件不能为空')
  2218. // return
  2219. // }
  2220. let _this = this;
  2221. confirm({
  2222. title: startType === 0 ? '确定要发起外包吗?' : '确定要提交供应商信息吗?',
  2223. content: startType === 0 ? '高于总部价格,费用个人承担' : '确定提交供应商信息后,不可修改',
  2224. onOk() {
  2225. return new Promise((resolve, reject) => {
  2226. _this.setState({
  2227. loading: true,
  2228. })
  2229. let data = {
  2230. tid: _this.state.id,
  2231. orderNo: _this.state.orderNo,
  2232. type: 1, //分类 0订单 1项目
  2233. startType: _this.state.startType, //支付类型 0外包 1供应商 false 0
  2234. companyName: _this.state.companyName,
  2235. amount: _this.state.amount,
  2236. outsourceRemarks: _this.state.outsourceRemarks,
  2237. unitNumber: _this.state.unitNumber,
  2238. unitPrice: _this.state.unitPrice,
  2239. id: _this.state.refundStatus === 2 ? _this.state.mid : undefined,//被拒绝外包申请时,需要传id
  2240. }
  2241. //refundStatus 0-待审核 ,1-审核通过,2-审核拒绝 审核被驳回时和第一次发起外包时,要填写发起原因
  2242. if(_this.state.refundStatus === 2 || typeof _this.state.refundStatus === 'undefined'){
  2243. data.reason = _this.state.reason
  2244. }
  2245. if (_this.state.projectType === 1) {
  2246. data.patentType = _this.state.patentType;
  2247. data.patentNameType = _this.state.patentNameType;
  2248. if (_this.state.patentNameType == 3) {
  2249. data.patentName = _this.state.patentName;
  2250. }
  2251. }
  2252. if (_this.state.pictureUrl && Array.isArray(_this.state.pictureUrl) && _this.state.pictureUrl.length !== 0){
  2253. data.pictureUrl = _this.getUrl(_this.state.pictureUrl).length
  2254. ? _this.getUrl(_this.state.pictureUrl)
  2255. : ''
  2256. }
  2257. $.ajax({
  2258. method: 'POST',
  2259. dataType: 'json',
  2260. crossDomain: false,
  2261. url:
  2262. globalConfig.context + '/api/admin/outsourceOrg/outsourceProjectAudit',
  2263. data: data,
  2264. }).done(
  2265. function (data) {
  2266. _this.setState({
  2267. loading: false,
  2268. })
  2269. if (!data.error.length) {
  2270. resolve();
  2271. message.success('提交成功!')
  2272. _this.visitCancel()
  2273. } else {
  2274. reject();
  2275. message.warning(data.error[0].message)
  2276. }
  2277. }.bind(_this)
  2278. )
  2279. }).catch((err) => console.log(err));
  2280. },
  2281. onCancel() {},
  2282. });
  2283. },
  2284. callback(e) {
  2285. this.setState({
  2286. activeKey: e,
  2287. })
  2288. if (e == 3) {
  2289. this.orderDetailData(this.state.orderNo)
  2290. this.xiangmu(this.state.orderNo)
  2291. this.jiedian(this.state.orderNo)
  2292. this.jiedianNew(this.state.orderNo)
  2293. }
  2294. },
  2295. getOrgCodeUrlWai(e) {
  2296. this.setState({ pictureUrl: e })
  2297. },
  2298. getUrl(url) {
  2299. let theorgCodeUrl = []
  2300. if (url.length) {
  2301. let picArr = []
  2302. url.map(function (item) {
  2303. if (item.response && item.response.data && item.response.data.length) {
  2304. picArr.push(item.response.data)
  2305. }
  2306. })
  2307. theorgCodeUrl = picArr.join(',')
  2308. }
  2309. return theorgCodeUrl
  2310. },
  2311. waiDetail() {
  2312. let url = window.location.href.substring(7)
  2313. this.setState({
  2314. loading: true,
  2315. })
  2316. $.ajax({
  2317. method: 'get',
  2318. dataType: 'json',
  2319. crossDomain: false,
  2320. url:
  2321. globalConfig.context + '/api/admin/outsourceOrg/orderOutsourceDtails',
  2322. data: {
  2323. tid: this.state.id,
  2324. orderNo: this.state.orderNo,
  2325. },
  2326. }).done(
  2327. function (data) {
  2328. this.setState({
  2329. loading: false,
  2330. })
  2331. if (!data.error.length && data.data) {
  2332. if(data.data.unitNumber){
  2333. this.setState({
  2334. oldInfor: {
  2335. companyName:data.data.companyName,
  2336. unitPrice:data.data.unitPrice,
  2337. unitNumber:data.data.unitNumber,
  2338. amount:data.data.amount,
  2339. outsourceRemarks:data.data.outsourceRemarks,
  2340. refundStatus: data.data.refundStatus,
  2341. pictureUrl: data.data.pictureUrl
  2342. ? splitUrl(
  2343. data.data.pictureUrl,
  2344. ',',
  2345. globalConfig.avatarHost + '/upload',
  2346. url
  2347. )
  2348. : [], //图片地址
  2349. },
  2350. })
  2351. }else{
  2352. this.setState({
  2353. oldInfor: {},
  2354. })
  2355. }
  2356. this.setState({
  2357. startType: data.data.startType, //类型
  2358. patentType: data.data.patentType, //专利类型
  2359. patentNameType: data.data.patentNameType, //专利名称类型
  2360. patentName: data.data.patentName, //专利名称
  2361. outsourceRemarks: data.data.outsourceRemarks,
  2362. remarks: data.data.remarks,
  2363. companyName: data.data.companyName,
  2364. amount: data.data.amount,
  2365. mid: data.data.id,
  2366. unitPrice: data.data.unitPrice,
  2367. refundStatus: data.data.refundStatus,
  2368. unitNumber: data.data.unitNumber, //如果存在 证明是以前的旧数据
  2369. pictureUrl: data.data.pictureUrl
  2370. ? splitUrl(
  2371. data.data.pictureUrl,
  2372. ',',
  2373. globalConfig.avatarHost + '/upload',
  2374. url
  2375. )
  2376. : [], //图片地址
  2377. createTimes: data.data.createTimes,
  2378. auditTimes: data.data.auditTimes,
  2379. })
  2380. } else if (data.error && data.error.length) {
  2381. message.warning(data.error[0].message)
  2382. } else if (!data.data) {
  2383. this.setState({
  2384. refundStatus: undefined,
  2385. })
  2386. }
  2387. }.bind(this)
  2388. )
  2389. },
  2390. rizhi() {
  2391. this.setState({
  2392. loading: true,
  2393. })
  2394. $.ajax({
  2395. method: 'get',
  2396. dataType: 'json',
  2397. crossDomain: false,
  2398. url: '/api/admin/newOrder/selectOrderLog',
  2399. data: {
  2400. orderNo: this.state.orderNo,
  2401. },
  2402. success: function (data) {
  2403. let theArr = []
  2404. let thisData = data.data
  2405. if (!thisData.length) {
  2406. if (data.error && data.error.length) {
  2407. message.warning(data.error[0].message)
  2408. }
  2409. thisData = {}
  2410. } else {
  2411. for (let i = 0; i < data.data.length; i++) {
  2412. let thisdata = data.data[i]
  2413. theArr.push({
  2414. processName: thisdata.processName,
  2415. adminName: thisdata.adminName,
  2416. createDate: thisdata.createDate,
  2417. remarks: thisdata.remarks,
  2418. })
  2419. }
  2420. }
  2421. this.setState({
  2422. dataSourceY: theArr,
  2423. })
  2424. }.bind(this),
  2425. }).always(
  2426. function () {
  2427. this.setState({
  2428. loading: false,
  2429. })
  2430. }.bind(this)
  2431. )
  2432. },
  2433. closeOrderLog() {
  2434. this.setState({
  2435. avisible: false,
  2436. })
  2437. },
  2438. getOrderLog() {
  2439. this.setState({
  2440. avisible: true,
  2441. })
  2442. this.rizhi()
  2443. },
  2444. orderChange(key) {
  2445. this.setState({
  2446. activeKey: key,
  2447. })
  2448. if (key == 3) {
  2449. this.orderDetailData(this.state.orderNo)
  2450. this.xiangmu(this.state.orderNo)
  2451. this.jiedian(this.state.orderNo)
  2452. this.jiedianNew(this.state.orderNo)
  2453. }
  2454. if (key == 2) {
  2455. this.waiDetail()
  2456. }
  2457. },
  2458. //节点列表
  2459. jiedian(orderNos) {
  2460. $.ajax({
  2461. method: 'get',
  2462. dataType: 'json',
  2463. crossDomain: false,
  2464. url: globalConfig.context + '/api/admin/newOrder/selectOrderDun',
  2465. data: {
  2466. orderNo: orderNos,
  2467. },
  2468. success: function (data) {
  2469. let theArr = []
  2470. let thisData = []
  2471. if (data.error.length || data.data.list == '') {
  2472. if (data.error && data.error.length) {
  2473. message.warning(data.error[0].message)
  2474. }
  2475. } else {
  2476. for (let i = 0; i < data.data.length; i++) {
  2477. thisData = data.data[i]
  2478. theArr.push({
  2479. key: i,
  2480. dunSubject: thisData.dunSubject
  2481. ? thisData.dunSubject.toString()
  2482. : '', //催款科目
  2483. id: thisData.id, //节点Id
  2484. money: thisData.money, //催款金额
  2485. dunStatus: thisData.dunStatus, //催款状态
  2486. })
  2487. }
  2488. this.setState({
  2489. jiedian: theArr,
  2490. })
  2491. }
  2492. }.bind(this),
  2493. })
  2494. },
  2495. jiedianNew(orderNos) {
  2496. $.ajax({
  2497. method: 'get',
  2498. dataType: 'json',
  2499. crossDomain: false,
  2500. url:
  2501. globalConfig.context + '/api/admin/newOrderDun/selectListNewOrderDun',
  2502. data: {
  2503. orderNo: orderNos,
  2504. },
  2505. success: function (data) {
  2506. if (data.error && data.error.length) {
  2507. message.warning(data.error[0].message)
  2508. } else {
  2509. let theArr = []
  2510. let thisData = []
  2511. let arr = data.data || []
  2512. let totalCui = 0
  2513. for (let i = 0; i < arr.length; i++) {
  2514. thisData = arr[i]
  2515. totalCui += +thisData.money
  2516. theArr.push({
  2517. key: i,
  2518. dunSubject: thisData.dunSubject
  2519. ? thisData.dunSubject.toString()
  2520. : '', //催款科目
  2521. id: thisData.id, //节点Id
  2522. tid: thisData.tid, //节点指定的第三方id
  2523. money: thisData.money, //催款金额
  2524. // orderNo: record ? record.orderNo : this.props.datauser.orderNo,
  2525. commodityName: thisData.commodityName,
  2526. projectType: thisData.projectType,
  2527. dunTypeName: thisData.dunTypeName,
  2528. status: thisData.status,
  2529. waitDay: thisData.waitDay,
  2530. effectiveCount: thisData.effectiveCount,
  2531. startDate: thisData.startDate,
  2532. dunType: thisData.dunType,
  2533. appropriationRatio: thisData.appropriationRatio,
  2534. customizeName: thisData.customizeName,
  2535. customizeTimes: thisData.customizeTimes,
  2536. })
  2537. }
  2538. if (!totalCui) {
  2539. totalCui = 0
  2540. }
  2541. totalCui = (Math.round(totalCui * 1000000) / 1000000).toFixed(6)
  2542. this.setState({
  2543. jiedianNew: theArr,
  2544. totalCui,
  2545. })
  2546. }
  2547. }.bind(this),
  2548. }).always(
  2549. function () {
  2550. this.setState({
  2551. loading: false,
  2552. })
  2553. }.bind(this)
  2554. )
  2555. },
  2556. orderDetailData(orderNos) {
  2557. this.setState({
  2558. loading: true,
  2559. })
  2560. $.ajax({
  2561. method: 'get',
  2562. dataType: 'json',
  2563. crossDomain: false,
  2564. url: globalConfig.context + '/api/admin/newOrder/getOrderNewDetail',
  2565. data: {
  2566. orderNo: orderNos,
  2567. },
  2568. success: function (data) {
  2569. if (data.error.length || data.data.list == '') {
  2570. if (data.error && data.error.length) {
  2571. message.warning(data.error[0].message)
  2572. this.setState({
  2573. loading: false,
  2574. })
  2575. }
  2576. } else {
  2577. let thisdata = data.data
  2578. this.setState({
  2579. loading: false,
  2580. userName: thisdata.userName,
  2581. primaryOrderNo: thisdata.primaryOrder,
  2582. additionalOrder: thisdata.additionalOrder,
  2583. contractNo: thisdata.contractNo,
  2584. orderData: thisdata,
  2585. isAddition: thisdata.additionalOrder ? true : false,
  2586. contractPictureUrl: thisdata.contractPictureUrl
  2587. ? splitUrl(
  2588. thisdata.contractPictureUrl,
  2589. ',',
  2590. globalConfig.avatarHost + '/upload'
  2591. )
  2592. : [],
  2593. })
  2594. }
  2595. }.bind(this),
  2596. })
  2597. },
  2598. //点击新增供应商
  2599. addcontactNew() {
  2600. this.state.contactListNew.push({
  2601. key: this.state.contactListNew.length,
  2602. money: '',
  2603. dunSubject: undefined,
  2604. orderNo: this.state.orderNo,
  2605. dunTarget: this.state.kehuId,
  2606. })
  2607. this.setState({
  2608. contactListNew: this.state.contactListNew,
  2609. cuiFlag: true,
  2610. })
  2611. },
  2612. //查看第三方信息表格
  2613. thirdTable(id) {
  2614. this.setState({
  2615. loadData: true,
  2616. })
  2617. $.ajax({
  2618. method: 'get',
  2619. dataType: 'json',
  2620. crossDomain: false,
  2621. url: globalConfig.context + '/api/admin/company/selectCompany',
  2622. data: {
  2623. tid: id,
  2624. },
  2625. success: function (data) {
  2626. if (data.error && data.error.length) {
  2627. message.warning(data.error[0].message)
  2628. } else {
  2629. let companyNameArr = []
  2630. let theArr = []
  2631. let thisData = []
  2632. let arr = data.data || []
  2633. let allTotalAmount = 0
  2634. let type = 0;
  2635. let patentNameType = 0;
  2636. for (let i = 0; i < arr.length; i++) {
  2637. thisData = arr[i]
  2638. allTotalAmount =
  2639. (allTotalAmount * 10000 + thisData.totalAmount * 10000) / 10000
  2640. companyNameArr.push(thisData.companyName);
  2641. thisData.key = i;
  2642. thisData.patentType = thisData.type;
  2643. theArr.push(thisData);
  2644. type=thisData.type
  2645. patentNameType= thisData.patentNameType
  2646. }
  2647. if (!allTotalAmount) {
  2648. allTotalAmount = 0
  2649. }
  2650. for(let d=0;d<theArr.length;d++){
  2651. theArr[d].companyName = theArr[d].companyName+ '-' + theArr[d].id;
  2652. companyNameArr[d] = {
  2653. companyName: theArr[d].companyName,
  2654. id: theArr[d].id,
  2655. }
  2656. }
  2657. if(type === 1 || type === 2){
  2658. this.setState({
  2659. patentType: type === 1 ? 0 : type === 2 ? 1 : -1, //0其他 1专利申请 2专利买卖
  2660. patentNameType: patentNameType, //0实用新型 1发明专利 2外观专利 3 其他
  2661. })
  2662. }
  2663. this.setState({
  2664. tid: id,
  2665. PayNodeCompany: companyNameArr,
  2666. thirdInfoList: theArr,
  2667. allTotalAmount: allTotalAmount,
  2668. },()=>{
  2669. this.projectTypeTabContent(this.state.projectType);
  2670. })
  2671. }
  2672. }.bind(this),
  2673. }).always(
  2674. function () {
  2675. this.setState({
  2676. loading: false,
  2677. })
  2678. }.bind(this)
  2679. )
  2680. },
  2681. //外包日志列表
  2682. getSelectOutsourceLog(tid){
  2683. $.ajax({
  2684. method: 'get',
  2685. dataType: 'json',
  2686. crossDomain: false,
  2687. url: globalConfig.context + '/api/admin/outsourceOrg/selectOutsourceLog',
  2688. data: {
  2689. tid: tid,
  2690. },
  2691. success: function (data) {
  2692. if (data.error.length) {
  2693. if (data.error && data.error.length) {
  2694. message.warning(data.error[0].message);
  2695. }
  2696. } else {
  2697. this.setState({
  2698. outsourceLogs: data.data
  2699. })
  2700. }
  2701. }.bind(this),
  2702. }).always(
  2703. function () {
  2704. }.bind(this)
  2705. )
  2706. },
  2707. payNodeTable(id) {
  2708. this.setState({
  2709. loadData: true,
  2710. })
  2711. $.ajax({
  2712. method: 'get',
  2713. dataType: 'json',
  2714. crossDomain: false,
  2715. url: globalConfig.context + '/api/admin/company/selectPaymentNode',
  2716. data: {
  2717. tid: id,
  2718. },
  2719. success: function (data) {
  2720. if (data.error && data.error.length) {
  2721. message.warning(data.error[0].message)
  2722. } else {
  2723. let payNodeArr = []
  2724. let thisData = []
  2725. let arr = data.data || []
  2726. // console.log('this.state.paySubject', this.state.paySubject)
  2727. //对#5283自定义的补充展示
  2728. this.state.paySubject.push({ key: '自定义', value: '0' })
  2729. for (let i = 0; i < arr.length; i++) {
  2730. thisData = arr[i]
  2731. //遍历paySubject,获取当前dunType对应的key
  2732. this.state.paySubject.map((item) => {
  2733. if (item.value == thisData.dunType) {
  2734. thisData.dunType = item.key
  2735. }
  2736. })
  2737. payNodeArr.push({
  2738. key: i,
  2739. id: thisData.id, //付款节点Id
  2740. nodeId: thisData.id, //付款节点Id
  2741. tid: thisData.tid,
  2742. companyName: thisData.companyName, //供应商名称
  2743. projectType: thisData.projectType, //项目分类
  2744. dunType: thisData.dunType, //催款分类
  2745. unitPrice: thisData.unitPrice, //单价
  2746. quantity: thisData.quantity, //数量
  2747. totalAmount: thisData.totalAmount, //总价
  2748. partyAmount: thisData.partyAmount, //付款
  2749. partyTimes: thisData.partyTimes, //付款时间
  2750. cid: thisData.cid, //机构id
  2751. status: thisData.status, //催款状态 0-未支付 1-待全款 ,2已全款 status=2的时候已经全款,申请付款按钮可以去掉了
  2752. })
  2753. }
  2754. for(let d=0;d<payNodeArr.length;d++){
  2755. payNodeArr[d].companyName = payNodeArr[d].companyName+ '-' + payNodeArr[d].cid;
  2756. }
  2757. console.log('payNodeArr:', payNodeArr)
  2758. this.setState({
  2759. tid: id,
  2760. payNodeList: payNodeArr,
  2761. })
  2762. }
  2763. }.bind(this),
  2764. }).always(
  2765. function () {
  2766. this.setState({
  2767. loading: false,
  2768. })
  2769. }.bind(this)
  2770. )
  2771. },
  2772. // 新增第三方供应商信息
  2773. addThirdList() {
  2774. this.setState({
  2775. ThirdListVisible: true,
  2776. })
  2777. },
  2778. // 新增支付节点
  2779. addPayNode() {
  2780. this.setState({
  2781. PayNodeVisible: true,
  2782. })
  2783. },
  2784. // 第三方信息自动计算总金额
  2785. calculatedAmount() {
  2786. let currentTotalPrice
  2787. currentTotalPrice = this.state.thirdUnitPrice * this.state.thirdQuantity
  2788. currentTotalPrice = currentTotalPrice.toFixed(6)
  2789. this.setState({
  2790. currentTotalPrice: currentTotalPrice,
  2791. })
  2792. },
  2793. // 付款节点自动计算总金额
  2794. payNodeCalculatedAmount(num) {
  2795. let currentTotalPrice,quantity,unitPrice
  2796. //获取当前供应商名称对应的单价并更新
  2797. this.state.thirdInfoList.forEach((item) => {
  2798. if (item.companyName === this.state.thirdCompanyName) {
  2799. currentTotalPrice = num ? item.unitPrice * num : item.quantity * item.unitPrice;
  2800. currentTotalPrice = currentTotalPrice.toFixed(6);
  2801. quantity = num ? num : item.quantity;
  2802. unitPrice = item.unitPrice;
  2803. }
  2804. })
  2805. this.setState({
  2806. payNodeQuantity: num ? num : quantity,
  2807. })
  2808. if(this.state.projectType !== 2){
  2809. this.setState({
  2810. currentTotalPrice: currentTotalPrice,
  2811. thirdUnitPrice: unitPrice
  2812. })
  2813. }
  2814. },
  2815. // 保存供应商信息
  2816. handleCancelq() {
  2817. let api
  2818. if (this.state.ThirdId) {
  2819. //修改
  2820. api = '/api/admin/company/updateCompany'
  2821. } else {
  2822. //新增
  2823. api = '/api/admin/company/addCompany'
  2824. }
  2825. let customerId = 0;
  2826. let isHave =this.state.customerArr.some((value)=>{
  2827. if(value.companyName === this.state.thirdCompanyName){
  2828. customerId = value.id
  2829. return true;
  2830. }
  2831. });
  2832. if(!isHave && this.state.projectType !== 0){
  2833. message.warning('请输入正确的供应商名称')
  2834. return;
  2835. }
  2836. this.setState({
  2837. loading: true,
  2838. })
  2839. // material: this.state.thirdMaterial, //材料
  2840. // urgent: this.state.thirdUrgent, //加急
  2841. // unitPrice: this.state.thirdUnitPrice, //单价
  2842. let data = {
  2843. id: this.state.ThirdId, //id
  2844. tid: this.state.tid, //订单编号
  2845. companyName: this.state.thirdCompanyName, //第三方名称
  2846. quantity: this.state.thirdQuantity, //数量
  2847. // totalAmount: this.state.currentTotalPrice, //总价
  2848. remarks: this.state.thirdRemarks, //备注
  2849. }
  2850. if(this.state.projectType === 0){
  2851. data.unitPrice = this.state.thirdUnitPrice;
  2852. }
  2853. if(isHave){
  2854. data.cid = customerId ////公司id
  2855. }
  2856. $.ajax({
  2857. url: globalConfig.context + api,
  2858. method: 'post',
  2859. dataType: 'json',
  2860. crossDomain: false,
  2861. data: data,
  2862. }).done(
  2863. function (data) {
  2864. this.setState({
  2865. loading: false,
  2866. })
  2867. if (!data.error.length) {
  2868. message.success('保存成功!')
  2869. this.setState({
  2870. ThirdId: '',
  2871. ThirdListVisible: false,
  2872. thirdCompanyName: '', //第三方名称
  2873. thirdUnitPrice: '', //单价
  2874. thirdQuantity: '', //数量
  2875. currentTotalPrice: '', //总价
  2876. thirdRemarks: '',
  2877. thirdUrgent: 0,
  2878. })
  2879. // this.visitCancel();
  2880. this.thirdTable(this.state.tid)
  2881. } else {
  2882. message.warning(data.error[0].message)
  2883. }
  2884. }.bind(this)
  2885. )
  2886. },
  2887. //保存付款节点
  2888. savePayNode() {
  2889. let api
  2890. if (this.state.ThirdId) {
  2891. //修改
  2892. api = '/api/admin/company/updatePaymentNode'
  2893. } else {
  2894. //新增
  2895. api = '/api/admin/company/addPaymentNode'
  2896. }
  2897. // totalAmount: this.state.currentTotalPrice, //总价
  2898. // partyAmount: this.state.partyAmount, //付款金额
  2899. //
  2900. let customerId=0;
  2901. this.state.PayNodeCompany.some((value)=>{
  2902. if(value.companyName === this.state.thirdCompanyName){
  2903. customerId = value.id
  2904. return true;
  2905. }
  2906. });
  2907. if(!this.state.thirdCompanyName){
  2908. message.error('请选择供应商名称');
  2909. return;
  2910. }
  2911. if(!this.state.paySubjectName){
  2912. message.error('请选择付款科目');
  2913. return;
  2914. }
  2915. if(!this.state.payNodeQuantity){
  2916. message.error('请输入数量');
  2917. return;
  2918. }
  2919. let data = {
  2920. id: this.state.ThirdId, //id
  2921. tid: this.state.tid, //订单编号
  2922. cid: customerId,//对应的第三方信息
  2923. companyName: this.state.thirdCompanyName.split('-')[0], //第三方名称
  2924. quantity: this.state.payNodeQuantity, //数量
  2925. dunType: this.state.dunType, //催款节点
  2926. projectType: this.state.cSort, //项目分类
  2927. }
  2928. if(this.state.paySubjectName === '0'){
  2929. if(!this.state.partyTimes){
  2930. message.error('请选择付款时间');
  2931. return;
  2932. }
  2933. data.partyTimes = this.state.partyTimes //付款时间
  2934. }
  2935. if(this.state.projectType !== 2){ //其他类型 0正常 1专利 2软著 3审计
  2936. data.totalAmount = this.state.currentTotalPrice //总价
  2937. data.unitPrice = this.state.thirdUnitPrice //单价
  2938. }
  2939. this.setState({
  2940. loading: true,
  2941. })
  2942. $.ajax({
  2943. url: globalConfig.context + api,
  2944. method: 'post',
  2945. dataType: 'json',
  2946. crossDomain: false,
  2947. data: data,
  2948. }).done(
  2949. function (data) {
  2950. this.setState({
  2951. loading: false,
  2952. })
  2953. if (!data.error.length) {
  2954. message.success('保存成功!')
  2955. this.setState({
  2956. ThirdId: '',
  2957. PayNodeVisible: false,
  2958. thirdCompanyName: '', //第三方名称
  2959. paySubjectName: '', //付款科目名称
  2960. thirdUnitPrice: '', //单价
  2961. thirdQuantity: '', //数量
  2962. payNodeQuantity: 1, //付款节点数量
  2963. currentTotalPrice: '', //总价
  2964. partyAmount: '', //付款金额
  2965. partyTimes: '', //付款时间
  2966. dunType: '', //催款节点
  2967. })
  2968. // this.visitCancel();
  2969. this.payNodeTable(this.state.tid)
  2970. } else {
  2971. message.warning(data.error[0].message)
  2972. }
  2973. }.bind(this)
  2974. )
  2975. },
  2976. // 取消
  2977. handleCancelclose() {
  2978. this.setState({
  2979. PayNodeVisible: false,
  2980. payNodeInfor: {},
  2981. ThirdId: '',
  2982. ThirdListVisible: false,
  2983. thirdCompanyName: '', //第三方名称
  2984. paySubjectName: '', //付款科目名称
  2985. thirdUnitPrice: '', //单价
  2986. partyTimes: '',
  2987. thirdQuantity: 1, //数量
  2988. payNodeQuantity: 1,
  2989. currentTotalPrice: '', //总价
  2990. thirdRemarks: '',
  2991. thirdUrgent: 0, //加急状态
  2992. })
  2993. },
  2994. // 删除供应商信息
  2995. confirmDeletNew(index,resolve=()=>{},reject=()=>{}) {
  2996. this.setState({
  2997. loading: true,
  2998. ThirdListVisible: false,
  2999. })
  3000. let id = '';
  3001. if(index === -1){
  3002. if(this.state.thirdInfoList.length === 1){
  3003. id = this.state.thirdInfoList[0].id
  3004. }else{
  3005. this.state.thirdInfoList.map((value,index)=>{
  3006. id+=value.id+',';
  3007. })
  3008. }
  3009. }else{
  3010. id = index.id
  3011. }
  3012. $.ajax({
  3013. url: globalConfig.context + '/api/admin/company/deleteCompany',
  3014. method: 'post',
  3015. data: {
  3016. id: id,
  3017. },
  3018. }).done(
  3019. function (data) {
  3020. this.setState({
  3021. loading: false,
  3022. })
  3023. if (!data.error.length) {
  3024. message.success('删除成功!')
  3025. this.thirdTable(this.state.tid)
  3026. resolve();
  3027. } else {
  3028. message.warning(data.error[0].message)
  3029. reject();
  3030. }
  3031. }.bind(this)
  3032. )
  3033. },
  3034. // 删除付款节点
  3035. payNodeConfirmDeletNew(index,resolve=()=>{},reject=()=>{}) {
  3036. this.setState({
  3037. loading: true,
  3038. PayNodeVisible: false,
  3039. })
  3040. let id = '';
  3041. if(index === -1){
  3042. this.state.payNodeList.map((value,index)=>{
  3043. id+=value.id+',';
  3044. })
  3045. }else{
  3046. id = index.id
  3047. }
  3048. $.ajax({
  3049. url: globalConfig.context + '/api/admin/company/deletePaymentNode',
  3050. method: 'post',
  3051. data: {
  3052. id: id,
  3053. },
  3054. }).done(
  3055. function (data) {
  3056. this.setState({
  3057. loading: false,
  3058. })
  3059. if (!data.error.length) {
  3060. message.success('删除成功!')
  3061. resolve();
  3062. this.payNodeTable(this.state.tid)
  3063. } else {
  3064. message.warning(data.error[0].message)
  3065. reject();
  3066. }
  3067. }.bind(this)
  3068. )
  3069. },
  3070. //点击供应商详情
  3071. tableRowClickOne(record) {
  3072. this.setState({
  3073. ThirdListVisible: true,
  3074. ThirdId: record.id, //供应商id
  3075. thirdCompanyName: record.companyName, //第三方名称
  3076. thirdUnitPrice: record.unitPrice, //单价
  3077. thirdQuantity: record.quantity, //数量
  3078. currentTotalPrice: record.totalAmount, //总价
  3079. thirdMaterial: record.material, //有无材料
  3080. thirdUrgent: record.urgent, //加急情况
  3081. thirdRemarks: record.remarks,
  3082. audit: record.audit,//审计
  3083. assets: record.assets,//公司资产
  3084. income: record.income,//收入
  3085. })
  3086. },
  3087. //点击付款节点详情
  3088. payNodeTableRowClickOne(record) {
  3089. this.setState({
  3090. PayNodeVisible: true,
  3091. ThirdId: record.id, //供应商id
  3092. thirdCompanyName: record.companyName, //第三方名称
  3093. thirdUnitPrice: record.unitPrice, //单价
  3094. thirdQuantity: record.quantity, //供应商数量
  3095. payNodeQuantity: record.quantity, //付款节点数量
  3096. currentTotalPrice: record.totalAmount, //总价
  3097. partyTimes: record.partyTimes,
  3098. paySubjectName: record.dunType,
  3099. });
  3100. let obj = JSON.parse(JSON.stringify(record));
  3101. this.state.paySubject.some((value)=>{
  3102. if(value.key === obj.dunType){
  3103. obj.dunType = value.value;
  3104. return true;
  3105. }
  3106. });
  3107. this.setState({
  3108. payNodeInfor: obj, //付款节点详情
  3109. });
  3110. },
  3111. render() {
  3112. const formItemLayout = {
  3113. labelCol: { span: 8 },
  3114. wrapperCol: { span: 14 },
  3115. }
  3116. let departmentArr = this.state.departmentArr || []
  3117. return (
  3118. <div className="user-content">
  3119. {this.state.resVisible ? (
  3120. <ResolutionDetail
  3121. cancel={this.resCancel}
  3122. detail={this.state.resRecord}
  3123. visible={this.state.resVisible}
  3124. id={this.state.resRecord.orderNo}
  3125. />
  3126. ) : (
  3127. ''
  3128. )}
  3129. <ShowModalDiv ShowModal={this.state.showModal} />
  3130. <div className="content-title" style={{ marginBottom: 10 }}>
  3131. <span style={{ fontWeight: 900, fontSize: 16 }}>项目任务</span>
  3132. </div>
  3133. <Tabs defaultActiveKey="2" className="test" bordered>
  3134. <TabPane tab="更改表格显示数据" key="1">
  3135. <div style={{ marginLeft: 10 }}>
  3136. <ChooseList
  3137. columns={this.state.columns}
  3138. changeFn={this.changeList}
  3139. changeList={this.state.changeList}
  3140. top={55}
  3141. margin={11}
  3142. />
  3143. </div>
  3144. </TabPane>
  3145. <TabPane tab="搜索" key="2">
  3146. <div className="user-search" style={{ marginLeft: 10 }}>
  3147. <Input
  3148. placeholder="客户名称"
  3149. value={this.state.nameSearch}
  3150. onChange={(e) => {
  3151. this.setState({ nameSearch: e.target.value })
  3152. }}
  3153. />
  3154. <Input
  3155. placeholder="订单编号"
  3156. value={this.state.orderNoSearch}
  3157. onChange={(e) => {
  3158. this.setState({ orderNoSearch: e.target.value })
  3159. }}
  3160. />
  3161. <Input
  3162. placeholder="合同编号"
  3163. value={this.state.contractNoSearch}
  3164. onChange={(e) => {
  3165. this.setState({ contractNoSearch: e.target.value })
  3166. }}
  3167. />
  3168. <Input
  3169. placeholder="项目编号"
  3170. value={this.state.taskNoSearch}
  3171. onChange={(e) => {
  3172. this.setState({ taskNoSearch: e.target.value })
  3173. }}
  3174. />
  3175. <Select
  3176. placeholder="选择部门"
  3177. style={{ width: 150, marginRight: '10px' }}
  3178. value={this.state.departmenttSearch}
  3179. onChange={(e) => {
  3180. this.setState({ departmenttSearch: e })
  3181. }}
  3182. >
  3183. {departmentArr.map(function (item) {
  3184. return (
  3185. <Select.Option key={item.id}>{item.name}</Select.Option>
  3186. )
  3187. })}
  3188. </Select>
  3189. <Select
  3190. placeholder="项目状态"
  3191. style={{ width: 150, marginRight: '10px' }}
  3192. value={this.state.projectStatusSearch}
  3193. onChange={(e) => {
  3194. this.setState({ projectStatusSearch: e })
  3195. console.log(this.state.projectStatusSearch)
  3196. }}
  3197. >
  3198. {projectStatus.map(function (item) {
  3199. return (
  3200. <Select.Option key={item.value}>{item.key}</Select.Option>
  3201. )
  3202. })}
  3203. </Select>
  3204. <Select
  3205. placeholder="特批状态"
  3206. style={{ width: 150, marginRight: '10px' }}
  3207. value={this.state.approvalSearch}
  3208. onChange={(e) => {
  3209. this.setState({ approvalSearch: e })
  3210. console.log(this.state.approvalSearch)
  3211. }}
  3212. >
  3213. <Select.Option key={0}>非特批</Select.Option>
  3214. <Select.Option key={1}>特批</Select.Option>
  3215. </Select>
  3216. <Select
  3217. placeholder="外包状态"
  3218. style={{ width: 150, marginRight: '10px' }}
  3219. value={this.state.outsourceStatusSearch}
  3220. onChange={(e) => {
  3221. this.setState({ outsourceStatusSearch: e })
  3222. console.log(this.state.outsourceStatusSearch)
  3223. }}
  3224. >
  3225. <Select.Option key={0}>外包待审核</Select.Option>
  3226. {/* <Select.Option key={1}>外包审核通过</Select.Option> */}
  3227. <Select.Option key={2}>外包审核驳回</Select.Option>
  3228. <Select.Option key={999}>全部</Select.Option>
  3229. </Select>
  3230. <Button type="primary" onClick={this.search}>
  3231. 搜索
  3232. </Button>
  3233. <Button
  3234. onClick={(e) => {
  3235. this.reset(true)
  3236. }}
  3237. >
  3238. 重置
  3239. </Button>
  3240. {/* <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  3241. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  3242. <span>订单时间 :</span>
  3243. <RangePicker
  3244. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  3245. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  3246. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  3247. </div> */}
  3248. </div>
  3249. </TabPane>
  3250. <TabPane tab="导出Excel" key="3">
  3251. <Button
  3252. type="primary"
  3253. style={{ margin: '11px 0 10px 10px' }}
  3254. onClick={this.exportExec}
  3255. >
  3256. 导出Excel
  3257. </Button>
  3258. </TabPane>
  3259. {/* <TabPane tab="批量操作" key="6">
  3260. <Button
  3261. type="primary"
  3262. disabled={this.state.selectedRowKeys.length == 0}
  3263. style={{ margin: "0px 0px 10px 10px" }}
  3264. onClick={e => {
  3265. e.stopPropagation(),
  3266. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  3267. }}
  3268. >
  3269. 转交
  3270. </Button>
  3271. </TabPane> */}
  3272. </Tabs>
  3273. {/* <div className="user-search">
  3274. <Input
  3275. placeholder="客户名称"
  3276. value={this.state.nameSearch}
  3277. onChange={e => {
  3278. this.setState({ nameSearch: e.target.value });
  3279. }}
  3280. />
  3281. <Input
  3282. placeholder="订单编号"
  3283. value={this.state.orderNoSearch}
  3284. onChange={e => {
  3285. this.setState({ orderNoSearch: e.target.value });
  3286. }}
  3287. />
  3288. <Input
  3289. placeholder="项目编号"
  3290. value={this.state.taskNoSearch}
  3291. onChange={e => {
  3292. this.setState({ taskNoSearch: e.target.value });
  3293. }}
  3294. />
  3295. <Select
  3296. placeholder="选择部门"
  3297. style={{ width: 150, marginRight: "10px" }}
  3298. value={this.state.departmenttSearch}
  3299. onChange={e => {
  3300. this.setState({ departmenttSearch: e });
  3301. }}
  3302. >
  3303. {departmentArr.map(function(item) {
  3304. return <Select.Option key={item.id}>{item.name}</Select.Option>;
  3305. })}
  3306. </Select>
  3307. <Button type="primary" onClick={this.search}>
  3308. 搜索
  3309. </Button>
  3310. <Button onClick={this.reset}>重置</Button>
  3311. <Button
  3312. type="primary"
  3313. style={{ marginLeft: "10px" }}
  3314. onClick={this.exportExec}
  3315. >
  3316. 导出Excel
  3317. </Button>
  3318. <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  3319. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  3320. <span>订单时间 :</span>
  3321. <RangePicker
  3322. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  3323. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  3324. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  3325. </div>
  3326. </div> */}
  3327. <div className="patent-table">
  3328. <Spin spinning={this.state.loading}>
  3329. <Table
  3330. columns={
  3331. this.state.changeList == undefined
  3332. ? this.state.columns
  3333. : this.state.changeList
  3334. }
  3335. dataSource={this.state.dataSource}
  3336. pagination={this.state.pagination}
  3337. scroll={{ x: 'max-content', y: 0 }}
  3338. onRowClick={this.tableRowClick.bind(this)}
  3339. bordered
  3340. size={'small'}
  3341. />
  3342. </Spin>
  3343. </div>
  3344. <Assign
  3345. title="项目"
  3346. selApi={'/api/admin/orderProject/projectDistribution'}
  3347. data={this.state.assignData}
  3348. showDesc={this.state.assignVisible}
  3349. closeDesc={this.closeAssign.bind(this)}
  3350. fenpaiData={8}
  3351. specially={0}
  3352. roleName={this.state.nub}
  3353. requestMethod={'post'}
  3354. flag={this.state.flag}
  3355. all={this.state}
  3356. />
  3357. {this.state.visible ? <Modal
  3358. className="customeDetails"
  3359. footer=""
  3360. title=""
  3361. width="900px"
  3362. visible={this.state.visible}
  3363. onOk={this.visitOk}
  3364. onCancel={this.visitCancel}
  3365. >
  3366. <Tabs
  3367. tabBarExtraContent={
  3368. <div style={{fontWeight:'bold',paddingRight:'15px'}}>
  3369. <span>
  3370. 项目名称:
  3371. <span style={{color:'#F00',paddingRight:'5px'}}>{this.state.taskName}</span>
  3372. </span>
  3373. <span style={{marginLeft:'15px'}}>
  3374. 项目编号:
  3375. <span style={{color:'#F00',paddingRight:'5px'}}>
  3376. {this.state.id}
  3377. {
  3378. this.state.splitStatus === 2 ? '('+this.state.splitSuper+'-'+this.state.splitId+')' : ''
  3379. }
  3380. </span>
  3381. </span>
  3382. </div>
  3383. }
  3384. activeKey={this.state.activeKey}
  3385. onChange={(e) => {
  3386. this.callback(e)
  3387. if (e == 2) {
  3388. this.waiDetail();
  3389. this.thirdTable(this.state.tid);
  3390. this.payNodeTable(this.state.tid);
  3391. this.getSelectOutsourceLog(this.state.tid);
  3392. }
  3393. }}
  3394. >
  3395. <TabPane tab="项目概况" key="1">
  3396. {this.state.activeKey === "1" ? <Form
  3397. layout="horizontal"
  3398. onSubmit={this.handleSubmit}
  3399. id="demand-form"
  3400. style={{ paddingBottom: '00px' }}
  3401. >
  3402. <Spin spinning={this.state.loading}>
  3403. <div className="clearfix">
  3404. <div className="clearfix">
  3405. <FormItem
  3406. className="half-item"
  3407. {...formItemLayout}
  3408. label="当前项目情况"
  3409. >
  3410. <Radio.Group
  3411. value={this.state.status}
  3412. onChange={(e) => {
  3413. this.setState({ status: e.target.value })
  3414. }}
  3415. >
  3416. <Radio value={0}>开启</Radio>
  3417. <Radio value={1}>暂停</Radio>
  3418. </Radio.Group>
  3419. <Button
  3420. type="primary"
  3421. size="small"
  3422. style={{ marginTop: '5px', position: 'absolute' }}
  3423. onClick={this.caozuorizhi}
  3424. >
  3425. 操作日志
  3426. </Button>
  3427. </FormItem>
  3428. <FormItem
  3429. className="half-item"
  3430. {...formItemLayout}
  3431. label="合同编号"
  3432. >
  3433. <span>{this.state.contractNo}</span>
  3434. </FormItem>
  3435. </div>
  3436. <div className="clearfix">
  3437. <FormItem
  3438. className="half-item"
  3439. {...formItemLayout}
  3440. label="项目状态"
  3441. >
  3442. <Select
  3443. placeholder="选择项目状态"
  3444. style={{ width: '200px' }}
  3445. value={this.state.projectStatus}
  3446. onChange={(e) => {
  3447. this.setState({ projectStatus: e })
  3448. }}
  3449. >
  3450. {projectStatus.map(function (item) {
  3451. return (
  3452. <Select.Option key={item.value}>
  3453. {item.key}
  3454. </Select.Option>
  3455. )
  3456. })}
  3457. </Select>
  3458. </FormItem>
  3459. <FormItem
  3460. className="half-item"
  3461. {...formItemLayout}
  3462. label="是否特批"
  3463. >
  3464. <span>{getApproval(this.state.approval)}</span>
  3465. </FormItem>
  3466. <FormItem
  3467. className="half-item"
  3468. {...formItemLayout}
  3469. label="结算状态"
  3470. >
  3471. <span>
  3472. {getLiquidationStatus(this.state.liquidationStatus)}
  3473. </span>
  3474. </FormItem>
  3475. <FormItem
  3476. className="half-item"
  3477. {...formItemLayout}
  3478. label="流程状态"
  3479. >
  3480. <span>
  3481. {getProcessStatus(this.state.processStatus)}
  3482. </span>
  3483. </FormItem>
  3484. <FormItem
  3485. className="half-item"
  3486. {...formItemLayout}
  3487. label="订单编号"
  3488. >
  3489. <span>{this.state.orderNo}</span>
  3490. </FormItem>
  3491. </div>
  3492. <div className="clearfix">
  3493. <FormItem
  3494. className="half-item"
  3495. {...formItemLayout}
  3496. label="满意度表格"
  3497. >
  3498. <Radio.Group
  3499. value={this.state.formRetrieve}
  3500. onChange={(e) => {
  3501. this.setState({ formRetrieve: e.target.value })
  3502. }}
  3503. >
  3504. <Radio value={0}>未收回</Radio>
  3505. <Radio value={1}>已收回</Radio>
  3506. <Radio value={2}>其他</Radio>
  3507. </Radio.Group>
  3508. </FormItem>
  3509. <FormItem
  3510. className="half-item"
  3511. {...formItemLayout}
  3512. label="退单"
  3513. >
  3514. <Radio.Group
  3515. value={this.state.taskRefund}
  3516. onChange={(e) => {
  3517. this.setState({ taskRefund: e.target.value })
  3518. }}
  3519. >
  3520. <Radio value={0}>已完成</Radio>
  3521. <Radio value={1}>未完成</Radio>
  3522. <Radio value={2}>其他</Radio>
  3523. </Radio.Group>
  3524. </FormItem>
  3525. </div>
  3526. <div className="clearfix">
  3527. {
  3528. <FormItem
  3529. className="half-item"
  3530. {...formItemLayout}
  3531. label="(满意度)备注"
  3532. >
  3533. <Input
  3534. type="textarea"
  3535. placeholder="请输入备注"
  3536. rows={2}
  3537. value={this.state.retrieveContent}
  3538. onChange={(e) => {
  3539. this.setState({
  3540. retrieveContent: e.target.value,
  3541. })
  3542. }}
  3543. />
  3544. </FormItem>
  3545. }
  3546. {
  3547. <FormItem
  3548. className="half-item"
  3549. {...formItemLayout}
  3550. label="(退单)备注"
  3551. >
  3552. <Input
  3553. type="textarea"
  3554. placeholder="请输入备注"
  3555. rows={2}
  3556. value={this.state.refundContent}
  3557. onChange={(e) => {
  3558. this.setState({ refundContent: e.target.value })
  3559. }}
  3560. />
  3561. </FormItem>
  3562. }
  3563. </div>
  3564. <div className="clearfix">
  3565. <h3 className="sub-title">订单负责人信息</h3>
  3566. <FormItem
  3567. className="half-item"
  3568. {...formItemLayout}
  3569. label="负责人"
  3570. >
  3571. <span>
  3572. {this.state.salesmanName +
  3573. '(' +
  3574. this.state.depName +
  3575. ')'}
  3576. </span>
  3577. </FormItem>
  3578. <FormItem
  3579. className="half-item"
  3580. {...formItemLayout}
  3581. label="负责人电话"
  3582. >
  3583. <span>{this.state.salesmanMobile}</span>
  3584. </FormItem>
  3585. <FormItem
  3586. className="half-item"
  3587. {...formItemLayout}
  3588. label="当前财务负责人"
  3589. >
  3590. <span>{this.state.nowFinance}</span>
  3591. </FormItem>
  3592. <FormItem
  3593. className="half-item"
  3594. {...formItemLayout}
  3595. label="当前财务负责人电话"
  3596. >
  3597. <span>{this.state.nowFinanceMobile}</span>
  3598. </FormItem>
  3599. <FormItem
  3600. className="half-item"
  3601. {...formItemLayout}
  3602. style={{ opacity: '.5' }}
  3603. label="原负责人"
  3604. >
  3605. <span>{this.state.oldSalesmanName}</span>
  3606. </FormItem>
  3607. <FormItem
  3608. className="half-item"
  3609. {...formItemLayout}
  3610. style={{ opacity: '.5' }}
  3611. label="原负责人电话"
  3612. >
  3613. <span>{this.state.oldSalesmanMobile}</span>
  3614. </FormItem>
  3615. <FormItem
  3616. className="half-item"
  3617. {...formItemLayout}
  3618. style={{ opacity: '.5' }}
  3619. label="实际财务操作人"
  3620. >
  3621. <span>{this.state.financeName}</span>
  3622. </FormItem>
  3623. <FormItem
  3624. className="half-item"
  3625. {...formItemLayout}
  3626. style={{ opacity: '.5' }}
  3627. label="实际财务操作人电话"
  3628. >
  3629. <span>{this.state.financeMobile}</span>
  3630. </FormItem>
  3631. <FormItem
  3632. className="half-item"
  3633. {...formItemLayout}
  3634. label="订单留言"
  3635. >
  3636. <span>{this.state.orderRemarks}</span>
  3637. </FormItem>
  3638. <FormItem
  3639. className="half-item"
  3640. {...formItemLayout}
  3641. label=""
  3642. >
  3643. <Button onClick={this.getOrderLog}>查看订单日志</Button>
  3644. </FormItem>
  3645. <OrderRiZi
  3646. dataSourcerizhi={this.state.dataSourceY}
  3647. closeOrderLog={this.closeOrderLog}
  3648. visible={this.state.avisible}
  3649. loading={this.state.loading}
  3650. />
  3651. </div>
  3652. {/*<div className="clearfix">*/}
  3653. {/* <h3 className="sub-title">外包信息</h3>*/}
  3654. {/* <FormItem*/}
  3655. {/* className="half-item"*/}
  3656. {/* {...formItemLayout}*/}
  3657. {/* label="外包公司"*/}
  3658. {/* >*/}
  3659. {/* <Input*/}
  3660. {/* value={this.state.outsourceName}*/}
  3661. {/* onChange={(e) => {*/}
  3662. {/* this.setState({*/}
  3663. {/* outsourceName: e.target.value,*/}
  3664. {/* })*/}
  3665. {/* }}*/}
  3666. {/* placeholder="请输入外包公司"*/}
  3667. {/* style={{ width: '200px' }}*/}
  3668. {/* />*/}
  3669. {/* </FormItem>*/}
  3670. {/* <FormItem*/}
  3671. {/* className="half-item"*/}
  3672. {/* {...formItemLayout}*/}
  3673. {/* label="外包成本(万元)"*/}
  3674. {/* >*/}
  3675. {/* <Input*/}
  3676. {/* value={this.state.outsourcePrice}*/}
  3677. {/* onChange={(e) => {*/}
  3678. {/* this.setState({*/}
  3679. {/* outsourcePrice: e.target.value,*/}
  3680. {/* })*/}
  3681. {/* }}*/}
  3682. {/* placeholder="请输入外包成本"*/}
  3683. {/* style={{ width: '200px' }}*/}
  3684. {/* />*/}
  3685. {/* </FormItem>*/}
  3686. {/*</div>*/}
  3687. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  3688. <div className="clearfix">
  3689. <h3 className="sub-title">联系信息</h3>
  3690. <FormItem
  3691. className="half-item"
  3692. {...formItemLayout}
  3693. label="客户名称"
  3694. >
  3695. <span>{this.state.userName}</span>
  3696. </FormItem>
  3697. <FormItem
  3698. className="half-item"
  3699. {...formItemLayout}
  3700. label="企业法人"
  3701. >
  3702. <Input
  3703. placeholder="请输入法人名称"
  3704. value={this.state.legalPerson}
  3705. style={{ width: '200px' }}
  3706. onChange={(e) => {
  3707. this.setState({ legalPerson: e.target.value })
  3708. }}
  3709. ref="commodityQuantity"
  3710. />
  3711. </FormItem>
  3712. <FormItem
  3713. className="half-item"
  3714. {...formItemLayout}
  3715. label="法人电话"
  3716. >
  3717. <Input
  3718. placeholder="请输入法人电话"
  3719. value={this.state.legalPersonTel}
  3720. style={{ width: '200px' }}
  3721. onChange={(e) => {
  3722. this.setState({ legalPersonTel: e.target.value })
  3723. }}
  3724. ref="commodityQuantity"
  3725. />
  3726. </FormItem>
  3727. <FormItem
  3728. className="half-item"
  3729. {...formItemLayout}
  3730. label="客户联系人"
  3731. >
  3732. <Input
  3733. placeholder="请输入联系人名称"
  3734. value={this.state.contacts}
  3735. style={{ width: '200px' }}
  3736. onChange={(e) => {
  3737. this.setState({ contacts: e.target.value })
  3738. }}
  3739. ref="commodityQuantity"
  3740. />
  3741. </FormItem>
  3742. <FormItem
  3743. className="half-item"
  3744. {...formItemLayout}
  3745. label="联系人电话"
  3746. >
  3747. <Input
  3748. placeholder="请输入联系人电话"
  3749. value={this.state.contactMobile}
  3750. style={{ width: '200px' }}
  3751. onChange={(e) => {
  3752. this.setState({ contactMobile: e.target.value })
  3753. }}
  3754. ref="commodityQuantity"
  3755. />
  3756. </FormItem>
  3757. <FormItem
  3758. className="half-item"
  3759. {...formItemLayout}
  3760. label="企业地址"
  3761. >
  3762. <Cascader
  3763. options={areaSelect()}
  3764. value={this.state.ProvinceCity}
  3765. placeholder="选择城市"
  3766. style={{ width: '200px' }}
  3767. onChange={(e) => {
  3768. this.setState({ ProvinceCity: e })
  3769. }}
  3770. />
  3771. </FormItem>
  3772. <FormItem
  3773. className="half-item"
  3774. {...formItemLayout}
  3775. label=""
  3776. ></FormItem>
  3777. <FormItem
  3778. className="half-item"
  3779. {...formItemLayout}
  3780. label=""
  3781. >
  3782. <Input
  3783. placeholder="请输入详细地址"
  3784. value={this.state.postalAddress}
  3785. style={{ width: '200px', marginLeft: '12em' }}
  3786. onChange={(e) => {
  3787. this.setState({ postalAddress: e.target.value })
  3788. }}
  3789. ref="commodityQuantity"
  3790. />
  3791. </FormItem>
  3792. </div>
  3793. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  3794. <div className="clearfix">
  3795. <h3 className="sub-title">项目信息</h3>
  3796. <FormItem
  3797. className="half-item"
  3798. {...formItemLayout}
  3799. label="项目编号"
  3800. >
  3801. <span>
  3802. {this.state.splitStatus == 2
  3803. ? this.state.splitSuper + '-' + this.state.splitId
  3804. : this.state.id}
  3805. </span>
  3806. </FormItem>
  3807. <FormItem
  3808. className="half-item"
  3809. {...formItemLayout}
  3810. label="项目名称"
  3811. >
  3812. <span>{this.state.taskName}</span>
  3813. </FormItem>
  3814. <FormItem
  3815. className="half-item"
  3816. {...formItemLayout}
  3817. label="项目状态"
  3818. >
  3819. <Select
  3820. placeholder="选择项目状态"
  3821. style={{ width: '200px' }}
  3822. value={this.state.taskStatus}
  3823. onChange={(e) => {
  3824. this.setState({ taskStatus: e })
  3825. }}
  3826. >
  3827. {taskStatus.map(function (item) {
  3828. return (
  3829. <Select.Option key={item.value}>
  3830. {item.key}
  3831. </Select.Option>
  3832. )
  3833. })}
  3834. </Select>
  3835. </FormItem>
  3836. <FormItem
  3837. className="half-item"
  3838. {...formItemLayout}
  3839. label="项目类别"
  3840. >
  3841. <span>{this.state.cname}</span>
  3842. </FormItem>
  3843. <FormItem
  3844. className="half-item"
  3845. {...formItemLayout}
  3846. label="证书编号"
  3847. >
  3848. <Input
  3849. placeholder="请输入证书编号"
  3850. value={this.state.certificateNumber}
  3851. style={{ width: '200px' }}
  3852. onChange={(e) => {
  3853. this.setState({
  3854. certificateNumber: e.target.value,
  3855. })
  3856. }}
  3857. ref="commodityQuantity"
  3858. />
  3859. </FormItem>
  3860. </div>
  3861. <div className="clearfix">
  3862. <h3 className="sub-title">申报系统账户信息</h3>
  3863. {/*<span style={{color:'red'}}>注:仅技术部可见</span>*/}
  3864. <FormItem
  3865. className="half-item"
  3866. {...formItemLayout}
  3867. label="用户名"
  3868. >
  3869. <Input
  3870. placeholder="请输入用户名"
  3871. value={this.state.declareUser}
  3872. style={{ width: '200px' }}
  3873. onChange={(e) => {
  3874. this.setState({ declareUser: e.target.value })
  3875. }}
  3876. />
  3877. </FormItem>
  3878. <FormItem
  3879. className="half-item"
  3880. {...formItemLayout}
  3881. label="密码"
  3882. >
  3883. <Input
  3884. placeholder="请输入密码"
  3885. value={this.state.declarePwd}
  3886. style={{ width: '200px' }}
  3887. onChange={(e) => {
  3888. this.setState({ declarePwd: e.target.value })
  3889. }}
  3890. />
  3891. </FormItem>
  3892. </div>
  3893. <div className="clearfix">
  3894. <h3 className="sub-title">项目申报进度</h3>
  3895. <FormItem
  3896. className="half-item"
  3897. {...formItemLayout}
  3898. label="申报批次"
  3899. >
  3900. <Select
  3901. style={{ width: 200 }}
  3902. placeholder="请选择批次"
  3903. value={
  3904. this.state.declarationBatch
  3905. ? this.state.declarationBatch
  3906. : undefined
  3907. }
  3908. onChange={(e) => {
  3909. this.setState({
  3910. declarationBatch: e,
  3911. })
  3912. }}
  3913. >
  3914. <Option value={1}>第一批</Option>
  3915. <Option value={2}>第二批</Option>
  3916. <Option value={3}>第三批</Option>
  3917. <Option value={4}>第四批</Option>
  3918. </Select>
  3919. </FormItem>
  3920. <FormItem
  3921. className="half-item"
  3922. {...formItemLayout}
  3923. label="启动时间"
  3924. >
  3925. <DatePicker
  3926. style={{
  3927. marginTop: '2px',
  3928. width: '200px',
  3929. height: '32px',
  3930. }}
  3931. showTime
  3932. format="YYYY-MM-DD"
  3933. onOk={() => {}}
  3934. value={
  3935. this.state.startDate
  3936. ? moment(this.state.startDate)
  3937. : null
  3938. }
  3939. onChange={(data, dataString) => {
  3940. this.setState({ startDate: dataString })
  3941. }}
  3942. />
  3943. </FormItem>
  3944. <FormItem
  3945. className="half-item"
  3946. {...formItemLayout}
  3947. label="完成时间"
  3948. >
  3949. <DatePicker
  3950. style={{
  3951. marginTop: '2px',
  3952. width: '200px',
  3953. height: '32px',
  3954. }}
  3955. showTime
  3956. format="YYYY-MM-DD"
  3957. onOk={() => {}}
  3958. value={
  3959. this.state.endDate
  3960. ? moment(this.state.endDate)
  3961. : null
  3962. }
  3963. onChange={(data, dataString) => {
  3964. this.setState({ endDate: dataString })
  3965. }}
  3966. />
  3967. </FormItem>
  3968. <FormItem
  3969. className="half-item"
  3970. {...formItemLayout}
  3971. label="受理时间"
  3972. >
  3973. <DatePicker
  3974. style={{
  3975. marginTop: '2px',
  3976. width: '200px',
  3977. height: '32px',
  3978. }}
  3979. showTime
  3980. format="YYYY-MM-DD"
  3981. onOk={() => {}}
  3982. value={
  3983. this.state.acceptDate
  3984. ? moment(this.state.acceptDate)
  3985. : null
  3986. }
  3987. onChange={(data, dataString) => {
  3988. this.setState({ acceptDate: dataString })
  3989. }}
  3990. />
  3991. </FormItem>
  3992. <FormItem
  3993. className="half-item"
  3994. {...formItemLayout}
  3995. label="评审时间"
  3996. >
  3997. <DatePicker
  3998. style={{
  3999. marginTop: '2px',
  4000. width: '200px',
  4001. height: '32px',
  4002. }}
  4003. showTime
  4004. format="YYYY-MM-DD"
  4005. onOk={() => {}}
  4006. value={
  4007. this.state.reviewDate
  4008. ? moment(this.state.reviewDate)
  4009. : null
  4010. }
  4011. onChange={(data, dataString) => {
  4012. this.setState({ reviewDate: dataString })
  4013. }}
  4014. />
  4015. </FormItem>
  4016. <FormItem
  4017. className="half-item"
  4018. {...formItemLayout}
  4019. label="公示时间"
  4020. >
  4021. <DatePicker
  4022. style={{
  4023. marginTop: '2px',
  4024. width: '200px',
  4025. height: '32px',
  4026. }}
  4027. showTime
  4028. format="YYYY-MM-DD"
  4029. onOk={() => {}}
  4030. value={
  4031. this.state.publicityDate
  4032. ? moment(this.state.publicityDate)
  4033. : null
  4034. }
  4035. onChange={(data, dataString) => {
  4036. this.setState({ publicityDate: dataString })
  4037. }}
  4038. />
  4039. </FormItem>
  4040. <FormItem
  4041. className="half-item"
  4042. {...formItemLayout}
  4043. label="发证时间"
  4044. >
  4045. <DatePicker
  4046. style={{
  4047. marginTop: '2px',
  4048. width: '200px',
  4049. height: '32px',
  4050. }}
  4051. showTime
  4052. format="YYYY-MM-DD"
  4053. onOk={() => {}}
  4054. value={
  4055. this.state.licenceDate
  4056. ? moment(this.state.licenceDate)
  4057. : null
  4058. }
  4059. onChange={(data, dataString) => {
  4060. this.setState({ licenceDate: dataString })
  4061. }}
  4062. />
  4063. </FormItem>
  4064. <FormItem
  4065. className="half-item"
  4066. {...formItemLayout}
  4067. label="立项金额(万元)"
  4068. >
  4069. <Input
  4070. placeholder="请输入立项金额"
  4071. value={this.state.setUpAmount}
  4072. style={{ width: '200px' }}
  4073. onChange={(e) => {
  4074. this.setState({ setUpAmount: e.target.value })
  4075. }}
  4076. ref="commodityQuantity"
  4077. />
  4078. </FormItem>
  4079. <FormItem
  4080. className="half-item"
  4081. {...formItemLayout}
  4082. label="是否到款"
  4083. >
  4084. <Radio.Group
  4085. value={this.state.arrivalMoney}
  4086. onChange={(e) => {
  4087. this.setState({ arrivalMoney: e.target.value })
  4088. }}
  4089. >
  4090. <Radio value={0}>未到企业</Radio>
  4091. <Radio value={1}>已到企业</Radio>
  4092. </Radio.Group>
  4093. </FormItem>
  4094. </div>
  4095. <div className="clearfix">
  4096. <FormItem
  4097. labelCol={{ span: 3 }}
  4098. wrapperCol={{ span: 16 }}
  4099. label="附件"
  4100. >
  4101. <Picture
  4102. fileList={(e) => {
  4103. this.setState({ attachmentUrl: e })
  4104. }}
  4105. pictureUrl={this.state.attachmentUrl}
  4106. visible={this.props.visible}
  4107. data={{
  4108. sign: 'order_task_file',
  4109. url: '/api/admin/orderProject/uploadOrderTaskFile',
  4110. }}
  4111. />
  4112. </FormItem>
  4113. </div>
  4114. <div className="clearfix">
  4115. <FormItem
  4116. labelCol={{ span: 3 }}
  4117. wrapperCol={{ span: 16 }}
  4118. label="备注"
  4119. >
  4120. <Input
  4121. type="textarea"
  4122. placeholder="请输入备注"
  4123. rows={4}
  4124. value={this.state.taskComment}
  4125. onChange={(e) => {
  4126. this.setState({ taskComment: e.target.value })
  4127. }}
  4128. />
  4129. </FormItem>
  4130. </div>
  4131. <div>
  4132. <h3 className="sub-title">项目业务</h3>
  4133. {this.state.processStatus == 0 ? (
  4134. <Button
  4135. type="primary"
  4136. onClick={this.addDetailed}
  4137. style={{
  4138. float: 'right',
  4139. marginRight: '50px',
  4140. marginBottom: '15px',
  4141. }}
  4142. >
  4143. 添加项目明细
  4144. </Button>
  4145. ) : (
  4146. ''
  4147. )}
  4148. </div>
  4149. <div className="patent-table">
  4150. <Spin spinning={this.state.loading}>
  4151. <Table
  4152. columns={this.state.columnsX}
  4153. dataSource={this.state.dataSourceX}
  4154. pagination={this.state.paginations}
  4155. onRowClick={this.tableRowClickX}
  4156. bordered
  4157. size="small"
  4158. />
  4159. </Spin>
  4160. </div>
  4161. <div className="clearfix">
  4162. <Button
  4163. className="cancel"
  4164. type="primary"
  4165. // onClick={this.tijiaoOk}
  4166. onClick={() => {
  4167. let num = this.state.projectStatus
  4168. if (
  4169. num != 0 &&
  4170. num != 10 &&
  4171. num != 11 &&
  4172. num != 12 &&
  4173. num != 2 &&
  4174. num != 5 &&
  4175. num != 6
  4176. ) {
  4177. this.showDeleteConfirm(num, this.tijiaoOk)
  4178. } else {
  4179. this.tijiaoOk()
  4180. }
  4181. }}
  4182. style={{ marginLeft: '200px', marginTop: '10px' }}
  4183. htmlType="submit"
  4184. >
  4185. 保存
  4186. </Button>
  4187. <Button
  4188. className="cancel"
  4189. type="ghost"
  4190. onClick={this.visitCancel}
  4191. style={{ marginLeft: '50px', marginTop: '10px' }}
  4192. >
  4193. 取消
  4194. </Button>
  4195. </div>
  4196. </div>
  4197. </Spin>
  4198. </Form> : <div/>}
  4199. </TabPane>
  4200. <TabPane tab="外包/供应商信息" key="2">
  4201. {this.state.refundStatus != 0 && this.state.refundStatus != 1 ? (
  4202. <div style={{ marginTop: 10 }}>
  4203. <div className="clearfix">
  4204. <FormItem
  4205. className="half-item"
  4206. {...formItemLayout}
  4207. label={
  4208. <span>
  4209. <strong style={{ color: '#f00' }}>*</strong>
  4210. 类型
  4211. </span>
  4212. }
  4213. >
  4214. <Radio.Group
  4215. value={this.state.startType}
  4216. onChange={(e) => {
  4217. this.setState({ startType: e.target.value })
  4218. }}
  4219. >
  4220. <Radio value={0}>外包(不走总部)</Radio>
  4221. <Radio value={1}>供应商信息</Radio>
  4222. </Radio.Group>
  4223. </FormItem>
  4224. </div>
  4225. {/* 专利类型 */}
  4226. <div
  4227. className="clearfix"
  4228. style={{
  4229. display: this.state.projectType === 1 ? 'block' : 'none',
  4230. }}
  4231. >
  4232. <FormItem
  4233. className="half-item"
  4234. {...formItemLayout}
  4235. label={
  4236. <span>
  4237. <strong style={{ color: '#f00' }}>*</strong>
  4238. 专利类型
  4239. </span>
  4240. }
  4241. >
  4242. <Radio.Group
  4243. value={this.state.patentType}
  4244. onChange={(e) => {
  4245. let _this = this;
  4246. if(this.state.thirdInfoList.length >0){
  4247. confirm({
  4248. title: '确定要切换吗?',
  4249. content: '切换将删除所有第三信息和付款节点',
  4250. onOk() {
  4251. return new Promise((resolve, reject) => {
  4252. _this.setState({ patentType: e.target.value },()=>{
  4253. _this.projectTypeTabContent(_this.state.projectType);
  4254. })
  4255. _this.confirmDeletNew(-1,resolve,reject)
  4256. if(_this.state.payNodeList.length > 0){
  4257. _this.payNodeConfirmDeletNew(-1,resolve,reject);
  4258. }
  4259. }).catch(() => console.log('Oops errors!'));
  4260. },
  4261. onCancel() {},
  4262. });
  4263. }else{
  4264. this.setState({ patentType: e.target.value },()=>{
  4265. this.projectTypeTabContent(this.state.projectType);
  4266. })
  4267. }
  4268. }}
  4269. >
  4270. <Radio value={0}>专利申请/变更/转让</Radio>
  4271. <Radio value={1}>专利买卖</Radio>
  4272. </Radio.Group>
  4273. </FormItem>
  4274. </div>
  4275. <div
  4276. className="clearfix"
  4277. style={{
  4278. display: this.state.projectType === 1? 'block' : 'none',
  4279. }}
  4280. >
  4281. <FormItem
  4282. className="half-item"
  4283. {...formItemLayout}
  4284. label={
  4285. <span>
  4286. <strong style={{ color: '#f00' }}>*</strong>
  4287. 专利名称
  4288. </span>
  4289. }
  4290. >
  4291. <Radio.Group
  4292. value={this.state.patentNameType}
  4293. onChange={(e) => {
  4294. let _this = this;
  4295. if(this.state.thirdInfoList.length >0){
  4296. confirm({
  4297. title: '确定要切换吗?',
  4298. content: '切换将删除所有第三信息和付款节点',
  4299. onOk() {
  4300. return new Promise((resolve, reject) => {
  4301. _this.setState({ patentNameType: e.target.value },()=>{
  4302. _this.projectTypeTabContent(_this.state.projectType);
  4303. })
  4304. _this.confirmDeletNew(-1,resolve,reject)
  4305. if(_this.state.payNodeList.length > 0){
  4306. _this.payNodeConfirmDeletNew(-1,resolve,reject);
  4307. }
  4308. }).catch(() => console.log('Oops errors!'));
  4309. },
  4310. onCancel() {},
  4311. });
  4312. }else{
  4313. this.setState({ patentNameType: e.target.value },()=>{
  4314. this.projectTypeTabContent(this.state.projectType);
  4315. })
  4316. }
  4317. }}
  4318. >
  4319. <Radio value={0}>实用新型专利</Radio>
  4320. <Radio value={1}>发明专利</Radio>
  4321. <Radio value={2}>外观专利</Radio>
  4322. {/*<Radio value={3}>*/}
  4323. {/* 其他*/}
  4324. {/* <Input*/}
  4325. {/* disabled={this.state.patentNameType !== 3}*/}
  4326. {/* value={this.state.patentName}*/}
  4327. {/* style={{ marginLeft: '15px' }}*/}
  4328. {/* onChange={(e) => {*/}
  4329. {/* this.setState({*/}
  4330. {/* patentName: e.target.value,*/}
  4331. {/* })*/}
  4332. {/* }}*/}
  4333. {/* placeholder="请填写专利名称"*/}
  4334. {/* />*/}
  4335. {/*</Radio>*/}
  4336. </Radio.Group>
  4337. </FormItem>
  4338. </div>
  4339. {/* 第三方信息专利 */}
  4340. <div
  4341. style={{
  4342. // display: this.state.type == 1 ? "block" : "none",
  4343. display: this.state.type == 1 ? 'block' : 'block',
  4344. }}
  4345. >
  4346. <span
  4347. style={{
  4348. marginLeft: '50px',
  4349. fontSize: '18px',
  4350. }}
  4351. >
  4352. 第三方信息
  4353. </span>
  4354. <span
  4355. style={{
  4356. display: 'inline-block',
  4357. marginLeft: 10,
  4358. color: 'red',
  4359. }}
  4360. >
  4361. 金额总计(万元): {this.state.allTotalAmount}
  4362. </span>
  4363. <Button
  4364. type="primary"
  4365. onClick={(e) => {
  4366. if(this.state.projectType === 1 && this.state.patentType === -1){
  4367. message.info('请先选择专利类型');
  4368. }else if(this.state.projectType === 1 && this.state.patentNameType === -1){
  4369. message.info('请先选择专利名称');
  4370. }
  4371. else{
  4372. this.addThirdList()
  4373. }
  4374. }}
  4375. style={{
  4376. float: 'right',
  4377. marginRight: '50px',
  4378. marginBottom: '15px',
  4379. }}
  4380. >
  4381. +新增供应商名称
  4382. </Button>
  4383. </div>
  4384. <div
  4385. className="clearfix"
  4386. style={{
  4387. // display: this.state.type == 1 ? "block" : "none",
  4388. display: this.state.type == 1 ? 'block' : 'block',
  4389. }}
  4390. >
  4391. <Spin spinning={this.state.loading}>
  4392. <Form layout="horizontal">
  4393. <Table
  4394. pagination={false}
  4395. columns={this.state.ContactsListsNew}
  4396. dataSource={this.state.thirdInfoList}
  4397. onRowClick={this.tableRowClickOne}
  4398. scroll={{ x: 'max-content', y: 0 }}
  4399. bordered
  4400. size="small"
  4401. />
  4402. <Col
  4403. span={24}
  4404. offset={9}
  4405. style={{ marginTop: '15px' }}
  4406. />
  4407. </Form>
  4408. </Spin>
  4409. </div>
  4410. {/*如果是软著类或者专利类的专利申请,隐藏付款节点*/}
  4411. <div
  4412. style={{
  4413. display: (this.state.projectType === 1 && this.state.patentType === 0) || this.state.projectType === 2? 'none' : 'block', //0正常 1专利 2软著 3审计
  4414. }}
  4415. >
  4416. <span
  4417. style={{
  4418. marginLeft: '50px',
  4419. fontSize: '18px',
  4420. }}
  4421. >
  4422. 付款节点
  4423. </span>
  4424. <span
  4425. style={{
  4426. display: 'inline-block',
  4427. marginLeft: 10,
  4428. color: 'red',
  4429. }}
  4430. ></span>
  4431. <Button
  4432. type="primary"
  4433. onClick={(e) => {
  4434. this.addPayNode()
  4435. }}
  4436. style={{
  4437. float: 'right',
  4438. marginRight: '50px',
  4439. marginBottom: '15px',
  4440. }}
  4441. >
  4442. +新增付款节点
  4443. </Button>
  4444. </div>
  4445. {/*如果是软著类或者专利类的专利申请,隐藏付款节点*/}
  4446. <div
  4447. className="clearfix"
  4448. style={{
  4449. display: (this.state.projectType === 1 && this.state.patentType === 0) || this.state.projectType === 2? 'none' : 'block', //0正常 1专利 2软著 3审计
  4450. }}
  4451. >
  4452. <Spin spinning={this.state.loading}>
  4453. <Form layout="horizontal">
  4454. <Table
  4455. pagination={false}
  4456. columns={this.state.PayNodeTableColunms}
  4457. dataSource={this.state.payNodeList}
  4458. onRowClick={this.payNodeTableRowClickOne}
  4459. scroll={{ x: 'max-content', y: 0 }}
  4460. bordered
  4461. size="small"
  4462. />
  4463. <Col
  4464. span={24}
  4465. offset={9}
  4466. style={{ marginTop: '15px' }}
  4467. />
  4468. </Form>
  4469. </Spin>
  4470. </div>
  4471. <div className="clearfix">
  4472. <FormItem
  4473. className="half-item"
  4474. {...formItemLayout}
  4475. label={
  4476. <span>
  4477. <strong style={{ color: '#f00' }}>*</strong>备注
  4478. </span>
  4479. }
  4480. >
  4481. <TextArea
  4482. rows={4}
  4483. value={this.state.outsourceRemarks}
  4484. onChange={(e) => {
  4485. this.setState({
  4486. outsourceRemarks: e.target.value,
  4487. })
  4488. }}
  4489. placeholder="请输入备注"
  4490. />
  4491. </FormItem>
  4492. </div>
  4493. {/*<div className="clearfix">
  4494. <FormItem className="half-item"
  4495. {...formItemLayout}
  4496. label="上传协议文件" style={{height:"auto"}}>
  4497. <Upload header={{authorization: 'authorization-text'}} action={globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"}
  4498. data={(e)=>{
  4499. return {
  4500. 'sign': e.name.substring(0,e.name.lastIndexOf("."))
  4501. }
  4502. }}
  4503. fileList={this.state.fileUrl}
  4504. onChange={(e)=>{
  4505. this.setState({
  4506. attachmentUrl:e.fileList,
  4507. fileUrl:e.fileList
  4508. })
  4509. }}>
  4510. {fileUrl.length>1?null:<Button>
  4511. <Icon type="upload" /> 点击上传
  4512. </Button>}
  4513. </Upload>
  4514. <span className="tip" style={{display:"inline-block"}}>支持文件格式: doc,excel,ppt</span>
  4515. </FormItem>
  4516. </div>*/}
  4517. <p
  4518. className="tip"
  4519. style={{
  4520. paddingBottom: '12px',
  4521. width: '240px',
  4522. marginLeft: '145px',
  4523. color: 'red',
  4524. }}
  4525. >
  4526. 首次派单项目,需上传协议,第2次起,同项目,只需写外包公司
  4527. </p>
  4528. <div className="clearfix">
  4529. <FormItem
  4530. labelCol={{ span: 4 }}
  4531. wrapperCol={{ span: 18 }}
  4532. label={
  4533. <span>
  4534. 合同/协议扫描件
  4535. </span>
  4536. }
  4537. >
  4538. <PicturesWall
  4539. fileList={this.getOrgCodeUrlWai}
  4540. pictureUrl={this.state.pictureUrl}
  4541. />
  4542. <p style={{ color: 'red' }}>图片建议:要清晰。</p>
  4543. </FormItem>
  4544. </div>
  4545. {/*只有审核拒绝和第一次发起外包的时候才要填写发起原因*/}
  4546. {typeof this.state.refundStatus === 'undefined' || this.state.refundStatus === 2 ? <div className="clearfix">
  4547. <FormItem
  4548. className="half-item"
  4549. {...formItemLayout}
  4550. label={
  4551. <span>
  4552. <strong style={{ color: '#f00' }}>*</strong>发起原因
  4553. </span>
  4554. }
  4555. >
  4556. <TextArea
  4557. rows={4}
  4558. value={this.state.reason}
  4559. onChange={(e) => {
  4560. this.setState({
  4561. reason: e.target.value,
  4562. })
  4563. }}
  4564. placeholder="请输入发起原因"
  4565. />
  4566. </FormItem>
  4567. </div> : <div/>}
  4568. <div className="clearfix">
  4569. <div
  4570. style={{
  4571. display: 'inline-black',
  4572. textAlign: 'center',
  4573. }}
  4574. >
  4575. <Button
  4576. type="primary"
  4577. loading={this.state.loading}
  4578. onClick={()=>{
  4579. this.sureOut(this.state.startType);
  4580. }}
  4581. >
  4582. {
  4583. this.state.startType === 0 ? "确认发起外包,不通过总部" : "提交供应商信息"
  4584. }
  4585. </Button>
  4586. <p className="tip" style={{ color: 'red' }}>
  4587. {
  4588. this.state.startType === 0 ? "提示:高于总部价格,费用个人承担" : "确定提交供应商信息,提交后,不可修改"
  4589. }
  4590. </p>
  4591. </div>
  4592. </div>
  4593. </div>
  4594. ) : (
  4595. <div>
  4596. {
  4597. this.state.visible && this.state.activeKey === '2' ?
  4598. <CheckProject
  4599. {...this.props}
  4600. tid={this.state.tid}
  4601. oldInfor={this.state.oldInfor}
  4602. projectType={this.state.projectType} //0正常 1专利 2软著 3审计
  4603. patentNameType={this.state.patentNameType}
  4604. patentName={this.state.patentName}
  4605. patentType={this.state.patentType}
  4606. status={this.state.refundStatus}
  4607. isPreviewPay={true}
  4608. thirdInfoList={this.state.thirdInfoList}
  4609. dataSource={this.state.payNodeList}
  4610. outsourceRemarks={this.state.outsourceRemarks}
  4611. fileList={this.state.pictureUrl}
  4612. startType={this.state.startType}
  4613. projectStatus={this.state.projectStatus}
  4614. onRefresh={()=>{
  4615. this.waiDetail();
  4616. this.thirdTable(this.state.tid);
  4617. this.getSelectOutsourceLog(this.state.tid);
  4618. this.payNodeTable(this.state.tid)
  4619. this.loadData(this.state.page)
  4620. }}
  4621. /> : <div/>
  4622. }
  4623. </div>
  4624. )}
  4625. {(this.state.refundStatus == 1 ||
  4626. this.state.refundStatus == 0 ||
  4627. this.state.refundStatus == 2) &&
  4628. this.state.startType !== 1
  4629. ? (
  4630. <div className="clearfix"
  4631. style={{
  4632. display: this.state.refundStatus == 0 ? 'none' : 'block',
  4633. }}
  4634. >
  4635. <hr className="division" />
  4636. {parseInt(this.state.startType) !== 1 ? <div style={{
  4637. color:'#F00',
  4638. fontWeight: 'bolder',
  4639. paddingBottom: '20px',
  4640. }}>
  4641. 审核结果: <span style={{paddingLeft:'20px'}}>{getRefundStatus(this.state.refundStatus)}</span>
  4642. </div> : <div/>}
  4643. <div className="outsourceLogList">
  4644. {
  4645. this.state.outsourceLogs && this.state.outsourceLogs.map((value,index)=>(
  4646. <div key={index} className="outsourceLogItem outsource">
  4647. <div style={{
  4648. display:'flex',
  4649. flexFlow:'row nowrap',
  4650. paddingBottom: '3px',
  4651. paddingTop: '3px',
  4652. }}>
  4653. <div>
  4654. {value.aname}
  4655. </div>
  4656. <div style={{paddingLeft:'5px'}}>
  4657. {
  4658. value.status === 0 ?
  4659. <Tag color="#2db7f5">发起外包审核</Tag> :
  4660. value.status === 1 ? <Tag color="#87d068">通过</Tag> :
  4661. <Tag color="#f50">驳回</Tag>
  4662. }
  4663. </div>
  4664. <div style={{
  4665. wordBreak: 'break-all',
  4666. maxWidth:'67%',
  4667. }}>
  4668. {value.remarks}
  4669. </div>
  4670. <div style={{paddingLeft: '10px'}}>
  4671. {value.createTimes}
  4672. </div>
  4673. </div>
  4674. </div>
  4675. ))
  4676. }
  4677. </div>
  4678. {/* <div*/}
  4679. {/* className="clearfix"*/}
  4680. {/* style={{*/}
  4681. {/* display: this.state.refundStatus == 0 ? 'none' : 'block',*/}
  4682. {/* }}*/}
  4683. {/* >*/}
  4684. {/* <FormItem*/}
  4685. {/* className="half-item"*/}
  4686. {/* {...formItemLayout}*/}
  4687. {/* label="审核意见"*/}
  4688. {/* >*/}
  4689. {/* <span>{this.state.remarks}</span>*/}
  4690. {/* </FormItem>*/}
  4691. {/* </div>*/}
  4692. {/* {parseInt(this.state.startType) !== 1 ?<div className="clearfix">*/}
  4693. {/* <FormItem*/}
  4694. {/* className="half-item"*/}
  4695. {/* {...formItemLayout}*/}
  4696. {/* label="审核结果"*/}
  4697. {/* >*/}
  4698. {/* <span>{getRefundStatus(this.state.refundStatus)}</span>*/}
  4699. {/* </FormItem>*/}
  4700. {/* </div> : <div/>}*/}
  4701. {/* <div*/}
  4702. {/* className="clearfix"*/}
  4703. {/* style={{*/}
  4704. {/* display: this.state.refundStatus == 0 ? 'none' : 'block',*/}
  4705. {/* }}*/}
  4706. {/* >*/}
  4707. {/* <FormItem*/}
  4708. {/* className="half-item"*/}
  4709. {/* {...formItemLayout}*/}
  4710. {/* label="审核时间"*/}
  4711. {/* >*/}
  4712. {/* <span>{this.state.auditTimes}</span>*/}
  4713. {/* </FormItem>*/}
  4714. {/* </div>*/}
  4715. </div>
  4716. ) : (
  4717. ''
  4718. )}
  4719. </TabPane>
  4720. {!this.props.isZxs || (this.state.isHuiyuan && this.props.isZxs) ? (
  4721. <TabPane tab="订单详情" key="3">
  4722. <Spin spinning={this.state.loading}>
  4723. {this.state.activeKey === "3" ? <OrderDetail
  4724. orderData={this.state.orderData}
  4725. getOrderLog={this.getOrderLog}
  4726. dataSourceX={this.state.dataSourceX}
  4727. contactList={this.state.jiedian}
  4728. orderNo={this.state.orderNo}
  4729. totalCui={this.state.totalCui}
  4730. contactListNew={this.state.jiedianNew}
  4731. pictureUrl={this.state.contractPictureUrl}
  4732. /> : <div/>}
  4733. </Spin>
  4734. </TabPane>
  4735. ) : (
  4736. ''
  4737. )}
  4738. </Tabs>
  4739. </Modal> : <div/>}
  4740. <Modal
  4741. maskClosable={false}
  4742. visible={this.state.lookVisible}
  4743. onOk={this.noCancel}
  4744. onCancel={this.noCancel}
  4745. width="500px"
  4746. title={'添加工时'}
  4747. footer=""
  4748. className="admin-desc-content"
  4749. >
  4750. <Form layout="horizontal" id="demand-form">
  4751. <Spin spinning={this.state.loading}>
  4752. <div className="clearfix">
  4753. <FormItem {...formItemLayout} label="工作日期">
  4754. <DatePicker
  4755. style={{ marginTop: '2px', width: '200px', height: '32px' }}
  4756. showTime
  4757. format="YYYY-MM-DD"
  4758. onOk={() => {}}
  4759. value={
  4760. this.state.taskDate ? moment(this.state.taskDate) : null
  4761. }
  4762. onChange={(data, dataString) => {
  4763. this.setState({ taskDate: dataString })
  4764. }}
  4765. />
  4766. </FormItem>
  4767. </div>
  4768. <div className="clearfix">
  4769. <FormItem {...formItemLayout} label="工作时长">
  4770. <Input
  4771. placeholder="请输入工作时长"
  4772. value={this.state.hours}
  4773. style={{ width: '200px' }}
  4774. onChange={(e) => {
  4775. this.setState({ hours: e.target.value })
  4776. }}
  4777. ref="commodityQuantity"
  4778. />
  4779. </FormItem>
  4780. </div>
  4781. <div className="clearfix">
  4782. <FormItem {...formItemLayout} label="工作内容">
  4783. <Input
  4784. type="textarea"
  4785. placeholder="请输入备注"
  4786. rows={4}
  4787. value={this.state.remarks}
  4788. onChange={(e) => {
  4789. this.setState({ remarks: e.target.value })
  4790. }}
  4791. />
  4792. </FormItem>
  4793. </div>
  4794. <div className="clearfix">
  4795. <Button
  4796. className="cancel"
  4797. type="primary"
  4798. onClick={this.tianjiaOk}
  4799. style={{ marginLeft: '100px' }}
  4800. htmlType="submit"
  4801. >
  4802. 确定
  4803. </Button>
  4804. <Button
  4805. className="cancel"
  4806. type="ghost"
  4807. onClick={this.noCancel}
  4808. style={{ marginLeft: '50px' }}
  4809. >
  4810. 取消
  4811. </Button>
  4812. </div>
  4813. </Spin>
  4814. </Form>
  4815. </Modal>
  4816. {this.state.addnextVisible ? <Modal
  4817. maskClosable={false}
  4818. visible={this.state.addnextVisible}
  4819. onOk={this.nextCancel}
  4820. onCancel={this.nextCancel}
  4821. width="800px"
  4822. title="项目详情"
  4823. footer=""
  4824. className="admin-desc-content"
  4825. >
  4826. <Form layout="horizontal" onSubmit={this.nextSubmit} id="demand-form">
  4827. <Spin spinning={this.state.loading}>
  4828. <div className="clearfix">
  4829. <FormItem
  4830. className="half-item"
  4831. {...formItemLayout}
  4832. label="项目名称"
  4833. >
  4834. <span>{this.state.commodityName}</span>
  4835. </FormItem>
  4836. <FormItem
  4837. className="half-item"
  4838. {...formItemLayout}
  4839. label="项目数量"
  4840. >
  4841. <span>{this.state.commodityQuantity}</span>
  4842. </FormItem>
  4843. <FormItem
  4844. className="half-item"
  4845. {...formItemLayout}
  4846. label="官费"
  4847. style={{ display: this.state.displayFees }}
  4848. >
  4849. <span>
  4850. {this.state.officialCost == 0 ? '无官费' : '有官费'}
  4851. </span>
  4852. </FormItem>
  4853. <FormItem
  4854. className="half-item"
  4855. {...formItemLayout}
  4856. label="费减"
  4857. style={{ display: this.state.displayFees }}
  4858. >
  4859. <span>
  4860. {this.state.costReduction == 0 ? '无费减' : '有费减'}
  4861. </span>
  4862. </FormItem>
  4863. <FormItem
  4864. className="half-item"
  4865. {...formItemLayout}
  4866. label="金额(万元)"
  4867. >
  4868. <span>{this.state.commodityPrice ? '***' : 0}</span>
  4869. </FormItem>
  4870. <FormItem
  4871. className="half-item"
  4872. {...formItemLayout}
  4873. label="主要项目"
  4874. >
  4875. <span>{getboutique(this.state.main)}</span>
  4876. </FormItem>
  4877. <div className="clearfix">
  4878. <FormItem
  4879. labelCol={{ span: 3 }}
  4880. wrapperCol={{ span: 18 }}
  4881. label="服务说明"
  4882. >
  4883. <span>{this.state.taskComment}</span>
  4884. </FormItem>
  4885. </div>
  4886. </div>
  4887. </Spin>
  4888. </Form>
  4889. </Modal> : <div/>}
  4890. <Modal
  4891. maskClosable={false}
  4892. visible={this.state.speVisible}
  4893. onOk={this.visitOk}
  4894. onCancel={this.visitCancel}
  4895. width="900px"
  4896. title=""
  4897. footer=""
  4898. className="admin-desc-content"
  4899. >
  4900. <Tabs
  4901. tabBarExtraContent={
  4902. <div style={{fontWeight:'bold',paddingRight:'15px'}}>
  4903. <span>
  4904. 项目名称:
  4905. <span style={{color:'#F00',paddingRight:'5px'}}>{this.state.taskName}</span>
  4906. </span>
  4907. <span style={{marginLeft:'15px'}}>
  4908. 项目编号:
  4909. <span style={{color:'#F00',paddingRight:'5px'}}>
  4910. {this.state.id}
  4911. {
  4912. this.state.splitStatus === 2 ? '('+this.state.splitSuper+'-'+this.state.splitId+')' : ''
  4913. }
  4914. </span>
  4915. </span>
  4916. </div>
  4917. }
  4918. activeKey={this.state.activeKey}
  4919. onChange={this.orderChange}
  4920. >
  4921. <TabPane tab="项目概况" key="1">
  4922. <div className="clearfix">
  4923. <FormItem
  4924. className="half-item"
  4925. {...formItemLayout}
  4926. label="当前项目情况"
  4927. >
  4928. <Radio.Group
  4929. value={this.state.status}
  4930. onChange={(e) => {
  4931. this.setState({ status: e.target.value })
  4932. }}
  4933. >
  4934. <Radio value={0}>开启</Radio>
  4935. <Radio value={1}>暂停</Radio>
  4936. </Radio.Group>
  4937. <Button
  4938. type="primary"
  4939. size="small"
  4940. style={{ marginTop: '5px', position: 'absolute' }}
  4941. onClick={this.caozuorizhi}
  4942. >
  4943. 操作日志
  4944. </Button>
  4945. </FormItem>
  4946. <FormItem
  4947. className="half-item"
  4948. {...formItemLayout}
  4949. label="合同编号"
  4950. >
  4951. <span>{this.state.contractNo}</span>
  4952. </FormItem>
  4953. </div>
  4954. <div className="clearfix">
  4955. <FormItem
  4956. className="half-item"
  4957. {...formItemLayout}
  4958. label="项目状态"
  4959. >
  4960. <Select
  4961. placeholder="选择项目状态"
  4962. style={{ width: '200px' }}
  4963. value={this.state.projectStatus}
  4964. onChange={(e) => {
  4965. this.setState({ projectStatus: e })
  4966. }}
  4967. >
  4968. {projectStatus.map(function (item) {
  4969. return (
  4970. <Select.Option key={item.value}>
  4971. {item.key}
  4972. </Select.Option>
  4973. )
  4974. })}
  4975. </Select>
  4976. </FormItem>
  4977. <FormItem
  4978. className="half-item"
  4979. {...formItemLayout}
  4980. label="是否特批"
  4981. >
  4982. <span>{getApproval(this.state.approval)}</span>
  4983. </FormItem>
  4984. <FormItem
  4985. className="half-item"
  4986. {...formItemLayout}
  4987. label="结算状态"
  4988. >
  4989. <span>
  4990. {getLiquidationStatus(this.state.liquidationStatus)}
  4991. </span>
  4992. </FormItem>
  4993. <FormItem
  4994. className="half-item"
  4995. {...formItemLayout}
  4996. label="流程状态"
  4997. >
  4998. <span>{getProcessStatus(this.state.processStatus)}</span>
  4999. </FormItem>
  5000. <FormItem
  5001. className="half-item"
  5002. {...formItemLayout}
  5003. label="订单编号"
  5004. >
  5005. <span>{this.state.orderNo}</span>
  5006. </FormItem>
  5007. </div>
  5008. <div className="clearfix">
  5009. <FormItem
  5010. className="half-item"
  5011. {...formItemLayout}
  5012. label="满意度表格"
  5013. >
  5014. <Radio.Group
  5015. value={this.state.formRetrieve}
  5016. onChange={(e) => {
  5017. this.setState({ formRetrieve: e.target.value })
  5018. }}
  5019. >
  5020. <Radio value={0}>未收回</Radio>
  5021. <Radio value={1}>已收回</Radio>
  5022. <Radio value={2}>其他</Radio>
  5023. </Radio.Group>
  5024. </FormItem>
  5025. <FormItem
  5026. className="half-item"
  5027. {...formItemLayout}
  5028. label="退单"
  5029. >
  5030. <Radio.Group
  5031. value={this.state.taskRefund}
  5032. onChange={(e) => {
  5033. this.setState({ taskRefund: e.target.value })
  5034. }}
  5035. >
  5036. <Radio value={0}>已完成</Radio>
  5037. <Radio value={1}>未完成</Radio>
  5038. <Radio value={2}>其他</Radio>
  5039. </Radio.Group>
  5040. </FormItem>
  5041. </div>
  5042. <div className="clearfix">
  5043. {
  5044. <FormItem
  5045. className="half-item"
  5046. {...formItemLayout}
  5047. label="(满意度)备注"
  5048. >
  5049. <Input
  5050. type="textarea"
  5051. placeholder="请输入备注"
  5052. rows={2}
  5053. value={this.state.retrieveContent}
  5054. onChange={(e) => {
  5055. this.setState({ retrieveContent: e.target.value })
  5056. }}
  5057. />
  5058. </FormItem>
  5059. }
  5060. {
  5061. <FormItem
  5062. className="half-item"
  5063. {...formItemLayout}
  5064. label="(退单)备注"
  5065. >
  5066. <Input
  5067. type="textarea"
  5068. placeholder="请输入备注"
  5069. rows={2}
  5070. value={this.state.refundContent}
  5071. onChange={(e) => {
  5072. this.setState({ refundContent: e.target.value })
  5073. }}
  5074. />
  5075. </FormItem>
  5076. }
  5077. </div>
  5078. <div className="clearfix">
  5079. <h3 className="sub-title">订单负责人信息</h3>
  5080. <FormItem
  5081. className="half-item"
  5082. {...formItemLayout}
  5083. label="负责人"
  5084. >
  5085. <span>
  5086. {this.state.salesmanName + '(' + this.state.depName + ')'}
  5087. </span>
  5088. </FormItem>
  5089. <FormItem
  5090. className="half-item"
  5091. {...formItemLayout}
  5092. label="负责人电话"
  5093. >
  5094. <span>{this.state.salesmanMobile}</span>
  5095. </FormItem>
  5096. <FormItem
  5097. className="half-item"
  5098. {...formItemLayout}
  5099. label="当前财务负责人"
  5100. >
  5101. <span>{this.state.nowFinance}</span>
  5102. </FormItem>
  5103. <FormItem
  5104. className="half-item"
  5105. {...formItemLayout}
  5106. label="当前财务负责人电话"
  5107. >
  5108. <span>{this.state.nowFinanceMobile}</span>
  5109. </FormItem>
  5110. <FormItem
  5111. className="half-item"
  5112. {...formItemLayout}
  5113. style={{ opacity: '.5' }}
  5114. label="原负责人"
  5115. >
  5116. <span>{this.state.oldSalesmanName}</span>
  5117. </FormItem>
  5118. <FormItem
  5119. className="half-item"
  5120. {...formItemLayout}
  5121. style={{ opacity: '.5' }}
  5122. label="原负责人电话"
  5123. >
  5124. <span>{this.state.oldSalesmanMobile}</span>
  5125. </FormItem>
  5126. <FormItem
  5127. className="half-item"
  5128. {...formItemLayout}
  5129. style={{ opacity: '.5' }}
  5130. label="实际财务操作人"
  5131. >
  5132. <span>{this.state.financeName}</span>
  5133. </FormItem>
  5134. <FormItem
  5135. className="half-item"
  5136. {...formItemLayout}
  5137. style={{ opacity: '.5' }}
  5138. label="实际财务操作人电话"
  5139. >
  5140. <span>{this.state.financeMobile}</span>
  5141. </FormItem>
  5142. <FormItem
  5143. className="half-item"
  5144. {...formItemLayout}
  5145. label="订单留言"
  5146. >
  5147. <span>{this.state.orderRemarks}</span>
  5148. </FormItem>
  5149. <FormItem className="half-item" {...formItemLayout} label="">
  5150. <Button onClick={this.getOrderLog}>查看订单日志</Button>
  5151. </FormItem>
  5152. <OrderRiZi
  5153. dataSourcerizhi={this.state.dataSourceY}
  5154. closeOrderLog={this.closeOrderLog}
  5155. visible={this.state.avisible}
  5156. loading={this.state.loading}
  5157. />
  5158. </div>
  5159. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  5160. <div className="clearfix">
  5161. <h3 className="sub-title">联系信息</h3>
  5162. <FormItem
  5163. className="half-item"
  5164. {...formItemLayout}
  5165. label="客户名称"
  5166. >
  5167. <span>{this.state.userName}</span>
  5168. </FormItem>
  5169. <FormItem
  5170. className="half-item"
  5171. {...formItemLayout}
  5172. label="企业法人"
  5173. >
  5174. <Input
  5175. placeholder="请输入法人名称"
  5176. value={this.state.legalPerson}
  5177. style={{ width: '200px' }}
  5178. onChange={(e) => {
  5179. this.setState({ legalPerson: e.target.value })
  5180. }}
  5181. ref="commodityQuantity"
  5182. />
  5183. </FormItem>
  5184. <FormItem
  5185. className="half-item"
  5186. {...formItemLayout}
  5187. label="法人电话"
  5188. >
  5189. <Input
  5190. placeholder="请输入法人电话"
  5191. value={this.state.legalPersonTel}
  5192. style={{ width: '200px' }}
  5193. onChange={(e) => {
  5194. this.setState({ legalPersonTel: e.target.value })
  5195. }}
  5196. ref="commodityQuantity"
  5197. />
  5198. </FormItem>
  5199. <FormItem
  5200. className="half-item"
  5201. {...formItemLayout}
  5202. label="客户联系人"
  5203. >
  5204. <Input
  5205. placeholder="请输入联系人名称"
  5206. value={this.state.contacts}
  5207. style={{ width: '200px' }}
  5208. onChange={(e) => {
  5209. this.setState({ contacts: e.target.value })
  5210. }}
  5211. ref="commodityQuantity"
  5212. />
  5213. </FormItem>
  5214. <FormItem
  5215. className="half-item"
  5216. {...formItemLayout}
  5217. label="联系人电话"
  5218. >
  5219. <Input
  5220. placeholder="请输入联系人电话"
  5221. value={this.state.contactMobile}
  5222. style={{ width: '200px' }}
  5223. onChange={(e) => {
  5224. this.setState({ contactMobile: e.target.value })
  5225. }}
  5226. ref="commodityQuantity"
  5227. />
  5228. </FormItem>
  5229. <FormItem
  5230. className="half-item"
  5231. {...formItemLayout}
  5232. label="企业地址"
  5233. >
  5234. <Cascader
  5235. options={areaSelect()}
  5236. value={this.state.ProvinceCity}
  5237. placeholder="选择城市"
  5238. style={{ width: '200px' }}
  5239. onChange={(e) => {
  5240. this.setState({ ProvinceCity: e })
  5241. }}
  5242. />
  5243. </FormItem>
  5244. <FormItem
  5245. className="half-item"
  5246. {...formItemLayout}
  5247. label=""
  5248. ></FormItem>
  5249. <FormItem className="half-item" {...formItemLayout} label="">
  5250. <Input
  5251. placeholder="请输入详细地址"
  5252. value={this.state.postalAddress}
  5253. style={{ width: '200px', marginLeft: '12em' }}
  5254. onChange={(e) => {
  5255. this.setState({ postalAddress: e.target.value })
  5256. }}
  5257. ref="commodityQuantity"
  5258. />
  5259. </FormItem>
  5260. </div>
  5261. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  5262. <div className="clearfix">
  5263. <h3 className="sub-title">项目信息</h3>
  5264. <FormItem
  5265. className="half-item"
  5266. {...formItemLayout}
  5267. label="项目编号"
  5268. >
  5269. <span>
  5270. {this.state.splitStatus == 2
  5271. ? this.state.splitSuper + '-' + this.state.splitId
  5272. : this.state.id}
  5273. </span>
  5274. </FormItem>
  5275. <FormItem
  5276. className="half-item"
  5277. {...formItemLayout}
  5278. label="项目名称"
  5279. >
  5280. <span>{this.state.taskName}</span>
  5281. </FormItem>
  5282. <FormItem
  5283. className="half-item"
  5284. {...formItemLayout}
  5285. label="项目状态"
  5286. >
  5287. <Select
  5288. placeholder="选择项目状态"
  5289. style={{ width: '200px' }}
  5290. value={this.state.taskStatus}
  5291. onChange={(e) => {
  5292. this.setState({ taskStatus: e })
  5293. }}
  5294. >
  5295. {taskStatus.map(function (item) {
  5296. return (
  5297. <Select.Option key={item.value}>
  5298. {item.key}
  5299. </Select.Option>
  5300. )
  5301. })}
  5302. </Select>
  5303. </FormItem>
  5304. <FormItem
  5305. className="half-item"
  5306. {...formItemLayout}
  5307. label="项目类别"
  5308. >
  5309. <span>{this.state.cname}</span>
  5310. </FormItem>
  5311. <FormItem
  5312. className="half-item"
  5313. {...formItemLayout}
  5314. label="证书编号"
  5315. >
  5316. <Input
  5317. placeholder="请输入证书编号"
  5318. value={this.state.certificateNumber}
  5319. style={{ width: '200px' }}
  5320. onChange={(e) => {
  5321. this.setState({ certificateNumber: e.target.value })
  5322. }}
  5323. ref="commodityQuantity"
  5324. />
  5325. </FormItem>
  5326. </div>
  5327. <div className="clearfix" style={{ marginTop: '10px' }}>
  5328. <FormItem
  5329. labelCol={{ span: 3 }}
  5330. wrapperCol={{ span: 14 }}
  5331. label="附件"
  5332. >
  5333. <Picture
  5334. fileList={(e) => {
  5335. this.setState({ attachmentUrl: e })
  5336. }}
  5337. pictureUrl={this.state.attachmentUrl}
  5338. visible={this.props.visible}
  5339. data={{
  5340. sign: 'order_task_file',
  5341. url: '/api/admin/orderProject/uploadOrderTaskFile',
  5342. number: 8,
  5343. }}
  5344. />
  5345. </FormItem>
  5346. </div>
  5347. <div className="clearfix">
  5348. <FormItem
  5349. labelCol={{ span: 3 }}
  5350. wrapperCol={{ span: 16 }}
  5351. label="备注"
  5352. >
  5353. <Input
  5354. type="textarea"
  5355. placeholder="请输入备注"
  5356. rows={4}
  5357. value={this.state.taskComment}
  5358. onChange={(e) => {
  5359. this.setState({ taskComment: e.target.value })
  5360. }}
  5361. />
  5362. </FormItem>
  5363. </div>
  5364. <div className="clearfix">
  5365. <h3 className="sub-title">项目申报进度</h3>
  5366. <FormItem
  5367. className="half-item"
  5368. {...formItemLayout}
  5369. label="申报批次"
  5370. >
  5371. <Select
  5372. value={
  5373. this.state.declarationBatch
  5374. ? this.state.declarationBatch
  5375. : undefined
  5376. }
  5377. placeholder="请选择批次"
  5378. style={{ width: 200 }}
  5379. onChange={(e) => {
  5380. this.setState({
  5381. declarationBatch: e,
  5382. })
  5383. }}
  5384. >
  5385. <Option value={1}>第一批</Option>
  5386. <Option value={2}>第二批</Option>
  5387. <Option value={3}>第三批</Option>
  5388. <Option value={4}>第四批</Option>
  5389. </Select>
  5390. </FormItem>
  5391. <FormItem
  5392. className="half-item"
  5393. {...formItemLayout}
  5394. label="软著派单数量"
  5395. >
  5396. <span>{this.state.commodityQuantity}</span>
  5397. <Button
  5398. type="primary"
  5399. size="small"
  5400. style={{ marginLeft: '45px' }}
  5401. onClick={this.addcontact}
  5402. >
  5403. +增加下证信息
  5404. </Button>
  5405. </FormItem>
  5406. <div className="patent-table">
  5407. <Spin spinning={this.state.loading}>
  5408. <Table
  5409. columns={this.state.ContactsLists}
  5410. dataSource={this.state.contactList}
  5411. pagination={false}
  5412. bordered
  5413. size="small"
  5414. />
  5415. </Spin>
  5416. </div>
  5417. </div>
  5418. <div className="clearfix">
  5419. <h3 className="sub-title">项目业务</h3>
  5420. <div className="patent-table">
  5421. <Spin spinning={this.state.loading}>
  5422. <Table
  5423. columns={this.state.columnsX}
  5424. dataSource={this.state.dataSourceX}
  5425. pagination={this.state.paginations}
  5426. onRowClick={this.tableRowClickX}
  5427. bordered
  5428. size="small"
  5429. />
  5430. </Spin>
  5431. </div>
  5432. </div>
  5433. <div className="clearfix">
  5434. <Button
  5435. className="cancel"
  5436. type="primary"
  5437. onClick={this.tijiaoOk}
  5438. style={{ marginLeft: '200px', marginTop: '10px' }}
  5439. htmlType="submit"
  5440. >
  5441. 保存
  5442. </Button>
  5443. <Button
  5444. className="cancel"
  5445. type="ghost"
  5446. onClick={this.visitCancel}
  5447. style={{ marginLeft: '50px', marginTop: '10px' }}
  5448. >
  5449. 取消
  5450. </Button>
  5451. </div>
  5452. </TabPane>
  5453. <TabPane tab="外包/供应商信息" key="2">
  5454. {this.state.refundStatus != 0 && this.state.refundStatus != 1 ? (
  5455. <div style={{ marginTop: 10 }}>
  5456. <div className="clearfix">
  5457. <FormItem
  5458. className="half-item"
  5459. {...formItemLayout}
  5460. label={
  5461. <span>
  5462. <strong style={{ color: '#f00' }}>*</strong>
  5463. 类型
  5464. </span>
  5465. }
  5466. >
  5467. <Radio.Group
  5468. value={this.state.startType}
  5469. onChange={(e) => {
  5470. this.setState({ startType: e.target.value })
  5471. }}
  5472. >
  5473. <Radio value={0}>外包(不走总部)</Radio>
  5474. <Radio value={1}>供应商信息</Radio>
  5475. </Radio.Group>
  5476. </FormItem>
  5477. </div>
  5478. {/* 专利类型 */}
  5479. <div
  5480. className="clearfix"
  5481. style={{
  5482. display: this.state.projectType === 1 ? 'block' : 'none',
  5483. }}
  5484. >
  5485. <FormItem
  5486. className="half-item"
  5487. {...formItemLayout}
  5488. label={
  5489. <span>
  5490. <strong style={{ color: '#f00' }}>*</strong>
  5491. 专利类型
  5492. </span>
  5493. }
  5494. >
  5495. <Radio.Group
  5496. value={this.state.patentType}
  5497. onChange={(e) => {
  5498. let _this = this;
  5499. if(this.state.thirdInfoList.length >0){
  5500. confirm({
  5501. title: '确定要切换吗?',
  5502. content: '切换将删除所有第三信息和付款节点',
  5503. onOk() {
  5504. return new Promise((resolve, reject) => {
  5505. _this.setState({ patentType: e.target.value },()=>{
  5506. _this.projectTypeTabContent(_this.state.projectType);
  5507. })
  5508. _this.confirmDeletNew(-1,resolve,reject)
  5509. if(_this.state.payNodeList.length > 0){
  5510. _this.payNodeConfirmDeletNew(-1,resolve,reject);
  5511. }
  5512. }).catch(() => console.log('Oops errors!'));
  5513. },
  5514. onCancel() {},
  5515. });
  5516. }else{
  5517. this.setState({ patentType: e.target.value },()=>{
  5518. this.projectTypeTabContent(this.state.projectType);
  5519. })
  5520. }
  5521. }}
  5522. >
  5523. <Radio value={0}>专利申请/变更/转让</Radio>
  5524. <Radio value={1}>专利买卖</Radio>
  5525. </Radio.Group>
  5526. </FormItem>
  5527. </div>
  5528. <div
  5529. className="clearfix"
  5530. style={{
  5531. display: this.state.projectType === 1? 'block' : 'none',
  5532. }}
  5533. >
  5534. <FormItem
  5535. className="half-item"
  5536. {...formItemLayout}
  5537. label={
  5538. <span>
  5539. <strong style={{ color: '#f00' }}>*</strong>
  5540. 专利名称
  5541. </span>
  5542. }
  5543. >
  5544. <Radio.Group
  5545. value={this.state.patentNameType}
  5546. onChange={(e) => {
  5547. let _this = this;
  5548. if(this.state.thirdInfoList.length >0){
  5549. confirm({
  5550. title: '确定要切换吗?',
  5551. content: '切换将删除所有第三信息和付款节点',
  5552. onOk() {
  5553. return new Promise((resolve, reject) => {
  5554. _this.setState({ patentNameType: e.target.value },()=>{
  5555. _this.projectTypeTabContent(_this.state.projectType);
  5556. })
  5557. _this.confirmDeletNew(-1,resolve,reject)
  5558. if(_this.state.payNodeList.length > 0){
  5559. _this.payNodeConfirmDeletNew(-1,resolve,reject);
  5560. }
  5561. }).catch(() => console.log('Oops errors!'));
  5562. },
  5563. onCancel() {},
  5564. });
  5565. }else{
  5566. this.setState({ patentNameType: e.target.value },()=>{
  5567. this.projectTypeTabContent(this.state.projectType);
  5568. })
  5569. }
  5570. }}
  5571. >
  5572. <Radio value={0}>实用新型专利</Radio>
  5573. <Radio value={1}>发明专利</Radio>
  5574. <Radio value={2}>外观专利</Radio>
  5575. {/*<Radio value={3}>*/}
  5576. {/* 其他*/}
  5577. {/* <Input*/}
  5578. {/* disabled={this.state.patentNameType !== 3}*/}
  5579. {/* value={this.state.patentName}*/}
  5580. {/* style={{ marginLeft: '15px' }}*/}
  5581. {/* onChange={(e) => {*/}
  5582. {/* this.setState({*/}
  5583. {/* patentName: e.target.value,*/}
  5584. {/* })*/}
  5585. {/* }}*/}
  5586. {/* placeholder="请填写专利名称"*/}
  5587. {/* />*/}
  5588. {/*</Radio>*/}
  5589. </Radio.Group>
  5590. </FormItem>
  5591. </div>
  5592. {/* 第三方信息专利 */}
  5593. <div
  5594. style={{
  5595. // display: this.state.type == 1 ? "block" : "none",
  5596. display: this.state.type == 1 ? 'block' : 'block',
  5597. }}
  5598. >
  5599. <span
  5600. style={{
  5601. marginLeft: '50px',
  5602. fontSize: '18px',
  5603. }}
  5604. >
  5605. 第三方信息
  5606. </span>
  5607. <span
  5608. style={{
  5609. display: 'inline-block',
  5610. marginLeft: 10,
  5611. color: 'red',
  5612. }}
  5613. >
  5614. 金额总计(万元): {this.state.allTotalAmount}
  5615. </span>
  5616. <Button
  5617. type="primary"
  5618. onClick={(e) => {
  5619. if(this.state.projectType === 1 && this.state.patentType === -1){
  5620. message.info('请先选择专利类型');
  5621. }else if(this.state.projectType === 1 && this.state.patentNameType === -1){
  5622. message.info('请先选择专利名称');
  5623. }
  5624. else{
  5625. this.addThirdList()
  5626. }
  5627. }}
  5628. style={{
  5629. float: 'right',
  5630. marginRight: '50px',
  5631. marginBottom: '15px',
  5632. }}
  5633. >
  5634. +新增供应商名称
  5635. </Button>
  5636. </div>
  5637. <div
  5638. className="clearfix"
  5639. style={{
  5640. // display: this.state.type == 1 ? "block" : "none",
  5641. display: this.state.type == 1 ? 'block' : 'block',
  5642. }}
  5643. >
  5644. <Spin spinning={this.state.loading}>
  5645. <Form layout="horizontal">
  5646. <Table
  5647. pagination={false}
  5648. columns={this.state.ContactsListsNew}
  5649. dataSource={this.state.thirdInfoList}
  5650. onRowClick={this.tableRowClickOne}
  5651. scroll={{ x: 'max-content', y: 0 }}
  5652. bordered
  5653. size="small"
  5654. />
  5655. <Col
  5656. span={24}
  5657. offset={9}
  5658. style={{ marginTop: '15px' }}
  5659. />
  5660. </Form>
  5661. </Spin>
  5662. </div>
  5663. {/*如果是软著类或者专利类的专利申请,隐藏付款节点*/}
  5664. <div
  5665. style={{
  5666. display: (this.state.projectType === 1 && this.state.patentType === 0) || this.state.projectType === 2? 'none' : 'block', //0正常 1专利 2软著 3审计
  5667. }}
  5668. >
  5669. <span
  5670. style={{
  5671. marginLeft: '50px',
  5672. fontSize: '18px',
  5673. }}
  5674. >
  5675. 付款节点
  5676. </span>
  5677. <span
  5678. style={{
  5679. display: 'inline-block',
  5680. marginLeft: 10,
  5681. color: 'red',
  5682. }}
  5683. ></span>
  5684. <Button
  5685. type="primary"
  5686. onClick={(e) => {
  5687. this.addPayNode()
  5688. }}
  5689. style={{
  5690. float: 'right',
  5691. marginRight: '50px',
  5692. marginBottom: '15px',
  5693. }}
  5694. >
  5695. +新增付款节点
  5696. </Button>
  5697. </div>
  5698. {/*如果是软著类或者专利类的专利申请,隐藏付款节点*/}
  5699. <div
  5700. className="clearfix"
  5701. style={{
  5702. display: (this.state.projectType === 1 && this.state.patentType === 0) || this.state.projectType === 2? 'none' : 'block', //0正常 1专利 2软著 3审计
  5703. }}
  5704. >
  5705. <Spin spinning={this.state.loading}>
  5706. <Form layout="horizontal">
  5707. <Table
  5708. pagination={false}
  5709. columns={this.state.PayNodeTableColunms}
  5710. dataSource={this.state.payNodeList}
  5711. onRowClick={this.payNodeTableRowClickOne}
  5712. scroll={{ x: 'max-content', y: 0 }}
  5713. bordered
  5714. size="small"
  5715. />
  5716. <Col
  5717. span={24}
  5718. offset={9}
  5719. style={{ marginTop: '15px' }}
  5720. />
  5721. </Form>
  5722. </Spin>
  5723. </div>
  5724. <div className="clearfix">
  5725. <FormItem
  5726. className="half-item"
  5727. {...formItemLayout}
  5728. label={
  5729. <span>
  5730. <strong style={{ color: '#f00' }}>*</strong>备注
  5731. </span>
  5732. }
  5733. >
  5734. <TextArea
  5735. rows={4}
  5736. value={this.state.outsourceRemarks}
  5737. onChange={(e) => {
  5738. this.setState({
  5739. outsourceRemarks: e.target.value,
  5740. })
  5741. }}
  5742. placeholder="请输入备注"
  5743. />
  5744. </FormItem>
  5745. </div>
  5746. {/*<div className="clearfix">
  5747. <FormItem className="half-item"
  5748. {...formItemLayout}
  5749. label="上传协议文件" style={{height:"auto"}}>
  5750. <Upload header={{authorization: 'authorization-text'}} action={globalConfig.context + "/api/admin/outsourceOrg/uploadOutsourceFile"}
  5751. data={(e)=>{
  5752. return {
  5753. 'sign': e.name.substring(0,e.name.lastIndexOf("."))
  5754. }
  5755. }}
  5756. fileList={this.state.fileUrl}
  5757. onChange={(e)=>{
  5758. this.setState({
  5759. attachmentUrl:e.fileList,
  5760. fileUrl:e.fileList
  5761. })
  5762. }}>
  5763. {fileUrl.length>1?null:<Button>
  5764. <Icon type="upload" /> 点击上传
  5765. </Button>}
  5766. </Upload>
  5767. <span className="tip" style={{display:"inline-block"}}>支持文件格式: doc,excel,ppt</span>
  5768. </FormItem>
  5769. </div>*/}
  5770. <p
  5771. className="tip"
  5772. style={{
  5773. paddingBottom: '12px',
  5774. width: '240px',
  5775. marginLeft: '145px',
  5776. color: 'red',
  5777. }}
  5778. >
  5779. 首次派单项目,需上传协议,第2次起,同项目,只需写外包公司
  5780. </p>
  5781. <div className="clearfix">
  5782. <FormItem
  5783. labelCol={{ span: 4 }}
  5784. wrapperCol={{ span: 18 }}
  5785. label={
  5786. <span>
  5787. 合同/协议扫描件
  5788. </span>
  5789. }
  5790. >
  5791. <PicturesWall
  5792. fileList={this.getOrgCodeUrlWai}
  5793. pictureUrl={this.state.pictureUrl}
  5794. />
  5795. <p style={{ color: 'red' }}>图片建议:要清晰。</p>
  5796. </FormItem>
  5797. </div>
  5798. {/*只有审核拒绝和第一次发起外包的时候才要填写发起原因*/}
  5799. {typeof this.state.refundStatus === 'undefined' || this.state.refundStatus === 2 ? <div className="clearfix">
  5800. <FormItem
  5801. className="half-item"
  5802. {...formItemLayout}
  5803. label={
  5804. <span>
  5805. <strong style={{ color: '#f00' }}>*</strong>发起原因
  5806. </span>
  5807. }
  5808. >
  5809. <TextArea
  5810. rows={4}
  5811. value={this.state.reason}
  5812. onChange={(e) => {
  5813. this.setState({
  5814. reason: e.target.value,
  5815. })
  5816. }}
  5817. placeholder="请输入发起原因"
  5818. />
  5819. </FormItem>
  5820. </div> : <div/>}
  5821. <div className="clearfix">
  5822. <div
  5823. style={{
  5824. display: 'inline-black',
  5825. textAlign: 'center',
  5826. }}
  5827. >
  5828. <Button
  5829. type="primary"
  5830. loading={this.state.loading}
  5831. onClick={()=>{
  5832. this.sureOut(this.state.startType);
  5833. }}
  5834. >
  5835. {
  5836. this.state.startType === 0 ? "确认发起外包,不通过总部" : "提交供应商信息"
  5837. }
  5838. </Button>
  5839. <p className="tip" style={{ color: 'red' }}>
  5840. {
  5841. this.state.startType === 0 ? "提示:高于总部价格,费用个人承担" : "确定提交供应商信息,提交后,不可修改"
  5842. }
  5843. </p>
  5844. </div>
  5845. </div>
  5846. </div>
  5847. ) : (
  5848. <div>
  5849. {
  5850. this.state.speVisible && this.state.activeKey === '2' ?
  5851. <CheckProject
  5852. {...this.props}
  5853. tid={this.state.tid}
  5854. oldInfor={this.state.oldInfor}
  5855. projectType={this.state.projectType} //0正常 1专利 2软著 3审计
  5856. patentNameType={this.state.patentNameType}
  5857. patentName={this.state.patentName}
  5858. patentType={this.state.patentType}
  5859. status={this.state.refundStatus}
  5860. isPreviewPay={true}
  5861. thirdInfoList={this.state.thirdInfoList}
  5862. dataSource={this.state.payNodeList}
  5863. outsourceRemarks={this.state.outsourceRemarks}
  5864. fileList={this.state.pictureUrl}
  5865. startType={this.state.startType}
  5866. projectStatus={this.state.projectStatus}
  5867. onRefresh={()=>{
  5868. this.waiDetail();
  5869. this.thirdTable(this.state.tid);
  5870. this.getSelectOutsourceLog(this.state.tid);
  5871. this.payNodeTable(this.state.tid)
  5872. this.loadData(this.state.page)
  5873. }}
  5874. /> : <div/>
  5875. }
  5876. </div>
  5877. )}
  5878. {(this.state.refundStatus == 1 ||
  5879. this.state.refundStatus == 0 ||
  5880. this.state.refundStatus == 2) &&
  5881. this.state.startType !== 1
  5882. ? (
  5883. <div className="clearfix"
  5884. style={{
  5885. display: this.state.refundStatus == 0 ? 'none' : 'block',
  5886. }}
  5887. >
  5888. <hr className="division" />
  5889. {parseInt(this.state.startType) !== 1 ? <div style={{
  5890. color:'#F00',
  5891. fontWeight: 'bolder',
  5892. paddingBottom: '20px',
  5893. }}>
  5894. 审核结果: <span style={{paddingLeft:'20px'}}>{getRefundStatus(this.state.refundStatus)}</span>
  5895. </div> : <div/>}
  5896. <div className="outsourceLogList">
  5897. {
  5898. this.state.outsourceLogs && this.state.outsourceLogs.map((value,index)=>(
  5899. <div key={index} className="outsourceLogItem outsource">
  5900. <div style={{
  5901. display:'flex',
  5902. flexFlow:'row nowrap',
  5903. paddingBottom: '3px',
  5904. paddingTop: '3px',
  5905. }}>
  5906. <div>
  5907. {value.aname}
  5908. </div>
  5909. <div style={{paddingLeft:'5px'}}>
  5910. {
  5911. value.status === 0 ?
  5912. <Tag color="#2db7f5">发起外包审核</Tag> :
  5913. value.status === 1 ? <Tag color="#87d068">通过</Tag> :
  5914. <Tag color="#f50">驳回</Tag>
  5915. }
  5916. </div>
  5917. <div style={{
  5918. wordBreak: 'break-all',
  5919. maxWidth:'67%',
  5920. }}>
  5921. {value.remarks}
  5922. </div>
  5923. <div style={{paddingLeft: '10px'}}>
  5924. {value.createTimes}
  5925. </div>
  5926. </div>
  5927. </div>
  5928. ))
  5929. }
  5930. </div>
  5931. {/* <div*/}
  5932. {/* className="clearfix"*/}
  5933. {/* style={{*/}
  5934. {/* display: this.state.refundStatus == 0 ? 'none' : 'block',*/}
  5935. {/* }}*/}
  5936. {/* >*/}
  5937. {/* <FormItem*/}
  5938. {/* className="half-item"*/}
  5939. {/* {...formItemLayout}*/}
  5940. {/* label="审核意见"*/}
  5941. {/* >*/}
  5942. {/* <span>{this.state.remarks}</span>*/}
  5943. {/* </FormItem>*/}
  5944. {/* </div>*/}
  5945. {/* {parseInt(this.state.startType) !== 1 ?<div className="clearfix">*/}
  5946. {/* <FormItem*/}
  5947. {/* className="half-item"*/}
  5948. {/* {...formItemLayout}*/}
  5949. {/* label="审核结果"*/}
  5950. {/* >*/}
  5951. {/* <span>{getRefundStatus(this.state.refundStatus)}</span>*/}
  5952. {/* </FormItem>*/}
  5953. {/* </div> : <div/>}*/}
  5954. {/* <div*/}
  5955. {/* className="clearfix"*/}
  5956. {/* style={{*/}
  5957. {/* display: this.state.refundStatus == 0 ? 'none' : 'block',*/}
  5958. {/* }}*/}
  5959. {/* >*/}
  5960. {/* <FormItem*/}
  5961. {/* className="half-item"*/}
  5962. {/* {...formItemLayout}*/}
  5963. {/* label="审核时间"*/}
  5964. {/* >*/}
  5965. {/* <span>{this.state.auditTimes}</span>*/}
  5966. {/* </FormItem>*/}
  5967. {/* </div>*/}
  5968. </div>
  5969. ) : (
  5970. ''
  5971. )}
  5972. </TabPane>
  5973. {!this.props.isZxs || (this.state.isHuiyuan && this.props.isZxs) ? (
  5974. <TabPane tab="订单详情" key="3">
  5975. <Spin spinning={this.state.loading}>
  5976. <OrderDetail
  5977. orderData={this.state.orderData}
  5978. getOrderLog={this.getOrderLog}
  5979. dataSourceX={this.state.dataSourceX}
  5980. contactList={this.state.jiedian}
  5981. orderNo={this.state.orderNo}
  5982. totalCui={this.state.totalCui}
  5983. contactListNew={this.state.jiedianNew}
  5984. pictureUrl={this.state.contractPictureUrl}
  5985. />
  5986. </Spin>
  5987. </TabPane>
  5988. ) : (
  5989. ''
  5990. )}
  5991. </Tabs>
  5992. </Modal>
  5993. <Modal
  5994. width="800px"
  5995. visible={this.state.visibleA}
  5996. onCancel={this.visitCancelA}
  5997. title="操作日志"
  5998. footer=""
  5999. className="admin-desc-content"
  6000. >
  6001. <div className="patent-table patent-table-center">
  6002. <Spin spinning={this.state.loading}>
  6003. <Table
  6004. columns={this.state.columnsA}
  6005. dataSource={this.state.dataSourceA}
  6006. pagination={false}
  6007. bordered
  6008. size="small"
  6009. />
  6010. </Spin>
  6011. </div>
  6012. </Modal>
  6013. <Modal
  6014. title="工时记录"
  6015. visible={this.state.timeVisible}
  6016. onCancel={this.timeClose}
  6017. width={800}
  6018. footer={null}
  6019. >
  6020. <Spin spinning={this.state.loading}>
  6021. <Table
  6022. columns={this.state.columnsTime}
  6023. dataSource={this.state.dataSourceTime}
  6024. pagination={false}
  6025. scroll={{ x: 'max-content', y: 0 }}
  6026. bordered
  6027. size={'small'}
  6028. />
  6029. <p style={{ marginTop: 10, color: 'red' }}>
  6030. 累计工时(小时):{this.state.recordHour}
  6031. </p>
  6032. </Spin>
  6033. </Modal>
  6034. {this.state.ThirdListVisible ? <NewSupplier
  6035. patentNameType={this.state.patentNameType}
  6036. ThirdId={this.state.ThirdId}
  6037. tid={this.state.tid}
  6038. patentType={this.state.patentType}
  6039. projectType={this.state.projectType}
  6040. thirdCompanyName={this.state.thirdCompanyName}
  6041. thirdUnitPrice={this.state.thirdUnitPrice}
  6042. thirdQuantity={this.state.thirdQuantity}
  6043. thirdRemarks={this.state.thirdRemarks}
  6044. spinning={this.state.loading}
  6045. visible={this.state.ThirdListVisible}
  6046. thirdMaterial={this.state.thirdMaterial}
  6047. thirdUrgent={this.state.thirdUrgent}
  6048. audit={this.state.audit}
  6049. assets={this.state.assets}
  6050. income={this.state.income}
  6051. onDetermine={this.handleCancelq}
  6052. onCancel={()=>{
  6053. this.thirdTable(this.state.tid);
  6054. this.setState({
  6055. ThirdListVisible: false,
  6056. ThirdId: '', //供应商id
  6057. thirdCompanyName: '', //第三方名称
  6058. thirdUnitPrice: '', //单价
  6059. thirdQuantity: '', //数量
  6060. currentTotalPrice: '', //总价
  6061. thirdMaterial: 0, //有无材料
  6062. thirdUrgent: 0, //加急情况
  6063. thirdRemarks: '',
  6064. audit: 1,
  6065. assets: '',
  6066. income: '',
  6067. })
  6068. }}
  6069. otherOperations={(data)=>{
  6070. this.setState({
  6071. thirdMaterial: data.thirdMaterial,
  6072. thirdUrgent: data.thirdUrgent,
  6073. customerArr: data.customerArr,
  6074. thirdCompanyName: data.thirdCompanyName
  6075. })
  6076. }}/> : <div/>}
  6077. {this.state.PayNodeVisible ? <OperationPayNode
  6078. tid={this.state.tid}
  6079. cSort={this.state.cSort}
  6080. visible={this.state.PayNodeVisible}
  6081. thirdId={this.state.ThirdId}
  6082. thirdInfoList={this.state.thirdInfoList}
  6083. supplierList={this.state.PayNodeCompany}
  6084. payNodeInfor={this.state.payNodeInfor}
  6085. thirdUnitPrice={this.state.thirdUnitPrice}
  6086. onCancel={()=>{
  6087. this.setState({
  6088. PayNodeVisible: false,
  6089. payNodeInfor: {},
  6090. ThirdId: '',
  6091. thirdUnitPrice: '',
  6092. })
  6093. this.payNodeTable(this.state.tid)
  6094. }}
  6095. /> : <div/>}
  6096. </div>
  6097. )
  6098. },
  6099. })
  6100. export default Task