Source of file FilterDataList.php
Size: 0,847 Bytes - Last Modified: 2021-12-23T10:31:47+00:00
/var/www/docs.ssmods.com/process/src/tests/Fake/FilterDataList.php
12345678910111213141516171819202122232425262728293031323334353637383940414243444546 | <?php namespace SilverStripe\GraphQL\Tests\Fake; use SilverStripe\Dev\TestOnly; use SilverStripe\GraphQL\MutationCreator; use SilverStripe\ORM\DataList; class FilterDataList extends DataList implements TestOnly { public $filterField; public $filterValue; public $excludeField; public $excludeValue; public function filter() { $args = func_get_args(); $field = $args[0]; $value = $args[1]; $clone = clone $this; $clone->filterField = $field; $clone->filterValue = $value; return $clone; } public function exclude() { $args = func_get_args(); $field = $args[0]; $value = $args[1]; $clone = clone $this; $clone->excludeField = $field; $clone->excludeValue = $value; return $clone; } } |