Hides "Contact-Support" footer option when user not logged in.
This commit is contained in:
parent
89b98f5377
commit
bc0fd36722
|
@ -20,7 +20,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="row d-flex flex-reverse">
|
||||
<div class="col-6 text-center">
|
||||
<div *ngIf="isAuthenticated()" class="col-6 text-center">
|
||||
<p class="option" (click)="openContactDialog()" [ngClass]="{'option-active': this.router.url === '/contact-support'}">
|
||||
<!-- <i class="fa fa-envelope-open pr-2 pt-1"></i> -->
|
||||
{{'FOOTER.CONTACT-SUPPORT' | translate}}</p>
|
||||
|
|
|
@ -13,6 +13,7 @@ import { FormService } from '@common/forms/form-service';
|
|||
import { ValidationErrorModel } from '@common/forms/validation/error-model/validation-error-model';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
import { takeUntil } from 'rxjs/operators';
|
||||
import { AuthService } from "@app/core/services/auth/auth.service";
|
||||
|
||||
@Component({
|
||||
selector: 'app-sidebar-footer',
|
||||
|
@ -30,7 +31,8 @@ export class SidebarFooterComponent extends BaseComponent implements OnInit {
|
|||
public router: Router,
|
||||
private contactSupportService: ContactSupportService,
|
||||
private uiNotificationService: UiNotificationService,
|
||||
private formService: FormService
|
||||
private formService: FormService,
|
||||
private authentication: AuthService,
|
||||
) {
|
||||
super();
|
||||
}
|
||||
|
@ -110,4 +112,8 @@ export class SidebarFooterComponent extends BaseComponent implements OnInit {
|
|||
(<any>this.contactEmailFormModel.validationErrorModel)[item] = (<any>validationErrorModel)[item];
|
||||
});
|
||||
}
|
||||
|
||||
public isAuthenticated(): boolean {
|
||||
return !(!this.authentication.current());
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue