import { Component, OnInit } from '@angular/core';
import {NavController} from "@ionic/angular";
import {Router} from "@angular/router";

@Component({
  selector: 'app-blogdetail',
  templateUrl: './blogdetail.page.html',
  styleUrls: ['./blogdetail.page.scss'],
})
export class BlogdetailPage implements OnInit {


  tabs = 'about';

  blogData: any;
  constructor(
      private navctr: NavController,
      private router: Router
  ) {

    this.blogData  =  this.router.getCurrentNavigation().extras.state;
console.log("XXXXX 1",   this.router.getCurrentNavigation().extras);
console.log("XXXXX 2",   this.router.getCurrentNavigation().extras.state);
console.log("XXXXX 3",   this.router.getCurrentNavigation().extras.state.ID);
  }

  ngOnInit() {
  }

  onBack() {
    this.navctr.back();
  }

  onMentor() {
    this.router.navigate(['mentor']);
  }

  onEnroll() {
    this.router.navigate(['enroll']);
  }



}
