myTaskOutsource.jsx 117 KB

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