Skip to content

Commit

Permalink
fix #484
Browse files Browse the repository at this point in the history
  • Loading branch information
AllenFang committed Jun 2, 2016
1 parent ddf7fc9 commit 4739d43
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/BootstrapTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -705,6 +705,8 @@ class BootstrapTable extends Component {
dataSize = this.store.getDataNum();
}
const { options } = this.props;
if (Math.ceil(dataSize / this.state.sizePerPage) <= 1 &&
this.props.ignoreSinglePage) return null;
return (
<div className='react-bs-table-pagination'>
<PaginationList
Expand Down Expand Up @@ -964,7 +966,8 @@ BootstrapTable.propTypes = {
dataTotalSize: PropTypes.number
}),
exportCSV: PropTypes.bool,
csvFileName: PropTypes.string
csvFileName: PropTypes.string,
ignoreSinglePage: PropTypes.bool
};
BootstrapTable.defaultProps = {
height: '100%',
Expand Down Expand Up @@ -1046,7 +1049,8 @@ BootstrapTable.defaultProps = {
dataTotalSize: 0
},
exportCSV: false,
csvFileName: 'spreadsheet.csv'
csvFileName: 'spreadsheet.csv',
ignoreSinglePage: false
};

export default BootstrapTable;

0 comments on commit 4739d43

Please sign in to comment.