Guest User

Untitled

a guest
Jan 22nd, 2018
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. public grants = (): Observable<Grants> => {
  2. return this._http.get(this.actionUrl + '/grants', { withCredentials: true })
  3. .map((response: Response) => response.json() as Grants)
  4. .catch(this.handleError);
  5. }
  6.  
  7. constructor(protected authService: AuthService) {
  8. this.authService.grants().subscribe(grants => {
  9. this.userAccess = grants;
  10. this.showComponents(grants); // Show the components that user has access to based the grants answer
  11. });
  12. }
Add Comment
Please, Sign In to add comment