Code:
class ProxyListFormFilter extends BaseProxyListFormFilter
...
public function doBuildQuery(array $values) {
$q = parent::doBuildQuery($values);
$rootAlias = $q->getRootAlias();
$q->addWhere($rootAlias . '.proxy_type = ?', 'regular');
return $q;
}
I just did this to filter as default 1 column by a fixed type. The column is defined this way:
proxy_type:
type: enum(16)
values:
- regular
#- php_gateway
The very strange behaviour is that i get an empty list with no rows but the counter at the end shows: 3 results.
What I'm doing wrong or missing ?
Sorry my fault..Basically due to caching after applying the filter the page still pointed to a huge page number while the returned records where only 3. So no display for a page which do not contain the first 3 records.