This is the codeAbility Sharing Platform! Learn more about the codeAbility Sharing Platform.

Skip to content
Snippets Groups Projects
bookmarkInfo.component.ts 895 B
Newer Older
import { Component } from '@angular/core';
Michael Breu's avatar
Michael Breu committed
import { WatchlistManager } from 'app/shared/watchlist/watchlist-manager';
Michael Breu's avatar
Michael Breu committed
import { IUserWatchList, UserWatchListWithContent } from 'app/shared/model/user-watch-list.model';
Michael Breu's avatar
Michael Breu committed

@Component({
  selector: 'jhi-bookmark-info',
  templateUrl: './bookmarkInfo.component.html',
  styleUrls: ['./bookmarkInfo.component.scss'],
Michael Breu's avatar
Michael Breu committed
})
Michael Breu's avatar
Michael Breu committed
export class BookmarkInfoComponent {
  constructor(private watchlistManager: WatchlistManager) {}
  getMyWatchLists(): IUserWatchList[] | undefined {
    return this.watchlistManager.getMyWatchLists();
  }
Michael Breu's avatar
Michael Breu committed

  getCurrentWatchList(): UserWatchListWithContent | undefined {
    return this.watchlistManager.getCurrentWatchList();
  }
Michael Breu's avatar
Michael Breu committed

  setCurrentWatchList(watchListName: string): void {
    this.watchlistManager.setCurrentWatchList(watchListName);
  }
Michael Breu's avatar
Michael Breu committed

  handleForCurrentWatchlist(exerciseId: string) {
    alert(exerciseId);
  }
Michael Breu's avatar
Michael Breu committed
}