myTask.jsx 197 KB

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