myTask.jsx 144 KB

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