|
4 | 4 |
|
5 | 5 | namespace Czim\Filter;
|
6 | 6 |
|
| 7 | +use Closure; |
7 | 8 | use Czim\Filter\Contracts\FilterDataInterface;
|
8 | 9 | use Czim\Filter\Contracts\FilterInterface;
|
9 | 10 | use Czim\Filter\Contracts\ParameterFilterInterface;
|
@@ -66,7 +67,7 @@ class Filter implements FilterInterface
|
66 | 67 | * Join memory: set join parameters for query->join() calls here, so they may be applied once and
|
67 | 68 | * without unnecessary or problematic duplication.
|
68 | 69 | *
|
69 |
| - * @var array<string, array<int, string>> keyed by identifying string/name |
| 70 | + * @var array<string, array<int, string|Closure>> keyed by identifying string/name |
70 | 71 | */
|
71 | 72 | protected array $joins = [];
|
72 | 73 |
|
@@ -304,9 +305,9 @@ protected function forgetJoins(): void
|
304 | 305 | /**
|
305 | 306 | * Adds a query join to be added after all parameters are applied.
|
306 | 307 | *
|
307 |
| - * @param string $key identifying key, used to prevent duplicates |
308 |
| - * @param array<int, string> $parameters |
309 |
| - * @param string|null $joinType {@link JoinType} 'join'/'inner', 'right'; defaults to left join |
| 308 | + * @param string $key identifying key, used to prevent duplicates |
| 309 | + * @param array<int, string|Closure> $parameters [...string] or [string, Closure] |
| 310 | + * @param string|null $joinType {@link JoinType} 'join'/'inner', 'right'; defaults to left join |
310 | 311 | */
|
311 | 312 | public function addJoin(string $key, array $parameters, ?string $joinType = null): void
|
312 | 313 | {
|
|
0 commit comments