From 1954586665e59031eae5d2c8b2cdb08f83d64fcb Mon Sep 17 00:00:00 2001 From: afc163 Date: Mon, 27 Jul 2015 15:38:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=9C=AC=E5=9C=B0=E6=A8=A1?= =?UTF-8?q?=E5=BC=8F=E4=B8=8B=20pagination=20=E4=B8=BA=20false=20=E6=97=B6?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=97=A0=E6=B3=95=E6=98=BE=E7=A4=BA=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/table/index.jsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/table/index.jsx b/components/table/index.jsx index 00fafac0a..628577b5e 100644 --- a/components/table/index.jsx +++ b/components/table/index.jsx @@ -218,7 +218,7 @@ export default React.createClass({ }, renderPagination() { // 强制不需要分页 - if (this.state.pagination === false) { + if (this.props.pagination === false) { return ''; } let classString = 'ant-table-pagination'; @@ -248,7 +248,7 @@ export default React.createClass({ } return [pagination, filters, sorter]; }, - fetch: function() { + fetch() { if (this.mode === 'remote') { // remote 模式使用 this.dataSource let dataSource = this.dataSource; @@ -283,8 +283,8 @@ export default React.createClass({ let data = this.props.dataSource; let current, pageSize; // 如果没有分页的话,默认全部展示 - if (this.state.pagination === false) { - pageSize = Number.POSITIVE_INFINITY; + if (this.props.pagination === false) { + pageSize = Number.MAX_VALUE; current = 1; } else { pageSize = this.state.pagination.pageSize;