Commit 6bb9ef44 authored by George Kalampokis's avatar George Kalampokis
Browse files

Admin Login can performed also by pressing the Enter key (ref #223)

parent ea5ec989
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
import { Component, OnInit } from '@angular/core';
import { Component, OnInit, HostListener } from '@angular/core';
import { Router } from '@angular/router';
import { Credential } from '@app/core/model/auth/credential';
import { AuthService } from '@app/core/services/auth/auth.service';
@@ -17,6 +17,10 @@ export class AdminLoginComponent extends BaseComponent implements OnInit {
	public auth2: any;
	public credential: Credential;

	@HostListener('document:keydown.enter', ['$event']) onKeydownHandler() {
		this.nativeLogin();
	}

	constructor(
		private authService: AuthService,
		private uiNotificationService: UiNotificationService,