personnelAll.jsx 194 KB

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