I'm trying to populate data from a < Select > component from Material UI v 1.0.0.0 beta but it's not working.
This is part of my code:
This is inside the render() method.
<Select
value={this.state.DivisionState}
onChange={this.handleChangeDivision}
>
{this.renderDivisionOptions()}
</Select>
And here I use the MenuItem tag to populate de value coming from a WS
renderDivisionOptions() {
return this.state.DivisionData.map((dt, i) => {
return (
<MenuItem
key={i}
value={dt.divDeptShrtDesc}>
</MenuItem>
);
});
}
This was working in the latest version of Material UI using the DropDown tag and MenuItem ej. "< DropDown > < MenuItem >....."
Some help will be nice.
Regards
I'm getting and error when I try to interact with the Select component..
this.state.DivisionData
set? – Josan Iracheta