Dropdown menu on paging does not work
See original GitHub issueHi, i don’t know what wrong with my code but the dropdown menu on paging does not show anything when i click, the other functions work well:
import boostrapTable from 'react-bootstrap-table/dist/react-bootstrap-table-all.min.css';
import React from 'react';
import { Grid } from 'react-mdl';
import { Col} from 'react-bootstrap';
import { BootstrapTable, TableHeaderColumn } from 'react-bootstrap-table';
import Page from '../Page/PageComponent';
const userData = [];
export default class Program extends React.Component {
static propTypes = {
viewer: React.PropTypes.object.isRequired,
};
render() {
function imageFormatter(cell, row) {
if (cell) {
return '<image src="' + cell + '" class="img-circle"/>';
}
return '<i style="height: 50px; width:50px; font-size: 50px" class="material-icons mdl-list__item-avatar">person</i>';
}
if (this.props.viewer != null) {
return (
<div>
<Page heading='Users'>
<Grid>
{this.props.viewer.groups.map((group) => {
if (group.connections.length > 0) {
return group.connections.map((connection) => {
if (!connection.user) {
return ('');
}
userData.push(connection.user);
});
}
})
}
<Col xs={12} sm={12} md={10} style={{ marginLeft: 50, marginRight: 50 }}>
<BootstrapTable
data={userData}
hover={true}
pagination={true}
search={true}
exportCSV={true}>
<TableHeaderColumn dataField='connectionID' isKey={true} hidden={true} dataSort={true}>ID</TableHeaderColumn>
<TableHeaderColumn width='70px' dataField='photo' dataFormat={imageFormatter}>Photo</TableHeaderColumn>
<TableHeaderColumn dataField='name' dataSort={true}>Name</TableHeaderColumn>
<TableHeaderColumn dataField='roles' dataSort={true}>Roles</TableHeaderColumn>
</BootstrapTable>
</Col>
</Grid>
</Page>
</div>
);
}
return (
<div>
<Page heading='Users'>
<h2>No Users</h2>
</Page>
</div>
);
}
}
I also got the same problem with issue#781, please fix the width of the table header to match table body. Thank you, your work is amazing
Issue Analytics
- State:
- Created 7 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Bootstrap Table pagination dropdown not working - Rails
The pagination works fine but the dropdown for choosing the page size does not open. It looks like a clickable dropdown menu but...
Read more >Problems with Grid paging after filling it with DropDownList ...
Hello team. I am filling a Grid based on the selection I make of the DropDownList, this is achieved by sending the value...
Read more >Dropdown menu not working after using custom PJAX code ...
This custom code seems to have affected my dropdown menu in some capacity to where it will open on the first page, but...
Read more >pagination not working when I select the page from dropdown
this is my pagination layout, whenever I select the page from dropdown menu the pagination does not work but it works fine when...
Read more >Dropdowns · Bootstrap v5.1
For this reason, Bootstrap does not expect (nor automatically add) any of the ... Wrap the dropdown's toggle (your button or link) and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You are right, actually the jQuery depend from
bootstrap.js
. Anyway, this both dependencies will be remove in the near future(v3.0.0-beta.2
)remember add jquery and bootstrap.js, but if you want to get rid of them, you can try v3.0.0-beta.6. Your choice.