Behavior:
The state for project details is reset every time the projects as a whole are updated. This causes the project details to close (if they are open) and also for the individual auto refresh to be reset.
To replicate:
- Change the interval timer to 1000ms on row 87 of ProjectList.js
autoRefreshProjectStatuses = () => {
if(this.state.projects.length && !this.state.authoRefreshIntervalId) {
const authoRefreshIntervalId = setInterval(() => {
this.loadProjectStatuses();
}, 20000) // <- Change to 1000
this.setState({authoRefreshIntervalId})
} else if(!this.state.projects.length && this.state.authoRefreshIntervalId) {
clearInterval(this.state.authoRefreshIntervalId);
this.setState({authoRefreshIntervalId: null})
}
}
- Start the application
- Try to open project details.
Step 1 is not necessary, but without it, you will have to wait 20 sec instead of 1 for the bug to appear.
Expected behavior:
Opened project details should stay open even after refreshing projects.
The project should still be set to auto update enable if it has been set to enabled.