fix(legacy): advanced search by track type id
Advanced where clause didn't support matching primary keys. Fixes #2344
This commit is contained in:
parent
87bc388c3e
commit
fcfe52ec9d
1 changed files with 7 additions and 2 deletions
|
@ -50,11 +50,16 @@ class Application_Model_Datatables
|
|||
}
|
||||
} else {
|
||||
if (trim($input1) !== '') {
|
||||
if ($dbname == 'track_type_id') {
|
||||
$where['clause'][$dbname] = $dbname . ' = :' . $dbname . '1';
|
||||
$where['params'][$dbname . '1'] = $input1;
|
||||
} else {
|
||||
$where['clause'][$dbname] = $dbname . ' ILIKE :' . $dbname . '1';
|
||||
$where['params'][$dbname . '1'] = '%' . $input1 . '%';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $where;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue