myTask.jsx 163 KB

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