|
|
@ -1,6 +1,7 @@
|
|
|
|
import { Component, OnInit } from '@angular/core';
|
|
|
|
import { Component, OnInit } from '@angular/core';
|
|
|
|
import { User } from './models/user';
|
|
|
|
import { User } from './models/user';
|
|
|
|
import { DatasharingService } from './services/datasharing.service';
|
|
|
|
import { DatasharingService } from './services/datasharing.service';
|
|
|
|
|
|
|
|
import { SelfService } from './services/selfservice/self.service';
|
|
|
|
|
|
|
|
|
|
|
|
@Component({
|
|
|
|
@Component({
|
|
|
|
selector: 'app-root',
|
|
|
|
selector: 'app-root',
|
|
|
@ -8,7 +9,7 @@ import { DatasharingService } from './services/datasharing.service';
|
|
|
|
styleUrls: ['./app.component.sass']
|
|
|
|
styleUrls: ['./app.component.sass']
|
|
|
|
})
|
|
|
|
})
|
|
|
|
export class AppComponent implements OnInit {
|
|
|
|
export class AppComponent implements OnInit {
|
|
|
|
constructor(private data: DatasharingService) { }
|
|
|
|
constructor(private data: DatasharingService, private selfservice: SelfService) { }
|
|
|
|
|
|
|
|
|
|
|
|
userInfo: User
|
|
|
|
userInfo: User
|
|
|
|
|
|
|
|
|
|
|
@ -31,5 +32,8 @@ export class AppComponent implements OnInit {
|
|
|
|
this.userInfo = user;
|
|
|
|
this.userInfo = user;
|
|
|
|
console.log(this.userInfo);
|
|
|
|
console.log(this.userInfo);
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
if(this.loggedIn != true){
|
|
|
|
|
|
|
|
this.selfservice.checkIfLoggedIn();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|