mirror of
https://github.com/nextcloud/passman.git
synced 2025-10-27 13:56:16 +08:00
Removed unused parameter from credentialscontroller
added nullcheck on native searchbox Signed-off-by: fnuesse <felix.nuesse@t-online.de>
This commit is contained in:
parent
013eefeb62
commit
78c97f4a18
1 changed files with 21 additions and 19 deletions
|
|
@ -33,8 +33,8 @@
|
|||
*/
|
||||
angular.module('passmanApp')
|
||||
.controller('CredentialCtrl', ['$scope', 'VaultService', 'SettingsService', '$location', 'CredentialService',
|
||||
'$rootScope', 'FileService', 'EncryptService', 'TagService', '$timeout', 'NotificationService', 'CacheService', 'ShareService', 'SharingACL', '$interval', '$filter', '$routeParams', '$sce', '$translate','$compile',
|
||||
function ($scope, VaultService, SettingsService, $location, CredentialService, $rootScope, FileService, EncryptService, TagService, $timeout, NotificationService, CacheService, ShareService, SharingACL, $interval, $filter, $routeParams, $sce, $translate, $compile) {
|
||||
'$rootScope', 'FileService', 'EncryptService', 'TagService', '$timeout', 'NotificationService', 'CacheService', 'ShareService', 'SharingACL', '$interval', '$filter', '$routeParams', '$sce', '$translate',
|
||||
function ($scope, VaultService, SettingsService, $location, CredentialService, $rootScope, FileService, EncryptService, TagService, $timeout, NotificationService, CacheService, ShareService, SharingACL, $interval, $filter, $routeParams, $sce, $translate) {
|
||||
$scope.active_vault = VaultService.getActiveVault();
|
||||
if (!SettingsService.getSetting('defaultVault') || !SettingsService.getSetting('defaultVaultPass')) {
|
||||
if (!$scope.active_vault) {
|
||||
|
|
@ -329,25 +329,27 @@
|
|||
|
||||
//searchboxfix
|
||||
var native_search = document.getElementById("searchbox");
|
||||
native_search.nextElementSibling.addEventListener('click', function (e) {
|
||||
$scope.$apply(function () {
|
||||
$scope.filterOptions.filterText="";
|
||||
});
|
||||
});
|
||||
if(native_search !== null){
|
||||
native_search.nextElementSibling.addEventListener('click', function (e) {
|
||||
$scope.$apply(function () {
|
||||
$scope.filterOptions.filterText="";
|
||||
});
|
||||
});
|
||||
|
||||
native_search.classList.remove('hidden');
|
||||
native_search.addEventListener('keypress', function (e) {
|
||||
if(e.keyCode === 13){
|
||||
e.preventDefault();
|
||||
}
|
||||
});
|
||||
native_search.classList.remove('hidden');
|
||||
native_search.addEventListener('keypress', function (e) {
|
||||
if(e.keyCode === 13){
|
||||
e.preventDefault();
|
||||
}
|
||||
});
|
||||
|
||||
native_search.addEventListener('keyup', function (e) {
|
||||
console.log("keyup");
|
||||
$scope.$apply(function () {
|
||||
$scope.filterOptions.filterText=native_search.value;
|
||||
});
|
||||
});
|
||||
native_search.addEventListener('keyup', function (e) {
|
||||
console.log("keyup");
|
||||
$scope.$apply(function () {
|
||||
$scope.filterOptions.filterText=native_search.value;
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
$scope.filtered_credentials = [];
|
||||
$scope.$watch('[selectedtags, filterOptions, delete_time, active_vault.credentials]', function () {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue