From 2c2acf99d0c1521e7a4be38364a70317dc103188 Mon Sep 17 00:00:00 2001 From: Luis Suarez Date: Tue, 4 Feb 2020 12:13:21 -0400 Subject: [PATCH] quitar TimeOut en pantalla mensaje-final --- .../mensaje-final/mensaje-final.component.ts | 29 +++++++++------------- 1 file changed, 12 insertions(+), 17 deletions(-) diff --git a/src/app/modules/mensaje-final/mensaje-final.component.ts b/src/app/modules/mensaje-final/mensaje-final.component.ts index e85f4b8..465a6c0 100644 --- a/src/app/modules/mensaje-final/mensaje-final.component.ts +++ b/src/app/modules/mensaje-final/mensaje-final.component.ts @@ -1,39 +1,34 @@ -import { Component, OnInit } from '@angular/core'; -import { ArticuloService } from 'src/app/services/articulo/articulo.service'; -import { Router } from '@angular/router'; +import { Component, OnInit } from "@angular/core"; +import { ArticuloService } from "src/app/services/articulo/articulo.service"; +import { Router } from "@angular/router"; @Component({ - selector: 'app-mensaje-final', - templateUrl: './mensaje-final.component.html', - styleUrls: ['./mensaje-final.component.scss'] + selector: "app-mensaje-final", + templateUrl: "./mensaje-final.component.html", + styleUrls: ["./mensaje-final.component.scss"] }) export class MensajeFinalComponent implements OnInit { timer: any; constructor( public articuloService: ArticuloService, - private router: Router, - ) { } + private router: Router + ) {} ngOnInit() { - this.timer = setTimeout(() => { - this.goToSplash(); - }, 15000); this.mediaPantalla(); } - OnDestroy() { - clearTimeout(this.timer); - } + OnDestroy() {} goToSplash() { this.articuloService.cleanShoppingCar(); - this.router.navigate(['']); + this.router.navigate([""]); } mediaPantalla() { - if ($('body').hasClass('media-pantalla')) { - $('body').removeClass('media-pantalla'); + if ($("body").hasClass("media-pantalla")) { + $("body").removeClass("media-pantalla"); } } } -- 1.9.1