examine.jsx 55 KB

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