import { Injectable } from '@angular/core';
import { BehaviorSubject, Subject } from 'rxjs';
import { LoginTokenViewModel } from '../entity/Auth';

@Injectable({
  providedIn: 'root'
})
export class LoginUserService {

  userAccess: LoginTokenViewModel;
  signalRInitialized = new BehaviorSubject<string>(null);
  constructor() {

  }

  setSignalRConnectionId(id: string) {
    this.userAccess.signalRSessionId = id;
  }

  public get sessionTabId(): string {
    return sessionStorage.getItem('tabId');
  }
  public set sessionTabId(v: string) {
    sessionStorage.setItem('tabId', v);
  }

}
