var React = require('react'); var ReactBootstrap = require('react-bootstrap'); var ButtonGroup = ReactBootstrap.ButtonGroup; var DropdownButton = ReactBootstrap.DropdownButton; var MenuItem = ReactBootstrap.MenuItem; var BarChart = require('../components/BarChart'); var RatioBarChart = require('../components/RatioBarChart'); module.exports = React.createClass({ displayName: "LunchStats", getInitialState: function() { return { selectedReportId: null }; }, selectReport: function(reportId) { if (reportId == "suggestion-veto-ratio") { this.props.fetchReport("suggestions"); this.props.fetchReport("vetoed-suggestions"); } else if (reportId == "suggestor-veto-ratio") { this.props.fetchReport("suggestors"); this.props.fetchReport("vetoed-suggestors"); } else { this.props.fetchReport(reportId); } this.setState({ selectedReportId: reportId }); }, render: function() { var chart = (