Skip to content

Commit

Permalink
Merge branch 'master_v.0.3' into #14
Browse files Browse the repository at this point in the history
  • Loading branch information
tibor-postek-m2ms authored Mar 19, 2020
2 parents e5758f7 + 4778b68 commit 674ebde
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions js/components/landing/Landing.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { resetCurrentCompoundsSettings } from '../preview/compounds/redux/action
import { resetProjectsReducer } from '../projects/redux/actions';

const Landing = memo(
({ resetSelectionState, resetTargetState, resetCurrentCompoundsSettings, resetProjectsReducer }) => {
({ resetSelectionState, resetTargetState, resetCurrentCompoundsSettings, resetProjectsReducer, history }) => {
const { setSnackBarTitle } = useContext(HeaderContext);
const [loginText, setLoginText] = useState("You're logged in as " + DJANGO_CONTEXT['username']);

Expand Down Expand Up @@ -54,7 +54,7 @@ const Landing = memo(
</Grid>
<Grid item xs={8}>
{/*<SessionList />*/}
<Projects />
<Projects history={history} />
</Grid>
</Grid>
);
Expand Down
2 changes: 1 addition & 1 deletion js/components/preview/Preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ const useStyles = makeStyles(theme => ({
}
}));

const Preview = memo(({ isStateLoaded, headerHeight }) => {
const Preview = memo(({ isStateLoaded, headerHeight, match }) => {
const classes = useStyles();
const theme = useTheme();

Expand Down
2 changes: 1 addition & 1 deletion js/components/preview/withLoadingProtein.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const withLoadingProtein = WrappedComponent => {
shouldLoadProtein(nglViewList, isStateLoaded, projectId);
}, [isStateLoaded, nglViewList, projectId, shouldLoadProtein]);

return <WrappedComponent isStateLoaded={isStateLoaded} {...rest} />;
return <WrappedComponent isStateLoaded={isStateLoaded} {...rest} match={match} />;
});

function mapStateToProps(state) {
Expand Down
2 changes: 1 addition & 1 deletion js/components/projects/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ export const Projects = memo(({}) => {
</TableFooter>
</Table>
</Panel>
<ProjectModal />
<ProjectModal history={history} />
</>
);
});
1 change: 1 addition & 0 deletions js/components/projects/projectModal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ export const ProjectModal = memo(({}) => {
const tags = response.data.tags;

dispatch(setCurrentProject({ projectID, authorID, title, description, targetID, tags }));

// create project_target relationShip on BE
history.push(`${URLS.projects}${projectID}`);
})
Expand Down
2 changes: 1 addition & 1 deletion js/components/target/withUpdatingTarget.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export const withUpdatingTarget = WrappedContainer => {
} else if (target_on === undefined) {
return <HandleUnrecognisedTarget />;
} else {
return <WrappedContainer {...rest} />;
return <WrappedContainer {...rest} match={match} />;
}
}
);
Expand Down

0 comments on commit 674ebde

Please sign in to comment.