Skip to content

Commit

Permalink
#2 add fixed conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
tibor-postek-m2ms committed Mar 10, 2020
1 parent c79a8e3 commit c6b091e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 14 deletions.
20 changes: 7 additions & 13 deletions js/components/preview/moleculeGroups/redux/dispatchActions.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,6 @@ export const saveMoleculeGroupsToNglView = (molGroupList, stage, projectId) => d
}
};

export const loadMoleculeGroups = ({ stage, setOldUrl, oldUrl, onCancel, isStateLoaded, projectId }) => (
dispatch,
getState
) => {
export const selectFirstMolGroup = ({ summaryView }) => (dispatch, getState) => {
const currentMolGroup = getState().apiReducers.mol_group_list[0];
if (currentMolGroup) {
Expand All @@ -102,7 +98,7 @@ export const selectFirstMolGroup = ({ summaryView }) => (dispatch, getState) =>
}
};

export const loadMoleculeGroups = ({ summaryView, setOldUrl, oldUrl, onCancel, isStateLoaded }) => (
export const loadMoleculeGroups = ({ summaryView, setOldUrl, oldUrl, onCancel, isStateLoaded, projectId }) => (
dispatch,
getState
) => {
Expand Down Expand Up @@ -136,14 +132,12 @@ export const clearMoleculeGroupSelection = ({ getNglView }) => dispatch => {
const majorViewStage = getNglView(VIEWS.MAJOR_VIEW) && getNglView(VIEWS.MAJOR_VIEW).stage;
const summaryViewStage = getNglView(VIEWS.SUMMARY_VIEW) && getNglView(VIEWS.SUMMARY_VIEW).stage;

dispatch(reloadNglViewFromSnapshot(majorViewStage, VIEWS.MAJOR_VIEW))
.catch(error => {
throw new Error(error);
});
dispatch(reloadNglViewFromSnapshot(summaryViewStage, VIEWS.SUMMARY_VIEW))
.catch(error => {
throw new Error(error);
});
dispatch(reloadNglViewFromSnapshot(majorViewStage, VIEWS.MAJOR_VIEW)).catch(error => {
throw new Error(error);
});
dispatch(reloadNglViewFromSnapshot(summaryViewStage, VIEWS.SUMMARY_VIEW)).catch(error => {
throw new Error(error);
});

// Reset selection reducer
// remove sites selection
Expand Down
2 changes: 1 addition & 1 deletion js/components/session/modalStateSave.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ const ModalStateSave = memo(

function mapStateToProps(state) {
return {
saveType: state.sessionReducers.saveType,
saveType: state.snapshotReducers.saveType,
savingState: state.apiReducers.savingState,
latestSession: state.apiReducers.latestSession,
latestSnapshot: state.apiReducers.latestSnapshot,
Expand Down

0 comments on commit c6b091e

Please sign in to comment.