myTask.jsx 91 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805
  1. import React from "react";
  2. import $ from "jquery";
  3. import moment from "moment";
  4. import Picture from "@/manageCenter/publicComponent/picture";
  5. import "@/manageCenter/financialManage/distribute/public.less";
  6. import "@/manageCenter/financialManage/distribute/shouKuan.less";
  7. import {
  8. Button,
  9. Form,
  10. Input,
  11. Select,
  12. Spin,
  13. Table,
  14. message,
  15. DatePicker,
  16. Modal,
  17. Radio,
  18. Cascader,
  19. Popconfirm,
  20. Switch,
  21. Tabs,
  22. } from "antd";
  23. import Assign from "@/manageCenter/publicComponent/assign";
  24. import { areaSelect } from "@/NewDicProvinceList";
  25. import { ChooseList } from "../../order/orderNew/chooseList";
  26. import "./table.less";
  27. import {
  28. getProcessStatus,
  29. getApproval,
  30. getTaskStatus,
  31. getLiquidationStatus,
  32. getProjectStatus,
  33. splitUrl,
  34. getboutique,
  35. ShowModal
  36. } from "@/tools";
  37. import { taskStatus, projectStatus } from "@/dataDic.js";
  38. import ShowModalDiv from "@/showModal.jsx";
  39. const FormItem = Form.Item;
  40. const { TabPane } = Tabs;
  41. const { MonthPicker, RangePicker } = DatePicker;
  42. const Task = React.createClass({
  43. loadData(pageNo) {
  44. this.state.data = [];
  45. this.setState({
  46. page: pageNo,
  47. loading: true
  48. });
  49. $.ajax({
  50. method: "get",
  51. dataType: "json",
  52. crossDomain: false,
  53. url: globalConfig.context + "/api/admin/orderProject/orderTaskList",
  54. data: {
  55. pageNo: pageNo || 1,
  56. pageSize: this.state.pagination.pageSize,
  57. specially: 0, //个人
  58. name: this.state.nameSearch, //客户名称
  59. depId: this.state.departmenttSearch, //订单部门
  60. orderNo: this.state.orderNoSearch, //订单编号
  61. contractNo: this.state.contractNoSearch, //合同编号
  62. taskId: this.state.taskNoSearch, //项目编号
  63. taskStatus: this.state.taskStatuSearch, //项目状态
  64. projectStatus: this.state.projectStatusSearch, //项目状态
  65. adminName: this.state.adminName //项目受理人
  66. },
  67. success: function(data) {
  68. ShowModal(this);
  69. let theArr = [];
  70. if (!data.data || !data.data.list) {
  71. if (data.error && data.error.length) {
  72. message.warning(data.error[0].message);
  73. }
  74. } else {
  75. for (let i = 0; i < data.data.list.length; i++) {
  76. let thisdata = data.data.list[i];
  77. theArr.push({
  78. key: i,
  79. orderNo: thisdata.orderNo, //订单编号
  80. id: thisdata.id, //项目ID
  81. taskName: thisdata.taskName, //名称
  82. cname: thisdata.cname, //项目品类
  83. receiverName: thisdata.receiverName, //受理人
  84. projectStatus: thisdata.projectStatus, //项目状态
  85. taskStatus: thisdata.taskStatus, //项目状态
  86. taskDate: thisdata.taskDate, //分配时间
  87. userName:
  88. thisdata.taskName.substring(0, 5) === "软件著作权"
  89. ? thisdata.userName +
  90. "(" +
  91. thisdata.commodityQuantity.toString() +
  92. "/" +
  93. thisdata.alreadyNumber +
  94. ")"
  95. : thisdata.userName, //用户名
  96. depName: thisdata.depName, //部门名称
  97. commodityQuantity: thisdata.commodityQuantity, //项目数量
  98. hours: thisdata.hours,
  99. contractNo: thisdata.contractNo
  100. });
  101. }
  102. }
  103. this.state.pagination.current = data.data.pageNo;
  104. this.state.pagination.total = data.data.totalCount;
  105. if (data.data && data.data.list && !data.data.list.length) {
  106. this.state.pagination.current = 0;
  107. this.state.pagination.total = 0;
  108. }
  109. this.setState({
  110. dataSource: theArr,
  111. pagination: this.state.pagination
  112. });
  113. }.bind(this)
  114. }).always(
  115. function() {
  116. this.setState({
  117. loading: false
  118. });
  119. }.bind(this)
  120. );
  121. },
  122. getInitialState() {
  123. return {
  124. timeVisible: false,
  125. searchMore: true,
  126. assignVisible: false,
  127. releaseDate: [],
  128. // 判断是否是退回给咨询师经理
  129. flag: false,
  130. roleName: "",
  131. testFlag: true,
  132. boHuivisible: false,
  133. selectedRowKeys: [],
  134. departmentArr: [],
  135. selectedRows: [],
  136. attachmentUrl: [],
  137. contactList: [],
  138. paginations: false,
  139. loading: false,
  140. pagination: {
  141. defaultCurrent: 1,
  142. defaultPageSize: 10,
  143. showQuickJumper: true,
  144. pageSize: 10,
  145. onChange: function(page) {
  146. this.loadData(page);
  147. }.bind(this),
  148. showTotal: function(total) {
  149. return "共" + total + "条数据";
  150. }
  151. },
  152. // 子组件改变的表格title数组
  153. changeList: undefined,
  154. columnsTime: [
  155. {
  156. title: "工作时长(小时)",
  157. dataIndex: "hours",
  158. key: "hours"
  159. },
  160. {
  161. title: "工作时间",
  162. dataIndex: "taskDays",
  163. key: "taskDays"
  164. },
  165. // {
  166. // title: "项目负责人",
  167. // dataIndex: "remarks",
  168. // key: "remarks"
  169. // },
  170. {
  171. title: "备注",
  172. dataIndex: "remarks",
  173. key: "remarks"
  174. }
  175. ],
  176. columns: [
  177. {
  178. title: "项目编号",
  179. dataIndex: "id",
  180. key: "id"
  181. },
  182. {
  183. title: "项目名称",
  184. dataIndex: "taskName",
  185. key: "taskName",
  186. render: text => {
  187. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  188. }
  189. },
  190. {
  191. title: "订单编号",
  192. dataIndex: "orderNo",
  193. key: "orderNo"
  194. },
  195. {
  196. title: "合同编号",
  197. dataIndex: "contractNo",
  198. key: "contractNo"
  199. },
  200. {
  201. title: "业务类别",
  202. dataIndex: "cname",
  203. key: "cname"
  204. },
  205. {
  206. title: "客户名称",
  207. dataIndex: "userName",
  208. key: "userName",
  209. className: "userName"
  210. },
  211. {
  212. title: "分配状态",
  213. dataIndex: "taskStatus",
  214. key: "taskStatus",
  215. render: text => {
  216. return getTaskStatus(text);
  217. }
  218. },
  219. {
  220. title: "项目状态",
  221. dataIndex: "projectStatus",
  222. key: "projectStatus",
  223. render: text => {
  224. return getProjectStatus(text);
  225. }
  226. },
  227. {
  228. title: "分配时间",
  229. dataIndex: "taskDate",
  230. key: "taskDate"
  231. },
  232. {
  233. title: "订单部门",
  234. dataIndex: "depName",
  235. key: "depName"
  236. },
  237. {
  238. title: "累计工时(小时)",
  239. dataIndex: "hours",
  240. key: "hours"
  241. },
  242. {
  243. title: "操作",
  244. dataIndex: "caozuo",
  245. key: "caozuo",
  246. render: (text, record) => {
  247. return (
  248. <div>
  249. <Button
  250. type="primary"
  251. onClick={e => {
  252. e.stopPropagation(), this.evaluate(record, "咨询师");
  253. }}
  254. >
  255. 转交
  256. </Button>
  257. <Button
  258. type="primary"
  259. style={{ marginLeft: 10 }}
  260. onClick={e => {
  261. e.stopPropagation(),
  262. this.evaluate(record, "咨询师经理", true);
  263. }}
  264. >
  265. 回退
  266. </Button>
  267. <Button
  268. type="primary"
  269. style={{ margin: "0 10px" }}
  270. onClick={e => {
  271. e.stopPropagation(), this.okCancel(record);
  272. }}
  273. >
  274. 添加工时
  275. </Button>
  276. <Button
  277. type="primary"
  278. onClick={e => {
  279. e.stopPropagation();
  280. this.setState({
  281. timeVisible: true
  282. });
  283. this.timeDetail(record);
  284. }}
  285. >
  286. 工时记录
  287. </Button>
  288. </div>
  289. );
  290. }
  291. }
  292. ],
  293. dataSource: [],
  294. searchTime: [],
  295. columnsX: [
  296. {
  297. title: "业务项目名称",
  298. dataIndex: "commodityName",
  299. key: "commodityName"
  300. },
  301. {
  302. title: "项目类别",
  303. dataIndex: "cname",
  304. key: "cname"
  305. },
  306. {
  307. title: "项目数量",
  308. dataIndex: "commodityQuantity",
  309. key: "commodityQuantity"
  310. },
  311. {
  312. title: "金额(万元)",
  313. dataIndex: "commodityPrice",
  314. key: "commodityPrice"
  315. },
  316. {
  317. title: "负责人",
  318. dataIndex: "contacts",
  319. key: "contacts"
  320. },
  321. {
  322. title: "负责人电话",
  323. dataIndex: "contactsMobile",
  324. key: "contactsMobile"
  325. },
  326. {
  327. title: "主要项目",
  328. dataIndex: "main",
  329. key: "main",
  330. render: text => {
  331. return text ? "是" : "否";
  332. }
  333. },
  334. {
  335. title: "项目说明",
  336. dataIndex: "taskComment",
  337. key: "taskComment",
  338. render: text => {
  339. return text && text.length > 8 ? text.substr(0, 8) + "…" : text;
  340. }
  341. }
  342. ],
  343. columnsA: [
  344. {
  345. title: "流程",
  346. dataIndex: "content",
  347. key: "content",
  348. align: "center"
  349. },
  350. {
  351. title: "操作人",
  352. dataIndex: "aName",
  353. key: "aName",
  354. align: "center"
  355. },
  356. {
  357. title: "时间",
  358. dataIndex: "createTimes",
  359. key: "createTimes",
  360. align: "center"
  361. }
  362. ],
  363. dataSourceX: [],
  364. dataSourceA: [],
  365. ContactsLists: [
  366. {
  367. title: "批次",
  368. dataIndex: "num",
  369. key: "num"
  370. },
  371. {
  372. title: "下证时间",
  373. dataIndex: "licenceTimes",
  374. key: "licenceTimes",
  375. render: (text, record) => {
  376. return (
  377. <div>
  378. <DatePicker
  379. style={{ marginTop: "5px" }}
  380. showTime
  381. format="YYYY-MM-DD"
  382. onOk={() => {}}
  383. value={
  384. record.licenceTimes ? moment(record.licenceTimes) : null
  385. }
  386. onChange={(data, dataString) => {
  387. record.licenceTimes = dataString;
  388. this.setState({ contactList: this.state.contactList });
  389. }}
  390. />
  391. </div>
  392. );
  393. }
  394. },
  395. {
  396. title: "下证数量",
  397. dataIndex: "alreadyNumber",
  398. key: "alreadyNumber",
  399. render: (text, record) => {
  400. return (
  401. <div>
  402. {
  403. <Input
  404. value={record.alreadyNumber}
  405. placeholder="请输入下证数量"
  406. key={record.id}
  407. required="required"
  408. onChange={e => {
  409. record.alreadyNumber = e.target.value;
  410. this.setState({ contactList: this.state.contactList });
  411. }}
  412. style={{ width: "120px" }}
  413. />
  414. }
  415. </div>
  416. );
  417. }
  418. },
  419. {
  420. title: "未下证数量",
  421. dataIndex: "notCount",
  422. key: "notCount"
  423. },
  424. {
  425. title: "操作",
  426. dataIndex: "dels",
  427. key: "dels",
  428. render: (text, record, index) => {
  429. return (
  430. <div>
  431. {
  432. <Popconfirm
  433. title="是否删除?"
  434. onConfirm={() => {
  435. this.confirmDelet(record);
  436. }}
  437. okText="删除"
  438. cancelText="不删除"
  439. >
  440. <Button
  441. style={{
  442. marginRight: "10px",
  443. color: "#ffffff",
  444. background: "#f00",
  445. border: "none"
  446. }}
  447. >
  448. 删除
  449. </Button>
  450. </Popconfirm>
  451. }
  452. {record.flag ? (
  453. ""
  454. ) : (
  455. <Button
  456. type="primary"
  457. onClick={e => {
  458. e.stopPropagation(), this.contactSave(record, index);
  459. }}
  460. >
  461. 保存
  462. </Button>
  463. )}
  464. </div>
  465. );
  466. }
  467. }
  468. ]
  469. };
  470. },
  471. /* 分派 */
  472. evaluate(record, nub, flag) {
  473. this.setState(
  474. {
  475. nub: nub,
  476. assignData: record,
  477. flag
  478. },
  479. () => {
  480. this.setState({
  481. assignVisible: true
  482. });
  483. }
  484. );
  485. },
  486. componentWillMount() {
  487. this.departmentList();
  488. this.loadData();
  489. },
  490. componentDidMount() {
  491. this.setColor();
  492. },
  493. setColor() {
  494. $(".userName span").after(
  495. "(<span class='ruanzhu'>软著数</span>/<span class='xiazheng'>下证数</span>)"
  496. );
  497. },
  498. tableRowClick(record) {
  499. this.state.RowData = record;
  500. if (record.taskName.substring(0, 5) === "软件著作权") {
  501. this.setState({
  502. speVisible: true,
  503. id: record.id,
  504. dataArr: record,
  505. commodityQuantity: record.commodityQuantity
  506. });
  507. } else {
  508. this.setState({
  509. visible: true
  510. });
  511. }
  512. this.xiangqing(record.id, record.taskName);
  513. this.xiangqings(record.orderNo);
  514. this.xiangmu(record.orderNo);
  515. this.loaduserss(record);
  516. },
  517. //点击修改项目详情
  518. tijiaoOk() {
  519. let attachmentUrls = [];
  520. if (this.state.attachmentUrl.length) {
  521. let picArr = [];
  522. this.state.attachmentUrl.map(function(item) {
  523. if (item.response && item.response.data && item.response.data.length) {
  524. picArr.push(item.response.data);
  525. }
  526. });
  527. attachmentUrls = picArr.join(",");
  528. }
  529. $.ajax({
  530. method: "POST",
  531. dataType: "json",
  532. crossDomain: false,
  533. url: globalConfig.context + "/api/admin/orderProject/updateOrderTask",
  534. data: {
  535. id: this.state.id, //项目编号
  536. orderNo: this.state.orderNo, //订单编号
  537. projectStatus: this.state.projectStatus, //项目状态
  538. taskStatus: this.state.taskStatus, //项目状态
  539. taskComment: this.state.taskComment, //说明
  540. startDate: this.state.startDate, //启动日期
  541. endDate: this.state.endDate, //结束日期
  542. acceptDate: this.state.acceptDate, //受理日期
  543. reviewDate: this.state.reviewDate, //评审日期
  544. publicityDate: this.state.publicityDate, //公示日期
  545. licenceDate: this.state.licenceDate, //发证日期
  546. attachmentUrl: attachmentUrls.length ? attachmentUrls : "", //附件
  547. contacts: this.state.contacts, //联系人
  548. contactMobile: this.state.contactMobile, //联系人电话
  549. legalPerson: this.state.legalPerson, //法人
  550. legalPersonTel: this.state.legalPersonTel, //法人电话
  551. certificateNumber: this.state.certificateNumber, //证书编号
  552. status: this.state.status, //状态
  553. formRetrieve: this.state.formRetrieve, //满意度表格
  554. taskRefund: this.state.taskRefund, //退单
  555. refundContent: this.state.refundContent, //退单信息
  556. retrieveContent: this.state.retrieveContent, //回收信息
  557. locationProvince: this.state.ProvinceCity[0],
  558. locationCity: this.state.ProvinceCity[1],
  559. locationArea: this.state.ProvinceCity[2],
  560. postalAddress: this.state.postalAddress, //详细地址
  561. arrivalMoney: this.state.arrivalMoney, //是否到款
  562. setUpAmount: this.state.setUpAmount, //立项金额
  563. declareUser: this.state.declareUser, //账号
  564. declarePwd: this.state.declarePwd, //密码
  565. outsourceName: this.state.outsourceName, //外包公司
  566. outsourcePrice: this.state.outsourcePrice //外包价格
  567. }
  568. }).done(
  569. function(data) {
  570. this.setState({
  571. loading: false
  572. });
  573. if (!data.error.length) {
  574. message.success("保存成功!");
  575. this.visitCancel();
  576. } else {
  577. message.warning(data.error[0].message);
  578. }
  579. }.bind(this)
  580. );
  581. },
  582. //点击修改项目详情
  583. tianjiaOk() {
  584. if (this.state.attachmentUrl.length) {
  585. let picArr = [];
  586. this.state.attachmentUrl.map(function(item) {
  587. if (item.response && item.response.data && item.response.data.length) {
  588. picArr.push(item.response.data);
  589. }
  590. });
  591. }
  592. $.ajax({
  593. method: "POST",
  594. dataType: "json",
  595. crossDomain: false,
  596. url: globalConfig.context + "/api/admin/orderProject/addTaskHours",
  597. data: {
  598. taskId: this.state.taskId, //项目编号
  599. hours: this.state.hours, //工时
  600. remarks: this.state.remarks, //说明
  601. taskDate: this.state.taskDate, //日期
  602. taskComment: this.state.taskComment //说明
  603. }
  604. }).done(
  605. function(data) {
  606. this.setState({
  607. loading: false
  608. });
  609. if (!data.error.length) {
  610. message.success("保存成功!");
  611. this.noCancel();
  612. } else {
  613. message.warning(data.error[0].message);
  614. }
  615. }.bind(this)
  616. );
  617. },
  618. //订单详情
  619. xiangqing(id) {
  620. $.ajax({
  621. method: "get",
  622. dataType: "json",
  623. crossDomain: false,
  624. url: globalConfig.context + "/api/admin/orderProject/orderTaskDetail",
  625. data: {
  626. id: id
  627. },
  628. success: function(data) {
  629. let thisdata = data.data;
  630. if (data.error.length || data.data.list == "") {
  631. if (data.error && data.error.length) {
  632. message.warning(data.error[0].message);
  633. }
  634. } else {
  635. this.setState({
  636. id: thisdata.id, //ID
  637. orderNo: thisdata.orderNo, //订单编号
  638. userName: thisdata.userName, //客户名称
  639. taskName: thisdata.taskName, //项目名称
  640. cname: thisdata.cname, //项目品类
  641. contractNo: thisdata.contractNo, //合同编号
  642. projectStatus: thisdata.projectStatus.toString(), //项目状态
  643. taskStatus: thisdata.taskStatus.toString(), //项目状态
  644. taskDate: thisdata.taskDate, //分配时间
  645. taskComment: thisdata.taskComment, //说明
  646. attachmentUrl: thisdata.attachmentUrl
  647. ? splitUrl(
  648. thisdata.attachmentUrl,
  649. ",",
  650. globalConfig.avatarHost + "/upload"
  651. )
  652. : [], //图片地址
  653. salesmanName: thisdata.salesmanName, //订单负责人
  654. startDate: thisdata.startDate, //启动日期
  655. endDate: thisdata.endDate, //结束日期
  656. acceptDate: thisdata.acceptDate, //受理日期
  657. reviewDate: thisdata.reviewDate, //评审日期
  658. publicityDate: thisdata.publicityDate, //公示日期
  659. licenceDate: thisdata.licenceDate, //发证日期
  660. contacts: thisdata.contacts, //联系人
  661. contactMobile: thisdata.contactMobile, //联系人电话
  662. legalPerson: thisdata.legalPerson, //法人
  663. legalPersonTel: thisdata.legalPersonTel, //法人电话
  664. certificateNumber: thisdata.certificateNumber, //证书编号
  665. status: thisdata.status, //状态
  666. formRetrieve: thisdata.formRetrieve, //满意度表格
  667. taskRefund: thisdata.taskRefund, //退单
  668. refundContent: thisdata.refundContent, //退单信息
  669. retrieveContent: thisdata.retrieveContent, //回收信息
  670. arrivalMoney: thisdata.arrivalMoney, //是否到款
  671. setUpAmount: thisdata.setUpAmount, //立项金额
  672. declareUser: thisdata.declareUser, //账号
  673. declarePwd: thisdata.declarePwd, //密码
  674. outsourceName: thisdata.outsourceName, //外包公司
  675. outsourcePrice: thisdata.outsourcePrice //外包价格
  676. });
  677. }
  678. }.bind(this)
  679. }).always(
  680. function() {
  681. this.setState({
  682. loading: false
  683. });
  684. }.bind(this)
  685. );
  686. },
  687. //订单详情
  688. xiangqings(orderNos) {
  689. $.ajax({
  690. method: "get",
  691. dataType: "json",
  692. crossDomain: false,
  693. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  694. data: {
  695. orderNo: orderNos
  696. },
  697. success: function(data) {
  698. let thisdata = data.data;
  699. let ProvinceCityArr = [];
  700. let ProvinceS = thisdata.locationProvince; //省
  701. let citys = thisdata.locationCity; //市
  702. let Areas = thisdata.locationArea; //区
  703. ProvinceCityArr.push(ProvinceS, citys, Areas);
  704. if (data.error.length || data.data.list == "") {
  705. if (data.error && data.error.length) {
  706. message.warning(data.error[0].message);
  707. }
  708. } else {
  709. this.setState({
  710. processStatus: thisdata.processStatus, //流程状态
  711. liquidationStatus: thisdata.liquidationStatus, //结算状态
  712. approval: thisdata.approval, //特批状态
  713. orderRemarks: thisdata.orderRemarks, //订单留言
  714. salesmanName: thisdata.salesmanName, //营销员名称
  715. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  716. financeName: thisdata.financeName, //财务名称
  717. financeMobile: thisdata.financeMobile, //财务电话
  718. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  719. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  720. nowFinance: thisdata.nowFinance, //财务名称
  721. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  722. depName: thisdata.depName, //订单部门
  723. ProvinceCity: ProvinceCityArr[0] === null ? [] : ProvinceCityArr,
  724. postalAddress: thisdata.postalAddress //详细地址
  725. });
  726. }
  727. console.log(this.state.ProvinceCity);
  728. }.bind(this)
  729. }).always(
  730. function() {
  731. this.setState({
  732. loading: false
  733. });
  734. }.bind(this)
  735. );
  736. },
  737. //项目列表
  738. xiangmu(orderNos) {
  739. $.ajax({
  740. method: "get",
  741. dataType: "json",
  742. crossDomain: false,
  743. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  744. data: {
  745. orderNo: orderNos
  746. },
  747. success: function(data) {
  748. let theArr = [];
  749. if (data.error.length || data.data.list == "") {
  750. if (data.error && data.error.length) {
  751. message.warning(data.error[0].message);
  752. }
  753. } else {
  754. for (let i = 0; i < data.data.length; i++) {
  755. let thisdata = data.data[i];
  756. theArr.push({
  757. key: i,
  758. id: thisdata.id,
  759. orderNo: thisdata.orderNo, //订单编号
  760. commodityId: thisdata.commodityId, //项目ID
  761. commodityName: thisdata.commodityName, //项目名称
  762. cname: thisdata.cname, //项目类别
  763. commodityPrice: thisdata.commodityPrice, //项目价格
  764. commodityQuantity: thisdata.commodityQuantity, //项目数量
  765. main: thisdata.main, //是否为主要项目
  766. taskComment: thisdata.taskComment, //项目说明
  767. contacts: thisdata.contacts, //联系人
  768. contactsMobile: thisdata.contactsMobile, //联系人电话
  769. taskStatus: thisdata.taskStatus, //是否分配
  770. contractNo: thisdata.contractNo, //合同编号
  771. certificateNumber: thisdata.certificateNumber
  772. });
  773. }
  774. }
  775. this.setState({
  776. dataSourceX: theArr
  777. });
  778. }.bind(this)
  779. }).always(
  780. function() {
  781. this.setState({
  782. loading: false
  783. });
  784. }.bind(this)
  785. );
  786. },
  787. //导出
  788. exportExec() {
  789. let departmentName = "",
  790. depart = this.state.departmentArr || [];
  791. depart.map(item => {
  792. if (this.state.departmentId == item.id) {
  793. departmentName = item.name;
  794. return;
  795. }
  796. });
  797. let data = {
  798. departmentId: this.state.departmentId,
  799. departmentName: departmentName,
  800. salesName: this.state.orderRefundSearch, //订单负责人
  801. startTime: this.state.releaseDate[0],
  802. endTime: this.state.releaseDate[1],
  803. grantStatus: this.state.grantStatus
  804. };
  805. window.location.href =
  806. globalConfig.context +
  807. "/api/admin/orderProject/exportMyTaskList?" +
  808. $.param(data);
  809. },
  810. //关闭详情
  811. visitCancel() {
  812. this.setState({
  813. visible: false,
  814. speVisible: false
  815. });
  816. this.reset();
  817. },
  818. visitOk() {
  819. this.setState({
  820. visible: false,
  821. speVisible: false
  822. });
  823. this.reset();
  824. },
  825. closeDesc(e, s) {
  826. this.state.showDesc = e;
  827. if (s) {
  828. this.loadData(this.state.page);
  829. }
  830. },
  831. closeAssign(e, s) {
  832. this.state.roleName = "";
  833. this.state.assignVisible = e;
  834. if (s) {
  835. this.loadData(this.state.page);
  836. }
  837. },
  838. //添加工时
  839. okCancel(record) {
  840. this.setState({
  841. lookVisible: true,
  842. taskId: record.id
  843. });
  844. },
  845. //测试
  846. getOrgCodeUrl(e) {
  847. this.setState({ orgCodeUrl: e });
  848. },
  849. //查看下证信息
  850. loaduserss(record) {
  851. $.ajax({
  852. method: "get",
  853. dataType: "json",
  854. crossDomain: false,
  855. url: globalConfig.context + "/api/admin/orderProject/selectTaskProgress",
  856. data: {
  857. tid: record.id
  858. },
  859. success: function(data) {
  860. let theArr = [];
  861. let thisData = [];
  862. if (!thisData) {
  863. if (data.error && data.error.length) {
  864. message.warning(data.error[0].message);
  865. }
  866. thisData = {};
  867. } else {
  868. for (let i = 0; i < data.data.length; i++) {
  869. thisData = data.data[i];
  870. theArr.push({
  871. num: i + 1,
  872. key: i,
  873. id: thisData.id, //编号
  874. alreadyNumber: thisData.alreadyNumber, //下证数
  875. licenceTimes: thisData.licenceTimes, //下证时间
  876. notCount: thisData.notCount, //未下证数
  877. flag: true
  878. });
  879. }
  880. this.setState({
  881. contactList: theArr
  882. });
  883. }
  884. }.bind(this)
  885. }).always(
  886. function() {
  887. this.setState({
  888. loading: false
  889. });
  890. }.bind(this)
  891. );
  892. },
  893. //下证信息保存
  894. contactSave(record) {
  895. if (!record.licenceTimes) {
  896. message.warning("下证日期不能为空");
  897. return;
  898. }
  899. if (!record.alreadyNumber) {
  900. message.warning("下证数量不能为空");
  901. return;
  902. }
  903. this.setState({
  904. loading: true
  905. });
  906. $.ajax({
  907. url: globalConfig.context + "/api/admin/orderProject/createTaskProgress",
  908. method: "post",
  909. data: {
  910. taskId: this.state.id,
  911. licenceTimes: record.licenceTimes,
  912. alreadyNumber: record.alreadyNumber
  913. }
  914. }).done(
  915. function(data) {
  916. this.setState({
  917. loading: false
  918. });
  919. if (!data.error.length) {
  920. message.success("保存成功!");
  921. record.flag = true;
  922. this.loaduserss(this.state.dataArr);
  923. } else {
  924. message.warning(data.error[0].message);
  925. }
  926. }.bind(this)
  927. );
  928. },
  929. //下证信息删除
  930. contactDele(record) {
  931. this.setState({
  932. loading: true
  933. });
  934. $.ajax({
  935. url: globalConfig.context + "/api/admin/orderProject/delectTaskProgress",
  936. method: "post",
  937. data: {
  938. id: record.id
  939. }
  940. }).done(
  941. function(data) {
  942. this.setState({
  943. loading: false
  944. });
  945. if (!data.error.length) {
  946. this.loaduserss(this.state.dataArr);
  947. } else {
  948. message.warning(data.error[0].message);
  949. }
  950. }.bind(this)
  951. );
  952. },
  953. //点击新增下证信息
  954. addcontact() {
  955. this.state.contactList.push({
  956. num: this.state.contactList.length + 1,
  957. key: this.state.contactList.length,
  958. licenceTimes: "",
  959. alreadyNumber: "",
  960. notCount: "",
  961. dels: "",
  962. flag: false,
  963. aflag: false
  964. });
  965. this.setState({
  966. contactList: this.state.contactList
  967. });
  968. },
  969. //删除下证信息
  970. confirmDelet(record) {
  971. this.state.contactList.splice(record.key, 1);
  972. this.setState({
  973. contactList: this.state.contactList
  974. });
  975. if (record.id) {
  976. this.contactDele(record);
  977. }
  978. },
  979. caozuorizhi() {
  980. this.setState({
  981. visibleA: true
  982. });
  983. $.ajax({
  984. method: "get",
  985. dataType: "json",
  986. crossDomain: false,
  987. url: globalConfig.context + "/api/admin/orderProject/TaskLogList",
  988. data: {
  989. id: this.state.id
  990. },
  991. success: function(data) {
  992. let theArr = [];
  993. if (data.error.length || data.data.list == "") {
  994. if (data.error && data.error.length) {
  995. message.warning(data.error[0].message);
  996. }
  997. } else {
  998. for (let i = 0; i < data.data.length; i++) {
  999. let thisdata = data.data[i];
  1000. theArr.push({
  1001. key: i,
  1002. id: thisdata.id, //日志ID
  1003. content: thisdata.content, //流程
  1004. taskId: thisdata.taskId, //项目ID
  1005. aName: thisdata.aName, //负责人
  1006. createTimes: thisdata.createTimes //时间
  1007. });
  1008. }
  1009. }
  1010. this.setState({
  1011. dataSourceA: theArr
  1012. });
  1013. }.bind(this)
  1014. }).always(
  1015. function() {
  1016. this.setState({
  1017. loading: false
  1018. });
  1019. }.bind(this)
  1020. );
  1021. },
  1022. //关闭操作工时
  1023. visitCancelA() {
  1024. this.setState({
  1025. visibleA: false
  1026. });
  1027. },
  1028. nextCancel() {
  1029. this.setState({
  1030. addnextVisible: false
  1031. });
  1032. },
  1033. //点击打卡项目详情
  1034. tableRowClickX(record) {
  1035. this.setState({
  1036. jid: record.id, //项目ID
  1037. kid: record.commodityId, //商品ID
  1038. commodityName: record.commodityName, //金额
  1039. commodityPrice: record.commodityPrice, //金额
  1040. commodityQuantity: record.commodityQuantity, //数量
  1041. taskComment: record.taskComment, //备注
  1042. main: record.main.toString(), //是否为主要
  1043. addnextVisible: true,
  1044. addState: 0
  1045. });
  1046. },
  1047. //关闭添加工时
  1048. noCancel() {
  1049. this.setState({
  1050. lookVisible: false
  1051. });
  1052. this.reset();
  1053. },
  1054. search() {
  1055. this.loadData();
  1056. },
  1057. reset() {
  1058. this.state.id = ""; //项目编号
  1059. this.state.orderNo = ""; //订单编号
  1060. this.state.projectStatus = undefined; //项目状态
  1061. this.state.contractNoSearch = undefined;
  1062. this.state.projectStatusSearch = undefined; //项目状态
  1063. this.state.taskStatuSearch = undefined; //项目状态
  1064. this.state.taskComment = ""; //说明
  1065. this.state.startDate = ""; //启动日期
  1066. this.state.endDate = ""; //结束日期
  1067. this.state.acceptDate = ""; //受理日期
  1068. this.state.reviewDate = ""; //评审日期
  1069. this.state.publicityDate = ""; //公示日期
  1070. this.state.licenceDate = ""; //发证日期
  1071. attachmentUrl: []; //附件
  1072. this.state.contacts = ""; //联系人
  1073. this.state.contactMobile = ""; //联系人电话
  1074. this.state.legalPerson = ""; //法人
  1075. this.state.legalPersonTel = ""; //法人电话
  1076. this.state.taskId = ""; //项目编号
  1077. this.state.hours = ""; //工时
  1078. this.state.remarks = ""; //说明
  1079. this.state.taskDate = ""; //日期
  1080. this.state.taskComment = ""; //说明
  1081. this.state.nameSearch = "";
  1082. this.state.releaseDate = [];
  1083. this.state.orderNoSearch = "";
  1084. this.state.taskNoSearch = "";
  1085. this.state.outsourceName = "";
  1086. this.state.outsourcePrice = undefined;
  1087. this.state.distribution = undefined;
  1088. this.state.departmenttSearch = undefined;
  1089. this.loadData(this.state.page);
  1090. },
  1091. searchSwitch() {
  1092. this.setState({
  1093. searchMore: !this.state.searchMore
  1094. });
  1095. },
  1096. //部门
  1097. departmentList() {
  1098. this.setState({
  1099. loading: true
  1100. });
  1101. $.ajax({
  1102. method: "get",
  1103. dataType: "json",
  1104. crossDomain: false,
  1105. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  1106. data: {},
  1107. success: function(data) {
  1108. let thedata = data.data;
  1109. let theArr = [];
  1110. if (!thedata) {
  1111. if (data.error && data.error.length) {
  1112. message.warning(data.error[0].message);
  1113. }
  1114. thedata = {};
  1115. } else {
  1116. thedata.map(function(item, index) {
  1117. theArr.push({
  1118. key: index,
  1119. name: item.name,
  1120. id: item.id
  1121. });
  1122. });
  1123. }
  1124. this.setState({
  1125. departmentArr: theArr
  1126. });
  1127. }.bind(this)
  1128. }).always(
  1129. function() {
  1130. this.setState({
  1131. loading: false
  1132. });
  1133. }.bind(this)
  1134. );
  1135. },
  1136. changeList(arr) {
  1137. const newArr = [];
  1138. this.state.columns.forEach(item => {
  1139. arr.forEach(val => {
  1140. if (val === item.title) {
  1141. newArr.push(item);
  1142. }
  1143. });
  1144. });
  1145. this.setState({
  1146. changeList: newArr
  1147. });
  1148. },
  1149. timeClose() {
  1150. this.setState({
  1151. timeVisible: false
  1152. })
  1153. },
  1154. timeDetail(record) {
  1155. console.log(record);
  1156. this.setState({
  1157. loading: true,
  1158. recordHour: record.hours
  1159. });
  1160. $.ajax({
  1161. method: "get",
  1162. dataType: "json",
  1163. crossDomain: false,
  1164. url:
  1165. globalConfig.context + "/api/admin/orderProject/taskHoursDetailsList",
  1166. data: {
  1167. taskId: record.id
  1168. },
  1169. success: function(data) {
  1170. if (data.error && data.error.length) {
  1171. message.warning(data.error[0].message);
  1172. }else {
  1173. this.setState({
  1174. dataSourceTime: data.data
  1175. });
  1176. console.log(this.state.dataSourceTime);
  1177. }
  1178. }.bind(this)
  1179. }).always(
  1180. function() {
  1181. this.setState({
  1182. loading: false
  1183. });
  1184. }.bind(this)
  1185. );
  1186. },
  1187. render() {
  1188. const formItemLayout = {
  1189. labelCol: { span: 8 },
  1190. wrapperCol: { span: 14 }
  1191. };
  1192. let departmentArr = this.state.departmentArr || [];
  1193. return (
  1194. <div className="user-content">
  1195. <ShowModalDiv ShowModal={this.state.showModal} />
  1196. <div className="content-title" style={{ marginBottom: 10 }}>
  1197. <span style={{ fontWeight: 900, fontSize: 16 }}>项目派单管理</span>
  1198. </div>
  1199. <Tabs defaultActiveKey="2" onChange={this.callback} className="test" bordered>
  1200. <TabPane tab="更改表格显示数据" key="1">
  1201. <div style={{ marginLeft: 10 }}>
  1202. <ChooseList
  1203. columns={this.state.columns}
  1204. changeFn={this.changeList}
  1205. changeList={this.state.changeList}
  1206. top={55}
  1207. margin={11}
  1208. />
  1209. </div>
  1210. </TabPane>
  1211. <TabPane tab="搜索" key="2">
  1212. <div className="user-search" style={{ marginLeft: 10 }}>
  1213. <Input
  1214. placeholder="客户名称"
  1215. value={this.state.nameSearch}
  1216. onChange={e => {
  1217. this.setState({ nameSearch: e.target.value });
  1218. }}
  1219. />
  1220. <Input
  1221. placeholder="订单编号"
  1222. value={this.state.orderNoSearch}
  1223. onChange={e => {
  1224. this.setState({ orderNoSearch: e.target.value });
  1225. }}
  1226. />
  1227. <Input
  1228. placeholder="合同编号"
  1229. value={this.state.contractNoSearch}
  1230. onChange={e => {
  1231. this.setState({ contractNoSearch: e.target.value });
  1232. }}
  1233. />
  1234. <Input
  1235. placeholder="项目编号"
  1236. value={this.state.taskNoSearch}
  1237. onChange={e => {
  1238. this.setState({ taskNoSearch: e.target.value });
  1239. }}
  1240. />
  1241. <Select
  1242. placeholder="选择部门"
  1243. style={{ width: 150, marginRight: "10px" }}
  1244. value={this.state.departmenttSearch}
  1245. onChange={e => {
  1246. this.setState({ departmenttSearch: e });
  1247. }}
  1248. >
  1249. {departmentArr.map(function(item) {
  1250. return (
  1251. <Select.Option key={item.id}>{item.name}</Select.Option>
  1252. );
  1253. })}
  1254. </Select>
  1255. <Select
  1256. placeholder="项目状态"
  1257. style={{ width: 150, marginRight: "10px" }}
  1258. value={this.state.projectStatusSearch}
  1259. onChange={e => {
  1260. this.setState({ projectStatusSearch: e });
  1261. console.log(this.state.projectStatusSearch);
  1262. }}
  1263. >
  1264. {projectStatus.map(function(item) {
  1265. return (
  1266. <Select.Option key={item.value}>{item.key}</Select.Option>
  1267. );
  1268. })}
  1269. </Select>
  1270. <Button type="primary" onClick={this.search}>
  1271. 搜索
  1272. </Button>
  1273. <Button onClick={this.reset}>重置</Button>
  1274. {/* <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  1275. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  1276. <span>订单时间 :</span>
  1277. <RangePicker
  1278. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  1279. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  1280. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  1281. </div> */}
  1282. </div>
  1283. </TabPane>
  1284. <TabPane tab="导出Excel" key="3">
  1285. <Button
  1286. type="primary"
  1287. style={{ margin: "11px 0 10px 10px" }}
  1288. onClick={this.exportExec}
  1289. >
  1290. 导出Excel
  1291. </Button>
  1292. </TabPane>
  1293. {/* <TabPane tab="批量操作" key="6">
  1294. <Button
  1295. type="primary"
  1296. disabled={this.state.selectedRowKeys.length == 0}
  1297. style={{ margin: "0px 0px 10px 10px" }}
  1298. onClick={e => {
  1299. e.stopPropagation(),
  1300. this.evaluateY(this.state.selectedRowKeys, "财务专员");
  1301. }}
  1302. >
  1303. 转交
  1304. </Button>
  1305. </TabPane> */}
  1306. </Tabs>
  1307. {/* <div className="user-search">
  1308. <Input
  1309. placeholder="客户名称"
  1310. value={this.state.nameSearch}
  1311. onChange={e => {
  1312. this.setState({ nameSearch: e.target.value });
  1313. }}
  1314. />
  1315. <Input
  1316. placeholder="订单编号"
  1317. value={this.state.orderNoSearch}
  1318. onChange={e => {
  1319. this.setState({ orderNoSearch: e.target.value });
  1320. }}
  1321. />
  1322. <Input
  1323. placeholder="项目编号"
  1324. value={this.state.taskNoSearch}
  1325. onChange={e => {
  1326. this.setState({ taskNoSearch: e.target.value });
  1327. }}
  1328. />
  1329. <Select
  1330. placeholder="选择部门"
  1331. style={{ width: 150, marginRight: "10px" }}
  1332. value={this.state.departmenttSearch}
  1333. onChange={e => {
  1334. this.setState({ departmenttSearch: e });
  1335. }}
  1336. >
  1337. {departmentArr.map(function(item) {
  1338. return <Select.Option key={item.id}>{item.name}</Select.Option>;
  1339. })}
  1340. </Select>
  1341. <Button type="primary" onClick={this.search}>
  1342. 搜索
  1343. </Button>
  1344. <Button onClick={this.reset}>重置</Button>
  1345. <Button
  1346. type="primary"
  1347. style={{ marginLeft: "10px" }}
  1348. onClick={this.exportExec}
  1349. >
  1350. 导出Excel
  1351. </Button>
  1352. <span>更多搜索<Switch defaultChecked={false} onChange={this.searchSwitch.bind(this)} /></span>
  1353. <div className="search-more" style={this.state.searchMore ? { display: 'none' } : {}}>
  1354. <span>订单时间 :</span>
  1355. <RangePicker
  1356. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  1357. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  1358. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
  1359. </div>
  1360. </div> */}
  1361. <div className="patent-table">
  1362. <Spin spinning={this.state.loading}>
  1363. <Table
  1364. columns={
  1365. this.state.changeList == undefined
  1366. ? this.state.columns
  1367. : this.state.changeList
  1368. }
  1369. dataSource={this.state.dataSource}
  1370. pagination={this.state.pagination}
  1371. scroll={{ x: "max-content", y: 0 }}
  1372. onRowClick={this.tableRowClick.bind(this)}
  1373. bordered
  1374. size={"small"}
  1375. />
  1376. </Spin>
  1377. </div>
  1378. <Assign
  1379. title="项目"
  1380. selApi={"/api/admin/orderProject/projectDistribution"}
  1381. data={this.state.assignData}
  1382. showDesc={this.state.assignVisible}
  1383. closeDesc={this.closeAssign.bind(this)}
  1384. fenpaiData={8}
  1385. specially={0}
  1386. roleName={this.state.nub}
  1387. requestMethod={"post"}
  1388. flag={this.state.flag}
  1389. all={this.state}
  1390. />
  1391. <Modal
  1392. className="customeDetails"
  1393. footer=""
  1394. title="项目概况"
  1395. width="900px"
  1396. visible={this.state.visible}
  1397. onOk={this.visitOk}
  1398. onCancel={this.visitCancel}
  1399. >
  1400. <Form
  1401. layout="horizontal"
  1402. onSubmit={this.handleSubmit}
  1403. id="demand-form"
  1404. style={{ paddingBottom: "00px" }}
  1405. >
  1406. <Spin spinning={this.state.loading}>
  1407. <div className="clearfix">
  1408. <div className="clearfix">
  1409. <FormItem
  1410. className="half-item"
  1411. {...formItemLayout}
  1412. label="当前项目情况"
  1413. >
  1414. <Radio.Group
  1415. value={this.state.status}
  1416. onChange={e => {
  1417. this.setState({ status: e.target.value });
  1418. }}
  1419. >
  1420. <Radio value={0}>开启</Radio>
  1421. <Radio value={1}>暂停</Radio>
  1422. </Radio.Group>
  1423. <Button
  1424. type="primary"
  1425. size="small"
  1426. style={{ marginTop: "5px", position: "absolute" }}
  1427. onClick={this.caozuorizhi}
  1428. >
  1429. 操作日志
  1430. </Button>
  1431. </FormItem>
  1432. <FormItem
  1433. className="half-item"
  1434. {...formItemLayout}
  1435. label="合同编号"
  1436. >
  1437. <span>{this.state.contractNo}</span>
  1438. </FormItem>
  1439. </div>
  1440. <div className="clearfix">
  1441. <FormItem
  1442. className="half-item"
  1443. {...formItemLayout}
  1444. label="项目状态"
  1445. >
  1446. <Select
  1447. placeholder="选择项目状态"
  1448. style={{ width: "200px" }}
  1449. value={this.state.projectStatus}
  1450. onChange={e => {
  1451. this.setState({ projectStatus: e });
  1452. }}
  1453. >
  1454. {projectStatus.map(function(item) {
  1455. return (
  1456. <Select.Option key={item.value}>
  1457. {item.key}
  1458. </Select.Option>
  1459. );
  1460. })}
  1461. </Select>
  1462. </FormItem>
  1463. <FormItem
  1464. className="half-item"
  1465. {...formItemLayout}
  1466. label="是否特批"
  1467. >
  1468. <span>{getApproval(this.state.approval)}</span>
  1469. </FormItem>
  1470. <FormItem
  1471. className="half-item"
  1472. {...formItemLayout}
  1473. label="结算状态"
  1474. >
  1475. <span>
  1476. {getLiquidationStatus(this.state.liquidationStatus)}
  1477. </span>
  1478. </FormItem>
  1479. <FormItem
  1480. className="half-item"
  1481. {...formItemLayout}
  1482. label="流程状态"
  1483. >
  1484. <span>{getProcessStatus(this.state.processStatus)}</span>
  1485. </FormItem>
  1486. <FormItem
  1487. className="half-item"
  1488. {...formItemLayout}
  1489. label="订单编号"
  1490. >
  1491. <span>{this.state.orderNo}</span>
  1492. </FormItem>
  1493. </div>
  1494. <div className="clearfix">
  1495. <FormItem
  1496. className="half-item"
  1497. {...formItemLayout}
  1498. label="满意度表格"
  1499. >
  1500. <Radio.Group
  1501. value={this.state.formRetrieve}
  1502. onChange={e => {
  1503. this.setState({ formRetrieve: e.target.value });
  1504. }}
  1505. >
  1506. <Radio value={0}>未收回</Radio>
  1507. <Radio value={1}>已收回</Radio>
  1508. <Radio value={2}>其他</Radio>
  1509. </Radio.Group>
  1510. </FormItem>
  1511. <FormItem
  1512. className="half-item"
  1513. {...formItemLayout}
  1514. label="退单"
  1515. >
  1516. <Radio.Group
  1517. value={this.state.taskRefund}
  1518. onChange={e => {
  1519. this.setState({ taskRefund: e.target.value });
  1520. }}
  1521. >
  1522. <Radio value={0}>已完成</Radio>
  1523. <Radio value={1}>未完成</Radio>
  1524. <Radio value={2}>其他</Radio>
  1525. </Radio.Group>
  1526. </FormItem>
  1527. </div>
  1528. <div className="clearfix">
  1529. {
  1530. <FormItem
  1531. className="half-item"
  1532. {...formItemLayout}
  1533. label="(满意度)备注"
  1534. >
  1535. <Input
  1536. type="textarea"
  1537. placeholder="请输入备注"
  1538. rows={2}
  1539. value={this.state.retrieveContent}
  1540. onChange={e => {
  1541. this.setState({ retrieveContent: e.target.value });
  1542. }}
  1543. />
  1544. </FormItem>
  1545. }
  1546. {
  1547. <FormItem
  1548. className="half-item"
  1549. {...formItemLayout}
  1550. label="(退单)备注"
  1551. >
  1552. <Input
  1553. type="textarea"
  1554. placeholder="请输入备注"
  1555. rows={2}
  1556. value={this.state.refundContent}
  1557. onChange={e => {
  1558. this.setState({ refundContent: e.target.value });
  1559. }}
  1560. />
  1561. </FormItem>
  1562. }
  1563. </div>
  1564. <div className="clearfix">
  1565. <h3 className="sub-title">订单负责人信息</h3>
  1566. <FormItem
  1567. className="half-item"
  1568. {...formItemLayout}
  1569. label="负责人"
  1570. >
  1571. <span>
  1572. {this.state.salesmanName + "(" + this.state.depName + ")"}
  1573. </span>
  1574. </FormItem>
  1575. <FormItem
  1576. className="half-item"
  1577. {...formItemLayout}
  1578. label="负责人电话"
  1579. >
  1580. <span>{this.state.salesmanMobile}</span>
  1581. </FormItem>
  1582. <FormItem
  1583. className="half-item"
  1584. {...formItemLayout}
  1585. label="当前财务负责人"
  1586. >
  1587. <span>{this.state.nowFinance}</span>
  1588. </FormItem>
  1589. <FormItem
  1590. className="half-item"
  1591. {...formItemLayout}
  1592. label="当前财务负责人电话"
  1593. >
  1594. <span>{this.state.nowFinanceMobile}</span>
  1595. </FormItem>
  1596. <FormItem
  1597. className="half-item"
  1598. {...formItemLayout}
  1599. style={{ opacity: ".5" }}
  1600. label="原负责人"
  1601. >
  1602. <span>{this.state.oldSalesmanName}</span>
  1603. </FormItem>
  1604. <FormItem
  1605. className="half-item"
  1606. {...formItemLayout}
  1607. style={{ opacity: ".5" }}
  1608. label="原负责人电话"
  1609. >
  1610. <span>{this.state.oldSalesmanMobile}</span>
  1611. </FormItem>
  1612. <FormItem
  1613. className="half-item"
  1614. {...formItemLayout}
  1615. style={{ opacity: ".5" }}
  1616. label="实际财务操作人"
  1617. >
  1618. <span>{this.state.financeName}</span>
  1619. </FormItem>
  1620. <FormItem
  1621. className="half-item"
  1622. {...formItemLayout}
  1623. style={{ opacity: ".5" }}
  1624. label="实际财务操作人电话"
  1625. >
  1626. <span>{this.state.financeMobile}</span>
  1627. </FormItem>
  1628. </div>
  1629. <div className="clearfix">
  1630. <h3 className="sub-title">外包信息</h3>
  1631. <FormItem
  1632. className="half-item"
  1633. {...formItemLayout}
  1634. label="外包公司"
  1635. >
  1636. <Input
  1637. value={this.state.outsourceName}
  1638. onChange={e => {
  1639. this.setState({
  1640. outsourceName: e.target.value
  1641. });
  1642. }}
  1643. placeholder="请输入外包公司"
  1644. style={{ width: "200px" }}
  1645. />
  1646. </FormItem>
  1647. <FormItem
  1648. className="half-item"
  1649. {...formItemLayout}
  1650. label="外包成本(万元)"
  1651. >
  1652. <Input
  1653. value={this.state.outsourcePrice}
  1654. onChange={e => {
  1655. this.setState({
  1656. outsourcePrice: e.target.value
  1657. });
  1658. }}
  1659. placeholder="请输入外包成本"
  1660. style={{ width: "200px" }}
  1661. />
  1662. </FormItem>
  1663. </div>
  1664. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  1665. <div className="clearfix">
  1666. <h3 className="sub-title">联系信息</h3>
  1667. <FormItem
  1668. className="half-item"
  1669. {...formItemLayout}
  1670. label="客户名称"
  1671. >
  1672. <span>{this.state.userName}</span>
  1673. </FormItem>
  1674. <FormItem
  1675. className="half-item"
  1676. {...formItemLayout}
  1677. label="企业法人"
  1678. >
  1679. <Input
  1680. placeholder="请输入法人名称"
  1681. value={this.state.legalPerson}
  1682. style={{ width: "200px" }}
  1683. onChange={e => {
  1684. this.setState({ legalPerson: e.target.value });
  1685. }}
  1686. ref="commodityQuantity"
  1687. />
  1688. </FormItem>
  1689. <FormItem
  1690. className="half-item"
  1691. {...formItemLayout}
  1692. label="法人电话"
  1693. >
  1694. <Input
  1695. placeholder="请输入法人电话"
  1696. value={this.state.legalPersonTel}
  1697. style={{ width: "200px" }}
  1698. onChange={e => {
  1699. this.setState({ legalPersonTel: e.target.value });
  1700. }}
  1701. ref="commodityQuantity"
  1702. />
  1703. </FormItem>
  1704. <FormItem
  1705. className="half-item"
  1706. {...formItemLayout}
  1707. label="客户联系人"
  1708. >
  1709. <Input
  1710. placeholder="请输入联系人名称"
  1711. value={this.state.contacts}
  1712. style={{ width: "200px" }}
  1713. onChange={e => {
  1714. this.setState({ contacts: e.target.value });
  1715. }}
  1716. ref="commodityQuantity"
  1717. />
  1718. </FormItem>
  1719. <FormItem
  1720. className="half-item"
  1721. {...formItemLayout}
  1722. label="联系人电话"
  1723. >
  1724. <Input
  1725. placeholder="请输入联系人电话"
  1726. value={this.state.contactMobile}
  1727. style={{ width: "200px" }}
  1728. onChange={e => {
  1729. this.setState({ contactMobile: e.target.value });
  1730. }}
  1731. ref="commodityQuantity"
  1732. />
  1733. </FormItem>
  1734. <FormItem
  1735. className="half-item"
  1736. {...formItemLayout}
  1737. label="企业地址"
  1738. >
  1739. <Cascader
  1740. options={areaSelect()}
  1741. value={this.state.ProvinceCity}
  1742. placeholder="选择城市"
  1743. style={{ width: "200px" }}
  1744. onChange={e => {
  1745. this.setState({ ProvinceCity: e });
  1746. }}
  1747. />
  1748. </FormItem>
  1749. <FormItem
  1750. className="half-item"
  1751. {...formItemLayout}
  1752. label=""
  1753. ></FormItem>
  1754. <FormItem className="half-item" {...formItemLayout} label="">
  1755. <Input
  1756. placeholder="请输入详细地址"
  1757. value={this.state.postalAddress}
  1758. style={{ width: "200px", marginLeft: "12em" }}
  1759. onChange={e => {
  1760. this.setState({ postalAddress: e.target.value });
  1761. }}
  1762. ref="commodityQuantity"
  1763. />
  1764. </FormItem>
  1765. </div>
  1766. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  1767. <div className="clearfix">
  1768. <h3 className="sub-title">项目信息</h3>
  1769. <FormItem
  1770. className="half-item"
  1771. {...formItemLayout}
  1772. label="项目编号"
  1773. >
  1774. <span>{this.state.id}</span>
  1775. </FormItem>
  1776. <FormItem
  1777. className="half-item"
  1778. {...formItemLayout}
  1779. label="项目名称"
  1780. >
  1781. <span>{this.state.taskName}</span>
  1782. </FormItem>
  1783. <FormItem
  1784. className="half-item"
  1785. {...formItemLayout}
  1786. label="项目状态"
  1787. >
  1788. <Select
  1789. placeholder="选择项目状态"
  1790. style={{ width: "200px" }}
  1791. value={this.state.taskStatus}
  1792. onChange={e => {
  1793. this.setState({ taskStatus: e });
  1794. }}
  1795. >
  1796. {taskStatus.map(function(item) {
  1797. return (
  1798. <Select.Option key={item.value}>
  1799. {item.key}
  1800. </Select.Option>
  1801. );
  1802. })}
  1803. </Select>
  1804. </FormItem>
  1805. <FormItem
  1806. className="half-item"
  1807. {...formItemLayout}
  1808. label="项目类别"
  1809. >
  1810. <span>{this.state.cname}</span>
  1811. </FormItem>
  1812. <FormItem
  1813. className="half-item"
  1814. {...formItemLayout}
  1815. label="证书编号"
  1816. >
  1817. <Input
  1818. placeholder="请输入证书编号"
  1819. value={this.state.certificateNumber}
  1820. style={{ width: "200px" }}
  1821. onChange={e => {
  1822. this.setState({ certificateNumber: e.target.value });
  1823. }}
  1824. ref="commodityQuantity"
  1825. />
  1826. </FormItem>
  1827. </div>
  1828. <div className="clearfix">
  1829. <h3 className="sub-title">申报系统账户信息</h3>
  1830. {/*<span style={{color:'red'}}>注:仅技术部可见</span>*/}
  1831. <FormItem
  1832. className="half-item"
  1833. {...formItemLayout}
  1834. label="用户名"
  1835. >
  1836. <Input
  1837. placeholder="请输入用户名"
  1838. value={this.state.declareUser}
  1839. style={{ width: "200px" }}
  1840. onChange={e => {
  1841. this.setState({ declareUser: e.target.value });
  1842. }}
  1843. />
  1844. </FormItem>
  1845. <FormItem
  1846. className="half-item"
  1847. {...formItemLayout}
  1848. label="密码"
  1849. >
  1850. <Input
  1851. placeholder="请输入密码"
  1852. value={this.state.declarePwd}
  1853. style={{ width: "200px" }}
  1854. onChange={e => {
  1855. this.setState({ declarePwd: e.target.value });
  1856. }}
  1857. />
  1858. </FormItem>
  1859. </div>
  1860. <div className="clearfix">
  1861. <h3 className="sub-title">项目申报进度</h3>
  1862. <FormItem
  1863. className="half-item"
  1864. {...formItemLayout}
  1865. label="启动时间"
  1866. >
  1867. <DatePicker
  1868. style={{
  1869. marginTop: "2px",
  1870. width: "200px",
  1871. height: "32px"
  1872. }}
  1873. showTime
  1874. format="YYYY-MM-DD"
  1875. onOk={() => {}}
  1876. value={
  1877. this.state.startDate
  1878. ? moment(this.state.startDate)
  1879. : null
  1880. }
  1881. onChange={(data, dataString) => {
  1882. this.setState({ startDate: dataString });
  1883. }}
  1884. />
  1885. </FormItem>
  1886. <FormItem
  1887. className="half-item"
  1888. {...formItemLayout}
  1889. label="完成时间"
  1890. >
  1891. <DatePicker
  1892. style={{
  1893. marginTop: "2px",
  1894. width: "200px",
  1895. height: "32px"
  1896. }}
  1897. showTime
  1898. format="YYYY-MM-DD"
  1899. onOk={() => {}}
  1900. value={
  1901. this.state.endDate ? moment(this.state.endDate) : null
  1902. }
  1903. onChange={(data, dataString) => {
  1904. this.setState({ endDate: dataString });
  1905. }}
  1906. />
  1907. </FormItem>
  1908. <FormItem
  1909. className="half-item"
  1910. {...formItemLayout}
  1911. label="受理时间"
  1912. >
  1913. <DatePicker
  1914. style={{
  1915. marginTop: "2px",
  1916. width: "200px",
  1917. height: "32px"
  1918. }}
  1919. showTime
  1920. format="YYYY-MM-DD"
  1921. onOk={() => {}}
  1922. value={
  1923. this.state.acceptDate
  1924. ? moment(this.state.acceptDate)
  1925. : null
  1926. }
  1927. onChange={(data, dataString) => {
  1928. this.setState({ acceptDate: dataString });
  1929. }}
  1930. />
  1931. </FormItem>
  1932. <FormItem
  1933. className="half-item"
  1934. {...formItemLayout}
  1935. label="评审时间"
  1936. >
  1937. <DatePicker
  1938. style={{
  1939. marginTop: "2px",
  1940. width: "200px",
  1941. height: "32px"
  1942. }}
  1943. showTime
  1944. format="YYYY-MM-DD"
  1945. onOk={() => {}}
  1946. value={
  1947. this.state.reviewDate
  1948. ? moment(this.state.reviewDate)
  1949. : null
  1950. }
  1951. onChange={(data, dataString) => {
  1952. this.setState({ reviewDate: dataString });
  1953. }}
  1954. />
  1955. </FormItem>
  1956. <FormItem
  1957. className="half-item"
  1958. {...formItemLayout}
  1959. label="公示时间"
  1960. >
  1961. <DatePicker
  1962. style={{
  1963. marginTop: "2px",
  1964. width: "200px",
  1965. height: "32px"
  1966. }}
  1967. showTime
  1968. format="YYYY-MM-DD"
  1969. onOk={() => {}}
  1970. value={
  1971. this.state.publicityDate
  1972. ? moment(this.state.publicityDate)
  1973. : null
  1974. }
  1975. onChange={(data, dataString) => {
  1976. this.setState({ publicityDate: dataString });
  1977. }}
  1978. />
  1979. </FormItem>
  1980. <FormItem
  1981. className="half-item"
  1982. {...formItemLayout}
  1983. label="发证时间"
  1984. >
  1985. <DatePicker
  1986. style={{
  1987. marginTop: "2px",
  1988. width: "200px",
  1989. height: "32px"
  1990. }}
  1991. showTime
  1992. format="YYYY-MM-DD"
  1993. onOk={() => {}}
  1994. value={
  1995. this.state.licenceDate
  1996. ? moment(this.state.licenceDate)
  1997. : null
  1998. }
  1999. onChange={(data, dataString) => {
  2000. this.setState({ licenceDate: dataString });
  2001. }}
  2002. />
  2003. </FormItem>
  2004. <FormItem
  2005. className="half-item"
  2006. {...formItemLayout}
  2007. label="立项金额(万元)"
  2008. >
  2009. <Input
  2010. placeholder="请输入立项金额"
  2011. value={this.state.setUpAmount}
  2012. style={{ width: "200px" }}
  2013. onChange={e => {
  2014. this.setState({ setUpAmount: e.target.value });
  2015. }}
  2016. ref="commodityQuantity"
  2017. />
  2018. </FormItem>
  2019. <FormItem
  2020. className="half-item"
  2021. {...formItemLayout}
  2022. label="是否到款"
  2023. >
  2024. <Radio.Group
  2025. value={this.state.arrivalMoney}
  2026. onChange={e => {
  2027. this.setState({ arrivalMoney: e.target.value });
  2028. }}
  2029. >
  2030. <Radio value={0}>未到企业</Radio>
  2031. <Radio value={1}>已到企业</Radio>
  2032. </Radio.Group>
  2033. </FormItem>
  2034. </div>
  2035. <div className="clearfix">
  2036. <FormItem
  2037. labelCol={{ span: 3 }}
  2038. wrapperCol={{ span: 16 }}
  2039. label="附件"
  2040. >
  2041. <Picture
  2042. fileList={e => {
  2043. this.setState({ attachmentUrl: e });
  2044. }}
  2045. pictureUrl={this.state.attachmentUrl}
  2046. visible={this.props.visible}
  2047. data={{
  2048. sign: "order_task_file",
  2049. url: "/api/admin/orderProject/uploadOrderTaskFile",
  2050. number: 8
  2051. }}
  2052. />
  2053. </FormItem>
  2054. </div>
  2055. <div className="clearfix">
  2056. <FormItem
  2057. labelCol={{ span: 3 }}
  2058. wrapperCol={{ span: 16 }}
  2059. label="备注"
  2060. >
  2061. <Input
  2062. type="textarea"
  2063. placeholder="请输入备注"
  2064. rows={4}
  2065. value={this.state.taskComment}
  2066. onChange={e => {
  2067. this.setState({ taskComment: e.target.value });
  2068. }}
  2069. />
  2070. </FormItem>
  2071. </div>
  2072. <div>
  2073. <h3 className="sub-title">项目业务</h3>
  2074. {this.state.processStatus == 0 ? (
  2075. <Button
  2076. type="primary"
  2077. onClick={this.addDetailed}
  2078. style={{
  2079. float: "right",
  2080. marginRight: "50px",
  2081. marginBottom: "15px"
  2082. }}
  2083. >
  2084. 添加项目明细
  2085. </Button>
  2086. ) : (
  2087. ""
  2088. )}
  2089. </div>
  2090. <div className="patent-table">
  2091. <Spin spinning={this.state.loading}>
  2092. <Table
  2093. columns={this.state.columnsX}
  2094. dataSource={this.state.dataSourceX}
  2095. pagination={this.state.paginations}
  2096. onRowClick={this.tableRowClickX}
  2097. />
  2098. </Spin>
  2099. </div>
  2100. <div className="clearfix">
  2101. <Button
  2102. className="cancel"
  2103. type="primary"
  2104. onClick={this.tijiaoOk}
  2105. style={{ marginLeft: "200px", marginTop: "10px" }}
  2106. htmlType="submit"
  2107. >
  2108. 保存
  2109. </Button>
  2110. <Button
  2111. className="cancel"
  2112. type="ghost"
  2113. onClick={this.visitCancel}
  2114. style={{ marginLeft: "50px", marginTop: "10px" }}
  2115. >
  2116. 取消
  2117. </Button>
  2118. </div>
  2119. </div>
  2120. </Spin>
  2121. </Form>
  2122. </Modal>
  2123. <Modal
  2124. maskClosable={false}
  2125. visible={this.state.lookVisible}
  2126. onOk={this.noCancel}
  2127. onCancel={this.noCancel}
  2128. width="500px"
  2129. title={"添加工时"}
  2130. footer=""
  2131. className="admin-desc-content"
  2132. >
  2133. <Form layout="horizontal" id="demand-form">
  2134. <Spin spinning={this.state.loading}>
  2135. <div className="clearfix">
  2136. <FormItem {...formItemLayout} label="工作日期">
  2137. <DatePicker
  2138. style={{ marginTop: "2px", width: "200px", height: "32px" }}
  2139. showTime
  2140. format="YYYY-MM-DD"
  2141. onOk={() => {}}
  2142. value={
  2143. this.state.taskDate ? moment(this.state.taskDate) : null
  2144. }
  2145. onChange={(data, dataString) => {
  2146. this.setState({ taskDate: dataString });
  2147. }}
  2148. />
  2149. </FormItem>
  2150. </div>
  2151. <div className="clearfix">
  2152. <FormItem {...formItemLayout} label="工作时长">
  2153. <Input
  2154. placeholder="请输入工作时长"
  2155. value={this.state.hours}
  2156. style={{ width: "200px" }}
  2157. onChange={e => {
  2158. this.setState({ hours: e.target.value });
  2159. }}
  2160. ref="commodityQuantity"
  2161. />
  2162. </FormItem>
  2163. </div>
  2164. <div className="clearfix">
  2165. <FormItem {...formItemLayout} label="工作内容">
  2166. <Input
  2167. type="textarea"
  2168. placeholder="请输入备注"
  2169. rows={4}
  2170. value={this.state.remarks}
  2171. onChange={e => {
  2172. this.setState({ remarks: e.target.value });
  2173. }}
  2174. />
  2175. </FormItem>
  2176. </div>
  2177. <div className="clearfix">
  2178. <Button
  2179. className="cancel"
  2180. type="primary"
  2181. onClick={this.tianjiaOk}
  2182. style={{ marginLeft: "100px" }}
  2183. htmlType="submit"
  2184. >
  2185. 确定
  2186. </Button>
  2187. <Button
  2188. className="cancel"
  2189. type="ghost"
  2190. onClick={this.noCancel}
  2191. style={{ marginLeft: "50px" }}
  2192. >
  2193. 取消
  2194. </Button>
  2195. </div>
  2196. </Spin>
  2197. </Form>
  2198. </Modal>
  2199. <Modal
  2200. maskClosable={false}
  2201. visible={this.state.addnextVisible}
  2202. onOk={this.nextCancel}
  2203. onCancel={this.nextCancel}
  2204. width="800px"
  2205. title="项目项目详情"
  2206. footer=""
  2207. className="admin-desc-content"
  2208. >
  2209. <Form layout="horizontal" onSubmit={this.nextSubmit} id="demand-form">
  2210. <Spin spinning={this.state.loading}>
  2211. <div className="clearfix">
  2212. <FormItem
  2213. className="half-item"
  2214. {...formItemLayout}
  2215. label="项目名称"
  2216. >
  2217. <span>{this.state.commodityName}</span>
  2218. </FormItem>
  2219. <FormItem
  2220. className="half-item"
  2221. {...formItemLayout}
  2222. label="项目数量"
  2223. >
  2224. <span>{this.state.commodityQuantity}</span>
  2225. </FormItem>
  2226. <FormItem
  2227. className="half-item"
  2228. {...formItemLayout}
  2229. label="金额(万元)"
  2230. >
  2231. <span>{this.state.commodityPrice}</span>
  2232. </FormItem>
  2233. <FormItem
  2234. className="half-item"
  2235. {...formItemLayout}
  2236. label="主要项目"
  2237. >
  2238. <span>{getboutique(this.state.main)}</span>
  2239. </FormItem>
  2240. <div className="clearfix">
  2241. <FormItem
  2242. labelCol={{ span: 3 }}
  2243. wrapperCol={{ span: 18 }}
  2244. label="服务说明"
  2245. >
  2246. <span>{this.state.taskComment}</span>
  2247. </FormItem>
  2248. </div>
  2249. </div>
  2250. </Spin>
  2251. </Form>
  2252. </Modal>
  2253. <Modal
  2254. maskClosable={false}
  2255. visible={this.state.speVisible}
  2256. onOk={this.visitOk}
  2257. onCancel={this.visitCancel}
  2258. width="900px"
  2259. title="项目概况"
  2260. footer=""
  2261. className="admin-desc-content"
  2262. >
  2263. <div className="clearfix">
  2264. <FormItem
  2265. className="half-item"
  2266. {...formItemLayout}
  2267. label="当前项目情况"
  2268. >
  2269. <Radio.Group
  2270. value={this.state.status}
  2271. onChange={e => {
  2272. this.setState({ status: e.target.value });
  2273. }}
  2274. >
  2275. <Radio value={0}>开启</Radio>
  2276. <Radio value={1}>暂停</Radio>
  2277. </Radio.Group>
  2278. <Button
  2279. type="primary"
  2280. size="small"
  2281. style={{ marginTop: "5px", position: "absolute" }}
  2282. onClick={this.caozuorizhi}
  2283. >
  2284. 操作日志
  2285. </Button>
  2286. </FormItem>
  2287. <FormItem
  2288. className="half-item"
  2289. {...formItemLayout}
  2290. label="合同编号"
  2291. >
  2292. <span>{this.state.contractNo}</span>
  2293. </FormItem>
  2294. </div>
  2295. <div className="clearfix">
  2296. <FormItem
  2297. className="half-item"
  2298. {...formItemLayout}
  2299. label="项目状态"
  2300. >
  2301. <Select
  2302. placeholder="选择项目状态"
  2303. style={{ width: "200px" }}
  2304. value={this.state.projectStatus}
  2305. onChange={e => {
  2306. this.setState({ projectStatus: e });
  2307. }}
  2308. >
  2309. {projectStatus.map(function(item) {
  2310. return (
  2311. <Select.Option key={item.value}>{item.key}</Select.Option>
  2312. );
  2313. })}
  2314. </Select>
  2315. </FormItem>
  2316. <FormItem
  2317. className="half-item"
  2318. {...formItemLayout}
  2319. label="是否特批"
  2320. >
  2321. <span>{getApproval(this.state.approval)}</span>
  2322. </FormItem>
  2323. <FormItem
  2324. className="half-item"
  2325. {...formItemLayout}
  2326. label="结算状态"
  2327. >
  2328. <span>{getLiquidationStatus(this.state.liquidationStatus)}</span>
  2329. </FormItem>
  2330. <FormItem
  2331. className="half-item"
  2332. {...formItemLayout}
  2333. label="流程状态"
  2334. >
  2335. <span>{getProcessStatus(this.state.processStatus)}</span>
  2336. </FormItem>
  2337. <FormItem
  2338. className="half-item"
  2339. {...formItemLayout}
  2340. label="订单编号"
  2341. >
  2342. <span>{this.state.orderNo}</span>
  2343. </FormItem>
  2344. </div>
  2345. <div className="clearfix">
  2346. <FormItem
  2347. className="half-item"
  2348. {...formItemLayout}
  2349. label="满意度表格"
  2350. >
  2351. <Radio.Group
  2352. value={this.state.formRetrieve}
  2353. onChange={e => {
  2354. this.setState({ formRetrieve: e.target.value });
  2355. }}
  2356. >
  2357. <Radio value={0}>未收回</Radio>
  2358. <Radio value={1}>已收回</Radio>
  2359. <Radio value={2}>其他</Radio>
  2360. </Radio.Group>
  2361. </FormItem>
  2362. <FormItem className="half-item" {...formItemLayout} label="退单">
  2363. <Radio.Group
  2364. value={this.state.taskRefund}
  2365. onChange={e => {
  2366. this.setState({ taskRefund: e.target.value });
  2367. }}
  2368. >
  2369. <Radio value={0}>已完成</Radio>
  2370. <Radio value={1}>未完成</Radio>
  2371. <Radio value={2}>其他</Radio>
  2372. </Radio.Group>
  2373. </FormItem>
  2374. </div>
  2375. <div className="clearfix">
  2376. {
  2377. <FormItem
  2378. className="half-item"
  2379. {...formItemLayout}
  2380. label="(满意度)备注"
  2381. >
  2382. <Input
  2383. type="textarea"
  2384. placeholder="请输入备注"
  2385. rows={2}
  2386. value={this.state.retrieveContent}
  2387. onChange={e => {
  2388. this.setState({ retrieveContent: e.target.value });
  2389. }}
  2390. />
  2391. </FormItem>
  2392. }
  2393. {
  2394. <FormItem
  2395. className="half-item"
  2396. {...formItemLayout}
  2397. label="(退单)备注"
  2398. >
  2399. <Input
  2400. type="textarea"
  2401. placeholder="请输入备注"
  2402. rows={2}
  2403. value={this.state.refundContent}
  2404. onChange={e => {
  2405. this.setState({ refundContent: e.target.value });
  2406. }}
  2407. />
  2408. </FormItem>
  2409. }
  2410. </div>
  2411. <div className="clearfix">
  2412. <h3 className="sub-title">订单负责人信息</h3>
  2413. <FormItem className="half-item" {...formItemLayout} label="负责人">
  2414. <span>
  2415. {this.state.salesmanName + "(" + this.state.depName + ")"}
  2416. </span>
  2417. </FormItem>
  2418. <FormItem
  2419. className="half-item"
  2420. {...formItemLayout}
  2421. label="负责人电话"
  2422. >
  2423. <span>{this.state.salesmanMobile}</span>
  2424. </FormItem>
  2425. <FormItem
  2426. className="half-item"
  2427. {...formItemLayout}
  2428. label="当前财务负责人"
  2429. >
  2430. <span>{this.state.nowFinance}</span>
  2431. </FormItem>
  2432. <FormItem
  2433. className="half-item"
  2434. {...formItemLayout}
  2435. label="当前财务负责人电话"
  2436. >
  2437. <span>{this.state.nowFinanceMobile}</span>
  2438. </FormItem>
  2439. <FormItem
  2440. className="half-item"
  2441. {...formItemLayout}
  2442. style={{ opacity: ".5" }}
  2443. label="原负责人"
  2444. >
  2445. <span>{this.state.oldSalesmanName}</span>
  2446. </FormItem>
  2447. <FormItem
  2448. className="half-item"
  2449. {...formItemLayout}
  2450. style={{ opacity: ".5" }}
  2451. label="原负责人电话"
  2452. >
  2453. <span>{this.state.oldSalesmanMobile}</span>
  2454. </FormItem>
  2455. <FormItem
  2456. className="half-item"
  2457. {...formItemLayout}
  2458. style={{ opacity: ".5" }}
  2459. label="实际财务操作人"
  2460. >
  2461. <span>{this.state.financeName}</span>
  2462. </FormItem>
  2463. <FormItem
  2464. className="half-item"
  2465. {...formItemLayout}
  2466. style={{ opacity: ".5" }}
  2467. label="实际财务操作人电话"
  2468. >
  2469. <span>{this.state.financeMobile}</span>
  2470. </FormItem>
  2471. </div>
  2472. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2473. <div className="clearfix">
  2474. <h3 className="sub-title">联系信息</h3>
  2475. <FormItem
  2476. className="half-item"
  2477. {...formItemLayout}
  2478. label="客户名称"
  2479. >
  2480. <span>{this.state.userName}</span>
  2481. </FormItem>
  2482. <FormItem
  2483. className="half-item"
  2484. {...formItemLayout}
  2485. label="企业法人"
  2486. >
  2487. <Input
  2488. placeholder="请输入法人名称"
  2489. value={this.state.legalPerson}
  2490. style={{ width: "200px" }}
  2491. onChange={e => {
  2492. this.setState({ legalPerson: e.target.value });
  2493. }}
  2494. ref="commodityQuantity"
  2495. />
  2496. </FormItem>
  2497. <FormItem
  2498. className="half-item"
  2499. {...formItemLayout}
  2500. label="法人电话"
  2501. >
  2502. <Input
  2503. placeholder="请输入法人电话"
  2504. value={this.state.legalPersonTel}
  2505. style={{ width: "200px" }}
  2506. onChange={e => {
  2507. this.setState({ legalPersonTel: e.target.value });
  2508. }}
  2509. ref="commodityQuantity"
  2510. />
  2511. </FormItem>
  2512. <FormItem
  2513. className="half-item"
  2514. {...formItemLayout}
  2515. label="客户联系人"
  2516. >
  2517. <Input
  2518. placeholder="请输入联系人名称"
  2519. value={this.state.contacts}
  2520. style={{ width: "200px" }}
  2521. onChange={e => {
  2522. this.setState({ contacts: e.target.value });
  2523. }}
  2524. ref="commodityQuantity"
  2525. />
  2526. </FormItem>
  2527. <FormItem
  2528. className="half-item"
  2529. {...formItemLayout}
  2530. label="联系人电话"
  2531. >
  2532. <Input
  2533. placeholder="请输入联系人电话"
  2534. value={this.state.contactMobile}
  2535. style={{ width: "200px" }}
  2536. onChange={e => {
  2537. this.setState({ contactMobile: e.target.value });
  2538. }}
  2539. ref="commodityQuantity"
  2540. />
  2541. </FormItem>
  2542. <FormItem
  2543. className="half-item"
  2544. {...formItemLayout}
  2545. label="企业地址"
  2546. >
  2547. <Cascader
  2548. options={areaSelect()}
  2549. value={this.state.ProvinceCity}
  2550. placeholder="选择城市"
  2551. style={{ width: "200px" }}
  2552. onChange={e => {
  2553. this.setState({ ProvinceCity: e });
  2554. }}
  2555. />
  2556. </FormItem>
  2557. <FormItem
  2558. className="half-item"
  2559. {...formItemLayout}
  2560. label=""
  2561. ></FormItem>
  2562. <FormItem className="half-item" {...formItemLayout} label="">
  2563. <Input
  2564. placeholder="请输入详细地址"
  2565. value={this.state.postalAddress}
  2566. style={{ width: "200px", marginLeft: "12em" }}
  2567. onChange={e => {
  2568. this.setState({ postalAddress: e.target.value });
  2569. }}
  2570. ref="commodityQuantity"
  2571. />
  2572. </FormItem>
  2573. </div>
  2574. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2575. <div className="clearfix">
  2576. <h3 className="sub-title">项目信息</h3>
  2577. <FormItem
  2578. className="half-item"
  2579. {...formItemLayout}
  2580. label="项目编号"
  2581. >
  2582. <span>{this.state.id}</span>
  2583. </FormItem>
  2584. <FormItem
  2585. className="half-item"
  2586. {...formItemLayout}
  2587. label="项目名称"
  2588. >
  2589. <span>{this.state.taskName}</span>
  2590. </FormItem>
  2591. <FormItem
  2592. className="half-item"
  2593. {...formItemLayout}
  2594. label="项目状态"
  2595. >
  2596. <Select
  2597. placeholder="选择项目状态"
  2598. style={{ width: "200px" }}
  2599. value={this.state.taskStatus}
  2600. onChange={e => {
  2601. this.setState({ taskStatus: e });
  2602. }}
  2603. >
  2604. {taskStatus.map(function(item) {
  2605. return (
  2606. <Select.Option key={item.value}>{item.key}</Select.Option>
  2607. );
  2608. })}
  2609. </Select>
  2610. </FormItem>
  2611. <FormItem
  2612. className="half-item"
  2613. {...formItemLayout}
  2614. label="项目类别"
  2615. >
  2616. <span>{this.state.cname}</span>
  2617. </FormItem>
  2618. <FormItem
  2619. className="half-item"
  2620. {...formItemLayout}
  2621. label="证书编号"
  2622. >
  2623. <Input
  2624. placeholder="请输入证书编号"
  2625. value={this.state.certificateNumber}
  2626. style={{ width: "200px" }}
  2627. onChange={e => {
  2628. this.setState({ certificateNumber: e.target.value });
  2629. }}
  2630. ref="commodityQuantity"
  2631. />
  2632. </FormItem>
  2633. </div>
  2634. <div className="clearfix" style={{ marginTop: "10px" }}>
  2635. <FormItem
  2636. labelCol={{ span: 3 }}
  2637. wrapperCol={{ span: 14 }}
  2638. label="附件"
  2639. >
  2640. <Picture
  2641. fileList={e => {
  2642. this.setState({ attachmentUrl: e });
  2643. }}
  2644. pictureUrl={this.state.attachmentUrl}
  2645. visible={this.props.visible}
  2646. data={{
  2647. sign: "order_task_file",
  2648. url: "/api/admin/orderProject/uploadOrderTaskFile",
  2649. number: 8
  2650. }}
  2651. />
  2652. </FormItem>
  2653. </div>
  2654. <div className="clearfix">
  2655. <FormItem
  2656. labelCol={{ span: 3 }}
  2657. wrapperCol={{ span: 16 }}
  2658. label="备注"
  2659. >
  2660. <Input
  2661. type="textarea"
  2662. placeholder="请输入备注"
  2663. rows={4}
  2664. value={this.state.taskComment}
  2665. onChange={e => {
  2666. this.setState({ taskComment: e.target.value });
  2667. }}
  2668. />
  2669. </FormItem>
  2670. </div>
  2671. <div className="clearfix">
  2672. <h3 className="sub-title">项目申报进度</h3>
  2673. <FormItem
  2674. className="half-item"
  2675. {...formItemLayout}
  2676. label="启动时间"
  2677. >
  2678. <DatePicker
  2679. style={{ marginTop: "5px" }}
  2680. showTime
  2681. format="YYYY-MM-DD"
  2682. onOk={() => {}}
  2683. value={
  2684. this.state.startDate ? moment(this.state.startDate) : null
  2685. }
  2686. onChange={(data, dataString) => {
  2687. this.setState({ startDate: dataString });
  2688. }}
  2689. />
  2690. </FormItem>
  2691. <FormItem
  2692. className="half-item"
  2693. {...formItemLayout}
  2694. label="软著派单数量"
  2695. >
  2696. <span>{this.state.commodityQuantity}</span>
  2697. <Button
  2698. type="primary"
  2699. size="small"
  2700. style={{ marginLeft: "45px" }}
  2701. onClick={this.addcontact}
  2702. >
  2703. +增加下证信息
  2704. </Button>
  2705. </FormItem>
  2706. <div className="patent-table">
  2707. <Spin spinning={this.state.loading}>
  2708. <Table
  2709. columns={this.state.ContactsLists}
  2710. dataSource={this.state.contactList}
  2711. pagination={false}
  2712. />
  2713. </Spin>
  2714. </div>
  2715. </div>
  2716. <div className="clearfix">
  2717. <h3 className="sub-title">项目业务</h3>
  2718. <div className="patent-table">
  2719. <Spin spinning={this.state.loading}>
  2720. <Table
  2721. columns={this.state.columnsX}
  2722. dataSource={this.state.dataSourceX}
  2723. pagination={this.state.paginations}
  2724. onRowClick={this.tableRowClickX}
  2725. />
  2726. </Spin>
  2727. </div>
  2728. </div>
  2729. <div className="clearfix">
  2730. <Button
  2731. className="cancel"
  2732. type="primary"
  2733. onClick={this.tijiaoOk}
  2734. style={{ marginLeft: "200px", marginTop: "10px" }}
  2735. htmlType="submit"
  2736. >
  2737. 保存
  2738. </Button>
  2739. <Button
  2740. className="cancel"
  2741. type="ghost"
  2742. onClick={this.visitCancel}
  2743. style={{ marginLeft: "50px", marginTop: "10px" }}
  2744. >
  2745. 取消
  2746. </Button>
  2747. </div>
  2748. </Modal>
  2749. <Modal
  2750. width="800px"
  2751. visible={this.state.visibleA}
  2752. onCancel={this.visitCancelA}
  2753. title="操作日志"
  2754. footer=""
  2755. className="admin-desc-content"
  2756. >
  2757. <div className="patent-table patent-table-center">
  2758. <Spin spinning={this.state.loading}>
  2759. <Table
  2760. columns={this.state.columnsA}
  2761. dataSource={this.state.dataSourceA}
  2762. pagination={false}
  2763. />
  2764. </Spin>
  2765. </div>
  2766. </Modal>
  2767. <Modal
  2768. title="工时记录"
  2769. visible={this.state.timeVisible}
  2770. onCancel={this.timeClose}
  2771. width={800}
  2772. footer={null}
  2773. >
  2774. <Spin spinning={this.state.loading}>
  2775. <Table
  2776. columns={this.state.columnsTime}
  2777. dataSource={this.state.dataSourceTime}
  2778. pagination={false}
  2779. scroll={{ x: "max-content", y: 0 }}
  2780. bordered
  2781. size={"small"}
  2782. />
  2783. <p style={{ marginTop: 10, color: "red" }}>
  2784. 累计工时(小时):{this.state.recordHour}
  2785. </p>
  2786. </Spin>
  2787. </Modal>
  2788. </div>
  2789. );
  2790. }
  2791. });
  2792. export default Task;