orderStatistics.jsx 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849
  1. import React from 'react';
  2. import { Select, Spin, Input, Table, Button ,DatePicker, Form , Tabs , Switch,message} from 'antd';
  3. import ajax from 'jquery/src/ajax/xhr.js';
  4. import $ from 'jquery/src/ajax';
  5. import './report.less';
  6. import { post,taskStatus,publishStatus } from '../../../dataDic.js';
  7. import moment from 'moment';
  8. import {ChooseList} from "../orderNew/chooseList";
  9. const TabPane = Tabs.TabPane;
  10. const DiurnalStatistics = React.createClass({
  11. loadData(timeTypes) {
  12. this.setState({
  13. loading: true,
  14. timeTypes:timeTypes
  15. });
  16. $.ajax({
  17. method: "get",
  18. dataType: "json",
  19. crossDomain: false,
  20. url: globalConfig.context + "/api/admin/report/technicalDepStatistics",
  21. data: {
  22. type:'1',
  23. timeType:this.state.releaseDate[0]?4:timeTypes,
  24. startTime: this.state.releaseDate[0],
  25. endTime: this.state.releaseDate[1],
  26. depId:this.state.superId,//部门机构
  27. taskStatus:this.state.taskStatus,//任务状态
  28. publishStatus:this.state.publishStatus,//公示状态
  29. },
  30. success: function(data) {
  31. let thedata = data.data;
  32. let theArr = [];
  33. if(!thedata) {
  34. if(data.error && data.error.length) {
  35. message.warning(data.error[0].message);
  36. };
  37. thedata = {};
  38. } else {
  39. thedata.map(function(item, index) {
  40. let nub=index+1;
  41. theArr.push({
  42. key: index,
  43. theNumber:false,
  44. nub:nub,
  45. orderDep: item.orderDep,//订单部门
  46. signTotalAmount:item.signTotalAmount,//项目签单金额
  47. signTime:item.signTime,//签单日期
  48. contractNo:item.contractNo,//合同编号
  49. orderRemarks:item.orderRemarks, //订单留言
  50. contacts:item.contacts,//企业联系人
  51. contactMobile:item.contactMobile,//联系人电话
  52. commodityName:item.commodityName,//任务名称
  53. taskDistributionTime:item.taskDistributionTime,//派单时间
  54. dutyDep:item.dutyDep, //任务责任部门
  55. dutyName:item.dutyName,//任务责任人
  56. dutyContactMobile:item.dutyContactMobile,//责任人联系电话
  57. taskStatus:item.taskStatus,//任务状态
  58. finishTime:item.finishTime, //完成时间
  59. taskComment:item.taskComment,//任务说明
  60. publishStatus:item.publishStatus, //公示状态
  61. publishTime:item.publishTime,//公示时间
  62. salesmanName:item.salesmanName, //营销员
  63. orgName:item.orgName,//公司名称
  64. })
  65. })
  66. }
  67. this.setState({
  68. dataSource: theArr,
  69. })
  70. }.bind(this),
  71. }).always(function() {
  72. this.setState({
  73. loading: false
  74. });
  75. }.bind(this));
  76. },
  77. totalData(timeTypes) {
  78. this.setState({
  79. loading: true
  80. });
  81. $.ajax({
  82. method: "get",
  83. dataType: "json",
  84. crossDomain: false,
  85. url: globalConfig.context + "/api/admin/report/sales/countsometimeMarketingStatistics",
  86. data: {
  87. type:'1',
  88. timeType:this.state.releaseDate[0]?4:timeTypes,
  89. startTime: this.state.releaseDate[0],
  90. endTime: this.state.releaseDate[1],
  91. depId:this.state.superId,//部门机构
  92. },
  93. success: function(data) {
  94. let thedata = data.data;
  95. let theArr = [];
  96. if(!thedata) {
  97. if(data.error && data.error.length) {
  98. message.warning(data.error[0].message);
  99. };
  100. thedata = {};
  101. }
  102. this.loadData(timeTypes)
  103. this.selectSuperId();
  104. }.bind(this),
  105. }).always(function() {
  106. this.setState({
  107. loading: false
  108. });
  109. }.bind(this));
  110. },
  111. //时间选择
  112. selTime(value,index){
  113. this.setState({
  114. Dtime:value,
  115. selTime:index
  116. })
  117. },
  118. //获取上级组织
  119. selectSuperId() {
  120. this.state.data = []
  121. $.ajax({
  122. method: "get",
  123. dataType: "json",
  124. crossDomain: false,
  125. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  126. data:{
  127. },
  128. success: function (data) {
  129. let theArr = [];
  130. let theId=[];//用于保存上级组织的ID和名称
  131. let thedata=data.data;
  132. if (!thedata) {
  133. if (data.error && data.error.length) {
  134. message.warning(data.error[0].message);
  135. };
  136. thedata = {};
  137. };
  138. var contactIds=[];
  139. for(var i=0;i<data.data.length;i++){
  140. let theData = data.data[i];
  141. theArr.push(
  142. <Select.Option value={theData.id} key={theData.id}>{theData.name}</Select.Option>
  143. );
  144. theId.push(
  145. [theData.id,theData.name]
  146. );
  147. };
  148. this.setState({
  149. SuperArr:thedata,
  150. contactsOption: theArr,
  151. theId: theId,
  152. orderStatusOptions:data.data,
  153. });
  154. }.bind(this),
  155. }).always(function () {
  156. this.setState({
  157. loading: false
  158. });
  159. }.bind(this));
  160. },
  161. //判断浏览器类型
  162. getExplorer() {
  163. var explorer = window.navigator.userAgent;
  164. //ie
  165. if(explorer.indexOf("MSIE") >= 0) {
  166. return 'ie';
  167. }
  168. //firefox
  169. else if(explorer.indexOf("Firefox") >= 0) {
  170. return 'Firefox';
  171. }
  172. //Chrome
  173. else if(explorer.indexOf("Chrome") >= 0) {
  174. return 'Chrome';
  175. }
  176. //Opera
  177. else if(explorer.indexOf("Opera") >= 0) {
  178. return 'Opera';
  179. }
  180. //Safari
  181. else if(explorer.indexOf("Safari") >= 0) {
  182. return 'Safari';
  183. }
  184. },
  185. //导出为exel表格
  186. tabExel() {
  187. var table = document.querySelector('#daochu');
  188. var idTmr;
  189. //debugger;
  190. //整个表格拷贝到EXCEL中
  191. if(this.getExplorer() == 'ie') {
  192. var curTbl = document.getElementById(tableid);
  193. var oXL = new ActiveXObject("Excel.Application");
  194. //创建AX对象excel
  195. var oWB = oXL.Workbooks.Add();
  196. //获取workbook对象
  197. var xlsheet = oWB.Worksheets(1);
  198. //激活当前sheet
  199. var sel = document.body.createTextRange();
  200. sel.moveToElementText(curTbl);
  201. //把表格中的内容移到TextRange中
  202. sel.select();
  203. //全选TextRange中内容
  204. sel.execCommand("Copy");
  205. //复制TextRange中内容
  206. xlsheet.Paste();
  207. //粘贴到活动的EXCEL中
  208. oXL.Visible = true;
  209. //设置excel可见属性
  210. try {
  211. var fname = oXL.Application.GetSaveAsFilename("Excel.xls", "Excel Spreadsheets (*.xls), *.xls");
  212. } catch(e) {
  213. print("Nested catch caught " + e);
  214. } finally {
  215. oWB.SaveAs(fname);
  216. oWB.Close(savechanges = false);
  217. //xls.visible = false;
  218. oXL.Quit();
  219. oXL = null;
  220. //结束excel进程,退出完成
  221. //window.setInterval("Cleanup();",1);
  222. idTmr = window.setInterval("Cleanup();", 1);
  223. }
  224. } else {
  225. this.tableToExcel(table,this.getExplorer());
  226. }
  227. function Cleanup() {
  228. window.clearInterval(idTmr);
  229. CollectGarbage();
  230. }
  231. },
  232. tableToExcel(table,name) {
  233. var uri = 'data:application/vnd.ms-excel;base64,',
  234. template = '<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--></head><body><table>{table}</table></body></html>',
  235. base64 = function(s) {
  236. return window.btoa(unescape(encodeURIComponent(s)))
  237. },
  238. format = function(s, c) {
  239. return s.replace(/{(\w+)}/g,
  240. function(m, p) {
  241. return c[p];
  242. })
  243. }
  244. if(!table.nodeType) table = document.getElementById(table);
  245. var ctx = {
  246. worksheet: name || 'Worksheet',
  247. table: table.innerHTML
  248. };
  249. window.location.href = uri + base64(format(template, ctx))
  250. },
  251. getInitialState() {
  252. return {
  253. releaseDate: [],
  254. selectedRowKeys: [],
  255. selectedRows: [],
  256. loading: false,
  257. visible: false,
  258. showDesc: false,
  259. timeState:false,
  260. weekColor:true,
  261. monthColor:false,
  262. quarterColor:false,
  263. yearColor:false,
  264. Dtime:undefined,
  265. timeTypes:0,
  266. selTime:'',
  267. columns: [
  268. {
  269. title: '序号',
  270. dataIndex: 'nub',
  271. width:50,
  272. key: 'nub',
  273. fixed:false,
  274. render:(text,record)=>{
  275. if(!record.theNumber){
  276. return text
  277. }else{
  278. return {
  279. children: text,
  280. props: {
  281. colSpan:0
  282. },
  283. }
  284. }
  285. }
  286. },
  287. {
  288. title: '公司名称',
  289. dataIndex: 'orgName',
  290. key: 'orgName',
  291. width:100,
  292. fixed:false,
  293. render:(text,record)=>{
  294. if(!record.theNumber){
  295. return text//&&text.length>6?<span title={text}>{text.substr(0,6)+'…'}</span>:text
  296. }else{
  297. return {
  298. children: text,
  299. props: {
  300. colSpan:3
  301. },
  302. }
  303. }
  304. }
  305. }, {
  306. title: '订单部门',
  307. fixed:false,
  308. width:100,
  309. dataIndex: 'orderDep',
  310. key: 'orderDep',
  311. render:(text,record)=>{
  312. if(!record.theNumber){
  313. return text
  314. }else{
  315. return {
  316. children: text,
  317. props: {
  318. colSpan:0
  319. },
  320. }
  321. }
  322. }
  323. },
  324. {
  325. title: '项目签单金额',
  326. fixed:false,
  327. dataIndex: 'signTotalAmount',
  328. key: 'signTotalAmount',
  329. sorter: (a, b) => a.signTotalAmount - b.signTotalAmount,
  330. render:(text,record)=>{
  331. if(!record.theNumber){
  332. return text
  333. }else{
  334. return {
  335. children: text,
  336. props: {
  337. colSpan:1
  338. },
  339. }
  340. }
  341. }
  342. }, {
  343. title: '签单日期',
  344. fixed:false,
  345. width:50,
  346. dataIndex: 'signTime',
  347. key: 'signTime',
  348. render:(text,record)=>{
  349. if(!record.theNumber){
  350. return text
  351. }else{
  352. return {
  353. children: text,
  354. props: {
  355. colSpan:0
  356. },
  357. }
  358. }
  359. }
  360. }, {
  361. title: '合同编号',
  362. fixed:false,
  363. dataIndex: 'contractNo',
  364. key: 'contractNo',
  365. render:(text,record)=>{
  366. if(!record.theNumber){
  367. return text
  368. }else{
  369. return {
  370. children: text,
  371. props: {
  372. colSpan:0
  373. },
  374. }
  375. }
  376. }
  377. },{
  378. title: '订单留言',
  379. fixed:false,
  380. width:200,
  381. dataIndex: 'orderRemarks',
  382. key: 'orderRemarks',
  383. render:(text,record)=>{
  384. if(!record.theNumber){
  385. return text
  386. }else{
  387. return {
  388. children: text,
  389. props: {
  390. colSpan:0
  391. },
  392. }
  393. }
  394. }
  395. },{
  396. title: '企业联系人',
  397. fixed:false,
  398. dataIndex: 'contacts',
  399. key: 'contacts',
  400. render:(text,record)=>{
  401. if(!record.theNumber){
  402. return text
  403. }else{
  404. return {
  405. children: text,
  406. props: {
  407. colSpan:0
  408. },
  409. }
  410. }
  411. }
  412. },{
  413. title: '联系人电话',
  414. fixed:false,
  415. dataIndex: 'contactMobile',
  416. key: 'contactMobile',
  417. render:(text,record)=>{
  418. if(!record.theNumber){
  419. return text
  420. }else{
  421. return {
  422. children: text,
  423. props: {
  424. colSpan:0
  425. },
  426. }
  427. }
  428. }
  429. },{
  430. title: '任务名称',
  431. fixed:false,
  432. dataIndex: 'commodityName',
  433. key: 'commodityName',
  434. render:(text,record)=>{
  435. if(!record.theNumber){
  436. return text
  437. }else{
  438. return {
  439. children: text,
  440. props: {
  441. colSpan:0
  442. },
  443. }
  444. }
  445. }
  446. },{
  447. title: '派单时间',
  448. fixed:false,
  449. dataIndex: 'taskDistributionTime',
  450. key: 'taskDistributionTime',
  451. render:(text,record)=>{
  452. if(!record.theNumber){
  453. return text
  454. }else{
  455. return {
  456. children: text,
  457. props: {
  458. colSpan:0
  459. },
  460. }
  461. }
  462. }
  463. },{
  464. title: '部门',
  465. fixed:false,
  466. dataIndex: 'dutyDep',
  467. key: 'dutyDep',
  468. render:(text,record)=>{
  469. if(!record.theNumber){
  470. return text
  471. }else{
  472. return {
  473. children: text,
  474. props: {
  475. colSpan:0
  476. },
  477. }
  478. }
  479. }
  480. },{
  481. title: '负责人',
  482. fixed:false,
  483. dataIndex: 'dutyName',
  484. key: 'dutyName',
  485. render:(text,record)=>{
  486. if(!record.theNumber){
  487. return text
  488. }else{
  489. return {
  490. children: text,
  491. props: {
  492. colSpan:0
  493. },
  494. }
  495. }
  496. }
  497. },{
  498. title: '负责人电话',
  499. fixed:false,
  500. dataIndex: 'dutyContactMobile',
  501. key: 'dutyContactMobile',
  502. render:(text,record)=>{
  503. if(!record.theNumber){
  504. return text
  505. }else{
  506. return {
  507. children: text,
  508. props: {
  509. colSpan:0
  510. },
  511. }
  512. }
  513. }
  514. },{
  515. title: '任务状态',
  516. fixed:false,
  517. dataIndex: 'taskStatus',
  518. key: 'taskStatus',
  519. render:(text,record)=>{
  520. if(!record.theNumber){
  521. return text
  522. }else{
  523. return {
  524. children: text,
  525. props: {
  526. colSpan:0
  527. },
  528. }
  529. }
  530. }
  531. },{
  532. title: '项目完成时间',
  533. fixed:false,
  534. dataIndex: 'finishTime',
  535. key: 'finishTime',
  536. render:(text,record)=>{
  537. if(!record.theNumber){
  538. return text
  539. }else{
  540. return {
  541. children: text,
  542. props: {
  543. colSpan:0
  544. },
  545. }
  546. }
  547. }
  548. },{
  549. title: '任务说明',
  550. fixed:false,
  551. width:200,
  552. dataIndex: 'taskComment',
  553. key: 'taskComment',
  554. render:(text,record)=>{
  555. if(!record.theNumber){
  556. return text
  557. }else{
  558. return {
  559. children: text,
  560. props: {
  561. colSpan:0
  562. },
  563. }
  564. }
  565. }
  566. },{
  567. title: '公示状态',
  568. fixed:false,
  569. dataIndex: 'publishStatus',
  570. key: 'publishStatus',
  571. render:(text,record)=>{
  572. if(!record.theNumber){
  573. return text
  574. }else{
  575. return {
  576. children: text,
  577. props: {
  578. colSpan:0
  579. },
  580. }
  581. }
  582. }
  583. },{
  584. title: '公示时间',
  585. fixed:false,
  586. dataIndex: 'publishTime',
  587. key: 'publishTime',
  588. render:(text,record)=>{
  589. if(!record.theNumber){
  590. return text
  591. }else{
  592. return {
  593. children: text,
  594. props: {
  595. colSpan:0
  596. },
  597. }
  598. }
  599. }
  600. },
  601. {
  602. title: '营销员',
  603. fixed:false,
  604. dataIndex: 'salesmanName',
  605. key: 'salesmanName',
  606. render:(text,record)=>{
  607. if(!record.theNumber){
  608. return text
  609. }else{
  610. return {
  611. children: text,
  612. props: {
  613. colSpan:1
  614. },
  615. }
  616. }
  617. }
  618. }
  619. ],
  620. dataSource: [],
  621. };
  622. },
  623. search() {
  624. this.loadData(this.state.timeTypes);
  625. },
  626. reset() {
  627. this.state.superId = undefined;//部门机构清零
  628. this.state.taskStatus= undefined;//任务状态
  629. this.state.publishStatus= undefined;//公示状态
  630. this.loadData(0)
  631. this.setState({
  632. order:"false",
  633. weekColor:true,
  634. monthColor:false,
  635. quarterColor:false,
  636. yearColor:false
  637. })
  638. },
  639. week(){
  640. this.state.releaseDate[0] = undefined;//开始时间清零
  641. this.state.releaseDate[1] = undefined;//结束时间清零
  642. this.loadData(0);
  643. this.setState({
  644. weekColor:true,
  645. monthColor:false,
  646. quarterColor:false,
  647. yearColor:false
  648. })
  649. },
  650. month(){
  651. this.state.releaseDate[0] = undefined;//开始时间清零
  652. this.state.releaseDate[1] = undefined;//结束时间清零
  653. this.loadData(1);
  654. this.setState({
  655. weekColor:false,
  656. monthColor:true,
  657. quarterColor:false,
  658. yearColor:false
  659. })
  660. },
  661. quarter(){
  662. this.state.releaseDate[0] = undefined;//开始时间清零
  663. this.state.releaseDate[1] = undefined;//结束时间清零
  664. this.loadData(2);
  665. this.setState({
  666. weekColor:false,
  667. monthColor:false,
  668. quarterColor:true,
  669. yearColor:false
  670. })
  671. },
  672. year(){
  673. this.state.releaseDate[0] = undefined;//开始时间清零
  674. this.state.releaseDate[1] = undefined;//结束时间清零
  675. this.loadData(3);
  676. this.setState({
  677. weekColor:false,
  678. monthColor:false,
  679. quarterColor:false,
  680. yearColor:true
  681. })
  682. },
  683. //重构排序
  684. tabChange(pagination,filter,sorter){
  685. console.log(pagination)
  686. console.log(sorter)
  687. },
  688. componentWillMount() {
  689. //this.loadData();
  690. this.totalData(0);
  691. let times=new Date();
  692. let nowTime=times.getFullYear()+'年'+(times.getMonth()+1)+'月'+times.getDate()+'日';
  693. this.setState({
  694. Nowtime:nowTime
  695. })
  696. },
  697. changeList(arr) {
  698. const newArr = [];
  699. this.state.columns.forEach(item => {
  700. arr.forEach(val => {
  701. if (val === item.title) {
  702. newArr.push(item);
  703. }
  704. });
  705. });
  706. this.setState({
  707. changeList: newArr
  708. });
  709. },
  710. render() {
  711. const { RangePicker } = DatePicker;
  712. let departmentArr = this.state.departmentArr || [];
  713. return(
  714. <div className='set-content'>
  715. <p style={{fontSize:'20px',marginBottom:'10px'}}>订单统计报表</p>
  716. <div className="clearfix">
  717. <Tabs defaultActiveKey="1" className="test">
  718. <TabPane tab="搜索" key="1">
  719. <div className="user-search" style={{padding:'11px'}}>
  720. <Button type="primary" onClick={this.tabExel} style={{ float:'right' }}>导出到表格</Button>
  721. <span style={{fontSize:'16px'}}>部门机构 : </span>
  722. <Select placeholder="选择部门"
  723. style={{ width:'200px',marginRight:'10px' }}
  724. value={this.state.superId}
  725. onChange={(e) => { this.setState({ superId: e }) }} notFoundContent="未获取到上级组织列表">
  726. {this.state.contactsOption}
  727. </Select>
  728. <Select placeholder="任务状态"
  729. style={{ width: 150 ,marginRight:'10px'}}
  730. value={this.state.taskStatus}
  731. onChange={(e) => { this.setState({ taskStatus: e }) }}>
  732. {
  733. taskStatus.map(function (item) {
  734. return <Select.Option key={item.value} >{item.key}</Select.Option>
  735. })
  736. }
  737. </Select>
  738. <Select placeholder="公示状态"
  739. style={{ width: 150 ,marginRight:'10px'}}
  740. value={this.state.publishStatus}
  741. onChange={(e) => { this.setState({ publishStatus: e }) }}>
  742. {
  743. publishStatus.map(function (item) {
  744. return <Select.Option key={item.value} >{item.key}</Select.Option>
  745. })
  746. }
  747. </Select>
  748. <Button type="primary" onClick={this.search} style={{marginLeft:'10px',marginRight:'10px'}}>搜索</Button>
  749. <Button onClick={this.reset}>重置</Button>
  750. <div className="clearfix" style={{marginTop:"10px"}}>
  751. <Button onClick={this.week} style={{marginRight:'5px'}} type={this.state.weekColor?"primary":''}>本周</Button>
  752. <Button onClick={this.month} style={{marginRight:'5px'}} type={this.state.monthColor?"primary":''}>本月</Button>
  753. <Button onClick={this.quarter} style={{marginRight:'5px'}} type={this.state.quarterColor?"primary":''}>本季</Button>
  754. <Button onClick={this.year} style={{marginRight:'5px'}} type={this.state.yearColor?"primary":''}>本年</Button>
  755. <span className="titleTime" style={{marginRight:'5px',marginTop:"0px"}}>起止时间:</span>
  756. <RangePicker
  757. style={{marginRight:'5px',marginTop:"0px"}}
  758. value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
  759. this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
  760. onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }}
  761. />
  762. </div>
  763. </div>
  764. </TabPane>
  765. <TabPane tab="更改表格显示数据" key="2">
  766. <div style={{ marginLeft: 10 }}>
  767. <ChooseList
  768. columns={this.state.columns}
  769. changeFn={this.changeList}
  770. changeList={this.state.changeList}
  771. top={55}
  772. margin={11}
  773. />
  774. </div>
  775. </TabPane>
  776. </Tabs>
  777. </div>
  778. <div id='daochu'>
  779. {/* <div className="surfaceTitle">
  780. <span style={{marginTop:"10px"}}>订单统计报表</span>
  781. </div> */}
  782. <div className="patent-table" id='daochu'>
  783. <div className="scroll">
  784. <Spin spinning={this.state.loading}>
  785. <Table
  786. size="small"
  787. columns={
  788. this.state.changeList
  789. ? this.state.changeList
  790. : this.state.columns
  791. }
  792. dataSource={this.state.dataSource}
  793. bordered
  794. onChange={this.tabChange}
  795. pagination={false}
  796. />
  797. </Spin>
  798. </div>
  799. </div>
  800. </div>
  801. </div>
  802. )
  803. }
  804. });
  805. export default DiurnalStatistics;