import { Component, OnInit } from '@angular/core';
import { NavController } from '@ionic/angular';
import { NavigationService } from '../navigation.service';
@Component({
selector: 'app-office',
templateUrl: './office.page.html',
styleUrls: ['./office.page.scss'],
})
export class OfficePage implements OnInit {
name: string;
constructor(private navCtrl: NavController, private navigationService: NavigationService) {
// Getting the value of name from the JSON data sent from the home page
this.name = this.navigationService.getData().name;
}
goBack(){
this.navCtrl.goBack('/home');
}
ngOnInit() {
}
}