myTaskOutsource.jsx 115 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438
  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. render() {
  1562. const { TabPane } = Tabs;
  1563. const formItemLayout = {
  1564. labelCol: { span: 8 },
  1565. wrapperCol: { span: 14 }
  1566. };
  1567. let departmentArr = this.state.departmentArr || [];
  1568. return (
  1569. <div className="user-content">
  1570. {this.state.resVisible ? (
  1571. <ResolutionDetail
  1572. cancel={this.resCancel}
  1573. detail={this.state.resRecord}
  1574. visible={this.state.resVisible}
  1575. id={this.state.resRecord.orderNo}
  1576. />
  1577. ) : (
  1578. ""
  1579. )}
  1580. <ShowModalDiv ShowModal={this.state.showModal} />
  1581. <div className="content-title" style={{ marginBottom: 10 }}>
  1582. <span style={{ fontWeight: 900, fontSize: 16 }}>我的外包项目</span>
  1583. </div>
  1584. <Tabs defaultActiveKey="2" onChange={this.callback} className="test">
  1585. <TabPane tab="更改表格显示数据" key="1">
  1586. <div style={{ marginLeft: 10 }}>
  1587. <ChooseList
  1588. columns={this.state.columns}
  1589. changeFn={this.changeList}
  1590. changeList={this.state.changeList}
  1591. top={55}
  1592. margin={11}
  1593. />
  1594. </div>
  1595. </TabPane>
  1596. <TabPane tab="搜索" key="2">
  1597. <div className="user-search" style={{ marginLeft: 10 }}>
  1598. <Input
  1599. placeholder="客户名称"
  1600. value={this.state.nameSearch}
  1601. onChange={e => {
  1602. this.setState({ nameSearch: e.target.value });
  1603. }}
  1604. />
  1605. <Input
  1606. placeholder="订单编号"
  1607. value={this.state.orderNoSearch}
  1608. onChange={e => {
  1609. this.setState({ orderNoSearch: e.target.value });
  1610. }}
  1611. />
  1612. <Input
  1613. placeholder="合同编号"
  1614. value={this.state.contractNoSearch}
  1615. onChange={e => {
  1616. this.setState({ contractNoSearch: e.target.value });
  1617. }}
  1618. />
  1619. <Input
  1620. placeholder="项目编号"
  1621. value={this.state.taskNoSearch}
  1622. onChange={e => {
  1623. this.setState({ taskNoSearch: e.target.value });
  1624. }}
  1625. />
  1626. <Select
  1627. placeholder="选择部门"
  1628. style={{ width: 150, marginRight: "10px" }}
  1629. value={this.state.departmenttSearch}
  1630. onChange={e => {
  1631. this.setState({ departmenttSearch: e });
  1632. }}
  1633. >
  1634. {departmentArr.map(function(item) {
  1635. return (
  1636. <Select.Option key={item.id}>{item.name}</Select.Option>
  1637. );
  1638. })}
  1639. </Select>
  1640. <Select
  1641. placeholder="项目状态"
  1642. style={{ width: 150, marginRight: "10px" }}
  1643. value={this.state.projectStatusSearch}
  1644. onChange={e => {
  1645. this.setState({ projectStatusSearch: e });
  1646. console.log(this.state.projectStatusSearch);
  1647. }}
  1648. >
  1649. {projectStatus.map(function(item) {
  1650. return (
  1651. <Select.Option key={item.value}>{item.key}</Select.Option>
  1652. );
  1653. })}
  1654. </Select>
  1655. <Select
  1656. placeholder="特批状态"
  1657. style={{ width: 150, marginRight: "10px" }}
  1658. value={this.state.approvalSearch}
  1659. onChange={e => {
  1660. this.setState({ approvalSearch: e });
  1661. console.log(this.state.approvalSearch);
  1662. }}
  1663. >
  1664. <Select.Option key={0}>非特批</Select.Option>
  1665. <Select.Option key={1}>特批</Select.Option>
  1666. </Select>
  1667. <Button type="primary" onClick={this.search}>
  1668. 搜索
  1669. </Button>
  1670. <Button onClick={this.reset}>重置</Button>
  1671. {/* <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  1672. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  1673. <span>订单时间 :</span>
  1674. <RangePicker
  1675. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  1676. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  1677. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  1678. </div> */}
  1679. </div>
  1680. </TabPane>
  1681. <TabPane tab="导出Excel" key="3">
  1682. <Button
  1683. type="primary"
  1684. style={{ margin: "11px 0 10px 10px" }}
  1685. onClick={this.exportExec}
  1686. >
  1687. 导出Excel
  1688. </Button>
  1689. </TabPane>
  1690. {/* <TabPane tab="批量操作" key="6">
  1691. <Button
  1692. type="primary"
  1693. disabled={this.state.selectedRowKeys.length == 0}
  1694. style={{ margin: "0px 0px 10px 10px" }}
  1695. onClick={e => {
  1696. e.stopPropagation(),
  1697. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  1698. }}
  1699. >
  1700. 转交
  1701. </Button>
  1702. </TabPane> */}
  1703. </Tabs>
  1704. <div className="patent-table">
  1705. <Spin spinning={this.state.loading}>
  1706. <Table
  1707. columns={
  1708. this.state.changeList == undefined
  1709. ? this.state.columns
  1710. : this.state.changeList
  1711. }
  1712. dataSource={this.state.dataSource}
  1713. pagination={this.state.pagination}
  1714. onRowClick={this.tableRowClick.bind(this)}
  1715. scroll={{ x: "max-content", y: 0 }}
  1716. bordered
  1717. size={"small"}
  1718. />
  1719. </Spin>
  1720. </div>
  1721. <Assign
  1722. title="项目"
  1723. selApi={"/api/admin/orderProject/projectDistribution"}
  1724. data={this.state.assignData}
  1725. showDesc={this.state.assignVisible}
  1726. closeDesc={this.closeAssign.bind(this)}
  1727. fenpaiData={8}
  1728. specially={0}
  1729. roleName={this.state.nub}
  1730. requestMethod={"post"}
  1731. flag={this.state.flag}
  1732. isZhuan={this.state.isZhuan} //是否转交
  1733. />
  1734. <Modal
  1735. className="customeDetails"
  1736. footer=""
  1737. title=""
  1738. width="900px"
  1739. visible={this.state.visible}
  1740. onOk={this.visitOk}
  1741. onCancel={this.visitCancel}
  1742. >
  1743. <Tabs
  1744. onChange={this.callBack}
  1745. type="card"
  1746. activeKey={this.state.modKey}
  1747. >
  1748. <TabPane tab="项目概况" key="1">
  1749. <Form
  1750. layout="horizontal"
  1751. onSubmit={this.handleSubmit}
  1752. id="demand-form"
  1753. style={{ paddingBottom: "00px" }}
  1754. >
  1755. <Spin spinning={this.state.loading}>
  1756. <div className="clearfix">
  1757. <div className="clearfix">
  1758. <FormItem
  1759. className="half-item"
  1760. {...formItemLayout}
  1761. label="当前项目情况"
  1762. >
  1763. <Radio.Group
  1764. value={this.state.status}
  1765. onChange={e => {
  1766. this.setState({ status: e.target.value });
  1767. }}
  1768. >
  1769. <Radio value={0}>开启</Radio>
  1770. <Radio value={1}>暂停</Radio>
  1771. </Radio.Group>
  1772. <Button
  1773. type="primary"
  1774. size="small"
  1775. style={{ marginTop: "5px", position: "absolute" }}
  1776. onClick={this.caozuorizhi}
  1777. >
  1778. 操作日志
  1779. </Button>
  1780. </FormItem>
  1781. <FormItem
  1782. className="half-item"
  1783. {...formItemLayout}
  1784. label="合同编号"
  1785. >
  1786. <span>{this.state.contractNo}</span>
  1787. </FormItem>
  1788. </div>
  1789. <div className="clearfix">
  1790. <FormItem
  1791. className="half-item"
  1792. {...formItemLayout}
  1793. label="项目状态"
  1794. >
  1795. <Select
  1796. placeholder="选择项目状态"
  1797. style={{ width: "200px" }}
  1798. value={this.state.projectStatus}
  1799. onChange={e => {
  1800. this.setState({ projectStatus: e });
  1801. }}
  1802. >
  1803. {projectStatus.map(function(item) {
  1804. return (
  1805. <Select.Option key={item.value}>
  1806. {item.key}
  1807. </Select.Option>
  1808. );
  1809. })}
  1810. </Select>
  1811. </FormItem>
  1812. <FormItem
  1813. className="half-item"
  1814. {...formItemLayout}
  1815. label="是否特批"
  1816. >
  1817. <span>{getApproval(this.state.approval)}</span>
  1818. </FormItem>
  1819. <FormItem
  1820. className="half-item"
  1821. {...formItemLayout}
  1822. label="结算状态"
  1823. >
  1824. <span>
  1825. {getLiquidationStatus(this.state.liquidationStatus)}
  1826. </span>
  1827. </FormItem>
  1828. <FormItem
  1829. className="half-item"
  1830. {...formItemLayout}
  1831. label="流程状态"
  1832. >
  1833. <span>
  1834. {getProcessStatus(this.state.processStatus)}
  1835. </span>
  1836. </FormItem>
  1837. <FormItem
  1838. className="half-item"
  1839. {...formItemLayout}
  1840. label="订单编号"
  1841. >
  1842. <span>{this.state.orderNo}</span>
  1843. </FormItem>
  1844. </div>
  1845. <div className="clearfix">
  1846. <FormItem
  1847. className="half-item"
  1848. {...formItemLayout}
  1849. label="满意度表格"
  1850. >
  1851. <Radio.Group
  1852. value={this.state.formRetrieve}
  1853. onChange={e => {
  1854. this.setState({ formRetrieve: e.target.value });
  1855. }}
  1856. >
  1857. <Radio value={0}>未收回</Radio>
  1858. <Radio value={1}>已收回</Radio>
  1859. <Radio value={2}>其他</Radio>
  1860. </Radio.Group>
  1861. </FormItem>
  1862. <FormItem
  1863. className="half-item"
  1864. {...formItemLayout}
  1865. label="退单"
  1866. >
  1867. <Radio.Group
  1868. value={this.state.taskRefund}
  1869. onChange={e => {
  1870. this.setState({ taskRefund: e.target.value });
  1871. }}
  1872. >
  1873. <Radio value={0}>已完成</Radio>
  1874. <Radio value={1}>未完成</Radio>
  1875. <Radio value={2}>其他</Radio>
  1876. </Radio.Group>
  1877. </FormItem>
  1878. </div>
  1879. <div className="clearfix">
  1880. {
  1881. <FormItem
  1882. className="half-item"
  1883. {...formItemLayout}
  1884. label="(满意度)备注"
  1885. >
  1886. <Input
  1887. type="textarea"
  1888. placeholder="请输入备注"
  1889. rows={2}
  1890. value={this.state.retrieveContent}
  1891. onChange={e => {
  1892. this.setState({
  1893. retrieveContent: e.target.value
  1894. });
  1895. }}
  1896. />
  1897. </FormItem>
  1898. }
  1899. {
  1900. <FormItem
  1901. className="half-item"
  1902. {...formItemLayout}
  1903. label="(退单)备注"
  1904. >
  1905. <Input
  1906. type="textarea"
  1907. placeholder="请输入备注"
  1908. rows={2}
  1909. value={this.state.refundContent}
  1910. onChange={e => {
  1911. this.setState({ refundContent: e.target.value });
  1912. }}
  1913. />
  1914. </FormItem>
  1915. }
  1916. </div>
  1917. <div className="clearfix">
  1918. <h3 className="sub-title">订单负责人信息</h3>
  1919. <FormItem
  1920. className="half-item"
  1921. {...formItemLayout}
  1922. label="负责人"
  1923. >
  1924. <span>
  1925. {this.state.salesmanName +
  1926. "(" +
  1927. this.state.depName +
  1928. ")"}
  1929. </span>
  1930. </FormItem>
  1931. <FormItem
  1932. className="half-item"
  1933. {...formItemLayout}
  1934. label="负责人电话"
  1935. >
  1936. <span>{this.state.salesmanMobile}</span>
  1937. </FormItem>
  1938. <FormItem
  1939. className="half-item"
  1940. {...formItemLayout}
  1941. label="当前财务负责人"
  1942. >
  1943. <span>{this.state.nowFinance}</span>
  1944. </FormItem>
  1945. <FormItem
  1946. className="half-item"
  1947. {...formItemLayout}
  1948. label="当前财务负责人电话"
  1949. >
  1950. <span>{this.state.nowFinanceMobile}</span>
  1951. </FormItem>
  1952. <FormItem
  1953. className="half-item"
  1954. {...formItemLayout}
  1955. style={{ opacity: ".5" }}
  1956. label="原负责人"
  1957. >
  1958. <span>{this.state.oldSalesmanName}</span>
  1959. </FormItem>
  1960. <FormItem
  1961. className="half-item"
  1962. {...formItemLayout}
  1963. style={{ opacity: ".5" }}
  1964. label="原负责人电话"
  1965. >
  1966. <span>{this.state.oldSalesmanMobile}</span>
  1967. </FormItem>
  1968. <FormItem
  1969. className="half-item"
  1970. {...formItemLayout}
  1971. style={{ opacity: ".5" }}
  1972. label="实际财务操作人"
  1973. >
  1974. <span>{this.state.financeName}</span>
  1975. </FormItem>
  1976. <FormItem
  1977. className="half-item"
  1978. {...formItemLayout}
  1979. style={{ opacity: ".5" }}
  1980. label="实际财务操作人电话"
  1981. >
  1982. <span>{this.state.financeMobile}</span>
  1983. </FormItem>
  1984. </div>
  1985. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  1986. <div className="clearfix">
  1987. <h3 className="sub-title">联系信息</h3>
  1988. <FormItem
  1989. className="half-item"
  1990. {...formItemLayout}
  1991. label="客户名称"
  1992. >
  1993. <span>{this.state.userName}</span>
  1994. </FormItem>
  1995. <FormItem
  1996. className="half-item"
  1997. {...formItemLayout}
  1998. label="企业法人"
  1999. >
  2000. <Input
  2001. placeholder="请输入法人名称"
  2002. value={this.state.legalPerson}
  2003. style={{ width: "200px" }}
  2004. onChange={e => {
  2005. this.setState({ legalPerson: e.target.value });
  2006. }}
  2007. ref="commodityQuantity"
  2008. />
  2009. </FormItem>
  2010. <FormItem
  2011. className="half-item"
  2012. {...formItemLayout}
  2013. label="法人电话"
  2014. >
  2015. <Input
  2016. placeholder="请输入法人电话"
  2017. value={this.state.legalPersonTel}
  2018. style={{ width: "200px" }}
  2019. onChange={e => {
  2020. this.setState({ legalPersonTel: e.target.value });
  2021. }}
  2022. ref="commodityQuantity"
  2023. />
  2024. </FormItem>
  2025. <FormItem
  2026. className="half-item"
  2027. {...formItemLayout}
  2028. label="客户联系人"
  2029. >
  2030. <Input
  2031. placeholder="请输入联系人名称"
  2032. value={this.state.contacts}
  2033. style={{ width: "200px" }}
  2034. onChange={e => {
  2035. this.setState({ contacts: e.target.value });
  2036. }}
  2037. ref="commodityQuantity"
  2038. />
  2039. </FormItem>
  2040. <FormItem
  2041. className="half-item"
  2042. {...formItemLayout}
  2043. label="联系人电话"
  2044. >
  2045. <Input
  2046. placeholder="请输入联系人电话"
  2047. value={this.state.contactMobile}
  2048. style={{ width: "200px" }}
  2049. onChange={e => {
  2050. this.setState({ contactMobile: e.target.value });
  2051. }}
  2052. ref="commodityQuantity"
  2053. />
  2054. </FormItem>
  2055. <FormItem
  2056. className="half-item"
  2057. {...formItemLayout}
  2058. label="企业地址"
  2059. >
  2060. <Cascader
  2061. options={areaSelect()}
  2062. value={this.state.ProvinceCity}
  2063. placeholder="选择城市"
  2064. style={{ width: "200px" }}
  2065. onChange={e => {
  2066. this.setState({ ProvinceCity: e });
  2067. }}
  2068. />
  2069. </FormItem>
  2070. <FormItem
  2071. className="half-item"
  2072. {...formItemLayout}
  2073. label=""
  2074. ></FormItem>
  2075. <FormItem
  2076. className="half-item"
  2077. {...formItemLayout}
  2078. label=""
  2079. >
  2080. <Input
  2081. placeholder="请输入详细地址"
  2082. value={this.state.postalAddress}
  2083. style={{ width: "200px", marginLeft: "12em" }}
  2084. onChange={e => {
  2085. this.setState({ postalAddress: e.target.value });
  2086. }}
  2087. ref="commodityQuantity"
  2088. />
  2089. </FormItem>
  2090. </div>
  2091. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2092. <div className="clearfix">
  2093. <h3 className="sub-title">项目信息</h3>
  2094. <FormItem
  2095. className="half-item"
  2096. {...formItemLayout}
  2097. label="项目编号"
  2098. >
  2099. <span>
  2100. {this.state.splitStatus == 2
  2101. ? this.state.splitSuper + "-" + this.state.splitId
  2102. : this.state.id}
  2103. </span>
  2104. </FormItem>
  2105. <FormItem
  2106. className="half-item"
  2107. {...formItemLayout}
  2108. label="项目名称"
  2109. >
  2110. <span>{this.state.taskName}</span>
  2111. </FormItem>
  2112. <FormItem
  2113. className="half-item"
  2114. {...formItemLayout}
  2115. label="项目状态"
  2116. >
  2117. <Select
  2118. placeholder="选择项目状态"
  2119. style={{ width: "200px" }}
  2120. value={this.state.taskStatus}
  2121. onChange={e => {
  2122. this.setState({ taskStatus: e });
  2123. }}
  2124. >
  2125. {taskStatus.map(function(item) {
  2126. return (
  2127. <Select.Option key={item.value}>
  2128. {item.key}
  2129. </Select.Option>
  2130. );
  2131. })}
  2132. </Select>
  2133. </FormItem>
  2134. <FormItem
  2135. className="half-item"
  2136. {...formItemLayout}
  2137. label="项目类别"
  2138. >
  2139. <span>{this.state.cname}</span>
  2140. </FormItem>
  2141. <FormItem
  2142. className="half-item"
  2143. {...formItemLayout}
  2144. label="证书编号"
  2145. >
  2146. <Input
  2147. placeholder="请输入证书编号"
  2148. value={this.state.certificateNumber}
  2149. style={{ width: "200px" }}
  2150. onChange={e => {
  2151. this.setState({
  2152. certificateNumber: e.target.value
  2153. });
  2154. }}
  2155. ref="commodityQuantity"
  2156. />
  2157. </FormItem>
  2158. </div>
  2159. <div className="clearfix">
  2160. <h3 className="sub-title">申报系统账户信息</h3>
  2161. {/*<span style={{color:'red'}}>注:仅技术部可见</span>*/}
  2162. <FormItem
  2163. className="half-item"
  2164. {...formItemLayout}
  2165. label="用户名"
  2166. >
  2167. <Input
  2168. placeholder="请输入用户名"
  2169. value={this.state.declareUser}
  2170. style={{ width: "200px" }}
  2171. onChange={e => {
  2172. this.setState({ declareUser: e.target.value });
  2173. }}
  2174. />
  2175. </FormItem>
  2176. <FormItem
  2177. className="half-item"
  2178. {...formItemLayout}
  2179. label="密码"
  2180. >
  2181. <Input
  2182. placeholder="请输入密码"
  2183. value={this.state.declarePwd}
  2184. style={{ width: "200px" }}
  2185. onChange={e => {
  2186. this.setState({ declarePwd: e.target.value });
  2187. }}
  2188. />
  2189. </FormItem>
  2190. </div>
  2191. <div className="clearfix">
  2192. <h3 className="sub-title">项目申报进度</h3>
  2193. <FormItem
  2194. className="half-item"
  2195. {...formItemLayout}
  2196. label="启动时间"
  2197. >
  2198. <DatePicker
  2199. style={{
  2200. marginTop: "2px",
  2201. width: "200px",
  2202. height: "32px"
  2203. }}
  2204. showTime
  2205. format="YYYY-MM-DD"
  2206. onOk={() => {}}
  2207. value={
  2208. this.state.startDate
  2209. ? moment(this.state.startDate)
  2210. : null
  2211. }
  2212. onChange={(data, dataString) => {
  2213. this.setState({ startDate: dataString });
  2214. }}
  2215. />
  2216. </FormItem>
  2217. <FormItem
  2218. className="half-item"
  2219. {...formItemLayout}
  2220. label="完成时间"
  2221. >
  2222. <DatePicker
  2223. style={{
  2224. marginTop: "2px",
  2225. width: "200px",
  2226. height: "32px"
  2227. }}
  2228. showTime
  2229. format="YYYY-MM-DD"
  2230. onOk={() => {}}
  2231. value={
  2232. this.state.endDate
  2233. ? moment(this.state.endDate)
  2234. : null
  2235. }
  2236. onChange={(data, dataString) => {
  2237. this.setState({ endDate: dataString });
  2238. }}
  2239. />
  2240. </FormItem>
  2241. <FormItem
  2242. className="half-item"
  2243. {...formItemLayout}
  2244. label="受理时间"
  2245. >
  2246. <DatePicker
  2247. style={{
  2248. marginTop: "2px",
  2249. width: "200px",
  2250. height: "32px"
  2251. }}
  2252. showTime
  2253. format="YYYY-MM-DD"
  2254. onOk={() => {}}
  2255. value={
  2256. this.state.acceptDate
  2257. ? moment(this.state.acceptDate)
  2258. : null
  2259. }
  2260. onChange={(data, dataString) => {
  2261. this.setState({ acceptDate: dataString });
  2262. }}
  2263. />
  2264. </FormItem>
  2265. <FormItem
  2266. className="half-item"
  2267. {...formItemLayout}
  2268. label="评审时间"
  2269. >
  2270. <DatePicker
  2271. style={{
  2272. marginTop: "2px",
  2273. width: "200px",
  2274. height: "32px"
  2275. }}
  2276. showTime
  2277. format="YYYY-MM-DD"
  2278. onOk={() => {}}
  2279. value={
  2280. this.state.reviewDate
  2281. ? moment(this.state.reviewDate)
  2282. : null
  2283. }
  2284. onChange={(data, dataString) => {
  2285. this.setState({ reviewDate: dataString });
  2286. }}
  2287. />
  2288. </FormItem>
  2289. <FormItem
  2290. className="half-item"
  2291. {...formItemLayout}
  2292. label="公示时间"
  2293. >
  2294. <DatePicker
  2295. style={{
  2296. marginTop: "2px",
  2297. width: "200px",
  2298. height: "32px"
  2299. }}
  2300. showTime
  2301. format="YYYY-MM-DD"
  2302. onOk={() => {}}
  2303. value={
  2304. this.state.publicityDate
  2305. ? moment(this.state.publicityDate)
  2306. : null
  2307. }
  2308. onChange={(data, dataString) => {
  2309. this.setState({ publicityDate: dataString });
  2310. }}
  2311. />
  2312. </FormItem>
  2313. <FormItem
  2314. className="half-item"
  2315. {...formItemLayout}
  2316. label="发证时间"
  2317. >
  2318. <DatePicker
  2319. style={{
  2320. marginTop: "2px",
  2321. width: "200px",
  2322. height: "32px"
  2323. }}
  2324. showTime
  2325. format="YYYY-MM-DD"
  2326. onOk={() => {}}
  2327. value={
  2328. this.state.licenceDate
  2329. ? moment(this.state.licenceDate)
  2330. : null
  2331. }
  2332. onChange={(data, dataString) => {
  2333. this.setState({ licenceDate: dataString });
  2334. }}
  2335. />
  2336. </FormItem>
  2337. <FormItem
  2338. className="half-item"
  2339. {...formItemLayout}
  2340. label="立项金额(万元)"
  2341. >
  2342. <Input
  2343. placeholder="请输入立项金额"
  2344. value={this.state.setUpAmount}
  2345. style={{ width: "200px" }}
  2346. onChange={e => {
  2347. this.setState({ setUpAmount: e.target.value });
  2348. }}
  2349. ref="commodityQuantity"
  2350. />
  2351. </FormItem>
  2352. <FormItem
  2353. className="half-item"
  2354. {...formItemLayout}
  2355. label="是否到款"
  2356. >
  2357. <Radio.Group
  2358. value={this.state.arrivalMoney}
  2359. onChange={e => {
  2360. this.setState({ arrivalMoney: e.target.value });
  2361. }}
  2362. >
  2363. <Radio value={0}>未到企业</Radio>
  2364. <Radio value={1}>已到企业</Radio>
  2365. </Radio.Group>
  2366. </FormItem>
  2367. </div>
  2368. <div className="clearfix">
  2369. <FormItem
  2370. labelCol={{ span: 3 }}
  2371. wrapperCol={{ span: 16 }}
  2372. label="附件"
  2373. >
  2374. <Picture
  2375. fileList={e => {
  2376. this.setState({ attachmentUrl: e });
  2377. }}
  2378. pictureUrl={this.state.attachmentUrl}
  2379. visible={this.props.visible}
  2380. data={{
  2381. sign: "order_task_file",
  2382. url: "/api/admin/orderProject/uploadOrderTaskFile",
  2383. number: 8
  2384. }}
  2385. />
  2386. </FormItem>
  2387. </div>
  2388. <div className="clearfix">
  2389. <FormItem
  2390. labelCol={{ span: 3 }}
  2391. wrapperCol={{ span: 16 }}
  2392. label="备注"
  2393. >
  2394. <Input
  2395. type="textarea"
  2396. placeholder="请输入备注"
  2397. rows={4}
  2398. value={this.state.taskComment}
  2399. onChange={e => {
  2400. this.setState({ taskComment: e.target.value });
  2401. }}
  2402. />
  2403. </FormItem>
  2404. </div>
  2405. <div>
  2406. <h3 className="sub-title">项目业务</h3>
  2407. {this.state.processStatus == 0 ? (
  2408. <Button
  2409. type="primary"
  2410. onClick={this.addDetailed}
  2411. style={{
  2412. float: "right",
  2413. marginRight: "50px",
  2414. marginBottom: "15px"
  2415. }}
  2416. >
  2417. 添加项目明细
  2418. </Button>
  2419. ) : (
  2420. ""
  2421. )}
  2422. </div>
  2423. <div className="patent-table">
  2424. <Spin spinning={this.state.loading}>
  2425. <Table
  2426. columns={this.state.columnsX}
  2427. dataSource={this.state.dataSourceX}
  2428. pagination={this.state.paginations}
  2429. onRowClick={this.tableRowClickX}
  2430. bordered
  2431. size="small"
  2432. />
  2433. </Spin>
  2434. </div>
  2435. <div className="clearfix">
  2436. <Button
  2437. className="cancel"
  2438. type="primary"
  2439. onClick={this.tijiaoOk}
  2440. style={{ marginLeft: "200px", marginTop: "10px" }}
  2441. htmlType="submit"
  2442. >
  2443. 保存
  2444. </Button>
  2445. <Button
  2446. className="cancel"
  2447. type="ghost"
  2448. onClick={this.visitCancel}
  2449. style={{ marginLeft: "50px", marginTop: "10px" }}
  2450. >
  2451. 取消
  2452. </Button>
  2453. </div>
  2454. </div>
  2455. </Spin>
  2456. </Form>
  2457. </TabPane>
  2458. <TabPane tab="外包接单公司信息" key="2">
  2459. {/*<Button type="primary" onClick={this.addCompany} style={{float:'right',marginBottom:'10px'}}>+新增接单公司</Button>*/}
  2460. {
  2461. <div className="clearfix">
  2462. <h3 className="sub-title" style={{ marginBottom: "10px" }}>
  2463. 新增(编辑)接单公司
  2464. </h3>
  2465. <FormItem
  2466. className="three-item"
  2467. {...formItemLayout}
  2468. label={
  2469. <span>
  2470. <strong style={{ color: "#f00" }}>*</strong>公司名称
  2471. </span>
  2472. }
  2473. >
  2474. <Input
  2475. placeholder="请输入公司名称"
  2476. value={this.state.cName}
  2477. style={{ width: "200px" }}
  2478. onChange={e => {
  2479. this.setState({ cName: e.target.value });
  2480. }}
  2481. className="height-input"
  2482. />
  2483. </FormItem>
  2484. <FormItem
  2485. className="three-item"
  2486. {...formItemLayout}
  2487. label={
  2488. <span>
  2489. <strong style={{ color: "#f00" }}>*</strong>联系人
  2490. </span>
  2491. }
  2492. >
  2493. <Input
  2494. placeholder="请输入联系人名称"
  2495. value={this.state.companyContacts}
  2496. style={{ width: "200px" }}
  2497. onChange={e => {
  2498. this.setState({ companyContacts: e.target.value });
  2499. }}
  2500. className="height-input"
  2501. />
  2502. </FormItem>
  2503. <FormItem
  2504. className="three-item"
  2505. {...formItemLayout}
  2506. label={
  2507. <span>
  2508. <strong style={{ color: "#f00" }}>*</strong>联系人电话
  2509. </span>
  2510. }
  2511. >
  2512. <Input
  2513. placeholder="请输入联系人电话"
  2514. value={this.state.companyContactsMobile}
  2515. style={{ width: "200px" }}
  2516. onChange={e => {
  2517. this.setState({
  2518. companyContactsMobile: e.target.value
  2519. });
  2520. }}
  2521. className="height-input"
  2522. />
  2523. </FormItem>
  2524. <FormItem
  2525. className="three-item"
  2526. {...formItemLayout}
  2527. label="企业地址"
  2528. >
  2529. <Cascader
  2530. options={areaSelect()}
  2531. value={this.state.companyProvinceArr}
  2532. placeholder="选择城市"
  2533. style={{ width: "200px" }}
  2534. onChange={e => {
  2535. this.setState({ companyProvinceArr: e });
  2536. }}
  2537. />
  2538. </FormItem>
  2539. <FormItem className="three-item" {...formItemLayout} label="">
  2540. <Input
  2541. placeholder="请输入详细地址"
  2542. value={this.state.companyAddress}
  2543. style={{ width: "200px", marginLeft: "12em" }}
  2544. onChange={e => {
  2545. this.setState({ companyAddress: e.target.value });
  2546. }}
  2547. className="height-input"
  2548. />
  2549. </FormItem>
  2550. <FormItem
  2551. className="three-item"
  2552. {...formItemLayout}
  2553. label=""
  2554. ></FormItem>
  2555. <div className="clearfix">
  2556. <FormItem
  2557. labelCol={{ span: 3 }}
  2558. wrapperCol={{ span: 16 }}
  2559. label="备注"
  2560. >
  2561. <Input
  2562. type="textarea"
  2563. placeholder="请输入备注"
  2564. rows={4}
  2565. value={this.state.companyRemarks}
  2566. onChange={e => {
  2567. this.setState({ companyRemarks: e.target.value });
  2568. }}
  2569. />
  2570. </FormItem>
  2571. </div>
  2572. <Button
  2573. type="primary"
  2574. style={{
  2575. float: "right",
  2576. marginTop: "10px",
  2577. marginRight: "50px"
  2578. }}
  2579. onClick={() => {
  2580. this.saveCompany(this.state.companyId);
  2581. }}
  2582. >
  2583. 保存
  2584. </Button>
  2585. </div>
  2586. }
  2587. <p style={{ color: "red" }}>
  2588. 提示:查看备注请点击表格左侧加号按钮~
  2589. </p>
  2590. <div className="patent-table" style={{ marginTop: "10px" }}>
  2591. <Spin spinning={this.state.loading}>
  2592. <Table
  2593. columns={this.state.companyColumns}
  2594. dataSource={this.state.companys}
  2595. scroll={{ x: 300, y: 0 }}
  2596. bordered
  2597. size="small"
  2598. expandedRowRender={record => {
  2599. return <p>{record.remarks}</p>;
  2600. }}
  2601. pagination={false}
  2602. />
  2603. </Spin>
  2604. </div>
  2605. </TabPane>
  2606. </Tabs>
  2607. </Modal>
  2608. <Modal
  2609. maskClosable={false}
  2610. visible={this.state.lookVisible}
  2611. onOk={this.noCancel}
  2612. onCancel={this.noCancel}
  2613. width="500px"
  2614. title={"添加工时"}
  2615. footer=""
  2616. className="admin-desc-content"
  2617. >
  2618. <Form layout="horizontal" id="demand-form">
  2619. <Spin spinning={this.state.loading}>
  2620. <div className="clearfix">
  2621. <FormItem {...formItemLayout} label="工作日期">
  2622. <DatePicker
  2623. style={{ marginTop: "2px", width: "200px", height: "32px" }}
  2624. showTime
  2625. format="YYYY-MM-DD"
  2626. onOk={() => {}}
  2627. value={
  2628. this.state.taskDate ? moment(this.state.taskDate) : null
  2629. }
  2630. onChange={(data, dataString) => {
  2631. this.setState({ taskDate: dataString });
  2632. }}
  2633. />
  2634. </FormItem>
  2635. </div>
  2636. <div className="clearfix">
  2637. <FormItem {...formItemLayout} label="工作时长">
  2638. <Input
  2639. placeholder="请输入工作时长"
  2640. value={this.state.hours}
  2641. style={{ width: "200px" }}
  2642. onChange={e => {
  2643. this.setState({ hours: e.target.value });
  2644. }}
  2645. ref="commodityQuantity"
  2646. />
  2647. </FormItem>
  2648. </div>
  2649. <div className="clearfix">
  2650. <FormItem {...formItemLayout} label="工作内容">
  2651. <Input
  2652. type="textarea"
  2653. placeholder="请输入备注"
  2654. rows={4}
  2655. value={this.state.remarks}
  2656. onChange={e => {
  2657. this.setState({ remarks: e.target.value });
  2658. }}
  2659. />
  2660. </FormItem>
  2661. </div>
  2662. <div className="clearfix">
  2663. <Button
  2664. className="cancel"
  2665. type="primary"
  2666. onClick={this.tianjiaOk}
  2667. style={{ marginLeft: "100px", marginTop: "10px" }}
  2668. htmlType="submit"
  2669. >
  2670. 确定
  2671. </Button>
  2672. <Button
  2673. className="cancel"
  2674. type="ghost"
  2675. onClick={this.noCancel}
  2676. style={{ marginLeft: "50px" }}
  2677. >
  2678. 取消
  2679. </Button>
  2680. </div>
  2681. </Spin>
  2682. </Form>
  2683. </Modal>
  2684. <Modal
  2685. maskClosable={false}
  2686. visible={this.state.addnextVisible}
  2687. onOk={this.nextCancel}
  2688. onCancel={this.nextCancel}
  2689. width="800px"
  2690. title="项目项目详情"
  2691. footer=""
  2692. className="admin-desc-content"
  2693. >
  2694. <Form layout="horizontal" onSubmit={this.nextSubmit} id="demand-form">
  2695. <Spin spinning={this.state.loading}>
  2696. <div className="clearfix">
  2697. <FormItem
  2698. className="half-item"
  2699. {...formItemLayout}
  2700. label="项目名称"
  2701. >
  2702. <span>{this.state.commodityName}</span>
  2703. </FormItem>
  2704. <FormItem
  2705. className="half-item"
  2706. {...formItemLayout}
  2707. label="项目数量"
  2708. >
  2709. <span>{this.state.commodityQuantity}</span>
  2710. </FormItem>
  2711. <FormItem
  2712. className="half-item"
  2713. {...formItemLayout}
  2714. label="金额(万元)"
  2715. >
  2716. <span>{this.state.commodityPrice}</span>
  2717. </FormItem>
  2718. <FormItem
  2719. className="half-item"
  2720. {...formItemLayout}
  2721. label="主要项目"
  2722. >
  2723. <span>{getboutique(this.state.main)}</span>
  2724. </FormItem>
  2725. <div className="clearfix">
  2726. <FormItem
  2727. labelCol={{ span: 3 }}
  2728. wrapperCol={{ span: 18 }}
  2729. label="服务说明"
  2730. >
  2731. <span>{this.state.taskComment}</span>
  2732. </FormItem>
  2733. </div>
  2734. </div>
  2735. </Spin>
  2736. </Form>
  2737. </Modal>
  2738. <Modal
  2739. maskClosable={false}
  2740. visible={this.state.speVisible}
  2741. onOk={this.visitOk}
  2742. onCancel={this.visitCancel}
  2743. width="900px"
  2744. title=""
  2745. footer=""
  2746. className="admin-desc-content"
  2747. >
  2748. <Tabs
  2749. activeKey={this.state.modKey}
  2750. onChange={this.callBack}
  2751. type="card"
  2752. >
  2753. <TabPane tab="项目概况" key="1">
  2754. <div className="clearfix">
  2755. <FormItem
  2756. className="half-item"
  2757. {...formItemLayout}
  2758. label="当前项目情况"
  2759. >
  2760. <Radio.Group
  2761. value={this.state.status}
  2762. onChange={e => {
  2763. this.setState({ status: e.target.value });
  2764. }}
  2765. >
  2766. <Radio value={0}>开启</Radio>
  2767. <Radio value={1}>暂停</Radio>
  2768. </Radio.Group>
  2769. <Button
  2770. type="primary"
  2771. size="small"
  2772. style={{ marginTop: "5px", position: "absolute" }}
  2773. onClick={this.caozuorizhi}
  2774. >
  2775. 操作日志
  2776. </Button>
  2777. </FormItem>
  2778. <FormItem
  2779. className="half-item"
  2780. {...formItemLayout}
  2781. label="合同编号"
  2782. >
  2783. <span>{this.state.contractNo}</span>
  2784. </FormItem>
  2785. </div>
  2786. <div className="clearfix">
  2787. <FormItem
  2788. className="half-item"
  2789. {...formItemLayout}
  2790. label="项目状态"
  2791. >
  2792. <Select
  2793. placeholder="选择项目状态"
  2794. style={{ width: "200px" }}
  2795. value={this.state.projectStatus}
  2796. onChange={e => {
  2797. this.setState({ projectStatus: e });
  2798. }}
  2799. >
  2800. {projectStatus.map(function(item) {
  2801. return (
  2802. <Select.Option key={item.value}>
  2803. {item.key}
  2804. </Select.Option>
  2805. );
  2806. })}
  2807. </Select>
  2808. </FormItem>
  2809. <FormItem
  2810. className="half-item"
  2811. {...formItemLayout}
  2812. label="是否特批"
  2813. >
  2814. <span>{getApproval(this.state.approval)}</span>
  2815. </FormItem>
  2816. <FormItem
  2817. className="half-item"
  2818. {...formItemLayout}
  2819. label="结算状态"
  2820. >
  2821. <span>
  2822. {getLiquidationStatus(this.state.liquidationStatus)}
  2823. </span>
  2824. </FormItem>
  2825. <FormItem
  2826. className="half-item"
  2827. {...formItemLayout}
  2828. label="流程状态"
  2829. >
  2830. <span>{getProcessStatus(this.state.processStatus)}</span>
  2831. </FormItem>
  2832. <FormItem
  2833. className="half-item"
  2834. {...formItemLayout}
  2835. label="订单编号"
  2836. >
  2837. <span>{this.state.orderNo}</span>
  2838. </FormItem>
  2839. </div>
  2840. <div className="clearfix">
  2841. <FormItem
  2842. className="half-item"
  2843. {...formItemLayout}
  2844. label="满意度表格"
  2845. >
  2846. <Radio.Group
  2847. value={this.state.formRetrieve}
  2848. onChange={e => {
  2849. this.setState({ formRetrieve: e.target.value });
  2850. }}
  2851. >
  2852. <Radio value={0}>未收回</Radio>
  2853. <Radio value={1}>已收回</Radio>
  2854. <Radio value={2}>其他</Radio>
  2855. </Radio.Group>
  2856. </FormItem>
  2857. <FormItem
  2858. className="half-item"
  2859. {...formItemLayout}
  2860. label="退单"
  2861. >
  2862. <Radio.Group
  2863. value={this.state.taskRefund}
  2864. onChange={e => {
  2865. this.setState({ taskRefund: e.target.value });
  2866. }}
  2867. >
  2868. <Radio value={0}>已完成</Radio>
  2869. <Radio value={1}>未完成</Radio>
  2870. <Radio value={2}>其他</Radio>
  2871. </Radio.Group>
  2872. </FormItem>
  2873. </div>
  2874. <div className="clearfix">
  2875. {
  2876. <FormItem
  2877. className="half-item"
  2878. {...formItemLayout}
  2879. label="(满意度)备注"
  2880. >
  2881. <Input
  2882. type="textarea"
  2883. placeholder="请输入备注"
  2884. rows={2}
  2885. value={this.state.retrieveContent}
  2886. onChange={e => {
  2887. this.setState({ retrieveContent: e.target.value });
  2888. }}
  2889. />
  2890. </FormItem>
  2891. }
  2892. {
  2893. <FormItem
  2894. className="half-item"
  2895. {...formItemLayout}
  2896. label="(退单)备注"
  2897. >
  2898. <Input
  2899. type="textarea"
  2900. placeholder="请输入备注"
  2901. rows={2}
  2902. value={this.state.refundContent}
  2903. onChange={e => {
  2904. this.setState({ refundContent: e.target.value });
  2905. }}
  2906. />
  2907. </FormItem>
  2908. }
  2909. </div>
  2910. <div className="clearfix">
  2911. <h3 className="sub-title">订单负责人信息</h3>
  2912. <FormItem
  2913. className="half-item"
  2914. {...formItemLayout}
  2915. label="负责人"
  2916. >
  2917. <span>
  2918. {this.state.salesmanName + "(" + this.state.depName + ")"}
  2919. </span>
  2920. </FormItem>
  2921. <FormItem
  2922. className="half-item"
  2923. {...formItemLayout}
  2924. label="负责人电话"
  2925. >
  2926. <span>{this.state.salesmanMobile}</span>
  2927. </FormItem>
  2928. <FormItem
  2929. className="half-item"
  2930. {...formItemLayout}
  2931. label="财务负责人"
  2932. >
  2933. <span>{this.state.financeName}</span>
  2934. </FormItem>
  2935. <FormItem
  2936. className="half-item"
  2937. {...formItemLayout}
  2938. label="财务负责人电话"
  2939. >
  2940. <span>{this.state.financeMobile}</span>
  2941. </FormItem>
  2942. </div>
  2943. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2944. <div className="clearfix">
  2945. <h3 className="sub-title">联系信息</h3>
  2946. <FormItem
  2947. className="half-item"
  2948. {...formItemLayout}
  2949. label="客户名称"
  2950. >
  2951. <span>{this.state.userName}</span>
  2952. </FormItem>
  2953. <FormItem
  2954. className="half-item"
  2955. {...formItemLayout}
  2956. label="企业法人"
  2957. >
  2958. <Input
  2959. placeholder="请输入法人名称"
  2960. value={this.state.legalPerson}
  2961. style={{ width: "200px" }}
  2962. onChange={e => {
  2963. this.setState({ legalPerson: e.target.value });
  2964. }}
  2965. ref="commodityQuantity"
  2966. />
  2967. </FormItem>
  2968. <FormItem
  2969. className="half-item"
  2970. {...formItemLayout}
  2971. label="法人电话"
  2972. >
  2973. <Input
  2974. placeholder="请输入法人电话"
  2975. value={this.state.legalPersonTel}
  2976. style={{ width: "200px" }}
  2977. onChange={e => {
  2978. this.setState({ legalPersonTel: e.target.value });
  2979. }}
  2980. ref="commodityQuantity"
  2981. />
  2982. </FormItem>
  2983. <FormItem
  2984. className="half-item"
  2985. {...formItemLayout}
  2986. label="客户联系人"
  2987. >
  2988. <Input
  2989. placeholder="请输入联系人名称"
  2990. value={this.state.contacts}
  2991. style={{ width: "200px" }}
  2992. onChange={e => {
  2993. this.setState({ contacts: e.target.value });
  2994. }}
  2995. ref="commodityQuantity"
  2996. />
  2997. </FormItem>
  2998. <FormItem
  2999. className="half-item"
  3000. {...formItemLayout}
  3001. label="联系人电话"
  3002. >
  3003. <Input
  3004. placeholder="请输入联系人电话"
  3005. value={this.state.contactMobile}
  3006. style={{ width: "200px" }}
  3007. onChange={e => {
  3008. this.setState({ contactMobile: e.target.value });
  3009. }}
  3010. ref="commodityQuantity"
  3011. />
  3012. </FormItem>
  3013. <FormItem
  3014. className="half-item"
  3015. {...formItemLayout}
  3016. label="企业地址"
  3017. >
  3018. <Cascader
  3019. options={areaSelect()}
  3020. value={this.state.ProvinceCity}
  3021. placeholder="选择城市"
  3022. style={{ width: "200px" }}
  3023. onChange={e => {
  3024. this.setState({ ProvinceCity: e });
  3025. }}
  3026. />
  3027. </FormItem>
  3028. <FormItem
  3029. className="half-item"
  3030. {...formItemLayout}
  3031. label=""
  3032. ></FormItem>
  3033. <FormItem className="half-item" {...formItemLayout} label="">
  3034. <Input
  3035. placeholder="请输入详细地址"
  3036. value={this.state.postalAddress}
  3037. style={{ width: "200px", marginLeft: "12em" }}
  3038. onChange={e => {
  3039. this.setState({ postalAddress: e.target.value });
  3040. }}
  3041. ref="commodityQuantity"
  3042. />
  3043. </FormItem>
  3044. </div>
  3045. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  3046. <div className="clearfix">
  3047. <h3 className="sub-title">项目信息</h3>
  3048. <FormItem
  3049. className="half-item"
  3050. {...formItemLayout}
  3051. label="项目编号"
  3052. >
  3053. <span>{this.state.id}</span>
  3054. </FormItem>
  3055. <FormItem
  3056. className="half-item"
  3057. {...formItemLayout}
  3058. label="项目名称"
  3059. >
  3060. <span>{this.state.taskName}</span>
  3061. </FormItem>
  3062. <FormItem
  3063. className="half-item"
  3064. {...formItemLayout}
  3065. label="项目状态"
  3066. >
  3067. <Select
  3068. placeholder="选择项目状态"
  3069. style={{ width: "200px" }}
  3070. value={this.state.taskStatus}
  3071. onChange={e => {
  3072. this.setState({ taskStatus: e });
  3073. }}
  3074. >
  3075. {taskStatus.map(function(item) {
  3076. return (
  3077. <Select.Option key={item.value}>
  3078. {item.key}
  3079. </Select.Option>
  3080. );
  3081. })}
  3082. </Select>
  3083. </FormItem>
  3084. <FormItem
  3085. className="half-item"
  3086. {...formItemLayout}
  3087. label="项目类别"
  3088. >
  3089. <span>{this.state.cname}</span>
  3090. </FormItem>
  3091. <FormItem
  3092. className="half-item"
  3093. {...formItemLayout}
  3094. label="证书编号"
  3095. >
  3096. <Input
  3097. placeholder="请输入证书编号"
  3098. value={this.state.certificateNumber}
  3099. style={{ width: "200px" }}
  3100. onChange={e => {
  3101. this.setState({ certificateNumber: e.target.value });
  3102. }}
  3103. ref="commodityQuantity"
  3104. />
  3105. </FormItem>
  3106. </div>
  3107. <div className="clearfix" style={{ marginTop: "10px" }}>
  3108. <FormItem
  3109. labelCol={{ span: 3 }}
  3110. wrapperCol={{ span: 14 }}
  3111. label="附件"
  3112. >
  3113. <Picture
  3114. fileList={e => {
  3115. this.setState({ attachmentUrl: e });
  3116. }}
  3117. pictureUrl={this.state.attachmentUrl}
  3118. visible={this.props.visible}
  3119. data={{
  3120. sign: "order_task_file",
  3121. url: "/api/admin/orderProject/uploadOrderTaskFile",
  3122. number: 8
  3123. }}
  3124. />
  3125. </FormItem>
  3126. </div>
  3127. <div className="clearfix">
  3128. <FormItem
  3129. labelCol={{ span: 3 }}
  3130. wrapperCol={{ span: 16 }}
  3131. label="备注"
  3132. >
  3133. <Input
  3134. type="textarea"
  3135. placeholder="请输入备注"
  3136. rows={4}
  3137. value={this.state.taskComment}
  3138. onChange={e => {
  3139. this.setState({ taskComment: e.target.value });
  3140. }}
  3141. />
  3142. </FormItem>
  3143. </div>
  3144. <div className="clearfix">
  3145. <h3 className="sub-title">项目申报进度</h3>
  3146. <FormItem
  3147. className="half-item"
  3148. {...formItemLayout}
  3149. label="启动时间"
  3150. >
  3151. <DatePicker
  3152. style={{ marginTop: "5px" }}
  3153. showTime
  3154. format="YYYY-MM-DD"
  3155. onOk={() => {}}
  3156. value={
  3157. this.state.startDate ? moment(this.state.startDate) : null
  3158. }
  3159. onChange={(data, dataString) => {
  3160. this.setState({ startDate: dataString });
  3161. }}
  3162. />
  3163. </FormItem>
  3164. <FormItem
  3165. className="half-item"
  3166. {...formItemLayout}
  3167. label="软著派单数量"
  3168. >
  3169. <span>{this.state.commodityQuantity}</span>
  3170. <Button
  3171. type="primary"
  3172. size="small"
  3173. style={{ marginLeft: "45px" }}
  3174. onClick={this.addcontact}
  3175. >
  3176. +增加下证信息
  3177. </Button>
  3178. </FormItem>
  3179. <div className="patent-table">
  3180. <Spin spinning={this.state.loading}>
  3181. <Table
  3182. columns={this.state.ContactsLists}
  3183. dataSource={this.state.contactList}
  3184. pagination={false}
  3185. bordered
  3186. size="small"
  3187. />
  3188. </Spin>
  3189. </div>
  3190. </div>
  3191. <div className="clearfix">
  3192. <h3 className="sub-title">项目业务</h3>
  3193. <div className="patent-table">
  3194. <Spin spinning={this.state.loading}>
  3195. <Table
  3196. columns={this.state.columnsX}
  3197. dataSource={this.state.dataSourceX}
  3198. pagination={this.state.paginations}
  3199. onRowClick={this.tableRowClickX}
  3200. bordered
  3201. size="small"
  3202. />
  3203. </Spin>
  3204. </div>
  3205. </div>
  3206. <div className="clearfix">
  3207. <Button
  3208. className="cancel"
  3209. type="primary"
  3210. onClick={this.tijiaoOk}
  3211. style={{ marginLeft: "200px", marginTop: "10px" }}
  3212. htmlType="submit"
  3213. >
  3214. 保存
  3215. </Button>
  3216. <Button
  3217. className="cancel"
  3218. type="ghost"
  3219. onClick={this.visitCancel}
  3220. style={{ marginLeft: "50px", marginTop: "10px" }}
  3221. >
  3222. 取消
  3223. </Button>
  3224. </div>
  3225. </TabPane>
  3226. <TabPane tab="外包接单公司信息" key="2">
  3227. {/*<Button type="primary" onClick={this.addCompany} style={{float:'right',marginBottom:'10px'}}>+新增接单公司</Button>*/}
  3228. {
  3229. <div className="clearfix">
  3230. <h3 className="sub-title" style={{ marginBottom: "10px" }}>
  3231. 新增(编辑)接单公司
  3232. </h3>
  3233. <FormItem
  3234. className="three-item"
  3235. {...formItemLayout}
  3236. label={
  3237. <span>
  3238. <strong style={{ color: "#f00" }}>*</strong>公司名称
  3239. </span>
  3240. }
  3241. >
  3242. <Input
  3243. placeholder="请输入公司名称"
  3244. value={this.state.cName}
  3245. style={{ width: "200px" }}
  3246. onChange={e => {
  3247. this.setState({ cName: e.target.value });
  3248. }}
  3249. className="height-input"
  3250. />
  3251. </FormItem>
  3252. <FormItem
  3253. className="three-item"
  3254. {...formItemLayout}
  3255. label={
  3256. <span>
  3257. <strong style={{ color: "#f00" }}>*</strong>联系人
  3258. </span>
  3259. }
  3260. >
  3261. <Input
  3262. placeholder="请输入联系人名称"
  3263. value={this.state.companyContacts}
  3264. style={{ width: "200px" }}
  3265. onChange={e => {
  3266. this.setState({ companyContacts: e.target.value });
  3267. }}
  3268. className="height-input"
  3269. />
  3270. </FormItem>
  3271. <FormItem
  3272. className="three-item"
  3273. {...formItemLayout}
  3274. label={
  3275. <span>
  3276. <strong style={{ color: "#f00" }}>*</strong>联系人电话
  3277. </span>
  3278. }
  3279. >
  3280. <Input
  3281. placeholder="请输入联系人电话"
  3282. value={this.state.companyContactsMobile}
  3283. style={{ width: "200px" }}
  3284. onChange={e => {
  3285. this.setState({
  3286. companyContactsMobile: e.target.value
  3287. });
  3288. }}
  3289. className="height-input"
  3290. />
  3291. </FormItem>
  3292. <FormItem
  3293. className="three-item"
  3294. {...formItemLayout}
  3295. label="企业地址"
  3296. >
  3297. <Cascader
  3298. options={areaSelect()}
  3299. value={this.state.companyProvinceArr}
  3300. placeholder="选择城市"
  3301. style={{ width: "200px" }}
  3302. onChange={e => {
  3303. this.setState({ companyProvinceArr: e });
  3304. }}
  3305. />
  3306. </FormItem>
  3307. <FormItem className="three-item" {...formItemLayout} label="">
  3308. <Input
  3309. placeholder="请输入详细地址"
  3310. value={this.state.companyAddress}
  3311. style={{ width: "200px", marginLeft: "12em" }}
  3312. onChange={e => {
  3313. this.setState({ companyAddress: e.target.value });
  3314. }}
  3315. className="height-input"
  3316. />
  3317. </FormItem>
  3318. <FormItem
  3319. className="three-item"
  3320. {...formItemLayout}
  3321. label=""
  3322. ></FormItem>
  3323. <div className="clearfix">
  3324. <FormItem
  3325. labelCol={{ span: 3 }}
  3326. wrapperCol={{ span: 16 }}
  3327. label="备注"
  3328. >
  3329. <Input
  3330. type="textarea"
  3331. placeholder="请输入备注"
  3332. rows={4}
  3333. value={this.state.companyRemarks}
  3334. onChange={e => {
  3335. this.setState({ companyRemarks: e.target.value });
  3336. }}
  3337. />
  3338. </FormItem>
  3339. </div>
  3340. <Button
  3341. type="primary"
  3342. style={{
  3343. float: "right",
  3344. marginTop: "10px",
  3345. marginRight: "50px"
  3346. }}
  3347. onClick={() => {
  3348. this.saveCompany(this.state.companyId);
  3349. }}
  3350. >
  3351. 保存
  3352. </Button>
  3353. </div>
  3354. }
  3355. <p style={{ color: "red" }}>
  3356. 提示:查看备注请点击表格左侧加号按钮~
  3357. </p>
  3358. <div className="patent-table" style={{ marginTop: "10px" }}>
  3359. <Spin spinning={this.state.loading}>
  3360. <Table
  3361. columns={this.state.companyColumns}
  3362. dataSource={this.state.companys}
  3363. scroll={{ x: 300, y: 0 }}
  3364. expandedRowRender={record => {
  3365. return <p>{record.remarks}</p>;
  3366. }}
  3367. bordered
  3368. size="small"
  3369. pagination={false}
  3370. />
  3371. </Spin>
  3372. </div>
  3373. </TabPane>
  3374. </Tabs>
  3375. </Modal>
  3376. {/* <Modal
  3377. width="800px"
  3378. visible={this.state.visibleA}
  3379. onCancel={this.visitCancelA}
  3380. title="操作日志"
  3381. footer=""
  3382. className="admin-desc-content"
  3383. >
  3384. <div className="patent-table patent-table-center">
  3385. <Spin spinning={this.state.loading}>
  3386. <Table
  3387. columns={this.state.columnsA}
  3388. dataSource={this.state.dataSourceA}
  3389. pagination={false}
  3390. />
  3391. </Spin>
  3392. </div>
  3393. </Modal> */}
  3394. <OrderRiZi
  3395. dataSourcerizhi={this.state.dataSourceA}
  3396. closeOrderLog={this.visitCancelA}
  3397. visible={this.state.visibleA}
  3398. loading={this.state.loading}
  3399. />
  3400. <Modal
  3401. title="工时记录"
  3402. visible={this.state.timeVisible}
  3403. onCancel={this.timeClose}
  3404. width={800}
  3405. footer={null}
  3406. >
  3407. <Spin spinning={this.state.loading}>
  3408. <Table
  3409. columns={this.state.columnsTime}
  3410. dataSource={this.state.dataSourceTime}
  3411. pagination={false}
  3412. scroll={{ x: "max-content", y: 0 }}
  3413. bordered
  3414. size={"small"}
  3415. />
  3416. <p style={{ marginTop: 10, color: "red" }}>
  3417. 累计工时(小时):{this.state.recordHour}
  3418. </p>
  3419. </Spin>
  3420. </Modal>
  3421. </div>
  3422. );
  3423. }
  3424. });
  3425. export default MyTaskOutsource;