Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ADmad committed Apr 18, 2020
1 parent 8f0eb99 commit 1d13d9f
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,9 @@ class PostsTable extends Table
{
/**
* @param array $config
*
* @return void
*/
public function initialize(array $config)
public function initialize(array $config): void
{
parent::initialize($config);

Expand Down Expand Up @@ -101,6 +100,9 @@ loaded only when actually used.

```php
// src/Model/Filter/PostsCollection.php
<?php
declare(strict_types=1);

namespace App\Model\Filter;

use Search\Model\Filter\FilterCollection;
Expand Down Expand Up @@ -202,6 +204,7 @@ in the Webservice plugin.

```php
<?php
declare(strict_types=1);

namespace App\Model\Endpoint;

Expand Down Expand Up @@ -453,7 +456,7 @@ your form. You can use the `filterEmpty` search option to ignore any empty field

Be sure to allow empty in your search form, if you're using one.
```php
echo $this->Form->input('author_id', ['empty' => 'Pick an author']);
echo $this->Form->control('author_id', ['empty' => 'Pick an author']);
```

## Empty fields
Expand All @@ -479,6 +482,8 @@ You can create your own filter by by creating a filter class under `src/Model/Fi

```php
<?php
declare(strict_types=1);

This comment has been minimized.

Copy link
@dereuromark

dereuromark Apr 18, 2020

Member

These shouldnt be in docs, IMO
they are just noise that is specific to the cs ruleset to apply where needed, but don't clarify the code/content.


namespace App\Model\Filter;

class MyCustomFilter extends \Search\Model\Filter\Base
Expand Down

0 comments on commit 1d13d9f

Please sign in to comment.