1
0
Fork 0

bugfix filter

This commit is contained in:
Heiko Kernbach 2013-02-25 12:32:06 +01:00
parent 52e791cbd7
commit d4b3982ba4
2 changed files with 4 additions and 2 deletions

View File

@ -25,7 +25,7 @@ arangoHelper = {
isSystemCollection: function (val) {
//return val && val.name && val.name.substr(0, 1) === '_';
return name.substr(0, 1) === '_';
return val.substr(0, 1) === '_';
},
collectionApiType: function (identifier) {

View File

@ -4,7 +4,7 @@ var collectionsView = Backbone.View.extend({
searchOptions: {
searchPhrase: null,
excludeSystem: false
excludeSystem: true
},
init: function () {
@ -20,6 +20,8 @@ var collectionsView = Backbone.View.extend({
searchPhrase = this.searchOptions.searchPhrase.toLowerCase();
}
this.collection.each(function (arango_collection) {
if (arango_collection.get('name').substr(0,1) === "_") {
}
if (searchPhrase !== '' && arango_collection.get('name').toLowerCase().indexOf(searchPhrase) === -1) {
// search phrase entered but current collection does not match?
return;