mirror of
https://git.rwth-aachen.de/acs/public/villas/web/
synced 2025-03-30 00:00:13 +01:00
Fix simulator data discarding
This commit is contained in:
parent
ac19c3c48d
commit
fa9fc61725
2 changed files with 1 additions and 3 deletions
|
@ -48,7 +48,6 @@ class NewSimulationModelDialog extends Component {
|
|||
|
||||
onClose(canceled) {
|
||||
if (canceled === false) {
|
||||
console.log(this.state);
|
||||
this.props.onClose(this.state);
|
||||
} else {
|
||||
this.props.onClose();
|
||||
|
@ -70,7 +69,6 @@ class NewSimulationModelDialog extends Component {
|
|||
}
|
||||
|
||||
if (e.target.id === 'simulator') {
|
||||
console.log(e.target.value);
|
||||
this.setState({ simulator: JSON.parse(e.target.value) });
|
||||
} else {
|
||||
this.setState({ [e.target.id]: e.target.value });
|
||||
|
|
|
@ -55,7 +55,7 @@ class SimulationDataStore extends ReduceStore {
|
|||
|
||||
case 'simulatorData/data-changed':
|
||||
// check if data is required, otherwise discard
|
||||
if (state[action.node._id] == null || state[action.data.id] == null) {
|
||||
if (state[action.node._id] == null || state[action.node._id][action.data.id] == null) {
|
||||
return state;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue