inactive-screen.service.ts 377 Bytes
import { Injectable } from '@angular/core';
import { Router } from '@angular/router';

@Injectable({
  providedIn: 'root'
})
export class InactiveScreenService {
  timerReposo: any;

  constructor(
    private router: Router,
  ) { }

  startTimeOutInactividad() {
    this.timerReposo = setTimeout(() => {
      this.router.navigate(['cancelar-compra']);
    }, 90000);
  }
}