For a plugin I\'m using I have to have a state that looks like this:
getInitialState() { return { invalid: true, access: { access_code: \'\',
I had this same issue too(not the same context) anyways, i did the code below in my own work and it worked perfectly
this.setState({ access: { ...this.state.access, hospital_id: 1, }, });