This commit is contained in:
Peter Maquiran
2022-10-11 14:53:48 +01:00
parent c2e9770153
commit a2fdfca19d
3 changed files with 14 additions and 26 deletions
+11 -22
View File
@@ -34,7 +34,7 @@ export class HeaderPage implements OnInit {
production = environment.production
environment = environment
isProfileOpen = false
canOpenSearch = false
constructor(
private router: Router,
@@ -51,7 +51,6 @@ export class HeaderPage implements OnInit {
this.loggeduser = SessionStore.user;
router.events.subscribe((val) => {
this.showSearch = false;
this.isProfileOpen = false
this.canOpenSearch = true;
});
@@ -110,7 +109,6 @@ export class HeaderPage implements OnInit {
}
}
canOpenSearch = true
async openSearch() {
let classs, showSearchInput, type;
@@ -122,8 +120,6 @@ export class HeaderPage implements OnInit {
showSearchInput = false
}
if (window.location.pathname.startsWith('/home/agenda')) {
type = "Agenda"
} else if (window.location.pathname.startsWith('/home/gabinete-digital')) {
@@ -188,24 +184,17 @@ export class HeaderPage implements OnInit {
}
if(this.isProfileOpen == false) {
const modal = await this.modalController.create({
component: ProfilePage,
cssClass: 'model profile-modal search-submodal',
componentProps: {
}
});
await modal.present();
this.isProfileOpen = true;
const modal = await this.modalController.create({
component: ProfilePage,
cssClass: 'model profile-modal search-submodal',
componentProps: {
}
});
await modal.present();
modal.onDidDismiss().then(() => {
this.isProfileOpen = false;
this.notificationLengthData()
})
}
modal.onDidDismiss().then(() => {
this.notificationLengthData()
})
}