aboutsummaryrefslogtreecommitdiff
path: root/frontend/src/app/_elements/item-predictor/item-predictor.component.ts
blob: 246032e0bf9dff4ebf9a9a50f5300374c0760077 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import { Component, Input, OnInit } from '@angular/core';
import { Router } from '@angular/router';
import Predictor from 'src/app/_data/Predictor';

@Component({
  selector: 'app-item-predictor',
  templateUrl: './item-predictor.component.html',
  styleUrls: ['./item-predictor.component.css']
})
export class ItemPredictorComponent implements OnInit {

  @Input() predictor: Predictor = new Predictor();

  constructor(private router: Router) { }

  ngOnInit(): void {
  }

  openPredictor() {
    this.router.navigate(['predict/'+ this.predictor._id]);
    }

}