projectAssignment.jsx 57 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import moment from "moment";
  4. import "../../order/userMangagement.less";
  5. import { boutique } from "../../../dataDic.js";
  6. import "@/manageCenter/financialManage/distribute/public.less";
  7. import ProjectDetailsReadOnly from '../../../common/projectDetailsReadOnly';
  8. import ResolutionDetail from "@/resolutionDetail";
  9. import {
  10. Button,
  11. Form,
  12. Input,
  13. Select,
  14. Spin,
  15. Table,
  16. Switch,
  17. message,
  18. DatePicker,
  19. Modal,
  20. AutoComplete, Tag, Tabs, Radio, Tooltip,
  21. } from "antd";
  22. import Assign from "@/manageCenter/publicComponent/assign";
  23. import {
  24. getProcessStatus,
  25. getApproval,
  26. getLiquidationStatus,
  27. getApprovedState,
  28. splitUrl,
  29. getboutique,
  30. ShowModal,
  31. getProjectName,
  32. } from "@/tools";
  33. import ImgList from "../../../common/imgList";
  34. import PicturesWall from "../../order/orderNew/changeComponent/picturesWall";
  35. import ShowModalDiv from "@/showModal.jsx";
  36. import OrderRiZi from "@/orderRiZi.jsx";
  37. import { ChooseList } from "../../order/orderNew/chooseList";
  38. import ProjectOperation from "../../../common/projectOperation";
  39. import NewAddProject from "../../../common/projectOperation/newAddProject"
  40. import NewEditProject from "../../../common/projectOperation/newEditProject"
  41. import OrderCoor from "../../order/orderNew/changeComponent/orderCoor";
  42. import ContentUrl from "../../order/orderNew/contentUrl";
  43. import { salesList } from "@/dataDic.js";
  44. import Cascaders from "../../../common/cascaders";
  45. import FlowChart from '../../../common/flowchart'; // 流程图
  46. import Gxczx from '../../../common/orderDetail/gxczx' // 高新纯咨询合同说明详情
  47. const { TabPane } = Tabs
  48. const PaiDan = React.createClass({
  49. loadData(pageNo) {
  50. this.state.data = [];
  51. this.setState({
  52. loading: true
  53. });
  54. $.ajax({
  55. method: "get",
  56. dataType: "json",
  57. crossDomain: false,
  58. url: globalConfig.context + "/api/admin/newOrder/orderNewList",
  59. data: {
  60. pageNo: pageNo || 1,
  61. pageSize: this.state.pagination.pageSize,
  62. specially: 4, //咨询师管理列表
  63. distribution: this.state.distribution, //全部列表
  64. name: this.state.customerName, //名称
  65. deps: this.state.departmenttSearch, //订单部门
  66. orderNo: this.state.orderNoSearch, //订单编号
  67. starTime: this.state.releaseDate[0], //开始时间
  68. endTime: this.state.releaseDate[1], //结束时间
  69. outsource: 0
  70. },
  71. success: function (data) {
  72. ShowModal(this);
  73. let theArr = [];
  74. if (!data.data || !data.data.list) {
  75. if (data.error && data.error.length) {
  76. message.warning(data.error[0].message);
  77. }
  78. } else {
  79. for (let i = 0; i < data.data.list.length; i++) {
  80. let thisdata = data.data.list[i];
  81. theArr.push({
  82. key: i,
  83. id: thisdata.id, //任务ID
  84. orderNo: thisdata.orderNo, //订单编号
  85. totalAmount: thisdata.totalAmount, //签单金额
  86. processStatus: thisdata.processStatus, //流程状态
  87. liquidationStatus: thisdata.liquidationStatus, //结算状态
  88. approval: thisdata.approval, //特批状态
  89. signDate: thisdata.signDate, //签单时间
  90. userName: thisdata.userName, //客户名称
  91. salesmanName: thisdata.salesmanName, //营销员名称
  92. financeName: thisdata.financeName, //财务名称
  93. consultantName: thisdata.consultantName, //项目负责人
  94. createDate: thisdata.createDate, //下单时间
  95. settlementAmount: thisdata.settlementAmount, //已交款项
  96. depName: thisdata.depName, //部门名称
  97. ischange: thisdata.ischange //是否通过变更生成的
  98. });
  99. }
  100. }
  101. this.state.pagination.current = data.data.pageNo;
  102. this.state.pagination.total = data.data.totalCount;
  103. if (data.data && data.data.list && !data.data.list.length) {
  104. this.state.pagination.current = 0;
  105. this.state.pagination.total = 0;
  106. }
  107. this.setState({
  108. page: data.data.pageNo,
  109. dataSource: theArr,
  110. pagination: this.state.pagination
  111. });
  112. }.bind(this)
  113. }).always(
  114. function () {
  115. this.setState({
  116. loading: false
  117. });
  118. }.bind(this)
  119. );
  120. },
  121. getInitialState() {
  122. return {
  123. distribution: "0",
  124. activeKey: "1",
  125. customerArr: [],
  126. orderNos: '',
  127. searchMore: true,
  128. visible: false,
  129. assignVisible: false,
  130. releaseDate: [],
  131. departmentArr: [],
  132. declarationBatch: 1,
  133. boHuivisible: false,
  134. selectedRowKeys: [],
  135. resVisible: false,
  136. selectedRows: [],
  137. loading: false,
  138. dataInfor: {},
  139. paginations: false,
  140. page: 1,
  141. pagination: {
  142. defaultCurrent: 1,
  143. defaultPageSize: 10,
  144. showQuickJumper: true,
  145. pageSize: 10,
  146. onChange: function (page) {
  147. this.loadData(page);
  148. }.bind(this),
  149. showTotal: function (total) {
  150. return "共" + total + "条数据";
  151. }
  152. },
  153. columns: [
  154. {
  155. title: "订单编号",
  156. dataIndex: "orderNo",
  157. key: "orderNo",
  158. render: (text, record) => {
  159. if (record.ischange == 1) {
  160. return (
  161. <span>
  162. <Tag color="#f50">变更</Tag>
  163. {text}
  164. </span>
  165. );
  166. } else {
  167. return <span>{text}</span>;
  168. }
  169. }
  170. },
  171. {
  172. title: "签单客户",
  173. dataIndex: "userName",
  174. key: "userName"
  175. },
  176. {
  177. title: "下单时间",
  178. dataIndex: "createDate",
  179. key: "createDate"
  180. },
  181. {
  182. title: "签单时间",
  183. dataIndex: "signDate",
  184. key: "signDate"
  185. },
  186. {
  187. title: "订单总金额(万)",
  188. dataIndex: "totalAmount",
  189. key: "totalAmount"
  190. },
  191. {
  192. title: "是否特批",
  193. dataIndex: "approval",
  194. key: "approval",
  195. render: text => {
  196. return getApproval(text);
  197. }
  198. },
  199. {
  200. title: "订单负责人",
  201. dataIndex: "salesmanName",
  202. key: "salesmanName"
  203. },
  204. {
  205. title: "订单部门",
  206. dataIndex: "depName",
  207. key: "depName"
  208. },
  209. {
  210. title: "财务负责人",
  211. dataIndex: "financeName",
  212. key: "financeName"
  213. },
  214. {
  215. title: "项目负责人",
  216. dataIndex: "consultantName",
  217. key: "consultantName"
  218. },
  219. {
  220. title: "分派状态",
  221. dataIndex: "processStatus",
  222. key: "processStatus",
  223. render: (text, record) => {
  224. return text == 6 || text == 7 ? getProcessStatus(text, record.examineName, record.approval) : "未分配";
  225. }
  226. },
  227. {
  228. title: "操作",
  229. dataIndex: "caozuo",
  230. key: "caouzo",
  231. render: (text, record) => {
  232. return (
  233. <div>
  234. {record.settlementAmount == 0 ? (
  235. <Button
  236. type="primary"
  237. style={{ margin: "0 10px" }}
  238. onClick={e => {
  239. e.stopPropagation(), this.examNo(record);
  240. }}
  241. >
  242. 驳回
  243. </Button>
  244. ) : (
  245. ""
  246. )}
  247. </div>
  248. );
  249. }
  250. }
  251. ],
  252. columnsrizhi: [
  253. {
  254. title: "流程",
  255. dataIndex: "processName",
  256. key: "processName"
  257. },
  258. {
  259. title: "操作人",
  260. dataIndex: "adminName",
  261. key: "adminName"
  262. },
  263. {
  264. title: "时间",
  265. dataIndex: "createDate",
  266. key: "createDate"
  267. },
  268. {
  269. title: "备注",
  270. dataIndex: "remarks",
  271. key: "remarks"
  272. }
  273. ],
  274. dataSource: [],
  275. searchTime: [],
  276. columnsX: [
  277. {
  278. title: "业务项目名称",
  279. dataIndex: "commodityName",
  280. key: "commodityName",
  281. render: (text, record) => {
  282. return (
  283. <span>
  284. {record.change == 1 && <Tag color="#f50">增</Tag>}
  285. {text}
  286. <span style={{ color: "red" }}>{record.patentTypeName}</span></span>
  287. )
  288. }
  289. },
  290. {
  291. title: "项目类别",
  292. dataIndex: "cname",
  293. key: "cname",
  294. },
  295. {
  296. title: "项目数量",
  297. dataIndex: "commodityQuantity",
  298. key: "commodityQuantity",
  299. render: (text, record) => {
  300. if (record.splitStatus == 1) {
  301. return (
  302. <span>
  303. {text}{" "}
  304. {/* {
  305. record.cSort != 6 &&
  306. <Tag
  307. color="#108ee9"
  308. onClick={e => {
  309. e.stopPropagation();
  310. this.showRes(record);
  311. }}
  312. >
  313. 已拆
  314. </Tag>
  315. } */}
  316. </span>
  317. );
  318. } else {
  319. return text;
  320. }
  321. }
  322. },
  323. {
  324. title: "金额(万元)",
  325. dataIndex: "commodityPrice",
  326. key: "commodityPrice",
  327. width: 80,
  328. },
  329. {
  330. title: "负责人",
  331. dataIndex: "contacts",
  332. key: "contacts",
  333. },
  334. {
  335. title: "负责人电话",
  336. dataIndex: "contactsMobile",
  337. key: "contactsMobile",
  338. },
  339. {
  340. title: "主要项目",
  341. dataIndex: "main",
  342. key: "main",
  343. width: 50,
  344. render: text => {
  345. return text ? "是" : "否";
  346. }
  347. },
  348. {
  349. title: "总年限",
  350. dataIndex: "yearSum",
  351. key: "yearSum",
  352. render: (text, record) => {
  353. return (
  354. <div>{["", "一年", "二年", "三年", "四年", "五年"][text]}</div>
  355. );
  356. }
  357. },
  358. {
  359. title: "年限",
  360. dataIndex: "serviceLife",
  361. key: "serviceLife",
  362. render: (text, record) => {
  363. return (
  364. <div>{!!text && JSON.parse(text).toString()}</div>
  365. );
  366. }
  367. },
  368. {
  369. title: "本次派单",
  370. dataIndex: "serviceYear",
  371. key: "serviceYear",
  372. render: (text, record) => {
  373. return (
  374. <div>{!text ? "" : text}</div>
  375. );
  376. }
  377. },
  378. {
  379. title: "项目说明",
  380. dataIndex: "taskComment",
  381. key: "taskComment",
  382. render: (text) => {
  383. return (
  384. <Tooltip title={text}>
  385. <div
  386. style={{
  387. width: 100,
  388. overflow: "hidden",
  389. whiteSpace: "nowrap",
  390. textOverflow: "ellipsis",
  391. }}
  392. >{text}</div>
  393. </Tooltip>
  394. )
  395. },
  396. },
  397. {
  398. title: "操作",
  399. dataIndex: "caozuo",
  400. key: "caouzo",
  401. width: 100,
  402. render: (text, record) => {
  403. return (
  404. <div>
  405. {(this.state.processStatus == 5 || record.taskStatus == 0) && record.cSort != 6 &&
  406. <Button
  407. type="primary"
  408. onClick={e => {
  409. e.stopPropagation(), this.evaluate(record);
  410. }}
  411. >
  412. 分配任务
  413. </Button>
  414. }
  415. </div>
  416. );
  417. }
  418. }
  419. ],
  420. dataSourceX: []
  421. };
  422. },
  423. /* 分派 */
  424. evaluate(record) {
  425. this.state.assignData = record;
  426. this.setState({
  427. assignVisible: true
  428. });
  429. },
  430. componentWillMount() {
  431. // this.departmentList();
  432. this.loadData();
  433. },
  434. tableRowClick(record) {
  435. this.state.RowData = record;
  436. this.setState({
  437. displayFees: "block",
  438. visible: true,
  439. orderNos: record.orderNo
  440. });
  441. this.xiangqing(record.orderNo);
  442. this.xiangmu(record.orderNo);
  443. this.jiedian(record.orderNo);
  444. },
  445. //审核不通过
  446. examOks() {
  447. if (this.state.flag) return;
  448. if (!this.state.reason) {
  449. message.warning("请填写拒绝理由");
  450. return;
  451. }
  452. if (!this.state.reason.replace(/\s+/g, '')) {
  453. message.warning("请填写拒绝理由~");
  454. return;
  455. }
  456. this.setState({
  457. flag: true
  458. });
  459. $.ajax({
  460. method: "post",
  461. dataType: "json",
  462. crossDomain: false,
  463. url: globalConfig.context + "/api/admin/newOrder/technicianBackOrder",
  464. data: {
  465. orderNo: this.state.orderNo,
  466. reason: this.state.reason
  467. },
  468. success: function (data) {
  469. if (data.error.length || data.data == "") {
  470. if (data.error && data.error.length) {
  471. message.warning(data.error[0].message);
  472. this.setState({
  473. flag: false
  474. });
  475. }
  476. } else {
  477. message.success("该订单已被驳回~");
  478. this.setState({
  479. visible: false,
  480. noVisible: false,
  481. reason: "",
  482. flag: false
  483. });
  484. this.reset();
  485. }
  486. }.bind(this)
  487. }).always(
  488. function () {
  489. this.setState({
  490. loading: false
  491. });
  492. }.bind(this)
  493. );
  494. },
  495. //点击拒绝
  496. examNo(record) {
  497. this.setState({
  498. noVisible: true,
  499. orderNo: record.orderNo
  500. });
  501. },
  502. //关闭输入理由框
  503. noCancel() {
  504. this.setState({
  505. noVisible: false,
  506. reason: ""
  507. });
  508. },
  509. // 拆分详细
  510. showRes(record) {
  511. this.setState({
  512. resVisible: true,
  513. resRecord: record
  514. });
  515. },
  516. resCancel() {
  517. this.setState({
  518. resVisible: false
  519. });
  520. },
  521. //订单详情
  522. xiangqing(orderNos) {
  523. $.ajax({
  524. method: "get",
  525. dataType: "json",
  526. crossDomain: false,
  527. url: globalConfig.context + "/api/admin/newOrder/getOrderNewDetail",
  528. data: {
  529. orderNo: orderNos
  530. },
  531. success: function (data) {
  532. if (data.error.length || data.data.list == "") {
  533. if (data.error && data.error.length) {
  534. message.warning(data.error[0].message);
  535. }
  536. } else {
  537. let thisdata = data.data;
  538. this.setState({
  539. userType: thisdata.userType,
  540. salesType: thisdata.salesType,
  541. other: thisdata.other,
  542. orderNo: thisdata.orderNo, //订单编号
  543. contractNo: thisdata.contractNo, //合同编号
  544. userName: thisdata.userName, //客户名称
  545. depName: thisdata.depName, //订单部门
  546. signDate: thisdata.signDate, //签单时间
  547. examineName: thisdata.examineName,
  548. processStatus: thisdata.processStatus, //流程状态
  549. liquidationStatus: thisdata.liquidationStatus, //结算状态
  550. contacts: thisdata.contacts, //企业联系人
  551. contactMobile: thisdata.contactMobile, //联系人电话
  552. legalPerson: thisdata.legalPerson, //法人
  553. legalPersonTel: thisdata.legalPersonTel, //法人电话
  554. firstAmount: thisdata.firstAmount, //签单金额
  555. totalAmount: thisdata.totalAmount, //首付金额
  556. approval: thisdata.approval, //特批状态
  557. settlementAmount: thisdata.settlementAmount, //已收款项
  558. orderRemarks: thisdata.orderRemarks, //订单留言
  559. orgCodeUrl: thisdata.contractPictureUrl
  560. ? splitUrl(
  561. thisdata.contractPictureUrl,
  562. ",",
  563. globalConfig.avatarHost + "/upload"
  564. )
  565. : [], //图片地址
  566. contentUrl: thisdata.serviceContent
  567. ? splitUrl(
  568. thisdata.serviceContent,
  569. ",",
  570. globalConfig.avatarHost + "/upload"
  571. )
  572. : [], //图片地址
  573. replenishUrl: thisdata.agreementUrl
  574. ? splitUrl(
  575. thisdata.agreementUrl,
  576. ",",
  577. globalConfig.avatarHost + "/upload"
  578. )
  579. : [], //图片地址
  580. salesmanName: thisdata.salesmanName, //营销员名称
  581. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  582. financeName: thisdata.financeName, //财务名称
  583. financeMobile: thisdata.financeMobile, //财务电话
  584. oldSalesmanName: thisdata.oldSalesmanName, //营销员名称
  585. oldSalesmanMobile: thisdata.oldSalesmanMobile, //营销员电话
  586. nowFinance: thisdata.nowFinance, //财务名称
  587. nowFinanceMobile: thisdata.nowFinanceMobile, //财务电话
  588. // 高新纯咨询合同说明
  589. knowledgeServices: thisdata.knowledgeServices, //知识产权服务
  590. auditServices: thisdata.auditServices, //审计服务
  591. addDeductionServices: thisdata.addDeductionServices, //加计扣除服务
  592. knowledgeOther: thisdata.knowledgeOther, //知识产权服务其他描述
  593. auditOther: thisdata.auditOther, //审计服务其他描述
  594. addDeductionOther: thisdata.addDeductionOther, //加计扣除服务其他描述
  595. });
  596. }
  597. }.bind(this)
  598. }).always(
  599. function () {
  600. this.setState({
  601. loading: false
  602. });
  603. }.bind(this)
  604. );
  605. },
  606. //项目列表
  607. xiangmu(orderNos) {
  608. $.ajax({
  609. method: "get",
  610. dataType: "json",
  611. crossDomain: false,
  612. url: globalConfig.context + "/api/admin/newOrder/getOrderTask",
  613. data: {
  614. orderNo: orderNos
  615. },
  616. success: function (data) {
  617. let theArr = [];
  618. if (data.error.length || data.data.list == "") {
  619. if (data.error && data.error.length) {
  620. message.warning(data.error[0].message);
  621. }
  622. } else {
  623. for (let i = 0; i < data.data.length; i++) {
  624. let thisdata = data.data[i];
  625. thisdata.key = i;
  626. theArr.push(thisdata);
  627. }
  628. }
  629. this.setState({
  630. dataSourceX: theArr
  631. });
  632. }.bind(this)
  633. }).always(
  634. function () {
  635. this.setState({
  636. loading: false
  637. });
  638. }.bind(this)
  639. );
  640. },
  641. rizhi() {
  642. // console.log(this.state.orderNo);
  643. this.setState({
  644. loading: true
  645. });
  646. $.ajax({
  647. method: "get",
  648. dataType: "json",
  649. crossDomain: false,
  650. url: "/api/admin/newOrder/selectOrderLog",
  651. data: {
  652. orderNo: this.state.orderNo
  653. },
  654. success: function (data) {
  655. let theArr = [];
  656. let thisData = data.data;
  657. if (!thisData.length) {
  658. if (data.error && data.error.length) {
  659. message.warning(data.error[0].message);
  660. }
  661. thisData = {};
  662. } else {
  663. for (let i = 0; i < data.data.length; i++) {
  664. let thisdata = data.data[i];
  665. theArr.push({
  666. processName: thisdata.processName,
  667. adminName: thisdata.adminName,
  668. createDate: thisdata.createDate,
  669. remarks: thisdata.remarks
  670. });
  671. }
  672. }
  673. this.setState({
  674. dataSourcerizhi: theArr
  675. });
  676. }.bind(this)
  677. }).always(
  678. function () {
  679. this.setState({
  680. loading: false
  681. });
  682. }.bind(this)
  683. );
  684. },
  685. //查看订单日志
  686. getOrderLog() {
  687. this.setState({
  688. rizhivisible: true
  689. });
  690. this.rizhi();
  691. },
  692. closeOrderLog() {
  693. this.setState({
  694. rizhivisible: false
  695. });
  696. },
  697. supervisor(e, state) {
  698. //客户名称与服务名称自动补全
  699. $.ajax({
  700. method: "get",
  701. dataType: "json",
  702. crossDomain: false,
  703. url: "/api/admin/order/getBusinessProjectByName",
  704. data: {
  705. businessName: e
  706. },
  707. success: function (data) {
  708. let thedata = data.data;
  709. if (!thedata) {
  710. if (data.error && data.error.length) {
  711. message.warning(data.error[0].message);
  712. }
  713. thedata = {};
  714. }
  715. this.setState({
  716. states: state,
  717. customerArr: thedata
  718. });
  719. }.bind(this)
  720. }).always(
  721. function () {
  722. this.setState({
  723. loading: false
  724. });
  725. }.bind(this)
  726. );
  727. },
  728. //服务值改变时请求客户名称
  729. httpChange(e) {
  730. this.state.gid = "";
  731. if (e.length >= 1) {
  732. this.supervisor(e, false);
  733. }
  734. this.setState({
  735. commodityName: e
  736. });
  737. },
  738. //上级主管输入框失去焦点是判断客户是否存在
  739. selectAuto(value) {
  740. let kid = [];
  741. let fwList = this.state.customerArr;
  742. fwList.map(function (item) {
  743. if (value == item.bname) {
  744. kid = item;
  745. }
  746. });
  747. if (kid.type === 1) {
  748. this.setState({
  749. displayFees: "block",
  750. });
  751. } else {
  752. this.setState({
  753. displayFees: "none",
  754. });
  755. }
  756. this.setState({
  757. commodityName: value,
  758. gid: kid.id,
  759. //commodityPrice:kid.price==0?kid.price.toString():kid.price,
  760. isIso: value.indexOf("贯标") !== -1,// 是否为贯标项目
  761. addProjectType: kid.type,
  762. commodityFirstPayment:
  763. kid.firstPayment == 0 ? kid.firstPayment.toString() : kid.firstPayment
  764. });
  765. },
  766. //点击添加项目明细
  767. addDetailed() {
  768. this.setState({
  769. projectOperationVisible: true,
  770. newData: this.state.dataSourceX,
  771. });
  772. },
  773. //节点列表
  774. jiedian(orderNos) {
  775. $.ajax({
  776. method: "get",
  777. dataType: "json",
  778. crossDomain: false,
  779. url: globalConfig.context + "/api/admin/newOrder/selectOrderDun",
  780. data: {
  781. orderNo: orderNos
  782. },
  783. success: function (data) {
  784. let theArr = [];
  785. let thisData = [];
  786. if (data.error.length || data.data.list == "") {
  787. if (data.error && data.error.length) {
  788. message.warning(data.error[0].message);
  789. }
  790. } else {
  791. for (let i = 0; i < data.data.length; i++) {
  792. thisData = data.data[i];
  793. theArr.push({
  794. key: i,
  795. dunSubject: thisData.dunSubject
  796. ? thisData.dunSubject.toString()
  797. : "", //催款科目
  798. id: thisData.id, //节点Id
  799. money: thisData.money, //催款金额
  800. dunStatus: thisData.dunStatus //催款状态
  801. });
  802. }
  803. this.setState({
  804. contactList: theArr
  805. });
  806. }
  807. }.bind(this)
  808. }).always(
  809. function () {
  810. this.setState({
  811. loading: false
  812. });
  813. }.bind(this)
  814. );
  815. },
  816. closeDesc(e, s) {
  817. this.state.showDesc = e;
  818. if (s) {
  819. this.loadData(this.state.page);
  820. }
  821. },
  822. closeAssign(e, s) {
  823. this.state.assignVisible = e;
  824. if (s) {
  825. this.loadData(this.state.page);
  826. this.xiangqing(this.state.orderNo);
  827. this.xiangmu(this.state.orderNo);
  828. this.jiedian(this.state.orderNo);
  829. }
  830. },
  831. search() {
  832. this.loadData();
  833. },
  834. reset() {
  835. this.state.nameSearch = "";
  836. this.state.customerName = "";
  837. this.state.releaseDate = [];
  838. this.state.orderNoSearch = "";
  839. this.state.departmenttSearch = undefined;
  840. this.state.distribution = undefined;
  841. this.Cascaders.empty();
  842. this.loadData(this.state.page);
  843. },
  844. nextCancel() {
  845. this.setState({
  846. infoVisible: false,
  847. projectOperationVisible: false,
  848. dataInfor: {},
  849. }, () => {
  850. this.xiangmu(this.state.orderNo);
  851. });
  852. },
  853. //点击打卡项目详情
  854. tableRowClickX(record) {
  855. this.setState({
  856. infoVisible: true,
  857. dataInfor: record,
  858. });
  859. },
  860. searchSwitch() {
  861. this.setState({
  862. searchMore: !this.state.searchMore
  863. });
  864. },
  865. //关闭详情
  866. visitCancel() {
  867. this.setState({
  868. visible: false
  869. });
  870. this.loadData(this.state.page);
  871. },
  872. visitOk() {
  873. this.setState({
  874. visible: false
  875. });
  876. this.loadData(this.state.page);
  877. },
  878. resets() {
  879. this.state.orderNo = "";
  880. this.state.customerName = "";
  881. this.state.departmenttSearch = undefined;
  882. this.state.releaseDate[0] = undefined;
  883. this.state.releaseDate[1] = undefined;
  884. this.Cascaders.empty();
  885. },
  886. //部门
  887. departmentList() {
  888. this.setState({
  889. loading: true
  890. });
  891. $.ajax({
  892. method: "get",
  893. dataType: "json",
  894. crossDomain: false,
  895. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  896. data: {},
  897. success: function (data) {
  898. let thedata = data.data;
  899. let theArr = [];
  900. if (!thedata) {
  901. if (data.error && data.error.length) {
  902. message.warning(data.error[0].message);
  903. }
  904. thedata = {};
  905. } else {
  906. thedata.map(function (item, index) {
  907. theArr.push({
  908. key: index,
  909. name: item.name,
  910. id: item.id
  911. });
  912. });
  913. }
  914. this.setState({
  915. departmentArr: theArr
  916. });
  917. }.bind(this)
  918. }).always(
  919. function () {
  920. this.setState({
  921. loading: false
  922. });
  923. }.bind(this)
  924. );
  925. },
  926. changeList(arr) {
  927. const newArr = [];
  928. this.state.columns.forEach(item => {
  929. arr.forEach(val => {
  930. if (val === item.title) {
  931. newArr.push(item);
  932. }
  933. });
  934. });
  935. this.setState({
  936. changeList: newArr
  937. });
  938. },
  939. downImg() {
  940. let num = 0;
  941. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  942. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  943. num = i;
  944. }
  945. }
  946. if (num == this.state.orgCodeUrl.length - 1) {
  947. return message.warning("已经是最后一张了哦");
  948. }
  949. this.state.previewImage = this.state.orgCodeUrl[num + 1].url;
  950. this.setState({
  951. previewImage: this.state.previewImage,
  952. rotateDeg: 0,
  953. });
  954. },
  955. upImg() {
  956. let num = 0;
  957. for (let i = 0; i < this.state.orgCodeUrl.length; i++) {
  958. if (this.state.orgCodeUrl[i].url == this.state.previewImage) {
  959. num = i;
  960. }
  961. }
  962. if (num == 0) {
  963. return message.warning("已经是第一张了哦");
  964. }
  965. this.state.previewImage = this.state.orgCodeUrl[num - 1].url;
  966. this.setState({
  967. previewImage: this.state.previewImage,
  968. rotateDeg: 0,
  969. });
  970. },
  971. rotate() {
  972. let rotateDeg = this.state.rotateDeg + 90;
  973. this.setState({
  974. rotateDeg,
  975. });
  976. },
  977. downImgs() {
  978. let num = 0;
  979. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  980. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  981. num = i;
  982. }
  983. }
  984. if (num == this.state.replenishUrl.length - 1) {
  985. return message.warning("已经是最后一张了哦");
  986. }
  987. this.state.previewImage = this.state.replenishUrl[num + 1].url;
  988. this.setState({
  989. previewImage: this.state.previewImage,
  990. rotateDeg: 0,
  991. });
  992. },
  993. upImgs() {
  994. let num = 0;
  995. for (let i = 0; i < this.state.replenishUrl.length; i++) {
  996. if (this.state.replenishUrl[i].url == this.state.previewImage) {
  997. num = i;
  998. }
  999. }
  1000. if (num == 0) {
  1001. return message.warning("已经是第一张了哦");
  1002. }
  1003. this.state.previewImage = this.state.replenishUrl[num - 1].url;
  1004. this.setState({
  1005. previewImage: this.state.previewImage,
  1006. rotateDeg: 0,
  1007. });
  1008. },
  1009. rotates() {
  1010. let rotateDeg = this.state.rotateDeg + 90;
  1011. this.setState({
  1012. rotateDeg,
  1013. });
  1014. },
  1015. getOrgCodeUrl(e) {
  1016. this.setState({ orgCodeUrl: e });
  1017. },
  1018. getReplenishUrl(e) {
  1019. this.setState({ replenishUrl: e });
  1020. },
  1021. // getVoucherUrl(e) {
  1022. // this.setState({ voucherUrl: e });
  1023. // },
  1024. // 可展开颜色不同
  1025. addRowColor(record) {
  1026. if (!!record.splitList && record.splitList.length > 0) {
  1027. return 'light'
  1028. } else {
  1029. return 'dark'
  1030. }
  1031. },
  1032. render() {
  1033. const expandedRowRenderVip = (e) => {
  1034. const data = e.splitList;
  1035. let columns = [];
  1036. if (data instanceof Array && data.length) {
  1037. if (e.cSort == 6) {
  1038. columns = [
  1039. {
  1040. title: "负责人",
  1041. dataIndex: "receiverName",
  1042. key: "receiverName",
  1043. },
  1044. {
  1045. title: "负责人电话",
  1046. dataIndex: "receiverMobile",
  1047. key: "receiverMobile",
  1048. },
  1049. {
  1050. title: "项目状态",
  1051. dataIndex: "projectStatus",
  1052. key: "projectStatus",
  1053. render: (text) => {
  1054. return getProjectName(text);
  1055. },
  1056. },
  1057. {
  1058. title: "本次派单",
  1059. dataIndex: "serviceYear",
  1060. key: "serviceYear",
  1061. },
  1062. {
  1063. title: "项目说明",
  1064. dataIndex: "taskComment",
  1065. key: "taskComment",
  1066. render: (text) => {
  1067. return (
  1068. <Tooltip title={text}>
  1069. <div
  1070. // style={{
  1071. // width: 100,
  1072. // overflow: "hidden",
  1073. // whiteSpace: "nowrap",
  1074. // textOverflow: "ellipsis",
  1075. // }}
  1076. >{text}</div>
  1077. </Tooltip>
  1078. )
  1079. },
  1080. },
  1081. {
  1082. title: "操作",
  1083. dataIndex: "caozuo",
  1084. key: "caouzo",
  1085. width: 100,
  1086. render: (text, record) => {
  1087. return (
  1088. <div>
  1089. {(this.state.processStatus == 5 || record.taskStatus == 0) &&
  1090. <Button
  1091. type="primary"
  1092. onClick={e => {
  1093. e.stopPropagation(), this.evaluate(record);
  1094. }}
  1095. >
  1096. 分配任务
  1097. </Button>
  1098. }
  1099. </div>
  1100. );
  1101. }
  1102. }
  1103. ];
  1104. } else {
  1105. columns = [
  1106. {
  1107. title: "子项目名称",
  1108. dataIndex: "taskName",
  1109. key: "taskName"
  1110. },
  1111. {
  1112. title: "子项目数量",
  1113. dataIndex: "commodityQuantity",
  1114. key: "commodityQuantity"
  1115. },
  1116. {
  1117. title: "拆分操作人",
  1118. dataIndex: "splitAname",
  1119. key: "splitAname"
  1120. },
  1121. {
  1122. title: "项目负责人",
  1123. dataIndex: "receiverName",
  1124. key: "receiverName"
  1125. },
  1126. {
  1127. title: "拆分时间",
  1128. dataIndex: "splitTimes",
  1129. key: "splitTimes"
  1130. }
  1131. ]
  1132. }
  1133. return (
  1134. <Table
  1135. columns={columns}
  1136. dataSource={data}
  1137. pagination={false}
  1138. />
  1139. );
  1140. } else {
  1141. columns = [];
  1142. return (
  1143. <p
  1144. style={{ fontWeight: "bold", color: "red", textAlign: "center" }}
  1145. >
  1146. {e.cSort == 6 ? "暂无派单" : "此项目暂未拆分"}
  1147. </p>
  1148. );
  1149. }
  1150. };
  1151. const rowSelection = {
  1152. selectedRowKeys: this.state.selectedRowKeys,
  1153. onChange: (selectedRowKeys, selectedRows) => {
  1154. this.setState({
  1155. selectedRows: selectedRows.slice(-1),
  1156. selectedRowKeys: selectedRowKeys.slice(-1)
  1157. });
  1158. }
  1159. };
  1160. const formItemLayout = {
  1161. labelCol: { span: 10 },
  1162. wrapperCol: { span: 14 }
  1163. };
  1164. const dataSources = this.state.customerArr || [];
  1165. const options = dataSources.map((group, index) => (
  1166. <Select.Option key={index} value={group.bname}>
  1167. {group.bname}
  1168. </Select.Option>
  1169. ));
  1170. const FormItem = Form.Item;
  1171. const { RangePicker } = DatePicker;
  1172. let departmentArr = this.state.departmentArr || [];
  1173. return (
  1174. <div className="user-content">
  1175. {this.state.resVisible ? (
  1176. <ResolutionDetail
  1177. cancel={this.resCancel}
  1178. detail={this.state.resRecord}
  1179. visible={this.state.resVisible}
  1180. id={this.state.resRecord.orderNo}
  1181. />
  1182. ) : (
  1183. ""
  1184. )}
  1185. <ShowModalDiv ShowModal={this.state.showModal} />
  1186. <div className="content-title" style={{ marginBottom: 10 }}>
  1187. <span style={{ fontWeight: 900, fontSize: 16 }}>项目派单管理</span>
  1188. </div>
  1189. <Tabs defaultActiveKey="1" onChange={this.callback} className="test">
  1190. <TabPane tab="搜索" key="1">
  1191. <div className="user-search">
  1192. <Input
  1193. placeholder="订单编号"
  1194. value={this.state.orderNoSearch}
  1195. onChange={(e) => {
  1196. this.setState({ orderNoSearch: e.target.value });
  1197. }}
  1198. />
  1199. <Input
  1200. placeholder="客户名称"
  1201. value={this.state.customerName}
  1202. style={{ marginLeft: 10 }}
  1203. onChange={(e) => {
  1204. this.setState({ customerName: e.target.value });
  1205. }}
  1206. />
  1207. <Cascaders
  1208. ref={node => this.Cascaders = node}
  1209. placeholder="选择部门"
  1210. id="id"
  1211. name="name"
  1212. children="list"
  1213. height={28}
  1214. onSel={(e) => {
  1215. this.setState({
  1216. departmenttSearch: JSON.stringify(e),
  1217. });
  1218. }}
  1219. />
  1220. {/* <Select
  1221. placeholder="选择部门"
  1222. style={{ width: 200, marginRight: "10px" }}
  1223. value={this.state.departmenttSearch}
  1224. onChange={(e) => {
  1225. this.setState({ departmenttSearch: e });
  1226. }}
  1227. >
  1228. {departmentArr.map(function (item) {
  1229. return (
  1230. <Select.Option key={item.id}>{item.name}</Select.Option>
  1231. );
  1232. })}
  1233. </Select> */}
  1234. <Select
  1235. onChange={(e) => {
  1236. this.setState({ distribution: e });
  1237. }}
  1238. style={{ width: 160, marginRight: 5 }}
  1239. placeholder="分派状态"
  1240. value={this.state.distribution}
  1241. >
  1242. <Option value="0">未分配</Option>
  1243. <Option value="1">部分分配</Option>
  1244. <Option value="2">全部分配</Option>
  1245. </Select>
  1246. <Button type="primary" onClick={this.search}>
  1247. 搜索
  1248. </Button>
  1249. <Button onClick={this.reset}>重置</Button>
  1250. <span>
  1251. 更多搜索
  1252. <Switch
  1253. defaultChecked={false}
  1254. onChange={this.searchSwitch.bind(this)}
  1255. />
  1256. </span>
  1257. <div
  1258. className="search-more"
  1259. style={this.state.searchMore ? { display: "none" } : {}}
  1260. >
  1261. <span>订单时间 :</span>
  1262. <RangePicker
  1263. value={[
  1264. this.state.releaseDate[0]
  1265. ? moment(this.state.releaseDate[0])
  1266. : null,
  1267. this.state.releaseDate[1]
  1268. ? moment(this.state.releaseDate[1])
  1269. : null,
  1270. ]}
  1271. onChange={(data, dataString) => {
  1272. this.setState({ releaseDate: dataString });
  1273. }}
  1274. />
  1275. </div>
  1276. </div>
  1277. </TabPane>
  1278. <TabPane tab="更改表格显示数据" key="2">
  1279. <div style={{ marginLeft: 10 }}>
  1280. <ChooseList
  1281. columns={this.state.columns}
  1282. changeFn={this.changeList}
  1283. changeList={this.state.changeList}
  1284. top={55}
  1285. margin={11}
  1286. />
  1287. </div>
  1288. </TabPane>
  1289. </Tabs>
  1290. <div className="patent-table">
  1291. <Spin spinning={this.state.loading}>
  1292. <Table
  1293. columns={
  1294. this.state.changeList
  1295. ? this.state.changeList
  1296. : this.state.columns
  1297. }
  1298. style={{
  1299. cursor: 'pointer',
  1300. }}
  1301. dataSource={this.state.dataSource}
  1302. pagination={this.state.pagination}
  1303. onRowClick={this.tableRowClick.bind(this)}
  1304. bordered
  1305. size="small"
  1306. />
  1307. </Spin>
  1308. </div>
  1309. <Assign
  1310. title="项目"
  1311. type={0}
  1312. selApi="/api/admin/orderProject/projectDistribution"
  1313. data={this.state.assignData}
  1314. showDesc={this.state.assignVisible}
  1315. closeDesc={this.closeAssign.bind(this)}
  1316. fenpaiData={8}
  1317. roleName={"咨询师经理"}
  1318. requestMethod={"post"}
  1319. reset={this.reset}
  1320. />
  1321. {this.state.visible ?
  1322. <Modal
  1323. className="customeDetails"
  1324. footer=""
  1325. title="订单详情"
  1326. width="1200px"
  1327. visible={this.state.visible}
  1328. onOk={this.visitOk}
  1329. onCancel={this.visitCancel}
  1330. >
  1331. <Form
  1332. layout="horizontal"
  1333. onSubmit={this.handleSubmit}
  1334. id="demand-form"
  1335. style={{ paddingBottom: "40px" }}
  1336. >
  1337. <Spin spinning={this.state.loading}>
  1338. <div className="clearfix">
  1339. <FormItem
  1340. className="half-item"
  1341. {...formItemLayout}
  1342. label="订单编号"
  1343. >
  1344. <span>{this.state.orderNo}</span>
  1345. </FormItem>
  1346. <FormItem
  1347. className="half-item"
  1348. {...formItemLayout}
  1349. label="合同编号"
  1350. >
  1351. <span>{this.state.contractNo}</span>
  1352. </FormItem>
  1353. <FormItem
  1354. className="half-item"
  1355. {...formItemLayout}
  1356. label="客户名称"
  1357. >
  1358. <span>{this.state.userName}</span>
  1359. </FormItem>
  1360. <FormItem
  1361. className="half-item"
  1362. {...formItemLayout}
  1363. label="销售类型"
  1364. >
  1365. <span>
  1366. {(["私有客户-", "签单客户-"][this.state.userType] || " ") +
  1367. (salesList[this.state.salesType] || "")}
  1368. {
  1369. this.state.other != null && this.state.other != "" &&
  1370. <Tooltip title={this.state.other}>
  1371. <span>
  1372. {"(" + this.state.other.toString().slice(0, 10) + (this.state.other.toString().length > 9 ? "...)" : ")")}
  1373. </span>
  1374. </Tooltip>
  1375. }
  1376. </span>
  1377. </FormItem>
  1378. <FormItem
  1379. className="half-item"
  1380. {...formItemLayout}
  1381. label="合同签订时间"
  1382. >
  1383. <span>{this.state.signDate}</span>
  1384. </FormItem>
  1385. <FormItem
  1386. className="half-item"
  1387. {...formItemLayout}
  1388. label="流程状态"
  1389. >
  1390. <span>{getProcessStatus(this.state.processStatus, this.state.examineName, this.state.approval)}</span>
  1391. <FlowChart
  1392. orderNo={this.state.orderNo}
  1393. />
  1394. </FormItem>
  1395. <FormItem
  1396. className="half-item"
  1397. {...formItemLayout}
  1398. label="结算状态"
  1399. >
  1400. <span>
  1401. {getLiquidationStatus(this.state.liquidationStatus)}
  1402. </span>
  1403. </FormItem>
  1404. <FormItem
  1405. className="half-item"
  1406. {...formItemLayout}
  1407. label="企业联系人"
  1408. >
  1409. <span>{this.state.contacts}</span>
  1410. </FormItem>
  1411. <FormItem
  1412. className="half-item"
  1413. {...formItemLayout}
  1414. label="联系人电话"
  1415. >
  1416. <span>{this.state.contactMobile}</span>
  1417. </FormItem>
  1418. <FormItem
  1419. className="half-item"
  1420. {...formItemLayout}
  1421. label="企业法人"
  1422. >
  1423. <span>{this.state.legalPerson}</span>
  1424. </FormItem>
  1425. <FormItem
  1426. className="half-item"
  1427. {...formItemLayout}
  1428. label="法人电话"
  1429. >
  1430. <span>{this.state.legalPersonTel}</span>
  1431. </FormItem>
  1432. <FormItem
  1433. className="half-item"
  1434. {...formItemLayout}
  1435. label="签单金额(万元)"
  1436. >
  1437. <span>{this.state.totalAmount}</span>
  1438. </FormItem>
  1439. <FormItem
  1440. className="half-item"
  1441. {...formItemLayout}
  1442. label="首付金额(万元)"
  1443. >
  1444. <span>{this.state.firstAmount}</span>
  1445. </FormItem>
  1446. <FormItem
  1447. className="half-item"
  1448. {...formItemLayout}
  1449. label="特批立项"
  1450. >
  1451. <span>{getApprovedState(this.state.approval)}</span>
  1452. </FormItem>
  1453. <FormItem
  1454. className="half-item"
  1455. {...formItemLayout}
  1456. label="已收款项(万元)"
  1457. >
  1458. <span>{this.state.settlementAmount}</span>
  1459. </FormItem>
  1460. <div className="clearfix">
  1461. <FormItem
  1462. style={{ height: "auto" }}
  1463. labelCol={{ span: 5 }}
  1464. wrapperCol={{ span: 19 }}
  1465. label="订单留言"
  1466. >
  1467. <p style={{ width: 500, wordWrap: "break-word" }}>
  1468. {this.state.orderRemarks}
  1469. </p>
  1470. </FormItem>
  1471. </div>
  1472. <div className="clearfix">
  1473. {this.state.processStatus == 0 ? (
  1474. <div>
  1475. <FormItem
  1476. labelCol={{ span: 5 }}
  1477. wrapperCol={{ span: 19 }}
  1478. label={
  1479. <span>
  1480. <strong style={{ color: "#f00" }}>
  1481. *
  1482. </strong>
  1483. 合同扫描件
  1484. </span>
  1485. }
  1486. >
  1487. <PicturesWall
  1488. domId={"addService1"}
  1489. fileList={this.getOrgCodeUrl}
  1490. pictureUrl={this.state.orgCodeUrl}
  1491. url="/api/admin/order/uploadOrderImg"
  1492. sign=""
  1493. />
  1494. <p>图片建议:要清晰。</p>
  1495. <Button
  1496. style={{
  1497. float: "right",
  1498. marginRight: "140px",
  1499. marginTop: "20px",
  1500. }}
  1501. onClick={this.getOrderLog}
  1502. >
  1503. 查看订单日志
  1504. </Button>
  1505. </FormItem>
  1506. {/* 高新纯咨询合同说明详情 */}
  1507. <Gxczx
  1508. knowledgeServices={this.state.knowledgeServices}
  1509. auditServices={this.state.auditServices}
  1510. addDeductionServices={this.state.addDeductionServices}
  1511. knowledgeOther={this.state.knowledgeOther}
  1512. auditOther={this.state.auditOther}
  1513. addDeductionOther={this.state.addDeductionOther}
  1514. />
  1515. <FormItem
  1516. labelCol={{ span: 5 }}
  1517. wrapperCol={{ span: 19 }}
  1518. label={<span>补充协议</span>}
  1519. >
  1520. <PicturesWall
  1521. domId={"addService2"}
  1522. fileList={this.getReplenishUrl}
  1523. pictureUrl={this.state.replenishUrl}
  1524. url="/api/admin/order/uploadOrderImg"
  1525. sign=""
  1526. />
  1527. <p>图片建议:要清晰。</p>
  1528. </FormItem>
  1529. </div>
  1530. ) : (
  1531. <div>
  1532. <FormItem
  1533. labelCol={{ span: 5 }}
  1534. wrapperCol={{ span: 19 }}
  1535. label="合同扫描件"
  1536. >
  1537. <div
  1538. style={{
  1539. paddingTop: "10px",
  1540. paddingBottom: "10px",
  1541. }}
  1542. >
  1543. {this.state.orgCodeUrl &&
  1544. this.state.visible &&
  1545. this.state.activeKey === "1" ? (
  1546. <ImgList
  1547. domId={"addService3"}
  1548. fileList={this.state.orgCodeUrl}
  1549. ItemWidth={"96px"}
  1550. />
  1551. ) : (
  1552. <div />
  1553. )}
  1554. </div>
  1555. <Button
  1556. style={{
  1557. float: "right",
  1558. marginRight: "140px",
  1559. marginTop: "20px",
  1560. }}
  1561. onClick={this.getOrderLog}
  1562. >
  1563. 查看订单日志
  1564. </Button>
  1565. </FormItem>
  1566. {/* 高新纯咨询合同说明详情 */}
  1567. <Gxczx
  1568. knowledgeServices={this.state.knowledgeServices}
  1569. auditServices={this.state.auditServices}
  1570. addDeductionServices={this.state.addDeductionServices}
  1571. knowledgeOther={this.state.knowledgeOther}
  1572. auditOther={this.state.auditOther}
  1573. addDeductionOther={this.state.addDeductionOther}
  1574. />
  1575. <FormItem
  1576. style={{ right: "15px" }}
  1577. labelCol={{ span: 5 }}
  1578. wrapperCol={{ span: 19 }}
  1579. label="补充协议"
  1580. >
  1581. <div
  1582. style={{
  1583. paddingTop: "10px",
  1584. paddingBottom: "10px",
  1585. }}
  1586. >
  1587. {this.state.visible &&
  1588. this.state.activeKey === "1" &&
  1589. this.state.replenishUrl ? (
  1590. <ImgList
  1591. domId={"addService4"}
  1592. fileList={this.state.replenishUrl}
  1593. ItemWidth={"96px"}
  1594. />
  1595. ) : (
  1596. <div />
  1597. )}
  1598. </div>
  1599. </FormItem>
  1600. </div>
  1601. )}
  1602. </div>
  1603. <ContentUrl
  1604. processStatus={2}
  1605. domId={"projectsContents"}
  1606. contentUrl={this.state.contentUrl}
  1607. imgId={"projectsContentsImg"}
  1608. />
  1609. <div className="clearfix">
  1610. <FormItem
  1611. className="half-item"
  1612. {...formItemLayout}
  1613. label="订单负责人"
  1614. >
  1615. <span>{this.state.salesmanName}</span>
  1616. </FormItem>
  1617. <FormItem
  1618. className="half-item"
  1619. {...formItemLayout}
  1620. label="订单负责人电话"
  1621. >
  1622. <span>{this.state.salesmanMobile}</span>
  1623. </FormItem>
  1624. <FormItem
  1625. className="half-item"
  1626. {...formItemLayout}
  1627. label="订单部门"
  1628. >
  1629. <span>{this.state.depName}</span>
  1630. </FormItem>
  1631. </div>
  1632. <div className="clearfix">
  1633. <FormItem
  1634. className="half-item"
  1635. {...formItemLayout}
  1636. label="当前财务负责人"
  1637. >
  1638. <span>{this.state.nowFinance}</span>
  1639. </FormItem>
  1640. <FormItem
  1641. className="half-item"
  1642. {...formItemLayout}
  1643. label="当前财务负责人电话"
  1644. >
  1645. <span>{this.state.nowFinanceMobile}</span>
  1646. </FormItem>
  1647. </div>
  1648. <div className="clearfix">
  1649. <FormItem
  1650. className="half-item"
  1651. {...formItemLayout}
  1652. style={{ opacity: ".5" }}
  1653. label="原订单负责人"
  1654. >
  1655. <span>{this.state.oldSalesmanName}</span>
  1656. </FormItem>
  1657. <FormItem
  1658. className="half-item"
  1659. {...formItemLayout}
  1660. style={{ opacity: ".5" }}
  1661. label="原订单负责人电话"
  1662. >
  1663. <span>{this.state.oldSalesmanMobile}</span>
  1664. </FormItem>
  1665. </div>
  1666. <div className="clearfix">
  1667. <FormItem
  1668. className="half-item"
  1669. {...formItemLayout}
  1670. style={{ opacity: ".5" }}
  1671. label="实际财务操作人"
  1672. >
  1673. <span>{this.state.financeName}</span>
  1674. </FormItem>
  1675. <FormItem
  1676. className="half-item"
  1677. {...formItemLayout}
  1678. style={{ opacity: ".5" }}
  1679. label="实际财务操作人电话"
  1680. >
  1681. <span>{this.state.financeMobile}</span>
  1682. </FormItem>
  1683. </div>
  1684. <OrderCoor orderNo={this.state.orderNos} />
  1685. {
  1686. <div>
  1687. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  1688. 项目业务
  1689. </span>
  1690. {
  1691. <Button
  1692. type="primary"
  1693. onClick={this.addDetailed}
  1694. style={{ float: "right", marginRight: "50px" }}
  1695. >
  1696. 添加项目明细
  1697. </Button>
  1698. }
  1699. </div>
  1700. }
  1701. <div className="patent-table">
  1702. <Spin spinning={this.state.loading}>
  1703. <Table
  1704. columns={this.state.columnsX}
  1705. dataSource={this.state.dataSourceX}
  1706. pagination={this.state.paginations}
  1707. onRowClick={this.tableRowClickX}
  1708. expandedRowRender={expandedRowRenderVip}
  1709. rowClassName={this.addRowColor}
  1710. style={{
  1711. cursor: 'pointer',
  1712. }}
  1713. bordered
  1714. size={"small"}
  1715. />
  1716. </Spin>
  1717. </div>
  1718. </div>
  1719. </Spin>
  1720. </Form>
  1721. </Modal> : <div />}
  1722. {this.state.noVisible ? <Modal
  1723. maskClosable={false}
  1724. visible={this.state.noVisible}
  1725. onOk={this.noCancel}
  1726. onCancel={this.noCancel}
  1727. width="400px"
  1728. title={"驳回理由"}
  1729. footer=""
  1730. className="admin-desc-content"
  1731. >
  1732. <Form layout="horizontal" id="demand-form">
  1733. <Spin spinning={this.state.loading}>
  1734. <div className="clearfix">
  1735. <FormItem
  1736. labelCol={{ span: 4 }}
  1737. wrapperCol={{ span: 16 }}
  1738. label="拒绝理由"
  1739. >
  1740. <Input
  1741. type="textarea"
  1742. placeholder="请输入拒绝理由"
  1743. rows={4}
  1744. value={this.state.reason}
  1745. onChange={(e) => {
  1746. this.setState({ reason: e.target.value });
  1747. }}
  1748. />
  1749. </FormItem>
  1750. </div>
  1751. <div className="clearfix">
  1752. <Button
  1753. className="cancel"
  1754. type="primary"
  1755. onClick={this.examOks}
  1756. style={{ marginLeft: "50px" }}
  1757. htmlType="submit"
  1758. >
  1759. 确定
  1760. </Button>
  1761. <Button
  1762. className="cancel"
  1763. type="ghost"
  1764. onClick={this.noCancel}
  1765. style={{ marginLeft: "50px" }}
  1766. >
  1767. 取消
  1768. </Button>
  1769. </div>
  1770. </Spin>
  1771. </Form>
  1772. </Modal> : <div />}
  1773. {/* <Modal
  1774. visible={this.state.rizhivisible}
  1775. className="admin-desc-content"
  1776. width="800px"
  1777. maskClosable={false}
  1778. title="订单日志"
  1779. footer={null}
  1780. onCancel={this.closeOrderLog}
  1781. >
  1782. <div className="patent-table">
  1783. <Spin spinning={this.state.loading}>
  1784. <Table
  1785. columns={this.state.columnsrizhi}
  1786. dataSource={this.state.dataSourcerizhi}
  1787. pagination={false}
  1788. />
  1789. </Spin>
  1790. </div>
  1791. </Modal> */}
  1792. <OrderRiZi
  1793. dataSourcerizhi={this.state.dataSourcerizhi}
  1794. closeOrderLog={this.closeOrderLog}
  1795. visible={this.state.rizhivisible}
  1796. loading={this.state.loading}
  1797. />
  1798. {
  1799. this.state.projectOperationVisible &&
  1800. <NewAddProject
  1801. readOnly={this.state.dataInfor && Object.keys(this.state.dataInfor).length > 0 && this.state.processStatus !== 0}
  1802. orderNo={this.state.orderNo}
  1803. visible={this.state.projectOperationVisible}
  1804. newData={this.state.newData}
  1805. dataInfor={this.state.dataInfor}
  1806. onCancel={this.nextCancel}
  1807. />
  1808. }
  1809. {
  1810. this.state.infoVisible &&
  1811. <NewEditProject
  1812. readOnly={this.state.dataInfor && Object.keys(this.state.dataInfor).length > 0 && this.state.processStatus !== 0}
  1813. orderNo={this.state.orderNo}
  1814. visible={this.state.infoVisible}
  1815. dataInfor={this.state.dataInfor}
  1816. onCancel={this.nextCancel}
  1817. />
  1818. // <ProjectOperation
  1819. // readOnly={this.state.dataInfor && Object.keys(this.state.dataInfor).length > 0 && this.state.processStatus !== 0}
  1820. // orderNo={this.state.orderNo}
  1821. // visible={this.state.infoVisible}
  1822. // dataInfor={this.state.dataInfor}
  1823. // onCancel={this.nextCancel}
  1824. // />
  1825. }
  1826. </div>
  1827. );
  1828. }
  1829. });
  1830. export default PaiDan;