import { Component, OnInit } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { SSOService } from 'src/app/core/services/sso.service';

@Component({
  selector: 'app-single-sign-on',
  templateUrl: './single-sign-on.component.html',
})
export class SingleSignOnComponent implements OnInit {
  IPData;
  constructor(
    private route: ActivatedRoute,
    private ssoService: SSOService,
  ) {
    this.route.queryParams.subscribe((params) => {
      ssoService.validateSSOLogin(params['key'], params['LoginUserId']);
      if (params['langcode']) {
        sessionStorage.setItem('LangCode', params['langcode']);
      }
    });
  };
  ngOnInit(): void {

  }

}
