From 3739334e25316702889ab10f3c7cf4c828b2307b Mon Sep 17 00:00:00 2001 From: Kotaro Terada Date: Tue, 13 Nov 2018 21:16:37 +0900 Subject: [PATCH] NIFIREG-188: Login by hitting Enter in the input fields in web UI Signed-off-by: Pierre Villard This closes #147. --- .../components/login/dialogs/nf-registry-user-login.html | 4 ++-- .../webapp/components/login/dialogs/nf-registry-user-login.js | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.html b/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.html index e873e47c1..7414469da 100644 --- a/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.html +++ b/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.html @@ -27,12 +27,12 @@
- +
- +
diff --git a/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.js b/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.js index e9c024e45..d97e85a49 100644 --- a/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.js +++ b/nifi-registry-core/nifi-registry-web-ui/src/main/webapp/components/login/dialogs/nf-registry-user-login.js @@ -50,6 +50,9 @@ NfRegistryUserLogin.prototype = { * @param password The password. */ login: function (username, password) { + if (username.value.length === 0 || password.value.length === 0) { + return; + } var self = this; this.nfRegistryApi.postToLogin(username.value, password.value).subscribe(function (response) { if (response || response.status === 200) {