mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Trim ModelAdmin SearchForm values
This commit is contained in:
parent
5f31983ded
commit
7484b4f5d9
@ -210,6 +210,11 @@ abstract class ModelAdmin extends LeftAndMain {
|
|||||||
public function getList() {
|
public function getList() {
|
||||||
$context = $this->getSearchContext();
|
$context = $this->getSearchContext();
|
||||||
$params = $this->request->requestVar('q');
|
$params = $this->request->requestVar('q');
|
||||||
|
|
||||||
|
if(is_array($params)) {
|
||||||
|
$params = array_map('trim', $params);
|
||||||
|
}
|
||||||
|
|
||||||
$list = $context->getResults($params);
|
$list = $context->getResults($params);
|
||||||
|
|
||||||
$this->extend('updateList', $list);
|
$this->extend('updateList', $list);
|
||||||
|
Loading…
Reference in New Issue
Block a user