Fix trigger
Some checks failed
FarmMaps.Develop/FarmMapsLib/pipeline/head There was a failure building this commit

This commit is contained in:
Willem Dantuma
2021-04-12 15:52:42 +02:00
parent a6d3b208b0
commit 1380d7169a
6 changed files with 36 additions and 40 deletions

View File

@@ -1,6 +1,5 @@
import { Input } from '@angular/core';
import { Component, OnInit,AfterViewInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { Component, OnInit } from '@angular/core';
import { IUser } from '../../models/user';
import {Store} from '@ngrx/store';
@@ -12,27 +11,27 @@ import * as appActions from '../../actions/app-common.actions';
templateUrl: './help-menu.component.html',
styleUrls: ['./help-menu.component.scss']
})
export class HelpMenuComponent implements OnInit, AfterViewInit {
export class HelpMenuComponent implements OnInit {
@Input() user:IUser;
@Input() showMenu:boolean;
public noContent: boolean = true;
constructor(private store: Store<appReducers.State>, private route: ActivatedRoute) { }
constructor(private store: Store<appReducers.State>) { }
ngOnInit(): void {
}
ngAfterViewInit() {
this.route.children.forEach((entry) => {
if(entry.outlet=="help-menu") {
this.noContent=false;
}
});
}
toggle(event:MouseEvent) {
event.stopPropagation();
this.store.dispatch(new appActions.ToggleHelpMenu());
}
activateRoute() {
this.noContent=false;
}
deActivateRoute() {
this.noContent=true;
}
}