mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
profile picture done
This commit is contained in:
@@ -47,14 +47,25 @@
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="icon font-45-em" src='assets/images/icons-profile.svg'></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="icon font-45-em" src='assets/images/theme/gov/icons-profile.svg'></ion-icon> -->
|
||||
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Presidente da República' " class="icon font-45-em"
|
||||
src='assets/images/presidente.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Ministro e Director do Gabinete do PR' " class="icon font-45-em"
|
||||
src='assets/images/ministro.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Secretário Geral' " class="icon font-45-em"
|
||||
src='assets/images/secretaria_geral.png'>
|
||||
<div *ngIf="profilePicture == ''" class="profile-image">
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Presidente da República' " class="profile-image"
|
||||
src='assets/images/presidente.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Ministro e Director do Gabinete do PR' " class="profile-image"
|
||||
src='assets/images/ministro.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Secretário Geral' " class="profile-image"
|
||||
src='assets/images/secretaria_geral.png'>
|
||||
|
||||
<ion-icon
|
||||
*ngIf="loggeduser.RoleDescription != 'Presidente da República'&& loggeduser.RoleDescription != 'Ministro e Director do Gabinete do PR' && loggeduser.RoleDescription != 'Secretário Geral' "
|
||||
class="icon font-45-em" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
|
||||
</div>
|
||||
|
||||
|
||||
<div *ngIf="profilePicture != ''" class="profile-image">
|
||||
<img class="profile-image" src={{profilePicture}}>
|
||||
</div>
|
||||
|
||||
|
||||
<ion-icon *ngIf="loggeduser.RoleDescription != 'Presidente da República'&& loggeduser.RoleDescription != 'Ministro e Director do Gabinete do PR' && loggeduser.RoleDescription != 'Secretário Geral' " class="icon font-45-em" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
|
||||
|
||||
<div class="profile-text">
|
||||
<div *ngIf="notificationLength > 0" class="icon-badge" style="right: -6px;top: 38px;top: -6px;">
|
||||
@@ -200,16 +211,23 @@
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'doneIt' " class="icon" src='assets/images/theme/doneIt/icons-profile.svg'></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="icon" src='assets/images/theme/gov/icons-profile.svg'></ion-icon> -->
|
||||
|
||||
<div *ngIf="profilePicture == ''" class="profile-image">
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Presidente da República' " class="profile-image"
|
||||
src='assets/images/presidente.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Ministro e Director do Gabinete do PR' " class="profile-image"
|
||||
src='assets/images/ministro.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Secretário Geral' " class="profile-image"
|
||||
src='assets/images/secretaria_geral.png'>
|
||||
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Presidente da República' " class="profile-image"
|
||||
src='assets/images/presidente.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Ministro e Director do Gabinete do PR' " class="profile-image"
|
||||
src='assets/images/ministro.png'>
|
||||
<img *ngIf="loggeduser.RoleDescription == 'Secretário Geral' " class="profile-image"
|
||||
src='assets/images/secretaria_geral.png'>
|
||||
<ion-icon
|
||||
*ngIf="loggeduser.RoleDescription != 'Presidente da República'&& loggeduser.RoleDescription != 'Ministro e Director do Gabinete do PR' && loggeduser.RoleDescription != 'Secretário Geral' "
|
||||
class="icon" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
|
||||
</div>
|
||||
|
||||
<ion-icon *ngIf="loggeduser.RoleDescription != 'Presidente da República'&& loggeduser.RoleDescription != 'Ministro e Director do Gabinete do PR' && loggeduser.RoleDescription != 'Secretário Geral' " class="icon" src='assets/images/theme/gov/icons-profile.svg'></ion-icon>
|
||||
|
||||
<div *ngIf="profilePicture != ''" class="profile-image">
|
||||
<img class="profile-image" src={{profilePicture}}>
|
||||
</div>
|
||||
|
||||
<div class="profile-text">
|
||||
<div *ngIf="notificationLength > 0" class="icon-badge" style="right: -6px;top: 38px;top: -6px;">
|
||||
|
||||
@@ -38,6 +38,7 @@ export class HeaderPage implements OnInit {
|
||||
showProfileModal = false
|
||||
permissionList = new PermissionList();
|
||||
notificationCount: number = 0;
|
||||
profilePicture = "";
|
||||
|
||||
|
||||
constructor(
|
||||
@@ -52,7 +53,8 @@ export class HeaderPage implements OnInit {
|
||||
private eventTriger: EventTrigger,
|
||||
public ActiveTabService: ActiveTabService,
|
||||
private notificationService: NotificationsService,
|
||||
private cdRef: ChangeDetectorRef
|
||||
private cdRef: ChangeDetectorRef,
|
||||
private storageService: StorageService,
|
||||
) {
|
||||
this.loggeduser = SessionStore.user;
|
||||
router.events.subscribe((val) => {
|
||||
@@ -76,9 +78,19 @@ export class HeaderPage implements OnInit {
|
||||
async ngOnInit() {
|
||||
this.hideSearch();
|
||||
this.notificationLengthData();
|
||||
this.getProfilpicture();
|
||||
|
||||
}
|
||||
|
||||
getProfilpicture() {
|
||||
this.storageService.get(this.SessionStore.user.RoleID.toString()).then((picture) => {
|
||||
console.log(picture)
|
||||
this.profilePicture = picture
|
||||
}).catch((error ) => {
|
||||
this.profilePicture = "";
|
||||
})
|
||||
}
|
||||
|
||||
updateReciveNotification() {
|
||||
this.eventTriger.getObservable().subscribe((event) => {
|
||||
if (event.notification == "recive") {
|
||||
|
||||
Reference in New Issue
Block a user