mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-09-08 18:51:12 +02:00
16 lines
274 B
PHP
16 lines
274 B
PHP
|
<?php
|
||
|
/**
|
||
|
* Uses a substring match against content in column rows.
|
||
|
*
|
||
|
* @package sapphire
|
||
|
* @subpackage search
|
||
|
*/
|
||
|
class SubstringFilter extends SearchFilter {
|
||
|
|
||
|
public function apply(SQLQuery $query) {
|
||
|
return $query->where("LOCATE({$this->name}, $value)");
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
?>
|