File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
frontend/src/pages/SubProjects Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -71,6 +71,16 @@ class SubProjectContainer extends Component {
71
71
}
72
72
73
73
componentDidUpdate ( prevProps ) {
74
+ if ( this . props . router . location . pathname !== prevProps . router . location . pathname ) {
75
+ const newProjectId = this . props . router . location . pathname . split ( "/" ) [ 2 ] ;
76
+ if ( newProjectId !== this . projectId ) {
77
+ this . setState ( { isDataFetched : false } ) ;
78
+ this . projectId = newProjectId ;
79
+ this . props . setSelectedView ( this . projectId , "project" ) ;
80
+ this . props . fetchAllProjectDetails ( this . projectId , true ) ;
81
+ this . setState ( { isDataFetched : true } ) ;
82
+ }
83
+ }
74
84
const searchTermChanges = this . props . searchTerm !== prevProps . searchTerm ;
75
85
const projectsChange = ! _isEqual ( this . props . subProjects , prevProps . subProjects ) ;
76
86
You can’t perform that action at this time.
0 commit comments