mirror of
https://github.com/nextcloud/passman.git
synced 2024-12-26 09:34:02 +08:00
Update tag filter
This commit is contained in:
parent
106cf3bf5b
commit
156f935498
1 changed files with 5 additions and 3 deletions
|
@ -15,14 +15,16 @@ angular.module('passmanApp')
|
|||
if(tags.length > 0) {
|
||||
for (var ci = 0; ci < credentials.length; ci++) {
|
||||
var c = credentials[ci];
|
||||
var matches = 0;
|
||||
for (var ct = 0; ct < c.tags_raw.length; ct++) {
|
||||
var t = c.tags_raw[ct];
|
||||
if(tags.indexOf(t.text) != -1){
|
||||
if(_credentials.indexOf(c) === -1){
|
||||
_credentials.push(c);
|
||||
}
|
||||
matches++;
|
||||
}
|
||||
}
|
||||
if(matches === tags.length){
|
||||
_credentials.push(c);
|
||||
}
|
||||
}
|
||||
}
|
||||
if(tags.length == 0){
|
||||
|
|
Loading…
Reference in a new issue