mirror of
https://github.com/getredash/redash.git
synced 2026-05-09 21:02:27 -04:00
Fix: default predicate should be undefined and not empty string
This commit is contained in:
committed by
Amir Nissim
parent
d421848795
commit
041d5da13b
@@ -15,7 +15,7 @@
|
||||
sortPredicate: '',
|
||||
formatFunction: '',
|
||||
formatParameter: '',
|
||||
filterPredicate: '',
|
||||
filterPredicate: undefined,
|
||||
cellTemplateUrl: '',
|
||||
headerClass: '',
|
||||
cellClass: ''
|
||||
@@ -184,7 +184,7 @@
|
||||
replace: false,
|
||||
link: function (scope, element, attr, ctrl) {
|
||||
|
||||
scope.searchValue = '';
|
||||
scope.searchValue = undefined;
|
||||
|
||||
scope.$watch('searchValue', function (value) {
|
||||
//todo perf improvement only filter on blur ?
|
||||
@@ -464,14 +464,13 @@
|
||||
* @param column
|
||||
*/
|
||||
this.search = function (input, column) {
|
||||
|
||||
//update column and global predicate
|
||||
if (column && scope.columns.indexOf(column) !== -1) {
|
||||
predicate.$ = '';
|
||||
column.filterPredicate = input;
|
||||
} else {
|
||||
for (var j = 0, l = scope.columns.length; j < l; j++) {
|
||||
scope.columns[j].filterPredicate = '';
|
||||
scope.columns[j].filterPredicate = undefined;
|
||||
}
|
||||
predicate.$ = input;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user