approveds.jsx 37 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210
  1. import React from 'react';
  2. import { Icon, Button, Input, Select, Spin, Table, message,DatePicker, Upload, Form ,Modal,Col} from 'antd';
  3. import $ from 'jquery/src/ajax';
  4. import moment from 'moment';
  5. import {
  6. getLiquidationStatus,
  7. getApprovedState,
  8. getProcessStatus,
  9. splitUrl,
  10. getjiedian,
  11. getboutique,
  12. getCuikuan,
  13. ShowModal
  14. } from "@/tools.js";
  15. import './customer.less';
  16. import ShowModalDiv from "@/showModal.jsx";
  17. //图片组件
  18. const PicturesWall = React.createClass({
  19. getInitialState() {
  20. return {
  21. previewVisible: false,
  22. previewImage: '',
  23. fileList: [],
  24. }
  25. },
  26. handleCancel() {
  27. this.setState({
  28. previewVisible: false
  29. })
  30. },
  31. handlePreview(file) {
  32. this.setState({
  33. previewImage: file.url || file.thumbUrl,
  34. previewVisible: true,
  35. });
  36. },
  37. handleChange(info) {
  38. let fileList = info.fileList;
  39. this.setState({
  40. fileList
  41. });
  42. this.props.fileList(fileList);
  43. },
  44. componentWillReceiveProps(nextProps) {
  45. this.state.fileList = nextProps.pictureUrl;
  46. this.state.pojectApplicationUrl = undefined;
  47. },
  48. render() {
  49. const {
  50. previewVisible,
  51. previewImage,
  52. fileList
  53. } = this.state;
  54. const uploadButton = (
  55. <div>
  56. <Icon type="plus" />
  57. <div className="ant-upload-text">点击上传</div>
  58. </div>
  59. );
  60. return(
  61. <div style={{display:"inline-block"}}>
  62. <Upload
  63. action={globalConfig.context + "/api/admin/customer/uploadCustomerImg"}
  64. data={{ 'sign': '' }}
  65. listType="picture-card"
  66. fileList={fileList}
  67. onPreview={this.handlePreview}
  68. onChange={this.handleChange} >
  69. {fileList.length >= 1 ? null : uploadButton}
  70. </Upload>
  71. <Modal maskClosable={false} visible={previewVisible} footer={null} onCancel={this.handleCancel}>
  72. <img alt="example" style={{ width: '100%' }} src={previewImage} />
  73. </Modal>
  74. </div>
  75. );
  76. }
  77. });
  78. const IntentionCustomer = Form.create()(React.createClass({
  79. loadData(pageNo) {
  80. this.setState({
  81. visitModul:false,
  82. loading: true,
  83. ispage:pageNo,
  84. modalVisible:false
  85. });
  86. $.ajax({
  87. method: "get",
  88. dataType: "json",
  89. crossDomain: false,
  90. url: globalConfig.context +"/api/admin/newOrder/orderNewList",
  91. data: {
  92. pageNo: pageNo || 1,
  93. pageSize: this.state.pagination.pageSize,
  94. specially: 3,//审核列表
  95. name: this.state.customerName,//名称
  96. orderNo: this.state.orderNo,//订单编号
  97. depId: this.state.departmenttSearch,//订单部门
  98. starTime: this.state.releaseDate[0],//开始时间
  99. endTime: this.state.releaseDate[1],//结束时间
  100. },
  101. success: function(data) {
  102. ShowModal(this);
  103. let theArr = [];
  104. if(data.error.length || data.data.list == "") {
  105. if(data.error && data.error.length) {
  106. message.warning(data.error[0].message);
  107. };
  108. } else {
  109. for(let i = 0; i < data.data.list.length; i++) {
  110. let thisdata = data.data.list[i];
  111. theArr.push({
  112. key: i,
  113. id: thisdata.id,//用户ID
  114. orderNo: thisdata.orderNo,//订单编号
  115. totalAmount:thisdata.totalAmount,//签单金额
  116. processStatus:thisdata.processStatus,//流程状态
  117. liquidationStatus:thisdata.liquidationStatus,//结算状态
  118. approval:thisdata.approval,//特批状态
  119. signDate:thisdata.signDate,//签单时间
  120. userName:thisdata.userName,//客户名称
  121. salesmanName:thisdata.salesmanName,//营销员名称
  122. financeName:thisdata.financeName,//财务名称
  123. createDate:thisdata.createDate,//下单时间
  124. depName:thisdata.depName,//部门名称
  125. });
  126. };
  127. this.state.pagination.total = data.data.totalCount;
  128. };
  129. if(data.data&&data.data.list&&!data.data.list.length){
  130. this.state.pagination.total=0
  131. }
  132. this.setState({
  133. dataSource: theArr,
  134. pageNo: pageNo,
  135. pagination: this.state.pagination,
  136. selectedRowKeys:[]
  137. });
  138. }.bind(this),
  139. }).always(function() {
  140. this.setState({
  141. loading: false
  142. });
  143. }.bind(this));
  144. },
  145. getInitialState() {
  146. return {
  147. page:1,
  148. releaseDate: [],
  149. selectedRowKeys: [],
  150. orgCodeUrl:[],
  151. departmentArr: [],
  152. paginations:false,
  153. pagination: {
  154. defaultCurrent: 1,
  155. defaultPageSize: 10,
  156. showQuickJumper: true,
  157. pageSize: 10,
  158. onChange: function(page) {
  159. this.loadData(page);
  160. }.bind(this),
  161. showTotal: function(total) {
  162. return '共' + total + '条数据';
  163. }
  164. },
  165. columns: [
  166. {
  167. title: '订单编号',
  168. dataIndex: 'orderNo',
  169. key: 'orderNo'
  170. }, {
  171. title: '下单时间',
  172. dataIndex: 'createDate',
  173. key: 'createTime'
  174. },{
  175. title: '合同签订时间',
  176. dataIndex: 'signDate',
  177. key: 'signDate'
  178. },{
  179. title: '客户名称',
  180. dataIndex: 'userName',
  181. key: 'userName',
  182. render:(text)=>{
  183. return (text&&text.length>9?text.substr(0,9)+'...':text)
  184. }
  185. }, {
  186. title: '流程状态',
  187. dataIndex: 'processStatus',
  188. key: 'processStatus',
  189. render:text=>{return getProcessStatus(text)}
  190. }, {
  191. title: '签单金额(万元)',
  192. dataIndex: 'totalAmount',
  193. key: 'totalAmount'
  194. },{
  195. title: '结算状态',
  196. dataIndex: 'liquidationStatus',
  197. key: 'liquidationStatus',
  198. render:text=>{return getLiquidationStatus(text)}
  199. }, {
  200. title: '是否特批',
  201. dataIndex: 'approval',
  202. key: 'approval',
  203. render:text=>{return getApprovedState(text)}
  204. },{
  205. title: '订单负责人',
  206. dataIndex: 'salesmanName',
  207. key: 'salesmanName'
  208. },{
  209. title: '财务负责人',
  210. dataIndex: 'financeName',
  211. key: 'financeName'
  212. },{
  213. title: '订单部门',
  214. dataIndex: 'depName',
  215. key: 'depName'
  216. }
  217. ],
  218. data: [],
  219. dataSource: [],
  220. columnsX: [
  221. {
  222. title: '业务项目名称',
  223. dataIndex: 'commodityName',
  224. key: 'commodityName'
  225. }, {
  226. title: '项目类别',
  227. dataIndex: 'cname',
  228. key: 'cname',
  229. },{
  230. title: '项目数量',
  231. dataIndex: 'commodityQuantity',
  232. key: 'commodityQuantity'
  233. }, {
  234. title: '金额(万元)',
  235. dataIndex: 'commodityPrice',
  236. key: 'commodityPrice'
  237. }, {
  238. title: '负责人',
  239. dataIndex: 'contacts',
  240. key: 'contacts'
  241. }, {
  242. title: '负责人电话',
  243. dataIndex: 'contactsMobile',
  244. key: 'contactsMobile'
  245. }, {
  246. title: '主要项目',
  247. dataIndex: 'main',
  248. key: 'main',
  249. render:(text)=>{
  250. return (text?'是':'否')
  251. }
  252. }, {
  253. title: '项目说明',
  254. dataIndex: 'taskComment',
  255. key: 'taskComment',
  256. render:(text)=>{
  257. return (text&&text.length>8?text.substr(0,8)+'…':text)
  258. }
  259. }
  260. ],
  261. columnsrizhi:[
  262. {
  263. title:'流程',
  264. dataIndex: 'processName',
  265. key: 'processName'
  266. },
  267. {
  268. title:'操作人',
  269. dataIndex: 'adminName',
  270. key: 'adminName'
  271. },{
  272. title:'时间',
  273. dataIndex: 'createDate',
  274. key: 'createDate'
  275. }
  276. ],
  277. dataSourceX: [],
  278. ContactsLists: [{
  279. title: '催款科目',
  280. dataIndex: 'dunSubject',
  281. key: 'dunSubject',
  282. render: text=>{return getjiedian(text)}
  283. },{
  284. title: '金额(万)',
  285. dataIndex: 'money',
  286. key: 'money',
  287. }, {
  288. title: '催款状态',
  289. dataIndex: 'dunStatus',
  290. key: 'dunStatus',
  291. render:text=>{return getCuikuan(text)}
  292. },
  293. ],
  294. }
  295. },
  296. //页面加载函数
  297. componentWillMount() {
  298. this.departmentList();
  299. this.loadData();
  300. },
  301. //整行点击
  302. tableRowClick(record) {
  303. this.setState({
  304. visible:true,
  305. });
  306. this.xiangqing(record.orderNo);
  307. this.xiangmu(record.orderNo);
  308. this.jiedian(record.orderNo);
  309. },
  310. //点击打卡项目详情
  311. tableRowClickX(record) {
  312. console.log(record);
  313. this.setState({
  314. jid:record.id,//项目ID
  315. kid:record.commodityId,//商品ID
  316. commodityName:record.commodityName,//金额
  317. commodityPrice:record.commodityPrice,//金额
  318. commodityQuantity:record.commodityQuantity,//数量
  319. taskComment:record.taskComment,//备注
  320. main:record.main.toString(),//是否为主要
  321. addnextVisible:true,
  322. addState:0,
  323. });
  324. },
  325. //项目详情关闭
  326. nextCancel() {
  327. this.setState({
  328. addnextVisible: false
  329. })
  330. },
  331. //订单详情
  332. xiangqing(orderNos) {
  333. $.ajax({
  334. method: "get",
  335. dataType: "json",
  336. crossDomain: false,
  337. url: globalConfig.context +"/api/admin/newOrder/getOrderNewDetail",
  338. data: {
  339. orderNo:orderNos
  340. },
  341. success: function(data) {
  342. if(data.error.length || data.data.list == "") {
  343. if(data.error && data.error.length) {
  344. message.warning(data.error[0].message);
  345. };
  346. } else {
  347. let thisdata=data.data;
  348. this.setState({
  349. orderNo: thisdata.orderNo, //订单编号
  350. contractNo: thisdata.contractNo, //合同编号
  351. userName: thisdata.userName, //客户名称
  352. signDate: thisdata.signDate, //签单时间
  353. processStatus: thisdata.processStatus, //流程状态
  354. liquidationStatus: thisdata.liquidationStatus, //结算状态
  355. contacts: thisdata.contacts, //企业联系人
  356. contactMobile: thisdata.contactMobile, //联系人电话
  357. legalPerson: thisdata.legalPerson, //法人
  358. legalPersonTel: thisdata.legalPersonTel, //法人电话
  359. firstAmount: thisdata.firstAmount, //签单金额
  360. totalAmount: thisdata.totalAmount, //首付金额
  361. approval: thisdata.approval, //特批状态
  362. settlementAmount: thisdata.settlementAmount, //已收款项
  363. orderRemarks: thisdata.orderRemarks, //订单留言
  364. orgCodeUrl: thisdata.contractPictureUrl
  365. ? splitUrl(
  366. thisdata.contractPictureUrl,
  367. ",",
  368. globalConfig.avatarHost + "/upload"
  369. )
  370. : [], //图片地址
  371. salesmanName: thisdata.salesmanName, //营销员名称
  372. salesmanMobile: thisdata.salesmanMobile, //营销员电话
  373. financeName: thisdata.financeName, //财务名称
  374. financeMobile: thisdata.financeMobile, //财务电话
  375. outsource: thisdata.outsource == 0 ? "否" : "是"
  376. });
  377. };
  378. }.bind(this),
  379. }).always(function() {
  380. this.setState({
  381. loading: false
  382. });
  383. }.bind(this));
  384. },
  385. //项目列表
  386. xiangmu(orderNos) {
  387. $.ajax({
  388. method: "get",
  389. dataType: "json",
  390. crossDomain: false,
  391. url: globalConfig.context +"/api/admin/newOrder/getOrderTask",
  392. data: {
  393. orderNo:orderNos
  394. },
  395. success: function(data) {
  396. let theArr = [];
  397. if(data.error.length || data.data.list == "") {
  398. if(data.error && data.error.length) {
  399. message.warning(data.error[0].message);
  400. };
  401. } else {
  402. for (let i = 0; i < data.data.length; i++) {
  403. let thisdata = data.data[i];
  404. theArr.push({
  405. key: i,
  406. id:thisdata.id,
  407. orderNo:thisdata.orderNo,//订单编号
  408. commodityId:thisdata.commodityId,//项目ID
  409. commodityName:thisdata.commodityName,//项目名称
  410. cname:thisdata.cname,//项目类别
  411. commodityPrice:thisdata.commodityPrice,//项目价格
  412. commodityQuantity:thisdata.commodityQuantity,//项目数量
  413. main:thisdata.main,//是否为主要任务
  414. taskComment:thisdata.taskComment,//任务说明
  415. contacts:thisdata.contacts,//联系人
  416. contactsMobile:thisdata.contactsMobile,//联系人电话
  417. });
  418. };
  419. };
  420. this.setState({
  421. dataSourceX: theArr,
  422. });
  423. }.bind(this),
  424. }).always(function() {
  425. this.setState({
  426. loading: false
  427. });
  428. }.bind(this));
  429. },
  430. rizhi(){
  431. console.log(this.state.orderNo)
  432. this.setState({
  433. loading:true
  434. })
  435. $.ajax({
  436. method: "get",
  437. dataType: "json",
  438. crossDomain: false,
  439. url: '/api/admin/newOrder/selectOrderLog',
  440. data: {
  441. orderNo:this.state.orderNo
  442. },
  443. success: function (data) {
  444. let theArr = [];
  445. let thisData = data.data;
  446. if (!thisData.length) {
  447. if (data.error && data.error.length) {
  448. message.warning(data.error[0].message);
  449. };
  450. thisData = {};
  451. }else{
  452. for(let i = 0; i < data.data.length; i++) {
  453. let thisdata = data.data[i];
  454. theArr.push({
  455. processName:thisdata.processName,
  456. adminName:thisdata.adminName,
  457. createDate:thisdata.createDate,
  458. });
  459. };
  460. };
  461. this.setState({
  462. dataSourcerizhi: theArr
  463. })
  464. }.bind(this),
  465. }).always(function () {
  466. this.setState({
  467. loading: false
  468. });
  469. }.bind(this));
  470. },
  471. //查看订单日志
  472. getOrderLog(){
  473. this.setState({
  474. rizhivisible:true
  475. })
  476. this.rizhi()
  477. },
  478. closeOrderLog(){
  479. this.setState({
  480. rizhivisible:false
  481. })
  482. },
  483. //节点列表
  484. jiedian(orderNos) {
  485. $.ajax({
  486. method: "get",
  487. dataType: "json",
  488. crossDomain: false,
  489. url: globalConfig.context +"/api/admin/newOrder/selectOrderDun",
  490. data: {
  491. orderNo:orderNos
  492. },
  493. success: function(data) {
  494. let theArr = [];
  495. let thisData=[];
  496. if(data.error.length || data.data.list == "") {
  497. if(data.error && data.error.length) {
  498. message.warning(data.error[0].message);
  499. };
  500. } else {
  501. for(let i = 0; i < data.data.length; i++) {
  502. thisData= data.data[i];
  503. theArr.push({
  504. key:i,
  505. dunSubject:thisData.dunSubject?thisData.dunSubject.toString():"",//催款科目
  506. id:thisData.id,//节点Id
  507. money:thisData.money,//催款金额
  508. dunStatus:thisData.dunStatus,//催款状态
  509. })
  510. }
  511. this.setState({
  512. contactList:theArr
  513. })
  514. };
  515. }.bind(this),
  516. }).always(function() {
  517. this.setState({
  518. loading: false
  519. });
  520. }.bind(this));
  521. },
  522. //审核通过
  523. examOk(){
  524. $.ajax({
  525. method: "post",
  526. dataType: "json",
  527. crossDomain: false,
  528. url: globalConfig.context +"/api/admin/newOrder/approvalOrder",
  529. data: {
  530. orderNo:this.state.orderNo,
  531. confirm:2,
  532. },
  533. success: function(data) {
  534. if(data.error.length || data.data.list == "") {
  535. if(data.error && data.error.length) {
  536. message.warning(data.error[0].message);
  537. };
  538. } else {
  539. message.success("该特批订单已通过审核~");
  540. this.setState({
  541. visible:false,
  542. });
  543. this.reset();
  544. };
  545. }.bind(this),
  546. }).always(function() {
  547. this.setState({
  548. loading: false
  549. });
  550. }.bind(this));
  551. },
  552. //审核不通过
  553. examOks(){
  554. $.ajax({
  555. method: "post",
  556. dataType: "json",
  557. crossDomain: false,
  558. url: globalConfig.context +"/api/admin/newOrder/approvalOrder",
  559. data: {
  560. orderNo:this.state.orderNo,
  561. confirm:3,
  562. reason:this.state.reason,
  563. },
  564. success: function(data) {
  565. if(data.error.length || data.data.list == "") {
  566. if(data.error && data.error.length) {
  567. message.warning(data.error[0].message);
  568. };
  569. } else {
  570. message.success("该特批订单已被驳回~");
  571. this.setState({
  572. visible:false,
  573. noVisible:false
  574. });
  575. this.loadData();
  576. this.resets();
  577. };
  578. }.bind(this),
  579. }).always(function() {
  580. this.setState({
  581. loading: false
  582. });
  583. }.bind(this));
  584. },
  585. //点击拒绝
  586. examNo(){
  587. this.setState({
  588. noVisible:true
  589. })
  590. },
  591. //关闭输入理由框
  592. noCancel(){
  593. this.setState({
  594. noVisible:false
  595. })
  596. },
  597. //搜索
  598. search() {
  599. this.setState({
  600. //signBillVisible:false
  601. })
  602. this.loadData();
  603. },
  604. //重置
  605. reset() {
  606. this.setState({
  607. signBillVisible:false
  608. })
  609. this.state.orderNo='';
  610. this.state.customerName='';
  611. this.state.departmenttSearch=undefined;
  612. this.state.releaseDate[0] = undefined;
  613. this.state.releaseDate[1] = undefined;
  614. this.state.approval= undefined;
  615. this.loadData();
  616. },
  617. resets(){
  618. this.state.orderNo='';
  619. this.state.customerName='';
  620. this.state.departmenttSearch=undefined;
  621. this.state.releaseDate[0] = undefined;
  622. this.state.releaseDate[1] = undefined;
  623. },
  624. getOrgCodeUrl(e) {
  625. this.setState({ orgCodeUrl: e });
  626. },
  627. //关闭详情
  628. visitCancel(){
  629. this.setState({
  630. visible:false
  631. })
  632. this.resets();
  633. },
  634. visitOk(){
  635. this.setState({
  636. visible:false
  637. })
  638. this.resets();
  639. },
  640. //部门
  641. departmentList() {
  642. this.setState({
  643. loading: true
  644. });
  645. $.ajax({
  646. method: "get",
  647. dataType: "json",
  648. crossDomain: false,
  649. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  650. data: {
  651. },
  652. success: function(data) {
  653. let thedata = data.data;
  654. let theArr = [];
  655. if(!thedata) {
  656. if(data.error && data.error.length) {
  657. message.warning(data.error[0].message);
  658. };
  659. thedata = {};
  660. } else {
  661. thedata.map(function(item, index) {
  662. theArr.push({
  663. key: index,
  664. name: item.name,
  665. id: item.id,
  666. })
  667. })
  668. }
  669. this.setState({
  670. departmentArr: theArr,
  671. })
  672. }.bind(this),
  673. }).always(function() {
  674. this.setState({
  675. loading: false
  676. });
  677. }.bind(this));
  678. },
  679. render() {
  680. const formItemLayout = {
  681. labelCol: { span: 8 },
  682. wrapperCol: { span: 14 },
  683. };
  684. const FormItem = Form.Item;
  685. const { RangePicker } = DatePicker;
  686. const rowSelection = {
  687. selectedRowKeys: this.state.selectedRowKeys,
  688. onChange: (selectedRowKeys, selectedRows) => {
  689. this.setState({
  690. modalVisible:false,
  691. selectedRows: selectedRows.slice(-1),
  692. selectedRowKeys: selectedRowKeys.slice(-1)
  693. });
  694. },
  695. onSelect: (recordt) => {
  696. this.setState({
  697. modalVisible:false,
  698. recordt: recordt.id
  699. })
  700. },
  701. };
  702. let departmentArr = this.state.departmentArr || [];
  703. return (
  704. <div className="user-content">
  705. <ShowModalDiv ShowModal={this.state.showModal} />
  706. <div className="content-title">
  707. <span>特批订单审核</span>
  708. </div>
  709. <div className="user-search">
  710. <Input
  711. placeholder="客户名称"
  712. style={{ width: "150px", marginBottom: "10px" }}
  713. value={this.state.customerName}
  714. onChange={e => {
  715. this.setState({ customerName: e.target.value });
  716. }}
  717. />
  718. <Input
  719. placeholder="订单编号"
  720. style={{ width: "150px" }}
  721. value={this.state.orderNo}
  722. onChange={e => {
  723. this.setState({ orderNo: e.target.value });
  724. }}
  725. />
  726. <Select
  727. placeholder="选择部门"
  728. style={{ width: 150, marginRight: "10px" }}
  729. value={this.state.departmenttSearch}
  730. onChange={e => {
  731. this.setState({ departmenttSearch: e });
  732. }}
  733. >
  734. {departmentArr.map(function(item) {
  735. return <Select.Option key={item.id}>{item.name}</Select.Option>;
  736. })}
  737. </Select>
  738. <span style={{ marginRight: "10px" }}>下单时间 :</span>
  739. <RangePicker
  740. value={[
  741. this.state.releaseDate[0]
  742. ? moment(this.state.releaseDate[0])
  743. : null,
  744. this.state.releaseDate[1]
  745. ? moment(this.state.releaseDate[1])
  746. : null
  747. ]}
  748. onChange={(data, dataString) => {
  749. this.setState({ releaseDate: dataString });
  750. }}
  751. />
  752. <Button
  753. type="primary"
  754. onClick={this.search}
  755. style={{ marginLeft: "10px" }}
  756. >
  757. 搜索
  758. </Button>
  759. <Button onClick={this.reset}>重置</Button>
  760. <div className="patent-table">
  761. <Spin spinning={this.state.loading}>
  762. <Table
  763. columns={this.state.columns}
  764. dataSource={this.state.dataSource}
  765. rowSelection={rowSelection}
  766. pagination={this.state.pagination}
  767. onRowClick={this.tableRowClick}
  768. />
  769. </Spin>
  770. </div>
  771. <Modal
  772. className="customeDetails"
  773. footer=""
  774. title="订单详情"
  775. width="900px"
  776. visible={this.state.visible}
  777. onOk={this.visitOk}
  778. onCancel={this.visitCancel}
  779. >
  780. <Form
  781. layout="horizontal"
  782. onSubmit={this.handleSubmit}
  783. id="demand-form"
  784. style={{ paddingBottom: "40px" }}
  785. >
  786. <Spin spinning={this.state.loading}>
  787. <div className="clearfix">
  788. <FormItem
  789. className="half-item"
  790. {...formItemLayout}
  791. label="订单编号"
  792. >
  793. <span>{this.state.orderNo}</span>
  794. </FormItem>
  795. <FormItem
  796. className="half-item"
  797. {...formItemLayout}
  798. label="合同编号"
  799. >
  800. <span>{this.state.contractNo}</span>
  801. </FormItem>
  802. <FormItem
  803. className="half-item"
  804. {...formItemLayout}
  805. label="客户名称"
  806. >
  807. <span>{this.state.userName}</span>
  808. </FormItem>
  809. <FormItem
  810. className="half-item"
  811. {...formItemLayout}
  812. label="合同签订时间"
  813. >
  814. <span>{this.state.signDate}</span>
  815. </FormItem>
  816. <FormItem
  817. className="half-item"
  818. {...formItemLayout}
  819. label="流程状态"
  820. >
  821. <span>{getProcessStatus(this.state.processStatus)}</span>
  822. </FormItem>
  823. <FormItem
  824. className="half-item"
  825. {...formItemLayout}
  826. label="结算状态"
  827. >
  828. <span>
  829. {getLiquidationStatus(this.state.liquidationStatus)}
  830. </span>
  831. </FormItem>
  832. <FormItem
  833. className="half-item"
  834. {...formItemLayout}
  835. label="企业联系人"
  836. >
  837. <span>{this.state.contacts}</span>
  838. </FormItem>
  839. <FormItem
  840. className="half-item"
  841. {...formItemLayout}
  842. label="联系人电话"
  843. >
  844. <span>{this.state.contactMobile}</span>
  845. </FormItem>
  846. <FormItem
  847. className="half-item"
  848. {...formItemLayout}
  849. label="企业法人"
  850. >
  851. <span>{this.state.legalPerson}</span>
  852. </FormItem>
  853. <FormItem
  854. className="half-item"
  855. {...formItemLayout}
  856. label="法人电话"
  857. >
  858. <span>{this.state.legalPersonTel}</span>
  859. </FormItem>
  860. <FormItem
  861. className="half-item"
  862. {...formItemLayout}
  863. label="签单金额(万元)"
  864. >
  865. <span>{this.state.totalAmount}</span>
  866. </FormItem>
  867. <FormItem
  868. className="half-item"
  869. {...formItemLayout}
  870. label="首付金额(万元)"
  871. >
  872. <span>{this.state.firstAmount}</span>
  873. </FormItem>
  874. <FormItem
  875. className="half-item"
  876. {...formItemLayout}
  877. label="特批立项"
  878. >
  879. <span>{getApprovedState(this.state.approval)}</span>
  880. </FormItem>
  881. <FormItem
  882. className="half-item"
  883. {...formItemLayout}
  884. label="已收款项(万元)"
  885. >
  886. <span>{this.state.settlementAmount}</span>
  887. </FormItem>
  888. <FormItem
  889. className="half-item"
  890. {...formItemLayout}
  891. label="是否外包"
  892. >
  893. <span>{this.state.outsource}</span>
  894. </FormItem>
  895. <div className="clearfix">
  896. <FormItem
  897. labelCol={{ span: 4 }}
  898. wrapperCol={{ span: 16 }}
  899. label="订单留言"
  900. >
  901. <span>{this.state.orderRemarks}</span>
  902. </FormItem>
  903. </div>
  904. <div className="clearfix">
  905. <FormItem
  906. labelCol={{ span: 4 }}
  907. wrapperCol={{ span: 18 }}
  908. label={
  909. <span>
  910. <strong style={{ color: "#f00" }}>*</strong>合同扫描件
  911. </span>
  912. }
  913. >
  914. <PicturesWall
  915. fileList={this.getOrgCodeUrl}
  916. pictureUrl={this.state.orgCodeUrl}
  917. />
  918. <p>图片建议:要清晰。</p>
  919. <Button
  920. style={{
  921. float: "right",
  922. marginRight: "140px",
  923. marginTop: "20px"
  924. }}
  925. onClick={this.getOrderLog}
  926. >
  927. 查看订单 日志
  928. </Button>
  929. </FormItem>
  930. </div>
  931. <div className="clearfix">
  932. <FormItem
  933. className="half-item"
  934. {...formItemLayout}
  935. label="订单负责人"
  936. >
  937. <span>{this.state.salesmanName}</span>
  938. </FormItem>
  939. <FormItem
  940. className="half-item"
  941. {...formItemLayout}
  942. label="订单负责人电话"
  943. >
  944. <span>{this.state.salesmanMobile}</span>
  945. </FormItem>
  946. </div>
  947. <div className="clearfix">
  948. <FormItem
  949. className="half-item"
  950. {...formItemLayout}
  951. label="财务负责人"
  952. >
  953. <span>{this.state.financeName}</span>
  954. </FormItem>
  955. <FormItem
  956. className="half-item"
  957. {...formItemLayout}
  958. label="财务负责人电话"
  959. >
  960. <span>{this.state.financeMobile}</span>
  961. </FormItem>
  962. </div>
  963. <div>
  964. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  965. 催款节点
  966. </span>
  967. {this.state.processStatus == 0 ? (
  968. <Button
  969. type="primary"
  970. onClick={this.addcontact}
  971. style={{
  972. float: "right",
  973. marginRight: "50px",
  974. marginBottom: "15px"
  975. }}
  976. >
  977. 添加催款节点
  978. </Button>
  979. ) : (
  980. ""
  981. )}
  982. </div>
  983. <div className="clearfix">
  984. <Spin spinning={this.state.loading}>
  985. <Form layout="horizontal" id="demand-form">
  986. <Table
  987. pagination={false}
  988. columns={this.state.ContactsLists}
  989. dataSource={this.state.contactList}
  990. />
  991. <Col
  992. span={24}
  993. offset={9}
  994. style={{ marginTop: "15px" }}
  995. ></Col>
  996. </Form>
  997. </Spin>
  998. </div>
  999. <div>
  1000. <span style={{ marginLeft: "50px", fontSize: "20px" }}>
  1001. 项目业务
  1002. </span>
  1003. {this.state.processStatus == 0 ? (
  1004. <Button
  1005. type="primary"
  1006. onClick={this.addDetailed}
  1007. style={{
  1008. float: "right",
  1009. marginRight: "50px",
  1010. marginBottom: "15px"
  1011. }}
  1012. >
  1013. 添加项目明细
  1014. </Button>
  1015. ) : (
  1016. ""
  1017. )}
  1018. </div>
  1019. <div className="patent-table">
  1020. <Spin spinning={this.state.loading}>
  1021. <Table
  1022. columns={this.state.columnsX}
  1023. dataSource={this.state.dataSourceX}
  1024. pagination={this.state.paginations}
  1025. onRowClick={this.tableRowClickX}
  1026. />
  1027. </Spin>
  1028. </div>
  1029. <div className="addSave" style={{ marginTop: "15px" }}>
  1030. <Button
  1031. className="cancel"
  1032. type="primary"
  1033. onClick={this.examOk}
  1034. style={{ marginLeft: "200px" }}
  1035. htmlType="submit"
  1036. >
  1037. 通过
  1038. </Button>
  1039. <Button
  1040. className="cancel"
  1041. type="primary"
  1042. onClick={this.examNo}
  1043. style={{ marginLeft: "50px" }}
  1044. htmlType="submit"
  1045. >
  1046. 驳回
  1047. </Button>
  1048. <Button
  1049. className="cancel"
  1050. type="ghost"
  1051. onClick={this.visitCancel}
  1052. style={{ marginLeft: "50px" }}
  1053. >
  1054. 取消
  1055. </Button>
  1056. </div>
  1057. </div>
  1058. </Spin>
  1059. </Form>
  1060. </Modal>
  1061. <Modal
  1062. maskClosable={false}
  1063. visible={this.state.addnextVisible}
  1064. onOk={this.nextCancel}
  1065. onCancel={this.nextCancel}
  1066. width="800px"
  1067. title={"项目任务详情"}
  1068. footer=""
  1069. className="admin-desc-content"
  1070. >
  1071. <Form layout="horizontal" id="demand-form">
  1072. <Spin spinning={this.state.loading}>
  1073. <div className="clearfix">
  1074. <FormItem
  1075. className="half-item"
  1076. {...formItemLayout}
  1077. label="项目名称"
  1078. >
  1079. <span>{this.state.commodityName}</span>
  1080. </FormItem>
  1081. <FormItem
  1082. className="half-item"
  1083. {...formItemLayout}
  1084. label="项目数量"
  1085. >
  1086. <span>{this.state.commodityQuantity}</span>
  1087. </FormItem>
  1088. <FormItem
  1089. className="half-item"
  1090. {...formItemLayout}
  1091. label="金额(万元)"
  1092. >
  1093. <span>{this.state.commodityPrice}</span>
  1094. </FormItem>
  1095. <FormItem
  1096. className="half-item"
  1097. {...formItemLayout}
  1098. label="主要项目"
  1099. >
  1100. <span>{getboutique(this.state.main)}</span>
  1101. </FormItem>
  1102. <div className="clearfix">
  1103. <FormItem
  1104. labelCol={{ span: 4 }}
  1105. wrapperCol={{ span: 16 }}
  1106. label="服务说明"
  1107. >
  1108. <span>{this.state.taskComment}</span>
  1109. </FormItem>
  1110. </div>
  1111. </div>
  1112. </Spin>
  1113. </Form>
  1114. </Modal>
  1115. <Modal
  1116. maskClosable={false}
  1117. visible={this.state.noVisible}
  1118. onOk={this.noCancel}
  1119. onCancel={this.noCancel}
  1120. width="400px"
  1121. title={"拒绝理由"}
  1122. footer=""
  1123. className="admin-desc-content"
  1124. >
  1125. <Form layout="horizontal" id="demand-form">
  1126. <Spin spinning={this.state.loading}>
  1127. <div className="clearfix">
  1128. <FormItem
  1129. labelCol={{ span: 4 }}
  1130. wrapperCol={{ span: 16 }}
  1131. label="拒绝理由"
  1132. >
  1133. <Input
  1134. type="textarea"
  1135. placeholder="请输入拒绝理由"
  1136. rows={4}
  1137. value={this.state.reason}
  1138. onChange={e => {
  1139. this.setState({ reason: e.target.value });
  1140. }}
  1141. />
  1142. </FormItem>
  1143. </div>
  1144. <div className="clearfix">
  1145. <Button
  1146. className="cancel"
  1147. type="primary"
  1148. onClick={this.examOks}
  1149. style={{ marginLeft: "50px" }}
  1150. htmlType="submit"
  1151. >
  1152. 确定
  1153. </Button>
  1154. <Button
  1155. className="cancel"
  1156. type="ghost"
  1157. onClick={this.noCancel}
  1158. style={{ marginLeft: "50px" }}
  1159. >
  1160. 取消
  1161. </Button>
  1162. </div>
  1163. </Spin>
  1164. </Form>
  1165. </Modal>
  1166. <Modal
  1167. visible={this.state.rizhivisible}
  1168. className="admin-desc-content"
  1169. width="800px"
  1170. maskClosable={false}
  1171. title="订单日志"
  1172. footer={null}
  1173. onCancel={this.closeOrderLog}
  1174. >
  1175. <div className="patent-table">
  1176. <Spin spinning={this.state.loading}>
  1177. <Table
  1178. columns={this.state.columnsrizhi}
  1179. dataSource={this.state.dataSourcerizhi}
  1180. pagination={false}
  1181. />
  1182. </Spin>
  1183. </div>
  1184. </Modal>
  1185. </div>
  1186. </div>
  1187. );
  1188. }
  1189. }));
  1190. export default IntentionCustomer;