myTask.jsx 91 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813
  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. bordered
  2098. size="small"
  2099. />
  2100. </Spin>
  2101. </div>
  2102. <div className="clearfix">
  2103. <Button
  2104. className="cancel"
  2105. type="primary"
  2106. onClick={this.tijiaoOk}
  2107. style={{ marginLeft: "200px", marginTop: "10px" }}
  2108. htmlType="submit"
  2109. >
  2110. 保存
  2111. </Button>
  2112. <Button
  2113. className="cancel"
  2114. type="ghost"
  2115. onClick={this.visitCancel}
  2116. style={{ marginLeft: "50px", marginTop: "10px" }}
  2117. >
  2118. 取消
  2119. </Button>
  2120. </div>
  2121. </div>
  2122. </Spin>
  2123. </Form>
  2124. </Modal>
  2125. <Modal
  2126. maskClosable={false}
  2127. visible={this.state.lookVisible}
  2128. onOk={this.noCancel}
  2129. onCancel={this.noCancel}
  2130. width="500px"
  2131. title={"添加工时"}
  2132. footer=""
  2133. className="admin-desc-content"
  2134. >
  2135. <Form layout="horizontal" id="demand-form">
  2136. <Spin spinning={this.state.loading}>
  2137. <div className="clearfix">
  2138. <FormItem {...formItemLayout} label="工作日期">
  2139. <DatePicker
  2140. style={{ marginTop: "2px", width: "200px", height: "32px" }}
  2141. showTime
  2142. format="YYYY-MM-DD"
  2143. onOk={() => {}}
  2144. value={
  2145. this.state.taskDate ? moment(this.state.taskDate) : null
  2146. }
  2147. onChange={(data, dataString) => {
  2148. this.setState({ taskDate: dataString });
  2149. }}
  2150. />
  2151. </FormItem>
  2152. </div>
  2153. <div className="clearfix">
  2154. <FormItem {...formItemLayout} label="工作时长">
  2155. <Input
  2156. placeholder="请输入工作时长"
  2157. value={this.state.hours}
  2158. style={{ width: "200px" }}
  2159. onChange={e => {
  2160. this.setState({ hours: e.target.value });
  2161. }}
  2162. ref="commodityQuantity"
  2163. />
  2164. </FormItem>
  2165. </div>
  2166. <div className="clearfix">
  2167. <FormItem {...formItemLayout} label="工作内容">
  2168. <Input
  2169. type="textarea"
  2170. placeholder="请输入备注"
  2171. rows={4}
  2172. value={this.state.remarks}
  2173. onChange={e => {
  2174. this.setState({ remarks: e.target.value });
  2175. }}
  2176. />
  2177. </FormItem>
  2178. </div>
  2179. <div className="clearfix">
  2180. <Button
  2181. className="cancel"
  2182. type="primary"
  2183. onClick={this.tianjiaOk}
  2184. style={{ marginLeft: "100px" }}
  2185. htmlType="submit"
  2186. >
  2187. 确定
  2188. </Button>
  2189. <Button
  2190. className="cancel"
  2191. type="ghost"
  2192. onClick={this.noCancel}
  2193. style={{ marginLeft: "50px" }}
  2194. >
  2195. 取消
  2196. </Button>
  2197. </div>
  2198. </Spin>
  2199. </Form>
  2200. </Modal>
  2201. <Modal
  2202. maskClosable={false}
  2203. visible={this.state.addnextVisible}
  2204. onOk={this.nextCancel}
  2205. onCancel={this.nextCancel}
  2206. width="800px"
  2207. title="项目详情"
  2208. footer=""
  2209. className="admin-desc-content"
  2210. >
  2211. <Form layout="horizontal" onSubmit={this.nextSubmit} id="demand-form">
  2212. <Spin spinning={this.state.loading}>
  2213. <div className="clearfix">
  2214. <FormItem
  2215. className="half-item"
  2216. {...formItemLayout}
  2217. label="项目名称"
  2218. >
  2219. <span>{this.state.commodityName}</span>
  2220. </FormItem>
  2221. <FormItem
  2222. className="half-item"
  2223. {...formItemLayout}
  2224. label="项目数量"
  2225. >
  2226. <span>{this.state.commodityQuantity}</span>
  2227. </FormItem>
  2228. <FormItem
  2229. className="half-item"
  2230. {...formItemLayout}
  2231. label="金额(万元)"
  2232. >
  2233. <span>{this.state.commodityPrice ? "***" : 0}</span>
  2234. </FormItem>
  2235. <FormItem
  2236. className="half-item"
  2237. {...formItemLayout}
  2238. label="主要项目"
  2239. >
  2240. <span>{getboutique(this.state.main)}</span>
  2241. </FormItem>
  2242. <div className="clearfix">
  2243. <FormItem
  2244. labelCol={{ span: 3 }}
  2245. wrapperCol={{ span: 18 }}
  2246. label="服务说明"
  2247. >
  2248. <span>{this.state.taskComment}</span>
  2249. </FormItem>
  2250. </div>
  2251. </div>
  2252. </Spin>
  2253. </Form>
  2254. </Modal>
  2255. <Modal
  2256. maskClosable={false}
  2257. visible={this.state.speVisible}
  2258. onOk={this.visitOk}
  2259. onCancel={this.visitCancel}
  2260. width="900px"
  2261. title="项目概况"
  2262. footer=""
  2263. className="admin-desc-content"
  2264. >
  2265. <div className="clearfix">
  2266. <FormItem
  2267. className="half-item"
  2268. {...formItemLayout}
  2269. label="当前项目情况"
  2270. >
  2271. <Radio.Group
  2272. value={this.state.status}
  2273. onChange={e => {
  2274. this.setState({ status: e.target.value });
  2275. }}
  2276. >
  2277. <Radio value={0}>开启</Radio>
  2278. <Radio value={1}>暂停</Radio>
  2279. </Radio.Group>
  2280. <Button
  2281. type="primary"
  2282. size="small"
  2283. style={{ marginTop: "5px", position: "absolute" }}
  2284. onClick={this.caozuorizhi}
  2285. >
  2286. 操作日志
  2287. </Button>
  2288. </FormItem>
  2289. <FormItem
  2290. className="half-item"
  2291. {...formItemLayout}
  2292. label="合同编号"
  2293. >
  2294. <span>{this.state.contractNo}</span>
  2295. </FormItem>
  2296. </div>
  2297. <div className="clearfix">
  2298. <FormItem
  2299. className="half-item"
  2300. {...formItemLayout}
  2301. label="项目状态"
  2302. >
  2303. <Select
  2304. placeholder="选择项目状态"
  2305. style={{ width: "200px" }}
  2306. value={this.state.projectStatus}
  2307. onChange={e => {
  2308. this.setState({ projectStatus: e });
  2309. }}
  2310. >
  2311. {projectStatus.map(function(item) {
  2312. return (
  2313. <Select.Option key={item.value}>{item.key}</Select.Option>
  2314. );
  2315. })}
  2316. </Select>
  2317. </FormItem>
  2318. <FormItem
  2319. className="half-item"
  2320. {...formItemLayout}
  2321. label="是否特批"
  2322. >
  2323. <span>{getApproval(this.state.approval)}</span>
  2324. </FormItem>
  2325. <FormItem
  2326. className="half-item"
  2327. {...formItemLayout}
  2328. label="结算状态"
  2329. >
  2330. <span>{getLiquidationStatus(this.state.liquidationStatus)}</span>
  2331. </FormItem>
  2332. <FormItem
  2333. className="half-item"
  2334. {...formItemLayout}
  2335. label="流程状态"
  2336. >
  2337. <span>{getProcessStatus(this.state.processStatus)}</span>
  2338. </FormItem>
  2339. <FormItem
  2340. className="half-item"
  2341. {...formItemLayout}
  2342. label="订单编号"
  2343. >
  2344. <span>{this.state.orderNo}</span>
  2345. </FormItem>
  2346. </div>
  2347. <div className="clearfix">
  2348. <FormItem
  2349. className="half-item"
  2350. {...formItemLayout}
  2351. label="满意度表格"
  2352. >
  2353. <Radio.Group
  2354. value={this.state.formRetrieve}
  2355. onChange={e => {
  2356. this.setState({ formRetrieve: e.target.value });
  2357. }}
  2358. >
  2359. <Radio value={0}>未收回</Radio>
  2360. <Radio value={1}>已收回</Radio>
  2361. <Radio value={2}>其他</Radio>
  2362. </Radio.Group>
  2363. </FormItem>
  2364. <FormItem className="half-item" {...formItemLayout} label="退单">
  2365. <Radio.Group
  2366. value={this.state.taskRefund}
  2367. onChange={e => {
  2368. this.setState({ taskRefund: e.target.value });
  2369. }}
  2370. >
  2371. <Radio value={0}>已完成</Radio>
  2372. <Radio value={1}>未完成</Radio>
  2373. <Radio value={2}>其他</Radio>
  2374. </Radio.Group>
  2375. </FormItem>
  2376. </div>
  2377. <div className="clearfix">
  2378. {
  2379. <FormItem
  2380. className="half-item"
  2381. {...formItemLayout}
  2382. label="(满意度)备注"
  2383. >
  2384. <Input
  2385. type="textarea"
  2386. placeholder="请输入备注"
  2387. rows={2}
  2388. value={this.state.retrieveContent}
  2389. onChange={e => {
  2390. this.setState({ retrieveContent: e.target.value });
  2391. }}
  2392. />
  2393. </FormItem>
  2394. }
  2395. {
  2396. <FormItem
  2397. className="half-item"
  2398. {...formItemLayout}
  2399. label="(退单)备注"
  2400. >
  2401. <Input
  2402. type="textarea"
  2403. placeholder="请输入备注"
  2404. rows={2}
  2405. value={this.state.refundContent}
  2406. onChange={e => {
  2407. this.setState({ refundContent: e.target.value });
  2408. }}
  2409. />
  2410. </FormItem>
  2411. }
  2412. </div>
  2413. <div className="clearfix">
  2414. <h3 className="sub-title">订单负责人信息</h3>
  2415. <FormItem className="half-item" {...formItemLayout} label="负责人">
  2416. <span>
  2417. {this.state.salesmanName + "(" + this.state.depName + ")"}
  2418. </span>
  2419. </FormItem>
  2420. <FormItem
  2421. className="half-item"
  2422. {...formItemLayout}
  2423. label="负责人电话"
  2424. >
  2425. <span>{this.state.salesmanMobile}</span>
  2426. </FormItem>
  2427. <FormItem
  2428. className="half-item"
  2429. {...formItemLayout}
  2430. label="当前财务负责人"
  2431. >
  2432. <span>{this.state.nowFinance}</span>
  2433. </FormItem>
  2434. <FormItem
  2435. className="half-item"
  2436. {...formItemLayout}
  2437. label="当前财务负责人电话"
  2438. >
  2439. <span>{this.state.nowFinanceMobile}</span>
  2440. </FormItem>
  2441. <FormItem
  2442. className="half-item"
  2443. {...formItemLayout}
  2444. style={{ opacity: ".5" }}
  2445. label="原负责人"
  2446. >
  2447. <span>{this.state.oldSalesmanName}</span>
  2448. </FormItem>
  2449. <FormItem
  2450. className="half-item"
  2451. {...formItemLayout}
  2452. style={{ opacity: ".5" }}
  2453. label="原负责人电话"
  2454. >
  2455. <span>{this.state.oldSalesmanMobile}</span>
  2456. </FormItem>
  2457. <FormItem
  2458. className="half-item"
  2459. {...formItemLayout}
  2460. style={{ opacity: ".5" }}
  2461. label="实际财务操作人"
  2462. >
  2463. <span>{this.state.financeName}</span>
  2464. </FormItem>
  2465. <FormItem
  2466. className="half-item"
  2467. {...formItemLayout}
  2468. style={{ opacity: ".5" }}
  2469. label="实际财务操作人电话"
  2470. >
  2471. <span>{this.state.financeMobile}</span>
  2472. </FormItem>
  2473. </div>
  2474. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2475. <div className="clearfix">
  2476. <h3 className="sub-title">联系信息</h3>
  2477. <FormItem
  2478. className="half-item"
  2479. {...formItemLayout}
  2480. label="客户名称"
  2481. >
  2482. <span>{this.state.userName}</span>
  2483. </FormItem>
  2484. <FormItem
  2485. className="half-item"
  2486. {...formItemLayout}
  2487. label="企业法人"
  2488. >
  2489. <Input
  2490. placeholder="请输入法人名称"
  2491. value={this.state.legalPerson}
  2492. style={{ width: "200px" }}
  2493. onChange={e => {
  2494. this.setState({ legalPerson: e.target.value });
  2495. }}
  2496. ref="commodityQuantity"
  2497. />
  2498. </FormItem>
  2499. <FormItem
  2500. className="half-item"
  2501. {...formItemLayout}
  2502. label="法人电话"
  2503. >
  2504. <Input
  2505. placeholder="请输入法人电话"
  2506. value={this.state.legalPersonTel}
  2507. style={{ width: "200px" }}
  2508. onChange={e => {
  2509. this.setState({ legalPersonTel: e.target.value });
  2510. }}
  2511. ref="commodityQuantity"
  2512. />
  2513. </FormItem>
  2514. <FormItem
  2515. className="half-item"
  2516. {...formItemLayout}
  2517. label="客户联系人"
  2518. >
  2519. <Input
  2520. placeholder="请输入联系人名称"
  2521. value={this.state.contacts}
  2522. style={{ width: "200px" }}
  2523. onChange={e => {
  2524. this.setState({ contacts: e.target.value });
  2525. }}
  2526. ref="commodityQuantity"
  2527. />
  2528. </FormItem>
  2529. <FormItem
  2530. className="half-item"
  2531. {...formItemLayout}
  2532. label="联系人电话"
  2533. >
  2534. <Input
  2535. placeholder="请输入联系人电话"
  2536. value={this.state.contactMobile}
  2537. style={{ width: "200px" }}
  2538. onChange={e => {
  2539. this.setState({ contactMobile: e.target.value });
  2540. }}
  2541. ref="commodityQuantity"
  2542. />
  2543. </FormItem>
  2544. <FormItem
  2545. className="half-item"
  2546. {...formItemLayout}
  2547. label="企业地址"
  2548. >
  2549. <Cascader
  2550. options={areaSelect()}
  2551. value={this.state.ProvinceCity}
  2552. placeholder="选择城市"
  2553. style={{ width: "200px" }}
  2554. onChange={e => {
  2555. this.setState({ ProvinceCity: e });
  2556. }}
  2557. />
  2558. </FormItem>
  2559. <FormItem
  2560. className="half-item"
  2561. {...formItemLayout}
  2562. label=""
  2563. ></FormItem>
  2564. <FormItem className="half-item" {...formItemLayout} label="">
  2565. <Input
  2566. placeholder="请输入详细地址"
  2567. value={this.state.postalAddress}
  2568. style={{ width: "200px", marginLeft: "12em" }}
  2569. onChange={e => {
  2570. this.setState({ postalAddress: e.target.value });
  2571. }}
  2572. ref="commodityQuantity"
  2573. />
  2574. </FormItem>
  2575. </div>
  2576. {/*<hr style={{border:'1px dashed #aaa', width:"90%",margin:'auto'}}/>*/}
  2577. <div className="clearfix">
  2578. <h3 className="sub-title">项目信息</h3>
  2579. <FormItem
  2580. className="half-item"
  2581. {...formItemLayout}
  2582. label="项目编号"
  2583. >
  2584. <span>{this.state.id}</span>
  2585. </FormItem>
  2586. <FormItem
  2587. className="half-item"
  2588. {...formItemLayout}
  2589. label="项目名称"
  2590. >
  2591. <span>{this.state.taskName}</span>
  2592. </FormItem>
  2593. <FormItem
  2594. className="half-item"
  2595. {...formItemLayout}
  2596. label="项目状态"
  2597. >
  2598. <Select
  2599. placeholder="选择项目状态"
  2600. style={{ width: "200px" }}
  2601. value={this.state.taskStatus}
  2602. onChange={e => {
  2603. this.setState({ taskStatus: e });
  2604. }}
  2605. >
  2606. {taskStatus.map(function(item) {
  2607. return (
  2608. <Select.Option key={item.value}>{item.key}</Select.Option>
  2609. );
  2610. })}
  2611. </Select>
  2612. </FormItem>
  2613. <FormItem
  2614. className="half-item"
  2615. {...formItemLayout}
  2616. label="项目类别"
  2617. >
  2618. <span>{this.state.cname}</span>
  2619. </FormItem>
  2620. <FormItem
  2621. className="half-item"
  2622. {...formItemLayout}
  2623. label="证书编号"
  2624. >
  2625. <Input
  2626. placeholder="请输入证书编号"
  2627. value={this.state.certificateNumber}
  2628. style={{ width: "200px" }}
  2629. onChange={e => {
  2630. this.setState({ certificateNumber: e.target.value });
  2631. }}
  2632. ref="commodityQuantity"
  2633. />
  2634. </FormItem>
  2635. </div>
  2636. <div className="clearfix" style={{ marginTop: "10px" }}>
  2637. <FormItem
  2638. labelCol={{ span: 3 }}
  2639. wrapperCol={{ span: 14 }}
  2640. label="附件"
  2641. >
  2642. <Picture
  2643. fileList={e => {
  2644. this.setState({ attachmentUrl: e });
  2645. }}
  2646. pictureUrl={this.state.attachmentUrl}
  2647. visible={this.props.visible}
  2648. data={{
  2649. sign: "order_task_file",
  2650. url: "/api/admin/orderProject/uploadOrderTaskFile",
  2651. number: 8
  2652. }}
  2653. />
  2654. </FormItem>
  2655. </div>
  2656. <div className="clearfix">
  2657. <FormItem
  2658. labelCol={{ span: 3 }}
  2659. wrapperCol={{ span: 16 }}
  2660. label="备注"
  2661. >
  2662. <Input
  2663. type="textarea"
  2664. placeholder="请输入备注"
  2665. rows={4}
  2666. value={this.state.taskComment}
  2667. onChange={e => {
  2668. this.setState({ taskComment: e.target.value });
  2669. }}
  2670. />
  2671. </FormItem>
  2672. </div>
  2673. <div className="clearfix">
  2674. <h3 className="sub-title">项目申报进度</h3>
  2675. <FormItem
  2676. className="half-item"
  2677. {...formItemLayout}
  2678. label="启动时间"
  2679. >
  2680. <DatePicker
  2681. style={{ marginTop: "5px" }}
  2682. showTime
  2683. format="YYYY-MM-DD"
  2684. onOk={() => {}}
  2685. value={
  2686. this.state.startDate ? moment(this.state.startDate) : null
  2687. }
  2688. onChange={(data, dataString) => {
  2689. this.setState({ startDate: dataString });
  2690. }}
  2691. />
  2692. </FormItem>
  2693. <FormItem
  2694. className="half-item"
  2695. {...formItemLayout}
  2696. label="软著派单数量"
  2697. >
  2698. <span>{this.state.commodityQuantity}</span>
  2699. <Button
  2700. type="primary"
  2701. size="small"
  2702. style={{ marginLeft: "45px" }}
  2703. onClick={this.addcontact}
  2704. >
  2705. +增加下证信息
  2706. </Button>
  2707. </FormItem>
  2708. <div className="patent-table">
  2709. <Spin spinning={this.state.loading}>
  2710. <Table
  2711. columns={this.state.ContactsLists}
  2712. dataSource={this.state.contactList}
  2713. pagination={false}
  2714. bordered
  2715. size="small"
  2716. />
  2717. </Spin>
  2718. </div>
  2719. </div>
  2720. <div className="clearfix">
  2721. <h3 className="sub-title">项目业务</h3>
  2722. <div className="patent-table">
  2723. <Spin spinning={this.state.loading}>
  2724. <Table
  2725. columns={this.state.columnsX}
  2726. dataSource={this.state.dataSourceX}
  2727. pagination={this.state.paginations}
  2728. onRowClick={this.tableRowClickX}
  2729. bordered
  2730. size="small"
  2731. />
  2732. </Spin>
  2733. </div>
  2734. </div>
  2735. <div className="clearfix">
  2736. <Button
  2737. className="cancel"
  2738. type="primary"
  2739. onClick={this.tijiaoOk}
  2740. style={{ marginLeft: "200px", marginTop: "10px" }}
  2741. htmlType="submit"
  2742. >
  2743. 保存
  2744. </Button>
  2745. <Button
  2746. className="cancel"
  2747. type="ghost"
  2748. onClick={this.visitCancel}
  2749. style={{ marginLeft: "50px", marginTop: "10px" }}
  2750. >
  2751. 取消
  2752. </Button>
  2753. </div>
  2754. </Modal>
  2755. <Modal
  2756. width="800px"
  2757. visible={this.state.visibleA}
  2758. onCancel={this.visitCancelA}
  2759. title="操作日志"
  2760. footer=""
  2761. className="admin-desc-content"
  2762. >
  2763. <div className="patent-table patent-table-center">
  2764. <Spin spinning={this.state.loading}>
  2765. <Table
  2766. columns={this.state.columnsA}
  2767. dataSource={this.state.dataSourceA}
  2768. pagination={false}
  2769. bordered
  2770. size="small"
  2771. />
  2772. </Spin>
  2773. </div>
  2774. </Modal>
  2775. <Modal
  2776. title="工时记录"
  2777. visible={this.state.timeVisible}
  2778. onCancel={this.timeClose}
  2779. width={800}
  2780. footer={null}
  2781. >
  2782. <Spin spinning={this.state.loading}>
  2783. <Table
  2784. columns={this.state.columnsTime}
  2785. dataSource={this.state.dataSourceTime}
  2786. pagination={false}
  2787. scroll={{ x: "max-content", y: 0 }}
  2788. bordered
  2789. size={"small"}
  2790. />
  2791. <p style={{ marginTop: 10, color: "red" }}>
  2792. 累计工时(小时):{this.state.recordHour}
  2793. </p>
  2794. </Spin>
  2795. </Modal>
  2796. </div>
  2797. );
  2798. }
  2799. });
  2800. export default Task;