Roo/data/Store.js
authoredward <edward@roojs.com>
Mon, 9 Nov 2015 06:21:37 +0000 (14:21 +0800)
committeredward <edward@roojs.com>
Mon, 9 Nov 2015 06:21:37 +0000 (14:21 +0800)
Roo/bootstrap/ComboBox.js

Roo/bootstrap/ComboBox.js
Roo/data/Store.js

index 376bf15..a1e3ec1 100644 (file)
@@ -1390,7 +1390,7 @@ Roo.extend(Roo.bootstrap.ComboBox, Roo.bootstrap.TriggerField, {
                     if(forceAll){
                         this.store.clearFilter();
                     }else{
-                        this.store.filter( this.displayField, q, this.anyMatch);
+                        this.store.filter(this.filterField || this.displayField, q, this.anyMatch);
                     }
                     this.onLoad();
                 }else{
index 7da8f31..9066f2d 100644 (file)
@@ -584,9 +584,18 @@ Roo.extend(Roo.data.Store, Roo.util.Observable, {
      * @param {Boolean} anyMatch True to match any part not just the beginning
      */
     filter : function(property, value, anyMatch){
-        Roo.log(typeof(property));
+        
+        if(typeof(property) == 'string'){
+            var fn = this.createFilterFn(property, value, anyMatch);
+            return fn ? this.filterBy(fn) : this.clearFilter();
+        }
+        Roo.each(property, function(p){
+            
+            
+        });
         var fn = this.createFilterFn(property, value, anyMatch);
         return fn ? this.filterBy(fn) : this.clearFilter();
+        
     },
 
     /**