From fe1a0589213e7a587cd04326cc2ae3f212380d7c Mon Sep 17 00:00:00 2001 From: Florian Hartwich Date: Sun, 6 Aug 2017 11:55:34 +0200 Subject: [PATCH] Fix redirect on war submit --- static/src/app/statistic/war-submit/war-submit.component.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/static/src/app/statistic/war-submit/war-submit.component.ts b/static/src/app/statistic/war-submit/war-submit.component.ts index da33ba7..22fc580 100644 --- a/static/src/app/statistic/war-submit/war-submit.component.ts +++ b/static/src/app/statistic/war-submit/war-submit.component.ts @@ -44,15 +44,13 @@ export class WarSubmitComponent { } saveWar() { - let file: File; - console.log(this.war.date) if (this.fileList) { - file = this.fileList[0]; + const file: File = this.fileList[0]; this.loading = true; this.warService.submitWar(this.war, file) .subscribe(war => { - this.router.navigate([war._id], {relativeTo: this.route}); + this.router.navigate(['../war/' + war._id], {relativeTo: this.route}); }, error => { this.error = error._body.error.message;