Added basic functionality related to reading groups
[arvados-workbench2.git] / src / components / api-token / api-token.tsx
index daebe9b93ca5292952da8107fbc5c9864eaacc80..34e2d64c110ca43a55cba2c7f0f2e11e361c2446 100644 (file)
@@ -5,7 +5,8 @@
 import { Redirect, RouteProps } from "react-router";
 import * as React from "react";
 import { connect, DispatchProp } from "react-redux";
-import authActions, { getUserDetails } from "../../store/auth/auth-action";
+import authActions from "../../store/auth/auth-action";
+import { authService, projectService } from "../../services/services";
 
 interface ApiTokenProps {
 }
@@ -22,7 +23,8 @@ class ApiToken extends React.Component<ApiTokenProps & RouteProps & DispatchProp
         const search = this.props.location ? this.props.location.search : "";
         const apiToken = ApiToken.getUrlParameter(search, 'api_token');
         this.props.dispatch(authActions.SAVE_API_TOKEN(apiToken));
-        this.props.dispatch(getUserDetails());
+        this.props.dispatch(authService.getUserDetails());
+        this.props.dispatch(projectService.getTopProjectList());
     }
     render() {
         return <Redirect to="/"/>