- Eula Progress

Signed-off-by: Dave Richer <dave@imexsystems.ca>
This commit is contained in:
Dave Richer
2024-01-19 20:55:15 -05:00
parent 06a8d4257a
commit 6937f33134
21 changed files with 235 additions and 83 deletions

View File

@@ -18,7 +18,7 @@ const INITIAL_STATE = {
loading: false,
},
authLevel: 0,
eulaContentToShow:null
currentEula: null,
};
const userReducer = (state = INITIAL_STATE, action) => {
@@ -65,11 +65,19 @@ const userReducer = (state = INITIAL_STATE, action) => {
loading: false,
},
};
case UserActionTypes.EULA_ACCEPTED:
return {
...state,
currentUser:{...state.currentUser, eulaIsAccepted: true},
currentEula: null,
};
case UserActionTypes.SIGN_IN_SUCCESS:
const{ currentEula,...currentUser} = action.payload
return {
...state,
loginLoading: false,
currentUser: action.payload,
currentUser: currentUser,
currentEula,
error: null,
};
case UserActionTypes.SIGN_OUT_SUCCESS: