From de4824077eecee0e76da422b039ff34428eef3ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julian=20M=C3=BCller?= Date: Thu, 21 Jan 2016 22:22:26 +0100 Subject: [PATCH] First try for shareWithField error message Second try for ShareWithField error message --- core/js/sharedialogview.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/js/sharedialogview.js b/core/js/sharedialogview.js index 4cebf7962e8..52e46664853 100644 --- a/core/js/sharedialogview.js +++ b/core/js/sharedialogview.js @@ -196,9 +196,16 @@ var suggestions = users.concat(groups).concat(remotes); if (suggestions.length > 0) { + $('.shareWithField').removeClass('error'); + $('.shareWithField').tooltip('hide') $('.shareWithField').autocomplete("option", "autoFocus", true); response(suggestions); + } else { + $('.shareWithField').addClass('error'); + $('.shareWithField').attr('title', t('core', 'No users or groups found for ' + $('.shareWithField').val())); + $('.shareWithField').tooltip({placement: 'bottom', trigger: 'manual'}); + $('.shareWithField').tooltip('show'); response(); } } else {