zxsglyOutSourcingPaiDan.jsx 51 KB

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