从"Blog"仓库中分离出来

This commit is contained in:
小海
2019-11-28 19:26:45 +08:00
commit c2aaf280db
616 changed files with 104128 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
import {Component, OnInit} from '@angular/core';
import {UserService} from '../../services/user/user.service';
@Component({
selector: 'app-header',
templateUrl: './header.component.html',
styleUrls: ['./header.component.css']
})
export class HeaderComponent implements OnInit {
constructor(public userService: UserService) {
}
// 菜单是否可见
public visible: boolean = false;
// 导航是否可见(手机显示时)
public visibleOfMenu: boolean = false;
ngOnInit() {
this.userService.getUserInfo();
this.userService.http.visit();
}
logout() {
this.userService.logout();
}
}